We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 34e41e1 commit d74cc92Copy full SHA for d74cc92
blosc2/ndarray.py
@@ -527,13 +527,13 @@ def fields(self):
527
Examples
528
--------
529
>>> import blosc2
530
+ >>> import numpy as np
531
>>> shape = (10,)
532
>>> dtype = np.dtype([('a', np.int32), ('b', np.float64)])
533
>>> # Create a structured array
534
>>> sa = blosc2.zeros(shape, dtype=dtype)
- >>> # Evaluate if the fields are equal
535
- >>> np.all((sa.fields['a'] == sa.fields['b'])[:])
536
- True
+ >>> # Check that fields are equal
+ >>> assert sa.fields['a'] == sa.fields['b']
537
538
"""
539
return self._fields
0 commit comments