Skip to content

Feedback #1

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

Open
wants to merge 182 commits into
base: feedback
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
182 commits
Select commit Hold shift + click to select a range
ef67e35
Setting up GitHub Classroom Feedback
github-classroom[bot] Sep 30, 2024
40a752f
Create README.md
Batwan01 Sep 30, 2024
3a2e3f7
Update README.md
Batwan01 Sep 30, 2024
1c58d8b
Update README.md
Batwan01 Oct 1, 2024
c1e1453
Output metric.json to tensorboard form
nOctaveLay Oct 2, 2024
6fa3830
feat: YOLOv5 초기 구현 Issue #11 진행 중
Batwan01 Oct 2, 2024
41132e0
Merge pull request #12 from boostcampaitech7/Batwan01/issue11
Batwan01 Oct 2, 2024
8cc2779
Update README.md
Batwan01 Oct 2, 2024
3b94d7f
Detectron2 모듈화
nOctaveLay Oct 3, 2024
0952bdc
seed 고정 추가
nOctaveLay Oct 3, 2024
8074f9d
custom_train 이름 변경 ->train_and_test.py
nOctaveLay Oct 3, 2024
69d27df
seed test 완료
nOctaveLay Oct 3, 2024
9c7477c
Detectron2 모듈화 및 Detectron2 upload
nOctaveLay Oct 3, 2024
f44b6f5
Detectron2 모듈화
nOctaveLay Oct 3, 2024
40fc02e
change practical form
nOctaveLay Oct 3, 2024
a109c6b
Merge pull request #14 from boostcampaitech7/nOctaveLay/issue8
nOctaveLay Oct 3, 2024
b6ac415
feat : 현재 detect 구현 중 #13
Batwan01 Oct 4, 2024
e6365d7
feat : yolov5 detect_code #11
Batwan01 Oct 4, 2024
8412968
acc 0
Batwan01 Oct 4, 2024
da770d8
mode dir
Batwan01 Oct 4, 2024
e920d7c
feat : detect 코드 #13
Batwan01 Oct 4, 2024
afe18f1
Merge pull request #16 from boostcampaitech7/Batwan01/issue13
Batwan01 Oct 4, 2024
f61ef3d
split train_set and validation_set
nOctaveLay Oct 4, 2024
9011d76
Add comment by code
nOctaveLay Oct 4, 2024
1c61239
COCOEvaluator의 AP가 전부 nan으로 나오는 문제
nOctaveLay Oct 6, 2024
20937cc
change "faster_rcnn_X_101_32x8d_FPN_3x"
nOctaveLay Oct 6, 2024
1df50e9
Merge pull request #18 from boostcampaitech7/nOctaveLay/issue17
nOctaveLay Oct 6, 2024
3ebfad4
Merge pull request #19 from boostcampaitech7/nOctaveLay/issue9
nOctaveLay Oct 7, 2024
25ca932
del
Batwan01 Oct 7, 2024
3f31fe0
detect_ori
Batwan01 Oct 7, 2024
3099a1f
feat : detect.py를 만들기 위한 과정 #13
Batwan01 Oct 7, 2024
1ad03ea
detect.py 구현 #13 - acc : 0.2277
Batwan01 Oct 7, 2024
c28ad66
Merge remote-tracking branch 'origin/HEAD' into Batwan01/issue20
Batwan01 Oct 7, 2024
4d85f47
Merge pull request #21 from boostcampaitech7/Batwan01/issue20
Batwan01 Oct 7, 2024
df27316
feat : detect.py 구현
Batwan01 Oct 7, 2024
30a8b02
feat : prec.py #13
Batwan01 Oct 7, 2024
6a8004b
feat : detect.py 구현
Batwan01 Oct 7, 2024
ea4c594
feat : YOLOv5 구현
Batwan01 Oct 7, 2024
e1fd078
del
Batwan01 Oct 7, 2024
3661d78
Merge remote-tracking branch 'origin/HEAD' into Batwan01/issue20
Batwan01 Oct 7, 2024
a184c32
feat : detect.py 구현
Batwan01 Oct 7, 2024
dc9cf7d
feat : detect.py #13
Batwan01 Oct 7, 2024
34c0021
MMDetection baseline 코드
Two-Silver Oct 7, 2024
7699500
train.py (validation, tensorboard 등 추가)
Two-Silver Oct 7, 2024
891e35b
test.py
Two-Silver Oct 7, 2024
897f120
delete
Two-Silver Oct 7, 2024
77b8846
train.py (validation, tensorboard 등 추가)
Two-Silver Oct 7, 2024
4e82019
test.py
Two-Silver Oct 7, 2024
00d6b05
Merge branch 'Two-Silver/issue22' into main
Two-Silver Oct 7, 2024
daa1998
delete
Two-Silver Oct 7, 2024
82c8b78
cascasde_rcnn_r50_fpn_1x_coco 실험
Two-Silver Oct 7, 2024
82e2fb7
cascadeRCNN 백본 모델 SwinS 변경 config 파일 추가
Two-Silver Oct 7, 2024
311cbb4
cascade_rcnn_SwinS_fpn_1x_coco 실험
Two-Silver Oct 7, 2024
9bc2737
cascadeRCNN 백본 모델 SwinL 변경 config 파일 추가
Two-Silver Oct 7, 2024
38efffa
cascade_rcnn_swinL_fpn_20e_coco 실험
Two-Silver Oct 7, 2024
c87341c
feat : Co-DETR 구현
taehan79-kim Oct 7, 2024
71d37dc
feat : Co-DETR co_dino_5scale_swin_large_16e_o365tococo 사전 학습 모델 테스트 #27
taehan79-kim Oct 7, 2024
9ac426c
Co-DETR : From Scratch Learning
taehan79-kim Oct 7, 2024
4151906
Co-DETR : co_dino_5scale_vit_large_coco 테스트
taehan79-kim Oct 7, 2024
6b38b9f
feat : Co-DETR co_dino_5scale_vit_large_coco 테스트
taehan79-kim Oct 7, 2024
eb55393
feat : co_dino_5scale_lsj_swin_large_3x_coco_12e
taehan79-kim Oct 9, 2024
8abf61c
del
Batwan01 Oct 10, 2024
a1a85b1
feat : detect code 변경 #32
Batwan01 Oct 10, 2024
581c16b
del
Batwan01 Oct 10, 2024
ce84c56
rename : 폴더 위치 변경 #11
Batwan01 Oct 10, 2024
9c5513b
fix : csv 형식에 맞게 write_to_csv 메서드 수정 Fixes #32
Batwan01 Oct 10, 2024
0d2c57e
Merge pull request #34 from boostcampaitech7:Batwan01/issue32
Batwan01 Oct 10, 2024
aa1fc0f
Merge branch 'Batwan01/issue32' into main
Batwan01 Oct 10, 2024
1138b58
Merge branch 'main' of https://github.com/boostcampaitech7/level2-obj…
Batwan01 Oct 10, 2024
bad8ad2
Merge branch 'main' into taehan79-kim/issue27
taehan79-kim Oct 10, 2024
e7763b1
Merge branch 'taehan79-kim/issue27' into main
taehan79-kim Oct 10, 2024
2d52a47
feat : copy train.py, test.py
taehan79-kim Oct 10, 2024
f88721a
Update README.md
Batwan01 Oct 10, 2024
d195174
Update README.md
Batwan01 Oct 10, 2024
66c9853
feat : main 코드들 가져오기 #26
taehan79-kim Oct 10, 2024
b84113d
feat : Co-DETR img size 변경 #26
taehan79-kim Oct 10, 2024
d662254
feat : img size memory test Co-DETR : CoCo #26
taehan79-kim Oct 10, 2024
0193536
feat : img_size, batch_size, eta test #26
taehan79-kim Oct 10, 2024
3f51d09
feat : co_dino_5scale_vit_large_coco, img_size 변경 #26
taehan79-kim Oct 10, 2024
969b0ba
train/val set 분리
nOctaveLay Oct 10, 2024
53bcb29
Test 완료, Co-DETR로 이동
nOctaveLay Oct 10, 2024
88d0cda
main module 수정
nOctaveLay Oct 10, 2024
12bd849
feat: k_fold_train.py 추가
nOctaveLay Oct 10, 2024
2ebb5f2
Merge branch 'main' into nOctaveLay/issue36
nOctaveLay Oct 10, 2024
a3860d4
Merge pull request #37 from boostcampaitech7/nOctaveLay/issue36
nOctaveLay Oct 10, 2024
74756cf
feat: split_train_and_val() main()을 n_splits에 맞게 작동되도록 변경
nOctaveLay Oct 11, 2024
5337291
draw_bounding.py 구현 Fixes #40
Batwan01 Oct 11, 2024
24d459b
Merge pull request #41 from boostcampaitech7:Batwan01/issue40
Batwan01 Oct 11, 2024
ffb5851
feat : CSV 기능 수정 #11
Batwan01 Oct 11, 2024
a93260f
Merge branch 'Batwan01/issue40' into main
Batwan01 Oct 11, 2024
3babd42
Merge branch 'main' of https://github.com/boostcampaitech7/level2-obj…
Batwan01 Oct 11, 2024
7611b7d
Update README.md
Batwan01 Oct 11, 2024
f2acf22
feat : co_dino_5scale_vit_large_coco_e16 #26
taehan79-kim Oct 11, 2024
3f24d31
UniverseNet 패키지 추가 feat #42
nOctaveLay Oct 12, 2024
5efb7f5
Neck: sepc 추가 feat UniverseNet #42
Two-Silver Oct 12, 2024
b320de4
gfl_head, sepc 추가 UniverseNet feat #42
Two-Silver Oct 12, 2024
d23ab55
UniverseNet config 파일, model 수정 fix #42
Two-Silver Oct 12, 2024
b67f188
update .gitignore
ch-leem Oct 14, 2024
e733433
UniverseNet fixes #42
Two-Silver Oct 14, 2024
3033208
k-fold Co-DETR #38
Two-Silver Oct 14, 2024
76c1abf
Merge branch 'Two-Silver/issue42' into main
Two-Silver Oct 14, 2024
567f589
weighted_boxes_fusion 구현
nOctaveLay Oct 14, 2024
2e9b32e
style: 이미지 사이즈 넣기
nOctaveLay Oct 14, 2024
93e7a3d
Merge pull request #47 from boostcampaitech7/nOctaveLay/issue46
nOctaveLay Oct 14, 2024
10c7609
Merge branch 'main' into nOctaveLay/issue48
nOctaveLay Oct 14, 2024
29742b0
weighted_boxes_fusion 구현 버그
nOctaveLay Oct 14, 2024
8025326
Merge pull request #49 from boostcampaitech7/nOctaveLay/issue48
nOctaveLay Oct 14, 2024
70a3688
Anchor Box 최적화
Batwan01 Oct 15, 2024
6845af0
feat : print 횟수 조정 #13
Batwan01 Oct 15, 2024
a8dfbb9
Merge remote-tracking branch 'origin/HEAD' into Batwan01/issue44
Batwan01 Oct 15, 2024
d1af64a
Merge pull request #50 from boostcampaitech7/Batwan01/issue44
Batwan01 Oct 15, 2024
8c8b3ef
anchorbox.py 구현 Fixes #44
Batwan01 Oct 15, 2024
171796e
feat : anchor 적합하게 변경 #44
Batwan01 Oct 15, 2024
d61b20e
feat : anchor box 최적화 코드 #44
Batwan01 Oct 15, 2024
2d2cb35
feat : datset_split.py 구현 Fixes #51
Batwan01 Oct 15, 2024
ee78978
Merge pull request #52 from boostcampaitech7/Batwan01/issue51
Batwan01 Oct 15, 2024
efd6483
rename : copy train_new.py
taehan79-kim Oct 15, 2024
34d784a
feat : degrees, flipud Fixes #54
Batwan01 Oct 16, 2024
399be30
feat : count 기능 추가 #32
Batwan01 Oct 16, 2024
b949fb9
feat : best hyp Fixes #45
Batwan01 Oct 17, 2024
581cb0d
feat : del count #13
Batwan01 Oct 17, 2024
86eea7d
rename : detect_1.py
Batwan01 Oct 17, 2024
fc2d9fc
feat : YOLOv11 구현 Fixes #57
Batwan01 Oct 17, 2024
768932e
Merge pull request #59 from boostcampaitech7:Batwan01/issue57
Batwan01 Oct 17, 2024
a4c6903
rename: ensemble.py 위치 이동
nOctaveLay Oct 17, 2024
4d5ddec
rename: team convention 맞춤 #58
nOctaveLay Oct 17, 2024
3f58856
Merge pull request #61 from boostcampaitech7/nOctaveLay/issue58
nOctaveLay Oct 17, 2024
05efd08
style: path 경로를 깔끔하게 만듬.
nOctaveLay Oct 17, 2024
733c8c3
Merge pull request #65 from boostcampaitech7/nOctaveLay/issue60
nOctaveLay Oct 17, 2024
f2e3b82
fix : image 범위를 벗어나는 문제 해결 #66
nOctaveLay Oct 17, 2024
8d70a20
Merge pull request #68 from boostcampaitech7/nOctaveLay/issue66
nOctaveLay Oct 17, 2024
8522c77
feat: ensemble 결과를 저장하는 폴더와 그렇지 않은 폴더들을 분리
nOctaveLay Oct 17, 2024
107aa4e
Ensemble Test
nOctaveLay Oct 17, 2024
f1ded7e
Merge pull request #70 from boostcampaitech7/nOctaveLay/issue69
nOctaveLay Oct 17, 2024
0a1377d
feat : yolo
Batwan01 Oct 18, 2024
f3325ef
Merge pull request #72 from boostcampaitech7/Batwan01/issue57
Batwan01 Oct 18, 2024
72323ad
feat : co_dino, Swinv2_L Fixes #71
Batwan01 Oct 18, 2024
bbc2310
Merge pull request #73 from boostcampaitech7:Batwan01/issue71
Batwan01 Oct 18, 2024
cdc4484
feat : image_size에 따른 test #56
taehan79-kim Oct 18, 2024
90e0c72
Merge branch 'main' into taehan79-kim/issue26
taehan79-kim Oct 18, 2024
7a1979c
Merge branch 'taehan79-kim/issue26' into main
taehan79-kim Oct 18, 2024
45f2733
co-DETR k-fold
nOctaveLay Oct 18, 2024
ef7f286
Merge pull request #75 from boostcampaitech7/nOctaveLay/issue74
nOctaveLay Oct 18, 2024
01aa41a
Ensemble 혼동을 주는 표현 제거
nOctaveLay Oct 21, 2024
1efd1fd
Merge pull request #82 from boostcampaitech7/nOctaveLay/issue81
nOctaveLay Oct 21, 2024
35e0ed0
feat : model prediction & PR curve visualization
taehan79-kim Oct 22, 2024
5438176
feat : csv file sorting & normalization 코드 추가
taehan79-kim Oct 22, 2024
95d2f8a
fix: 모델 전부가 bounding box를 예측하지 못했을 때 발생하는 문제 해결 #86
nOctaveLay Oct 23, 2024
a907550
style: assert 코드를 만들게 되면 강제로라도 변환할 수 없음.
nOctaveLay Oct 23, 2024
2b31fd4
Merge pull request #87 from boostcampaitech7/nOctaveLay/issue86
nOctaveLay Oct 23, 2024
114bf52
fix: ensemble.py에서 버그 발생 시 예측 파일을 남기는 기능 추가 #88
nOctaveLay Oct 23, 2024
02bc3d3
refactor: 중복되는 부분 제거 #88
nOctaveLay Oct 23, 2024
947b5f9
Merge pull request #89 from boostcampaitech7/nOctaveLay/issue88
nOctaveLay Oct 23, 2024
2ba90c5
feat: ensemble할 target을 저장하는 method 만들기
nOctaveLay Oct 24, 2024
2681b79
feat: error message도 json 파일에 추가
nOctaveLay Oct 24, 2024
385ab1b
fix : 강제로 종료시켰을 때 exception이 탐지하지 않는 문제 해결
nOctaveLay Oct 24, 2024
1de6193
fix: 강제 종료시엔 error message를 출력하지 않는 문제 해결
nOctaveLay Oct 24, 2024
d3722cd
Update README.md
Batwan01 Oct 24, 2024
9a99195
refactor: 어떤 파일을 앙상블 했는지 알아보기 쉽게 만든다.
nOctaveLay Oct 24, 2024
4d62d0a
refactor: 문맥상 이상한 부분을 수정
nOctaveLay Oct 24, 2024
8e27669
remove: 샘플 파일들 삭제
nOctaveLay Oct 24, 2024
f1ecbbf
Merge pull request #91 from boostcampaitech7/nOctaveLay/issue90
nOctaveLay Oct 24, 2024
2bbdd89
feat: make func: make_pseudo_dataframe
nOctaveLay Oct 25, 2024
5dac6bb
refactor: make_pseudo_dataframe
nOctaveLay Oct 25, 2024
c9014b4
rename: change_pascal_to_coco
nOctaveLay Oct 25, 2024
270d484
feat: 저장할 곳을 지정하게끔 만듬 output #92
nOctaveLay Oct 25, 2024
f30b210
Merge pull request #93 from boostcampaitech7/nOctaveLay/issue92
nOctaveLay Oct 25, 2024
e4a7ebb
Ensemble.py 속도 개선 #94
nOctaveLay Oct 27, 2024
dfb6b0f
fix : csv 파일을 여러번 불러오는 문제 해결 Ensemble.py 속도 개선 #94
nOctaveLay Oct 27, 2024
5863749
Merge pull request #95 from boostcampaitech7/nOctaveLay/issue94
nOctaveLay Oct 27, 2024
c50c6dd
docs : README 맨 윗쪽에 명시되어 있던 Commit Message Header를 아래로 옮김
nOctaveLay Oct 28, 2024
b0edeee
docs: Voting 명칭 변경
nOctaveLay Oct 28, 2024
f9b2740
docs: csv 위치 변경
nOctaveLay Oct 28, 2024
455dbce
docs : branch name convention 추가
nOctaveLay Oct 28, 2024
eed5f83
remove: 불필요한 파일 제거 meta_data.md #96
nOctaveLay Oct 28, 2024
7b118dd
docs: branch name 설명 수정
nOctaveLay Oct 28, 2024
e9dad66
Merge pull request #97 from boostcampaitech7/nOctaveLay/issue96
Batwan01 Oct 28, 2024
c24a8a5
remove: double code
nOctaveLay Oct 28, 2024
b2d22c9
Delete tools/ensemble/non_maximum_weighted_result.csv
nOctaveLay Nov 4, 2024
fbe2368
Delete tools/target/output (5).csv
nOctaveLay Nov 4, 2024
80a949f
Delete tools/target/output (6).csv
nOctaveLay Nov 4, 2024
1797383
Update README.md
Batwan01 Mar 25, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
The diff you're trying to view is too large. We only load the first 3000 changed files.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
data.tar.gz
dataset/
125 changes: 125 additions & 0 deletions Co-DETR/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,125 @@
# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
*$py.class

