Sensor¶
dnois.sensor
implements image sensor models with frequently used functions,
such as Bayer CFA, noise simulation, Gamma correction, quantization, saturation, etc.
Sensor model¶
|
Rearrange all the pixels in an image with shape \((\cdots,H,W)\) into channels-wise form \((\cdots,C,H/h,W/w)\), where \(C=hw\) is the number of channels and \(h\) and \(w\) are the size of a unit of a regular color filter array (CFA). |
|
Flatten the pixels in a channel-wise image with shape \((\cdots,C,H,W)\) into CFA units with size \((h,w)\) to form an image with shape \((\cdots,H\times h,W\times w)\), where \(C=hw\). |
|
Quantize continuous-valued signal, emulating an analogous-to-digital conversion. |
|
Convert an RGB image into a single-channel image using Bayer CFA pattern. |
|
Integrate given radiance field across wavelengths with given spectral response function (SRF). |
|
A basic sensor model. |
|
A simple RGB or grayscale sensor model, which processes the radiance field reaching the sensor plane as follows: |