Re: Another optimization request :-)

2009-02-12 Thread bearophileHUGS
On Feb 12, 2:48 am, jeffg wrote: > If anyone wants to take this on... I would really really like to have > the spring_layout modified to support multi-threading if at all > possible. You can start creating a compiled Python extension using ShedSkin, it may be enough. Bye, bearophile -- http://ma

Re: Another optimization request :-)

2009-02-12 Thread andrew cooke
jeffg wrote: > To be honest, this is not my code and I'm new to python. It's part of > the open source project NetworkX, but I'm using this one call > extensively. I'm also not that familiar with the math behind the > physics. I'll read the documents and see if I can figure it > out. :-) Thank

Re: Another optimization request :-)

2009-02-11 Thread Terry Reedy
jeffg wrote: If anyone wants to take this on... I would really really like to have the spring_layout modified to support multi-threading if at all possible. My test data is 20,000, which makes this process 20,000 x 20,000 or 400,000,000 (400 million) calculations. This is taking somewhere betwee

Re: Another optimization request :-)

2009-02-11 Thread jeffg
On Feb 11, 9:56 pm, "andrew cooke" wrote: > sorry, that was stupid.  there is no inversion (apart from 1/m), just the > integration. > > still, improving the integration would allow larger steps. > > andrew > > andrew cooke wrote: > > > why are you dong this point by point?  surely you can express

Re: Another optimization request :-)

2009-02-11 Thread andrew cooke
sorry, that was stupid. there is no inversion (apart from 1/m), just the integration. still, improving the integration would allow larger steps. andrew andrew cooke wrote: > > why are you dong this point by point? surely you can express the physics > as a set of equations and invert the mat

Re: Another optimization request :-)

2009-02-11 Thread andrew cooke
why are you dong this point by point? surely you can express the physics as a set of equations and invert the matrix? wouldn't that be a lot faster? you'd replace the iteration over all combinations of points with a faster matrix inversion. see for example http://www.medwelljournals.com/fullte

Another optimization request :-)

2009-02-11 Thread jeffg
If anyone wants to take this on... I would really really like to have the spring_layout modified to support multi-threading if at all possible. My test data is 20,000, which makes this process 20,000 x 20,000 or 400,000,000 (400 million) calculations. This is taking somewhere between 2-3 hours an