In this video, I show you how to use Amazon SageMaker to train a Transformer model with AWS Trainium and compile it for AWS Inferentia.
Starting from a BERT model and the Yelp review datatset, I first train a multi-class classification model on an ml.trn1.2xlarge instance. I also show you how to reuse the Neuron SDK model cache from one training job to the next, in order to save time and money on repeated jobs. Then, I compile the trained model for Inferentia with a SageMaker Processing batch job, making it easy to automate such tasks.
⭐️⭐️⭐️ Don't forget to subscribe to be notified of future videos ⭐️⭐️⭐️
⭐️⭐️⭐️ Want to buy me a coffee? I can always use more :) [ Ссылка ] ⭐️⭐️⭐️
- Code: [ Ссылка ]
- Training with Trainium on EC2: [ Ссылка ]
- Predicting with Inferentia on EC2: [ Ссылка ]
- SageMaker SDK feature request: [ Ссылка ]
Interested in hardware acceleration for Transformers? Check out my other videos :
- Training on Habana Gaudi: [ Ссылка ]
- Training on Graphcore: [ Ссылка ]
- Predicting with ONNX: [ Ссылка ]
- Predicting with Intel OpenVINO: [ Ссылка ]
![](https://i.ytimg.com/vi/pokM1r3rgIg/mqdefault.jpg)