ratarmount

This commit is contained in:
Noe Brucy
2022-11-25 16:37:10 +01:00
parent 191be98733
commit 3be5413873
+6 -1
View File
@@ -524,7 +524,12 @@ def main(arg):
read_lvl = None read_lvl = None
if True: if True:
# Load output ------------------------------------------------------------------ # Load output ------------------------------------------------------------------
ro = pymses.RamsesOutput(arg.repo, iout, order=arg.order) # If ratarmount was used
if os.path.exists(f"{self.path}/output_{self.num:05}/output_{self.num:05}"):
path = f"{arg.repo}/output_{self.num:05}"
else:
path = arg.repo
ro = pymses.RamsesOutput(path, iout, order=arg.order)
if arg.magnetic: if arg.magnetic:
amr = ro.amr_source(["rho", "vel", "Bl", "Br"]) amr = ro.amr_source(["rho", "vel", "Bl", "Br"])
else: else: