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

Add sapiens as a library #900

Merged
merged 3 commits into from
Sep 17, 2024
Merged

Add sapiens as a library #900

merged 3 commits into from
Sep 17, 2024

Conversation

merveenoyan
Copy link
Contributor

No description provided.

Copy link
Contributor

@Wauplin Wauplin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Look good to me except the download count rule. I saw that there are already 6 models under https://huggingface.co/models?other=sapiens which is nice 👍

repoName: "sapiens",
repoUrl: "https://github.com/facebookresearch/sapiens",
filter: false,
countDownloads: `path_extension:"pt"`,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From what I can see in https://huggingface.co/models?other=sapiens, all models have a config.json file and no .pt files. I think it's best to continue to count downloads using config.json (the default rule) in that case.
Except if the config.json file is not loaded when a onnx file is used and in that case we should count downloads using the onnx downloads instead (but counting config.json would still be preferable if it makes sense)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The models that are intended to be covered by this PR are these ones. They don't have the tag yet, and they may be split into separate repos (either per-task or per-checkpoint).

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh ok, thanks for the pointer 👍
Let's think of a clean up before merging then (maybe contact the other 6 repos to change their tag?)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cc @xenova. I think the tag is auto-inferred from the configuration (they are sapiens models), but they are ONNX versions.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So maybe

Suggested change
countDownloads: `path_extension:"pt"`,
countDownloads: `path_extension:"pt" OR path_extension:"onnx"`,

would be appropriate to handle both cases. If all of them are sapiens models, that's perfect.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems the extension is a bit flexible:

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But is https://github.com/facebookresearch/sapiens able to load all of these weights? This doesn't seem very unified 😕

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

addressed this

@merveenoyan
Copy link
Contributor Author

they've merged all PRs adding sapiens tag @Wauplin

Copy link
Contributor

@Wauplin Wauplin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! Thanks for handling it @merveenoyan :)

@Wauplin Wauplin merged commit 23a083a into main Sep 17, 2024
3 of 5 checks passed
@Wauplin Wauplin deleted the add-sapiens branch September 17, 2024 08:06
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.

5 participants