Samples#

Samples are grouped by what they demonstrate. Schematic samples ship as a GDSFactory+ schematic and a YAML layout instead of a Python script.

Getting Started

8 samples

Getting Started
Qubit Test Chips

3 samples

Qubit Test Chips
Resonator and Lattice Chips

3 samples

Resonator and Lattice Chips
3D Integration

2 samples

3D Integration
Metal Fill

5 samples

Metal Fill
Simulation

1 sample

Simulation
Other Samples

2 samples

Other Samples

Getting Started#

Step-by-step primers on gdsfactory basics with QPDK cells.

qpdk.samples.sample0.sample0_hello_world#

qpdk.samples.sample0.sample0_hello_world()[source]#

Returns a component with ‘Hello world’ text and a rectangle.

Return type:

Component

sample0_hello_world

qpdk.samples.sample1.sample1_connect#

qpdk.samples.sample1.sample1_connect()[source]#

Returns a component with connected waveguides.

Return type:

Component

sample1_connect

qpdk.samples.sample2.sample2_remove_layers#

qpdk.samples.sample2.sample2_remove_layers()[source]#

Returns a component with ‘Hello world’ text and a rectangle.

Return type:

Component

sample2_remove_layers

qpdk.samples.sample3.sample3_grid#

qpdk.samples.sample3.sample3_grid()[source]#

Returns a component with a grid of text elements.

sample3_grid

qpdk.samples.sample4.sample4_pack#

qpdk.samples.sample4.sample4_pack()[source]#

Returns a component with a packed set of ellipses.

sample4_pack

qpdk.samples.sample5.sample5_path#

qpdk.samples.sample5.sample5_path()[source]#

Returns a component with a path made of different segments.

sample5_path

qpdk.samples.sample6.sample6_cross_section#

qpdk.samples.sample6.sample6_cross_section()[source]#

Returns a component with a path made of different segments.

sample6_cross_section

qpdk.samples.all_cells.all_cells#

qpdk.samples.all_cells.all_cells(spacing=200.0, **kwargs)[source]#

Create a component containing all cells from qpdk.PDK.cells.

Instantiates and arranges all available cells efficiently. Cells that fail to instantiate are skipped with a warning message.

Parameters:
  • spacing (float) – Spacing between cells in micrometers (default: 200.0).

  • **kwargs – Additional arguments passed to gf.pack. If max_size is not provided, it defaults to (None, None) so packing is unconstrained in both dimensions unless the caller explicitly sets limits.

Returns:

Component containing all successfully instantiated cells.

Return type:

Component

Example

>>> import qpdk
>>> c = qpdk.cells.all_cells()
>>> c.show()  # Display all cells in KLayout
all_cells

Qubit Test Chips#

Transmon, flipmon and gatemon chips with readout resonators.

qpdk.samples.qubit_test_chip.qubit_test_chip#

qpdk.samples.qubit_test_chip.qubit_test_chip()[source]#

Layout of the qubit test chip, read from its .pic.yml netlist.

The matching .gsch remains the source for licensed schematic flows.

Returns:

The materialized sample component.

Return type:

Component

qubit_test_chip

qpdk.samples.flipmon_test_chip.flipmon_test_chip#

qpdk.samples.flipmon_test_chip.flipmon_test_chip()[source]#

Layout of the flipmon test chip, read from its .pic.yml netlist.

The full chip layout is defined declaratively in the sample’s netlist; this factory only reads that file, so editing the netlist edits the layout. The materialized name matches the .pic.yml/GDS stem because elvis resolves the top cell from the GDS file name.

Returns:

The materialized sample component.

Return type:

Component

flipmon_test_chip

gatemon_test_chip#

Open the GDSFactory+ schematic or load the YAML layout with gf.get_component("gatemon_test_chip") after activating QPDK.

gatemon_test_chip

Resonator and Lattice Chips#

Resonator test chips and resonator lattices.

qpdk.samples.resonator_test_chip.resonator_test_chip_python#

qpdk.samples.resonator_test_chip.resonator_test_chip_python(probeline_length=9000.0, probeline_separation=1000.0, resonator_length=4000.0, coupling_length=200.0, coupling_gap=4.0)[source]#

