Saptarshi Ghosh
06/11/2024, 11:50 AM...Creating nmos component...
2024-06-11 13:35:27.864 | INFO | gdsfactory.pdk:activate:337 - 'sky130' PDK is now active
...Showing nmos component...
------miniforge3/envs/fasoc/lib/python3.10/site-packages/gdsfactory/show.py:40: UserWarning: Unnamed cells, 1 in 'Unnamed_03b80ae3'
gdspath = component.write_gds(
2024-06-11 13:35:30.677 | WARNING | gdsfactory.klive:show:48 - Could not connect to klive server. Is klayout open and klive plugin installed?
Created nmos component!
...Running LVS...
using user specified pdk_root, will search for required files in the specified directory
2024-06-11 13:35:30.679 | INFO | gdsfactory.component:_write_library:1851 - Wrote to '/tmp/tmpl2r2gt9g/nmos_test.gds'
Magic 8.3 revision 464 - Compiled on Sat Mar 9 23:18:29 UTC 2024.
Starting magic under Tcl interpreter
Using the terminal as the console.
Using NULL graphics device.
Processing system .magicrc file
Using technology "minimum", version 0.0
Creating new cell
Netgen 1.5.272 compiled on Tue Mar 5 23:16:53 UTC 2024
Warning: netgen command 'format' use fully-qualified name '::netgen::format'
Warning: netgen command 'global' use fully-qualified name '::netgen::global'
Reading netlist file /tmp/tmpl2r2gt9g/nmos_test_lvsmag.spice
-1
while executing
"netgen::readnet $file1"
(procedure "lvs" line 58)
invoked from within
"lvs {/tmp/tmpl2r2gt9g/nmos_test_lvsmag.spice nmos_test} {/tmp/tmpl2r2gt9g/nmos_test.spice nmos_test} /usr/bin/miniconda3/share/pdk/sky130A/libs.tech/n..."
("eval" body line 1)
invoked from within
"eval $argv"
Traceback (most recent call last):
File "-----/OpenFASOC/openfasoc/generators/glayout/test_glayout.py", line 176, in <module>
place_nfet_run_lvs()
File "---/OpenFASOC/openfasoc/generators/glayout/test_glayout.py", line 160, in place_nfet_run_lvs
sky130.lvs_netgen(nmos_component, 'nmos_test')
File "--/miniforge3/envs/fasoc/lib/python3.10/site-packages/pydantic/deprecated/decorator.py", line 55, in wrapper_function
return vd.call(*args, **kwargs)
File "--/miniforge3/envs/fasoc/lib/python3.10/site-packages/pydantic/deprecated/decorator.py", line 150, in call
return self.execute(m)
File "--/miniforge3/envs/fasoc/lib/python3.10/site-packages/pydantic/deprecated/decorator.py", line 222, in execute
return self.raw_function(**d, **var_kwargs)
File "--/OpenFASOC/openfasoc/generators/glayout/glayout/flow/pdk/mappedpdk.py", line 753, in lvs_netgen
raise ValueError("LVS report not found!")
ValueError: LVS report not found!
Now it says using user specified pdk_root, will search for required files in the specified directory
and I have defined PDK_ROOT in my bashrc, accordingly but not sure why its checking in this path "lvs {/tmp/tmpl2r2gt9g/nmos_test_lvsmag.spice nmos_test} {/tmp/tmpl2r2gt9g/nmos_test.spice nmos_test} /usr/bin/miniconda3/share/pdk/sky130A/libs.tech/n..."
Chetanya Goyal
06/11/2024, 3:10 PMtest_glayout.py
script?Chetanya Goyal
06/11/2024, 3:11 PMSaptarshi Ghosh
06/11/2024, 3:31 PMpaths_to_check = [
Path("/usr/bin/miniconda3/share/pdk/"),
Path(f"/home/{os.getenv('LOGNAME')}/miniconda3/share/pdk/"),
Path(os.getenv('PDK_ROOT'))
]
the third line is added.
2. no! My conda (or mamba rather) is installed locally. pdk_root.resolve().parents[1]
shows
PosixPath('/home/sapta/miniforge3/envs/fasoc')
with sapta being my username
I got the problem. Didn't found the solution yet. The problem is with the place_nfet_run_lvs()
function which calls sky130.lvs_netgen(nmos_component, 'nmos_test')
now upon checking the lvs_netgen
it defaults to None
which in turn triggers
if pdk_root is None:
print("using default pdk_root: /usr/bin/miniconda3/share/pdk/")
else:
print('using provided pdk_root')
self.pdk_files['pdk_root'] = pdk_root
Which is creating the problem. Strangely modifying the command to following doesn't solve the problem
sky130.lvs_netgen(nmos_component, 'nmos_test',pdk_root=os.getenv('PDK_ROOT'))
Saptarshi Ghosh
06/11/2024, 4:29 PMSaptarshi Ghosh
06/11/2024, 6:13 PM--/openfasoc/generators/glayout/glayout/flow/pdk/sky130_mapped/sky130_mapped.py
which had hard coded pdk_root path
pdk_root = Path('/usr/bin/miniconda3/share/pdk/')
replacing that with
import os; pdk_root=Path(f"{os.getenv('PDK_ROOT')}/")
solved the problem.
Is it possible to open an issue in the github repo and submit the solution? I have never done the same. Basically in all libraries, the PDK_ROOT environment should give the pathChetanya Goyal
06/12/2024, 1:40 PMPDK_ROOT
Chetanya Goyal
06/12/2024, 1:40 PM