Skip to main content

Python Potrace

Pure Python Port of Potrace. This is a python port of Peter Selinger's Potrace (based on 1.16 code).

head-orig3

This port is needed because many python hooks to the original code such as pypotrace have installation issues and compilation problems with some OSes. This potrace is written in pure python and will be compatible with basically anything.

Installing

To install or use as a requirement:

  • pip install potracer

Potrace-CLI

If you wish to use the Command Line Interface that is stored in a sister project potrace-cli (https://github.com/tatarize/potrace-cli). This can be installed with:

  • pip install potracer[cli]

or:

  • pip install potrace-cli

The cli project contains valid console script entrypoints for potrace. If you install the command-line package it will add potracer to your console scripts. Note the -r suffix so that it does not interfere with potrace that may be otherwise installed.

Requirements

  • numpy: for bitmap structures.

Speed

Being written in python this code may be about 500x slower than the pure-c potrace. It is however fast enough for general use.

Parallel Projects

This project intentionally duplicates a considerable amount of the API of pypotrace such that this library can be used as a drop-in replacement.

This library offers CLI potrace as an optional package, to permit performing potrace commands from the commandline.

License

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2, or (at your option) any later version.

Furthermore, this is permitted to be relicensed under any terms the Peter Selinger's original Potrace is licensed under. If he broadly publishes the software under a more permissive license this port should be considered licensed as such as well. Further, if you purchase a proprietary license for inclusion within commercial software under his Dual Licensing program your use of this software shall be under whatever terms he permits for that. Any contributions to this port must be made under equally permissive terms.

"Potrace" is a trademark of Peter Selinger. Permission granted by Peter Selinger.

Release files for potracer 0.0.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for potracer 0.0.4
File Size Uploaded
potracer-0.0.4.tar.gz 19.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for potracer 0.0.4
File Interpreter ABI Platform
potracer-0.0.4-py2.py3-none-any.whl Python 3, Python 2 none any Details

Total release size: 44.2 kB

Release files / potracer-0.0.4.tar.gz

Download URL potracer-0.0.4.tar.gz
Size 19.3 kB
Tags Source
SHA-256 checksum
How to use checksums
32cbdb984446066bcfbe8b600142a54b90fa6da274b69219473205d6e4c09713
BLAKE2b-256 checksum
How to use checksums
d45fd84189372d95ffd144ae515907f775d385863dc3fb7e123331428c8a2a3e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.2.0 pkginfo/1.6.1 requests/2.23.0 setuptools/51.0.0 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.8.5

Release files / potracer-0.0.4-py2.py3-none-any.whl

Download URL potracer-0.0.4-py2.py3-none-any.whl
Size 24.9 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
350bb2c7c8532059165264974617d460999e0215cf2f459c0616fa8805c27ce6
BLAKE2b-256 checksum
How to use checksums
441b98a371d1b72cf004555698362266889a87c9bb0bed14a814652b32972034
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.2.0 pkginfo/1.6.1 requests/2.23.0 setuptools/51.0.0 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.8.5

Release history Release notifications | RSS feed

This release

0.0.4 This release

2 release files

0.0.2

2 release files

0.0.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page