Skip to content
Snippets Groups Projects
Verified Commit d22b3666 authored by Reza Housseini's avatar Reza Housseini
Browse files

refactor: use loadonly argument instead of server and batch

parent 3f13adfd
Branches
Tags
No related merge requests found
......@@ -130,9 +130,8 @@ class Submit(Slurm):
macro: str = "",
podkey: str = "szxrGQmT/l6o77a1UnyuyA",
licpath: str = "1999@flex.cd-adapco.com",
batch: str = "run",
loadonly: bool = False,
power: bool = True,
server: bool = False,
np: Union[str, int] = "$SLURM_NPROCS",
loc: bool = True,
version: str = "latest",
......@@ -152,12 +151,10 @@ class Submit(Slurm):
Specify a PoD license key.
licpath:
Specify a license path that overrides the default license path.
batch:
Run in batch mode (no UI), commands are mesh, run, step or Java macro files.
loadonly:
Run in server instead of batch mode.
power:
Use Power Session license option.
server:
Starts the server. The default is to start the client.
np:
Specify the number of processes for parallel simulations.
loc:
......@@ -171,12 +168,13 @@ class Submit(Slurm):
"""
self._add_argument_no_overwrite("job_name", f"starccm+-{Path(simfile).stem}")
loadonly_args = "-server" if loadonly else "-batch"
args = [
f"-macro {macro}" if macro else "",
f"-podkey {podkey}" if podkey else "",
f"-licpath {licpath}" if licpath else "",
"-batchsystem slurm",
f"-batch {batch}" if batch else "",
loadonly_args,
"-power" if power else "",
"-server" if server else "",
f"-np {np}" if np else "",
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment