2 artifacts
Tap to collapse details
python -m venv hf-env source hf-env/bin/activate # Linux/Mac # or hf-env\Scripts\activate on Windows
pip install "transformers[torch]" pip install datasets evaluate accelerate
Use Google Colab for no-install option: Open colab.research.google.com and run !pip install transformers[torch].
!pip install transformers[torch]
❌ Skipping virtual environment
→Always use venv to avoid package conflicts
❌ Using CPU-only PyTorch on large models
→Install with [torch] extras for GPU support if available
Tap to expand details
Spin up a personalized “learn Hugging Face” plan you can save, check off, and return to anytime — unlimited on the free trial.
Hugging Face
DeepLearning.AI
by Lewis Tunstall, Leandro von Werra, Thomas Wolf
Official docs for installation, quickstart, and advanced usage
Host models, datasets, and Spaces
Free courses on NLP, LLMs, and more
Core library for models and pipelines
Load and process datasets easily
Free GPU notebooks