Skip to content

DUNE/sandreco

Repository files navigation

Installation

Currently, there are only two supported building and development environments:

FNAL machines

FNAL machines are Almalinux9 and the supported package manager is Spack. Documentation can be found here.

Installation

To build and install sandreco using spack, download the installation file and run it.

curl -O https://raw.githubusercontent.com/wiki/DUNE/sandreco/files/install-sandreco-with-spack.sh
source install-sandreco-with-spack.sh <spack installation folder>

When the script ends to run, you are ready to use sandreco.

Development

To develop sandreco, first install edepsim downloading the installation file and run it.

curl -O https://raw.githubusercontent.com/wiki/DUNE/sandreco/files/install-edepsim-with-spack.sh
source install-edepsim-with-spack.sh <spack installation folder>

Then, build edep-reader using the following commands:

cd <edepreader installation path>
git clone https://baltig.infn.it/vpia/edep-reader.git

in file <edep-reader installation folder>/edep-reader/CMakeList.txt: change set(CMAKE_CXX_STANDARD 14) into set(CMAKE_CXX_STANDARD 17), then use the following commands:

cd edep-reader
mkdir build
mkdir install
cd build
spack load [email protected]
spack load [email protected]
spack load [email protected]
spack load [email protected]
cmake -DCMAKE_INSTALL_PREFIX=./../install ./.. -DEDepSim_DIR=$(dirname $(find $(spack location -i [email protected]) -name "EDepSimConfig.cmake"))
make -j8 
make install
source ../install/setup.sh

Then, build sandreco using the following commands:

cd <sandreco installation path>
git clone https://github.com/DUNE/sandreco.git
mkdir build && cd build
spack load [email protected]
spack load [email protected]
spack load [email protected]
cmake ../sandreco/ -DCMAKE_INSTALL_PREFIX=.. \
-DCMAKE_INSTALL_RPATH="$(spack find --paths [email protected] | grep "[email protected]" | awk -F' ' '{print $2}')/lib:$(spack find --paths [email protected] | grep "[email protected]" | awk -F' ' '{print $2}')/lib/root:${PWD}/../lib"
make -j8
make install

CNAF machine

On the CNAF machine run, CMake is used to build sandreco.

Currently, sandreco depends on the EDEPReader library. Thus, it is necessary to install and source it before installing sandreco. To install EDEPReader, use the following commands:

mkdir <EDEPReader installation path>
cd <EDEPReader installation path>
git clone https://baltig.infn.it/dune/edep-reader
mkdir install
mkdir build && cd build
source /opt/exp_software/neutrino/al9/env.sh
cmake -DCMAKE_INSTALL_PREFIX=../install
make -j8
make install
source ../install/setup.sh

If everything went well, you can now install sandreco using the following commands:

mkdir <sandreco installation path>
cd <sandreco installation path>
git clone https://github.com/DUNE/sandreco.git
mkdir build && cd build
source /opt/exp_software/neutrino/al9/env.sh
cmake ../sandreco/ -DCMAKE_INSTALL_PREFIX=..
make -j8
make install
source ../setup.sh

Installation with ups [DEPRECATED]

$ VERSION="v01_00_00"
$ QUAL="e20:prof"
$ source /cvmfs/dune.opensciencegrid.org/products/dune/setup_dune.sh
$ mrb newDev -v $VERSION -q $QUAL
$ source localProducts_larsoft_*/setup
$ mrb g sandreco
$ cd $MRB_BUILDDIR
$ mrbsetenv
$ mrb b -j8
$ mrb i

for a specific tag or branch do mrb g -t $TAG sandreco or mrb g -b $BRANCH sandreco

sandreco

The sandreco project provides six executables:

  • Digitize will perform digitization,
  • SANDECALClustering will clusterize the ECAL DAQ digit in clusters of reconstructed cells,
  • Reconstruct will reconstruct tracks in STT and clusters in ECAL
  • Analyze will identify particles and assign them a momentum
  • FastCheck will produce a lot of plots to check everything is ok
  • Display displays events

The executables exploit two libraries:

  • libUtils.so for utilities
  • libStruct.so for i/o

Run

Digitize

  • Create digits of STT and cells of calorimeter
$ Digitize <MC file> <digit file>

SANDECALClustering

  • Create clusters of ECAL reconstructed cells (output <cluster file> is not an input argument)
$ SANDECALClustering -d <digit file>

Description

SANDECALClustering takes as input the digitized photodetector signals in <digit file> and produces clusters of reconstructed cells in the ECAL. The output <cluster file> has the following structure:

TTree tCluster

cluster
cluster.tid
cluster.x (y, z) 
cluster.t
cluster.e
cluster.ax (ay, az) #apex
cluster.sx (sy, sz) #direction
cluster.varx (vay, varz) #variance
cluster.reco_cells 

Each reco_cell object has the following structure:

int id;
double z;
double y;
double x;
double l;
int mod;
int lay;
double e;
double t; 
dg_ps ps1; #photodetector 1 digitized photo-signal
dg_ps ps2; #photodetector 2 digitized photo-signal

Reconstruct

  • Track find and fit of STT track
  • Clustering of calorimeter cells
$ Reconstruct <MC file> <digiti file> <reco file>

Analyze

  • Evaluate parameters of particles
  • Evaluate neutrino energy
$ Analyze <MC file> <reco file>

FastCheck

  • Produce several plots to check everything is ok
$ FastCheck <root file> <pdf file>

Display

  • Display an event
$ Display <event number> <MC file> <input file> [show trajectories] [show fits] [show digits]

Data format

The description of the data format can be found here

Contribute

Support

For any communication, please refer to [email protected]

BUILD AND TEST SANDRECO

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

No packages published

Contributors 12

Languages