We support utilizing [Deepspeed](https://github.com/microsoft/DeepSpeed) to reduce memory costs for training large-scale models, e.g. InternImage-H with over 1 billion parameters.
To use it, first install the requirements as
```bash
pip install deepspeed
```
Then you could launch the training in a slurm system with 8 GPUs as follows (tiny and huge as examples)
Then, you could use `best.pth` as usual, e.g., `model.load_state_dict(torch.load('best.pth'))`
> Due to the lack of computational resources, the deepspeed training scripts are currently only verified for the first few epochs. Please fire an issue if you have problems for reproducing the whole training.
### Export
### Export
To export `InternImage-T` from PyTorch to ONNX, run:
To export `InternImage-T` from PyTorch to ONNX, run: