-
Notifications
You must be signed in to change notification settings - Fork 33
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
Local OpenLane Installs + Colaboratory #143
Conversation
mohamedleithy
commented
Mar 16, 2022
•
edited by donn
Loading
edited by donn
- Added new option "--using-local-openlane" that allows for dockerless operation
- Modified "openlane_harden" to allow enabling disabling KLAYOUT and CVC in case of using a local openlane install
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sorry I missed this PR, added a few comments afterwards. I'd be happy to send PR to implement the ones you agree with.
env["RUN_KLAYOUT"] = "0" | ||
env["RUN_CVC"] = "0" | ||
env["PDK_ROOT"] = pdk_root | ||
env["MISMATCHES_OK"] = "1" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what abouy moving this to the notebook instead? (as it's quite specific to this environment)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, agreed.
@@ -496,6 +515,12 @@ def openlane_harden( | |||
default=False, | |||
help="Open the last def in Klayout. (Default: False)", | |||
) | |||
@click.option( | |||
"--using-local-openlane", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what about using --openlane-root
instead? (to match the other --pdk-root
option)
}, | ||
"outputs": [], | ||
"source": [ | ||
"!conda install -y -c litex-hub -c conda-forge open_pdks.sky130a=1.0.290 magic openroad netgen yosys gdstk" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what do you think of adding an environment.yml
file to the repo (see https://docs.conda.io/projects/conda/en/latest/user-guide/tasks/manage-environments.html#creating-an-environment-from-an-environment-yml-file) ? so that conda user can also easily install dependencies outside of notebooks.
For example:
channels:
- litex-hub
- conda-forge
dependencies:
- open_pdks.sky130a=1.0.290
- magic
- openroad
- netgen
- yosys
- gdstk
- tcllib
- python
- pip
- pip:
- pyyaml
- click
- pandas
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, that's a great idea. I'll do that.
"!git clone https://github.com/Cloud-V/DFFRAM --branch dffram-dockerless\n", | ||
"%cd /content/DFFRAM\n", | ||
"\n", | ||
"%env NO_CHECK_INSTALL=1\n", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
curious why this is displayed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No reason not to.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I must confess I don't understand what you're asking here.
|
||
subprocess.check_call(args, env=env) | ||
else: | ||
run_docker(f"efabless/openlane:{openlane_version}", args) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
curious if you still need the run_docker
logic here, wouldn't it just work if you instructed the user to do the equivalent of make mount
w/ something like:
docker run -ti -v $(pwd):/mnt/dffram -w /mnt/dffram -v $PDK_ROOT:/mnt/pdkroot -e PDK_ROOT=/mnt/pdkroot efabless/openlane
before running dffram.py
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm weary of replicating OpenLane's make mount
.