apply_rejection_to_parms

sofia_redux.scan.filters.filters_numba_functions.apply_rejection_to_parms(frame_valid, frame_weight, frame_parms, dp, channel_indices, sample_flag)[source]

Update the frame dependents following the remove operation.

Apply the channel dependent updates to the frame dependents. For a given frame the increment is given by:

increment = w * sum(dp)

where w is the frame relative weight, dp is the channel dependent delta, and the sum occurs over valid frames and nonzero samples. The frame dependents are updated via:

frame_dependents = frame_dependents + increment
Parameters:
frame_validnumpy.ndarray (bool)

A boolean mask, where False indicates that the frame is invalid and should be ignored during processing. Should be of shape (n_frames,).

frame_weightnumpy.ndarray (float)

The relative frame weights of shape (n_frames,).

frame_parmsnumpy.ndarray (float)

The frame dependents to update of shape (n_frames,).

dpnumpy.ndarray (float)

The channel delta dependents of shape (n_channels,).

channel_indicesnumpy.ndarray (int)

The channel indices mapping n_channels onto all_channels of shape (n_channels,)

sample_flagnumpy.ndarray (int)

The sample flags of shape (n_frames, all_channels) where any nonzero flag will remove that frame,channel sample from processing.

Returns:
None