Improve loading from ramses + hdf5 consersion

This commit is contained in:
Noe Brucy
2023-03-01 15:34:17 +01:00
parent 9bda60702a
commit ae8a8a605d
3 changed files with 213 additions and 50 deletions
+8
View File
@@ -0,0 +1,8 @@
# coding: utf-8
from snapshotprocessor import SnapshotProcessor
def convert_to_hdf5(path, snap_num, path_out=".", filename=None, **kwargs):
snap = SnapshotProcessor(path=path, num=snap_num, path_out=path_out, **kwargs)
snap.convert_hdf5(filename)
+5 -1
View File
@@ -100,7 +100,11 @@ class RunSelector:
self.allow_nodata = allow_nodata
self.namelist = {}
do_tests = (not self.fallback_nml) or (len(filter_nml) > 0)
do_tests = (
(not self.fallback_nml)
or (len(filter_nml) > 0)
or (sort_run_by is not None)
)
self.runs = self.get_runs(
in_runs, filter_name, filter_nml, sort_run_by, do_tests=do_tests
)