Packet#
- class torchcodec.decoders.Packet(handle: Tensor, stream_index: int, *, generation: int = 0)[source]#
One compressed packet of one stream, as a
Demuxerproduced it.You should not build one yourself: a
Demuxercreates them, and aVideoPacketDecoderor anAudioPacketDecoderconsumes them. The contents are opaque: aPacketis a handle to an FFmpeg packet.Examples using
Packet: