Skip to content

Commit e532a07

Browse files
committed
MAINT: add several missing aliases
1 parent d8aa07b commit e532a07

File tree

4 files changed

+7
-1
lines changed

4 files changed

+7
-1
lines changed

torch_np/_detail/_binary_ufuncs.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
not_equal,
3939
)
4040
from torch import pow as power
41-
from torch import remainder, subtract
41+
from torch import remainder, subtract, true_divide
4242

4343
from . import _dtypes_impl, _util
4444

torch_np/_detail/_unary_ufuncs.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
# renames
88
from torch import absolute as fabs
99
from torch import arccos, arccosh, arcsin, arcsinh, arctan, arctanh
10+
from torch import bitwise_not
1011
from torch import bitwise_not as invert
1112
from torch import ceil
1213
from torch import conj_physical as conjugate
@@ -31,6 +32,7 @@
3132
from torch import rad2deg
3233
from torch import rad2deg as degrees
3334
from torch import reciprocal
35+
from torch import round as fix
3436
from torch import round as rint
3537
from torch import sign, signbit, sin, sinh, sqrt, square, tan, tanh, trunc
3638

torch_np/_dtypes.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,10 @@ class bool_(generic):
174174
"double": float64,
175175
"float_": float64,
176176
"csingle": complex64,
177+
"singlecomplex": complex64,
177178
"cdouble": complex128,
179+
"cfloat": complex128,
180+
"complex_": complex128,
178181
}
179182
for name, obj in _name_aliases.items():
180183
globals()[name] = obj

torch_np/tests/test_basic.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@
4545

4646
ufunc_names = _unary_ufuncs.__all__
4747
ufunc_names.remove("invert") # torch: bitwise_not_cpu not implemented for 'Float'
48+
ufunc_names.remove("bitwise_not")
4849

4950
one_arg_funcs += [getattr(_unary_ufuncs, name) for name in ufunc_names]
5051

0 commit comments

Comments
 (0)