From 9b8728eaecb78774417275cc185dacd43310b25d Mon Sep 17 00:00:00 2001 From: P-A Loizeau <p.-a.loizeau@gsi.de> Date: Fri, 5 Jul 2024 13:03:36 +0200 Subject: [PATCH] [mCBM 2024] Cleanup outdated param repos info in combined reco script --- macro/beamtime/mcbm2024/reco_mcbm.sh | 65 +++++++++++----------------- 1 file changed, 25 insertions(+), 40 deletions(-) diff --git a/macro/beamtime/mcbm2024/reco_mcbm.sh b/macro/beamtime/mcbm2024/reco_mcbm.sh index 3c9aa11653..d10ea6902c 100755 --- a/macro/beamtime/mcbm2024/reco_mcbm.sh +++ b/macro/beamtime/mcbm2024/reco_mcbm.sh @@ -1,7 +1,7 @@ #!/bin/bash # Copyright (C) 2024 GSI Helmholtzzentrum fuer Schwerionenforschung, Darmstadt # SPDX-License-Identifier: GPL-3.0-only -# Authors: Sergei Zharko [committer] +# Authors: Sergei Zharko [committer], Pierre-Alain Loizeau # # @file reco_mcbm.sh # @brief Script to run the TSA file reconstruction in mCBM @@ -9,11 +9,11 @@ # @author Sergei Zharko <s.zharko@gsi.de> # # ********************************************************************************************************************** -# *** User Manual (v. 0.0.1, 19.06.2024) *** +# *** User Manual (v. 0.0.2, 05.07.2024) *** # ********************************************************************************************************************** -# +# # 1. Definitions -# <setup>: +# <setup>: # An official setup tag, e.g. "mcbm_beam_2024_05_08_nickel". # <label>: # A common part of name bases of the data-files, e.g. "3105_node8_05_0002" @@ -22,49 +22,34 @@ # A top "data" directory. # # 2. Introduction -# +# # This script aims to provide a generic data reconstruction scenario in mCBM, which includes: # - setup files generation: [--setup] # - TSA file unpacking [--unpack] # - reconstruction [--reco] -# - main QA [--qa] +# - main QA [--qa] # - reconstruciton QA (Alex) [--qa-module] -# +# # Required options: # --tsa <path> Path to the input TSA file # NOTE: must contain a run index as a first integer in its base name. # Auxiliary options: # -n [--nts] <N_TS> Number of timeslices to procede -# --setup, --unpack, --reco, --qa, --qa-module -# --param-online <path> Path to the online parameters -# NOTE: must be ${VMCWORKDIR}/parameters/online, but the current parameter repositories -# a diverged for the detector and online binary parameters. -# +# --setup, --unpack, --reco, --qa, --qa-module +# --param-online <path> Path to the online parameters +# NOTE: should be ${VMCWORKDIR}/parameters/online, but local user may have copy for testing +# # 3. File names involved: # <geo>: Input geometry file: <top_dir>/<setup>.geo.root -# <par>: Input parameter file: <top_dir>/<setup>.par.root --copy--> <top_dir>/<label>.par.root +# <par>: Input parameter file: <top_dir>/<setup>.par.root --copy--> <top_dir>/<label>.par.root # <tra>: Dummy transport file: <top_dir>/<setup>.tra.root # <digi>: Digitization output: <top_dir>/<label>.digi.root --ln--> <top_dir>/<label>.raw.root # <reco>: Reconstruction output: <top_dir>/<label>.reco.root --ln--> <top_dir>/<label>.rec.root -# <qa>: Main QA output: <top_dir>/<label>.qa.root +# <qa>: Main QA output: <top_dir>/<label>.qa.root # <qa-module>: Reconstruction module QA: <top_dir>/<label>.rqa.root # -# -# 4. Parameters situation (for 20.06.2024) -# The cbmroot_parameter repository is diverged: the valid online binary parameters are stored in the main CbmSoft/ -# cbmroot_parameter repository, and the detector parameters are stored on the mCBM fork of this repository. This -# will be changed with the merger request !1864 to the cbmroot master. For now one can checkout the main parameter -# repository with: -# cd /path/to/dir -# git clone https://git.cbm.gsi.de/CbmSoft/cbmroot_parameter.git -# cd cbmroot_parameter -# git remote add upstream https://git.cbm.gsi.de/CbmSoft/cbmroot_parameter.git -# git fetch --al -# Provide a path --param-online /path/to/dir/cbmroot_parameter/online -# -# To configure CbmRoot with correct mcbm parameters, one must provide a parameter -DCBM_MCBM_PARS=1 in the -# cmake configuration command. -# +# +# # # ********************* # ** USER PARAMETERS ** @@ -114,7 +99,7 @@ RUN=-1 TSA= N_TS=-1 while [[ $# > 0 ]]; do - case ${1} in + case ${1} in --setup ) CREATE_SETUP=1 ;; @@ -139,28 +124,28 @@ while [[ $# > 0 ]]; do -n | --nts ) N_TS=${2} ;; - esac + esac shift done # ----- Check the environment # -if [[ -z "${VMCWORKDIR}" ]]; then +if [[ -z "${VMCWORKDIR}" ]]; then printf "E- CBM environment is not defined (VMCWORKDIR is not found). Please, configure your CbmRoot\n" exit 1 -fi +fi # ----- Select the reconstruction binary ONLINE_BINARY="${VMCWORKDIR}/../../bin/cbmreco" -if [[ ! -x "${ONLINE_BINARY}" ]]; then +if [[ ! -x "${ONLINE_BINARY}" ]]; then ONLINE_BINARY=$(which cbmreco) - if [[ ! -x "${ONLINE_BINARY}" ]]; then + if [[ ! -x "${ONLINE_BINARY}" ]]; then printf "E- Online binary was not found. Please, install and configure your CbmRoot " printf "or provide the bin directory in the PATH environmental variable\n" exit 2 fi fi - + printf "I- Online binary path: %s, with parameters: %s\n" ${ONLINE_BINARY} ${ONLINE_PAR} # ----- Check the TSA input and retrieve the run index @@ -185,7 +170,7 @@ MACRO_QA="${VMCWORKDIR}/macro/mcbm/mcbm_qa.C" MACRO_QA_MODULE="${VMCWORKDIR}/macro/qa/run_recoQa.C" SETUP_NAME= -# ----- !!! Setting selections vs. +# ----- !!! Setting selections vs. if [[ ${RUN} -ge 2350 && ${RUN} -le 2397 ]]; then SETUP_NAME="mcbm_beam_2022_05_23_nickel" @@ -207,7 +192,7 @@ else exit 4 fi -# ----- +# ----- # File FILE_LABEL=$(printf $(basename ${TSA_INP}) | cut -f 1 -d '.') OUT_DIGI="${DATA_TOP_DIR}/${FILE_LABEL}.digi.out" @@ -254,7 +239,7 @@ if [[ ${DO_QA_MODULE} -eq 1 ]]; then fi # ----- Run QA -if [[ ${DO_QA} -eq 1 ]]; then +if [[ ${DO_QA} -eq 1 ]]; then USE_MC="kFALSE" CONFIG="" BENCHMARK="" -- GitLab