diff options
author | mawr <mawr@mail.ru> | 2022-10-30 21:14:07 +0000 |
---|---|---|
committer | mawr <mawr@mail.ru> | 2022-10-30 21:14:07 +0000 |
commit | d587586d3be2de061238defb8a556f03743287f6 (patch) | |
tree | e77d86d46dbb7f39eb573e8ce50a2e0eb8fc31bb /modules/interrogate.py | |
parent | 17a2076f72562b428052ee3fc8c43d19c03ecd1e (diff) | |
download | stable-diffusion-webui-gfx803-d587586d3be2de061238defb8a556f03743287f6.tar.gz stable-diffusion-webui-gfx803-d587586d3be2de061238defb8a556f03743287f6.tar.bz2 stable-diffusion-webui-gfx803-d587586d3be2de061238defb8a556f03743287f6.zip |
Added "--clip-models-path" switch to avoid using default "~/.cache/clip" and enable to run under unprivileged user without homedir
Diffstat (limited to 'modules/interrogate.py')
-rw-r--r-- | modules/interrogate.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/interrogate.py b/modules/interrogate.py index 65b05d34..9769aa34 100644 --- a/modules/interrogate.py +++ b/modules/interrogate.py @@ -56,9 +56,9 @@ class InterrogateModels: import clip
if self.running_on_cpu:
- model, preprocess = clip.load(clip_model_name, device="cpu")
+ model, preprocess = clip.load(clip_model_name, device="cpu", download_root=shared.cmd_opts.clip_models_path)
else:
- model, preprocess = clip.load(clip_model_name)
+ model, preprocess = clip.load(clip_model_name, download_root=shared.cmd_opts.clip_models_path)
model.eval()
model = model.to(devices.device_interrogate)
|