Closed ramav87 closed 3 years ago
set_dimension does not assert uniqueness of the name of the dimension. This will then throw errors during writing.
data = np.random.normal(size=(5,5,5)) data = np.squeeze(np.array(data, dtype=np.float64)) data_set = sid.Dataset.from_array(data[:], name='Image') dim_types = ['spatial', 'spatial', 'spectral'] for ind in range(dims): print(ind, dims) data_set.set_dimension(ind, sid.Dimension(np.linspace(-2, 2, num=data_set.shape[ind], endpoint=True), name='x', units='um', quantity='Length', dimension_type=dim_types[ind]))
set_dimension does not assert uniqueness of the name of the dimension. This will then throw errors during writing.