From 510480271bac1f55b5c2384281f90e673a3dd7fc Mon Sep 17 00:00:00 2001 From: Karim Ahmed <ahmedk@max-exfl001.desy.de> Date: Tue, 9 Apr 2019 15:22:38 +0200 Subject: [PATCH] Load anaconda in non-karabo python end only --- xfel_calibrate/calibrate.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/xfel_calibrate/calibrate.py b/xfel_calibrate/calibrate.py index fefa30112..f8f107ffb 100755 --- a/xfel_calibrate/calibrate.py +++ b/xfel_calibrate/calibrate.py @@ -377,7 +377,8 @@ def concurrent_run(temp_path, nb, nbname, args, cparm=None, cval=None, with open("{}/finalize.sh".format(temp_path), "w") as finfile: finfile.write("#!/bin/tcsh\n") finfile.write("module load texlive/2017\n") - finfile.write("module load anaconda/3\n") + finfile.write("PyExe=$(which python)\n") + finfile.write("if [[ $PyExe != *"karabo"* ]]; then module load anaconda/3; fi\n") finfile.write("echo 'Running finalize script'\n") finfile.write("python3 -c {}\n".format(fmtcmd.format(joblist=job_list))) all_stats = stat.S_IXUSR | stat.S_IWUSR | stat.S_IRUSR | stat.S_IRGRP | stat.S_IROTH -- GitLab