gplugins 1.3.6__tar.gz → 1.3.8__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (245) hide show
  1. {gplugins-1.3.6 → gplugins-1.3.8}/PKG-INFO +3 -3
  2. {gplugins-1.3.6 → gplugins-1.3.8}/README.md +2 -2
  3. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/__init__.py +1 -1
  4. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/common/base_models/component.py +3 -0
  5. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/common/utils/get_sparameters_path.py +2 -3
  6. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/get_meep_geometry.py +6 -6
  7. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/write_sparameters_meep.py +6 -6
  8. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/write_sparameters_meep_mpi.py +4 -2
  9. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/lumerical/write_sparameters_lumerical.py +97 -39
  10. {gplugins-1.3.6 → gplugins-1.3.8}/pyproject.toml +2 -2
  11. {gplugins-1.3.6 → gplugins-1.3.8}/LICENSE +0 -0
  12. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/common/__init__.py +0 -0
  13. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/common/base_models/__init__.py +0 -0
  14. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/common/base_models/simulation.py +0 -0
  15. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/common/config.py +0 -0
  16. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/common/types.py +0 -0
  17. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/common/utils/__init__.py +0 -0
  18. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/common/utils/add_simulation_markers.py +0 -0
  19. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/common/utils/async_helpers.py +0 -0
  20. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/common/utils/cache.py +0 -0
  21. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/common/utils/convert_sparameters.py +0 -0
  22. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/common/utils/disable_print.py +0 -0
  23. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/common/utils/get_capacitance.py +0 -0
  24. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/common/utils/get_component_with_net_layers.py +0 -0
  25. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/common/utils/get_effective_indices.py +0 -0
  26. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/common/utils/get_scattering.py +0 -0
  27. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/common/utils/optical_constants.py +0 -0
  28. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/common/utils/parse_layer_stack.py +0 -0
  29. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/common/utils/plot.py +0 -0
  30. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/common/utils/plot_csv.py +0 -0
  31. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/common/utils/port_symmetries.py +0 -0
  32. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/common/utils/tests/test_get_component_with_new_port_layers.py +0 -0
  33. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/devsim/__init__.py +0 -0
  34. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/devsim/doping.py +0 -0
  35. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/devsim/get_simulation.py +0 -0
  36. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/devsim/get_simulation_xsection.py +0 -0
  37. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/devsim/get_solver.py +0 -0
  38. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/devsim/test_devsim.py +0 -0
  39. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/elmer/__init__.py +0 -0
  40. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/elmer/electrostatic.sif.j2 +0 -0
  41. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/elmer/get_capacitance.py +0 -0
  42. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/elmer/tests/test_elmer.py +0 -0
  43. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/fdtdz/__init__.py +0 -0
  44. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/fdtdz/get_epsilon_fdtdz.py +0 -0
  45. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/fdtdz/get_ports_fdtdz.py +0 -0
  46. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/fdtdz/get_sparameters_fdtdz.py +0 -0
  47. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/femwell/__init__.py +0 -0
  48. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/femwell/mode_solver.py +0 -0
  49. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/femwell/solve_thermal.py +0 -0
  50. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/femwell/test_mode_solver.py +0 -0
  51. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gfviz/Makefile +0 -0
  52. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gfviz/__init__.py +0 -0
  53. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gfviz/b64.py +0 -0
  54. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gfviz/gfviz.py +0 -0
  55. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gfviz/netlist.py +0 -0
  56. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gfviz/serve.py +0 -0
  57. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gfviz/static/b64.js +0 -0
  58. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gfviz/static/schemedit.js +0 -0
  59. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gfviz/static/schemedit.wasm +0 -0
  60. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gfviz/templates/example.json +0 -0
  61. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gfviz/templates/index.html +0 -0
  62. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/__init__.py +0 -0
  63. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/get_material.py +0 -0
  64. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/get_port_eigenmode.py +0 -0
  65. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/get_simulation.py +0 -0
  66. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/get_simulation_grating_farfield.py +0 -0
  67. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/get_simulation_grating_fiber.py +0 -0
  68. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/meep_adjoint_optimization.py +0 -0
  69. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/test_eigenmode.py +0 -0
  70. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/test_materials.py +0 -0
  71. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/test_sparameterNxN/test_sparameterNxN_crossing.csv +0 -0
  72. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/test_sparameterNxN/test_sparameterNxN_straight.csv +0 -0
  73. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/test_write_sparameters_meep/test_sparameterNxN_crossing.csv +0 -0
  74. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/test_write_sparameters_meep/test_sparameterNxN_straight.csv +0 -0
  75. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/test_write_sparameters_meep/test_sparameterNxN_symmetries_straight.csv +0 -0
  76. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/test_write_sparameters_meep/test_sparameter_straight_mpi.csv +0 -0
  77. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/test_write_sparameters_meep/test_sparameter_straight_mpi_pool.csv +0 -0
  78. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/test_write_sparameters_meep/test_sparameters_crossing_symmetric.csv +0 -0
  79. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/test_write_sparameters_meep/test_sparameters_straight.csv +0 -0
  80. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/test_write_sparameters_meep/test_sparameters_straight_batch.csv +0 -0
  81. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/test_write_sparameters_meep/test_sparameters_straight_mpi.csv +0 -0
  82. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/test_write_sparameters_meep/test_sparameters_straight_mpi_pool.csv +0 -0
  83. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/test_write_sparameters_meep/test_sparameters_straight_symmetric.csv +0 -0
  84. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/test_write_sparameters_meep.py +0 -0
  85. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/write_sparameters_grating.py +0 -0
  86. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmeep/write_sparameters_meep_batch.py +0 -0
  87. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmsh/__init__.py +0 -0
  88. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmsh/define_polysurfaces.py +0 -0
  89. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmsh/get_mesh.py +0 -0
  90. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmsh/parse_component.py +0 -0
  91. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmsh/parse_gds.py +0 -0
  92. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmsh/tests/test_custom_names.py +0 -0
  93. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmsh/tests/test_meshing_2D.py +0 -0
  94. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmsh/tests/test_meshing_3D.py +0 -0
  95. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmsh/uz_xsection_mesh.py +0 -0
  96. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmsh/xy_xsection_mesh.py +0 -0
  97. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/gmsh/xyz_mesh.py +0 -0
  98. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/__init__.py +0 -0
  99. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/dataprep/__init__.py +0 -0
  100. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/dataprep/regions.py +0 -0
  101. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/drc/__init__.py +0 -0
  102. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/drc/check_duplicated_cells.py +0 -0
  103. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/drc/check_exclusion.py +0 -0
  104. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/drc/check_inclusion.py +0 -0
  105. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/drc/check_space.py +0 -0
  106. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/drc/check_width.py +0 -0
  107. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/drc/count_drc.py +0 -0
  108. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/drc/samples/drc_errors.py +0 -0
  109. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/drc/write_drc.py +0 -0
  110. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/get_density.py +0 -0
  111. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/get_netlist.py +0 -0
  112. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/netlist_graph.py +0 -0
  113. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/netlist_spice_reader.py +0 -0
  114. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/plot_nets.py +0 -0
  115. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/tests/test_dataprep_regions.py +0 -0
  116. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/tests/test_density.py +0 -0
  117. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/tests/test_drc_exclusion.py +0 -0
  118. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/tests/test_drc_inclusion.py +0 -0
  119. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/tests/test_drc_space.py +0 -0
  120. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/tests/test_drc_width.py +0 -0
  121. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/tests/test_global_density.py +0 -0
  122. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/tests/test_netlist_spice_reader.py +0 -0
  123. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/klayout/tests/test_plot_nets.py +0 -0
  124. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/lumerical/README.md +0 -0
  125. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/lumerical/__init__.py +0 -0
  126. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/lumerical/interconnect.py +0 -0
  127. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/lumerical/mapping_ubcpdk.yml +0 -0
  128. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/lumerical/read.py +0 -0
  129. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/lumerical/settings.py +0 -0
  130. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/lumerical/tests/test_lumerical_read_sparameters.py +0 -0
  131. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/lumerical/tests/test_netlist.py +0 -0
  132. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/lumerical/tests/test_netlist_get_routes.py +0 -0
  133. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/lumerical/write_sparameters_lumerical_components.py +0 -0
  134. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/materials/__init__.py +0 -0
  135. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/materials/inorganic.py +0 -0
  136. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/materials/optical/__init__.py +0 -0
  137. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/materials/optical/optical_mat.py +0 -0
  138. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/materials/optical/refractive_index_info.py +0 -0
  139. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/materials/semiconductor/__init__.py +0 -0
  140. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/materials/semiconductor/semiconductor_mat.py +0 -0
  141. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/meow/__init__.py +0 -0
  142. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/meow/meow_eme.py +0 -0
  143. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/meow/test_meow_simulation.py +0 -0
  144. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/__init__.py +0 -0
  145. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/coupler.py +0 -0
  146. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/find_coupling_vs_gap.py +0 -0
  147. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/find_mode_dispersion.py +0 -0
  148. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/find_modes.py +0 -0
  149. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/find_modes_cross_section.py +0 -0
  150. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/find_neff_ng_dw_dh.py +0 -0
  151. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/find_neff_vs_width.py +0 -0
  152. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/get_mode_solver_coupler.py +0 -0
  153. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/get_mode_solver_cross_section.py +0 -0
  154. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/get_mode_solver_rib.py +0 -0
  155. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/modes/neff_vs_width_nitride.csv +0 -0
  156. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/modes/neff_vs_width_rib.csv +0 -0
  157. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/modes/neff_vs_width_strip.csv +0 -0
  158. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/neff_convergence_test.py +0 -0
  159. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/neff_vs_width.csv +0 -0
  160. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/overlap.py +0 -0
  161. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/tests/test_dw_dh/test_dw_dh.csv +0 -0
  162. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/tests/test_dw_dh/test_dw_dh.obtained.csv +0 -0
  163. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/tests/test_dw_dh/test_dw_dh_dispersion.csv +0 -0
  164. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/tests/test_dw_dh.py +0 -0
  165. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/tests/test_find_modes.py +0 -0
  166. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/tests/test_find_modes_dispersion.py +0 -0
  167. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/tests/test_neff_vs_width/test_neff_vs_width.csv +0 -0
  168. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/tests/test_neff_vs_width/test_neff_vs_width.obtained.csv +0 -0
  169. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/tests/test_neff_vs_width.py +0 -0
  170. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/types.py +0 -0
  171. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/modes/waveguide.py +0 -0
  172. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/palace/__init__.py +0 -0
  173. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/palace/driven.json +0 -0
  174. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/palace/electrostatic.json +0 -0
  175. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/palace/get_capacitance.py +0 -0
  176. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/palace/get_scattering.py +0 -0
  177. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/palace/tests/test_palace.py +0 -0
  178. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/path_length_analysis/__init__.py +0 -0
  179. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/path_length_analysis/path_length_analysis.py +0 -0
  180. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/path_length_analysis/path_length_analysis_from_gds.py +0 -0
  181. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/path_length_analysis/test_pathlength_extraction.py +0 -0
  182. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/photonic_circuit_models/__init__.py +0 -0
  183. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/photonic_circuit_models/coupler.py +0 -0
  184. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/photonic_circuit_models/fsr.py +0 -0
  185. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/photonic_circuit_models/heater.py +0 -0
  186. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/photonic_circuit_models/mzi.py +0 -0
  187. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/photonic_circuit_models/ring.py +0 -0
  188. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/process/__init__.py +0 -0
  189. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/process/diffusion.py +0 -0
  190. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/process/implant_tables.py +0 -0
  191. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/process/pysrim.py +0 -0
  192. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/process/silicon.py +0 -0
  193. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/process/skew/antimony_si_skew.csv +0 -0
  194. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/process/skew/arsenic_si_skew.csv +0 -0
  195. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/process/skew/boron_si_skew.csv +0 -0
  196. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/process/skew/phosphorus_si_skew.csv +0 -0
  197. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/sax/__init__.py +0 -0
  198. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/sax/interpolators.py +0 -0
  199. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/sax/mlp.py +0 -0
  200. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/sax/models.py +0 -0
  201. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/sax/parameter.py +0 -0
  202. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/sax/plot_model.py +0 -0
  203. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/sax/read.py +0 -0
  204. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/sax/tests/test_mzi.py +0 -0
  205. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/sax/tests/test_mzi_lattice/test_mzi_lattice.obtained.yml +0 -0
  206. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/sax/tests/test_mzi_lattice/test_mzi_lattice.yml +0 -0
  207. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/sax/tests/test_mzi_lattice.py +0 -0
  208. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/sax/tests/test_parameters.py +0 -0
  209. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/sentaurus/mask_sde.py +0 -0
  210. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/sentaurus/mask_sprocess.py +0 -0
  211. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/sentaurus/sde.py +0 -0
  212. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/sentaurus/sdevice.py +0 -0
  213. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/sentaurus/sprocess.py +0 -0
  214. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/sentaurus/svisual.py +0 -0
  215. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/spice/__init__.py +0 -0
  216. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/spice/spice_to_yaml.py +0 -0
  217. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/spice/tests/__init__.py +0 -0
  218. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/spice/tests/test_interconnect.py +0 -0
  219. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/tidy3d/__init__.py +0 -0
  220. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/tidy3d/component.py +0 -0
  221. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/tidy3d/get_results.py +0 -0
  222. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/tidy3d/get_simulation_grating_coupler.py +0 -0
  223. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/tidy3d/materials.py +0 -0
  224. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/tidy3d/modes.py +0 -0
  225. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/tidy3d/tests/test_component_modeler.py +0 -0
  226. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/tidy3d/tests/test_materials.py +0 -0
  227. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/tidy3d/tests/test_modes/test_sweep_width.csv +0 -0
  228. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/tidy3d/tests/test_modes/test_sweep_width.obtained.csv +0 -0
  229. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/tidy3d/tests/test_modes_coupler.py +0 -0
  230. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/tidy3d/tests/test_modes_waveguide.py +0 -0
  231. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/tidy3d/tests/test_plot_simulation_grating_coupler.py +0 -0
  232. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/tidy3d/tests/test_write_sparameters.py +0 -0
  233. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/tidy3d/tests/tests_sparameters/sim_ref.yaml +0 -0
  234. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/tidy3d/tests/tests_sparameters/test_write_sparameters.py +0 -0
  235. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/tidy3d/tests/tests_sparameters/test_write_sparameters_grating_coupler.py +0 -0
  236. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/tidy3d/types.py +0 -0
  237. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/tidy3d/util.py +0 -0
  238. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/tidy3d/write_sparameters_grating_coupler.py +0 -0
  239. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/typings.py +0 -0
  240. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/vlsir/__init__.py +0 -0
  241. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/vlsir/export_netlist.py +0 -0
  242. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/vlsir/tests/resources/pads_correct.cir +0 -0
  243. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/vlsir/tests/resources/pads_correct.scs +0 -0
  244. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/vlsir/tests/resources/pads_correct.sp +0 -0
  245. {gplugins-1.3.6 → gplugins-1.3.8}/gplugins/vlsir/tests/test_vlsir.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: gplugins
