FrbSifterEvents¶
- class pirate_frb.rpc.FrbSifterEvents(beam_ids, fpga_timestamps, dms, snrs, rfi_probs, widths_ms, subband_freqs_lo_MHz, subband_freqs_hi_MHz, chunk_fpga_start, chunk_fpga_end)¶
Helper class, representing FRB events to send to the sifter.
Returned by FrbGrouper.create_events(), and passed to FrbSifterClient.send_events().
Attributes (numpy arrays, shapes must be equal):
beam_ids(int32) – X-engine beam id of each eventfpga_timestamps(int64) – absolute FPGA-counter timestamp of each eventdms(float32) – dispersion measuresnrs(float32) – signal-to-noise ratiorfi_probs(float32) – RFI probabilitywidths_ms(float32) – intrinsic pulse width in millisecondssubband_freqs_lo_MHz(float32) – low edge of the event’s frequency subband (MHz)subband_freqs_hi_MHz(float32) – high edge of the event’s frequency subband (MHz)
Other attributes:
chunk_fpga_start(int) – FPGA count at the start of the time chunk.chunk_fpga_end(int) – FPGA count at the end of the time chunk (= start of the next chunk).shape(tuple) – common shape of the per-event arrays.
- to_proto()¶
Return a list of frb_sifter_pb2.FrbEvent, one per event (row-major order).
Arrays of any shape are flattened; .tolist() yields the native Python scalars required by protobuf.