Belle II Software development
NoiseMap.h
1/**************************************************************************
2 * basf2 (Belle II Analysis Software Framework) *
3 * Author: The Belle II Collaboration *
4 * *
5 * See git log for contributors and copyright holders. *
6 * This file is licensed under LGPL-3.0, see LICENSE.md. *
7 **************************************************************************/
8
9#pragma once
10
11#include <pxd/reconstruction/Pixel.h>
12
13namespace Belle2 {
19 namespace PXD {
20
25 class NoiseMap {
26 public:
30 virtual ~NoiseMap() {}
31
33 void setNoiseLevel(float noise) { m_noiseLevel = noise; }
34
38 virtual void setSensorID(VxdID) {}
39
41 float getSignificance(const Pixel& px) const { return px.getCharge() / getNoise(px); }
42
44 virtual float getNoise(const Pixel&) const { return m_noiseLevel; }
45
50 bool operator()(const Pixel& px, float significance) const { return getSignificance(px) >= significance; }
51
56 bool operator()(float signal, float significance) const { return signal / m_noiseLevel >= significance; }
57
58 protected:
61 };
62
63 }
64
66}
Base Class to represent pixel dependent Noise Map.
Definition: NoiseMap.h:25
void setNoiseLevel(float noise)
Set the noise level.
Definition: NoiseMap.h:33
bool operator()(float signal, float significance) const
Check wether a signal exceeds a given significance using the average noise level.
Definition: NoiseMap.h:56
virtual float getNoise(const Pixel &) const
Return the noise value for a given pixel.
Definition: NoiseMap.h:44
virtual void setSensorID(VxdID)
Set the sensorID currently used.
Definition: NoiseMap.h:38
virtual ~NoiseMap()
Destructor.
Definition: NoiseMap.h:30
bool operator()(const Pixel &px, float significance) const
Check wether a signal exceeds a given significance.
Definition: NoiseMap.h:50
NoiseMap()
Constructor
Definition: NoiseMap.h:28
float getSignificance(const Pixel &px) const
Return the significance of a signal, that is signal divided by noise level.
Definition: NoiseMap.h:41
float m_noiseLevel
Noise level.
Definition: NoiseMap.h:60
Class to represent one pixel, used in clustering for fast access.
Definition: Pixel.h:36
float getCharge() const
Return the Charge of the Pixel.
Definition: Pixel.h:70
Class to uniquely identify a any structure of the PXD and SVD.
Definition: VxdID.h:33
Abstract base class for different kinds of events.