Skip to content

Commit

Permalink
Merge pull request #378 from gdsfactory/fix_gc_port_type
Browse files Browse the repository at this point in the history
Fix gc port type
  • Loading branch information
joamatab authored May 1, 2024
2 parents 492da34 + bdd15a9 commit 30e05e3
Show file tree
Hide file tree
Showing 7 changed files with 16 additions and 15 deletions.
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ repos:
- tomli

- repo: https://github.com/astral-sh/ruff-pre-commit
rev: "v0.4.1"
rev: "v0.4.2"
hooks:
- id: ruff
args: [ --fix, --exit-non-zero-on-fix ]
Expand Down
5 changes: 1 addition & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@

[![Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/gdsfactory/binder-sandbox/HEAD)
[![pypi](https://img.shields.io/pypi/v/ubcpdk)](https://pypi.org/project/ubcpdk/)
[![issues](https://img.shields.io/github/issues/gdsfactory/ubc)](https://github.com/gdsfactory/ubc/issues)
![forks](https://img.shields.io/github/forks/gdsfactory/ubc)
![Stars](https://img.shields.io/github/stars/gdsfactory/ubc)
[![mit](https://img.shields.io/github/license/gdsfactory/ubc)](https://choosealicense.com/licenses/mit/)
[![codecov](https://codecov.io/gh/gdsfactory/ubc/branch/main/graph/badge.svg?token=T3kCV2gYE9)](https://codecov.io/gh/gdsfactory/ubc)
[![black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)
Expand All @@ -31,7 +28,7 @@ Then you need to restart Klayout to make sure the new technology installed appea

### Installation for developers

For developers you need to `git clone` the GitHub repository, fork it, git add, git commit, git push and merge request your changes.
For developers you need to fork, `git clone` the GitHub repository, git add, git commit, git push and merge request your changes.

```
git clone https://github.com/gdsfactory/ubc.git
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ classifiers = [
"Operating System :: OS Independent"
]
dependencies = [
"gdsfactory==7.25.0",
"gdsfactory==7.25.1",
"gplugins[tidy3d,sax,schematic]>=0.13,<0.14"
]
description = "ubcpdk pdk"
Expand Down
1 change: 1 addition & 0 deletions tests/test_netlists/test_netlists_add_fiber_array_.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ instances:
fanout_length: 0.0
gc_port_labels: null
gc_port_name: o1
gc_port_name_fiber: o2
get_input_label_text_function:
function: get_input_label_text
get_input_labels_function:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,7 @@ instances:
fanout_length: 0.0
gc_port_labels: null
gc_port_name: o1
gc_port_name_fiber: o2
get_input_label_text_function:
function: get_input_label_text
get_input_labels_function:
Expand Down
1 change: 1 addition & 0 deletions tests/test_netlists/test_netlists_dbr_cavity_te_.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ instances:
fanout_length: 0.0
gc_port_labels: null
gc_port_name: o1
gc_port_name_fiber: o2
get_input_label_text_function:
function: get_input_label_text
get_input_labels_function:
Expand Down
19 changes: 10 additions & 9 deletions ubcpdk/components.py
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,7 @@ def gc_te1310() -> gf.Component:
name = prefix_te1310
c.add_port(
name=name,
port_type=name,
port_type="vertical_te",
center=(25, 0),
layer=(1, 0),
width=9,
Expand All @@ -257,7 +257,7 @@ def gc_te1310_8deg() -> gf.Component:
name = prefix_te1310
c.add_port(
name=name,
port_type=name,
port_type="vertical_te",
center=(25, 0),
layer=(1, 0),
width=9,
Expand All @@ -277,7 +277,7 @@ def gc_te1310_broadband() -> gf.Component:
name = prefix_te1310
c.add_port(
name=name,
port_type=name,
port_type="vertical_te",
center=(25, 0),
layer=(1, 0),
width=9,
Expand All @@ -297,7 +297,7 @@ def gc_te1550() -> gf.Component:
name = prefix_te1550
c.add_port(
name=name,
port_type=name,
port_type="vertical_te",
center=(25, 0),
layer=(1, 0),
width=9,
Expand All @@ -317,7 +317,7 @@ def gc_te1550_90nmSlab() -> gf.Component:
name = prefix_te1550
c.add_port(
name=name,
port_type=name,
port_type="vertical_te",
center=(25, 0),
layer=(1, 0),
width=9,
Expand All @@ -337,7 +337,7 @@ def gc_te1550_broadband() -> gf.Component:
name = prefix_te1550
c.add_port(
name=name,
port_type=name,
port_type="vertical_te",
center=(25, 0),
layer=(1, 0),
width=9,
Expand All @@ -357,7 +357,7 @@ def gc_tm1550() -> gf.Component:
name = prefix_tm1550
c.add_port(
name=name,
port_type=name,
port_type="vertical_tm",
center=(25, 0),
layer=(1, 0),
width=9,
Expand Down Expand Up @@ -514,7 +514,6 @@ def add_fiber_array(
ref.rotate(-90)
c.add_ports(ref.ports)
c.copy_child_info(component)

return c


Expand Down Expand Up @@ -816,6 +815,7 @@ def add_pads(

if __name__ == "__main__":
c = straight_heater_metal()
c.pprint_ports()
# c.pprint_ports()
# c = straight()
# c = uc.ring_single_heater()
Expand All @@ -824,7 +824,7 @@ def add_pads(
# c = ring_double(length_y=10)
# c = ring_with_crossing()
# c = mmi1x2()
# c = add_fiber_array(mzi)
c = add_fiber_array(straight_heater_metal)
# c = coupler_ring()
# c = dbr_cavity_te()
# c = dbr_cavity()
Expand All @@ -840,4 +840,5 @@ def add_pads(
# c = ebeam_dc_halfring_straight()
# c = ring_with_crossing()
# c = ring_single()
c.pprint_ports()
c.show(show_ports=False)

0 comments on commit 30e05e3

Please sign in to comment.