ITADN

Issue with `UI_chat.py`, no attribute `texture_paths`

#29Openbsuvonov 创建于 2025-06-28
B
bsuvonovcommented
Hi, I am having the following problem: ``` user@DESKTOP-OHRIT5I MINGW64 ~/Desktop/research/DressCode (main) $ python nn/UI_chat.py C:\Users\user\miniconda3\envs\dresscode310\lib\site-packages\langchain\chat_models\__init__.py:33: LangChainDeprecationWarning: Importing chat models from langchain is deprecated. Importing from langchain will no longer be supported as of langchain==0.2.0. Please import from langchain-community instead: `from langchain_community.chat_models import ChatOpenAI`. To install langchain-community run `pip install -U langchain-community`. warnings.warn( C:\Users\user\miniconda3\envs\dresscode310\lib\site-packages\langchain\chat_models\__init__.py:33: LangChainDeprecationWarning: Importing chat models from langchain is deprecated. Importing from langchain will no longer be supported as of langchain==0.2.0. Please import from langchain-community instead: `from langchain_community.chat_models import ChatOpenAI`. To install langchain-community run `pip install -U langchain-community`. warnings.warn( C:\Users\user\miniconda3\envs\dresscode310\lib\site-packages\langchain\__init__.py:30: UserWarning: Importing PromptTemplate from langchain root module is no longer supported. Please use langchain_core.prompts. PromptTemplate instead. warnings.warn( C:\Users\user\miniconda3\envs\dresscode310\lib\site-packages\langchain\__init__.py:30: UserWarning: Importing LLMChain from langchain root module is no longer supported. Please use langchain.chains.LLMChain ins tead. warnings.warn( ExperimentWrappper::Warning::Requested status of run not connected to wandb ExperimentWrappper::Warning::Skipping loading split file from cloud.. ExperimentWrappper::Warning::Skipping loading panel classes file from cloud.. ExperimentWrappper::Warning::Skipping loading parameter filter file from cloud.. [INFO] loading stable diffusion... Loading pipeline components...: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 6/6 [00:00<00:00, 6.83it/s] [INFO] loaded stable diffusion! ExperimentWrappper::Warning::Skipping loading split file from cloud.. ExperimentWrappper::Warning::Skipping loading panel classes file from cloud.. ExperimentWrappper::Warning::Skipping loading parameter filter file from cloud.. numel = 103.8 M parameters ExperimentWrappper::Info::Loading locally saved model [Reading file from...] ./models/checkpoint.pth Loading pipeline components...: 100%|██████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 6/6 [00:08<00:00, 1.40s/it] You have disabled the safety checker for <class 'diffusers.pipelines.stable_diffusion.pipeline_stable_diffusion.StableDiffusionPipeline'> by passing `safety_checker=None`. Ensure that you abide to the condition s of the Stable Diffusion license and do not expose unfiltered results in services or applications open to the public. Both the diffusers team and Hugging Face strongly recommend to keep the safety filter enabl ed in all public facing circumstances, disabling it only for use-cases that involve analyzing network behavior or auditing its results. For more information, please have a look at https://github.com/huggingface /diffusers/pull/254 . C:\Users\user\Desktop\research\DressCode\nn\UI_chat.py:254: UserWarning: You have not specified a value for the `type` parameter. Defaulting to the 'tuples' format for chatbot messages, but this is deprecated a nd will be removed in a future version of Gradio. Please set type='messages' instead, which uses openai-style dictionaries with 'role' and 'content' keys. chatbot = gr.Chatbot(height=500) C:\Users\user\Desktop\research\DressCode\nn\UI_chat.py:258: UserWarning: You have not specified a value for the `type` parameter. Defaulting to the 'tuples' format for chatbot messages, but this is deprecated a nd will be removed in a future version of Gradio. Please set type='messages' instead, which uses openai-style dictionaries with 'role' and 'content' keys. output_images = gr.Chatbot(height=500) * Running on local URL: http://127.0.0.1:7860/ * To create a public link, set `share=True` in `launch()`. Traceback (most recent call last): File "C:\Users\user\miniconda3\envs\dresscode310\lib\site-packages\gradio\queueing.py", line 625, in process_events response = await route_utils.call_process_api( File "C:\Users\user\miniconda3\envs\dresscode310\lib\site-packages\gradio\route_utils.py", line 322, in call_process_api output = await app.get_blocks().process_api( File "C:\Users\user\miniconda3\envs\dresscode310\lib\site-packages\gradio\blocks.py", line 2220, in process_api result = await self.call_function( File "C:\Users\user\miniconda3\envs\dresscode310\lib\site-packages\gradio\blocks.py", line 1731, in call_function prediction = await anyio.to_thread.run_sync( # type: ignore File "C:\Users\user\miniconda3\envs\dresscode310\lib\site-packages\anyio\to_thread.py", line 56, in run_sync return await get_async_backend().run_sync_in_worker_thread( File "C:\Users\user\miniconda3\envs\dresscode310\lib\site-packages\anyio\_backends\_asyncio.py", line 2470, in run_sync_in_worker_thread return await future File "C:\Users\user\miniconda3\envs\dresscode310\lib\site-packages\anyio\_backends\_asyncio.py", line 967, in run result = context.run(func, *args) File "C:\Users\user\miniconda3\envs\dresscode310\lib\site-packages\gradio\utils.py", line 904, in wrapper response = f(*args, **kwargs) File "C:\Users\user\Desktop\research\DressCode\nn\UI_chat.py", line 230, in predict os.system('copy ' + self.texture_paths[-1] + ' ' + self.texture_paths[-1].split('.')[0] + '_backup.png') AttributeError: 'UI_interface' object has no attribute 'texture_paths' ``` does anyone have any idea? I'd appreciate your feedback @IHe-KaiI
0 条评论