Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enhance training dataset format support #24

Merged
merged 7 commits into from
Mar 14, 2024
Merged

Enhance training dataset format support #24

merged 7 commits into from
Mar 14, 2024

Conversation

talmo
Copy link
Contributor

@talmo talmo commented Feb 28, 2024

Overview

Goal: Be able to store SLEAP package files (example) in PoseTraining objects so we can embed images used for training models together with the ground truth poses.

Data model equivalences

sleap-io ndx-pose
Labels PoseTraining
LabeledFrame TrainingFrame
Skeleton Skeleton
Instance SkeletonInstance
Video ImageSeries
Labels.skeletons Skeletons
Labels.labeled_frames TrainingFrames
Labels.videos SourceVideos

TODO

MVP

Nice to have

  • Add a plain string field to TrainingFrame to point to source video as provenance but without triggering validation on DANDI
  • Add support for PNG string encoding representation for Image
  • Convert and upload reference SLEAP training datasets to DANDI
  • Add support for directly opening SLEAP Dandisets in sleap-io via dandi API

talmo and others added 3 commits February 27, 2024 12:07
Add tests for using Image in TrainingFrame.source_image
* Add `SkeletonInstances` class for multiple instances

* Merge changes from main

* Start changing tests

* Add `SkeletonInstances` to `TrainingFrame`

* Add name to distinguish instances

* Add `SkeletonInstances` to tests

---------

Co-authored-by: eberrigan <berri104@gmail.com>
spec/ndx-pose.extensions.yaml Outdated Show resolved Hide resolved
spec/ndx-pose.extensions.yaml Outdated Show resolved Hide resolved
@rly
Copy link
Owner

rly commented Mar 8, 2024

Hi @talmo and @eberrigan, thank you for all your work on this PR and for looking through the recent changes in the main branch at brainhack! I am happy to take on updating the README example and test, but I think you all would be better suited to do Integrate into sleap_io.io.nwb and Update docs/readme. Let me know if you'd like me to jump in to update the README example and test.

@eberrigan
Copy link
Contributor

eberrigan commented Mar 9, 2024 via email

@rly
Copy link
Owner

rly commented Mar 13, 2024

@talmo Can you give me write access to your fork? It will be easier than me creating a fork of your fork and us having to merge each fork in one by one...

@talmo
Copy link
Contributor Author

talmo commented Mar 14, 2024

@talmo Can you give me write access to your fork? It will be easier than me creating a fork of your fork and us having to merge each fork in one by one...

Done! https://github.com/talmolab/ndx-pose/invitations

@rly
Copy link
Owner

rly commented Mar 14, 2024

Thanks! I made a few changes - I moved the Skeletons type out of the PoseTraining container type because the PoseEstimation type now requires a Skeleton object and, for people who don't have (or want to include) training data with their pose estimates, it feels weird in my opinion, to require them to make a PoseTraining container just to put Skeletons into it.

I also updated the readme and tests and made some other minor adjustments.

@talmo I would like to merge this PR soon so that it will be easier for me to refactor the repo to use the latest ndx-template. Then you could start a new PR with any necessary adjustments for integration with SLEAP and any other changes you want to make (or you can make those changes here if you have time). Would that be all right?

@talmo
Copy link
Contributor Author

talmo commented Mar 14, 2024

Yes that works for me @rly!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants