Code refactor and prototype v.1#1
Merged
Merged
Conversation
There was a problem hiding this comment.
Pull Request Overview
This PR refactors and consolidates the image classification model comparison pipeline by removing legacy scripts and introducing a new, modular compressed_perception package.
- Removed all old per-experiment scripts and configuration files under
src/modelsand top‐levelvit_lr_*folders. - Added
src/compressed_perceptionmodules for data transformation, dataset preparation, training utilities, and comparison workflows. - Updated documentation (
docs/pipeline.md,README.md) and CI configurations (.yamllint, GitHub workflows) to align with the new structure.
Reviewed Changes
Copilot reviewed 50 out of 61 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| vit_lr_0.001/preprocessor_config.json | Removed outdated ViT preprocessing config |
| vit_lr_0.001/config.json | Removed old ViT model config |
| vit_lr_0.0005/preprocessor_config.json | Removed duplicate preprocessing config |
| vit_lr_0.0005/config.json | Removed duplicate model config |
| src/models/utils/util_methods.py | Deleted legacy utility methods |
| src/models/utils/util_classes.py & util_classes_test.py | Deleted old dataset and callback classes |
| src/models/utils/transforms.py & transforms_test.py | Removed legacy image transforms |
| src/models/model_comparison*.py (all variants) | Removed multiple legacy comparison scripts |
| src/compressed_perception/modules/data_transformation/image_transformation.py | Added unified image augmentation/degradation utilities |
| src/compressed_perception/modules/data_preparation/preparation.py | Added dataset filtering, balancing, splitting, transforms |
| src/compressed_perception/models/training/utils_methods.py | Added training metrics, disk checks, GPU profiling utilities |
| src/compressed_perception/models/training/utils_classes.py | Added dataset wrapper, model classes, and training callbacks |
| src/compressed_perception/models/training/constants.py | Defined model-type constants |
| src/compressed_perception/models/comparison/compare_lr_sweep.py | Added learning-rate sweep comparison script |
| src/compressed_perception/models/comparison/compare_baseline.py | Added baseline model comparison script |
| docs/pipeline.md | New pipeline documentation with usage and workflow overview |
| README.md | Updated project structure and media paths |
| .yamllint | Introduced custom YAML lint rules |
| .reuse/dep5.txt | Added REUSE compliance metadata |
| .github/workflows/pull_request.yml & build-and-test.yml | Added CI workflows for linting, REUSE compliance, link checks |
Comments suppressed due to low confidence (1)
docs/pipeline.md:52
- The markdown link is broken—replace
[model_comparison_models.py](...)with a backtick-wrapped command, e.g.,python model_comparison_models.py --resolution 224 ....
</details>
…prove transform handling
… hyperparameter tuning is natively supported via Hydra multiruns
…ect original (224×224) images
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Code refactor and prototype v.1
♻️ Current Situation & Problem
This PR refactors and consolidates the model comparison pipeline.
Enhancement: Improves code maintainability, extensibility, and experiment reproducibility.
Addresses performance and usability issues by streamlining dataset handling and optional augmentation transforms.
⚙️ Release Notes
📚 Documentation
📝 Code of Conduct & Contributing Guidelines
By submitting this pull request, you agree to follow our Coding Guidelines: