Skip to content
Snippets Groups Projects
Commit 0a5e8526 authored by Viktoriia Lysenko's avatar Viktoriia Lysenko
Browse files

fix

parent 29368ee2
No related branches found
No related tags found
1 merge request!68897AFP dqm algorithm for tof efficiency
......@@ -34,19 +34,11 @@ dqm_core::Result*
dqm_algorithms::AFP_ToFEfficiency::execute( const std::string& name,
const TObject& object,
const dqm_core::AlgorithmConfig& config ) {
<<<<<<< HEAD
if ( !object.IsA()->InheritsFrom( "TH2" ) ) {
throw dqm_core::BadConfig( ERS_HERE, name, "does not inherit from TH2" );
}
auto histogram = static_cast<const TH2D*>( &object );
=======
if ( !object.IsA()->InheritsFrom( "TEfficiency" ) ) {
throw dqm_core::BadConfig( ERS_HERE, name, "does not inherit from TEfficiency" );
}
auto histogram = static_cast<const TEfficiency*>( &object );
>>>>>>> 6f1c858ac9cda197407bff0cadca10adaee6ae45
auto gthreshold = static_cast<uint32_t>( dqm_algorithms::tools::GetFromMap( "NbadTrains", config.getGreenThresholds() ) );
auto rthreshold = static_cast<uint32_t>( dqm_algorithms::tools::GetFromMap( "NbadTrains", config.getRedThresholds() ) );
......@@ -55,11 +47,7 @@ dqm_algorithms::AFP_ToFEfficiency::execute( const std::string& name,
uint32_t each_tr_status[2] = {};
for (uint32_t i = 1; i < 5; ++i)
{
<<<<<<< HEAD
float current_eff = histogram->GetBinContent(histogram->GetBin(5,i));
=======
float current_eff = histogram->GetEfficiency(histogram->GetGlobalBin(5,i));
>>>>>>> 6f1c858ac9cda197407bff0cadca10adaee6ae45
if (current_eff >= eff_limit)
each_tr_status[0]++;
else
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment