Metadata-Version: 2.1
Name: dsp
Version: 0.1
Summary: library for model compression
Home-page: https://github.com/lilujunai
Author: Contributors
License: Apache License 2.0
Keywords: computer vision,model compression
Classifier: Development Status :: 4 - Beta
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.5
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: 3.7
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
Description-Content-Type: text/markdown

# DSP

DSP: Efficient Student Training via Distill-aware Sparse Paradigm

## Introduction

This is the official implementation of the paper [DSP: Efficient Student Training via Distill-aware Sparse Paradigm](https://arxiv.org/abs/xxxx.xxxx).

## Requirements

- Python 
- PyTorch
- Torchvision

install dsp with pip:

```bash
pip install -e .
```

## Usage

### Training

```bash
python train.py --dataset cifar10 --arch resnet18 --teacher resnet50 --teacher_path ./pretrained/resnet50.pth --distill kd --alpha 0.5 --beta 0.5 --gamma 0.5 --epochs 200 --batch_size 128 --lr 0.1 --schedule 60 120 160 --gamma 0.2 --wd 5e-4 --save ./results
```

### Evaluation

```bash
python eval.py --dataset cifar10 --arch resnet18 --teacher resnet50 --teacher_path ./pretrained/resnet50.pth --distill kd --alpha 0.5 --beta 0.5 --gamma 0.5 --batch_size 128 --wd 5e-4 --resume ./results/checkpoint.pth.tar
```

## Citation

If you find this code useful for your research, please cite our paper:

```bibtex
@article{xxxx,
  title={DSP: Efficient Student Training via Distill-aware Sparse Paradigm},
  author={xxxx},
  journal={xxxx},
  year={2021}
}
```
