Python hits the spot
Siegfried Gonzi
siegfried.gonzi at kfunigraz.ac.at
Sat Jun 22 15:27:17 EDT 2002
Bengt Richter wrote:
>
> You apparently have a lot of different stuff glued together. Have you tested the
> separate pieces separately? Do you have some test problems that you can use to validate
> numerical results *exactly* (trailing decimal differences need an explanation. They
> can be benign/acceptable or not).
The Mie code (C function) works, because on Windows I wrote a program
under DISLIN in order to depict the phase function, and I can use the
same program under Linux without problems. The Fortran function works
too (the Fortran function is really a tiny piece and straightforward in
contrast to the C function which is a third party insane pointer hell).
The C code itself is essentially the same: on Windows I compiled it
with SWIG and Microsoft Visual C++ and on Linux I used gcc and SWIG; but
the name of the function is actually the same. The same goes for all the
other functions and directories.
> I hate to see Python (or anything) bashed without proof. So far I haven't seen the proof,
> nor an explanation.
>
> If your code is open source, maybe someone will be interested in discovering why
> it bogs Python down (or Python bogs it down ;-)
The code is open source but not very well documented. But I can send it
to you if you like. You can also get the data if you like.
First, I thought there is something wrong with my data because I have it
converted from DOS to UNIX with: dos2unix.
There is an interesting thing to observe: On Windows I am likely to hit
the 100MB threshold, but on Unix I only hit 10MB (and sometimes 20MB).
At least "top" shows me that.
You can get all the functions if you like. I would only have to get it
from my laptop back to my stationary machine.
Drop me a note if you want the functions and data. I can prepare it that
way that it will be ready to use for you.
What I further noticed. On Windows the Task manager tells me that in the
first 20 minutes Python uses constantly 99% of the processor power. The
same goes under Linux, but after that 20 minutes it sucks down to 87% on
Linux and on Windows! Note: same functions and that 8 times!
S. Gonzi
More information about the Python-list
mailing list