PhotonTransferCurves.jl
Photon transfer curves (PTC) for methodically characterizing CCD and CMOS detectors. This module provides models for PTCs with varying complexity, ready for fitting to recorded data.
Installation
Usage
API/Reference
PhotonTransferCurves.AbstractNoiseSource
PhotonTransferCurves.AbstractNoiseSource
PhotonTransferCurves.ReadNoise
PhotonTransferCurves.ShotNoise
PhotonTransferCurves.limits
PhotonTransferCurves.noise
PhotonTransferCurves.testdata
PhotonTransferCurves.AbstractNoiseSource
— TypeAbstractNoiseSource
Interface
To define your own source, simply provide the function for how signal is manipulated given an AbstractRNG
(::MySource)(rng, input)
noise(::MySource, input)
limits(::MySource)
(optional)
See ShotNoise
for an example of an implementation of the interface
PhotonTransferCurves.AbstractNoiseSource
— Method(::AbstractNoiseSource)([rng], input)
Process a signal following the transfer function defined by the noise source. A random number generator can be passed if the process is stochastic.
PhotonTransferCurves.ReadNoise
— TypeReadNoise(;noise)
Gaussian read noise, with the given RMS noise.
PhotonTransferCurves.ShotNoise
— TypeShotNoise()
A simple Poisson process for modifying incoming signal according to counting statistics.
Examples
Simulate a Poisson process with average value of 1 three times.
julia> proc = ShotNoise()
julia> [proc(1) for _ in 1:3]
3-element Vector{Int64}:
0
3
2
julia> noise(proc, 100)
10.0
PhotonTransferCurves.limits
— Methodlimimts(::AbstractNoiseSource)
Returns the limits for signal input. By Default, is (0, Inf)
PhotonTransferCurves.noise
— Methodnoise(::AbstractNoiseSource, input)
Return the RMS noise given the input signal
PhotonTransferCurves.testdata
— Methodtestdata()
Loads a tuple of the signal and total noise from the Appendix A table A.1 from Janesick (2007).[1] This data is generated by a CMOS imager with V/e- nonlinearity. Data units are in DN.
Examples
julia> data = testdata();
julia> size(data.S)
(43,)
Contributing and Support
If you would like to contribute, feel free to open a pull request. If you want to discuss something before contributing, head over to discussions and join or open a new topic. If you're having problems with something, please open an issue.
- 1James R. Janesick, 2007, "Photon Transfer", SPIE