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

Update ngspice regression tests README to include information about how to interpret the results #71

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
83 changes: 61 additions & 22 deletions models/ngspice/testing/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,34 +6,31 @@ Explains how to run GF180nm models-ngspice regression.

```text
📦testing
┣ 📜Makefile
┣ 📜README.md
┣ 📦regression
┣ 📦smoke_test
┣ 📦180MCU_SPICE_Models
┣ 📜Makefile (Makefile to setup test cases)
┣ 📜README.md (This file)
┣ 📦sc_regression/gf180mcu_fd_sc_mcu7t5v0 (Standard cells regression that simulates the standard cells using different voltage stimulus.)
┣ 📦regression (This is the regression folder that has a test case per device.)
┣ 📦smoke_test (An inverter design that simulates in all corners to make sure that all corners will work with no issue.)
┣ 📦180MCU_SPICE_Models (Foundry measurement data used for model calibration.)
```

## Prerequisites

At a minimum:

- Git 2.35+
- Python 3.6+
- ngspice-36+

### On Ubuntu, you can just
- ngspice-37+

`apt install -y build-essential python3`

- Check this [ngspice](http://ngspice.sourceforge.net/download.html) for ngspice installation.
Our test environment has the following:
- Python 3.9.12
- ngspice-37

## Regression Usage

To make a full test for GF180nm models-ngspice, you could use the following command in testing directory:
- To make a full test for GF180nm models-ngspice, you could use the following command in testing directory:

```bash
make all
```
```bash
make all
```

- You could also check allowed targets in the Makefile, using the following command:

Expand All @@ -43,9 +40,51 @@ make all

## **Regression Outputs**

- The resulting files are in `regression/<device_folder>/` with name of `<device_name><options>` that contains:
After running regression, you should find the following in the folder `run_<date>_<time>` under that folder you will find the folder structure:
```text
run_<date_time>/
├── bjt_beta
│ ├── device_netlists (Template Netlists)
│ └── models_regression.py (Regression script for device)
│ ├── <dev>_... (Output folder after runing with run logs and actual netlists)
├── bjt_cj
│ ├── device_netlists (Template Netlists)
│ ├── models_regression.py (Regression script for device)
│ ├── <dev>_... (Output folder after runing with run logs and actual netlists)
├── bjt_iv
│ ├── device_netlists (Template Netlists)
│ └── models_regression.py (Regression script for device)
│ ├── <dev>_... (Output folder after runing with run logs and actual netlists)
├── diode
│ ├── 0_measured_data
│ ├── device_netlists (Template Netlists)
│ ├── <dev>_... (Output folder after runing with run logs and actual netlists)
│ ├── models_regression.py (Regression script for device)
├── mimcap_c
│ ├── device_netlists (Template Netlists)
│ └── models_regression.py (Regression script for device)
│ ├── <dev>_... (Output folder after runing with run logs and actual netlists)
├── moscap_c
│ ├── device_netlists (Template Netlists)
│ └── models_regression.py (Regression script for device)
│ ├── <dev>_... (Output folder after runing with run logs and actual netlists)
├── mos_cv
│ ├── device_netlists (Template Netlists)
│ └── models_regression.py (Regression script for device)
│ ├── <dev>_... (Output folder after runing with run logs and actual netlists)
├── mos_iv_vbs
│ ├── device_netlists (Template Netlists)
│ └── models_regression.py (Regression script for device)
│ ├── <dev>_... (Output folder after runing with run logs and actual netlists)
├── mos_iv_vgs
│ ├── device_netlists (Template Netlists)
│ └── models_regression.py (Regression script for device)
│ ├── <dev>_... (Output folder after runing with run logs and actual netlists)
├── resistor_r
│ ├── device_netlists (Template Netlists)
│ └── models_regression.py (Regression script for device)
│ ├── <dev>_... (Output folder after runing with run logs and actual netlists)
└── run_log.log (Summary of all runs for all devices)
```

1. A final report file of all results.
2. measured folder that contains measured data used in regression.
3. simulated folder that contains simulated data used in regression.
4. netlists folder that contains spice files used in simulation.
It's important to check the `run_log.log` to see the error per device.
66 changes: 51 additions & 15 deletions models/xyce/testing/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,19 +21,13 @@ At a minimum:
- Python 3.6+
- Xyce 7.5+

### On Ubuntu, you can just

`apt install -y build-essential python3`

- Check this [xyce](https://xyce.sandia.gov/documentation-tutorials/building-guide/) for Xyce installation.

## Regression Usage

To make a full test for GF180nm models-xyce, you could use the following command in testing directory:
- To make a full test for GF180nm models-xyce, you could use the following command in testing directory:

```bash
make all
```
```bash
make all
```

- You could also check allowed targets in the Makefile, using the following command:

Expand All @@ -43,9 +37,51 @@ make all

## **Regression Outputs**

- The resulting files are in `regression/<device_folder>/` with name of `<device_name><options>` that contains:
After running regression, you should find the following in the folder `run_<date>_<time>` under that folder you will find the folder structure:
```text
run_<date_time>/
├── bjt_beta
│ ├── device_netlists (Template Netlists)
│ └── models_regression.py (Regression script for device)
│ ├── <dev>_... (Output folder after runing with run logs and actual netlists)
├── bjt_cj
│ ├── device_netlists (Template Netlists)
│ ├── models_regression.py (Regression script for device)
│ ├── <dev>_... (Output folder after runing with run logs and actual netlists)
├── bjt_iv
│ ├── device_netlists (Template Netlists)
│ └── models_regression.py (Regression script for device)
│ ├── <dev>_... (Output folder after runing with run logs and actual netlists)
├── diode
│ ├── 0_measured_data
│ ├── device_netlists (Template Netlists)
│ ├── <dev>_... (Output folder after runing with run logs and actual netlists)
│ ├── models_regression.py (Regression script for device)
├── mimcap_c
│ ├── device_netlists (Template Netlists)
│ └── models_regression.py (Regression script for device)
│ ├── <dev>_... (Output folder after runing with run logs and actual netlists)
├── moscap_c
│ ├── device_netlists (Template Netlists)
│ └── models_regression.py (Regression script for device)
│ ├── <dev>_... (Output folder after runing with run logs and actual netlists)
├── mos_cv
│ ├── device_netlists (Template Netlists)
│ └── models_regression.py (Regression script for device)
│ ├── <dev>_... (Output folder after runing with run logs and actual netlists)
├── mos_iv_vbs
│ ├── device_netlists (Template Netlists)
│ └── models_regression.py (Regression script for device)
│ ├── <dev>_... (Output folder after runing with run logs and actual netlists)
├── mos_iv_vgs
│ ├── device_netlists (Template Netlists)
│ └── models_regression.py (Regression script for device)
│ ├── <dev>_... (Output folder after runing with run logs and actual netlists)
├── resistor_r
│ ├── device_netlists (Template Netlists)
│ └── models_regression.py (Regression script for device)
│ ├── <dev>_... (Output folder after runing with run logs and actual netlists)
└── run_log.log (Summary of all runs for all devices)
```

1. A final report file of all results.
2. measured folder that contains measured data used in regression.
3. simulated folder that contains simulated data used in regression.
4. netlists folder that contains spice files used in simulation.
It's important to check the `run_log.log` to see the error per device.
Loading