2016-03-15 19:12:39 -07:00
|
|
|
"""
|
|
|
|
masque 2D CAD library
|
|
|
|
|
|
|
|
masque is an attempt to make a relatively small library for designing lithography
|
2020-11-01 19:45:57 -08:00
|
|
|
masks. The general idea is to implement something resembling the GDSII and OASIS file-formats,
|
2023-01-18 18:14:33 -08:00
|
|
|
but with some additional vectorized element types (eg. ellipses, not just polygons), and the
|
|
|
|
ability to interface with multiple file formats.
|
2016-03-15 19:12:39 -07:00
|
|
|
|
2020-02-17 21:02:53 -08:00
|
|
|
`Pattern` is a basic object containing a 2D lithography mask, composed of a list of `Shape`
|
|
|
|
objects, a list of `Label` objects, and a list of references to other `Patterns` (using
|
2023-01-21 21:22:11 -08:00
|
|
|
`Ref`).
|
2016-03-15 19:12:39 -07:00
|
|
|
|
2023-01-21 21:22:11 -08:00
|
|
|
`Ref` provides basic support for nesting `Pattern` objects within each other, by adding
|
2020-07-22 02:45:16 -07:00
|
|
|
offset, rotation, scaling, repetition, and other such properties to a Pattern reference.
|
2020-02-17 21:02:53 -08:00
|
|
|
|
2016-03-15 19:12:39 -07:00
|
|
|
Note that the methods for these classes try to avoid copying wherever possible, so unless
|
|
|
|
otherwise noted, assume that arguments are stored by-reference.
|
2020-11-09 21:55:46 -08:00
|
|
|
|
|
|
|
|
|
|
|
NOTES ON INTERNALS
|
|
|
|
==========================
|
|
|
|
- Many of `masque`'s classes make use of `__slots__` to make them faster / smaller.
|
|
|
|
Since `__slots__` doesn't play well with multiple inheritance, the `masque.utils.AutoSlots`
|
|
|
|
metaclass is used to auto-generate slots based on superclass type annotations.
|
|
|
|
- File I/O submodules are imported by `masque.file` to avoid creating hard dependencies on
|
|
|
|
external file-format reader/writers
|
|
|
|
|
2016-03-15 19:12:39 -07:00
|
|
|
"""
|
|
|
|
|
2023-01-25 23:57:02 -08:00
|
|
|
from .utils import layer_t, annotations_t, SupportsBool
|
2023-01-22 16:59:32 -08:00
|
|
|
from .error import MasqueError, PatternError, LibraryError, BuildError
|
2023-01-23 22:27:26 -08:00
|
|
|
from .shapes import Shape, Polygon, Path, Circle, Arc, Ellipse
|
2018-08-30 23:06:31 -07:00
|
|
|
from .label import Label
|
2023-01-21 21:22:11 -08:00
|
|
|
from .ref import Ref
|
2023-04-12 14:47:10 -07:00
|
|
|
from .pattern import Pattern, map_layers, map_targets, chain_elements
|
2023-01-31 12:05:44 -08:00
|
|
|
|
|
|
|
from .library import (
|
2023-04-07 18:08:42 -07:00
|
|
|
ILibraryView, ILibrary,
|
|
|
|
LibraryView, Library, LazyLibrary,
|
2023-01-31 12:05:44 -08:00
|
|
|
AbstractView,
|
|
|
|
)
|
2023-01-21 21:22:11 -08:00
|
|
|
from .ports import Port, PortList
|
2023-01-24 12:45:44 -08:00
|
|
|
from .abstract import Abstract
|
2023-04-13 17:54:52 -07:00
|
|
|
from .builder import Builder, Tool, Pather, RenderPather, RenderStep
|
2023-04-07 16:33:59 -07:00
|
|
|
from .utils import ports2data, oneshot
|
2023-01-24 12:45:44 -08:00
|
|
|
|
2016-03-15 19:12:39 -07:00
|
|
|
|
|
|
|
__author__ = 'Jan Petykiewicz'
|
2018-08-30 23:12:01 -07:00
|
|
|
|
2022-08-18 22:59:50 -07:00
|
|
|
__version__ = '2.7'
|
2020-11-01 19:45:31 -08:00
|
|
|
version = __version__ # legacy
|