NVIDIA / Stable-Diffusion-WebUI-TensorRT

TensorRT Extension for Stable Diffusion Web UI
MIT License
1.91k stars 145 forks source link

AttributeError: 'FakeInitialModel' object has no attribute 'is_sdxl' #345

Open jswag245 opened 3 weeks ago

jswag245 commented 3 weeks ago

Hi, I have successfully installed TensorRT on Forge WebUI. I am receiving the following error after trying to generate a default model in the TensorRT tab. The models I am using are SDXL models.

Traceback (most recent call last): File "C:\Users\JS\Downloads\webui_forge_cu121_torch231\system\python\lib\site-packages\gradio\queueing.py", line 536, in process_events response = await route_utils.call_process_api( File "C:\Users\JS\Downloads\webui_forge_cu121_torch231\system\python\lib\site-packages\gradio\route_utils.py", line 285, in call_process_api output = await app.get_blocks().process_api( File "C:\Users\JS\Downloads\webui_forge_cu121_torch231\system\python\lib\site-packages\gradio\blocks.py", line 1923, in process_api result = await self.call_function( File "C:\Users\JS\Downloads\webui_forge_cu121_torch231\system\python\lib\site-packages\gradio\blocks.py", line 1508, in call_function prediction = await anyio.to_thread.run_sync( # type: ignore File "C:\Users\JS\Downloads\webui_forge_cu121_torch231\system\python\lib\site-packages\anyio\to_thread.py", line 33, in run_sync return await get_asynclib().run_sync_in_worker_thread( File "C:\Users\JS\Downloads\webui_forge_cu121_torch231\system\python\lib\site-packages\anyio_backends_asyncio.py", line 877, in run_sync_in_worker_thread return await future File "C:\Users\JS\Downloads\webui_forge_cu121_torch231\system\python\lib\site-packages\anyio_backends_asyncio.py", line 807, in run result = context.run(func, args) File "C:\Users\JS\Downloads\webui_forge_cu121_torch231\system\python\lib\site-packages\gradio\utils.py", line 818, in wrapper response = f(args, **kwargs) File "C:\Users\JS\Downloads\webui_forge_cu121_torch231\webui\extensions\Stable-Diffusion-WebUI-TensorRT\ui_trt.py", line 64, in export_unet_to_trt is_xl = shared.sd_model.is_sdxl AttributeError: 'FakeInitialModel' object has no attribute 'is_sdxl'

Notabey commented 1 week ago

I‘m having the same issue. It seems like this extension doesn't work on Forge since codes in \modules are different. Yomisana/Stable-Diffusion-WebUI-TensorRT-Enhanced/#1

Yomisana commented 1 week ago

I‘m having the same issue. It seems like this extension doesn't work on Forge since codes in \modules are different. Yomisana/Stable-Diffusion-WebUI-TensorRT-Enhanced/#1

only export can't use...cause it is forge comment out the code about hijack modules, sub folder modules...etc may need ask for SDW forge endpoint want release some detail about dev docs replace modules node.