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

feat: add nutrient extractor #1437

Merged
merged 5 commits into from
Oct 24, 2024
Merged

feat: add nutrient extractor #1437

merged 5 commits into from
Oct 24, 2024

Conversation

raphael0202
Copy link
Collaborator

@raphael0202 raphael0202 commented Oct 24, 2024

Add the nutrient extractor model.
For every new image, we run the model inference and save the raw prediction in ImagePrediction table.
If the prediction is not empty (=if some values were found), we create a prediction. If the product has no nutrient, an insight is created.

A new API route was not added, it will be dealt with in a subsequent PR.

Copy link

codecov bot commented Oct 24, 2024

Codecov Report

Attention: Patch coverage is 48.67925% with 136 lines in your changes missing coverage. Please review.

Project coverage is 54.65%. Comparing base (463a1f1) to head (91ef024).
Report is 4 commits behind head on main.

Files with missing lines Patch % Lines
robotoff/prediction/nutrition_extraction.py 57.44% 80 Missing ⚠️
robotoff/workers/tasks/import_image.py 8.82% 31 Missing ⚠️
robotoff/cli/main.py 13.33% 13 Missing ⚠️
robotoff/insights/importer.py 62.50% 6 Missing ⚠️
robotoff/triton.py 14.28% 6 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1437      +/-   ##
==========================================
- Coverage   54.79%   54.65%   -0.14%     
==========================================
  Files          84       85       +1     
  Lines        8359     8625     +266     
==========================================
+ Hits         4580     4714     +134     
- Misses       3779     3911     +132     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@raphael0202 raphael0202 merged commit 9ae5ff7 into main Oct 24, 2024
5 of 7 checks passed
@raphael0202 raphael0202 deleted the add-nutrient-extractor branch October 24, 2024 14:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

1 participant