openvinotoolkit / stable-diffusion-webui

Stable Diffusion web UI
GNU Affero General Public License v3.0
290 stars 45 forks source link

[Bug]: Unable to generate high resolution images #31

Open TheWonderfulTartiflette opened 1 year ago

TheWonderfulTartiflette commented 1 year ago

Is there an existing issue for this?

What happened?

When I try to generate high resolution images, I am getting an error. I do not know at which resolution the error starts to appear

Steps to reproduce the problem

Try to generate a very high res image

What should have happened?

Generate a very high res image

Version or Commit where the problem happens

Latest

What Python version are you running on ?

Python 3.10.x

What platforms do you use to access the UI ?

Windows

What device are you running WebUI on?

Other GPUs

Cross attention optimization

Automatic

What browsers do you use to access the UI ?

Google Chrome

Command Line Arguments

No

List of extensions

No

Console logs

*** Error completing request
*** Arguments: ('task(pwwpsxcjtfboexc)', 'fantasy medieval village world inside a glass sphere , high detail, fantasy, realistic, light effect, hyper detail, volumetric lighting, cinematic, macro, depth of field, blur, red light and clouds from the back, highly detailed epic cinematic concept art cg render made in maya, blender and photoshop, octane render, excellent composition, dynamic dramatic cinematic lighting, aesthetic, very inspirational, world inside a glass sphere by james gurney by artgerm with james jean, joe fenton and tristan eaton by ross tran, <lora:epinoiseoffset_v2:0.35>, fine details, 4k resolution, <lora:add_detail:0.25>', '', [], 150, 0, False, False, 1, 1, 7, -1.0, -1.0, 0, 0, 0, False, 2048, 2048, False, 0.7, 2, 'Latent', 0, 0, 0, 0, '', '', [], <gradio.routes.Request object at 0x0000023F42664C40>, 1, 'instruct-pix2pix.yaml', 'GPU', True, 'Euler a', True, False, False, 'positive', 'comma', 0, False, False, '', 1, '', [], 0, '', [], 0, '', [], True, False, False, False, 0) {}
    Traceback (most recent call last):
      File "C:\Stable_Diffusion\stable-diffusion-webui\modules\call_queue.py", line 58, in f
        res = list(func(*args, **kwargs))
      File "C:\Stable_Diffusion\stable-diffusion-webui\modules\call_queue.py", line 37, in f
        res = func(*args, **kwargs)
      File "C:\Stable_Diffusion\stable-diffusion-webui\modules\txt2img.py", line 59, in txt2img
        processed = modules.scripts.scripts_txt2img.run(p, *args)
      File "C:\Stable_Diffusion\stable-diffusion-webui\modules\scripts.py", line 501, in run
        processed = script.run(p, *script_args)
      File "C:\Stable_Diffusion\stable-diffusion-webui\scripts\openvino_accelerate.py", line 774, in run
        processed = process_images_openvino(p, model_config, p.sampler_name, enable_caching, openvino_device, mode)
      File "C:\Stable_Diffusion\stable-diffusion-webui\scripts\openvino_accelerate.py", line 579, in process_images_openvino
        output = shared.sd_diffusers_model(
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\utils\_contextlib.py", line 115, in decorate_context
        return func(*args, **kwargs)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\diffusers\pipelines\stable_diffusion\pipeline_stable_diffusion.py", line 728, in __call__
        noise_pred = self.unet(
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\nn\modules\module.py", line 1522, in _wrapped_call_impl
        return self._call_impl(*args, **kwargs)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\nn\modules\module.py", line 1531, in _call_impl
        return forward_call(*args, **kwargs)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\eval_frame.py", line 294, in _fn
        return fn(*args, **kwargs)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\nn\modules\module.py", line 1522, in _wrapped_call_impl
        return self._call_impl(*args, **kwargs)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\nn\modules\module.py", line 1531, in _call_impl
        return forward_call(*args, **kwargs)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\eval_frame.py", line 447, in catch_errors
        return callback(frame, cache_size, hooks, frame_state)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\convert_frame.py", line 531, in _convert_frame
        result = inner_convert(frame, cache_size, hooks, frame_state)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\convert_frame.py", line 127, in _fn
        return fn(*args, **kwargs)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\convert_frame.py", line 360, in _convert_frame_assert
        return _compile(
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\utils.py", line 179, in time_wrapper
        r = func(*args, **kwargs)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\convert_frame.py", line 430, in _compile
        out_code = transform_code_object(code, transform)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\bytecode_transformation.py", line 1002, in transform_code_object
        transformations(instructions, code_options)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\convert_frame.py", line 415, in transform
        tracer.run()
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\symbolic_convert.py", line 2053, in run
        super().run()
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\symbolic_convert.py", line 726, in run
        and self.step()
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\symbolic_convert.py", line 686, in step
        getattr(self, inst.opname)(inst)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\symbolic_convert.py", line 2141, in RETURN_VALUE
        self.output.compile_subgraph(
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\output_graph.py", line 804, in compile_subgraph
        self.compile_and_call_fx_graph(tx, pass2.graph_output_vars(), root)
      File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.3056.0_x64__qbz5n2kfra8p0\lib\contextlib.py", line 79, in inner
        return func(*args, **kwds)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\output_graph.py", line 904, in compile_and_call_fx_graph
        compiled_fn = self.call_user_compiler(gm)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\utils.py", line 179, in time_wrapper
        r = func(*args, **kwargs)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\output_graph.py", line 960, in call_user_compiler
        raise BackendCompilerFailed(self.compiler_fn, e).with_traceback(
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\output_graph.py", line 956, in call_user_compiler
        compiled_fn = compiler_fn(gm, self.example_inputs())
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\repro\after_dynamo.py", line 117, in debug_wrapper
        compiled_gm = compiler_fn(gm, example_inputs)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\__init__.py", line 1586, in __call__
        return self.compiler_fn(model_, inputs_, **self.kwargs)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\backends\common.py", line 95, in wrapper
        return fn(model, inputs, **kwargs)
      File "C:\Stable_Diffusion\stable-diffusion-webui\scripts\openvino_accelerate.py", line 146, in openvino_fx
        return compile_fx(subgraph, example_inputs)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_inductor\compile_fx.py", line 1043, in compile_fx
        return aot_autograd(
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\backends\common.py", line 55, in compiler_fn
        cg = aot_module_simplified(gm, example_inputs, **kwargs)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_functorch\aot_autograd.py", line 3750, in aot_module_simplified
        compiled_fn = create_aot_dispatcher_function(
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\utils.py", line 179, in time_wrapper
        r = func(*args, **kwargs)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_functorch\aot_autograd.py", line 3289, in create_aot_dispatcher_function
        compiled_fn = compiler_fn(flat_fn, fake_flat_args, aot_config, fw_metadata=fw_metadata)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_functorch\aot_autograd.py", line 2098, in aot_wrapper_dedupe
        return compiler_fn(flat_fn, leaf_flat_args, aot_config, fw_metadata=fw_metadata)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_functorch\aot_autograd.py", line 2278, in aot_wrapper_synthetic_base
        return compiler_fn(flat_fn, flat_args, aot_config, fw_metadata=fw_metadata)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_functorch\aot_autograd.py", line 1552, in aot_dispatch_base
        compiled_fw = compiler(fw_module, flat_args)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\utils.py", line 179, in time_wrapper
        r = func(*args, **kwargs)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_inductor\compile_fx.py", line 985, in fw_compiler_base
        return inner_compile(
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\repro\after_aot.py", line 80, in debug_wrapper
        inner_compiled_fn = compiler_fn(gm, example_inputs)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_inductor\debug.py", line 220, in inner
        return fn(*args, **kwargs)
      File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.3056.0_x64__qbz5n2kfra8p0\lib\contextlib.py", line 79, in inner
        return func(*args, **kwds)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_inductor\compile_fx.py", line 48, in newFunction
        return old_func(*args, **kwargs)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_inductor\compile_fx.py", line 303, in compile_fx_inner
        compiled_graph: CompiledFxGraph = fx_codegen_and_compile(
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_inductor\compile_fx.py", line 515, in fx_codegen_and_compile
        compiled_fn = graph.compile_to_fn()
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_inductor\graph.py", line 918, in compile_to_fn
        return self.compile_to_module().call
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\utils.py", line 179, in time_wrapper
        r = func(*args, **kwargs)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_inductor\graph.py", line 887, in compile_to_module
        code, linemap = self.codegen()
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_inductor\graph.py", line 838, in codegen
        self.scheduler.codegen()
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_dynamo\utils.py", line 179, in time_wrapper
        r = func(*args, **kwargs)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_inductor\scheduler.py", line 1442, in codegen
        self.get_backend(device).codegen_nodes(node.get_nodes())
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_inductor\codegen\cpp.py", line 2719, in codegen_nodes
        kernel_group.finalize_kernel(cpp_kernel_proxy, nodes)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_inductor\codegen\cpp.py", line 2746, in finalize_kernel
        new_kernel.codegen_loops(code, ws)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_inductor\codegen\cpp.py", line 2669, in codegen_loops
        self.codegen_loops_impl(self.loop_nest, code, worksharing)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_inductor\codegen\cpp.py", line 1372, in codegen_loops_impl
        gen_loops(loop_nest.root)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_inductor\codegen\cpp.py", line 1344, in gen_loops
        gen_loop(loop, in_reduction)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_inductor\codegen\cpp.py", line 1364, in gen_loop
        gen_loops(loop.inner, loop.is_reduction())
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_inductor\codegen\cpp.py", line 1344, in gen_loops
        gen_loop(loop, in_reduction)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_inductor\codegen\cpp.py", line 1357, in gen_loop
        loop_lines = loop.lines()
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_inductor\codegen\cpp.py", line 2989, in lines
        elif not self.reduction_var_map and codecache.is_gcc():
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_inductor\codecache.py", line 424, in is_gcc
        return re.search(r"(gcc|g\+\+)", cpp_compiler())
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_inductor\codecache.py", line 367, in cpp_compiler
        return cpp_compiler_search(search)
      File "C:\Stable_Diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\_inductor\codecache.py", line 394, in cpp_compiler_search
        raise exc.InvalidCxxCompiler()
    torch._dynamo.exc.BackendCompilerFailed: backend='openvino_fx' raised:
    InvalidCxxCompiler: No working C++ compiler found in torch._inductor.config.cpp.cxx: (None, 'g++')

    You can suppress this exception and fall back to eager by setting:
        import torch._dynamo
        torch._dynamo.config.suppress_errors = True

Additional information

No response

UltraOrder commented 1 year ago

have the exact same problem

devangaggarwal commented 1 year ago

This is WIP here: https://github.com/openvinotoolkit/stable-diffusion-webui/pull/19