imgviz.depth2rgb

imgviz.depth2rgb(depth: ~numpy.ndarray, min_value: ~typing.Optional[float] = None, max_value: ~typing.Optional[float] = None, colormap: str = 'jet', dtype: ~typing.Type = <class 'numpy.uint8'>) ndarray[source]

Convert depth to rgb.

Parameters:
  • depth (numpy.ndarray, (H, W), float) – Depth image.

  • dtype (numpy.dtype) – Dtype of output image. default: np.uint8

  • min_value (float, optional) – Minimum value for colorizing.

  • max_value (float, optional) – Maximum value for colorizing.

  • colormap (str, optional) – Colormap, default: ‘jet’.

Returns:

rgb – Output colorized image.

Return type:

numpy.ndarray, (H, W, 3), np.uint8