Sensor¶
- class dnois.sensor.Sensor(pixel_num: int | tuple[int, int], pixel_size: float | tuple[float, float])¶
A basic sensor model.
- Parameters:
pixel_num (int or tuple[int, int]) – Numbers of pixels in vertical and horizontal directions.
pixel_size (float or tuple[float, float]) – Height and width of a pixel in meters.
- extra_repr() str ¶
Return the extra representation of the module.
To print customized extra information, you should re-implement this method in your own modules. Both single-line and multi-line strings are acceptable.
- forward(radiance: Tensor) Tensor ¶
Returns the input radiance field reaching the sensor plane instantaneously.
- Parameters:
radiance (Tensor) – Radiance field of shape \((\ldots, N_\text{wl}, H, W)\).
- Returns:
radiance
itself.- Return type:
Tensor
- property h¶
Physical height of the sensor in meters.
- Type:
float
- property pixel_h: float¶
Height of a pixel.
- Type:
float
- pixel_num: tuple[int, int]¶
Numbers of pixels in vertical and horizontal directions.
- pixel_size: tuple[float, float]¶
Height and width of a pixel in meters.
- property pixel_w: float¶
Width of a pixel.
- Type:
float
- property res_h: int¶
Number of pixels in vertical direction.
- Type:
int
- property res_w: int¶
Number of pixels in horizontal direction.
- Type:
int
- property size: tuple[float, float]¶
Returns the physical size i.e. height and width of the sensor.
- Type:
tuple[float, float]
- property w¶
Physical width of the sensor in meters.
- Type:
float