|
vitrio 0.1.4
High-throughput image I/O for Cryo-Electron Microscopy (CryoEM)
|
How many pixels of a detector an image gathers into one, along each axis. More...
#include <vitrio/detector_event_binning.hpp>
Public Member Functions | |
| detector_event_binning (std::size_t factor) | |
| Construct a binning by a factor. | |
| detector_event_binning (const detector_event_binning &other) noexcept | |
| detector_event_binning & | operator= (const detector_event_binning &other) noexcept |
| std::size_t | get_factor () const noexcept |
| Get how many pixels of the detector are merged into one. | |
| std::vector< std::size_t > | resolve (const detector_event_timeline_descriptor &events) const |
| Get how many position quanta a pixel of an image gathers. | |
Friends | |
| bool | operator== (const detector_event_binning &lhs, const detector_event_binning &rhs) noexcept |
| bool | operator!= (const detector_event_binning &lhs, const detector_event_binning &rhs) noexcept |
How many pixels of a detector an image gathers into one, along each axis.
A factor of 1 renders at the resolution of the detector, 2 merges blocks of 2 by 2 pixels, and so on. It is stated in pixels of the detector rather than in the quanta its events are placed with, so the same binning applies to any acquisition, whatever subdivisions of a pixel it records.
The factor must divide the pixels along every axis of an acquisition it is applied to, so that every pixel of an image gathers as many of the detector as any other.
|
explicit |
Construct a binning by a factor.
| factor | Pixels of the detector merged into one along each axis. |
| std::invalid_argument | If factor is zero. |
|
noexcept |
Get how many pixels of the detector are merged into one.
| std::vector< std::size_t > vitrio::detector_event_binning::resolve | ( | const detector_event_timeline_descriptor & | events | ) | const |
Get how many position quanta a pixel of an image gathers.
| events | The grid the events of an acquisition are placed on. |
| std::invalid_argument | If the factor does not divide the pixels of the detector along an axis of events. |