Creates a resonator test chip with two probelines and 16 resonators.

The chip features two horizontal probelines running west to east, each with launchers on both ends. Eight quarter-wave resonators are coupled to each probeline, with systematically varied lengths for characterization studies.

Parameters:
  • probeline_length (float) – Length of each probeline in µm.

  • probeline_separation (float) – Vertical separation between probelines in µm.

  • resonator_length (float) – Nominal resonator length in µm. Resonator lengths are varied around this value to separate their resonance frequencies.

  • coupling_length (float) – Length of coupling region between resonator and probeline in µm.

  • coupling_gap (float) – Gap between resonator and probeline for coupling in µm. The 4 µm default broadens the resonance notches enough for a 1001-point SAX sweep from 4 to 10 GHz to resolve all eight per line.

Returns:

A gdsfactory component containing the complete test chip layout.

Return type:

Component

resonator_test_chip_python

qpdk.samples.resonator_test_chip_yaml.resonator_test_chip_yaml#

qpdk.samples.resonator_test_chip_yaml.resonator_test_chip_yaml()[source]#

Layout of the resonator test chip, read from its .pic.yml netlist.

The full chip layout is defined declaratively in the sample’s netlist; this factory only reads that file, so editing the netlist edits the layout. The materialized name matches the .pic.yml/GDS stem because elvis resolves the top cell from the GDS file name.

Returns:

The materialized sample component.

Return type:

Component

resonator_test_chip_yaml

qpdk.samples.hyperbolic_lattice_chip.hyperbolic_lattice_chip#

qpdk.samples.hyperbolic_lattice_chip.hyperbolic_lattice_chip(p=7, q=3, shells=1, resonator_length=7500.0, edge_margin=500.0)[source]#

Returns a hyperbolic lattice of edge resonators framed by a chip edge.

Parameters:
  • p (int) – Polygon side count of the tiling.

  • q (int) – Polygons per vertex, i.e. coupler pins.

  • shells (int) – Polygon rings around the central polygon.

  • resonator_length (float) – Length of every edge resonator in µm.

  • edge_margin (float) – Clearance between the lattice and the chip edge in µm.

Return type:

Component

hyperbolic_lattice_chip

3D Integration#

Flip-chip, TSV and 3D layer stack examples.

tsv_flip_chip_test_chip#

Open the GDSFactory+ schematic or load the YAML layout with gf.get_component("tsv_flip_chip_test_chip") after activating QPDK.

tsv_flip_chip_test_chip

qpdk.samples.sample_to_3d.sample_to_3d#

qpdk.samples.sample_to_3d.sample_to_3d()[source]#

Returns a transmon with a resonator and chip edge for 3D visualization.

This function demonstrates the full workflow of adding logical components, filling with magnetic vortices, adding a simulation area, and finally applying the additive metal transformation for mask generation and 3D visualization.

Return type:

Component

sample_to_3d

Metal Fill#

Chips with ground-plane fill and flux-trapping holes.

qpdk.samples.filled_resonator.filled_quarter_wave_resonator#

qpdk.samples.filled_resonator.filled_quarter_wave_resonator()[source]#

Returns a quarter wave resonator filled with magnetic vortex trapping rectangles.

This sample demonstrates how to use the fill_magnetic_vortices helper function to add small rectangles that trap magnetic vortices in superconducting quantum circuits.

Returns:

A quarter wave resonator with fill rectangles for vortex trapping.

Return type:

Component

filled_quarter_wave_resonator

qpdk.samples.filled_test_chip.filled_qubit_test_chip#

qpdk.samples.filled_test_chip.filled_qubit_test_chip(yaml_path=PosixPath('/home/runner/work/quantum-rf-pdk/quantum-rf-pdk/qpdk/samples/qubit_test_chip.pic.yml'))[source]#

Returns a qubit test chip filled with magnetic vortex trapping rectangles.

Roughly corresponds to the sample in [TSK+25].

Parameters:

yaml_path (str | Path)

filled_qubit_test_chip

qpdk.samples.filled_test_chip.filled_flipmon_test_chip#

