-
Notifications
You must be signed in to change notification settings - Fork 46
ITEP-31006 Anomaly Reduction clean up #316
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
Conversation
…o aurelien/anomaly-reduction-cleanup # Conflicts: # interactive_ai/data_migration/migration/changelog/30.json
…o aurelien/anomaly-reduction-cleanup # Conflicts: # interactive_ai/services/director/app/communication/controllers/model_test_controller.py # interactive_ai/services/director/app/communication/views/annotation_rest_views.py # interactive_ai/services/director/app/communication/views/model_template_rest_views.py # interactive_ai/services/director/app/communication/views/performance_rest_views.py # interactive_ai/services/director/app/features/feature_flag_provider.py # interactive_ai/services/director/tests/unit/communication/rest_controllers/test_model_test_controller.py # interactive_ai/services/director/tests/unit/communication/rest_views/test_annotation_rest_views.py # interactive_ai/services/director/tests/unit/communication/rest_views/test_model_template_rest_views.py # interactive_ai/services/director/tests/unit/communication/rest_views/test_performance_rest_views.py # interactive_ai/services/director/tests/unit/communication/test_rest_datamodels.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.
Pull Request Overview
This PR cleans up obsolete anomaly reduction logic by removing the FEATURE_FLAG_ANOMALY_REDUCTION flag from various parts of the code and unifying anomaly task types into a single ANOMALY enum value. In addition, it introduces a new data migration script to update legacy anomaly representations and bumps the project data version.
- Removed obsolete feature flag checks and related test fixtures.
- Updated the anomaly task type to a unified ANOMALY value in enums and test expectations.
- Added a migration script (with corresponding tests and metadata) to reduce anomaly tasks.
Reviewed Changes
Copilot reviewed 48 out of 48 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| interactive_ai/services/director/tests/unit/... | Removed obsolete feature flag imports and calls in tests. |
| interactive_ai/services/dataset_ie/app/... | Updated feature flag usage and project type mapping. |
| interactive_ai/libs/iai_core_py/iai_core/utils/project_builder.py | Removed anomaly-specific renaming logic to align with streamlined task type representation. |
| interactive_ai/data_migration/migration/scripts/reduce_anomaly_tasks.py | New migration script for anomaly reduction with recursive field updates. |
| interactive_ai/libs/iai_core_py/iai_core/entities/... | Added the unified ANOMALY task type and updated related constants. |
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.
Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.
JortBergfeld
left a comment
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, I am just wondering why a new domain had to be introduced in this PR, and why the old ones are not removed.
…o aurelien/anomaly-reduction-cleanup # Conflicts: # interactive_ai/libs/iai_core_py/iai_core/versioning/data_version.txt
📝 Description
Adds a data migrations script to clean up the database of local anomaly references.
The following collections are affected
["annotation_scene", "annotation_scene_state", "project", "label", "label_schema", "model", "model_storage", "task_node"]Removes the
FEATURE_FLAG_ANOMALY_REDUCTIONand cleans up remaining code related to local anomaly tasks.The dataset IE still supports
GetiProjectType.ANOMALY_CLASSIFICATIONGetiProjectType.ANOMALY_DETECTIONGetiProjectType.ANOMALY_SEGMENTATIONso that old exported datasets can be imported to the new
GetProjectType.ANOMALY✨ Type of Change
Select the type of change your PR introduces:
🧪 Testing Scenarios
Describe how the changes were tested and how reviewers can test them too:
✅ Checklist
Before submitting the PR, ensure the following: