From 149a641bbfa8d31a8c2260c56d924b776015ad70 Mon Sep 17 00:00:00 2001 From: Connor Moore Date: Tue, 4 Aug 2026 10:08:51 +0200 Subject: Updated positions saving logic to read/write to positions.temp instead of positions.out, does not save if reading --- hpmr.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/hpmr.py b/hpmr.py index d33532b..c6e4791 100755 --- a/hpmr.py +++ b/hpmr.py @@ -500,7 +500,7 @@ geo_triso_compact_domain = (4,4,int(4*geo_const_height)) if cli_args.triso_latti # Generate packing if cli_args.packing: - geo_triso_compact_packing = np.loadtxt("positions.out",delimiter=",") + geo_triso_compact_packing = np.loadtxt("positions.temp",delimiter=",") else: geo_triso_compact_packing = openmc.model.pack_spheres( radius=geo_triso_spheres[-1].r, @@ -511,7 +511,8 @@ else: ) # Export positions to file for backup -np.savetxt("positions.out",geo_triso_compact_packing,delimiter=",") +if !cli_args.packing: + np.savetxt("positions.temp",geo_triso_compact_packing,delimiter=",") # Create the TRISO particles geo_triso_compact_trisos = [openmc.model.TRISO(geo_triso_spheres[4].r, geo_triso_universe, loc) for loc in geo_triso_compact_packing] -- cgit v1.2.3