ikd
Official implementation of "Exploring Inconsistent Knowledge Distillation for Object Detection with Data Augmentation" (ACMMM2023)
Science Score: 54.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
✓CITATION.cff file
Found CITATION.cff file -
✓codemeta.json file
Found codemeta.json file -
✓.zenodo.json file
Found .zenodo.json file -
○DOI references
-
✓Academic publication links
Links to: arxiv.org -
○Academic email domains
-
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (6.9%) to scientific vocabulary
Repository
Official implementation of "Exploring Inconsistent Knowledge Distillation for Object Detection with Data Augmentation" (ACMMM2023)
Basic Info
Statistics
- Stars: 4
- Watchers: 1
- Forks: 0
- Open Issues: 0
- Releases: 0
Metadata Files
README.md
Exploring Inconsistent Knowledge Distillation for Object Detection with Data Augmentation
This repository contains the official PyTorch implementation of the following paper at ACMMM 2023:
Exploring Inconsistent Knowledge Distillation for Object Detection with Data Augmentation
Jiawei Liang, Siyuan Liang, Aishan Liu, Ke Ma, Jingzhi Li, Xiaochun Cao
https://arxiv.org/abs/2209.09841
Installation
- Install python (python == 3.8)
- Install pytorch (pytorch == 2.0.0)
- Install mmcvfull (mmcvfull == 1.6.0)
- Install mmdetection (mmdetection == 2.25.0) from source code
bash git clone https://github.com/JWLiang007/IKD.git cd IKD/ pip install -r requirements/optional.txt pip install -v -e .
Download Dataset and Checkpoint
- Download MS COCO2017 dataset
- Unzip COCO dataset into data/coco/ in mmdetection/
- Download pretrained teacher model retinanetx10164x4dfpn1xcoco20200130-366f5af1.pth from the repository of mmdetection
- Put the downloaded pretrained model into checkpoints/ in mmdetection/
Generate Adversarial Examples
```bash
single GPU
python tools/taGT.py configs/retinanet/retinanetx10164x4dfpn1xcoco.py checkpoints/retinanetx10164x4dfpn1xcoco20200130-366f5af1.pth --method difgsm --show-dir data/advrtncoco85 --genadvaug --eps 8 --alpha 2 --steps 5
multi GPU
bash tools/distadv.sh configs/retinanet/retinanetx10164x4dfpn1xcoco.py checkpoints/retinanetx10164x4dfpn1xcoco20200130-366f5af1.pth 8 --method difgsm --show-dir data/advrtncoco85 --genadvaug --eps 8 --alpha 2 --steps 5 ```
Train
```bash
single GPU
Step 1: train with DFA
python tools/train.py configs/fgd/DFAfgdretinarx10164x4ddistillretinar50fpn2xcoco.py
Step 2: resume from epoch 16 and train without DFA
python tools/train.py configs/fgd/fgdretinarx10164x4ddistillretinar50fpn2xcoco.py --resume-from workdirs/DFAfgdretinarx10164x4ddistillretinar50fpn2xcoco/epoch_16.pth
multi GPU
Step 1: train with DFA
bash tools/disttrain.sh configs/fgd/DFAfgdretinarx10164x4ddistillretinar50fpn2x_coco.py 8
Step 2: resume from epoch 16 and train without DFA
bash tools/disttrain.sh configs/fgd/fgdretinarx10164x4ddistillretinar50fpn2xcoco.py 8 --resume-from workdirs/DFAfgdretinarx10164x4ddistillretinar50fpn2xcoco/epoch16.pth
```
Test
```bash
single GPU
python tools/test.py configs/fgd/DFAfgdretinarx10164x4ddistillretinar50fpn2xcoco.py $PATH_CHECKPOINT --eval bbox
multi GPU
bash tools/disttest.sh configs/fgd/DFAfgdretinarx10164x4ddistillretinar50fpn2xcoco.py $PATHCHECKPOINT 8 --eval bbox ```
Generalizability
Backdoor Defense
| Index | Method | ASR | ASR Drop |
|---|---|---|---|
| 1 | Victim | 96.7 | - |
| 2 | NAD | 82.88 | 13.82 |
| 3 | Ours | 78.26 | 18.44(↑33%) |
For more recent progress in backdoor defense, please refers to the following repo:
https://github.com/JWLiang007/BD_DeCLIP.git
and switches to the bd branch.
Acknowledgement
Our code is based on the project MMDetection.
Owner
- Login: JWLiang007
- Kind: user
- Repositories: 2
- Profile: https://github.com/JWLiang007
Citation (CITATION.cff)
cff-version: 1.2.0 message: "If you use this software, please cite it as below." authors: - name: "MMDetection Contributors" title: "OpenMMLab Detection Toolbox and Benchmark" date-released: 2018-08-22 url: "https://github.com/open-mmlab/mmdetection" license: Apache-2.0
GitHub Events
Total
- Watch event: 1
Last Year
- Watch event: 1
Dependencies
- actions/checkout v2 composite
- actions/setup-python v2 composite
- codecov/codecov-action v1.0.10 composite
- codecov/codecov-action v2 composite
- actions/checkout v2 composite
- actions/checkout v2 composite
- actions/setup-python v2 composite
- actions/checkout v2 composite
- actions/setup-python v2 composite
- pytorch/pytorch ${PYTORCH}-cuda${CUDA}-cudnn${CUDNN}-devel build
- pytorch/pytorch ${PYTORCH}-cuda${CUDA}-cudnn${CUDNN}-devel build
- albumentations >=0.3.2
- cython *
- numpy *
- docutils ==0.16.0
- myst-parser *
- sphinx ==4.0.2
- sphinx-copybutton *
- sphinx_markdown_tables *
- sphinx_rtd_theme ==0.5.2
- mmcv-full >=1.3.17
- cityscapesscripts *
- imagecorruptions *
- scipy *
- sklearn *
- timm *
- mmcv *
- torch *
- torchvision *
- matplotlib *
- numpy *
- pycocotools *
- six *
- terminaltables *
- asynctest * test
- codecov * test
- flake8 * test
- interrogate * test
- isort ==4.3.21 test
- kwarray * test
- onnx ==1.7.0 test
- onnxruntime >=1.8.0 test
- protobuf <=3.20.1 test
- pytest * test
- ubelt * test
- xdoctest >=0.10.0 test
- yapf * test