Skip to content

Commit

Permalink
Changed which run file each scone version uses
Browse files Browse the repository at this point in the history
  • Loading branch information
OmegaLambda1998 committed Jun 19, 2024
1 parent ed21847 commit 41487c2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 7 deletions.
2 changes: 1 addition & 1 deletion pippin/classifiers/scone.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@

# =========================================

SCONE_SHELL_SCRIPT = "run_refactor.py" # top-level script under $SCONE_DIR
SCONE_SHELL_SCRIPT = "run.py" # top-level script under $SCONE_DIR

KEYLIST_SCONE_INPUT = [ 'init_env_train', 'init_env_heatmaps',
'prescale_heatmaps', 'nevt_select_heatmaps',
Expand Down
7 changes: 1 addition & 6 deletions pippin/classifiers/scone_legacy.py
Original file line number Diff line number Diff line change
Expand Up @@ -176,13 +176,8 @@ def classify(self, mode):

# TODO: nersc needs `module load esslurm` to sbatch gpu jobs, maybe make
# this shell command to a file so diff systems can define their own
file_to_run = 'run.py'
if self.options.get("REFACTORED", False):
file_to_run = 'run_refactor.py'
elif self.options.get("LEGACY", False):
file_to_run = 'run_legacy.py'
file_to_run = 'run_legacy.py'
path = Path(self.path_to_classifier) / file_to_run
path = path if path.exists() else Path(self.path_to_classifier) / 'run.py'
cmd = f"python {str(path)} --config_path {self.config_path}"
subprocess.run([cmd], shell=True)
self.logger.info(f"Running command: {cmd}")
Expand Down

0 comments on commit 41487c2

Please sign in to comment.