Commit 3bcd42de authored by Chichi Lalescu's avatar Chichi Lalescu
Browse files

resizing of source field seems to be working

parent 37750597
...@@ -813,11 +813,12 @@ class DNS(_code): ...@@ -813,11 +813,12 @@ class DNS(_code):
min(dst_shape[1], src_file[src_dset_name].shape[1]), min(dst_shape[1], src_file[src_dset_name].shape[1]),
min(dst_shape[2], src_file[src_dset_name].shape[2]), min(dst_shape[2], src_file[src_dset_name].shape[2]),
3) 3)
print(self.ctype)
dst_file.create_dataset( dst_file.create_dataset(
dst_dset_name, dst_dset_name,
shape = dst_shape, shape = dst_shape,
dtype = self.ctype, dtype = np.dtype(self.ctype),
fillvalue = 0.0) fillvalue = complex(0))
for kz in range(min_shape[0]): for kz in range(min_shape[0]):
dst_file[dst_dset_name][kz,:min_shape[1], :min_shape[2]] = \ dst_file[dst_dset_name][kz,:min_shape[1], :min_shape[2]] = \
src_file[src_dset_name][kz, :min_shape[1], :min_shape[2]] src_file[src_dset_name][kz, :min_shape[1], :min_shape[2]]
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment