There was no context manager solution to go with the comment
This commit is contained in:
1 parent
8c96897af3
commit
1ecdd416d3
1 file changed
+2
-2
@@ -371,8 +371,8 @@ Z = np.ones(1) / 0
|
|||||||
_ = np.seterr(**defaults)
|
_ = np.seterr(**defaults)
|
||||||
|
|
||||||
# Equivalently with a context manager
|
# Equivalently with a context manager
|
||||||
nz = np.nonzero([1,2,0,0,4,0])
|
with np.errstate(all="ignore"):
|
||||||
print(nz)
|
np.arange(3) / 0
|
||||||
|
|
||||||
< q32
|
< q32
|
||||||
Is the following expressions true? (★☆☆)
|
Is the following expressions true? (★☆☆)
|
||||||
|
|||||||
Reference in new issue
Block a user