Commit f15ec588 authored by Jens Kroeger's avatar Jens Kroeger
Browse files

EventLoaderATLASpix: remove calibration parameter which is not used anyway (yet)

parent f5cac97e
......@@ -14,11 +14,6 @@ EventLoaderATLASpix::EventLoaderATLASpix(Configuration config, std::shared_ptr<D
m_clkdivend2M = m_config.get<int>("clkdivend2", 0.) + 1;
m_highToTCut = m_config.get<int>("high_tot_cut", 40);
if(m_config.has("calibration_file")) {
m_calibrationFile = m_config.getPath("calibration_file");
}
m_buffer_depth = m_config.get<int>("buffer_depth", 1000);
// ts1Range = 0x800 * m_clkdivendM;
......@@ -159,22 +154,6 @@ void EventLoaderATLASpix::initialise() {
hPixelTriggerTimeResidualOverTime =
new TH2D("hPixelTriggerTimeResidualOverTime_0", histTitle.c_str(), 3e3, 0, 3e3, 1e4, -50, 50);
// Read calibration:
m_calibrationFactors.resize(static_cast<size_t>(m_detector->nPixels().X() * m_detector->nPixels().Y()), 1.0);
if(!m_calibrationFile.empty()) {
std::ifstream calibration(m_calibrationFile);
std::string line;
std::getline(calibration, line);
int col, row;
double calibfactor;
while(getline(calibration, line)) {
std::istringstream(line) >> col >> row >> calibfactor;
m_calibrationFactors.at(static_cast<size_t>(row * 25 + col)) = calibfactor;
}
calibration.close();
}
LOG(INFO) << "Using clock cycle length of " << m_clockCycle << " ns." << std::endl;
m_oldtoa = 0;
......@@ -405,7 +384,7 @@ bool EventLoaderATLASpix::read_caribou_data() { // return false when reaching eo
return true;
}
// when calibration is not available, set charge = tot
// since calibration is not implemented yet, set charge = tot
Pixel* pixel = new Pixel(m_detector->name(), col, row, tot, tot, timestamp);
// FIXME: implement conversion from ToT to charge:
......
......@@ -107,8 +107,6 @@ namespace corryvreckan {
std::string m_inputDirectory;
double m_clockCycle;
int m_highToTCut;
std::string m_calibrationFile;
std::vector<double> m_calibrationFactors;
// int m_clkdivendM;
int m_clkdivend2M;
int m_buffer_depth;
......
......@@ -8,8 +8,9 @@
This module reads in data for the ATLASpix device from an input file created by the Caribou readout system. It supports binary output format.
The module opens and reads one data file named `data.bin` in the specified input directory. For each hit it, stores the detectorID, row, column, and ToT.
Since a calibration is not yet implemented, the pixel charge is set to the pixel ToT.
This module requires either another event loader of another detector type before which defines the event start and end times (variables `eventStart` and `eventEnd` on the clipboard) or an instance of the Metronome module which provides this information.
This module requires either another event loader of another detector type before which defines the event on the clipboard or an instance of the Metronome module which provides this information.
### Parameters
* `input_directory`: Path to the directory containing the `data.bin` file. This path should lead to the directory above the ALTASpix directory, as this string is added to the input directory in the module.
......@@ -17,7 +18,6 @@ This module requires either another event loader of another detector type before
* `legacy_format`: Set `true` if using legacy data format of the Karlsruhe readout system. Default is `false`, corresponding the the format of the Caribou readout system.
* `clkdivend2`: Value of clkdivend2 register in ATLASPix specifying the speed of TS2 counter. Default is `0`.
* `high_tot_cut`: "high ToT" histograms are filled if pixel ToT is larger than this cut. Default is `40`.
* `calibration_file` (optional): input file for pixel-wise calibration from ToT to charge in electrons. If not provided, the pixel charge is equivalent to pixel ToT.
* `buffer_depth`: Depth of buffer in which pixel hits are timesorted before being added to an event. If set to `1`, effectively no timesorting is done. Default is `1000`.
### Plots produced
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment