Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/KLayout/klayout
/ find_layer
Function
find_layer
testdata/python/dbPCells.py:209–214 ·
view source on GitHub ↗
(ly, lp)
Source
from the content-addressed store, hash-verified
207
pya.LayerInfo.__repr__ = inspect_LayerInfo
208
209
def
find_layer(ly, lp):
210
211
for
li in ly.layer_indices():
212
if
str(ly.get_info(li)) == lp:
213
return
li
214
return
None
215
216
217
def
nh(h):
Callers
4
test_1
Method · 0.70
test_1a
Method · 0.70
test_2
Method · 0.70
test_9
Method · 0.70
Calls
1
str
Function · 0.85
Tested by
4
test_1
Method · 0.56
test_1a
Method · 0.56
test_2
Method · 0.56
test_9
Method · 0.56