improve doc, fix bug

main
Tran Xen 2 years ago
parent 0db1f452fd
commit db79243acc

@ -176,7 +176,7 @@ You need a sufficiently recent version of your SD environment. Using the GPU has
In Version 1.2.1, the ability to use the GPU has been added, a setting that can be configured in SD at startup. Currently, this feature is only supported on Windows and Linux, as the necessary dependencies for Mac have not been included. In Version 1.2.1, the ability to use the GPU has been added, a setting that can be configured in SD at startup. Currently, this feature is only supported on Windows and Linux, as the necessary dependencies for Mac have not been included.
The `--faceswaplab_gpu` option in SD can be added to the args in webui-user.sh or webui-user.bat. The `--faceswaplab_gpu` option in SD can be added to the args in webui-user.sh or webui-user.bat. **There is also an option in SD settings**.
The model stays loaded in VRAM and won't be unloaded after each use. As of now, I don't know a straightforward way to handle this, so it will occupy space continuously. If your system's VRAM is limited, enabling this option might not be advisable. The model stays loaded in VRAM and won't be unloaded after each use. As of now, I don't know a straightforward way to handle this, so it will occupy space continuously. If your system's VRAM is limited, enabling this option might not be advisable.
@ -196,6 +196,16 @@ You should therefore be able to debug a little before activating the option. If
The first time the swap is used, the program will continue to use the CPU, but will offer to install the GPU. You will then need to restart. This is due to the optimizations made by SD.Next to the installation scripts. The first time the swap is used, the program will continue to use the CPU, but will offer to install the GPU. You will then need to restart. This is due to the optimizations made by SD.Next to the installation scripts.
For SD.Next, the best is to install dependencies manually :
on windows :
```shell
.\venv\Scripts\activate
cd .\extensions\sd-webui-faceswaplab\
pip install .\requirements-gpu.txt
```
## Settings ## Settings
You can change the program's default behavior in your webui's global settings (FaceSwapLab section in settings). This is particularly useful if you want to have default options for inpainting or for post-processsing, for example. You can change the program's default behavior in your webui's global settings (FaceSwapLab section in settings). This is particularly useful if you want to have default options for inpainting or for post-processsing, for example.

@ -50,6 +50,7 @@ def use_gpu() -> bool:
@lru_cache @lru_cache
def force_install_gpu_providers() -> None: def force_install_gpu_providers() -> None:
# Ugly Ugly hack due to SDNEXT : # Ugly Ugly hack due to SDNEXT :
try:
from scripts.configure import check_install from scripts.configure import check_install
logger.warning("Try to reinstall gpu dependencies") logger.warning("Try to reinstall gpu dependencies")
@ -58,6 +59,10 @@ def force_install_gpu_providers() -> None:
logger.warning( logger.warning(
"On SD.NEXT/vladmantic you will also need to check numpy>=1.24.2 and tensorflow>=2.13.0" "On SD.NEXT/vladmantic you will also need to check numpy>=1.24.2 and tensorflow>=2.13.0"
) )
except:
logger.error(
"Reinstall has failed (which is normal on windows), please install requirements-gpu.txt manually to enable gpu."
)
def get_providers() -> List[str]: def get_providers() -> List[str]:

Loading…
Cancel
Save