-
Notifications
You must be signed in to change notification settings - Fork 139
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 ShiftAnalyzer to compute covariate and label shift between two datasets #855
Conversation
datumaro/plugins/openvino_plugin/samples/ssd_mobilenet_coco_detection_interp.py
Outdated
Show resolved
Hide resolved
datumaro/plugins/openvino_plugin/samples/ssd_person_detection_interp.py
Outdated
Show resolved
Hide resolved
datumaro/plugins/openvino_plugin/samples/ssd_person_vehicle_bike_detection_interp.py
Outdated
Show resolved
Hide resolved
datumaro/plugins/openvino_plugin/samples/ssd_vehicle_detection_interp.py
Outdated
Show resolved
Hide resolved
if model_name: | ||
model_dir = os.path.join(os.path.expanduser("~"), ".cache", "datumaro") | ||
if not osp.exists(model_dir): | ||
os.makedirs(model_dir) | ||
|
||
# Please visit open-model-zoo repository for OpenVINO public models if you are interested in | ||
# https://github.com/openvinotoolkit/open_model_zoo/blob/master/models/public/index.md | ||
url_folder = "https://storage.openvinotoolkit.org/repositories/datumaro/models/" | ||
|
||
description = osp.join(model_dir, model_name + ".xml") | ||
if not osp.exists(description): | ||
cached_description_url = osp.join(url_folder, model_name + ".xml") | ||
log.info('Downloading: "{}" to {}\n'.format(cached_description_url, description)) | ||
self._download_file(cached_description_url, description) | ||
|
||
weights = osp.join(model_dir, model_name + ".bin") | ||
if not osp.exists(weights): | ||
cached_weights_url = osp.join(url_folder, model_name + ".bin") | ||
log.info('Downloading: "{}" to {}\n'.format(cached_weights_url, weights)) | ||
self._download_file(cached_weights_url, weights) | ||
|
||
if not interpreter: | ||
openvino_plugin_samples_dir = get_samples_path() | ||
interpreter = osp.join(openvino_plugin_samples_dir, model_name + "_interp.py") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think that it is more appropriate to move the model download functionality to _OpenvinoImporter
but leave it in this PR.
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## develop #855 +/- ##
===========================================
- Coverage 78.59% 78.57% -0.02%
===========================================
Files 201 205 +4
Lines 24534 24726 +192
Branches 4957 4985 +28
===========================================
+ Hits 19282 19428 +146
- Misses 4141 4180 +39
- Partials 1111 1118 +7
Flags with carried forward coverage won't be shown. Click here to find out more.
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
Summary
How to test
Checklist
develop
branchLicense
Feel free to contact the maintainers if that's a concern.