Ratarmount support

This commit is contained in:
Noe Brucy
2022-11-24 16:44:44 +01:00
parent facb37d753
commit df84e6c2d5
3 changed files with 22 additions and 4 deletions
+5 -2
View File
@@ -41,8 +41,11 @@ def find_nums(study, prep_function, time_function, time_min=0):
def write_paths(nums, path_from_home, filename="~/list_file"):
paths = []
for key in nums:
for num in nums[key]:
paths.append(f"{path_from_home}/{key}/output_{num:05}\n")
for num in self.nums[run]:
if os.path.exists("{prefix}/{run}/output_{num:05}/output_{num:05}\n"):
paths.append(f"{prefix}/{run}/output_{num:05}/output_{num:05}\n")
else:
paths.append(f"{prefix}/{run}/output_{num:05}\n")
f = open(os.path.expanduser(filename), "w")
f.writelines(paths)
f.close()