accelerate: add page (#11340)

* accelerate: add page

* accelerate: modify command description

* accelerate: update template format

Co-authored-by: Sebastiaan Speck <12570668+sebastiaanspeck@users.noreply.github.com>

* accelerate: remove inappropriate description

Co-authored-by: Juri Dispan <juri.dispan@posteo.net>

* accelerate: update command description

Co-authored-by: Juri Dispan <juri.dispan@posteo.net>

* accelerate: fix typo and update appropriate description

Co-authored-by: Juri Dispan <juri.dispan@posteo.net>

---------

Co-authored-by: Sebastiaan Speck <12570668+sebastiaanspeck@users.noreply.github.com>
Co-authored-by: Juri Dispan <juri.dispan@posteo.net>
pull/23/head
WU Zhenglong 2023-11-01 01:17:44 +08:00 committed by GitHub
parent 2983e82ec1
commit f994b81ad5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 28 additions and 0 deletions

View File

@ -0,0 +1,28 @@
# Accelerate
> Accelerate is a library that enables the same PyTorch code to be run across any distributed configuration.
> More information: <https://huggingface.co/docs/accelerate/index>.
- Print environment information:
`accelerate env`
- Interactively create a configuration file:
`accelerate config`
- Print the estimated GPU memory cost of running a huggingface model with different data types:
`accelerate estimate-memory {{name/model}}`
- Test an Accelerate configuration file:
`accelerate test --config_file {{path/to/config.yaml}}`
- Run a model on CPU with Accelerate:
`accelerate launch {{path/to/script.py}} {{--cpu}}`
- Run a model on multi-GPU with Accelerate, with 2 machines:
`accelerate launch {{path/to/script.py}} --multi_gpu --num_machines {{2}}`