PyDL:docs

- Index
- Modules

### Navigation

- next »
- « previous |
- pydl v0.6.0 »
- PyDL »
- SDSS Utilities (`pydl.pydlutils`) »
- nw_float_to_byte

# nw_float_to_byte

`pydl.pydlutils.rgbcolor.``nw_float_to_byte`(image, bits=8)

  Converts an array of floats in [0.0, 1.0] to bytes in [0, 255].

  Parameters:

  image : `ndarray`

  > Image to convert.

  bits : `int`, optional

  > Number of bits in final image.

  Returns:

  `ndarray`

  > Converted image.