# C extensions
*.so

# Distribution / packaging
.Python
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
wheels/
*.egg-info/
.installed.cfg
*.egg
MANIFEST

# PyInstaller
# Usually these files are written by a python script from a template
# before PyInstaller builds the exe, so as to inject date/other infos into it.
*.manifest
*.spec

# Installer logs
pip-log.txt
pip-delete-this-directory.txt

# Unit test / coverage reports
htmlcov/
.tox/
.coverage
.coverage.*
.cache
nosetests.xml
coverage.xml
*.cover
.hypothesis/
.pytest_cache/

# Translations
*.mo
*.pot

# Django stuff:
*.log
local_settings.py
db.sqlite3

# Flask stuff:
instance/
.webassets-cache

# Scrapy stuff:
.scrapy

# Sphinx documentation
docs/en/_build/
docs/zh_cn/_build/

# PyBuilder
target/

# Jupyter Notebook
.ipynb_checkpoints

# pyenv
.python-version

# celery beat schedule file
celerybeat-schedule

# SageMath parsed files
*.sage.py

# Environments
.env
.venv
env/
venv/
ENV/
env.bak/
venv.bak/

# Spyder project settings
.spyderproject
.spyproject

# Rope project settings
.ropeproject

# mkdocs documentation
/site

# mypy
.mypy_cache/

