Run a Hugging Face Natural Language Processing model on Arm

Who is this for?

This is an introductory topic for software developers who want to learn how to run a natural language processing (NLP) model from Hugging Face using PyTorch on Arm based servers.

What will you learn?

After completing this Learning Path, you'll be able to perform the following tasks:

  • Deploy a PyTorch NLP model from Hugging Face on an Arm AArch64 CPU
  • Use the PyTorch profiler to analyze the execution time of the model

Prerequisites

Before starting, you'll need the following prerequisites:

Summary

AI-assisted

This summary was drafted with an approved AI-assisted workflow and reviewed by Arm contributors before publication. Human technical review remains part of the process so the final page reflects engineering rigor, accuracy, and Arm editorial standards.

Close
?
You’ll run and profile a Hugging Face NLP model with PyTorch on an Arm AArch64 CPU. First, you’ll prepare an Ubuntu 22.04 LTS Arm server and install PyTorch, Transformers, and SciPy. You’ll then run a RoBERTa sentiment-analysis model and inspect its ranked labels and confidence scores. Finally, you’ll add the PyTorch Profiler and review the CPU execution time for individual operators.
Next