Currently photon counting (or more precisely, edge counting) mode with NI MFIO cards scales up a default 8-bit range to the full 16-bit range used in intermediate processing, then averages a number consecutive samples into a pixel. This approach was adapted from the analog input mode (it's the same Numba kernel:
|
def resample_kernel(raw_data: np.ndarray, |
), where this approach makes more sense.
For photon counting, it would be better to 1) not scale the sample values--the fundamental data is quantized so integer levels have meaning and 2) integrate rather than average samples into a pixel.
Will need to look at whether we can add a switch in processor and possibly and integrating version of the numba kernel. We would also need the number of samples/pixel to be constant across the line or else there will be excess variance. This would remove possibility of resampling (like to correct res scanner or optics distortions).
Currently photon counting (or more precisely, edge counting) mode with NI MFIO cards scales up a default 8-bit range to the full 16-bit range used in intermediate processing, then averages a number consecutive samples into a pixel. This approach was adapted from the analog input mode (it's the same Numba kernel:
dirigo/dirigo/plugins/processors.py
Line 37 in 81829a0
For photon counting, it would be better to 1) not scale the sample values--the fundamental data is quantized so integer levels have meaning and 2) integrate rather than average samples into a pixel.
Will need to look at whether we can add a switch in processor and possibly and integrating version of the numba kernel. We would also need the number of samples/pixel to be constant across the line or else there will be excess variance. This would remove possibility of resampling (like to correct res scanner or optics distortions).