3
- Version: 1.3.6
3
+ Version: 1.3.8
4
4
  Summary: gdsfactory plugins
5
5
  Keywords: python
6
6
  Author-email: gdsfactory <contact@gdsfactory.com>
@@ -82,7 +82,7 @@ Provides-Extra: schematic
82
82
  Provides-Extra: tidy3d
83
83
  Provides-Extra: vlsir
84
84
 
85
- # gplugins 1.3.6
85
+ # gplugins 1.3.8
86
86
 
87
87
  [![docs](https://github.com/gdsfactory/gplugins/actions/workflows/pages.yml/badge.svg)](https://gdsfactory.github.io/gplugins/)
88
88
  [![PyPI](https://img.shields.io/pypi/v/gplugins)](https://pypi.org/project/gplugins/)
@@ -128,7 +128,7 @@ pip install "gdsfactory[full]" --upgrade
128
128
  or
129
129
 
130
130
  ```bash
131
- pip install "gplugins[devsim,femwell,gmsh,schematic,meow,meshwell,ray,sax,tidy3d]" --upgrade
131
+ pip install "gplugins[devsim,femwell,gmsh,schematic,meow,meshwell,sax,tidy3d]" --upgrade
132
132
  ```
133
133
 
134
134
  Or install only the plugins you need. For example:
@@ -1,4 +1,4 @@
1
- # gplugins 1.3.6
1
+ # gplugins 1.3.8
2
2
 
3
3
  [![docs](https://github.com/gdsfactory/gplugins/actions/workflows/pages.yml/badge.svg)](https://gdsfactory.github.io/gplugins/)
4
4
  [![PyPI](https://img.shields.io/pypi/v/gplugins)](https://pypi.org/project/gplugins/)
@@ -44,7 +44,7 @@ pip install "gdsfactory[full]" --upgrade
44
44
  or
45
45
 
46
46
  ```bash
47
- pip install "gplugins[devsim,femwell,gmsh,schematic,meow,meshwell,ray,sax,tidy3d]" --upgrade
47
+ pip install "gplugins[devsim,femwell,gmsh,schematic,meow,meshwell,sax,tidy3d]" --upgrade
48
48
  ```
49
49
 
50
50
  Or install only the plugins you need. For example:
@@ -1,6 +1,6 @@
1
1
  """gplugins - gdsfactory plugins."""
2
2
 
3
- __version__ = "1.3.6"
3
+ __version__ = "1.3.8"
4
4
 
5
5
  import pathlib
6
6
 
@@ -290,6 +290,9 @@ class LayeredComponentBase(BaseModel):
290
290
  def get_port_layers(self, port: gf.Port) -> tuple[str, ...]:
291
291
  layer_name = get_layer_name(port.layer)
292
292
 
293
+ if "_intent" in layer_name:
294
+ layer_name = layer_name.replace("_intent", "")
295
+
293
296
  derived_layers = []
294
297
  for l_name, level in self.layer_stack.layers.items():
295
298
  if layer_name in str(level.layer):
@@ -31,8 +31,7 @@ def _get_sparameters_path(
31
31
  dirpath: PathType | None = PATH.sparameters,
32
32
  **kwargs,
33
33
  ) -> Path:
34
- """Return Sparameters npz filepath hashing simulation settings for \
35
- a consistent unique name.
34
+ """Return Sparameters npz filepath hashing simulation settings for a consistent unique name.
36
35
 
37
36
  Args:
38
37
  component: component or component factory.
@@ -47,7 +46,7 @@ def _get_sparameters_path(
47
46
 
48
47
  dirpath = pathlib.Path(dirpath)
49
48
  dirpath = (
50
- dirpath / component.function_name
49
+ dirpath / component.name
51
50
  if hasattr(component, "function_name")
52
51
  else dirpath
53
52
  )
@@ -58,14 +58,14 @@ def get_meep_geometry_from_component(
58
58
  layer = level.layer
59
59
 
60
60
  if isinstance(layer, LogicalLayer):
61
- assert isinstance(layer.layer, tuple | LayerEnum)
62
- layer_tuple = cast(tuple[int, int], tuple(layer.layer))
61
+ layer_tuple = gf.get_layer_tuple(layer.layer)
63
62
  elif isinstance(layer, DerivedLayer):
64
- assert level.derived_layer is not None
65
- assert isinstance(level.derived_layer.layer, tuple | LayerEnum)
66
- layer_tuple = cast(tuple[int, int], tuple(level.derived_layer.layer))
63
+ layer_tuple = gf.get_layer_tuple(level.derived_layer.layer)
64
+ elif isinstance(layer, tuple):
65
+ # Handle plain tuple layers directly
66
+ layer_tuple = layer
67
67
  else:
68
- raise ValueError(f"Layer {layer!r} is not a DerivedLayer or LogicalLayer")
68
+ raise ValueError(f"Layer {layer!r} is not a DerivedLayer, LogicalLayer, or tuple")
69
69
 
70
70
  layer_index = int(get_layer(layer_tuple))
71
71
 
@@ -54,8 +54,7 @@ def remove_simulation_kwargs(d: dict[str, Any]) -> dict[str, Any]:
54
54
  def parse_port_eigenmode_coeff(
55
55
  port_name: str, ports: dict[str, Port], sim_dict: dict, port_mode: int = 0
56
56
  ):
57
- """Returns the coefficients relative to whether the wavevector is entering or \
58
- exiting simulation.
57
+ """Returns the coefficients relative to whether the wavevector is entering or exiting simulation.
59
58
 
60
59
  Args:
61
60
  port_index: index of port.
@@ -320,7 +319,7 @@ def write_sparameters_meep(
320
319
  filepath = filepath or get_sparameters_path(
321
320
  component=component,
322
321
  dirpath=dirpath,
323
- layer_stack=layer_stack,
322
+ layer_stack=layer_stack.to_dict(),
324
323
  **sim_settings,
325
324
  )
326
325
 
@@ -605,8 +604,8 @@ settings_write_sparameters_meep = set(sig.parameters.keys()).union(
605
604
  )
606
605
 
607
606
  if __name__ == "__main__":
608
- wavelength_start = 1.26
609
- wavelength_stop = 1.36
607
+ wavelength_start = 1.5
608
+ wavelength_stop = 1.6
610
609
  sim_settings = dict(
611
610
  wavelength_start=wavelength_start, wavelength_stop=wavelength_stop
612
611
  )
@@ -621,8 +620,9 @@ if __name__ == "__main__":
621
620
  sp = write_sparameters_meep(
622
621
  c,
623
622
  run=True,
624
- animate=True,
623
+ #animate=True,
625
624
  is_3d=False,
625
+ ymargin=3,
626
626
  plot_args={
627
627
  "eps_parameters": {"contour": True},
628
628
  "field_parameters": {
@@ -45,7 +45,7 @@ def write_sparameters_meep_mpi(
45
45
  cores: int = core_materials,
46
46
  filepath: PathType | None = None,
47
47
  dirpath: PathType | None = None,
48
- temp_dir: Path = temp_dir_default,
48
+ temp_dir: Path|str = temp_dir_default,
49
49
  temp_file_str: str = "write_sparameters_meep_mpi",
50
50
  live_output: bool = False,
51
51
  overwrite: bool = False,
@@ -152,6 +152,7 @@ def write_sparameters_meep_mpi(
152
152
  filepath.unlink()
153
153
 
154
154
  # Save all the simulation arguments for later retrieval
155
+ temp_dir = Path(temp_dir)
155
156
  temp_dir.mkdir(exist_ok=True, parents=True)
156
157
  tempfile = temp_dir / temp_file_str
157
158
  filepath_json = tempfile.with_suffix(".json")
@@ -178,7 +179,7 @@ def write_sparameters_meep_mpi(
178
179
  "if __name__ == '__main__':\n",
179
180
  f"\twith open(\"{parameters_file}\", 'rb') as inp:\n",
180
181
  "\t\tparameters_dict = pickle.load(inp)\n\n",
181
- f"\tcomponent = import_gds({str(component_file)!r}, read_metadata=True)\n",
182
+ f"\tcomponent = import_gds({str(component_file)!r})\n",
182
183
  f"\tfilepath_json = pathlib.Path({str(filepath_json)!r})\n",
183
184
  "\tlayer_stack = LayerStack.parse_raw(filepath_json.read_text())\n",
184
185
  f"\twrite_sparameters_meep(component=component, overwrite={overwrite}, "
@@ -254,6 +255,7 @@ if __name__ == "__main__":
254
255
  temp_dir="./test/",
255
256
  filepath="instance_dict.csv",
256
257
  resolution=20,
258
+ is_3d=False,
257
259
  )
258
260
  sp = np.load(filepath)
259
261
  print(list(sp.keys()))
@@ -4,7 +4,7 @@ from __future__ import annotations
4
4
 
5
5
  import shutil
6
6
  import time
7
- from typing import TYPE_CHECKING
7
+ from typing import TYPE_CHECKING, cast
8
8
 
9
9
  import gdsfactory as gf
10
10
  import numpy as np
@@ -17,6 +17,8 @@ from gdsfactory.generic_tech.simulation_settings import (
17
17
  )
18
18
  from gdsfactory.pdk import get_layer_stack
19
19
  from gdsfactory.technology import LayerStack
20
+ from gdsfactory.technology.layer_stack import DerivedLayer, LogicalLayer
21
+ from gdsfactory.typings import LayerEnum
20
22
 
21
23
  from gplugins.common.utils.get_sparameters_path import (
22
24
  get_sparameters_path_lumerical as get_sparameters_path,
@@ -84,12 +86,13 @@ def write_sparameters_lumerical(
84
86
  material_name_to_lumerical: dict[str, MaterialSpec] | None = None,
85
87
  delete_fsp_files: bool = True,
86
88
  xmargin: float = 0,
87
- ymargin: float = 0,
88
- xmargin_left: float = 0,
89
- xmargin_right: float = 0,
90
- ymargin_top: float = 0,
91
- ymargin_bot: float = 0,
89
+ ymargin: float = 3,
90
+ xmargin_left: float | None = None,
91
+ xmargin_right: float | None = None,
92
+ ymargin_top: float | None = None,
93
+ ymargin_bot: float | None = None,
92
94
  zmargin: float = 1.0,
95
+ exclude_layers: list[int] | None = None,
93
96
  **settings,
94
97
  ) -> np.ndarray:
95
98
  r"""Returns and writes component Sparameters using Lumerical FDTD.
@@ -140,6 +143,8 @@ def write_sparameters_lumerical(
140
143
  ymargin_top: top distance from component to PML.
141
144
  ymargin_bot: bottom distance from component to PML.
142
145
  zmargin: thickness for cladding above and below core.
146
+ exclude_layers: list of layer indices to exclude from simulation.
147
+ settings: additional simulation settings to overwrite
143
148
 
144
149
  Keyword Args:
145
150
  background_material: for the background.
@@ -201,6 +206,12 @@ def write_sparameters_lumerical(
201
206
  component = component
202
207
  sim_settings = dict(simulation_settings)
203
208
 
209
+
210
+ xmargin_left = xmargin_left or xmargin
211
+ xmargin_right = xmargin_right or xmargin
212
+ ymargin_top = ymargin_top or ymargin
213
+ ymargin_bot = ymargin_bot or ymargin
214
+
204
215
  layer_to_thickness = layer_stack.get_layer_to_thickness()
205
216
  layer_to_zmin = layer_stack.get_layer_to_zmin()
206
217
  layer_to_material = layer_stack.get_layer_to_material()
@@ -223,10 +234,10 @@ def write_sparameters_lumerical(
223
234
  component_with_padding = gf.add_padding_container(
224
235
  component_with_booleans,
225
236
  default=0,
226
- top=ymargin or ymargin_top,
227
- bottom=ymargin or ymargin_bot,
228
- left=xmargin or xmargin_left,
229
- right=xmargin or xmargin_right,
237
+ top=ymargin_top,
238
+ bottom=ymargin_bot,
239
+ left=xmargin_left,
240
+ right=xmargin_right,
230
241
  )
231
242
 
232
243
  component_extended = gf.components.extend_ports(
@@ -240,6 +251,10 @@ def write_sparameters_lumerical(
240
251
  component_extended_beyond_pml = gf.components.extension.extend_ports(
241
252
  component=component_extended, length=ss.port_extension
242
253
  )
254
+ component_extended_beyond_pml = component_extended_beyond_pml.copy()
255
+ component_extended_beyond_pml.flatten()
256
+ component_extended_beyond_pml.name = "top"
257
+
243
258
  gdspath = component_extended_beyond_pml.write_gds()
244
259
 
245
260
  filepath_npz = get_sparameters_path(
@@ -269,12 +284,27 @@ def write_sparameters_lumerical(
269
284
  index_to_thickness = {}
270
285
  index_to_zmin = {}
271
286
  for level in layer_stack.layers.values():
272
- if level.derived_layer is None:
273
- index_to_thickness[level.layer.layer] = level.thickness
274
- index_to_zmin[level.layer.layer] = level.thickness
287
+ layer = level.layer
288
+
289
+ if isinstance(layer, LogicalLayer):
290
+ assert isinstance(layer.layer, tuple | LayerEnum)
291
+ layer_tuple = cast(tuple[int, int], tuple(layer.layer))
292
+ elif isinstance(layer, DerivedLayer):
293
+ assert level.derived_layer is not None
294
+ assert isinstance(level.derived_layer.layer, tuple | LayerEnum)
295
+ layer_tuple = cast(tuple[int, int], tuple(level.derived_layer.layer))
296
+ elif isinstance(layer, tuple):
297
+ # Handle plain tuple layers directly
298
+ layer_tuple = cast(tuple[int, int], layer)
275
299
  else:
276
- index_to_thickness[level.derived_layer.layer] = level.zmin
277
- index_to_zmin[level.derived_layer.layer] = level.zmin
300
+ raise ValueError(
301
+ f"Layer {layer!r} is not a DerivedLayer, LogicalLayer, or tuple"
302
+ )
303
+
304
+ layer_index = int(gf.get_layer(layer_tuple))
305
+
306
+ index_to_thickness[layer_index] = level.thickness
307
+ index_to_zmin[layer_index] = level.zmin
278
308
 
279
309
  layers_thickness = [
280
310
  index_to_thickness[gf.get_layer(layer)]
@@ -344,6 +374,9 @@ def write_sparameters_lumerical(
344
374
  name="clad",
345
375
  )
346
376
 
377
+ # Set cladding opacity
378
+ s.setnamed("clad", "alpha", 0.1)
379
+
347
380
  material_name_to_lumerical_new = material_name_to_lumerical or {}
348
381
  material_name_to_lumerical = ss.material_name_to_lumerical.copy()
349
382
  material_name_to_lumerical.update(**material_name_to_lumerical_new)
@@ -364,39 +397,64 @@ def write_sparameters_lumerical(
364
397
  simulation_time=ss.simulation_time,
365
398
  simulation_temperature=ss.simulation_temperature,
366
399
  )
367
- component_layers = component_with_booleans.layers
368
400
 
369
- for layer, thickness in layer_to_thickness.items():
370
- if layer not in component_layers:
371
- continue
401
+ exclude_layers = exclude_layers or []
402
+ polygons_per_layer = component_extended_beyond_pml.get_polygons_points(merge=True)
372
403
 
373
- if layer not in layer_to_material:
374
- raise ValueError(f"{layer} not in {layer_to_material.keys()}")
375
-
376
- material_name = layer_to_material[layer]
377
- if material_name not in material_name_to_lumerical:
404
+ for level in layer_stack.layers.values():
405
+ layer = level.layer
406
+
407
+ if isinstance(layer, LogicalLayer):
408
+ layer_tuple = gf.get_layer_tuple(layer.layer)
409
+ elif isinstance(layer, DerivedLayer):
410
+ layer_tuple = gf.get_layer_tuple(level.derived_layer.layer)
411
+ elif isinstance(layer, tuple):
412
+ # Handle plain tuple layers directly
413
+ layer_tuple = layer
414
+ else:
378
415
  raise ValueError(
379
- f"{material_name!r} not in {list(material_name_to_lumerical.keys())}"
416
+ f"Layer {layer!r} is not a DerivedLayer, LogicalLayer, or tuple"
380
417
  )
381
- material = material_name_to_lumerical[material_name]
382
418
 
383
- if layer not in layer_to_zmin:
384
- raise ValueError(f"{layer} not in {list(layer_to_zmin.keys())}")
419
+ layer_index = int(gf.get_layer(layer_tuple))
420
+
421
+ if layer_index in exclude_layers:
422
+ continue
385
423
 
386
- zmin = layer_to_zmin[layer]
387
- zmax = zmin + thickness
388
- z = (zmax + zmin) / 2
424
+ if layer_index not in polygons_per_layer:
425
+ continue
389
426
 
390
- s.gdsimport(str(gdspath), "top", f"{layer[0]}:{layer[1]}")
391
- layername = f"GDS_LAYER_{layer[0]}:{layer[1]}"
392
- s.setnamed(layername, "z", z * 1e-6)
393
- s.setnamed(layername, "z span", thickness * 1e-6)
394
- set_material(session=s, structure=layername, material=material)
395
- logger.info(f"adding {layer}, thickness = {thickness} um, zmin = {zmin} um ")
427
+ zmin = level.zmin
428
+
429
+ if zmin is not None:
430
+ thickness = level.thickness
431
+ material_name = layer_to_material[layer]
432
+ if material_name not in material_name_to_lumerical:
433
+ raise ValueError(
434
+ f"{material_name!r} not in {list(material_name_to_lumerical.keys())}"
435
+ )
436
+ material = material_name_to_lumerical[material_name]
437
+
438
+ if layer not in layer_to_zmin:
439
+ raise ValueError(f"{layer} not in {list(layer_to_zmin.keys())}")
440
+
441
+ zmin = layer_to_zmin[layer]
442
+ zmax = zmin + thickness
443
+ z = (zmax + zmin) / 2
444
+
445
+ s.gdsimport(str(gdspath), "top", f"{layer_tuple[0]}:{layer_tuple[1]}")
446
+ layername = f"GDS_LAYER_{layer_tuple[0]}:{layer_tuple[1]}"
447
+ s.setnamed(layername, "z", z * 1e-6)
448
+ s.setnamed(layername, "z span", thickness * 1e-6)
449
+ set_material(session=s, structure=layername, material=material)
450
+ logger.info(
451
+ f"adding {layer_tuple}, thickness = {thickness} um, zmin = {zmin} um "
452
+ )
396
453
 
397
454
  for i, port in enumerate(ports):
398
- zmin = layer_to_zmin[port.layer]
399
- thickness = layer_to_thickness[port.layer]
455
+ port_layer_index = gf.get_layer(port.layer)
456
+ zmin = index_to_zmin[port_layer_index]
457
+ thickness = index_to_thickness[port_layer_index]
400
458
  z = (zmin + thickness) / 2
401
459
  zspan = 2 * ss.port_margin + thickness
402
460
 
@@ -25,7 +25,7 @@ license = {file = "LICENSE"}
25
25
  name = "gplugins"
26
26
  readme = "README.md"
27
27
  requires-python = ">=3.11"
28
- version = "1.3.6"
28
+ version = "1.3.8"
29
29
 
30
30
  [project.optional-dependencies]
31
31
  dev = [
@@ -189,7 +189,7 @@ message_template = "Bump to {new_version}"
189
189
  tag_template = "v{new_version}"
190
190
 
191
191
  [tool.tbump.version]
192
- current = "1.3.6"
192
+ current = "1.3.8"
193
193
  regex = '''
194
194
  (?P<major>\d+)
195
195
  \.
File without changes
File without changes