Skip to content

Specifying training video paths in batch when using a new machine #1212

Answered by talmo
NeuTTH asked this question in Help!
Discussion options

You must be logged in to vote

Hey @NeuTTH,

Yep, you can do this programmatically to save a new SLP file by doing something like this:

import sleap
labels = sleap.load_file("labels.v000.slp", search_paths=["path/to/video1.mp4", "path/to/video2.mp4", ...])
labels.save("labels.v000.fixed.slp")

You can also specify this in the CLI to sleap-train, but it's usually easier to save a new SLEAP file.

Note: If you're doing it via the GUI, a prompt will appear asking you to find the new paths to the video files. After locating the first one, it'll try to match the prefix to auto-detect the other ones as long as they have a shared parent folder at some point.

Let us know if that works for you!

Talmo

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@NeuTTH
Comment options

Answer selected by roomrys
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Help!
Labels
None yet
2 participants