Skip to main content

No project description provided

Project description

Gsim 0.0.3

a GDSFactory Simulation Plugin

gsim-logo

Overview

Gsim bridges the gap between circuit layout design (using GDSFactory) and electromagnetic simulation (using Palace). It automates the conversion of IC component layouts into simulation-ready mesh files and configuration.

Features

  • Layer Stack Extraction: Extract layer stacks from PDK definitions with a comprehensive material properties database
  • Port Configuration: Convert GDSFactory ports into Palace-compatible port definitions (inplane, via, and CPW ports)
  • Mesh Generation: Generate GMSH-compatible finite element meshes with configurable quality presets

Installation

pip install gsim

For development:

git clone https://github.com/doplaydo/gsim
cd gsim
pip install -e .[dev]

Quick Start

from gsim.palace import (
    get_stack,
    configure_inplane_port,
    extract_ports,
    generate_mesh,
    MeshConfig,
)

# Get layer stack from active PDK
stack = get_stack()

# Configure ports on your component
configure_inplane_port(c.ports["o1"], layer="topmetal2", length=5.0)
configure_inplane_port(c.ports["o2"], layer="topmetal2", length=5.0)

# Extract configured ports
ports = extract_ports(c, stack)

# Generate mesh
result = generate_mesh(
    component=c,
    stack=stack,
    ports=ports,
    output_dir="./simulation",
    config=MeshConfig.default(),
)

Mesh Presets

Preset Refined Size Max Size Use Case
Coarse 10.0 µm 600.0 µm Fast iteration (~2.5 elements/λ)
Default 5.0 µm 300.0 µm Balanced accuracy (~5 elements/λ)
Fine 2.0 µm 70.0 µm High accuracy (~10 elements/λ)

Port Types

  • Inplane ports: Horizontal ports on single metal layer for CPW gaps
  • Via ports: Vertical ports between two metal layers for microstrip structures
  • CPW ports: Multi-element ports for proper Coplanar Waveguide excitation

Documentation

See the documentation for detailed API reference and examples.

License

Copyright 2026 GDSFactory

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

gsim-0.0.3.tar.gz (56.3 kB view details)

Uploaded Source

Built Distribution

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

gsim-0.0.3-py3-none-any.whl (71.1 kB view details)

Uploaded Python 3

File details

Details for the file gsim-0.0.3.tar.gz.

File metadata

  • Download URL: gsim-0.0.3.tar.gz
  • Upload date:
  • Size: 56.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for gsim-0.0.3.tar.gz
Algorithm Hash digest
SHA256 5d0b97096bc75ba5ee7b9c43d8af5b32bfecefcf5af34e03a4539137c244c9f2
MD5 f5d0dee93ba1f32ea4b28a06ca08a037
BLAKE2b-256 dbe855da50f901008a93f81541a44a13f97359ef57c8b1b268046ea4a76b602a

See more details on using hashes here.

Provenance

The following attestation bundles were made for gsim-0.0.3.tar.gz:

Publisher: release.yml on gdsfactory/gsim

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file gsim-0.0.3-py3-none-any.whl.

File metadata

  • Download URL: gsim-0.0.3-py3-none-any.whl
  • Upload date:
  • Size: 71.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for gsim-0.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 ef8674d6114583e6b5ccde56e2c3a4be2df40c93cfcd659f513ffef5b79fb0e9
MD5 785a90bbe984eb6049a748d25294da86
BLAKE2b-256 a80d0a68a026fd4f2df3c04b5fb425843c6a3e453b6f00edb89fb8000dbbdf1c

See more details on using hashes here.

Provenance

The following attestation bundles were made for gsim-0.0.3-py3-none-any.whl:

Publisher: release.yml on gdsfactory/gsim

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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