Skip to main content

pygrbl-build

PyPI

A collection of algorithms to generate G-code for GRBL diode lasers from different sources, plus tooling around the G-code itself. Five generators today:

  • Line-to-Line (l2l_gcode) — raster engraving from an image, with LaserGRBL fidelity.
  • Jarvis (jarvis_gcode) — 1-bit Jarvis-Judice-Ninke error diffusion followed by the same raster G-code engine. The dots are short powered raster segments, as in LaserGRBL.
  • SVG vector (svg_gcode) — vector tracing from an SVG (paths, basic shapes, groups, transforms), a faithful port of LaserGRBL's SVG import. Pure Python, no extra dependency.
  • Image vector (img2vector_gcode) — outline tracing from a raster image (LaserGRBL's "Vectorize!"): the image is reduced to black/white, Potrace traces its outlines as closed contours, and each curve is emitted as G2/G3 arcs. Pure Python, Pillow only. Outlines only today (no interior filling yet).
  • Image to SVG (img2svg) — the same Potrace trace as img2vector_gcode, but the contours are written to a standard vector SVG instead of G-code. Inner contours become holes (fill-rule evenodd), so you get the filled black silhouette potrace.exe produces. Pure Python, Pillow only.

Plus G-code bounds & framing (get_bounding_box + generate_framing_gcode): a fast C parser for the bounding box of any G-code (file or in-memory) and a framing pass that traces it, so the operator can confirm placement before engraving.

Part of the pygrbl family, a set of libraries to manage GRBL. Companion to pygrbl-streamer and pygrbl-server

Speed

This is the whole point. A full 300 mm @ 10 lines/mm raster job — nearly 4.7 million lines of G-code — comes out in ~0.34 s. LaserGRBL can take around 2 minutes to produce the same job: that's roughly a 350× speedup, and byte-for-byte the same output.

Install

pip install pygrbl-build

The only requirements are Pillow and a C compiler. Pillow is the single Python dependency (image loading and resizing); the C compiler is needed at install time because the raster engine ships as a C extension. Nothing else — no numpy, no runtime toolchain.

Use

from pygrbl_build import L2LProfile, l2l_gcode, write_gcode

profile = L2LProfile(width_mm=300.0, lines_per_mm=10.0, feed=3000, s_max=100)
write_gcode(l2l_gcode("shield.png", profile), "shield.nc")

Documentation

  • Raster: Line-to-Line and Jarvis engraving, and the image inputs they accept.
  • Vector: SVG to G-code, image to G-code outlines, and image to SVG.
  • Bounds and framing: the bounding box of any G-code, and a framing pass around it.
  • Output: writing G-code, lazy line iterators, and the public API.
  • Changelog
  • Releasing

Metadata

Release files for pygrbl-build 1.0.2

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

Source distribution (sdist)

Source distribution for pygrbl-build 1.0.2
File Size Uploaded
pygrbl_build-1.0.2.tar.gz 51.4 kB Details

Built distributions (wheels)

Table of built distributions (wheels) for pygrbl-build 1.0.2
File
pygrbl_build-1.0.2-cp314-cp314-win_amd64.whl CPython 3.14 CPython 3.14 Windows x86-64 Details
pygrbl_build-1.0.2-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl CPython 3.14 CPython 3.14 Linux glibc 2.17+ x86-64, Linux glibc 2.28+ x86-64 Details
pygrbl_build-1.0.2-cp313-cp313-win_amd64.whl CPython 3.13 CPython 3.13 Windows x86-64 Details
pygrbl_build-1.0.2-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl CPython 3.13 CPython 3.13 Linux glibc 2.17+ x86-64, Linux glibc 2.28+ x86-64 Details
pygrbl_build-1.0.2-cp312-cp312-win_amd64.whl CPython 3.12 CPython 3.12 Windows x86-64 Details
pygrbl_build-1.0.2-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl CPython 3.12 CPython 3.12 Linux glibc 2.17+ x86-64, Linux glibc 2.28+ x86-64 Details
pygrbl_build-1.0.2-cp311-cp311-win_amd64.whl CPython 3.11 CPython 3.11 Windows x86-64 Details
pygrbl_build-1.0.2-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl CPython 3.11 CPython 3.11 Linux glibc 2.28+ x86-64, Linux glibc 2.17+ x86-64 Details
pygrbl_build-1.0.2-cp310-cp310-win_amd64.whl CPython 3.10 CPython 3.10 Windows x86-64 Details
pygrbl_build-1.0.2-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl CPython 3.10 CPython 3.10 Linux glibc 2.28+ x86-64, Linux glibc 2.17+ x86-64 Details

Total release size: 836.4 kB

Release files / pygrbl_build-1.0.2.tar.gz

Download URL pygrbl_build-1.0.2.tar.gz
Size 51.4 kB
Tags Source
SHA-256 checksum
How to use checksums
e349199b538dc83ab59f98fe5f5e12da43ca54eaed785865f933ad287175a714
BLAKE2b-256 checksum
How to use checksums
0c22e641ab2bd32500a8da1ee234dc0a03a7cb4b92502b96f2d124bb17e9d983
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 29, 2026.

Transparency log

Release files / pygrbl_build-1.0.2-cp314-cp314-win_amd64.whl

Download URL pygrbl_build-1.0.2-cp314-cp314-win_amd64.whl
Size 67.4 kB
Tags CPython 3.14 Windows x86-64
SHA-256 checksum
How to use checksums
f6cff4b687deded7f37cf83f5a91d26c1afcd8ac01146e87777f847054784b68
BLAKE2b-256 checksum
How to use checksums
90f9c3daf0a802a2c62008e1449d37a408397e88315074c73940486fcfd564cc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 29, 2026.

Transparency log

Release files / pygrbl_build-1.0.2-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl

Download URL pygrbl_build-1.0.2-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Size 90.8 kB
Tags CPython 3.14 Linux glibc 2.17+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
624cb1938fd7a915a61aeae8043494da9d51efdc08b8b251f09a031e82fd11e0
BLAKE2b-256 checksum
How to use checksums
a330b2743af7811ef4d77fc3aff6271dd3c3179a9771718d25caeec748cf9d29
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 29, 2026.

Transparency log

Release files / pygrbl_build-1.0.2-cp313-cp313-win_amd64.whl

Download URL pygrbl_build-1.0.2-cp313-cp313-win_amd64.whl
Size 66.6 kB
Tags CPython 3.13 Windows x86-64
SHA-256 checksum
How to use checksums
90e206a9eeac9a288dbddf16597435dccc3c040a50c1b9dfa2dbc774123390cd
BLAKE2b-256 checksum
How to use checksums
465a0ec27fa9d62805e18642e4bb4b1c3f8d480e71fd2b3d56dcb72a4756022f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 29, 2026.

Transparency log

Release files / pygrbl_build-1.0.2-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl

Download URL pygrbl_build-1.0.2-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Size 90.7 kB
Tags CPython 3.13 Linux glibc 2.17+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
29f9aa233bf1d4791610e56c93b1b0f8f9e7cb41558c9a3aea793f4acf29b53e
BLAKE2b-256 checksum
How to use checksums
03afa09ad3bb9410472ef0e7e721a010dff8850bcf52fc5467e42ce6f042cb78
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 29, 2026.

Transparency log

Release files / pygrbl_build-1.0.2-cp312-cp312-win_amd64.whl

Download URL pygrbl_build-1.0.2-cp312-cp312-win_amd64.whl
Size 66.6 kB
Tags CPython 3.12 Windows x86-64
SHA-256 checksum
How to use checksums
c57d6752aa53e5bfad078461886e8ce0762a6b1abd61e3359e984dab24f1a53c
BLAKE2b-256 checksum
How to use checksums
e04813c3654c80e8120551146f3f41a2026c12db5ec4ab1631da7f0386f921d7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 29, 2026.

Transparency log

Release files / pygrbl_build-1.0.2-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl

Download URL pygrbl_build-1.0.2-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Size 90.7 kB
Tags CPython 3.12 Linux glibc 2.17+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
fbd59b8d2b9d5e0de260b9f7bb32b9cabdba803ff3566531309298516c2e71fa
BLAKE2b-256 checksum
How to use checksums
1506b1ed972e74b74d3a0c6ebfc274b8cb64138be986e29fb26ef8f577eff44a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 29, 2026.

Transparency log

Release files / pygrbl_build-1.0.2-cp311-cp311-win_amd64.whl

Download URL pygrbl_build-1.0.2-cp311-cp311-win_amd64.whl
Size 66.6 kB
Tags CPython 3.11 Windows x86-64
SHA-256 checksum
How to use checksums
bd02e049ebdbcfed3c3a62c8a7fb45016a5bb2bf2b29f28b3a8b45ac5d590d60
BLAKE2b-256 checksum
How to use checksums
dd0381c2bd21ca54a7b4a28c7baae497dd8c0eaf72ff400bbf75fdd42a9bee54
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 29, 2026.

Transparency log

Release files / pygrbl_build-1.0.2-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl

Download URL pygrbl_build-1.0.2-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Size 89.9 kB
Tags CPython 3.11 Linux glibc 2.17+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
a795614fe6d393dced938c85c0175bbe8c6ba5777838d0d7d4175ebd96da7057
BLAKE2b-256 checksum
How to use checksums
56119811d5561621893876368d021f82900e2ed7b961c89c84f37dc387c46b84
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 29, 2026.

Transparency log

Release files / pygrbl_build-1.0.2-cp310-cp310-win_amd64.whl

Download URL pygrbl_build-1.0.2-cp310-cp310-win_amd64.whl
Size 66.6 kB
Tags CPython 3.10 Windows x86-64
SHA-256 checksum
How to use checksums
4ae693d2f236c3a4fd66538111d2e9e67f6039307b43c18d42760d7218c31e40
BLAKE2b-256 checksum
How to use checksums
65b0d0b29e72bbcb82bda400f3a02f77409b52bd56e243d7b0438db523c6d4de
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 29, 2026.

Transparency log

Release files / pygrbl_build-1.0.2-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl

Download URL pygrbl_build-1.0.2-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Size 88.9 kB
Tags CPython 3.10 Linux glibc 2.17+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
d5dac2f8fe1b99304b76a08d2635d9b400255648df41a836642340d34c6905ff
BLAKE2b-256 checksum
How to use checksums
e1b58742f3657b60259f55ccc238592fb1c6b80b183fd2775bbb49e2e6e45396
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 29, 2026.

Transparency log

Release history Release notifications | RSS feed

1.0.4

11 release files

1.0.3

11 release files

This release

1.0.2 This release

11 release files

1.0.1

11 release files

1.0.0

11 release files

0.3.0

2 release files

0.2.0

2 release files

0.1.0

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