pyrfu.mms.psd_rebin module#

pyrfu.mms.psd_rebin.psd_rebin(vdf: Dataset, phi: ndarray[tuple[int, ...], dtype[float32]], energy0: ndarray[tuple[int, ...], dtype[float32]], energy1: ndarray[tuple[int, ...], dtype[float32]], esteptable: ndarray[tuple[int, ...], dtype[uint8]]) Tuple[ndarray[tuple[int, ...], dtype[datetime64]], ndarray[tuple[int, ...], dtype[float32 | float64]], ndarray[tuple[int, ...], dtype[float32]], ndarray[tuple[int, ...], dtype[float32]]][source]#

Convert burst mode distribution into 64 energy channel distribution.

Takes the burst mode distribution sampled in two energy tables and converts to a single energy table with 64 energy channels. Time resolution is halved and phi angles are averaged over adjacent times.

Parameters:
  • vdf (Dataset) – Time series of the particle distribution.

  • phi (numpy.ndarray) – Time series of the phi angles.

  • energy0 (numpy.ndarray) – Energy table 0.

  • energy1 (numpy.ndarray) – Energy table 1.

  • esteptable (numpy.ndarray) – Time series of the stepping table between energies (burst).

Returns:

  • time_rnumpy.ndarray

    Time array of the recompiled distribution.

  • vdf_rnumpy.ndarray

    Recompiled distribution.

  • energy_rnumpy.ndarray

    Recompiled energy table.

  • phi_rnumpy.ndarray

    Recompiled phi angles.

Return type:

tuple

Raises:

TypeError – If vdf is not a xarray.Dataset or if phi is not a numpy.ndarray or if energy0 is not a numpy.ndarray or if energy1 is not a numpy.ndarray or if esteptable is not a numpy.ndarray.

Notes

I’m assuming no gaps in the burst data interval. If there is a gap use time_clip before running. To be updated later.