Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 9 additions & 5 deletions tools/scaling/scaling_cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -310,7 +310,7 @@ def organize_longitudinal(
"""
banner = r"""
+----------------------------------+
| Organize longitudianl data... |
| Organize longitudinal data... |
+----------------------------------+
"""
print(banner)
Expand Down Expand Up @@ -482,7 +482,7 @@ def collect_config(
else None
)
workflow_parameters = workflow_parameters.format_map(
SafeDict({"outdir": output_dir / "data"})
SafeDict({"outdir": working_dir / "data"})
)
print(f"- edited parameters: {workflow_parameters}")

Expand All @@ -497,7 +497,7 @@ def collect_config(
if infra == "slurm":
image_parameters = (
f"--cleanenv --home {home_dir} --bind {bind_dir} "
f"--bind {output_dir} "
f"--bind {working_dir} "
)
else:
image_parameters = ""
Expand All @@ -520,12 +520,16 @@ def collect_config(
index=False,
)

commands = f'"brainprep {workflow_id} {workflow_parameters}"'
if "group" in workflow_id:
commands = f"[[{commands}]]"

config_template = config_file.read_text()
config_str = config_template.format(
name=workflow_name,
operator="TO UPDATE",
date=str(datetime.now().date()),
commands=f'"brainprep {workflow_id} {workflow_parameters}"',
commands=commands,
parameters=image_parameters,
cluster=infra,
partition=partition,
Expand Down Expand Up @@ -632,7 +636,7 @@ def scan_configs(
print("No cache files found. Parsing data.")
selected = None
else:
print("Multiple cache files found:")
print("Cache file(s) found:")
for idx, path in enumerate(cache_files, 1):
print(f"{idx}. {path.name}")
choice = input(
Expand Down
Loading