update 020_INSTALL_MANUAL.md

- some formatting changes / fixes
- updates venv creation commands
- remove extra index from Mac Installations
This commit is contained in:
mauwii 2023-02-10 17:29:12 +01:00
parent 13a4666a6e
commit 4cf43b858d
No known key found for this signature in database
GPG Key ID: D923DB04ADB3F5AB

View File

@ -30,23 +30,33 @@ Installation](010_INSTALL_AUTOMATED.md), and in many cases will
already be installed (if, for example, you have used your system for already be installed (if, for example, you have used your system for
gaming): gaming):
* **Python** version 3.9 or 3.10 (3.11 is not recommended). * **Python**
* **CUDA Tools** For those with _NVidia GPUs_, you will need to version 3.9 or 3.10 (3.11 is not recommended).
* **CUDA Tools**
For those with _NVidia GPUs_, you will need to
install the [CUDA toolkit and optionally the XFormers library](070_INSTALL_XFORMERS.md). install the [CUDA toolkit and optionally the XFormers library](070_INSTALL_XFORMERS.md).
* **ROCm Tools** For _Linux users with AMD GPUs_, you will need * **ROCm Tools**
For _Linux users with AMD GPUs_, you will need
to install the [ROCm toolkit](./030_INSTALL_CUDA_AND_ROCM.md). Note that to install the [ROCm toolkit](./030_INSTALL_CUDA_AND_ROCM.md). Note that
InvokeAI does not support AMD GPUs on Windows systems due to InvokeAI does not support AMD GPUs on Windows systems due to
lack of a Windows ROCm library. lack of a Windows ROCm library.
* **Visual C++ Libraries** _Windows users_ must install the free * **Visual C++ Libraries**
_Windows users_ must install the free
[Visual C++ libraries from Microsoft](https://learn.microsoft.com/en-US/cpp/windows/latest-supported-vc-redist?view=msvc-170) [Visual C++ libraries from Microsoft](https://learn.microsoft.com/en-US/cpp/windows/latest-supported-vc-redist?view=msvc-170)
* **The Xcode command line tools** for _Macintosh users_. Instructions are * **The Xcode command line tools**
available at [Free Code Camp](https://www.freecodecamp.org/news/install-xcode-command-line-tools/)
* _Macintosh users_ may also need to run the `Install Certificates` command for _Macintosh users_. Instructions are available at
[Free Code Camp](https://www.freecodecamp.org/news/install-xcode-command-line-tools/)
* _Macintosh users_ may also need to run the `Install Certificates` command
if model downloads give lots of certificate errors. Run: if model downloads give lots of certificate errors. Run:
`/Applications/Python\ 3.10/Install\ Certificates.command` `/Applications/Python\ 3.10/Install\ Certificates.command`
@ -75,7 +85,7 @@ manager, please follow these steps:
=== "Linux/Mac" === "Linux/Mac"
```bash ```bash
export INVOKEAI_ROOT="~/invokeai" export INVOKEAI_ROOT=~/invokeai
mkdir $INVOKEAI_ROOT mkdir $INVOKEAI_ROOT
``` ```
@ -99,35 +109,30 @@ manager, please follow these steps:
Windows environment variable using the Advanced System Settings dialogue. Windows environment variable using the Advanced System Settings dialogue.
Refer to your operating system documentation for details. Refer to your operating system documentation for details.
```terminal
=== "Linux/Mac"
```bash
cd $INVOKEAI_ROOT cd $INVOKEAI_ROOT
python -m venv create .venv python -m venv .venv --prompt InvokeAI
```
=== "Windows"
```bash
cd $INVOKEAI_ROOT
python -m venv create .venv
``` ```
4. Activate the new environment: 4. Activate the new environment:
=== "Linux/Mac" === "Linux/Mac"
```bash ```bash
source .venv/bin/activate source .venv/bin/activate
``` ```
=== "Windows" === "Windows"
```bash
```ps
.venv\script\activate .venv\script\activate
``` ```
If you get a permissions error at this point, run the command
`Set-ExecutionPolicy -ExecutionPolicy Unrestricted -Scope CurrentUser`
and try `activate` again.
The command-line prompt should change to to show `(.venv)` at the If you get a permissions error at this point, run this command and try again
`Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser`
The command-line prompt should change to to show `(InvokeAI)` at the
beginning of the prompt. Note that all the following steps should be beginning of the prompt. Note that all the following steps should be
run while inside the INVOKEAI_ROOT directory run while inside the INVOKEAI_ROOT directory
@ -137,38 +142,45 @@ manager, please follow these steps:
python -m pip install --upgrade pip python -m pip install --upgrade pip
``` ```
6. Install the InvokeAI Package. The `--extra-index-url` option is used to select among CUDA, ROCm and CPU/MPS drivers as shown below: 6. Install the InvokeAI Package. The `--extra-index-url` option is used to select among
CUDA, ROCm and CPU/MPS drivers as shown below:
=== "CUDA (NVidia)" === "CUDA (NVidia)"
```bash ```bash
pip install InvokeAI[xformers] --use-pep517 --extra-index-url https://download.pytorch.org/whl/cu117 pip install InvokeAI[xformers] --use-pep517 --extra-index-url https://download.pytorch.org/whl/cu117
``` ```
=== "ROCm (AMD)" === "ROCm (AMD)"
```bash ```bash
pip install InvokeAI --use-pep517 --extra-index-url https://download.pytorch.org/whl/rocm5.2 pip install InvokeAI --use-pep517 --extra-index-url https://download.pytorch.org/whl/rocm5.2
``` ```
=== "CPU (Intel Macs & non-GPU systems)" === "CPU (Intel Macs & non-GPU systems)"
```bash ```bash
pip install InvokeAI --use-pep517 --extra-index-url https://download.pytorch.org/whl/cpu pip install InvokeAI --use-pep517 --extra-index-url https://download.pytorch.org/whl/cpu
``` ```
=== "MPS (M1 and M2 Macs)" === "MPS (M1 and M2 Macs)"
```bash ```bash
pip install InvokeAI --use-pep517 --extra-index-url https://download.pytorch.org/whl/cpu pip install InvokeAI --use-pep517
``` ```
7. Deactivate and reactivate your runtime directory so that the invokeai-specific commands 7. Deactivate and reactivate your runtime directory so that the invokeai-specific commands
become available in the environment become available in the environment
=== "Linux/Macintosh" === "Linux/Macintosh"
```bash ```bash
deactivate && source .venv/bin/activate deactivate && source .venv/bin/activate
``` ```
=== "Windows" === "Windows"
```bash
```ps
deactivate deactivate
.venv\Scripts\activate .venv\Scripts\activate
``` ```
@ -179,7 +191,7 @@ manager, please follow these steps:
models, model config files, directory for textual inversion embeddings, and models, model config files, directory for textual inversion embeddings, and
your outputs. your outputs.
```bash ```terminal
invokeai-configure invokeai-configure
``` ```
@ -314,7 +326,7 @@ installation protocol (important!)
=== "MPS (M1 and M2 Macs)" === "MPS (M1 and M2 Macs)"
```bash ```bash
pip install -e . --use-pep517 --extra-index-url https://download.pytorch.org/whl/cpu pip install -e . --use-pep517
``` ```
Be sure to pass `-e` (for an editable install) and don't forget the Be sure to pass `-e` (for an editable install) and don't forget the