GeorgLegato / Txt2Vectorgraphics

Custom Script for Automatics1111 StableDiffusion-WebUI.
GNU General Public License v3.0
362 stars 29 forks source link

Potracer issue #11

Closed fredm00n closed 1 year ago

fredm00n commented 1 year ago

I'm using your script on a Google Colab but there's an issue with Portrace

Error completing request
Arguments: ('mona lisa kurzgesagt style', '', 'None', 'None', 20, 0, False, False, 1, 1, 7, -1.0, -1.0, 0, 0, 0, False, 512, 512, False, 0.7, 0, 0, 3, False, False, False, None, '', 'Illustration', 'svg', True, True, False, 0.5, True, 16, True, 16, 1, '', 0, '', True, False, False) {}
Traceback (most recent call last):
  File "/content/gdrive/MyDrive/sd/stable-diffusion-webui/scripts/txt2vectorgfx.py", line 201, in check_Potrace_install
    checkPath = subprocess.Popen(["potrace","-v"])
  File "/usr/lib/python3.7/subprocess.py", line 800, in __init__
    restore_signals, start_new_session)
  File "/usr/lib/python3.7/subprocess.py", line 1551, in _execute_child
    raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'potrace': 'potrace'

I tried running pip install potracer

pip install potracer
Looking in indexes: https://pypi.org/simple, https://us-python.pkg.dev/colab-wheels/public/simple/
Collecting potracer
  Downloading potracer-0.0.4-py2.py3-none-any.whl (24 kB)
Requirement already satisfied: numpy in /usr/local/lib/python3.7/dist-packages (from potracer) (1.21.6)
Installing collected packages: potracer
Successfully installed potracer-0.0.4

But still getting the same error. Any help much appreciated :)

GeorgLegato commented 1 year ago

the script does not use the python ported potracer (for some good reasons). instead, follow readme.md; on linux do "sudo apt install potracer" or on mac "brew install potracer". if on windows, the script actually donwloads the potracer.exe from the sourceforge-site.

Since you are on a Collab, it could not work at all. Not tested here