I can get the .pnm.svg results I want using the Trace Bitmap tool in the Inkscape GUI. If I understand it correctly, that tool is just a front end to Potrace. Is there a way to see what Inkscape is telling Potrace such that I can recreate the steps using the Potrace CLI? (I want to trace a bunch of .pnm's, but it sounds like Inkscape's CLI can't do tracing)

I'm on a Mac which maybe cuts out the Potracegui solution.

The specific setup I have in Inkscape is:

  • Multicolor
  • Colors Detection mode
  • 4 scans
  • Smooth enabled
  • Stack enabled
  • Remove background enabled
  • Speckles disable
  • Smooth corners set to 1.00
  • Optimize set to 0.200

1 Answer 1


Billy's linked question was helpful, but unfortunately Potrace only does black and white tracing and I couldn't use the windows binary provided. Instead, I found this post on the Inkscape forum that linked to this github repo. I was eventually able to get it up and running with a few caveats:

  1. You need a version of Python at least 3.2 to get color_trace to run, but it can't be past 3.7 since "multiprocessing.Process itself is not picklable as of Python 3.7". I eventually went with Python 3.6.15
  2. Inkscape seemed to handle tracing transparent backgrounds okay, but color_trace won't AFAICT. I used mogrify -background white -alpha remove -alpha off *.png from here to set all the backgrounds to white before tracing.
  3. After that python color_trace_multi.py -i source/*.png -d output/ -c 5 -s -bg gave me pretty much what I had in Inkscape at scale.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.