Skip to content

Commit 60ce20a

Browse files
committed
hdf5 halo: store in kji order
1 parent 484eaf3 commit 60ce20a

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

libmpdata++/output/hdf5.hpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -411,7 +411,11 @@ namespace libmpdataxx
411411
space.selectHyperslab(H5S_SELECT_SET, shape_h.data(), offst_h.data());
412412
sspace_mem_h.selectHyperslab(H5S_SELECT_SET, shape_h.data(), offst_mem_h.data());
413413

414-
aux.write(arr.data(), flttype_solver, sspace_mem_h, space, dxpl_id);
414+
// convert from kij to kji storage order
415+
typename solver_t::arr_t kji_arr(shape_h);
416+
kji_arr = arr;
417+
418+
aux.write(kji_arr.data(), flttype_solver, sspace_mem_h, space, dxpl_id);
415419
}
416420

417421
void record_scalar_hlpr(const std::string &name, const std::string &group_name, typename solver_t::real_t data, H5::H5File hdf)

0 commit comments

Comments
 (0)