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

Add generator for bin based plots for FETs #237

Open
wants to merge 22 commits into
base: main
Choose a base branch
from

Conversation

glatosinski
Copy link
Collaborator

Addresses #200

The scripts generate bin based plots for FETs available in the sky130_fd_pr library.

@google-cla
Copy link

google-cla bot commented Nov 12, 2020

Thanks for your pull request. It looks like this may be your first contribution to a Google open source project (if not, look below for help). Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

📝 Please visit https://cla.developers.google.com/ to sign.

Once you've signed (or fixed any issues), please reply here with @googlebot I signed it! and we'll verify it.


What to do if you already signed the CLA

Individual signers
Corporate signers

ℹ️ Googlers: Go here for more info.

@glatosinski
Copy link
Collaborator Author

@googlebot I signed it!

@glatosinski
Copy link
Collaborator Author

My question is - what should be done when there are lots of combinations of W and L parameters? Should I introduce some steps for those values, or limits? We could possibly make some custom legend so it would fit into the plot, but still the plot lines would overlap heavily in some places.

sim_pfet_01v8_lvt__fT

@mithro
Copy link
Contributor

mithro commented Nov 13, 2020

My question is - what should be done when there are lots of combinations of W and L parameters? Should I introduce some steps for those values, or limits? We could possibly make some custom legend so it would fit into the plot, but still the plot lines would overlap heavily in some places.

It seems like grouping the plots for different W values (1.0, 3.0, 5.0, 7.0) might work?

You should ask on the #analog-design channel on slack about what people would find most useful

@yrrapt
Copy link

yrrapt commented Nov 14, 2020

According to the gm/Id theory you only need to do the plot for one width because you're looking for the current density, drain current/width. So you would sweep the current density for each length to get the plots.

That's the theory anyway, it falls over at the extremes but for the central regions of Id/W it should hold true.

@glatosinski
Copy link
Collaborator Author

I added grouping plots for the different W values. There is also a possibility to explicitly tell what W values should be considered for plots (in --only-w parameter in https://github.com/antmicro/skywater-pdk/blob/200-generate-bin-plots/scripts/python-skywater-pdk/skywater_pdk/fet_simulator/fet_simulator.py or in https://github.com/antmicro/skywater-pdk/blob/200-generate-bin-plots/scripts/python-skywater-pdk/skywater_pdk/fet_simulator/generate-docs-plots.py, where None values should be replaced by a list of desired W values).

I also moved legend outside the plot so it does not cover title or plots:

sim_nfet_01v8__fT_W3_0

During generation of FET plots it turned out that for some bins.csv files the content is invalid, e.g. for https://foss-eda-tools.googlesource.com/skywater-pdk/libs/sky130_fd_pr/+/refs/heads/master/cells/nfet_20v0_nvt_iso/sky130_fd_pr__nfet_20v0_nvt_iso.bins.csv we have:

device,bin,W,L
model corner
,0,30.0,1.0

instead of

device,bin,W,L
sky130_fd_pr__nfet_20v0_nvt_iso,0,30.0,1.0

This occurs for:
https://foss-eda-tools.googlesource.com/skywater-pdk/libs/sky130_fd_pr/+/refs/heads/master/cells/nfet_20v0_nvt_iso/sky130_fd_pr__nfet_20v0_nvt_iso.bins.csv
https://foss-eda-tools.googlesource.com/skywater-pdk/libs/sky130_fd_pr/+/refs/heads/master/cells/nfet_20v0_nvt/sky130_fd_pr__nfet_20v0_nvt.bins.csv
https://foss-eda-tools.googlesource.com/skywater-pdk/libs/sky130_fd_pr/+/refs/heads/master/cells/nfet_20v0_nvt_iso/sky130_fd_pr__nfet_20v0_nvt_iso.bins.csv
https://foss-eda-tools.googlesource.com/skywater-pdk/libs/sky130_fd_pr/+/refs/heads/master/cells/nfet_20v0_zvt/sky130_fd_pr__nfet_20v0_zvt.bins.csv

Later, the bins.csv files are missing for nfet_20v0 and nfet_g11v0d16v0 cells - should I use some default values of bin, W and L in such scenarios?

In the end, the PySpice ends successfully but does not provide values for gm_id, id_W, ft and gm_gds for the simulation of pfet_20v0 and pfet_g5v0d16v0 cells.

@mithro
Copy link
Contributor

mithro commented Nov 16, 2020

@glatosinski - Please log bugs for those other issues.

Copy link
Contributor

@mithro mithro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The plots don't seem to be included in the documentation anywhere?

@glatosinski
Copy link
Collaborator Author

The plots don't seem to be included in the documentation anywhere?

I am not sure what is the final destination for those generated files - should they end up in corresponding FET directories in docs/rules/device-details, or in some separate repository for intermediate results?

@tclarke
Copy link

tclarke commented Nov 16, 2020

Is this working with the rf_* fet models? When I wrote the original, it did not because these models are actually subcircuits with multiple FETs so you can't get a gm from an internal parameter and likely will have to calculate from the Vgg and Iout. Are gm values composable? (can we combine the individual gm values in the constituent fets?)

@glatosinski glatosinski force-pushed the 200-generate-bin-plots branch 2 times, most recently from 9e9a501 to a5613c5 Compare November 25, 2020 09:58
Signed-off-by: Grzegorz Latosinski <glatosinski@antmicro.com>
Signed-off-by: Grzegorz Latosinski <glatosinski@antmicro.com>
Signed-off-by: Grzegorz Latosinski <glatosinski@antmicro.com>
Signed-off-by: Grzegorz Latosinski <glatosinski@antmicro.com>
Signed-off-by: Grzegorz Latosinski <glatosinski@antmicro.com>
Signed-off-by: Grzegorz Latosinski <glatosinski@antmicro.com>
Signed-off-by: Grzegorz Latosinski <glatosinski@antmicro.com>
Signed-off-by: Grzegorz Latosinski <glatosinski@antmicro.com>
Signed-off-by: Grzegorz Latosinski <glatosinski@antmicro.com>
Signed-off-by: Grzegorz Latosinski <glatosinski@antmicro.com>
Signed-off-by: Grzegorz Latosinski <glatosinski@antmicro.com>
Signed-off-by: Grzegorz Latosinski <glatosinski@antmicro.com>
Signed-off-by: Grzegorz Latosinski <glatosinski@antmicro.com>
Signed-off-by: Grzegorz Latosinski <glatosinski@antmicro.com>
Signed-off-by: Grzegorz Latosinski <glatosinski@antmicro.com>
Signed-off-by: Grzegorz Latosinski <glatosinski@antmicro.com>
Signed-off-by: Grzegorz Latosinski <glatosinski@antmicro.com>
Signed-off-by: Grzegorz Latosinski <glatosinski@antmicro.com>
Signed-off-by: Grzegorz Latosinski <glatosinski@antmicro.com>
Signed-off-by: Grzegorz Latosinski <glatosinski@antmicro.com>
Signed-off-by: Grzegorz Latosinski <glatosinski@antmicro.com>
Signed-off-by: Grzegorz Latosinski <glatosinski@antmicro.com>
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.

None yet

4 participants