AlanZee's picture
Upload folder using huggingface_hub
ed552fd verified
Raw
History Blame Contribute Delete
464 Bytes
import h5py, sys
path = sys.argv[1] if len(sys.argv) > 1 else r"X:\0Agents-workspace\scholarship\paper2\Exp\data\raw\exp-000\dam_break\traj_0000.h5"
with h5py.File(path, "r") as f:
print(f"Keys: {list(f.keys())}")
for k in f.keys():
d = f[k]
if hasattr(d, "shape"):
print(f" {k}: shape={d.shape}, dtype={d.dtype}, min={d[:].min():.6f}, max={d[:].max():.6f}")
else:
print(f" {k}: {type(d).__name__} = {d}")