[SciPy-dev] band matrices in scipy

Robert Kern kern at ugcs.caltech.edu
Sun Nov 16 16:45:34 CST 2003


On Sun, Nov 16, 2003 at 03:50:39PM -0600, Pearu Peterson wrote:

[snip]

> However, help(MODULENAME.dsbev) could certainly give more
> information than just '<fortran object>'. The reason why it
> does not may be due to the fact that a <fortran object> does not
> have a __doc__ attribute, instead, when one tries to access
> <fortran object>.__doc__ then getattr function is called
> that generates documentation on fly. This is f2py feature to 
> reduce the size of extension modules.

Looking through pydoc.py (which the builtin help() calls), the problem
is that pydoc.py does not recognize a fortranobject as a function-alike.
For the interested, look at the method Doc.document. It uses the inspect
module, and that only seems to recognize the builtin function-like
types. I'll file a bug report asking for something a little smarter.

In the meantime, SciPy's info() and IPython's ? magic work just fine.

-- 
Robert Kern
kern at ugcs.caltech.edu

"In the fields of hell where the grass grows high
 Are the graves of dreams allowed to die."
  -- Richard Harter


More information about the Scipy-dev mailing list