load_dataset#
- movement.io.load.load_dataset(file, source_software, fps=None, **kwargs)[source]#
Create a
movementdataset from any supported third-party file.- Parameters:
file (
Path|str|NWBFile) – Path to the file containing predicted poses or tracked bounding boxes. Ifsource softwareis “NWB”, this can also be apynwb.file.NWBFileobject. The file format must be among those supported by themovement.io.load_posesormovement.io.load_bboxesmodules. Based on the value ofsource_software, the appropriate loading function will be called.source_software (
Literal['DeepLabCut','SLEAP','LightningPose','Anipose','NWB','VIA-tracks']) – The source software of the file.fps (
float|None) – The number of frames per second in the video. If None (default), thetimecoordinates will be in frame numbers. This argument is ignored whensource_softwareis “NWB”, as the frame rate will be directly read or estimated from metadata in the NWB file.**kwargs – Additional keyword arguments to pass to the software-specific loading functions in modules listed under “See Also”.
- Returns:
movementdataset containing the pose or bounding box tracks, confidence scores, and associated metadata.- Return type:
Examples
>>> from movement.io import load_dataset >>> ds = load_dataset( ... "path/to/file.h5", source_software="DeepLabCut", fps=30 ... )