nerfbaselines.utils

class nerfbaselines.utils.Formatter(fmt=None, datefmt=None, style='%', validate=True, *, defaults=None)[source]

Bases: Formatter

format(record: LogRecord)[source]

Format the specified record as text.

The record’s attribute dictionary is used as the operand to a string formatting operation which yields the returned string. Before formatting the dictionary, a couple of preparatory steps are carried out. The message attribute of the record is computed using LogRecord.getMessage(). If the formatting string uses the time (as determined by a call to usesTime(), formatTime() is called to format the event time. If there is exception information, it is formatted using formatException() and appended to the message.

class nerfbaselines.utils.Indices(steps)[source]

Bases: object

classmethod every_iters(iters: int, zero: bool = False)[source]
nerfbaselines.utils.batched(array, batch_size)[source]
nerfbaselines.utils.convert_image_dtype(image, dtype)[source]
nerfbaselines.utils.get_rays(camera_poses: ndarray, camera_intrinsics: ndarray, xy: ndarray, distortions: Distortions | None) Tuple[ndarray, ndarray][source]
nerfbaselines.utils.linear_to_srgb(img)[source]
nerfbaselines.utils.partialclass(cls, *args, **kwargs)[source]
nerfbaselines.utils.partialmethod(func, *args, **kwargs)[source]
nerfbaselines.utils.setup_logging(verbose: bool)[source]
nerfbaselines.utils.srgb_to_linear(img)[source]