Permalink
Browse files

supports numpy.fabs, fixes #51

  • Loading branch information...
1 parent 1463069 commit 724f2bcb00e93b42c0a51a08d8c3e5b4a3a09608 @ddale ddale committed Jan 17, 2013
Showing with 2 additions and 1 deletion.
  1. +1 −0 quantities/dimensionality.py
  2. +1 −1 quantities/quantity.py
View
1 quantities/dimensionality.py
@@ -309,6 +309,7 @@ def _d_reciprocal(q1, out=None):
def _d_copy(q1, out=None):
return q1.dimensionality
+p_dict[np.fabs] = _d_copy
p_dict[np.absolute] = _d_copy
p_dict[np.conjugate] = _d_copy
p_dict[np.negative] = _d_copy
View
2 quantities/quantity.py
@@ -233,7 +233,7 @@ def __array_prepare__(self, obj, context=None):
raise ValueError(
"""ufunc %r not supported by quantities
please file a bug report at https://github.com/python-quantities
- """
+ """ % uf
)
return res

0 comments on commit 724f2bc

Please sign in to comment.