Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
T
ToolBox
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
SCS
ToolBox
Commits
7157e231
Commit
7157e231
authored
3 years ago
by
Loïc Le Guyader
Browse files
Options
Downloads
Plain Diff
Merge branch 'SLURM' of
https://git.xfel.eu/gitlab/SCS/ToolBox
into SLURM
parents
9472910c
2c32330e
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!176
Improving SLURM based notebooks and scripts
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
doc/scripts/bin_dssc_module_job.sh
+39
-11
39 additions, 11 deletions
doc/scripts/bin_dssc_module_job.sh
doc/scripts/boz_parameters_job.sh
+0
-2
0 additions, 2 deletions
doc/scripts/boz_parameters_job.sh
with
39 additions
and
13 deletions
doc/scripts/bin_dssc_module_job.sh
+
39
−
11
View file @
7157e231
...
@@ -5,21 +5,49 @@
...
@@ -5,21 +5,49 @@
#SBATCH --mail-type=END,FAIL
#SBATCH --mail-type=END,FAIL
#SBATCH --output=logs/%j-%x.out
#SBATCH --output=logs/%j-%x.out
PROPOSAL
=
2719
while
getopts
":p:d:r:k:g:t:s:m:"
option
DARK
=
$1
do
RUN
=
$2
case
$option
in
MODULE_GROUP
=
$3
p
)
PROPOSAL
=
"
$OPTARG
"
;;
d
)
DARK
=
"
$OPTARG
"
;;
r
)
RUN
=
"
$OPTARG
"
;;
k
)
KERNEL
=
"
$OPTARG
"
;;
m
)
MODULE_GROUP
=
"
$OPTARG
"
;;
x
)
XAXIS
=
"
$OPTARG
"
;;
b
)
BINWIDTH
=
"
$OPTARG
"
;;
\?
)
echo
"Unknown option"
exit
1
;;
:
)
echo
"Missing option for input flag"
exit
1
;;
esac
done
# Load xfel environment
source
/etc/profile.d/modules.sh
source
/etc/profile.d/modules.sh
module load exfel
module load exfel
module load exfel_anaconda3/1.1
module load exfel_anaconda3/1.1
echo
processing run
$RUN
echo
processing run
$RUN
OUTPATH
=
/gpfs/exfel/exp/SCS/202002/p002719/scratch/tests
PDIR
=
$(
find-proposal
$PROPOSAL
)
mkdir
$OUTPATH
/r
$RUN
PPROPOSAL
=
"p
$(
printf
'%06d'
$PROPOSAL
)
"
RDIR
=
"
$PDIR
/usr/processed_runs/r
$(
printf
'%04d'
$RUN
)
"
mkdir
$RDIR
# Run papermill
NB
=
'Dask DSSC module binning.ipynb'
python3
-c
"import papermill as pm; pm.execute_notebook('Dask DSSC module binning.ipynb',
\
'
$OUTPATH
/r
$RUN
/output
$MODULE_GROUP
.ipynb',
\
# kernel list can be seen from 'jupyter kernelspec list'
parameters=dict(proposalNB='
$PROPOSAL
', dark_runNB='
$DARK
', runNB='
$RUN
', module_group='
$MODULE_GROUP
',
\
if
[
-z
"
${
KERNEL
}
"
]
;
then
path='
$OUTPATH
/r
$RUN
/', kernel='xfel'))"
KERNEL
=
"toolbox_
$PPROPOSAL
"
fi
python
-c
"import papermill as pm; pm.execute_notebook(
\
'
$NB
',
\
'
$RDIR
/output
$MODULE_GROUP
.ipynb',
\
kernel_name='
$KERNEL
',
\
parameters=dict(proposalNB=int('
$PROPOSAL
'),
\
dark_runNB=int('
$DARK
'),
\
runNB=int('
$RUN
'),
\
module_group=int('
$MODULE_GROUP
'),
\
path='
$RDIR
',
\
xaxis='
$XAXIS
',
\
bin_width=float('
$BINWIDTH
')))"
This diff is collapsed.
Click to expand it.
doc/scripts/boz_parameters_job.sh
+
0
−
2
View file @
7157e231
...
@@ -27,8 +27,6 @@ do
...
@@ -27,8 +27,6 @@ do
esac
esac
done
done
echo
${
KERNEL
}
# Load xfel environment
# Load xfel environment
source
/etc/profile.d/modules.sh
source
/etc/profile.d/modules.sh
module load exfel
module load exfel
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment