Git Product home page Git Product logo

Comments (5)

yaohuiwu avatar yaohuiwu commented on June 11, 2024

To walk around the issue, you need:

  1. Stop the webui;
  2. Delete the v1-5-pruned-emaonly.safetensors file (in the dir /path/to/stable-diffusion-webui/models/Stable-diffusion) which you downloaded;
  3. Start the webui again to let the webui download the v1-5-pruned-emaonly.safetensors file itself.

I don't know why the file downloaded by webui itself is ok but mine is not. I even checked the SHA256 checksum. It's so wired and waste me a lot of time.

from stable-diffusion-webui.

mclaughlin111 avatar mclaughlin111 commented on June 11, 2024

followed these steps: exactly same error
Screenshot 2024-05-15 at 10 37 08 AM

100%|██████████████████████████████████████| 3.97G/3.97G [15:08<00:00, 4.69MB/s]
Calculating sha256 for /Users/thomasmclaughlin/stable-diffusion-webui/models/Stable-diffusion/v1-5-pruned-emaonly.safetensors: Running on local URL:  http://127.0.0.1:7860

To create a public link, set `share=True` in `launch()`.
Startup time: 920.8s (prepare environment: 0.2s, import torch: 5.7s, import gradio: 1.2s, setup paths: 1.6s, initialize shared: 0.1s, other imports: 1.2s, list SD models: 909.1s, load scripts: 0.7s, create ui: 0.4s, gradio launch: 0.5s).
6ce0161689b3853acaa03779ec93eafe75a02f4ced659bee03f50797806fa2fa
Loading weights [6ce0161689] from /Users/thomasmclaughlin/stable-diffusion-webui/models/Stable-diffusion/v1-5-pruned-emaonly.safetensors
Creating model from config: /Users/thomasmclaughlin/stable-diffusion-webui/configs/v1-inference.yaml
/Users/thomasmclaughlin/stable-diffusion-webui/venv/lib/python3.10/site-packages/huggingface_hub/file_download.py:1132: FutureWarning: `resume_download` is deprecated and will be removed in version 1.0.0. Downloads always resume when possible. If you want to force a new download, use `force_download=True`.
  warnings.warn(
Applying attention optimization: InvokeAI... done.
loading stable diffusion model: AssertionError
Traceback (most recent call last):
  File "/usr/local/Cellar/[email protected]/3.10.14/Frameworks/Python.framework/Versions/3.10/lib/python3.10/threading.py", line 973, in _bootstrap
    self._bootstrap_inner()
  File "/usr/local/Cellar/[email protected]/3.10.14/Frameworks/Python.framework/Versions/3.10/lib/python3.10/threading.py", line 1016, in _bootstrap_inner
    self.run()
  File "/usr/local/Cellar/[email protected]/3.10.14/Frameworks/Python.framework/Versions/3.10/lib/python3.10/threading.py", line 953, in run
    self._target(*self._args, **self._kwargs)
  File "/Users/thomasmclaughlin/stable-diffusion-webui/modules/initialize.py", line 149, in load_model
    shared.sd_model  # noqa: B018
  File "/Users/thomasmclaughlin/stable-diffusion-webui/modules/shared_items.py", line 175, in sd_model
    return modules.sd_models.model_data.get_sd_model()
  File "/Users/thomasmclaughlin/stable-diffusion-webui/modules/sd_models.py", line 620, in get_sd_model
    load_model()
  File "/Users/thomasmclaughlin/stable-diffusion-webui/modules/sd_models.py", line 770, in load_model
    with devices.autocast(), torch.no_grad():
  File "/Users/thomasmclaughlin/stable-diffusion-webui/modules/devices.py", line 218, in autocast
    if has_xpu() or has_mps() or cuda_no_autocast():
  File "/Users/thomasmclaughlin/stable-diffusion-webui/modules/devices.py", line 28, in cuda_no_autocast
    device_id = get_cuda_device_id()
  File "/Users/thomasmclaughlin/stable-diffusion-webui/modules/devices.py", line 40, in get_cuda_device_id
    ) or torch.cuda.current_device()
  File "/Users/thomasmclaughlin/stable-diffusion-webui/venv/lib/python3.10/site-packages/torch/cuda/__init__.py", line 769, in current_device
    _lazy_init()
  File "/Users/thomasmclaughlin/stable-diffusion-webui/venv/lib/python3.10/site-packages/torch/cuda/__init__.py", line 289, in _lazy_init
    raise AssertionError("Torch not compiled with CUDA enabled")
AssertionError: Torch not compiled with CUDA enabled


