xlang-ai / instructor-embedding

[ACL 2023] One Embedder, Any Task: Instruction-Finetuned Text Embeddings
Apache License 2.0
1.85k stars 134 forks source link

training with deepspeed got oom #61

Closed Costwen closed 1 year ago

Costwen commented 1 year ago

I tried train the sentence-xl on 8*A100 but got oom with deepspeed. Have you evry been used deepspeed to train model? image

{
    "train_micro_batch_size_per_gpu": "auto",
    "gradient_accumulation_steps": "auto",
    "zero_allow_untested_optimizer": true,
    "bp16": {
      "enabled": "auto"
    },
    "zero_optimization": {
      "stage": 2,
      "allgather_partitions": true,
      "allgather_bucket_size": 5e8,
      "overlap_comm": false,
      "reduce_scatter": true,
      "reduce_bucket_size": 5e8,
      "contiguous_gradients" : true
    }
  }

here is my deepspeed config