Skip to content

Commit 45d95e1

Browse files
committed
MAINT: use _private not __private__
1 parent 634ae95 commit 45d95e1

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

torch_np/_ufuncs.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77

88
# ############# Binary ufuncs ######################
99

10-
__binary__ = [
10+
_binary = [
1111
name
1212
for name in dir(_binary_ufuncs_impl)
1313
if not name.startswith("_") and name not in ["torch", "matmul"]
@@ -120,7 +120,7 @@ def divmod(
120120
# For each torch ufunc implementation, decorate and attach the decorated name
121121
# to this module. Its contents is then exported to the public namespace in __init__.py
122122
#
123-
for name in __binary__:
123+
for name in _binary:
124124
ufunc = getattr(_binary_ufuncs_impl, name)
125125
decorated = normalizer(deco_binary_ufunc(ufunc))
126126

@@ -134,13 +134,13 @@ def modf(x, /, *args, **kwds):
134134
return rem, quot
135135

136136

137-
__binary__ = __binary__ + ["divmod", "modf", "matmul"]
137+
_binary = _binary + ["divmod", "modf", "matmul"]
138138

139139

140140
# ############# Unary ufuncs ######################
141141

142142

143-
__unary__ = [
143+
_unary = [
144144
name
145145
for name in dir(_unary_ufuncs_impl)
146146
if not name.startswith("_") and name != "torch"
@@ -185,7 +185,7 @@ def wrapped(
185185
# For each torch ufunc implementation, decorate and attach the decorated name
186186
# to this module. Its contents is then exported to the public namespace in __init__.py
187187
#
188-
for name in __unary__:
188+
for name in _unary:
189189
ufunc = getattr(_unary_ufuncs_impl, name)
190190
decorated = normalizer(deco_unary_ufunc(ufunc))
191191

@@ -194,4 +194,4 @@ def wrapped(
194194
vars()[name] = decorated
195195

196196

197-
__all__ = __binary__ + __unary__
197+
__all__ = _binary + _unary

0 commit comments

Comments
 (0)