How to run fairest-train with Mac M1 Max GPU

I need a little help. I have been trying to run fairseq-train on my Mac M1 Max using the GPU, but it is running on CPU.

torch.backends.mps.is_available() gives “True”

How can I force fairest-train to use “mps”?

!fairseq-train /Users/ha/data/preprocessed --max-epoch 7
–encoder-normalize-before --decoder-normalize-before
–arch transformer --layernorm-embedding
–task translation_multi_simple_epoch
–sampling-method “temperature”
–sampling-temperature 1.5
–encoder-langtok “src”
–lang-pairs “$LANGPAIRS”
–criterion label_smoothed_cross_entropy --label-smoothing 0.2
–optimizer adam --adam-eps 1e-06 --adam-betas ‘(0.9, 0.98)’
–lr-scheduler inverse_sqrt --lr 3e-04 --warmup-updates 2500 --max-update 40000
–dropout 0.3 --attention-dropout 0.1 --weight-decay 0.0
–max-tokens 1024 --max-tokens-valid 1024 --update-freq 2
–save-interval 1 --save-interval-updates 5000 --keep-interval-updates 10 --no-epoch-checkpoints
–seed 222 --log-format simple --log-interval 50 --ddp-backend=legacy_ddp