more improvements to h5_writer