shanto268's picture
Replace mislabeled v1 vectors with static shape embedding v0
287c983 verified
|
Raw
History Blame
3.97 kB
---
license: mit
configs:
- config_name: static-embedding-v0
data_files:
- split: train
path: "metadata/static-embedding-v0.parquet"
tags:
- quantum
- superconducting
- qiskit-metal
- gds
- layout
- embedding
- geometry
- computer-vision
pretty_name: SQuADDS Layout Embeddings
size_categories:
- 1K<n<10K
---
<center>
<img src="https://github.com/LFL-Lab/SQuADDS/blob/master/docs/_static/images/squadds_logo_dark_name.png?raw=true" width="80%" alt="SQuADDS Logo" />
</center>
# SQuADDS Layout Embeddings
Versioned layout representations for the 4,577 GDS artifacts in
[SQuADDS/SQuADDS_Layouts](https://huggingface.co/datasets/SQuADDS/SQuADDS_Layouts).
## Static embedding model `v0`
`static-embedding-v0` implements the original SQuADDS proof-of-concept model:
```text
v0 = parameter_sum + geometric_moments + flattened_shape_bitmap
```
Each unit-normalized vector has **9,227 dimensions**:
| Block | Dimensions | Contents |
| --- | ---: | --- |
| Parameter sum | 1 | Permutation- and parameter-count-invariant sum of numerical design options, converted to micrometers where units are present |
| Geometric moments | 10 | Functional area, perimeter, aspect ratio, occupancy, centroid, second central moments, and eccentricity |
| Shape tensor | 9,216 | Row-major flattened 96×96 signed bitmap of functional GDS geometry |
The bitmap uses `+1` for conductor, `-1` for etch, `+0.5` for explicit port
geometry, and `0` for background. Geometry is cropped to its functional bounds,
centered without distortion, supersampled at 4×, and reduced to 96×96. The
large simulation-domain ground rectangle on layer `(1, 0)` is excluded so it
does not hide the component shape.
This is a deterministic static embedding, not a learned model. It is intended
as a transparent baseline and as a stable input for similarity search. A future
`v1` may use a compact learned raster or geometry-graph encoder, but will be
published as a separate model rather than changing `v0` in place.
The exact block offsets, moment order, raster semantics, normalization
statistics, and source schema are frozen in
`metadata/static-embedding-v0.schema.json`.
## Coverage and links
| Component | Embeddings |
| --- | ---: |
| `GeneralizedCapNInterdigital` | 3,683 |
| `CapNInterdigitalTee` | 894 |
Every row retains `layout_id`, `artifact_id`, `design_id`, `component_name`,
and `source_id`, plus the raw parameter sum, geometric moments, functional
bounds, and a SHA-256 hash of the 96×96 bitmap.
## Access
```python
from squadds.layouts import StaticEmbeddingClient
client = StaticEmbeddingClient()
record = client.get("layout:sha256:<layout hash>")
bitmap = client.shape_bitmap(record["layout_id"])
neighbors = client.nearest(record["layout_id"], limit=10)
```
SQuADDS_DB rows can resolve the same vector directly with
`SQuADDS_DB.get_layout_embedding(row)`. The SQuADDS MCP server also provides
`get_layout_embedding` and `find_similar_layouts`.
## Provenance
Raw GDS artifacts, layer semantics, checksums, and geometry features live in
[SQuADDS/SQuADDS_Layouts](https://huggingface.co/datasets/SQuADDS/SQuADDS_Layouts).
Simulation results and design options live in
[SQuADDS/SQuADDS_DB](https://huggingface.co/datasets/SQuADDS/SQuADDS_DB).
The generalized-capacitor dataset was contributed by Saikat Das of the
Levenson-Falk Lab at USC.
## Citation
If you use this dataset, cite SQuADDS:
```bibtex
@article{Shanto2024squaddsvalidated,
doi = {10.22331/q-2024-09-09-1465},
title = {{SQ}u{ADDS}: {A} validated design database and simulation workflow for superconducting qubit design},
author = {Shanto, Sadman and Kuo, Andre and Miyamoto, Clark and Zhang, Haimeng and Maurya, Vivek and Vlachos, Evangelos and Hecht, Malida and Shum, Chung Wa and Levenson-Falk, Eli},
journal = {{Quantum}},
volume = {8},
pages = {1465},
year = {2024}
}
```
This dataset is licensed under the [MIT License](https://github.com/LFL-Lab/SQuADDS/blob/master/LICENSE).