ironjr / StreamMultiDiffusion

Official code for the paper "StreamMultiDiffusion: Real-Time Interactive Generation with Region-Based Semantic Control."
https://jaerinlee.com/research/streammultidiffusion
MIT License
518 stars 43 forks source link

UnicodeDecodeError。 #5

Closed DreamLoveBetty closed 5 months ago

DreamLoveBetty commented 5 months ago

(venv) D:\Program\StreamMultiDiffusion\demo\semantic_palette>python app.py Traceback (most recent call last): File "D:\Program\StreamMultiDiffusion\demo\semantic_palette\app.py", line 39, in import gradio as gr File "D:\Program\StreamMultiDiffusion\venv\lib\site-packages\gradio__init.py", line 3, in import gradio._simple_templates File "D:\Program\StreamMultiDiffusion\venv\lib\site-packages\gradio_simple_templates__init.py", line 1, in from .simpledropdown import SimpleDropdown File "D:\Program\StreamMultiDiffusion\venv\lib\site-packages\gradio_simple_templates\simpledropdown.py", line 6, in from gradio.components.base import FormComponent File "D:\Program\StreamMultiDiffusion\venv\lib\site-packages\gradio\components\init__.py", line 40, in from gradio.components.multimodal_textbox import MultimodalTextbox File "D:\Program\StreamMultiDiffusion\venv\lib\site-packages\gradio\components\multimodal_textbox.py", line 34, in class MultimodalTextbox(FormComponent): File "D:\Program\StreamMultiDiffusion\venv\lib\site-packages\gradio\component_meta.py", line 198, in new__ create_or_modify_pyi(component_class, name, events) File "D:\Program\StreamMultiDiffusion\venv\lib\site-packages\gradio\component_meta.py", line 92, in create_or_modify_pyi source_code = source_file.read_text() File "C:\Users\H\AppData\Local\Programs\Python\Python310\lib\pathlib.py", line 1135, in read_text return f.read() c: 'gbk' codec can't decode byte 0xb2 in position 2074: illegal multibyte sequence

Additionally, there is no "app. py" in the root directory, only "app. py" in the demo directory?

ironjr commented 5 months ago
  1. It seems like a gradio bug. I have found similar issue here. It seems like newer version of gradio raises error when opened with non-English environment. Please try this in your venv:

    pip install gradio==4.21.0

    then run again. If the error persists, please reopen this issue.

  2. Thanks for the correction. Just changed the instructions accordingly. If you want to use Semantic Palette app, cd demo/semantic_palette; python app.py --model "model here" will do as you have already tried.

DreamLoveBetty commented 5 months ago

Okay, let's give it a try now. Thank you for your answer!