#include <EmcIndexer.h>
Inherited by PbGlIndexer, and PbScIndexer.
Inheritance diagram for EmcIndexer:
Primary source of conversion to/from various types of emcal indices, within various "frames" (whole emcal, one sector, one supermodule).
If you were to pick up only one index, please use TowerID (ranging from 0 to 24767), as it is the less ambiguous and the most compact (only one integer).
Definition at line 19 of file EmcIndexer.h.
Public Member Functions | |
EmcIndexer () | |
virtual | ~EmcIndexer () |
Methods specific to sub-system (PbSc/PbGl). | |
To be overriden in subclasses. | |
virtual void | iST_SMInd (const int, int &, int &, int &, int &)=0 |
i(SectorTower) -> SM#, iSM144, iSM144T, x(SM144T), y(SM144T). | |
virtual void | iSTxyST (const int, int &, int &)=0 |
Converts i(SectorTower) -> x(SectorTower), y(SectorTower). | |
virtual int | SMiSMTiST (int, int)=0 |
SM, i(SM Tower) -> i(SectorTower). | |
virtual void | SMxySM (int, int &, int &)=0 |
SM# -> xSM, ySM. | |
virtual int | xySMiSM (int x, int y)=0 |
xSM,ySM -> SM# (reverse operation of SMxySM). | |
virtual int | SMxySMTiST (int, int, int)=0 |
SM#, x(SM Tower), y(SM Tower) -> i(SectorTower). | |
virtual int | xySMTiSMT (int, int)=0 |
x(SM Tower), y(SM Tower) -> i(SM Tower). | |
Static Public Member Functions | |
(Static) Methods common for PbSc and PbGl. | |
static bool | IsValid (int iS, int x, int y) |
Checks validity of the Sector, x, y combination. | |
static int | iSiSTiPX (int iS, int iST) |
Converts PHENIX (on-line) Sector number and Sector Tower Number into PHENIX TowerId. | |
static void | iPXiSiST (int TowerId, int &iS, int &iST) |
PHENIX tower(TowerId) -> SectorNumber, SectorTower. | |
static void | iPXiSiSMiSMT (int TowerId, int &iS, int &iSM, int &iSMT) |
PHENIX tower(TowerId) -> SectorNumber, SuperModule, Supermodule tower. | |
static void | iSTxyST (int iS, int iST, int &x, int &y) |
Converts i(SectorTower) -> x(SectorTower), y(SectorTower). | |
static int | xySTiST (int iS, int x, int y) |
Sector, x(SectorTower), y(SectorTower) -> i(SectorTower). | |
static int | getTowerId (int iS, int x, int y) |
Gets TowerId for the Tower x/y in Sector iS(online). | |
static void | decodeTowerId (int TowerId, int &iS, int &x, int &y) |
Decodes TowerId into Sector Nmber iS (online) and x/y inside the Sector. | |
static void | TowerLocation (int towerID, int &arm, int §or_in_arm, int &yrow, int &zrow) |
Get (arm,sector_in_arm,yrow,zrow) from a TowerID (offline used). | |
static void | decodeSoftwareKey (int software, int &arm, int §or_in_arm, int &yrow, int &zrow) |
Decode software key. | |
static int | TowerID (int arm, int sector_in_arm, int yrow, int zrow) |
Get TowerID from (arm,sector_in_arm,yrow,zrow (offline used). | |
static int | TowerID (int softwareKey) |
static int | SoftwareKey (int TowerId) |
Get (offline) softwareKey from TowerID. | |
static int | SoftwareKey (int arm, int sector_in_arm, int yrow, int zrow) |
static bool | isPbScReference (int TowerId) |
Tells if an absolute tower id is a PbSc reference. | |
static bool | isPbGlReference (int TowerId) |
Tells if an absolute tower id is a PbGl reference. | |
static bool | isReference (int TowerId) |
Tells if an absolute tower id is a reference tower. | |
static bool | isReferenceFEM (int femAbsolutePosition) |
Tells if a fem holds reference signals. | |
static bool | isPbSc (int TowerId) |
Tells if an absolute tower id is PbSc. | |
static bool | isPbScFEM (int absFEM) |
Tells if an absolute FEM id is PbSc. | |
static bool | isPbGl (int TowerId) |
Tells if an absolute tower id is PbGl. | |
static bool | isPbGlFEM (int absFEM) |
Tells if an absolute FEM id is PbGl. | |
static void | iSiSTiSMiSMT (const int iS, const int iST, int &iSM, int &iSMT) |
SectorNumber, SectorTower -> SM144 NUmber (Sector scope), SM144 Tower. | |
static int | iSiSM144_PXSM144 (int iS, int iSM144) |
Sector, SM144 Number(Sector Scope) -> PHENIX SM144 (0-171). | |
static int | iSMTiCH (const int iSMT) |
i(SM144 Tower) -> FEM Channel Converts Tower Number (scope of SM144) into FEM Channel number. | |
static int | iSiSMiSMTiPX (int iS, int iSM, int iSMT) |
static int | iSMTiCH (const int iSMT, const bool fl) |
i(SM Tower), ASIC Readout Flag -> FEM Channel. | |
static void | iSM144TxySM144T (const int iSMT, int &xsmt, int &ysmt) |
i(SM144 Tower) -> x(SM144 Tower), y(SM144 Tower) | |
static int | iSiSMiSMTiST (int iS, int iSM, int SMT) |
static void | PXSM144_iSiSM144 (int PXSM144, int &iS, int &iSM144) |
PHENIX SM144 (0-171) -> Sector, SM NUmber(Sector SM). | |
static void | PXPXSM144CH (int PX, int &PXSM144, int &CH) |
From TowerId (PHENIX scope) to FEM number (PHENIX scope) and FEM channel number. | |
static int | PXSM144iCH_iPX (const int SM144, const int CH) |
SM144 (EMC Scope), FEM Channel -> PHENIX EMC Tower. | |
static int | iCHiSMT (int ch) |
FEM Channel -> i(SM144 Tower). | |
static int | iCHiSMT (const int, bool ASIC24) |
FEM Channel -> i(SM144 Tower). | |
static int | MaxNumberOfFEMs (void) |
Max. number of FEMs in EMCAL. | |
static int | FirstReferenceFEMAbsolutePosition (void) |
The absolute id of the first reference FEM. | |
static int | EmcSectorNumber (const char *sectorName) |
Sector identifier -> Sector Number. | |
static const char * | EmcSectorId (int sectorNumber) |
Sector number -> Sector Identifier. | |
static int | sectorOfflineToOnline (int arm, int offline_sector) |
Arm,Sector (offline convention) -> sectorNumber (online). | |
static void | sectorOnlineToOffline (int sectorOnline, int &arm, int &offline_sector) |
sectorNumber(online) -> Arm,Sector (offline convention); | |
(Static) methods again, but probably for experts only. | |
static int | absFEMCHiPX (const int absFEMCH) |
"Absolute" Channel number to TowerNumber (PHENIX scope). | |
static int | iPXabsFEMCH (const int iPX) |
TowerNumber (PHENIX scope) to "Absolute" Channel number. | |
static void | iCH192ASICi32 (const int iCH192, int &ASIC, int &iCH32) |
Conversion from absolute FEM Channel number (0-191) into ASIC number and ASIC Channel number (0-31). | |
static void | iSM144TtoHWIndexes (int iSMT, bool ASIC24, int &QB, int &Cell, int &ASIC, int &Preamp, int &Input, int &FEMChannel) |
i(SM144 Tower), ASIC24 -> Q-base, Cell, ASIC, Preamp, Input, FEM Channel. | |
static void | findItemIdentity (const int ItemId, const bool ASIC24, const bool EMCalMapStyle, int &iS, int &iSM, int &iSMT, int &iFEM, int &iCH192, int &ASIC, int &ASICCh) |
Converts FEM Channel number or EMC Tower number into all other possible indices. | |
Static Private Attributes | |
static std::vector< std::string > | fEmcSectorIdent |
|
Definition at line 23 of file EmcIndexer.h. |
|
Definition at line 24 of file EmcIndexer.h. |
|
"Absolute" Channel number to TowerNumber (PHENIX scope). On request from Sergei Belikov: Conversion from Channel number defined as "absolute" or equal to 192 X SM144 number (incrementing over all eight sectors 0-171) + FEMChannel (0-191) to TowerNumber (PHENIX scope) -1 is returned for formally disconnected FEM channels (12-16 and 28-31 on every ASIC board) Definition at line 321 of file EmcIndexer.C. References FEM, iCHiSMT(), and iSiSMiSMTiPX(). |
|
Decode software key.
Definition at line 661 of file EmcIndexer.C. Referenced by TowerID(). |
|
Decodes TowerId into Sector Nmber iS (online) and x/y inside the Sector.
Definition at line 496 of file EmcIndexer.C. References iPXiSiST(), and iSTxyST(). Referenced by mEmcCalibratorModulev2::changeToF(), getIy(), getIz(), histogram(), emcBadNormt::process(), and emcOMRejectList::Write(). |
|
Sector number -> Sector Identifier.
Definition at line 60 of file EmcIndexer.C. References EmcSectorNumber(), and fEmcSectorIdent. Referenced by buildBasename(), convertNormalization(), emcBadNormt::emcBadNormt(), emcFEMList::emcFEMList(), emcGainBaseLineCalculator::getBaseLine(), EmcSimuRawDataReCal::GetGainFactorFromDB(), Sector::histos(), emcCalibrationDataHelper::initECalAtT0(), makeHistoMap(), namer(), emcOMCalibrationDataTofSectorOffset::Read(), reader(), emcOMCalibrationDataIniCal::Write(), and emcQAs::WriteDataToFile(). |
|
Sector identifier -> Sector Number.
Definition at line 30 of file EmcIndexer.C. References fEmcSectorIdent. Referenced by EmcStaticData::buildEmcSector(), EmcSectorId(), emcFEMList::fems(), and emcGainEvolution::run(). |
|
Converts FEM Channel number or EMC Tower number into all other possible indices.
Definition at line 399 of file EmcIndexer.C. References iCH192ASICi32(), iCHiSMT(), iPXiSiST(), iSiSTiSMiSMT(), iSMTiCH(), and PXSM144_iSiSM144(). |
|
The absolute id of the first reference FEM. i.e. if (absPosition>=FirstReferenceFEMAbsolutePosition) then absPosition is a reference FEM. Definition at line 193 of file EmcIndexer.h. Referenced by isReferenceFEM(). |
|
Gets TowerId for the Tower x/y in Sector iS(online).
Definition at line 490 of file EmcIndexer.C. Referenced by mEmcToolsModule::AssignRealDeadMaptoSimulTowers(), EmcSimuRawDataReCal::getTowerID(), and emcOMRejectList::Read(). |
|
Conversion from absolute FEM Channel number (0-191) into ASIC number and ASIC Channel number (0-31).
Definition at line 356 of file EmcIndexer.C. Referenced by findItemIdentity(). |
|
FEM Channel -> i(SM144 Tower). Converts FEM Channel into Tower Number (scope of SM144). Definition at line 275 of file EmcIndexer.C. |
|
FEM Channel -> i(SM144 Tower). Converts FEM Channel into Tower Number (scope of SM144). Assumes ASIC24=true and Channel Numbers from 0 to 143). Definition at line 257 of file EmcIndexer.C. Referenced by absFEMCHiPX(), PbScSector::CorrectEnergyCalibration(), findItemIdentity(), and PXSM144iCH_iPX(). |
|
TowerNumber (PHENIX scope) to "Absolute" Channel number. On request from Sergei Belikov: Conversion from TowerNumber (PHENIX scope) into Channel number defined as "absolute" or equal to 192 X SM144 number (incrementing over all eight sectors 0-171) + FEMChannel (0-191) Definition at line 340 of file EmcIndexer.C. References iPXiSiST(), iSiSTiSMiSMT(), and iSMTiCH(). |
|
PHENIX tower(TowerId) -> SectorNumber, SuperModule, Supermodule tower.
Definition at line 456 of file EmcIndexer.C. Referenced by emcRawDataCalibratorV1::CalibrateTime(). |
|
PHENIX tower(TowerId) -> SectorNumber, SectorTower.
Definition at line 442 of file EmcIndexer.C. Referenced by decodeTowerId(), findItemIdentity(), emcDataObject::GenerateSoftwareKey(), emcCalibratedDataObject::GenerateSoftwareKey(), emcCalibratedDataObject::GetSMEnergies(), emcCalibrationDataHelper::initECalAtT0(), iPXabsFEMCH(), PXPXSM144CH(), SoftwareKey(), and TowerLocation(). |
|
Sector, SM144 Number(Sector Scope) -> PHENIX SM144 (0-171).
Definition at line 158 of file EmcIndexer.C. Referenced by convertSector(), emcFEMList::fems(), emcCalibratedDataObject::GetSMEnergies(), and PXPXSM144CH(). |
|
Definition at line 186 of file EmcIndexer.C. References PbGlIndexer::buildPbGlIndexer(), PbScIndexer::buildPbScIndexer(), gPbGl, PbGlIndexer::SMiSMTiST(), and PbScIndexer::SMiSMTiST(). Referenced by absFEMCHiPX(), and PXSM144iCH_iPX(). |
|
Definition at line 171 of file EmcIndexer.C. References PbGlIndexer::buildPbGlIndexer(), PbScIndexer::buildPbScIndexer(), gPbGl, PbGlIndexer::SMiSMTiST(), and PbScIndexer::SMiSMTiST(). Referenced by PbScSector::CorrectEnergyCalibration(). |
|
Converts PHENIX (on-line) Sector number and Sector Tower Number into PHENIX TowerId.
Definition at line 437 of file EmcIndexer.C. Referenced by TowerID(), and emcOMCalibrationDataIniCal::Write(). |
|
SectorNumber, SectorTower -> SM144 NUmber (Sector scope), SM144 Tower.
Definition at line 201 of file EmcIndexer.C. References PbGlIndexer::buildPbGlIndexer(), PbScIndexer::buildPbScIndexer(), gPbGl, PbGlIndexer::iST_SMInd(), and PbScIndexer::iST_SMInd(). Referenced by findItemIdentity(), emcCalibratedDataObject::GetSMEnergies(), iPXabsFEMCH(), and PXPXSM144CH(). |
|
i(SM144 Tower), ASIC24 -> Q-base, Cell, ASIC, Preamp, Input, FEM Channel.
Definition at line 372 of file EmcIndexer.C. References iSM144TxySM144T(). |
|
i(SM144 Tower) -> x(SM144 Tower), y(SM144 Tower)
Definition at line 364 of file EmcIndexer.C. Referenced by iSM144TtoHWIndexes(), iSMTiCH(), PbScIndexer::SMiSMTiST(), and PbGlIndexer::SMiSMTiST(). |
|
i(SM Tower), ASIC Readout Flag -> FEM Channel. Same as above but includes FIX for 144/192 channels switching. It returns the channel number either in the 0-143 scope if ASIC24 is TRUE or in the 0-191 scope if ASIC24 is false. Definition at line 300 of file EmcIndexer.C. References iSM144TxySM144T(). |
|
i(SM144 Tower) -> FEM Channel Converts Tower Number (scope of SM144) into FEM Channel number. Assumes ASIC24=true and Channel Numbers from 0 to 143) Definition at line 149 of file EmcIndexer.h. Referenced by findItemIdentity(), iPXabsFEMCH(), and PXPXSM144CH(). |
|
Tells if an absolute tower id is PbGl.
Definition at line 131 of file EmcIndexer.h. References isPbGlReference(). Referenced by emcRawDataCalibratorV2::CalibrateEnergy(), emcRawDataCalibratorV1::CalibrateEnergy(), emcRawDataCalibrator::CalibrateEnergy(), and mEmcReCalibratorModulev1::event(). |
|
Tells if an absolute FEM id is PbGl.
Definition at line 136 of file EmcIndexer.h. Referenced by emcDataProcessorv2::decode(). |
|
Tells if an absolute tower id is a PbGl reference.
Definition at line 622 of file EmcIndexer.C. Referenced by isPbGl(). |
|
Tells if an absolute tower id is PbSc.
Definition at line 121 of file EmcIndexer.h. References isPbScReference(). Referenced by emcRawDataCalibratorV2::CalibrateEnergy(), emcRawDataCalibratorV1::CalibrateEnergy(), emcRawDataCalibrator::CalibrateEnergy(), and mEmcReCalibratorModulev1::event(). |
|
Tells if an absolute FEM id is PbSc.
Definition at line 126 of file EmcIndexer.h. Referenced by emcGainFEM::AddNewItem(), emcGainFEM::Compact(), and emcDataProcessorv2::decode(). |
|
Tells if an absolute tower id is a PbSc reference.
Definition at line 611 of file EmcIndexer.C. Referenced by isPbSc(). |
|
Tells if an absolute tower id is a reference tower.
Definition at line 111 of file EmcIndexer.h. Referenced by emcDCProcessorv3::calibrate(), and emcDCProcessorv2::calibrate(). |
|
Tells if a fem holds reference signals.
Definition at line 116 of file EmcIndexer.h. References FirstReferenceFEMAbsolutePosition(). |
|
i(SectorTower) -> SM#, iSM144, iSM144T, x(SM144T), y(SM144T).
Implemented in PbGlIndexer, and PbScIndexer. |
|
Converts i(SectorTower) -> x(SectorTower), y(SectorTower).
Definition at line 477 of file EmcIndexer.C. |
|
Converts i(SectorTower) -> x(SectorTower), y(SectorTower).
Implemented in PbGlIndexer, and PbScIndexer. Referenced by decodeTowerId(), and TowerLocation(). |
|
Checks validity of the Sector, x, y combination.
Definition at line 425 of file EmcIndexer.C. Referenced by emcOMRejectList::Read(). |
|
Max. number of FEMs in EMCAL.
Definition at line 187 of file EmcIndexer.h. Referenced by emcDB::GetPinNumber(), PXSM144iCH_iPX(), and emcDB::ReadConfiguration(). |
|
From TowerId (PHENIX scope) to FEM number (PHENIX scope) and FEM channel number.
Definition at line 544 of file EmcIndexer.C. References iPXiSiST(), iSiSM144_PXSM144(), iSiSTiSMiSMT(), and iSMTiCH(). Referenced by emcPatch::event(), emcOFTowerContainer::fill(), emcBadModulesv1::update(), and emcOMCalibrationDataIniCal::Write(). |
|
PHENIX SM144 (0-171) -> Sector, SM NUmber(Sector SM).
Definition at line 143 of file EmcIndexer.C. Referenced by findItemIdentity(), emcBadNormt::initGainBaseLine(), namer(), emcCalibrationDataHelper::patch(), emcChannelEvolution::produce(), PXSM144iCH_iPX(), reader(), and emcQAs::WriteDataToFile(). |
|
SM144 (EMC Scope), FEM Channel -> PHENIX EMC Tower. SM144 (EMC Scope), FEM Channel -> PHENIX EMC Tower. Definition at line 216 of file EmcIndexer.C. References iCHiSMT(), iSiSMiSMTiPX(), MaxNumberOfFEMs(), and PXSM144_iSiSM144(). Referenced by emcBadNormt::process(), emcTowerContentv3::SetID(), emcTowerContentv2::SetID(), emcTowerContentv1S::SetID(), emcTowerContentv1M::SetID(), and emcTowerContentv1::SetID(). |
|
Arm,Sector (offline convention) -> sectorNumber (online).
Definition at line 581 of file EmcIndexer.C. Referenced by emcOFClusterContainer::fill(), mEmcClusterizerv0::fillPeakArea(), histogram(), and TowerID(). |
|
sectorNumber(online) -> Arm,Sector (offline convention);
Definition at line 633 of file EmcIndexer.C. |
|
SM, i(SM Tower) -> i(SectorTower).
Implemented in PbGlIndexer, and PbScIndexer. |
|
SM# -> xSM, ySM.
Implemented in PbGlIndexer, and PbScIndexer. |
|
SM#, x(SM Tower), y(SM Tower) -> i(SectorTower).
Implemented in PbGlIndexer, and PbScIndexer. |
|
Definition at line 136 of file EmcIndexer.C. |
|
Get (offline) softwareKey from TowerID.
Definition at line 70 of file EmcIndexer.C. References iPXiSiST(). |
|
Definition at line 681 of file EmcIndexer.C. References decodeSoftwareKey(), and TowerID(). |
|
Get TowerID from (arm,sector_in_arm,yrow,zrow (offline used).
Definition at line 672 of file EmcIndexer.C. References iSiSTiPX(), sectorOfflineToOnline(), and xySTiST(). Referenced by emcPatch::event(), emcOFTowerContainer::fill(), and TowerID(). |
|
Get (arm,sector_in_arm,yrow,zrow) from a TowerID (offline used).
Definition at line 504 of file EmcIndexer.C. References emcTowerLocation::arm, iPXiSiST(), iSTxyST(), emcTowerLocation::sector, emcTowerLocation::yrow, and emcTowerLocation::zrow. Referenced by mEmcTOFCorr6Module::event(), mEmcTOFCorr5Module::event(), EmcSimuRawDataReCal::SetGainFromAfterBurner(), and EmcSimuRawDataReCal::SetGainFromMIP(). |
|
xSM,ySM -> SM# (reverse operation of SMxySM).
Implemented in PbGlIndexer, and PbScIndexer. |
|
x(SM Tower), y(SM Tower) -> i(SM Tower).
Implemented in PbGlIndexer, and PbScIndexer. |
|
Sector, x(SectorTower), y(SectorTower) -> i(SectorTower).
Definition at line 484 of file EmcIndexer.C. Referenced by TowerID(). |
|
Definition at line 249 of file EmcIndexer.h. Referenced by EmcSectorId(), and EmcSectorNumber(). |