Stable diffusion model failed to load
changing setting sd_model_checkpoint to v1-5-pruned-emaonly.safetensors: AttributeError
Traceback (most recent call last):
  File "/Users/thomasmclaughlin/stable-diffusion-webui/modules/options.py", line 165, in set
    option.onchange()
  File "/Users/thomasmclaughlin/stable-diffusion-webui/modules/call_queue.py", line 13, in f
    res = func(*args, **kwargs)
  File "/Users/thomasmclaughlin/stable-diffusion-webui/modules/initialize_util.py", line 181, in <lambda>
    shared.opts.onchange("sd_model_checkpoint", wrap_queued_call(lambda: sd_models.reload_model_weights()), call=False)
  File "/Users/thomasmclaughlin/stable-diffusion-webui/modules/sd_models.py", line 860, in reload_model_weights
    sd_model = reuse_model_from_already_loaded(sd_model, checkpoint_info, timer)
  File "/Users/thomasmclaughlin/stable-diffusion-webui/modules/sd_models.py", line 793, in reuse_model_from_already_loaded
    send_model_to_cpu(sd_model)
  File "/Users/thomasmclaughlin/stable-diffusion-webui/modules/sd_models.py", line 662, in send_model_to_cpu
    if m.lowvram:
AttributeError: 'NoneType' object has no attribute 'lowvram'

*** Error completing request
*** Arguments: ('task(q0r8omuzr5jxt25)', <gradio.routes.Request object at 0x15fa8f8b0>, 'test', '', [], 1, 1, 7, 512, 512, False, 0.7, 2, 'Latent', 0, 0, 0, 'Use same checkpoint', 'Use same sampler', 'Use same scheduler', '', '', [], 0, 20, 'DPM++ 2M', 'Automatic', False, '', 0.8, -1, False, -1, 0, 0, 0, False, False, 'positive', 'comma', 0, False, False, 'start', '', 1, '', [], 0, '', [], 0, '', [], True, False, False, False, False, False, False, 0, False) {}
    Traceback (most recent call last):
      File "/Users/thomasmclaughlin/stable-diffusion-webui/modules/call_queue.py", line 57, in f
        res = list(func(*args, **kwargs))
      File "/Users/thomasmclaughlin/stable-diffusion-webui/modules/call_queue.py", line 36, in f
        res = func(*args, **kwargs)
      File "/Users/thomasmclaughlin/stable-diffusion-webui/modules/txt2img.py", line 109, in txt2img
        processed = processing.process_images(p)
      File "/Users/thomasmclaughlin/stable-diffusion-webui/modules/processing.py", line 832, in process_images
        sd_models.reload_model_weights()
      File "/Users/thomasmclaughlin/stable-diffusion-webui/modules/sd_models.py", line 860, in reload_model_weights
        sd_model = reuse_model_from_already_loaded(sd_model, checkpoint_info, timer)
      File "/Users/thomasmclaughlin/stable-diffusion-webui/modules/sd_models.py", line 793, in reuse_model_from_already_loaded
        send_model_to_cpu(sd_model)
      File "/Users/thomasmclaughlin/stable-diffusion-webui/modules/sd_models.py", line 662, in send_model_to_cpu
        if m.lowvram:
    AttributeError: 'NoneType' object has no attribute 'lowvram'

---

from stable-diffusion-webui.

yaohuiwu avatar yaohuiwu commented on June 11, 2024

It seems that it may not be due to file integrity. I have no idea then. Good luck with you !

from stable-diffusion-webui.

ceeyang avatar ceeyang commented on June 11, 2024

When I completely reinstalled the project, it worked for the first time, but when I added other models, the project would throw this exception,

I found that after I deleted the models I added manually, the project could run normally again;

from stable-diffusion-webui.

100-gusenits avatar 100-gusenits commented on June 11, 2024

I removed all models, fresh install, trying to switch to default model (as it was pulled again) and see
changing setting sd_model_checkpoint to v1-5-pruned-emaonly.safetensors: AttributeError
Traceback (most recent call last):
File "/Users/gusenits/development/stable_diff/stable-diffusion-webui/modules/options.py", line 165, in set
option.onchange()
File "/Users/gusenits/development/stable_diff/stable-diffusion-webui/modules/call_queue.py", line 13, in f
res = func(*args, **kwargs)
File "/Users/gusenits/development/stable_diff/stable-diffusion-webui/modules/initialize_util.py", line 181, in
shared.opts.onchange("sd_model_checkpoint", wrap_queued_call(lambda: sd_models.reload_model_weights()), call=False)
File "/Users/gusenits/development/stable_diff/stable-diffusion-webui/modules/sd_models.py", line 860, in reload_model_weights
sd_model = reuse_model_from_already_loaded(sd_model, checkpoint_info, timer)
File "/Users/gusenits/development/stable_diff/stable-diffusion-webui/modules/sd_models.py", line 793, in reuse_model_from_already_loaded
send_model_to_cpu(sd_model)
File "/Users/gusenits/development/stable_diff/stable-diffusion-webui/modules/sd_models.py", line 662, in send_model_to_cpu
if m.lowvram:
AttributeError: 'NoneType' object has no attribute 'lowvram'

from stable-diffusion-webui.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.