Commit 734f5cd7 authored by Katharina Dort's avatar Katharina Dort
Browse files

Fixed hNoAssocCls by moving check if clusters are nullptr inside the loop over tracks.

parent 62a9b4ea
......@@ -83,16 +83,18 @@ StatusCode DUTAssociation::run(std::shared_ptr<Clipboard> clipboard) {
// Get the DUT clusters from the clipboard
Clusters* clusters = reinterpret_cast<Clusters*>(clipboard->get(m_detector->name(), "clusters"));
if(clusters == nullptr) {
LOG(DEBUG) << "No DUT clusters on the clipboard";
return StatusCode::Success;
}
// Loop over all tracks
for(auto& track : (*tracks)) {
int assoc_cls_per_track = 0;
auto min_distance = std::numeric_limits<double>::max();
if(clusters == nullptr) {
hNoAssocCls->Fill(0);
LOG(DEBUG) << "No DUT clusters on the clipboard";
continue;
}
// Loop over all DUT clusters
for(auto& cluster : (*clusters)) {
// Check distance between track and cluster
......
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