Skip to main content

Overview

WakeNotifierFilter monitors the pipeline for specific frame types and triggers a notification when those frames pass a custom filter condition. It passes all frames through unchanged while performing this notification side-effect.

Constructor Parameters

notifier
BaseNotifier
required
The notifier object to trigger when conditions are met
types
Tuple[Type[Frame]]
required
Tuple of frame types to monitor
filter
Callable[[Frame], Awaitable[bool]]
required
Async function that examines each matching frame and returns True to trigger notification

Functionality

The processor operates as follows:
  1. Checks if the incoming frame matches any of the specified types
  2. If it’s a matching type, calls the filter function with the frame
  3. If the filter returns True, triggers the notifier
  4. Passes all frames through unchanged, regardless of the filtering result
This allows for notification side-effects without modifying the pipeline’s data flow.

Output Frames

  • All frames pass through unchanged in their original direction
  • No frames are modified or filtered out

Usage Example

Frame Flow

Notes

  • Acts as a transparent pass-through for all frames
  • Can trigger external events without modifying pipeline flow
  • Useful for signaling between pipeline components
  • Can monitor for multiple frame types simultaneously
  • Uses async filter function for complex conditions
  • Functions as a “listener” that doesn’t affect the data stream
  • Can be used for logging, analytics, or coordinating external systems