-
Notifications
You must be signed in to change notification settings - Fork 62
Description
I have had the great fortune of meeting someone who was able to get the standalone version of Layer Divider to work. However, the automatic1111 extension version of Layer Divider still does not work, according to him, he believes that Layer Divider should be updated for the current gradio version.
Keep in mind that this fix only works for the standalone webui version of Layer Divider, and not the automatic1111 extension version.
Apparently, there is another requirement other than Python 3.10.8 and Git, it is listed on this page: https://zenn.dev/mattyamonaca/articles/b3fec7a6edd722
The hidden prerequisite requirements:
- Onnx runtime, CUDA and cuDNN, your CUDA and cuDNN must match up with your Onnx runtime version, and the table can be found here: https://onnxruntime.ai/docs/execution-providers/CUDA-ExecutionProvider.html#requirements
- Installing Microsoft C++ BuildTools, you must download visual studio build tools with "Desktop development with C++" ticked:


- Copy your cublas64_11.dll from your NVIDIA GPU Computing Toolkit which you gotten from downloading CUDA in step 1 into your layer divider folder, here is an example of where to copy and paste it to: C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v11.6\bin\cublas64_11.dll to layerdivider\venv\lib\site-packages\torch\lib\cublas64_11.dll
FYI: I was using ONNX runtime 1.15, CUDA 11.8, cuDNN 8.5.0.96, Microsoft Visual Build Tools 2022
My issue was that I kept getting Winerror 127:

In order to fix this issue, fulfill the prerequisite requirements, and then follow these steps:
- delete the venv folder which is found inside your layer divider folder
- open your command prompt or powershell inside your layer divider folder
- python -m venv venv
- venv\scripts\activate
- pip install -r requirements.txt
- pip install opencv-python pycocotools matplotlib onnxruntime onnx
- pip install torch==2.0.1+cu118 torchvision==0.15.2+cu118 --extra-index-url https://download.pytorch.org/whl/cu118
- pip install cython packbits onnx onnxruntime-gpu opencv-python numpy Pillow scikit-learn psd-tools requests
- pip uninstall gradio
- pip install gradio==3.39.0
- pip uninstall pytoshop
- pip install pytoshop --no-cache-dir
- close your command prompt or powershell
- open .\venv\Lib\site-packages\pytoshop\codecs.py file in txt editor
- add the following:
import pyximport
pyximport.install()
before the line
try:
from . import packbits # type: ignore
except ImportError:
pass
- Now you can launch your run_gui.ps1
