Python GUI for gds2palace
Install
pip install setupEM
Full documentation, installation guide, and usage walkthrough: https://github.com/VolkerMuehlhaus/setupEM
Recent changes
What's New - October 5, 2026
Import Model (*.py) with several GDS purposes (datatypes), e.g. settings['purpose'] = [0, 35, 4], now works: the purpose field shows "0, 35, 4" and the model uses all three. Before, the field showed "(0, 35, 4)" and no datatype matched, so the layout preview and the model had no polygons on any layer. Models with a single purpose were not affected. A single number in the script (settings['purpose'] = 0) is now also read as [0].
What's New - October 2, 2026
3D Field Viewer: with Log color scale, a Range dropdown (-10, -20 ... -70 dB below Max) replaces the Min field; the default is -70 dB. dB means 20·log10 for E and B fields and 10·log10 for power-like arrays such as S or the energy densities. Switching to another result file or cycle now keeps the selected field (if the new data has it; a field you picked comes back as soon as it is available again) and keeps the camera view, zoom and clip position if the new mesh has the same bounding box, e.g. another AMR iteration or the matching "boundary" file. Only a file with different bounds resets the view.
Tools > Simplify GDS... has a new step Merge via arrays (default off), with a merge distance (default: the via array merge distance from Preferences). Vias closer than this distance are merged into one shape, but only if they connect the same metal shapes above and below, so merging never shorts different metal shapes. The via layers and the metal layers above and below them come from the loaded XML stackup. Vias without metal above or below are kept unchanged. Merged vias in the file are treated as solid metal in the model: fill factor correction needs the original vias, which are then no longer in the file. For accurate via resistance, merge vias in the model instead (via array merge distance > 0 with fill factor correction). gds2palace prints a note when fill factor correction is on and the vias in the file seem to be merged already. Requires gds_prepare_for_EM v1.3.0 or later.
The via array merging of the models themselves (gds2palace merge_polygon_size) no longer shorts different metal shapes either, with gds2palace v0.8.1 or later.
What's New - September 30, 2026
The Adaptive mesh refinement (AMR) group on the Mesh and Boundaries tab is now called Solver & Adaptive Mesh Refinement (AMR) and has a new Palace linear solver setting, shown with Show advanced configuration = Yes.
Complex coarse solve (default Yes for every model, set in Preferences > Palace) lets Palace's direct coarse solver factorize the full complex system instead of only its real part. With No (Palace's own default), some models don't converge at some frequencies and get wrong S-parameters there: a D-band line failed at 170 GHz, and an inductor failed at 2.4 GHz with 1.1 nH instead of 2.5 nH, while it converged at 0.1 and 10 GHz. With Yes both converged in 1-31 iterations and ran 3.5-6x faster. Models that already converge give identical results in about the same or less time. The cost is peak RAM, depending on the model 1.0-1.6x at order 2 and 1.5-1.9x at order 1; the AMR RAM estimate includes this.
Maximum solver iterations (400) and Solver tolerance (1e-6) can now be changed too, in Preferences > Palace. These settings require gds2palace v0.8.0 or later and are hidden with an older version. setupEM module installation now requires gds2palace v0.8.0 or later, which also restores the dielectric loss tangent in Palace models that had been deleted by mistake.
Conformal AMR (experimental) is a new advanced setting in the Solver & Adaptive Mesh Refinement (AMR) group (default No, set in Preferences > Palace). With AMR iterations > 0, it switches Palace from its default nonconformal (hanging-node) mesh refinement to conformal refinement (gds2palace settings['adaptive_mesh_conformal']). In the test cases so far it converged in fewer AMR iterations (D-band balun: 2 iterations instead of 4, in half the time), but the mesh cell count grows faster per iteration.
setupEM now warns when Palace's linear solver does not converge: Palace carries on and writes S-parameters for that frequency anyway, but they are unreliable. Each case gets a ⚠ warning in the Log panel with its frequency, and all of them are listed again at the end of the run.
Full history: CHANGES.md
Note: the setupEM PyPI package itself requires:
- gds2palace>=0.8.0
- gds_prepare_for_EM>=1.3.0
- PySide6
- shiboken6
- scipy
- requests
- scikit-rf
- matplotlib
- numpy
- gdspy
- meshio
- pyvista
- pyvistaqt
(Other Python modules mentioned above are only needed to run standalone helper scripts in this repository, not to use the installed package.)
Metadata
Release files for setupEM 0.11.1.post1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| setupem-0.11.1.post1.tar.gz | 330.6 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| setupem-0.11.1.post1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 666.1 kB
Release files / setupem-0.11.1.post1.tar.gz
| Download URL | setupem-0.11.1.post1.tar.gz |
|---|---|
| Size | 330.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
04608356ff6c877613cfbde363838a059c52ad73d87060fefd30dd731fb34294
|
|
BLAKE2b-256 checksum How to use checksums |
081131cc74a1aa7b131c954e3eb0b2d8edeba63c13e530086d1dd1625a380cfb
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Release files / setupem-0.11.1.post1-py3-none-any.whl
| Download URL | setupem-0.11.1.post1-py3-none-any.whl |
|---|---|
| Size | 335.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
932faa44d9f6fcc444c816820d5ec2b67e7d2022445848d675175337a4f6afc5
|
|
BLAKE2b-256 checksum How to use checksums |
9b0a8ddc5e4e67255caf1593ac178a6d4f17988b1fd547c70220c6d2b9b9aa8e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|