Skip to main content

Python add-on module for gdspy that can perform chamfering operation on GDSII files.

Project description

gdschamfer

gdschamfer is a Python add-on module for gdspy that can perform chamfering operation on GDSII files. It extends the fillet function in gdspy so that:

  • inside corners (i.e., concave bends) or outside corners (i.e., convex bends) can be selectively chamfered or filleted.

  • orthogonal corners can be selectively chamfered or filleted.

The operation of chamfering leads to corners being replaced with 45° slanting edges. An example of inside corners of a polygon being chamfered is shown below:

On the other hand, the filleting operation that gdspy's fillet() function does will result in concave curved corners for inside corners and convex (or rounded) corners for outside corners. When the fillet radius of curvature tends to infinity the resulting fillet starts to approximate a chamfer.

Usage

To use gdschamfer install its PyPI python distribution package using pip:

pip install gdschamfer

In your python scripts place the import statement

import gdschamfer

There are 3 functions available for use:

  1. gdschamfer.chamfer_polygons(...): Use this to perform chamfering of gdspy Polygon objects.

  2. gdschamfer.chamfer_cell(...): Use this to perform chamfering of gdspy Cell objects.

  3. gdschamfer.chamfer_gds(...): Use this to perform chamfering on GDSII file.

Chamfer style

To understand how the option chamfer_style modifies the corners consider the GDSII file demo/input.gds shown below:


a) When chamfer_style = "inside_corners":

GDSII with 3 polygons, with 2 on layer 20 and 1 on layer 22 showing chamfered inside corners


b) When chamfer_style = "outside_corners":

GDSII with 3 polygons, with 2 on layer 20 and 1 on layer 22 showing chamfered outside corners


c) When chamfer_style = "all_corners":

GDSII with 3 polygons, with 2 on layer 20 and 1 on layer 22 showing chamfered corners


Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gdschamfer-0.3.0.tar.gz (9.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

gdschamfer-0.3.0-py3-none-any.whl (9.9 kB view details)

Uploaded Python 3

File details

Details for the file gdschamfer-0.3.0.tar.gz.

File metadata

  • Download URL: gdschamfer-0.3.0.tar.gz
  • Upload date:
  • Size: 9.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/3.7.3 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.8.6

File hashes

Hashes for gdschamfer-0.3.0.tar.gz
Algorithm Hash digest
SHA256 aa3c4b5e25180bc99262a124e5a764428a8efdba35f6cf81ca31685f1d5e1c3d
MD5 973ff5c6354619b9037f3ec1d22f179c
BLAKE2b-256 007e1853baba0493259db6cbeeaded2a80e4862c75a6973bb75fc383cef02988

See more details on using hashes here.

File details

Details for the file gdschamfer-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: gdschamfer-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 9.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/3.7.3 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.8.6

File hashes

Hashes for gdschamfer-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 88008a13f75f1128fd81cfbf7e24c94a34a30923575c37896aa2d36d9fac5f74
MD5 2ccd1727f55de1402a7a5f356ed498a0
BLAKE2b-256 0a80e459faf887a1285aa64530a6abed25a28fd34939cb564ccfd516d6dd0643

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page