Download modules/import_hook.py from coding-alt/stable-diffusion-webui: direct link, hf CLI and curl.
- Browser
- Download file 204 Bytes
-
https://huggingface.co/coding-alt/stable-diffusion-webui/resolve/25c4c044341127cd0fc3d4be199d4cf24a883090/modules/import_hook.py
- Command line
-
hf download hf://coding-alt/stable-diffusion-webui@25c4c044341127cd0fc3d4be199d4cf24a883090/modules/import_hook.py
-
curl -L -o import_hook.py https://huggingface.co/coding-alt/stable-diffusion-webui/resolve/25c4c044341127cd0fc3d4be199d4cf24a883090/modules/import_hook.py
204 Bytes
| import sys | |
| # this will break any attempt to import xformers which will prevent stability diffusion repo from trying to use it | |
| if "--xformers" not in "".join(sys.argv): | |
| sys.modules["xformers"] = None | |