qpdk.samples.filled_test_chip.filled_flipmon_test_chip()[source]#

Returns the flipmon test chip filled with magnetic vortex trapping rectangles.

The flipmon qubit design follows [LZY+21], and the test chip layout is the sample from [TSK+25].

Return type:

Component

filled_flipmon_test_chip

qpdk.samples.filled_test_chip.filled_gatemon_test_chip#

qpdk.samples.filled_test_chip.filled_gatemon_test_chip()[source]#

Returns the two-gatemon test chip filled with magnetic vortex trapping rectangles.

Roughly corresponds to the chip layout in [RAP+25].

Return type:

Component

filled_gatemon_test_chip

qpdk.samples.resonator_test_chip.filled_resonator_test_chip#

qpdk.samples.resonator_test_chip.filled_resonator_test_chip()[source]#

Creates a resonator test chip filled with magnetic vortex trapping holes.

This version includes the complete resonator test chip layout with additional ground plane holes to trap magnetic vortices, improving the performance of superconducting quantum circuits. Includes chip edge components with extra y-padding to keep resonators away from the chip edges.

Returns:

Test chip with ground plane fill patterns and chip edges.

Return type:

Component

filled_resonator_test_chip

Simulation#

Layouts prepared for electromagnetic simulation.

qpdk.samples.simulate_resonator.resonator_simulation#

qpdk.samples.simulate_resonator.resonator_simulation(coupling_gap=12.0)[source]#

Create a resonator simulation layout with launchers and CPW routes.

Returns:

The resonator simulation component.

Parameters:

coupling_gap (float)

Return type:

Component

resonator_simulation

Other Samples#

qpdk.samples.cpw_jpa_chip.cpw_jpa_chip#

qpdk.samples.cpw_jpa_chip.cpw_jpa_chip(signal_route_length=800.0, pump_route_length=800.0)[source]#

Flux-driven CPW JPA with launchers on the signal and pump lines.

Parameters:
  • signal_route_length (float) – Distance in µm between the signal launcher and the JPA signal port.

  • pump_route_length (float) – Distance in µm between the pump launcher and the JPA pump port.

Returns:

The chip with the signal launcher waveport o1 and the pump launcher waveport o2.

Return type:

Component

cpw_jpa_chip

vortex_neck_test_chip#

Open the GDSFactory+ schematic or load the YAML layout with gf.get_component("vortex_neck_test_chip") after activating QPDK.

vortex_neck_test_chip

References#

[LZY+21]

Xuegang Li, Yingshan Zhang, Chuhong Yang, Zhiyuan Li, Junhua Wang, Tang Su, Mo Chen, Yongchao Li, Chengyao Li, Zhenyu Mi, Xuehui Liang, Chenlu Wang, Zhen Yang, Yulong Feng, Kehuan Linghu, Huikai Xu, Jiaxiu Han, Weiyang Liu, Peng Zhao, Teng Ma, Ruixia Wang, Jingning Zhang, Yu Song, Pei Liu, Ziting Wang, Zhaohua Yang, Guangming Xue, Yirong Jin, and Haifeng Yu. Vacuum-gap transmon qubits realized using flip-chip technology. Applied Physics Letters, 119(18):184003, November 2021. doi:10.1063/5.0068255.

[RAP+25]

H. Riechert, S. Annabi, A. Peugeot, H. Duprez, M. Hantute, K. Watanabe, T. Taniguchi, E. Arrighi, J. Griesmar, J.-D. Pillet, and L. Bretheau. The carbon nanotube gatemon qubit. Nature Communications, 16(1):7197, August 2025. doi:10.1038/s41467-025-62283-y.

[TSK+25] (1,2)

Mikko Tuokkola, Yoshiki Sunada, Heidi Kivijärvi, Jonatan Albanese, Leif Grönberg, Jukka-Pekka Kaikkonen, Visa Vesterinen, Joonas Govenius, and Mikko Möttönen. Methods to achieve near-millisecond energy relaxation and dephasing times for a superconducting transmon qubit. Nature Communications, 16(1):5421, July 2025. doi:10.1038/s41467-025-61126-0.