confusion about usage #1898
Unanswered
SoulProficiency
asked this question in
1. Help
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
i try pyav with ascend device(HUAWEI altas NPU) and ascend provides us a example of pulling stream and hard decode.
#-----
video = av.open(self._stream_name)
stream = [s for s in video.streams if s.type == 'video']
for packet in video.demux([stream[0]]):
in_frame_np = np.frombuffer(packet.to_bytes(), np.byte)
size = in_frame_np.size
#-----
this demo will run success with av==11.0.0 but will fail with 12.3.0 and python tell me "AttributeError: 'av.packet.Packet' object has no attribute 'to_bytes'"
how we can do it with new version?
Beta Was this translation helpful? Give feedback.
All reactions