lentil.radiometry.Spectrum.pad

Spectrum.pad(ends, sampling='min', mode='constant', **kwargs)[source]

Pad a Spectrum

Parameters
  • ends (sequence or array_like, optional) – Wavelength ends to pad to. If None (default), a single value is padded to each end of the Spectrum according to the sampling and mode parameters.

  • sampling ('min' or float, optional) –

    • ‘min’ (Default)

    • float

  • mode ({'constant', 'edge'}, optional) –

    • ‘constant’ pads with a constant value (Default)

    • ’edge’ pads with the edge values

  • values (sequence or int, optional) – Used in ‘constant’. The (before, after) values to set the padded values for each end. int is a shortcut for before = after. Default is 0.