Skip to content

Curate cells_no_model_expected to sharpen model-coverage metric #151

Description

@ThomasPluck

Current model coverage: 9%

This issue asks maintainers to curate cells_no_model_expected in pyproject.toml so that the model_coverage metric reflects the real modelling gap — not boilerplate, reference, or intentionally-out-of-scope cells.

How the metric works

model_coverage.yml runs on every push. The badge is:

coverage = cells_with_model / (all_cells - skip_set)

skip_set unions two lists:

Defaults (hardcoded in doplaydo/pdk-ci-workflow):

  • Prefix: add_fiber, die, import_gds, load, mzi, mzm, pack, pad, rectangle, ring, spiral, TEMPLATE, via, wire
  • Substring: bondpad, frame, metal

Per-PDK overrides in pyproject.toml:

[tool.gdsfactoryplus.pdk]
cells_no_model_expected = [
    "my_diagnostic_cell",
    "vendor_library_frame_a",
]

Both lists are unioned. Listed cells drop out of the denominator.

What's legit to exempt

  • Non-component cells not already caught by defaults (test frames, DOE containers, alignment marks, reticle-level variants)
  • Reference-only cells the PDK ships but aren't design primitives
  • Cells deliberately modelled outside SAX (black-box, SPICE, time-domain) — flag these so they can be registered as "modelled elsewhere"
  • Duplicate / wrapper cells where the real model lives on the underlying cell

What's not

  • A real primitive you haven't modelled yet — that's the gap, not an exemption
  • "Don't know how to model this active device yet" — leave it as a real gap so the upcoming modelling-engine scope sees it
  • Anything you'd be embarrassed to justify in PR review

Workflow

  1. Open a PR touching pyproject.toml
  2. One-line justification per new exemption in the PR body
  3. Tag @thomaspluck or link the modelling-engine project on Linear

What's coming — don't over-invest against it

A centralized modelling-engine effort is in scoping. Expect:

  • Shared SAX template library for the usual primitives (MMI, GC, DC, edge coupler, ring, phase shifters) — most hand-written models become partial(template, fit_constants)
  • Cross-PDK s-parameter data registry — .nc / CSV files move out of individual repos
  • Scaffolding CLI that emits SAX stubs from pdk.cells
  • Model-serving API so the engine is consumable, not vendored

So: clean up your skip-list, flag cells that shouldn't count, but don't sink a week into bespoke models for primitives that are on the shared-template list.

Questions / exemption sanity-checks → #gdsfactory-dev or comment on this issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    pdkPDK issuepdk:ihpPDK this issue belongs to

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions