Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create SWG_Ring.py #293

Merged
merged 3 commits into from
Jul 23, 2024
Merged

Create SWG_Ring.py #293

merged 3 commits into from
Jul 23, 2024

Conversation

bcohenkl55
Copy link
Contributor

Sub-Wavelength Grating Ring Resonator - Improved version of "SWG_MultiBox_Ring"

Sub-Wavelength Grating Ring Resonator - Improved version of "SWG_MultiBox_Ring"
@codecov-commenter
Copy link

codecov-commenter commented Jul 22, 2024

Codecov Report

Attention: Patch coverage is 94.56522% with 10 lines in your changes missing coverage. Please review.

Project coverage is 73.34%. Comparing base (0db1171) to head (96465f9).

Files Patch % Lines
...ayout/EBeam/pymacros/pcells_EBeam_Beta/SWG_Ring.py 94.87% 8 Missing ⚠️
...eam/pymacros/pcells_EBeam_Beta/spiral_paperclip.py 92.85% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #293      +/-   ##
==========================================
+ Coverage   73.00%   73.34%   +0.34%     
==========================================
  Files          93       94       +1     
  Lines       11284    11467     +183     
==========================================
+ Hits         8238     8411     +173     
- Misses       3046     3056      +10     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@lukasc-ubc
Copy link
Member

Could you use the following to make the pins?

from SiEPIC.utils.layout import make_pin
make_pin(self.cell, "optA", [x,y], self.wg_width, LayerPinRecN, 0)

'''
Makes a pin that SiEPIC-Tools will recognize
cell: which cell to draw it in
name: text label for the pin
center: location, int [x,y]
w: pin width
layer: layout.layer() integer type, or string
direction = 
    0: right
    90: up
    180: left
    270: down

Units: input can be float for microns, or int for database units (typ. nm)

@bcohenkl55
Copy link
Contributor Author

Updated. Thanks Lukas

Updated the total length parameter - before it was just measuring the average length of the straight waveguide section. Unless this was the desired functionality, I changed it to calculate the entire length of the spiral. This can probably be done more elegantly, but it works!
@lukasc-ubc
Copy link
Member

Thanks Ben.

@lukasc-ubc lukasc-ubc merged commit cd2fc67 into SiEPIC:master Jul 23, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants