9#include <cdc/modules/cdcJobCntlParModifier/CDCJobCntlParModifierModule.h>
35 setDescription(
"Change job contorol parameters. Please put this module in the path (before Geometry module) with specified input parameters when you want to change them.");
44 "Switch on/off time-walk correction in the TDC-count translator for MC events. Use the CDCDigitizer's flag if you want to add/not add time walk in digitization.",
48 "Switch on/off sense wire (gravitational) sag in FullSim. Here, sag means the main part which corresponds to design+displacement in case of wire position. You can control the perturbative part (corresponding to (mis)alignment in case of wire-position) of sag in Digitizer.",
54 "Energy deposite (edep) thresh. for G4 step (GeV). All hits with smaller edep will be dropped at FullSim level. Set this to a negative value if you want to keep simhits with edep=0.",
58 "Minimum track length (cm) required for saving in MCParticle.; to be applied to all particles other than primaries and decay-daughters.",
66 "Switch on/off printing the G4 material table at the stage of CDC geometry creation.",
false);
69 "Material definition mode: =0: define a mixture of gases and wires in the entire tracking volume; =1: dummy; =2: define all sense and field wires explicitly in the volume.",
73 "Sense wire z position mode: =1: correct for feedthrough effect; =0: not correct.", 1);
92 addParam(
"XtInputType",
m_xtInputType,
"Input type for xt-relations; db-object (true); text-file (false).",
true);
98 addParam(
"T0InputType",
m_t0InputType,
"Input type for t0s; db-object (true); text-file (false).",
true);
100 addParam(
"TimeWalkInputType",
m_twInputType,
"Input type for time walks; db-object (true); text-file (false).",
true);
102 addParam(
"BadWireInputType",
m_bwInputType,
"Input type for bad wires; db-object (true); text-file (false).",
true);
104 addParam(
"ChannelMapInputType",
m_chMapInputType,
"Input type for channel map; db-object (true); text-file (false).",
true);
111 string(
"displacement_v2.2.1.dat"));
113 addParam(
"AlignmentFile",
m_alignmentFile,
"Input file name (on cdc/data) for wire alignment.",
string(
"alignment_v2.dat"));
118 addParam(
"XtFile",
m_xtFile,
"Input file name (on cdc/data) for xt-relations. You can specify either an uncompressed or gzip file.",
119 string(
"xt_v3_chebyshev.dat.gz"));
121 addParam(
"SigmaFile",
m_sigmaFile,
"Input file name (on cdc/data) for sigmas.",
string(
"sigma_v2.dat"));
123 addParam(
"PropSpeedFile",
m_propSpeedFile,
"Input file name (on cdc/data) for prop-speeds.",
string(
"propspeed_v0.dat"));
125 addParam(
"T0File",
m_t0File,
"Input file name (on cdc/data) for t0s.",
string(
"t0_v1.dat"));
127 addParam(
"TimeWalkFile",
m_twFile,
"Input file name (on cdc/data) for time walks.",
string(
"tw_off.dat"));
129 addParam(
"BadWireFile",
m_bwFile,
"Input file name (on cdc/data) for bad wires.",
string(
"badwire_v1.dat"));
131 addParam(
"ChannelMapFile",
m_chMapFile,
"Input file name (on cdc/data) for channel map.",
string(
"ch_map.dat"));
133 addParam(
"EDepToADCFile",
m_eDepToADCFile,
"Input file name (on cdc/data) for edep-to-adc.",
string(
"edeptoadc.dat"));
137 "Additional fudge factor for space resol. used in real data event reconstruction (common to all cells).",
142 "Additional fudge factor for space resol. used in MC event reconstruction (common to all cells). N.B. This factor is not applied in digitization; only applied in reconstruction. Pplease set the fudge parameter of digitizer instead if you want to change the digitization sigma indep. of sigma used in reconstruction.",
146 addParam(
"MapperGeometry",
m_mapperGeometry,
"Define B-field mapper geometry used in GCR in 2017 summer. Tentative option.",
150 addParam(
"MapperPhiAngle",
m_mapperPhiAngle,
"Phi-angle (deg.) of B-field mapper used in GCR in 2017 summer. Tentative option.",
160 B2INFO(
"CDCJobCntlParModifier: timeWalk modified: " <<
m_scp.getTimeWalk() <<
" to " <<
m_timeWalk);
165 B2INFO(
"CDCJobCntlParModifier: wireSag modified: " <<
m_scp.getWireSag() <<
" to " <<
m_wireSag);
170 B2INFO(
"CDCJobCntlParModifier: modLeftRightFlag modified: " <<
m_scp.getModLeftRightFlag() <<
" to " <<
m_modLeftRightFlag);
175 B2INFO(
"CDCJobCntlParModifier: debug4Sim modified: " <<
m_scp.getDebug() <<
" to " <<
m_debug4Sim);
180 B2INFO(
"CDCJobCntlParModifier: thresholdEnergyDeposit modified: " <<
m_scp.getThresholdEnergyDeposit() <<
" to " <<
186 B2INFO(
"CDCJobCntlParModifier: minTrackLength modified: " <<
m_scp.getMinTrackLength() <<
" to " <<
m_minTrackLength);
192 B2INFO(
"CDCJobCntlParModifier: materialDefinitionMode modified: " <<
m_gcp.getMaterialDefinitionMode() <<
" to " <<
198 B2INFO(
"CDCJobCntlParModifier: senseWireZposMode modified: " <<
m_gcp.getSenseWireZposMode() <<
" " <<
m_senseWireZposMode);
203 B2INFO(
"CDCJobCntlParModifier: printMaterialTable modified: " <<
m_gcp.getPrintMaterialTable() <<
" to " <<
m_printMaterialTable);
208 B2INFO(
"CDCJobCntlParModifier: debug4Geo modified: " <<
m_gcp.getDebug() <<
" to " <<
m_debug4Geo);
213 B2INFO(
"CDCJobCntlParModifier: displacement switch modified: " <<
m_gcp.getDisplacement() <<
" to " <<
m_displacement);
218 B2INFO(
"CDCJobCntlParModifier: alignment switch modified: " <<
m_gcp.getAlignment() <<
" to " <<
m_alignment);
223 B2INFO(
"CDCJobCntlParModifier: misalignment switch modified: " <<
m_gcp.getMisalignment() <<
" to " <<
m_misalignment);
228 B2INFO(
"CDCJobCntlParModifier: displacementInputType modified: " <<
m_gcp.getDisplacementInputType() <<
" to " <<
234 B2INFO(
"CDCJobCntlParModifier: alignmentInputType modified: " <<
m_gcp.getAlignmentInputType() <<
" to " <<
m_alignmentInputType);
239 B2INFO(
"CDCJobCntlParModifier: misalignmentInputType modified: " <<
m_gcp.getMisalignmentInputType() <<
" to " <<
245 B2INFO(
"CDCJobCntlParModifier: xtInputType modified: " <<
m_gcp.getXtInputType() <<
" to " <<
m_xtInputType);
250 B2INFO(
"CDCJobCntlParModifier: sigmaInputType modified: " <<
m_gcp.getSigmaInputType() <<
" to " <<
m_sigmaInputType);
255 B2INFO(
"CDCJobCntlParModifier: propSpeedInputType modified: " <<
m_gcp.getPropSpeedInputType() <<
" to " <<
m_propSpeedInputType);
260 B2INFO(
"CDCJobCntlParModifier: t0InputType modified: " <<
m_gcp.getT0InputType() <<
" to " <<
m_t0InputType);
265 B2INFO(
"CDCJobCntlParModifier: twInputType modified: " <<
m_gcp.getTwInputType() <<
" to " <<
m_twInputType);
270 B2INFO(
"CDCJobCntlParModifier: bwInputType modified: " <<
m_gcp.getBwInputType() <<
" to " <<
m_bwInputType);
275 B2INFO(
"CDCJobCntlParModifier: chMapInputType modified: " <<
m_gcp.getChMapInputType() <<
" to " <<
m_chMapInputType);
280 B2INFO(
"CDCJobCntlParModifier: edep-to-adc modified: " <<
m_gcp.getEDepToADCInputType() <<
" to " <<
m_eDepToADCInputType);
285 B2INFO(
"CDCJobCntlParModifier: displacementFile modified: " <<
m_gcp.getDisplacementFile() <<
" to " <<
m_displacementFile);
290 B2INFO(
"CDCJobCntlParModifier: alignmentFile modified: " <<
m_gcp.getAlignmentFile() <<
" to " <<
m_alignmentFile);
295 B2INFO(
"CDCJobCntlParModifier: misalignmentFile modified: " <<
m_gcp.getMisalignmentFile() <<
" to " <<
m_misalignmentFile);
300 B2INFO(
"CDCJobCntlParModifier: xtFile modified: " <<
m_gcp.getXtFile() <<
" to " <<
m_xtFile);
305 B2INFO(
"CDCJobCntlParModifier: sigmaFile modified: " <<
m_gcp.getSigmaFile() <<
" to " <<
m_sigmaFile);
310 B2INFO(
"CDCJobCntlParModifier: propSpeedFile modified: " <<
m_gcp.getPropSpeedFile() <<
" to " <<
m_propSpeedFile);
315 B2INFO(
"CDCJobCntlParModifier: t0File modified: " <<
m_gcp.getT0File() <<
" to " <<
m_t0File);
320 B2INFO(
"CDCJobCntlParModifier: timeWalkFile modified: " <<
m_gcp.getTwFile() <<
" to " <<
m_twFile);
325 B2INFO(
"CDCJobCntlParModifier: badWireFile modified: " <<
m_gcp.getBwFile() <<
" to " <<
m_bwFile);
330 B2INFO(
"CDCJobCntlParModifier: chMapFile modified: " <<
m_gcp.getChMapFile() <<
" to " <<
m_chMapFile);
335 B2INFO(
"CDCJobCntlParModifier: edep-to-adcFile modified: " <<
m_gcp.getEDepToADCFile() <<
" to " <<
m_eDepToADCFile);
340 B2INFO(
"CDCJobCntlParModifier: addFudgeFactorForSigmaForData modified: " <<
m_gcp.getAddFudgeFactorForSigmaForData() <<
" to "
346 B2INFO(
"CDCJobCntlParModifier: addFudgeFactorForSigmaForMC modified: " <<
m_gcp.getAddFudgeFactorForSigmaForMC() <<
" to " <<
352 B2INFO(
"CDCJobCntlParModifier: mapper geometry flag modified: " <<
m_gcp.getMapperGeometry() <<
" to " <<
m_mapperGeometry);
357 B2INFO(
"CDCJobCntlParModifier: mapper phi-angle modified: " <<
m_gcp.getMapperPhiAngle() <<
" to " <<
m_mapperPhiAngle);
int m_materialDefinitionMode
Material definition mode.
bool m_timeWalk
Switch for time walk in translator.
bool m_chMapInputType
Channel map input type.
bool m_alignment
Switch for alignment.
std::string m_displacementFile
Displacement file.
double m_addFudgeFactorForSigmaForMC
Additional fudge factor for space resol.
bool m_wireSag
Switch for sense wire sag.
bool m_alignmentInputType
Alignment input type.
std::string m_chMapFile
Channel map file.
void initialize() override
Initialize.
double m_minTrackLength
Minimum track length for G4 step (cm)
double m_addFudgeFactorForSigmaForData
Additional fudge factor for space resol.
void event() override
Actual digitization of all hits in the CDC.
bool m_displacementInputType
Displacement input type.
bool m_bwInputType
Bad wire input type.
std::string m_misalignmentFile
Misalignment file.
bool m_xtInputType
Xt input type.
bool m_debug4Sim
Switch for debug printing.
bool m_eDepToADCInputType
EDep-to-adc input type.
std::string m_eDepToADCFile
EDep-to-adc file.
bool m_displacement
Switch for displacement.
bool m_printMaterialTable
Switch for printing the G4 material table.
std::string m_twFile
Time walk file.
std::string m_propSpeedFile
Prop-apeed file.
std::string m_sigmaFile
Sigma file.
std::string m_bwFile
Bad wire file.
bool m_misalignmentInputType
Misalignment input type.
CDC::CDCGeoControlPar & m_gcp
Reference to CDCGeo...
std::string m_t0File
T0 file.
std::string m_alignmentFile
Alignment file.
bool m_propSpeedInputType
Prop-apeed input type.
bool m_misalignment
Switch for misalignment.
bool m_mapperGeometry
Mapper geometry flag.
double m_thresholdEnergyDeposit
Energy thresh.
double m_mapperPhiAngle
Mapper phi-angle(deg).
bool m_t0InputType
T0 input type.
bool m_debug4Geo
Switch for debug printing.
bool m_twInputType
Time walk input type.
int m_senseWireZposMode
Sense wire Z pos.
std::string m_xtFile
Xt file.
bool m_sigmaInputType
Sigma input type.
bool m_modLeftRightFlag
Switch for modified left/right flag.
CDCJobCntlParModifierModule()
Constructor.
CDC::CDCSimControlPar & m_scp
Reference to CDCSim...
The Class for CDC Geometry Control Parameters.
The Class for CDC Simulation Control Parameters.
void setDescription(const std::string &description)
Sets the description of the module.
void setPropertyFlags(unsigned int propertyFlags)
Sets the flags for the module properties.
@ c_ParallelProcessingCertified
This module can be run in parallel processing mode safely (All I/O must be done through the data stor...
void addParam(const std::string &name, T ¶mVariable, const std::string &description, const T &defaultValue)
Adds a new parameter to the module.
#define REG_MODULE(moduleName)
Register the given module (without 'Module' suffix) with the framework.
Abstract base class for different kinds of events.