동준 | 경윤 | 영석 | 태영 | 태성 | 세린 |
Member | Roles |
---|---|
동준 | EDA, Detectron2 k-fold, 빠른 테스트 위한 RT-DETR 선정, Class 세부 분리 실험, 결과 시각화 |
영석 | EDA, Streamlit으로 데이터 시각화 및 양상블, detectron2 Albumentation, mmdetection k-fold |
경윤 | EDA, 라이브러리 구조파악, Model 선택, 가설 설정 및 실험 |
태영 | EDA, 라이브러리 구조파악, Data 정제, Model 선택, 가설 설정 및 augmentation 실험 |
세린 | EDA, Detectron2 k-fold |
태성 | Model 선택, 템플릿 코드 작성, 가설 설정 및 실험, 결과 시각화 |
This project is part of BoostCamp AI Tech and focuses on developing an object detection model specifically designed to identify and classify various types of trash. The primary goal is to enhance waste sorting efficiency by accurately detecting different categories of waste materials in images.
This project utilizes a dataset specifically designed for trash classification. The dataset contains labeled images of various types of waste, divided into training and test sets.
- Training Images: 4883
- Test Images: 4871
- Classes: 10 categories of trash items, with counts as follows:
- General trash: 3966
- Paper: 6352
- Paper pack: 897
- Metal: 936
- Glass: 982
- Plastic: 2943
- Styrofoam: 1263
- Plastic bag: 5178
- Battery: 159
- Clothing: 468
Each image in the dataset is annotated with bounding boxes for these categories to facilitate the training of an object detection model.
Category | Details | Category | Details |
---|---|---|---|
Hardware | GPU: V100 32GB × 4 | Python | 3.10 |
CUDA | 11.6 | PyTorch | 1.12 |
PyTorch Lightning | 1.8 | Libraries | MMDetection(3.3.0), Detectron2(0.6), Ultralytics(8.3.23) |
Collaboration Tools | Notion, WandB |
MMDetection
- please refer to the configuration file in mmDetection/configs for details.
- To train the model, run the following command:
python tools/train.py configs/faster_rcnn/faster-rcnn_r50_fpn_1x_coco.py
- To test the model, run the following command:
python tools/test.py --work-dir "save/dir" "path/pth"
- see
mmdetection/configs/
to adjust various training and model parameters
Detectron2
- please refer to the configuration file in detectron2/configs for details.
- Detectron2 provides pre-defined model architectures. Customize by modifying
config.yaml
and adding models to thebackbone
folder.
- Run the following command to train and test the model:
python lightning_train_net_custom.py --config-file ../configs/COCO-Detection/faster_rcnn_R_101_FPN_3x_TRASH.yaml --num-gpus 1
Ultralytics
- Data Augmentation
Use OpenCV-based augmentation methods and specify additional transformations inselect_transforms.py
.
- Ultralytics models (like YOLOv5/YOLOv8) are configured using
ultralytics/config.yaml
. You can adjust the architecture by changing the model type and parameters in this file.
- Use the following command to start training and testing:
python train.py --data data.yaml --cfg cfg/yolov5.yaml --weights weights/yolov5s.pt
-
Customize
ultralytics.yaml
for batch size, epochs, learning rate, and other parameters.batch_size: 64 epochs: 50 data: ./data.yaml weights: yolov5s.pt imgsz: 640 device: 0 project: yolov5 name: exp cache: True optimizer: SGD