astropy / ccdproc

Astropy affiliated package for reducing optical/IR CCD data
https://ccdproc.readthedocs.io
BSD 3-Clause "New" or "Revised" License
89 stars 87 forks source link

Several of the functions in ccdproc.ccdproc do not actually return CCDData objects #18

Closed mwcraig closed 10 years ago

mwcraig commented 10 years ago

Not sure this is the end of the world, but they tend to return whatever type was passed in (e.g. a numpy array).

I'd lean towards ensuring that a CCDData object is returned.

crawfordsm commented 10 years ago

My feeling is more along the lines that they should return the type that they were given if the type is an acceptable object to give it. It would probably be better to add something to throw an error if an unacceptable type is given, but i'd rather than limit how people might use the tools.

mwcraig commented 10 years ago

I'm fine with just updating the docstrings to state that the return type will match the input type. I think it would make sense to do some type checking on input, but maybe we should hold off a bit until the implementation is further along.

For example, if we end up embedding uncertainty propagation fairly deeply into this we presumably need to impose different restrictions than if not.

Though maybe that is a non-issue because if you want uncertainty propagation you need to use a CCDData object?

mwcraig commented 10 years ago

Closing because we settled on returning CCDData for now.