Belle II Software
release-08-01-10
|
ARICH database importer. More...
#include <ARICHDatabaseImporter.h>
Public Member Functions | |
ARICHDatabaseImporter () | |
Default constructor. | |
ARICHDatabaseImporter (const std::vector< std::string > &inputFilesHapdQA, const std::vector< std::string > &inputFilesAsicRoot, const std::vector< std::string > &inputFilesAsicTxt, const std::vector< std::string > &inputFilesHapdQE, const std::vector< std::string > &inputFilesFebTest) | |
Constructor. | |
ARICHDatabaseImporter (int experiment, int run) | |
virtual | ~ARICHDatabaseImporter () |
Destructor. | |
void | SetIOV (int experimentLow, int runLow, int experimentHigh, int runHigh) |
void | setExperimentAndRun (int experiment, int run) |
void | importSimulationParams () |
Import simulation parameters from the xml file (QE curve, etc.) | |
void | importReconstructionParams () |
Import reconstruction parameters (for now only initializes "default" values and imports) | |
void | printSimulationPar () |
Print simulation parameters from the database (QE curve, etc.) | |
void | importModulesInfo () |
Import HAPD modules info from the xml file and database (2D QE maps) Goes through the list of installed modules in ARICH-InstalledModules.xml, finds corresponding 2D QE maps in the database and imports lightweight ARICHModulesInfo class (which is used in sim/rec) into database. | |
void | printModulesInfo () |
Print HAPD modules info from the database (lightweight class for sim/rec=) | |
void | setHAPDQE (unsigned modID, double qe=0.27, bool import=false) |
Example function for importing HAPD QE to database class (ARICHModulesInfo) | |
void | importGlobalAlignment () |
Import global alignment parameters from ARICH-GlobalAlignment.xml. | |
void | importMirrorAlignment () |
Import mirror alignment parameters from ARICH-MirrorAlignment.xml. | |
void | importAeroTilesAlignment () |
Import aerogel tiles alignment parameters from ARICH-AeroTilesAlignment.xml. | |
void | importMergerCoolingGeo () |
Import Merger cooling bodies geometry. | |
tessellatedSolidStr | readTessellatedSolidVerticesFromDATfile (const std::string &inDATfile) |
reads merger cooling bodies geometry from dat files | |
void | importChannelMask () |
Import channel mask for all HAPD modules from the database (list of dead channels) Goes through the list of installed modules in ARICH-InstalledModules.xml, finds corresponding lists of dead channels in the database and imports lightweight ARICHChannelMask class (which is used in sim/rec) into database. | |
void | importChannelMask (TH1 *h) |
Import channel mask from the calibration histogram ( list of dead and hot channels ) to ARICHChannelMask class into database. More... | |
void | printChannelMask (bool makeHist=false) |
Print channel mask of all HAPD modules from the database (lightweight class for sim/rec) | |
void | importChannelMapping () |
Imports HAPD (asic) channel mappings from the xml file. | |
void | printChannelMapping () |
Prints HAPD (asic) channel mapping from the database. | |
void | importFEMappings () |
Imports mappings of FE electronics from the xml file (ARICH-FrontEndMapping.xml) to the database Mapping of modules to mergers and mergers to coppers. | |
void | printMergerMapping () |
Prints merger to FEB mappings from the database. | |
void | printCopperMapping () |
Prints Copper to merger mappings from the database. | |
void | printReconstructionPar () |
Prints reconstruction parameters. | |
void | printGeometryConfig () |
Prints geometry configuration parameters from the database. | |
void | dumpQEMap (bool simple=false) |
Dumps 2D QE map of full detector surface from the database into root file (from ARICHModulesInfo) More... | |
void | dumpHvMappings () |
Dumps detector map of HAPD modules to HV cable channels. | |
void | printFEMappings () |
Prints electronics mappings for all modules (merger ID + SN, merger port, copper, finnese) | |
void | dumpMergerMapping (bool sn=true) |
Dumps module - merger mapping into root file. | |
void | dumpModuleNumbering () |
Dumps module numbering scheme into root file (module position on the detector plane -> module number) | |
void | dumpAerogelOpticalProperties (std::string outRootFileName="ARICH_AerogelOpticalProperties.root") |
Dumps aerogel tile properties (aerogel optical properties - AOP) into root file with arich/utility/ARICHAerogelHist histos. More... | |
void | importCosmicTestGeometry () |
Import parameters of the cosmic test geometry configuration. | |
void | importGeometryConfig () |
Import geometry configuration parameters to the database. | |
void | importAeroTilesInfo () |
Import optical information of aerogel tiles into database. | |
void | importAeroRayleighScatteringFit (std::string commentSingleWord="") |
Import optical information of aerogel tiles into database. | |
int | getAeroTileRing (int slot) |
Get aerogel ring number from global indetifier. | |
int | getAeroTileColumn (int slot) |
Get aerogel ring number from global indetifier. | |
void | printAeroTileInfo () |
Prints mapping of aerogel tiles and their optical properties. | |
void | printGlobalAlignment () |
Prints global alignment constants. | |
void | printMirrorAlignment () |
Prints mirror alignment constants. | |
void | printAeroTilesAlignment () |
Prints aerogel tiles alignment constants. | |
void | importBiasMappings () |
Imports mappings of power supply to bias cables and cables to HAPDs and nominal values of bias voltages. | |
void | importHvMappings () |
Imports mappings of power supply to high voltage cables. | |
void | importNominalBiasVoltages () |
Imports mappings of nominal values of bias voltages. | |
void | printBiasMappings () |
Prints mappings of power supply to bias cables and cables to HAPDs and nominal values of bias voltages from the database. | |
void | printHvMappings () |
Prints mappings of power supply to HV cables and cables to HAPDs from the database. | |
void | printNominalBiasVoltages () |
Prints mappings of nominal values of bias voltages from the database. | |
void | printNominalBiasVoltageForChannel (std::vector< int > channel) |
Prints nominal bias voltage for channel on power supply from the database. More... | |
void | printHapdPositionFromCrateSlot (int crate, int slot, int channelID) |
Prints HAPD position (sector, ring, azimuth) and merger connection (merger, feb slot) from the database. More... | |
int | getFebDaqSlot (unsigned febSlot) |
Returns feb daq position from feb slot. More... | |
void | importAerogelInfo (TString coreNameSuffix="") |
Import ARICH aerogel data in the database. | |
void | exportAerogelInfo (int verboseLevel=0) |
Export ARICH aerogel data from the database. | |
void | importAerogelMap () |
Import ARICH aerogel map in the database. | |
void | exportAerogelMap () |
Export ARICH aerogel map in the database. | |
void | importAerogelInfoEventDep () |
Import intrarun dependant ARICH aerogel data in the database. More... | |
void | exportAerogelInfoEventDep () |
Export intrarun dependant ARICH aerogel data from the database. More... | |
void | importHapdQA () |
Import ARICH HAPD QA data in the database. | |
void | exportHapdQA () |
Export ARICH HAPD QA data from the database. | |
void | importAsicInfo () |
Import ARICH ASICs data in the database. | |
void | importAsicInfoRoot () |
Import large histograms from ARICH ASICs data in the database. | |
void | exportAsicInfo () |
Export ARICH ASICs data from the database. | |
TTimeStamp | timedate (std::string enddate) |
Convert date (ASICs) to TTimeStamp. More... | |
TTimeStamp | getAsicDate (const std::string &asicSerial, const std::string &type) |
Get date for ASIC measurement. More... | |
std::vector< int > | channelsList (std::string badCH) |
Get lists of problematic ASIC channels. | |
void | importFebTest () |
Import ARICH FEB test data in the database. | |
void | importFebTestRoot () |
Import large histograms from ARICH FEB test data in the database. | |
std::tuple< std::string, float, float, float > | getFebLVtestData (int serial, int lvRun) |
Returns data from low voltage test. | |
std::tuple< std::string, float > | getFebHVtestData (int serial, int hvRun) |
Returns data from high voltage test. | |
std::vector< int > | getDeadChFEB (const std::string &dna) |
Returns list of dead channels on FEB. | |
TTimeStamp | timedate2 (std::string time) |
Convert date (FEB) to TTimeStamp. More... | |
std::pair< std::vector< float >, std::vector< float > > | getSlopes (int serialNum, const std::string &runSCAN) |
Returns lists of slopes (fine & rough) | |
std::vector< std::pair< float, float > > | getFwhm (int serialNum, const std::string &runSCAN) |
Returns lists of FWHM values&sigmas. | |
std::vector< TH3F * > | getFebTestHistograms (const std::string &dna, const std::string &run, int febposition) |
Returns TH3F histograms - offset settings. | |
TH2F * | getFebTestPulse (const std::string &dna, const std::string &run, int febposition) |
Returns TH2F histogram of pulse test. | |
void | exportFebTest () |
Export ARICH FEB test data from the database. | |
void | importHapdChipInfo () |
Import ARICH HAPD chip data in the database. | |
void | exportHapdChipInfo () |
Export ARICH HAPD chip data from the database. | |
void | importHapdInfo () |
Import ARICH HAPD data in the database. | |
std::vector< int > | channelsListHapd (std::string chlist, std::string chipDelay) |
Get lists of problematic HAPD channels. | |
int | getChannelPosition (const std::string &XY, const std::string &chip_2d, int chipnum) |
Get position of channel on HAPD. More... | |
TGraph * | getGraphGainCurrent (const std::string &bomb_aval, const std::string &g_i, const std::string &chip_label, int i, float *HV, float *gain_current) |
Get graphs for bombardment and avalanche gain and current. More... | |
TH2F * | getBiasGraph (const std::string &chip_2d, const std::string &voltage_current, int *chipnum, float *bias_v_i) |
Get histograms for bias voltage and current. More... | |
void | exportHapdInfo () |
Export ARICH HAPD info and chip info data from the database. | |
void | importHapdQE () |
Import HAPD quantum efficiency in the database. | |
void | exportHapdQE () |
Export HAPD quantum efficiency from the database. | |
void | printBiasVoltagesForHapdChip (const std::string &serialNumber) |
Export ARICH HAPD chip info data from the database and calculate bias voltages for one HAPD. More... | |
void | printMyParams (const std::string &aeroSerialNumber) |
Example that shows how to use data from the database. More... | |
std::map< std::string, float > | getAerogelParams (const std::string &aeroSerialNumber) |
Function that returns refractive index, thickness and transmission length of aerogel. More... | |
void | importFEBoardInfo () |
Import module test results. | |
void | exportFEBoardInfo () |
Export module test results. | |
void | importModuleTest (const std::string &mypath, const std::string &HVtest) |
Import module test results. | |
void | exportModuleTest (const std::string &HVtest) |
Export module test results. | |
void | importSensorModuleInfo () |
Import module sensor info classes. | |
void | importSensorModuleMap () |
Import module sensor map classes. | |
void | exportSensorModuleMap () |
Export module sensor map and info classes from database. | |
void | exportSensorModuleMapInfo (int number) |
void | importMagnetTest () |
Import results of magnet test. | |
void | exportMagnetTest () |
Export results of magnet test. | |
void | exportAll () |
Export all the data. | |
Private Member Functions | |
template<typename Container_t > | |
auto | printContainer (const Container_t &rContainer, std::ostream &rStream=std::cout) noexcept -> void |
printContainer used for debugging purposes... More... | |
Private Attributes | |
std::vector< std::string > | m_inputFilesHapdQA |
Input root files for HAPD QA. | |
std::vector< std::string > | m_inputFilesAsicRoot |
Input root files for ASICs. | |
std::vector< std::string > | m_inputFilesAsicTxt |
Input txt files for ASICs. | |
std::vector< std::string > | m_inputFilesHapdQE |
Input root files for HAPD quantum efficiency. | |
std::vector< std::string > | m_inputFilesFebTest |
Input root files from FEB test (coarse/fine offset settings, test pulse) | |
IntervalOfValidity | m_iov |
ARICH database importer.
This module writes data to database.
Definition at line 34 of file ARICHDatabaseImporter.h.
void dumpAerogelOpticalProperties | ( | std::string | outRootFileName = "ARICH_AerogelOpticalProperties.root" | ) |
Dumps aerogel tile properties (aerogel optical properties - AOP) into root file with arich/utility/ARICHAerogelHist histos.
string | with output name |
Definition at line 1166 of file ARICHDatabaseImporter.cc.
void dumpQEMap | ( | bool | simple = false | ) |
Dumps 2D QE map of full detector surface from the database into root file (from ARICHModulesInfo)
simple | false for proper histogram with bin for each channel, true for simpler plot with point for each channel (smaller file, faster) for simple option, draw TGraph2D with "pcolz" option and set view to "top" |
Definition at line 1133 of file ARICHDatabaseImporter.cc.
void exportAerogelInfoEventDep | ( | ) |
Export intrarun dependant ARICH aerogel data from the database.
-> Example for intrarun dependat data!
Definition at line 1498 of file ARICHDatabaseImporter.cc.
std::map< std::string, float > getAerogelParams | ( | const std::string & | aeroSerialNumber | ) |
Function that returns refractive index, thickness and transmission length of aerogel.
aerogel | serial number |
Definition at line 2741 of file ARICHDatabaseImporter.cc.
TTimeStamp getAsicDate | ( | const std::string & | asicSerial, |
const std::string & | type | ||
) |
Get date for ASIC measurement.
asicSerial | - serial number of asic |
type | - gain or offset |
Definition at line 1748 of file ARICHDatabaseImporter.cc.
TH2F * getBiasGraph | ( | const std::string & | chip_2d, |
const std::string & | voltage_current, | ||
int * | chipnum, | ||
float * | bias_v_i | ||
) |
Get histograms for bias voltage and current.
chip_2d | - chip label |
voltage_current | - voltage or current |
chipnum | - channel number |
bias_v_i | - bias voltage/current |
Definition at line 2581 of file ARICHDatabaseImporter.cc.
int getChannelPosition | ( | const std::string & | XY, |
const std::string & | chip_2d, | ||
int | chipnum | ||
) |
Get position of channel on HAPD.
XY | - choose X/Y coordinate |
chip_2d | - chip label |
chipnum | - channel number |
Definition at line 2542 of file ARICHDatabaseImporter.cc.
int getFebDaqSlot | ( | unsigned | febSlot | ) |
Returns feb daq position from feb slot.
febSlot | feb slot number on merger |
Definition at line 994 of file ARICHDatabaseImporter.cc.
TGraph * getGraphGainCurrent | ( | const std::string & | bomb_aval, |
const std::string & | g_i, | ||
const std::string & | chip_label, | ||
int | i, | ||
float * | HV, | ||
float * | gain_current | ||
) |
Get graphs for bombardment and avalanche gain and current.
bomb_val | - bombardment or avalanche |
g_i | - gain or current |
chip_label | - chip label |
i | - number of entries |
HV | - voltage |
gain_current | - gain/current |
Definition at line 2529 of file ARICHDatabaseImporter.cc.
void importAerogelInfoEventDep | ( | ) |
Import intrarun dependant ARICH aerogel data in the database.
-> Example for intrarun dependat data!
Definition at line 1436 of file ARICHDatabaseImporter.cc.
void importChannelMask | ( | TH1 * | h | ) |
Import channel mask from the calibration histogram ( list of dead and hot channels ) to ARICHChannelMask class into database.
h | TH1F root histogram with 420*144 bins |
Definition at line 421 of file ARICHDatabaseImporter.cc.
void printBiasVoltagesForHapdChip | ( | const std::string & | serialNumber | ) |
Export ARICH HAPD chip info data from the database and calculate bias voltages for one HAPD.
HAPD | serial number |
Definition at line 2685 of file ARICHDatabaseImporter.cc.
|
inlineprivatenoexcept |
printContainer used for debugging purposes...
rContainer | |
rStream |
Definition at line 601 of file ARICHDatabaseImporter.h.
void printHapdPositionFromCrateSlot | ( | int | crate, |
int | slot, | ||
int | channelID | ||
) |
Prints HAPD position (sector, ring, azimuth) and merger connection (merger, feb slot) from the database.
crate | crate on power supply |
slot | slot on power supply |
channelID | channel number on power supply |
Definition at line 959 of file ARICHDatabaseImporter.cc.
void printMyParams | ( | const std::string & | aeroSerialNumber | ) |
Example that shows how to use data from the database.
aerogel | serial number |
Definition at line 2732 of file ARICHDatabaseImporter.cc.
void printNominalBiasVoltageForChannel | ( | std::vector< int > | channel | ) |
Prints nominal bias voltage for channel on power supply from the database.
channel | vector of values crate, slot and channel on power supply |
Definition at line 921 of file ARICHDatabaseImporter.cc.
TTimeStamp timedate | ( | std::string | enddate | ) |
Convert date (ASICs) to TTimeStamp.
enddate | - time as string |
Definition at line 1777 of file ARICHDatabaseImporter.cc.
TTimeStamp timedate2 | ( | std::string | time | ) |
Convert date (FEB) to TTimeStamp.
time | - time as string |
Definition at line 2094 of file ARICHDatabaseImporter.cc.