You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I wonder if at some point we need a helper in poseinterface.io that can take frames from a variety of sources (extracted from the video, taken from .pkg.slp, or directly as an image sequence) and write them in PoseMark format. That would also replace the inline imageio loop later in this example.
frames_to_posemark only copies and renames existing image files, so it can't be used in #87. A .slp file stores only references to frames in the video, not the images. (.pkg.slp files embed the images as an HDF5 dataset, but they still have to be read with sleap-io.)
Instead, the example loops through the framelabels JSON and reads each frame from the video with sleap-io. This duplicates the frame-matching logic in frames_to_posemark and means SLEAP is handled differently from DLC and Lightning Pose.
frames_to_posemark could also accept a video (a path or a sio.Video) as the frame source, so all three formats use the same function.
Activity
[-]`frames_to_posemark` to accept sio.Video?[/-][+]`frames_to_posemark` to accept a video?[/+]