Usage ===== .. note:: You have the option to execute the SG13G2-DRC through either a Python script via the command-line interface (CLI) or by the Klayout graphical user interface (GUI), as detailed in the subsequent usage sections. .. _CLI Usage: CLI --- The `run_drc.py` script takes your gds to run DRC rule decks with switches to select subsets of all checks. .. code-block:: bash run_drc.py (--help | -h) run_drc.py --path= [--table=]... [--mp=] [--run_dir=] [--topcell=] [--run_mode=] [--drc_json=] [--disable_extra_rules] [--no_feol] [--no_beol] [--no_density] [--density_thr=] [--density_only] [--antenna] [--antenna_only] [--no_offgrid] [--macro_gen] **Options:** .. code-block:: rst `-h, --help` show this help message and exit `--path PATH` Path to the input GDS file to be processed. `--table TABLE` DRC table name(s) to execute (e.g., activ, metal1). This option can be used multiple times. `--mp MP` Number of parts to split the rule deck for parallel execution. [default: 1] `--run_dir RUN_DIR` Dir to store all run results. If not specified, a timestamped dir under the current path will be used. `--topcell TOPCELL` Top-level cell name to use from the input GDS. `--density_thr DENSITY_THR` Number of threads to use during the density run (default: number of CPU cores). `--run_mode {deep,flat}` KLayout execution mode: deep, or flat. [default: deep] `--drc_json DRC_JSON` Path to a JSON file that defines rule values to use. `--no_feol` Disable all FEOL-related DRC checks. `--no_beol` Disable all BEOL-related DRC checks. `--disable_extra_rules` Distable the remaining DRC rules from the full rule set (may be slower). `--no_density` Disable density rule checks. `--density_only` Run only density rules. `--antenna` Enable antenna rule checks. `--antenna_only` Run only antenna rules. `--no_offgrid` Disable offgrid rule checks. `--macro_gen` Only generate the DRC rule deck without running. .. note:: By default, the **main DRC rule set** will be executed, which includes **density rules**. To disable density checks, use the ``--no_density`` switch. .. tip:: If the ``--drc_json=`` option is not provided, the script will get rule values as following: - 1. Attempt to load the **SG13G2 technology JSON file**: `SG13G2 tech JSON `_ file. - 2. Fall back to **default DRC values**: `default tech DRC values `_ file. **Example:** .. code-block:: bash python3 run_drc.py --path=testing/testcases/unit/activ.gds --run_mode=deep --run_dir=test_activ --no_density **DRC Outputs** You could find the run results at your run directory if you previously specified it through `--run_dir=`. Default path of run directory is `drc_run__