[SciPy-dev] ndimage - docfiller and output_type

Ralf Gommers ralf.gommers@googlemail....
Mon Oct 12 14:51:54 CDT 2009

Hi all,

While working on the ndimage docs, I saw that the docfiller decorator in
ndimage.filters does not work well with the doc wiki. Basically, in the doc
wiki you see the docstring with the decorator applied. Then if you make an
edit, all the %(param) markup has been replaced. Compare the `convolve` and
`convolve1d` docstrings in trunk to see what happens.

Some options to fix this:
1. remove the filters docstrings from the doc wiki
2. make the doc wiki understand the decorator
3. remove the decorator, and do some copy-paste'ing of parameter
4. remove the decorator, and refer to a single description of those
parameters outside the docstring.

I would have a preference for 3 or 4, mostly because it's easier and more
robust. Would you like a patch for either of those options?

The second thing I came across is the output_type keyword in
ndimage.interpolation. Specifying anything other than None for that keyword
results in a RuntimeError. The code responsible for that is in
ndimage._ni_support.py :

def _get_output(output, input, output_type = None, shape = None):
    if output_type is not None:
        msg = "'output_type' argument is deprecated."
        msg += " Assign type to 'output' instead."
        raise RuntimeError, msg
        <6 more lines that never execute>

Is there any reason to keep that keyword around? I can write a patch for
that as well.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.scipy.org/pipermail/scipy-dev/attachments/20091012/f0f0ce21/attachment-0001.html 

More information about the Scipy-dev mailing list