pythia.types#

Types for pythia.

pythia.types.Con#

Mapping of element-name to gst elements’ signal callbacks.

Example

>>> def cb(*a, **kw): ...
>>> con = {"pgie": {"pad-added": cb}}

alias of Dict[str, Dict[str, Callable]]

pythia.types.GstPadProbeCallback#

Gstreamer PadProbe must implement this protocol.

Using upstream ‘Gst.PadProbeCallback’ raises NotImplementedError.

alias of Callable[[Pad, PadProbeInfo], PadProbeReturn]

class pythia.types.HasConnections(*args, **kwargs)[source]#

Bases: Protocol

Protocol to indicate a class has connections.

See also

Con

CONNECTIONS: Dict[str, Dict[str, Callable]]#
_abc_impl = <_abc_data object>#
_is_protocol = True#
class pythia.types.Loop(*args, **kwargs)[source]#

Bases: Protocol

A loop interface, where code is executed.

Example

>>> from gi.repository import GLib
>>> loop = GLib.MainLoop()
_abc_impl = <_abc_data object>#
_is_protocol = True#
quit() Any[source]#
run() Any[source]#
pythia.types.PydsClass#

Common pyds metadata class API.

alias of Union[NvDsAnalyticsFrameMeta, NvDsAnalyticsObjInfo, NvDsInferSegmentationMeta, NvDsUserMeta, NvDsLabelInfo, NvDsFrameMeta, NvDsObjectMeta, NvDsClassifierMeta]

class pythia.types.RegisteredProbe(*args, **kwargs)[source]#

Bases: dict

Simple storage for generator-induced buffer probes.

backend: base_stream.Backend#
probe: SupportedCb#
pythia.types.SinkUri#

Examples

/path/to/video.mp4 /path/to/frames/%04d.jpg livesink -> nveglglessink fakesink -> fakesink appsink -> TODO

pythia.types.SourceUri#

should start with scheme://.

  • multifilesink usese multifile:// for the uri.

  • v4l2src uses v4l2:// for the uri.

  • filesrc uses file:// for the uri.

See Also: https://gstreamer.freedesktop.org/documentation/gstreamer/gsturihandler.html?gi-language=c#GstURIHandler