ANASEN_analysis/run_17F.sh
Sudarsan Balakrishnan f6f07a1b0c Another commit in between many breaking changes. Has Hammer+Tweezer approach for 27Al and 17F applied.
* Analyzing 17F approach will require the use of a #define in addition to globals. Not ideal but it is what it is.

* No new clever tricks other than beam eloss being treated to account for more effects.

* Urgent pending alignments:

	- geometry between sx3/qqq/pc to reflect vertexz in agreement with sourcez

	- better dynamic range correction for a1c2 wire handover points

	- need to resolve dE layer for different particle groups. No luck yet with just a *sinTheta

	- p+a dataset seems to be getting closer and closer to fully fleshed out

* Do not use this commit for future analyses. Pushed under sleep deprivation and fatigue.
2026-06-08 17:49:52 -04:00

38 lines
1.3 KiB
Bash

rm results_run*.root
export DATASET="17F"
export reactiondata=1
root -l -q -x -e ".L MakeVertex.C++g"
rm 17F_output/*.root
#17F reaction data
#declare -i run=231 #49
#while [[ $run -lt 258 ]]; do #392
# wrun=$(printf "%03d" $run)
# file_exists=$(test -f ../ANASEN_analysis/data/17F_Data/Run_"$wrun"_mapped.root)
# if [[ $file_exists -ne 0 ]]; then continue; fi
# root -q -l -b -x ../ANASEN_analysis/data/17F_Data/Run_"$wrun"_mapped.root -e 'tree->Process("MakeVertex.C+O")'; mv Analyzer_SX3.root results_run$wrun.root;
# run=run+1
#done
function run_once() {
wrun=$(printf "%03d" $1)
file_exists=$(test -f /home/sud/Desktop/Software2/ANASEN_analysis/data/17F_fsu_files/Run_"$wrun"_mapped.root)
if [[ $file_exists -ne 0 ]]; then return; fi
root -q -l -b -x /home/sud/Desktop/Software2/ANASEN_analysis/data/17F_fsu_files/Run_"$wrun"_mapped.root -e 'gInterpreter->ProcessLine("#define ADD_NEW_BRANCHES 1");' -e $(printf 'tree->Process("MakeVertex.C+","analyzed_run%s.root")' "$wrun");
mv analyzed_run$wrun.root results_run$wrun.root;
}
export -f run_once
#run_once 351
#parallel -j 6 --ctag run_once {1} ::: {350..400}
parallel -j 6 --ctag run_once {1} ::: {350..360}
rm output_17F.root
hadd -j 4 -k output_17F.root results_run3*.root
unset souce_vertex
unset DATASET
unset flip180
unset flipa
unset anode_offset
unset reactiondata