Commit 512edc0d authored by Jens Kroeger's avatar Jens Kroeger
Browse files

AnalysisEfficiency: changed calculation of nbins_x/y into base units

parent 63a582d4
......@@ -30,8 +30,8 @@ void AnalysisEfficiency::initialise() {
auto pitch_x = static_cast<double>(Units::convert(m_detector->pitch().X(), "um"));
auto pitch_y = static_cast<double>(Units::convert(m_detector->pitch().Y(), "um"));
auto nbins_x = static_cast<int>(std::ceil(pitch_x / Units::convert(m_inpixelBinSize, "um")));
auto nbins_y = static_cast<int>(std::ceil(pitch_y / Units::convert(m_inpixelBinSize, "um")));
auto nbins_x = static_cast<int>(std::ceil(m_detector->pitch().X() / m_inpixelBinSize));
auto nbins_y = static_cast<int>(std::ceil(m_detector->pitch().Y() / m_inpixelBinSize));
if(nbins_x > 1e4 || nbins_y > 1e4) {
throw InvalidValueError(m_config, "inpixel_bin_size", "Too many bins for in-pixel histograms.");
}
......
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