Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
HADES-Cracovia
software
feb22_geant
Commits
86952760
Commit
86952760
authored
Aug 13, 2022
by
Rafał Lalik
Browse files
Add out subdir to input list
parent
6f472aa7
Changes
1
Hide whitespace changes
Inline
Side-by-side
job_script.sh
View file @
86952760
...
...
@@ -9,24 +9,29 @@ echo " odir=$odir"
if
[[
-n
${
SLURM_ARRAY_TASK_ID
}
]]
;
then
echo
"ARRAY:
${
SLURM_ARRAY_TASK_ID
}
in
${
pattern
}
"
file
=
$(
sed
-n
$((${
SLURM_ARRAY_TASK_ID
}
+
1
))
p
${
pattern
}
)
line
=
$(
sed
-n
$((${
SLURM_ARRAY_TASK_ID
}
+
1
))
p
${
pattern
}
)
IFS
=
' '
read
-ra
linearr
<<<
"
$line
"
file
=
${
linearr
[0]
}
sodir
=
${
linearr
[1]
}
else
echo
"NO ARRAY"
file
=
$pattern
fi
.
/lustre/hades/user/rlalik/hades/
profile
_feb22
.sh
[
-e
job_profile.sh
]
&&
.
job_
profile.sh
cd
/lustre/hades/user/rlalik/hades/feb22/sim/geant
odir
=
$(
readlink
-e
$odir
)
mkdir
$odir
mkdir
-p
$odir
/
$sodir
odir
=
$(
readlink
-e
$odir
/
$sodir
)
#file=$(readlink -e $file)
echo
file
=
$file
echo
events
=
$events
echo
odir
=
$odir
crashfile
=
$odir
/crash_await_
${
SLURM_ARRAY_JOB_ID
}
_
${
SLURM_ARRAY_TASK_ID
}
.txt
echo
$file
>
$crashfile
root
-b
-q
card_file_base
=
simul_p4500p_fwdet_feb22
...
...
@@ -37,11 +42,18 @@ date
truncate
-s0
${
odir
}
/
$(
basename
${
file
}
.evt
)
_1.root
# update placeholders and generate temporary file
echo
"*********************************************"
echo
"*********************************************"
sed
\
-e
"s|@wd@|
$(
pwd
)
|g"
\
-e
"s|@input@|
${
file
}
|"
\
-e
"s|@output@|
$(
basename
${
file
}
.evt
)
_.root|"
\
${
card_file_base
}
.dat
>
${
card_file
}
${
card_file_base
}
.dat |
tee
${
card_file
}
echo
"*********************************************"
echo
"*********************************************"
if
[
-z
${
SLURM_TMPDIR
+x
}
]
;
then
echo
"SLURM_TMPDIR is unset"
...
...
@@ -64,12 +76,7 @@ fi
mv
$(
basename
${
file
}
.evt
)
_
*
.root
${
odir
}
/
-v
echo
"*********************************************"
cat
${
card_file
}
echo
"*********************************************"
cat
${
card_file
}
cd
-
rm
-rfv
${
tmpdirname
}
rm
-fv
${
card_file
}
rm
-v
$crashfile
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment