ddPn08 / Radiata

Stable diffusion webui based on diffusers.
https://ddpn08.github.io/Radiata/
Apache License 2.0
983 stars 68 forks source link

Model build error #30

Closed Daniel-Kelvich closed 1 year ago

Daniel-Kelvich commented 1 year ago
lsmith-lsmith-1  |   if any(s % default_overall_up_factor != 0 for s in sample.shape[-2:]):
lsmith-lsmith-1  | ERROR:    Exception in ASGI application
lsmith-lsmith-1  | Traceback (most recent call last):
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/uvicorn/protocols/http/h11_impl.py", line 407, in run_asgi
lsmith-lsmith-1  |     result = await app(  # type: ignore[func-returns-value]
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/uvicorn/middleware/proxy_headers.py", line 78, in __call__
lsmith-lsmith-1  |     return await self.app(scope, receive, send)
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/fastapi/applications.py", line 270, in __call__
lsmith-lsmith-1  |     await super().__call__(scope, receive, send)
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/starlette/applications.py", line 124, in __call__
lsmith-lsmith-1  |     await self.middleware_stack(scope, receive, send)
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/errors.py", line 184, in __call__
lsmith-lsmith-1  |     raise exc
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/errors.py", line 162, in __call__
lsmith-lsmith-1  |     await self.app(scope, receive, _send)
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/cors.py", line 92, in __call__
lsmith-lsmith-1  |     await self.simple_response(scope, receive, send, request_headers=headers)
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/cors.py", line 147, in simple_response
lsmith-lsmith-1  |     await self.app(scope, receive, send)
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/exceptions.py", line 79, in __call__
lsmith-lsmith-1  |     raise exc
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/starlette/middleware/exceptions.py", line 68, in __call__
lsmith-lsmith-1  |     await self.app(scope, receive, sender)
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/fastapi/middleware/asyncexitstack.py", line 21, in __call__
lsmith-lsmith-1  |     raise e
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/fastapi/middleware/asyncexitstack.py", line 18, in __call__
lsmith-lsmith-1  |     await self.app(scope, receive, send)
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 706, in __call__
lsmith-lsmith-1  |     await route.handle(scope, receive, send)
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 276, in handle
lsmith-lsmith-1  |     await self.app(scope, receive, send)
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/starlette/routing.py", line 69, in app
lsmith-lsmith-1  |     await response(scope, receive, send)
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/starlette/responses.py", line 266, in __call__
lsmith-lsmith-1  |     async with anyio.create_task_group() as task_group:
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/anyio/_backends/_asyncio.py", line 662, in __aexit__
lsmith-lsmith-1  |     raise exceptions[0]
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/starlette/responses.py", line 269, in wrap
lsmith-lsmith-1  |     await func()
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/starlette/responses.py", line 258, in stream_response
lsmith-lsmith-1  |     async for chunk in self.body_iterator:
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/starlette/concurrency.py", line 63, in iterate_in_threadpool
lsmith-lsmith-1  |     yield await anyio.to_thread.run_sync(_next, iterator)
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/anyio/to_thread.py", line 31, in run_sync
lsmith-lsmith-1  |     return await get_asynclib().run_sync_in_worker_thread(
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/anyio/_backends/_asyncio.py", line 937, in run_sync_in_worker_thread
lsmith-lsmith-1  |     return await future
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/anyio/_backends/_asyncio.py", line 867, in run
lsmith-lsmith-1  |     result = context.run(func, *args)
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/starlette/concurrency.py", line 53, in _next
lsmith-lsmith-1  |     return next(iterator)
lsmith-lsmith-1  |   File "/app/./modules/diffusion/tensorrt/engine.py", line 154, in build
lsmith-lsmith-1  |     engine = build_engine(
lsmith-lsmith-1  |   File "/app/./modules/diffusion/tensorrt/engine.py", line 46, in build_engine
lsmith-lsmith-1  |     torch.onnx.export(
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/torch/onnx/__init__.py", line 350, in export
lsmith-lsmith-1  |     return utils.export(
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/torch/onnx/utils.py", line 163, in export
lsmith-lsmith-1  |     _export(
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/torch/onnx/utils.py", line 1074, in _export
lsmith-lsmith-1  |     graph, params_dict, torch_out = _model_to_graph(
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/torch/onnx/utils.py", line 727, in _model_to_graph
lsmith-lsmith-1  |     graph, params, torch_out, module = _create_jit_graph(model, args)
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/torch/onnx/utils.py", line 602, in _create_jit_graph
lsmith-lsmith-1  |     graph, torch_out = _trace_and_get_graph_from_model(model, args)
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/torch/onnx/utils.py", line 517, in _trace_and_get_graph_from_model
lsmith-lsmith-1  |     trace_graph, torch_out, inputs_states = torch.jit._get_trace_graph(
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/torch/jit/_trace.py", line 1175, in _get_trace_graph
lsmith-lsmith-1  |     outs = ONNXTracedModule(f, strict, _force_outplace, return_inputs, _return_inputs_states)(*args, **kwargs)
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/torch/nn/modules/module.py", line 1130, in _call_impl
lsmith-lsmith-1  |     return forward_call(*input, **kwargs)
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/torch/jit/_trace.py", line 127, in forward
lsmith-lsmith-1  |     graph, out = torch._C._create_graph_by_tracing(
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/torch/jit/_trace.py", line 118, in wrapper
lsmith-lsmith-1  |     outs.append(self.inner(*trace_inputs))
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/torch/nn/modules/module.py", line 1130, in _call_impl
lsmith-lsmith-1  |     return forward_call(*input, **kwargs)
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/torch/nn/modules/module.py", line 1118, in _slow_forward
lsmith-lsmith-1  |     result = self.forward(*input, **kwargs)
lsmith-lsmith-1  |   File "/app/./submodules/diffusers_0_7_2/src/diffusers/models/unet_2d_condition.py", line 301, in forward
lsmith-lsmith-1  |     sample = self.conv_in(sample)
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/torch/nn/modules/module.py", line 1130, in _call_impl
lsmith-lsmith-1  |     return forward_call(*input, **kwargs)
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/torch/nn/modules/module.py", line 1118, in _slow_forward
lsmith-lsmith-1  |     result = self.forward(*input, **kwargs)
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/torch/nn/modules/conv.py", line 457, in forward
lsmith-lsmith-1  |     return self._conv_forward(input, self.weight, self.bias)
lsmith-lsmith-1  |   File "/usr/local/lib/python3.10/dist-packages/torch/nn/modules/conv.py", line 453, in _conv_forward
lsmith-lsmith-1  |     return F.conv2d(input, weight, bias, self.stride,
lsmith-lsmith-1  | RuntimeError: cuDNN error: CUDNN_STATUS_NOT_INITIALIZED
ddPn08 commented 1 year ago

It's probably related to #29. I fixed it earlier, so please check again.

ddPn08 commented 1 year ago

Apparently it had nothing to do with #29. We are currently investigating.

dsully commented 1 year ago

Seeing this error as well.

ddPn08 commented 1 year ago

Closing this issue as the project has been significantly updated. Please reopen if you still have problems.