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

Adding Merlin for accurate download count #1232

Merged
merged 5 commits into from
Feb 27, 2025
Merged

Conversation

ashwinkumargb
Copy link
Contributor

I don't think we are getting an accurate download count for our hugging face repo: https://huggingface.co/stanfordmimi/Merlin, since the downloads page counts the queries to the config.json file and in our case the config.json file is empty. I was looking through the hugging face documentation and it seems like I had to add the file to the hugging face repo to allow it to have an accurate download count? Please let me know if I'm mistaken.

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.

Thanks for your PR @ashwinkumargb , this is exactly what's required! I left 2 comments below that I'll merge. For this PR to work, your repo will have to be tagged as merlin instead of Merlin. Can you update the library_name accordingly in the modelcard metadata (here https://huggingface.co/stanfordmimi/Merlin/blob/main/README.md?code=true#L5)

Once that's done, we should be good to merge!

repoName: "merlin",
repoUrl: "https://github.com/StanfordMIMI/Merlin",
filter: false,
countDownloads: `path_filename:"i3_resnet_clinical_longformer_best_clip_04-02-2024_23-21-36_epoch_99.pt"`,
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
countDownloads: `path_filename:"i3_resnet_clinical_longformer_best_clip_04-02-2024_23-21-36_epoch_99.pt"`,
countDownloads: `path_extension:"pt"`,

I fear that putting the filename will be too specific. Better to count downloads on .pt files instead. This way if you update the model in the repo or create a new repo with another trained Merlin model, then we won't have to update the countDownloads again.

@ashwinkumargb
Copy link
Contributor Author

ashwinkumargb commented Feb 27, 2025

Perfect, thank you so much for taking action on this so quickly! Yes, I have updated the model card to reflect "merlin". Please let me know if you need any other information!

Do I need to modify config.json at all? Or will everything be handled in the backend?

@Wauplin Wauplin merged commit 11e07c0 into huggingface:main Feb 27, 2025
4 checks passed
@Wauplin
Copy link
Contributor

Wauplin commented Feb 27, 2025

@ashwinkumargb thanks for updating the model card! From there nothing to do on your side. The new download count will be in effect within 4-5 days.

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