Skip to content

Commit 540c808

Browse files
committed
fix 'numpy' NameError in __init__.py
1 parent c51fbb1 commit 540c808

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

openmatrix/__init__.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ def open_file(filename, mode='r', title='', root_uep='/',
3838
'None' will create enormous uncompressed files.
3939
Only 'zlib' compression is guaranteed to be available on all HDF5 implementations.
4040
See HDF5 docs for more detail.
41-
shape: numpy.array
41+
shape: array-like
4242
Shape of matrices in this file. Default is None. Specify a valid shape
4343
(e.g. (1000,1200)) to enforce shape-checking for all added objects.
4444
If shape is not specified, the first added matrix will not be shape-checked
@@ -62,7 +62,7 @@ def open_file(filename, mode='r', title='', root_uep='/',
6262

6363
# shape
6464
if shape:
65-
storeshape = numpy.array([shape[0],shape[1]], dtype='int32')
65+
storeshape = np.array([shape[0],shape[1]], dtype='int32')
6666
f.root._v_attrs['SHAPE'] = storeshape
6767

6868
# /data and /lookup folders

0 commit comments

Comments
 (0)