Closed olegs closed 8 years ago
import numpy as np npz = np.load('/Users/oleg/Desktop/zinbra_peaks_200_1.0E-4.npz') npz.files npz = np.load('/Users/oleg/Desktop/zinbra_peaks_200_1.0E-4.npz') npz.files Out[31]: ['H4K20me1', 'H3K4me1', 'H3K9ac', 'H3K4me3', 'H3K4me2', 'H3K27ac', 'Input_Sonicated', 'CTCF', 'H3K36me3', 'H3K27me3'] In [32]: npz['CTCF'] --------------------------------------------------------------------------- ValueError Traceback (most recent call last) <ipython-input-32-56170b6f17ad> in <module>() ----> 1 npz['CTCF'] /Users/oleg/miniconda3/lib/python3.5/site-packages/numpy/lib/npyio.py in __getitem__(self, key) 222 return format.read_array(bytes, 223 allow_pickle=self.allow_pickle, --> 224 pickle_kwargs=self.pickle_kwargs) 225 else: 226 return self.zip.read(key) /Users/oleg/miniconda3/lib/python3.5/site-packages/numpy/lib/format.py in read_array(fp, allow_pickle, pickle_kwargs) 621 version = read_magic(fp) 622 _check_version(version) --> 623 shape, fortran_order, dtype = _read_array_header(fp, version) 624 if len(shape) == 0: 625 count = 1 /Users/oleg/miniconda3/lib/python3.5/site-packages/numpy/lib/format.py in _read_array_header(fp, version) 504 not numpy.all([isinstance(x, (int, long)) for x in d['shape']])): 505 msg = "shape is not valid: %r" --> 506 raise ValueError(msg % (d['shape'],)) 507 if not isinstance(d['fortran_order'], bool): 508 msg = "fortran_order is not a valid bool: %r" ValueError: shape is not valid: 550581