[SciPy-dev] genetic algorithm, number theory, filterdesign,zerofinding
oliphant at ee.byu.edu
Thu Apr 11 12:11:18 CDT 2002
> How to you feel about Fortran? Actually C is also fine for me.
> My point is that we should use f2py to generate the interfaces to these C
> (or Fortran, if you have positive feelings about it) routines.
> It has an advantage that you don't need to struggle with the
> details of Python C/API (reference counting, argument checks, etc.)
> All this is supported in f2py generated interfaces. Using f2py saves time
> and bugs. And the f2py generated extension modules are really easy to
> If you are not familiar with f2py then we can cooperate. You give me
> a native C function and I'll give you an interface for calling this C
> function from Python in no time.
> > For newton, I don't think the option of using computed derivatives is
> > worth including. There is a slightly higher order of convergence (2 vs
> > 1.4), but this is likely to be swamped in function evaluation time,
> > especially if the function is python and the routine is C.
I understand the point now. I misread it.
We should include it. Yes, people may never actually use it. But there
are cases where the derivative is not hard to compute. (We could put an
option where the derivative is computed along with the function and both
are returned together --- can often save time).
But, I would hesitate to remove it entirely. It's turned off by default
> Indeed, I have never used computed derivatives in my real problems. They
> are usually to large that calculating exact jacobian, even a bounded one,
> is to expensive. But I would like to see how much is there gain or lost of
> using exact jacobian in real example.
See optimize.py for an example of how knowledge of the jacobian can
decrease minimization time for the rosenbrock function.
More information about the Scipy-dev