irtk.scene.EnvironmentLight

class irtk.scene.EnvironmentLight(radiance: torch.Tensor | ndarray | List | Tuple, to_world: torch.Tensor | ndarray | List | Tuple = torch.eye)

A class representing an environment light.

__init__(radiance: torch.Tensor | ndarray | List | Tuple, to_world: torch.Tensor | ndarray | List | Tuple = torch.eye) None

Initializes an EnvironmentLight object.

Parameters:
  • radiance – The environment light radiance (float, shape (m, n, 3)).

  • to_world – The transformation matrix to world coordinates (float, shape (4, 4)).

classmethod from_file(radiance_filename: str, radiance_is_srgb: bool | None = None, to_world: torch.Tensor | ndarray | List | Tuple = torch.eye) EnvironmentLight

Creates an EnvironmentLight object from a file.

Parameters:
  • radiance_filename – The filename of the radiance texture.

  • radiance_is_srgb – Whether the radiance texture is in sRGB format.

  • to_world – The transformation matrix to world coordinates (float, shape (4, 4)).

Returns:

An EnvironmentLight object.