n00mkrad / text2image-gui

Somewhat modular text2image GUI, initially just for Stable Diffusion
GNU General Public License v3.0
921 stars 93 forks source link

Input path in spanish #71

Closed washinoboku closed 1 year ago

washinoboku commented 1 year ago

My version of Windows is in Spanish, so my input path has the word "imágenes". It doesn't like the tick in the "a".

This window displays all messages that are logged while it's open. [01-25-2023 03:29:46] [general] HasBins - Has Python: True - Has Git: True - Has WKL: True - Has OK: True [01-25-2023 03:29:46] [general] HasSdRepo - Has invoke.py: True [01-25-2023 03:29:46] [general] HasSdEnv - Has Python Exe: True - Has Pytorch: True [01-25-2023 03:29:46] [general] SetState(ImageGeneration) [01-25-2023 03:29:46] [general] Importing initialization images... [01-25-2023 03:29:46] [general] ExportLoop START [01-25-2023 03:29:46] [general] Imported 1 image(s). [01-25-2023 03:29:46] [general] Running Stable Diffusion - 1 Iterations, 1 Steps, Scales 8, Starting Seed: 1156550453 [01-25-2023 03:29:46] [general] 1 prompt 1 image 1 step value * 1 scale and 1 image using 1 strength = 1 images total. [01-25-2023 03:29:46] [general] cmd.exe /C cd /D "T:\IA\SD-GUI\Data" && SET "PATH=./venv/Scripts;./py/Scripts;./py;./git/cmd;C:/Windows/system32;C:/Windows;C:/Windows/System32/Wbem;C:/Windows/System32/WindowsPowerShell/v1.0/;C:/Windows/System32/OpenSSH/;" && SET "TORCH_HOME=T:\IA\SD-GUI\Data\cache\torch" && python "repo/sd_ip2p/ip2p_batch.py" -j "T:/IA/SD-GUI/Data/sessions/2023-01-25-03-12-23/prompts-ip2p.json" -o "T:/IA/SD-GUI/Data/sessions/2023-01-25-03-12-23/out" [01-25-2023 03:29:46] [general] Loading Stable Diffusion (InstructPix2Pix)... [01-25-2023 03:29:51] [sd] text_encoder\model.safetensors not found [01-25-2023 03:29:51] [sd] Fetching 15 files: 0%| | 0/15 [00:00<?, ?it/s] [01-25-2023 03:29:51] [sd] Fetching 15 files: 100%|##########| 15/15 [00:00<00:00, 677.57it/s] [01-25-2023 03:29:53] [sd] You have disabled the safety checker for <class 'diffusers.pipelines.stable_diffusion.pipeline_stable_diffusion_instruct_pix2pix.StableDiffusionInstructPix2PixPipeline'> by passing safety_checker=None. Ensure that you abide to the conditions 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 enabled 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 . [01-25-2023 03:29:54] [sd] Model loaded. [01-25-2023 03:29:54] [general] Model loaded. [01-25-2023 03:29:54] [sd] Generating 1/1: Prompt: change red for green - Neg Prompt: - Steps: 25 - Seed: 1156550453 - Text Scale 8.0 - Image Scale 1.5 [01-25-2023 03:29:54] [sd] Using seed 1156550453 [01-25-2023 03:29:54] [sd] Traceback (most recent call last): [01-25-2023 03:29:54] [sd] File "T:\IA\SD-GUI\Data\repo\sd_ip2p\ip2p_batch.py", line 80, in [01-25-2023 03:29:54] [sd] generate(inpath, prompt, prompt_neg, seed, cfg_txt, cfg_img) [01-25-2023 03:29:54] [sd] File "T:\IA\SD-GUI\Data\repo\sd_ip2p\ip2p_batch.py", line 53, in generate [01-25-2023 03:29:54] [sd] image = PIL.Image.open(inpath) [01-25-2023 03:29:54] [sd] File "T:\IA\SD-GUI\Data\venv\lib\site-packages\PIL\Image.py", line 3092, in open [01-25-2023 03:29:54] [sd] fp = builtins.open(filename, "rb") [01-25-2023 03:29:54] [sd] FileNotFoundError: [Errno 2] No such file or directory: 'T:\Mis Documentos\Mis imágenes\Espejo\Sacar\20220524164048-3532118984.png' [01-25-2023 03:29:54] [general] ExportLoop: Breaking. Process running: False - Any files exist: False [01-25-2023 03:29:54] [general] ExportLoop END [01-25-2023 03:29:54] [general] No images generated. [01-25-2023 03:29:54] [general] SetState(Standby)

fireYtail commented 1 year ago

Don't expect any luck, I use Spanish Windows too and they just ignore the issues I report from the GUI not accepting European characters configuration. It keeps using commas (",") but interpreting them as separators rather than decimal delimeters, it has been over a month and all they did was write a four words reply.

fireYtail commented 1 year ago

Also the new features implement the same bugs that were fixed in older versions... So don't expect them to listen or do anything about it.

fireYtail commented 1 year ago

As a workaround for non-English paths use NTFS symlinks. Since Windows Vista IIRC, user account folders such as "Mis imágenes", "Mis documentos", etc aren't real folders but symlinks to the hidden corresponding folders with English names ("Pictures", "Documents"...). If you open the run dialog (Windows key + R) and type "C:\Users\YourName\Pictures" it's the same as if you type "C:\Documents and Settings\YourName\Mis imágenes". Microsoft makes it this way for compatibility. Windows 10 still has symlinks for compatibility with Windows XP programs. Too bad Microsoft cares but software developers do not. For software developers, English is the only regional configuration that exists or matters. The world = USA.

It really makes me tired and angry to have to always restrict my paths to English characters, and often to short paths with no spaces, or else all software stops working. Nothing new under the sun.

n00mkrad commented 1 year ago

Fixed in https://github.com/n00mkrad/stable-diffusion-cust/commit/00ab53084f0e6bec5123afd762e66776727fa152