From 838523b8febd923c2ad39b3e61fd74a2880c8587 Mon Sep 17 00:00:00 2001 From: dachengx Date: Mon, 26 Feb 2024 11:29:05 +0800 Subject: [PATCH 1/2] Minor bug fix for cutax installation --- utilix/batchq.py | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/utilix/batchq.py b/utilix/batchq.py index acab814..5980fa6 100644 --- a/utilix/batchq.py +++ b/utilix/batchq.py @@ -116,7 +116,7 @@ def submit_job(jobstring, dry_run=False, mem_per_cpu=1000, container='xenonnt-development.simg', - bind=['/project2/lgrandi/xenonnt/dali:/dali', '/project2', '/project', '/scratch/midway2/%s'%(getpass.getuser()), '/scratch/midway3/%s'%(getpass.getuser())], + bind=['/home', '/project2/lgrandi/xenonnt/dali:/dali', '/project2', '/project', '/scratch/midway2/%s'%(getpass.getuser()), '/scratch/midway3/%s'%(getpass.getuser())], cpus_per_task=1, hours=None, node=None, @@ -171,13 +171,12 @@ def submit_job(jobstring, jobstring = singularity_wrap(jobstring, container, bind, partition) # if you have exported INSTALL_CUTAX to be 1, then you do NOT need to unset CUTAX_LOCATION - if os.environ.get('INSTALL_CUTAX') == '1': - print("You have exported INSTALL_CUTAX to be 1, so I will unset it for you") - print("Your CUTAX_LOCATION is %s"%(os.environ.get('CUTAX_LOCATION'))) + print("Your current CUTAX_LOCATION is %s"%(os.environ.get('CUTAX_LOCATION'))) + if os.environ.get('INSTALL_CUTAX') != '1': + print("You have NOT exported INSTALL_CUTAX to be 1, so I will not unset CUTAX_LOCATION.") jobstring = 'unset X509_CERT_DIR\n' + 'module load singularity\n' + jobstring else: - print("You have NOT exported INSTALL_CUTAX to be 1, so I will unset CUTAX_LOCATION for you") - print("Your CUTAX_LOCATION is %s"%(os.environ.get('CUTAX_LOCATION'))) + print("You have exported INSTALL_CUTAX to be 1, so I will unset CUTAX_LOCATION for you.") jobstring = 'unset X509_CERT_DIR CUTAX_LOCATION\n' + 'module load singularity\n' + jobstring if not hours is None: From f2ea0027eb94e28c441ee5cb31eb9acb96296e95 Mon Sep 17 00:00:00 2001 From: dachengx Date: Mon, 26 Feb 2024 11:30:04 +0800 Subject: [PATCH 2/2] Remove unnecessary bind --- utilix/batchq.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utilix/batchq.py b/utilix/batchq.py index 5980fa6..90cdcf0 100644 --- a/utilix/batchq.py +++ b/utilix/batchq.py @@ -116,7 +116,7 @@ def submit_job(jobstring, dry_run=False, mem_per_cpu=1000, container='xenonnt-development.simg', - bind=['/home', '/project2/lgrandi/xenonnt/dali:/dali', '/project2', '/project', '/scratch/midway2/%s'%(getpass.getuser()), '/scratch/midway3/%s'%(getpass.getuser())], + bind=['/project2/lgrandi/xenonnt/dali:/dali', '/project2', '/project', '/scratch/midway2/%s'%(getpass.getuser()), '/scratch/midway3/%s'%(getpass.getuser())], cpus_per_task=1, hours=None, node=None,