astropy / halotools

Python package for studying large scale structure, cosmology, and galaxy evolution using N-body simulations and halo models
http://halotools.rtfd.org
100 stars 63 forks source link

Implement Astropy Quantities #76

Open aphearin opened 9 years ago

aphearin commented 9 years ago

Mostly this will only impact the halo catalog and merger tree dtype formatting.

aphearin commented 9 years ago

Give users the option to write supported model components that either do or do not work with Quantities. Try to implement this via a class-level use_quantities attribute. If set to False, the composite-model decorator will ensure that an ndarray view of the columns are passed to the component, and then the component model can safely perform arbitrary operations on the columns; if set to True, the passed columns will be Quantities, and so the component model will need to make columns dimensionless if they want to perform nonlinear transformations on them. Suggestion due to @eteq.