Refactor dataset and classification predictor code for improved readability and maintainability #5

Merged
iboubakri merged 1 commit from feature/adapt_inference into main 2025-11-21 05:36:32 +01:00
Owner
  • Updated assertions and comments in YOLODataset to enhance clarity.
  • Reformatted multi-line statements for better readability in YOLODataset.
  • Simplified the setup of transforms in ClassificationPredictor to always use classify_transforms for inference.
  • Improved image preprocessing in ClassificationPredictor by converting images to PIL format before applying transformations.
- Updated assertions and comments in YOLODataset to enhance clarity. - Reformatted multi-line statements for better readability in YOLODataset. - Simplified the setup of transforms in ClassificationPredictor to always use classify_transforms for inference. - Improved image preprocessing in ClassificationPredictor by converting images to PIL format before applying transformations.
Refactor dataset and classification predictor code for improved readability and maintainability
Some checks failed
Ultralytics CI / HUB (ubuntu-latest, 3.12) (pull_request) Has been skipped
Ultralytics CI / Benchmarks (yolo11n, ubuntu-latest, 3.12) (pull_request) Failing after 51s
Ultralytics CI / Tests (ubuntu-latest, 3.12, latest) (pull_request) Failing after 5s
Ultralytics CI / Tests (ubuntu-latest, 3.8, 1.8.0) (pull_request) Failing after 6s
Ultralytics CI / Conda (ubuntu-latest, 3.12) (pull_request) Has been skipped
Publish Docs / Docs (pull_request) Has been skipped
CLA Assistant / CLA (pull_request_target) Has been skipped
Ultralytics Actions / actions (pull_request) Failing after 1s
Ultralytics CI / Benchmarks (yolo11n, macos-latest, 3.12) (pull_request) Has been cancelled
Ultralytics CI / Benchmarks (yolo11n, ubuntu-24.04-arm, 3.12) (pull_request) Has been cancelled
Ultralytics CI / Tests (macos-latest, 3.12, latest) (pull_request) Has been cancelled
Ultralytics CI / Tests (ubuntu-24.04-arm, 3.12, latest) (pull_request) Has been cancelled
Ultralytics CI / Tests (windows-latest, 3.12, latest) (pull_request) Has been cancelled
Ultralytics CI / GPU (pull_request) Has been cancelled
Ultralytics CI / RaspberryPi (pull_request) Has been cancelled
Ultralytics CI / NVIDIA_Jetson (JetPack5.1.2, 1.23.5, https://github.com/ultralytics/assets/releases/download/v0.0.0/onnxruntime_gpu-1.16.3-cp38-cp38-linux_aarch64.whl, 3.8, jetson-jp512, https://github.com/ultralytics/assets/releases/download/v0.0.0/torch-2.2.0-cp38-c… (pull_request) Has been cancelled
Ultralytics CI / NVIDIA_Jetson (JetPack6.2, 1.26.4, https://github.com/ultralytics/assets/releases/download/v0.0.0/onnxruntime_gpu-1.20.0-cp310-cp310-linux_aarch64.whl, 3.10, jetson-jp62, https://github.com/ultralytics/assets/releases/download/v0.0.0/torch-2.5.0a0+872d… (pull_request) Has been cancelled
Ultralytics CI / Summary (pull_request) Has been cancelled
1b37460073
- Updated assertions and comments in YOLODataset to enhance clarity.
- Reformatted multi-line statements for better readability in YOLODataset.
- Simplified the setup of transforms in ClassificationPredictor to always use classify_transforms for inference.
- Improved image preprocessing in ClassificationPredictor by converting images to PIL format before applying transformations.
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
MedusAI/ultralytics!5
No description provided.