网页 综合 更新时间 2026-11-16 04:55:38

Installation · Hugging Face

自动蜘蛛 huggingface.co 正文约 1357 字
Installation · Hugging Face
Accelerate documentation
and get access to the augmented documentation experience
Before you start, you will need to setup your environment, install the appropriate packages, and configure Accelerate. Accelerate is tested on Python 3.8+.
Accelerate is available on pypi and conda, as well as on GitHub. Details to install from each are below:
To install Accelerate from pypi, perform:
Accelerate can also be installed with conda with:
New features are added every day that haven’t been released yet. To try them out yourself, install from the GitHub repository:
If you’re working on contributing to the library or wish to play with the source code and see live results as you run the code, an editable version can be installed from a locally-cloned version of the repository:
After installing, you need to configure Accelerate for how the current system is set up for training. To do so run the following and answer the questions prompted to you:
To write a barebones configuration that doesn’t include options such as DeepSpeed configuration or running on TPUs, you can quickly run:
Accelerate will automatically utilize the maximum number of GPUs available and set the mixed precision mode.
To check that your configuration looks fine, run:
An example output is shown below, which describes two GPUs on a single machine with no mixed precision being used:
访问原文 返回搜索 https://huggingface.co/docs/accelerate/basic_tutorials/install
本页为82搜索生成的网页快照,内容来自站内索引;演示数据的原文链接仅作示例。