Skip to main content


planex2d

Fast, exact 2D geometry for Python
Documentation · Installation · Examples · License and notices

planex2d is free software under the GNU Lesser General Public License, version 2.1 or (at your option) any later version. Its compiled module contains code from Eigen, pybind11 and Taskflow, and it is linked to Netgen and Open CASCADE Technology; see License and notices and THIRD_PARTY_NOTICES.md. planex2d makes use of facilities provided by the Open CASCADE Technology software.

What it is

planex2d is a 2D geometry kernel for Python, written in C++. You draw outlines from lines, arcs, circles and splines, combine them with exact Boolean operations, dimension them with constraints, and clean up drawings imported from other tools. The resulting faces go to OpenCASCADE, netgen/NGSolve, gmsh and other tools for 3D modeling, meshing and simulation.

Installation

pip install netgen-mesher netgen-occt-devel scikit-build-core
pip install --no-build-isolation planex2d

Version 0.1 has no prebuilt wheels yet, so pip builds planex2d from source against netgen's OpenCASCADE: the first line installs netgen, the OpenCASCADE headers and the build backend, and the second builds without build isolation so that the build uses them. The build needs a C++20 compiler and CMake. The package is called planex2d on PyPI and planex in Python (import planex as px). See Installation for the optional packages.

A first sketch

A QuickSketch draws with a pen: Line draws along the current direction, Turn changes the direction, Arc continues with a tangent arc, and Close joins the outline to its start. Circle adds a hole. The result is an angle bracket with an inner fillet and two holes.

import planex as px

bracket = px.QuickSketch()
bracket.Line(60).Turn(90).Line(10).Turn(90).Line(40)
bracket.Arc(10, -90).Line(30).Turn(90).Line(10).Close()
bracket.Circle(45, 5, 2.5).Circle(5, 35, 2.5)
face = px.Face(bracket.Wires())
face.Plot()

The angle bracket drawn by the pen: two legs, an inner fillet of radius 10 and a hole in each leg

Where to go next

License

planex2d is Copyright (C) 2026 Sebastian Hirnschall.

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

planex2d is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License, the file LICENSE, for more details. The third-party notices are in THIRD_PARTY_NOTICES.md and on the page License and notices.

Metadata

Release files for planex2d 0.1.0

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

Source distribution (sdist)

Source distribution for planex2d 0.1.0
File Size Uploaded Provenance Actions
planex2d-0.1.0.tar.gz 2.3 MB With provenance Details for planex2d-0.1.0.tar.gz

Release files / planex2d-0.1.0.tar.gz

Download URL planex2d-0.1.0.tar.gz
Size 2.3 MB
Tags Source
SHA-256 checksum
How to use checksums
d994fc81296cacd5713b65321997a91213cf88340a96e122a25820ec7db61285
BLAKE2b-256 checksum
How to use checksums
64020417ecfbc4b398ced923b89c4456e98efddba6e85098ab8d5b46ac36154c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 Oct 23, 2026.

Transparency log

Security for planex2d 0.1.0

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.

Full provenance

All 1 file in this release has been uploaded with provenance metadata.

Attestation for planex2d-0.1.0.tar.gz

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 Oct 23, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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