data/
data
.vscode
.idea
.DS_Store

# custom
*.pkl
*.pkl.json
*.log.json
docs/modelzoo_statistics.md
mmdet/.mim
work_dirs/

# Pytorch
*.pth
*.py~
*.sh~

9 changes: 9 additions & 0 deletions Co-DETR/.readthedocs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
version: 2

formats: all

python:
version: 3.7
install:
- requirements: requirements/docs.txt
- requirements: requirements/readthedocs.txt
21 changes: 21 additions & 0 deletions Co-DETR/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2022 SenseTime X-Lab

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
151 changes: 151 additions & 0 deletions Co-DETR/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,151 @@
# DETRs with Collaborative Hybrid Assignments Training

[![PWC](https://img.shields.io/endpoint.svg?url=https://paperswithcode.com/badge/detrs-with-collaborative-hybrid-assignments/object-detection-on-coco-minival)](https://paperswithcode.com/sota/object-detection-on-coco-minival?p=detrs-with-collaborative-hybrid-assignments)
[![PWC](https://img.shields.io/endpoint.svg?url=https://paperswithcode.com/badge/detrs-with-collaborative-hybrid-assignments/object-detection-on-coco)](https://paperswithcode.com/sota/object-detection-on-coco?p=detrs-with-collaborative-hybrid-assignments)
[![PWC](https://img.shields.io/endpoint.svg?url=https://paperswithcode.com/badge/detrs-with-collaborative-hybrid-assignments/object-detection-on-lvis-v1-0-minival)](https://paperswithcode.com/sota/object-detection-on-lvis-v1-0-minival?p=detrs-with-collaborative-hybrid-assignments)
[![PWC](https://img.shields.io/endpoint.svg?url=https://paperswithcode.com/badge/detrs-with-collaborative-hybrid-assignments/object-detection-on-lvis-v1-0-val)](https://paperswithcode.com/sota/object-detection-on-lvis-v1-0-val?p=detrs-with-collaborative-hybrid-assignments)
[![PWC](https://img.shields.io/endpoint.svg?url=https://paperswithcode.com/badge/detrs-with-collaborative-hybrid-assignments/instance-segmentation-on-lvis-v1-0-val)](https://paperswithcode.com/sota/instance-segmentation-on-lvis-v1-0-val?p=detrs-with-collaborative-hybrid-assignments)


[[📖 Paper](https://arxiv.org/pdf/2211.12860.pdf)] [[🤗 Huggingface Model](https://huggingface.co/zongzhuofan)]

## News

* ***[04/22/2024]*** We release a new MLLM framework [MoVA](https://github.com/TempleX98/MoVA), which adopts Co-DETR as the vision and achieves state-of-the-art performance on multimodal benchmarks.
* ***[10/19/2023]*** Our SOTA model Co-DETR w/ ViT-L is released now. Please refer to [our huggingface page](https://huggingface.co/zongzhuofan) for more details.
* ***[09/10/2023]*** We release LVIS inference configs and a stronger LVIS detector that achieves **64.5 box AP**.
* ***[08/21/2023]*** Our O365 pre-trained Co-DETR with Swin-L achieves **64.8 AP** on COCO test-dev. The config and weights are released.
* ***[07/20/2023]*** Code for Co-DINO is released: **55.4 AP** with ResNet-50 and **60.7 AP** with Swin-L.
* ***[07/14/2023]*** Co-DETR is accepted to ICCV 2023!
* ***[07/12/2023]*** We finetune Co-DETR on LVIS and achieve the best results **without TTA**: **72.0 box AP** and **59.7 mask AP** on LVIS minival, **68.0 box AP** and **56.0 mask AP** on LVIS val. For instance segmentation, we report the performance of the auxiliary mask branch.
* ***[07/03/2023]*** Co-DETR with [ViT-L](https://github.com/baaivision/EVA/tree/master/EVA-02) **(304M parameters)** sets a new record of <strike>65.6</strike> **66.0 AP** on COCO test-dev, surpassing the previous best model [InternImage-G](https://github.com/OpenGVLab/InternImage) **(~3000M parameters)**. It is the **first model to exceed 66.0 AP on COCO test-dev**.
* ***[07/03/2023]*** Code for Co-Deformable-DETR is released.
* ***[04/05/2023]*** [HoP](https://github.com/Sense-X/HoP) leverages Co-DETR as the backbone and achieves new SOTA performance on [nuScenes 3D detection leaderboard](https://www.nuscenes.org/object-detection?externalData=all&mapData=all&modalities=Camera).
* ***[11/19/2022]*** We achieved 64.4 AP on COCO minival and 64.5 AP on COCO test-dev with only ImageNet-1K as pre-training data. Codes will be available soon.


## Introduction

![teaser](figures/framework.png)

In this paper, we present a novel collaborative hybrid assignments training scheme, namely Co-DETR, to learn more efficient and effective DETR-based detectors from versatile label assignment manners.
1. **Encoder optimization**: The proposed training scheme can easily enhance the encoder's learning ability in end-to-end detectors by training multiple parallel auxiliary heads supervised by one-to-many label assignments.
2. **Decoder optimization**: We conduct extra customized positive queries by extracting the positive coordinates from these auxiliary heads to improve attention learning of the decoder.
3. **State-of-the-art performance**: Co-DETR with [ViT-L](https://github.com/baaivision/EVA/tree/master/EVA-02) (304M parameters) is **the first model to achieve 66.0 AP on COCO test-dev.**

![teaser](figures/performance.png)

## Model Zoo

### Objects365 pre-trained Co-DETR

| Model | Backbone | Aug | Dataset | box AP (val) | mask AP (val) | box AP (test) | mask AP (test) | Config | Download |
| ------ | -------- | --- | ------- | ------------ | ------------- | ------ | ------------- | ------ | ----- |
| Co-DINO | Swin-L | DETR | COCO | 64.1 | - | - | - | [config](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_dino/co_dino_5scale_swin_large_16e_o365tococo.py) | [model](https://drive.google.com/drive/folders/1nAXOkzqrEgz-YnXxIEs4d5j9li_kmrnv?usp=sharing) |
| Co-DINO | ViT-L | DETR | COCO | 65.9 | - | 66.0 | - | [config](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_dino_vit/co_dino_5scale_vit_large_coco.py) | [model](https://huggingface.co/zongzhuofan) |
| Co-DINO | Swin-L | LSJ | LVIS | 64.5 | - | - | - | [config (test)](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_dino/co_dino_5scale_lsj_swin_large_16e_o365tolvis.py) | [model](https://drive.google.com/drive/folders/1nAXOkzqrEgz-YnXxIEs4d5j9li_kmrnv?usp=sharing) |
| Co-DINO | ViT-L | LSJ | LVIS | 68.0 | - | - | - | [config (test)](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_dino_vit/co_dino_5scale_lsj_vit_large_lvis.py) | [model](https://huggingface.co/zongzhuofan) |
| Co-DINO-Inst | ViT-L | LSJ | LVIS | 67.3 | 60.7 | - | - | [config (test)](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_dino_vit/co_dino_5scale_lsj_vit_large_lvis_instance.py) | [model](https://huggingface.co/zongzhuofan) |


### Co-DETR with ResNet-50

| Model | Backbone | Epochs | Aug | Dataset | box AP | Config | Download |
| ------ | -------- | ------ | --- | ------- | ------ | ------ | ----- |
| Co-DINO | R50 | 12 | DETR | COCO | 52.1 | [config](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_dino/co_dino_5scale_r50_1x_coco.py) | [model](https://drive.google.com/drive/folders/1nAXOkzqrEgz-YnXxIEs4d5j9li_kmrnv?usp=sharing) |
| Co-DINO | R50 | 12 | LSJ | COCO | 52.1 | [config](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_dino/co_dino_5scale_lsj_r50_1x_coco.py) | [model](https://drive.google.com/drive/folders/1nAXOkzqrEgz-YnXxIEs4d5j9li_kmrnv?usp=sharing) |
| Co-DINO-9enc | R50 | 12 | LSJ | COCO | 52.6 | [config](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_dino/co_dino_5scale_9encoder_lsj_r50_1x_coco.py) | [model](https://drive.google.com/drive/folders/1nAXOkzqrEgz-YnXxIEs4d5j9li_kmrnv?usp=sharing) |
| Co-DINO | R50 | 36 | LSJ | COCO | 54.8 | [config](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_dino/co_dino_5scale_lsj_r50_3x_coco.py) | [model](https://drive.google.com/drive/folders/1nAXOkzqrEgz-YnXxIEs4d5j9li_kmrnv?usp=sharing) |
| Co-DINO-9enc | R50 | 36 | LSJ | COCO | 55.4 | [config](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_dino/co_dino_5scale_9encoder_lsj_r50_3x_coco.py) | [model](https://drive.google.com/drive/folders/1nAXOkzqrEgz-YnXxIEs4d5j9li_kmrnv?usp=sharing) |


### Co-DETR with Swin-L

| Model | Backbone | Epochs | Aug | Dataset | box AP | Config | Download |
| ------ | -------- | ------ | --- | ------- | ------ | ------ | ----- |
| Co-DINO | Swin-L | 12 | DETR | COCO | 58.9 | [config](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_dino/co_dino_5scale_swin_large_1x_coco.py) | [model](https://drive.google.com/drive/folders/1nAXOkzqrEgz-YnXxIEs4d5j9li_kmrnv?usp=sharing) |
| Co-DINO | Swin-L | 24 | DETR | COCO | 59.8 | [config](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_dino/co_dino_5scale_swin_large_2x_coco.py) | [model](https://drive.google.com/drive/folders/1nAXOkzqrEgz-YnXxIEs4d5j9li_kmrnv?usp=sharing) |
| Co-DINO | Swin-L | 36 | DETR | COCO | 60.0 | [config](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_dino/co_dino_5scale_swin_large_3x_coco.py) | [model](https://drive.google.com/drive/folders/1nAXOkzqrEgz-YnXxIEs4d5j9li_kmrnv?usp=sharing) |
| Co-DINO | Swin-L | 12 | LSJ | COCO | 59.3 | [config](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_dino/co_dino_5scale_lsj_swin_large_1x_coco.py) | [model](https://drive.google.com/drive/folders/1nAXOkzqrEgz-YnXxIEs4d5j9li_kmrnv?usp=sharing) |
| Co-DINO | Swin-L | 24 | LSJ | COCO | 60.4 | [config](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_dino/co_dino_5scale_lsj_swin_large_2x_coco.py) | [model](https://drive.google.com/drive/folders/1nAXOkzqrEgz-YnXxIEs4d5j9li_kmrnv?usp=sharing) |
| Co-DINO | Swin-L | 36 | LSJ | COCO | 60.7 | [config](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_dino/co_dino_5scale_lsj_swin_large_3x_coco.py) | [model](https://drive.google.com/drive/folders/1nAXOkzqrEgz-YnXxIEs4d5j9li_kmrnv?usp=sharing) |
| Co-DINO | Swin-L | 36 | LSJ | LVIS | 56.9 | [config (test)](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_dino/co_dino_5scale_lsj_swin_large_3x_lvis.py) | [model](https://drive.google.com/drive/folders/1nAXOkzqrEgz-YnXxIEs4d5j9li_kmrnv?usp=sharing) |

### Co-Deformable-DETR

| Model | Backbone | Epochs | Queries | box AP | Config | Download |
| ------ | -------- | ------ | ------- | ------ | ---- | --- |
| Co-Deformable-DETR | R50 | 12 | 300 | 49.5 | [config](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_deformable_detr/co_deformable_detr_r50_1x_coco.py) | [model](https://drive.google.com/drive/folders/1asWoZ3SuM6APTL9D-QUF_YW9mjULNdh9?usp=sharing) \| [log](https://drive.google.com/drive/folders/1GktHRm2oAxmOzdK3jPaRqNu4uOQhecgZ?usp=sharing) |
| Co-Deformable-DETR | Swin-T | 12 | 300 | 51.7 | [config](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_deformable_detr/co_deformable_detr_swin_tiny_1x_coco.py) | [model](https://drive.google.com/drive/folders/1asWoZ3SuM6APTL9D-QUF_YW9mjULNdh9?usp=sharing) \| [log](https://drive.google.com/drive/folders/1GktHRm2oAxmOzdK3jPaRqNu4uOQhecgZ?usp=sharing) |
| Co-Deformable-DETR | Swin-T | 36 | 300 | 54.1 | [config](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_deformable_detr/co_deformable_detr_swin_tiny_3x_coco.py) | [model](https://drive.google.com/drive/folders/1asWoZ3SuM6APTL9D-QUF_YW9mjULNdh9?usp=sharing) \| [log](https://drive.google.com/drive/folders/1GktHRm2oAxmOzdK3jPaRqNu4uOQhecgZ?usp=sharing) |
| Co-Deformable-DETR | Swin-S | 12 | 300 | 53.4 | [config](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_deformable_detr/co_deformable_detr_swin_small_1x_coco.py) | [model](https://drive.google.com/drive/folders/1asWoZ3SuM6APTL9D-QUF_YW9mjULNdh9?usp=sharing) \| [log](https://drive.google.com/drive/folders/1GktHRm2oAxmOzdK3jPaRqNu4uOQhecgZ?usp=sharing) |
| Co-Deformable-DETR | Swin-S | 36 | 300 | 55.3 | [config](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_deformable_detr/co_deformable_detr_swin_small_3x_coco.py) | [model](https://drive.google.com/drive/folders/1asWoZ3SuM6APTL9D-QUF_YW9mjULNdh9?usp=sharing) \| [log](https://drive.google.com/drive/folders/1GktHRm2oAxmOzdK3jPaRqNu4uOQhecgZ?usp=sharing) |
| Co-Deformable-DETR | Swin-B | 12 | 300 | 55.5 | [config](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_deformable_detr/co_deformable_detr_swin_base_1x_coco.py) | [model](https://drive.google.com/drive/folders/1asWoZ3SuM6APTL9D-QUF_YW9mjULNdh9?usp=sharing) \| [log](https://drive.google.com/drive/folders/1GktHRm2oAxmOzdK3jPaRqNu4uOQhecgZ?usp=sharing) |
| Co-Deformable-DETR | Swin-B | 36 | 300 | 57.5 | [config](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_deformable_detr/co_deformable_detr_swin_base_3x_coco.py) | [model](https://drive.google.com/drive/folders/1asWoZ3SuM6APTL9D-QUF_YW9mjULNdh9?usp=sharing) \| [log](https://drive.google.com/drive/folders/1GktHRm2oAxmOzdK3jPaRqNu4uOQhecgZ?usp=sharing) |
| Co-Deformable-DETR | Swin-L | 12 | 300 | 56.9 | [config](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_deformable_detr/co_deformable_detr_swin_large_1x_coco.py) | [model](https://drive.google.com/drive/folders/1asWoZ3SuM6APTL9D-QUF_YW9mjULNdh9?usp=sharing) \| [log](https://drive.google.com/drive/folders/1GktHRm2oAxmOzdK3jPaRqNu4uOQhecgZ?usp=sharing) |
| Co-Deformable-DETR | Swin-L | 36 | 900 | 58.5 | [config](https://github.com/Sense-X/Co-DETR/blob/main/projects/configs/co_deformable_detr/co_deformable_detr_swin_large_900q_3x_coco.py) | [model](https://drive.google.com/drive/folders/1asWoZ3SuM6APTL9D-QUF_YW9mjULNdh9?usp=sharing) \| [log](https://drive.google.com/drive/folders/1GktHRm2oAxmOzdK3jPaRqNu4uOQhecgZ?usp=sharing) |

## Running

### Install
We implement Co-DETR using [MMDetection V2.25.3](https://github.com/open-mmlab/mmdetection/releases/tag/v2.25.3) and [MMCV V1.5.0](https://github.com/open-mmlab/mmcv/releases/tag/v1.5.0).
The source code of MMdetection has been included in this repo and you only need to build MMCV following [official instructions](https://github.com/open-mmlab/mmcv/tree/v1.5.0#installation).
We test our models under ```python=3.7.11,pytorch=1.11.0,cuda=11.3```. Other versions may not be compatible.

### Data
The COCO dataset and LVIS dataset should be organized as:
```
Co-DETR
└── data
├── coco
│ ├── annotations
│ │ ├── instances_train2017.json
│ │ └── instances_val2017.json
│ ├── train2017
│ └── val2017
└── lvis_v1
├── annotations
│ ├── lvis_v1_train.json
│ └── lvis_v1_val.json
├── train2017
└── val2017
```

### Training
Train Co-Deformable-DETR + ResNet-50 with 8 GPUs:
```shell
sh tools/dist_train.sh projects/configs/co_deformable_detr/co_deformable_detr_r50_1x_coco.py 8 path_to_exp
```
Train using slurm:
```shell
sh tools/slurm_train.sh partition job_name projects/configs/co_deformable_detr/co_deformable_detr_r50_1x_coco.py path_to_exp
```

### Testing
Test Co-Deformable-DETR + ResNet-50 with 8 GPUs, and evaluate:
```shell
sh tools/dist_test.sh projects/configs/co_deformable_detr/co_deformable_detr_r50_1x_coco.py path_to_checkpoint 8 --eval bbox
```
Test using slurm:
```shell
sh tools/slurm_test.sh partition job_name projects/configs/co_deformable_detr/co_deformable_detr_r50_1x_coco.py path_to_checkpoint --eval bbox
```

## Cite Co-DETR

If you find this repository useful, please use the following BibTeX entry for citation.

```latex
@inproceedings{zong2023detrs,
title={Detrs with collaborative hybrid assignments training},
author={Zong, Zhuofan and Song, Guanglu and Liu, Yu},
booktitle={Proceedings of the IEEE/CVF international conference on computer vision},
pages={6748--6758},
year={2023}
}
```

## License

This project is released under the MIT license. Please see the [LICENSE](LICENSE) file for more information.
Loading