jina-ai / discoart

🪩 Create Disco Diffusion artworks in one line
Other
3.84k stars 249 forks source link

Unicode prompt problem running on Windows #172

Open fastrocket opened 2 years ago

fastrocket commented 2 years ago

I don't have this problem on Colab, but when I run DiscoArt on my Windows 11 PC, I get this error when I add in names of artists with non-English characters like zdzisław beksiński (the L and N with accent marks) to the prompts:

`UnicodeEncodeError

'charmap' codec can't encode character '\u0142' in position 29: character maps to <undefined>
*** You may need to add PYTHONIOENCODING=utf-8 to your environment ***

I've tried setting these environment variables and they don't fix it:

import os

os.environ['PYTHONIOENCODING']='utf-8'
os.environ['PYTHONUTF8']='1'