Skip to content

Commit

Permalink
Adding documentation for global command line options
Browse files Browse the repository at this point in the history
Signed-off-by: coleramos425 <[email protected]>
  • Loading branch information
coleramos425 committed Apr 1, 2024
1 parent 281a307 commit ee4173a
Show file tree
Hide file tree
Showing 3 changed files with 33 additions and 13 deletions.
4 changes: 2 additions & 2 deletions src/argparser.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,12 +48,12 @@ def add_general_group(parser, omniperf_version):
default=0,
)
general_group.add_argument(
"-q", "--quiet", action="store_true", help="Run in quiet mode."
"-q", "--quiet", action="store_true", help="Reduce output and run quietly."
)
# Nowhere to load specs from in db mode
if "database" not in parser.usage:
general_group.add_argument(
"-s", "--specs", action="store_true", help="Print system specs."
"-s", "--specs", action="store_true", help="Print system specs and exit."
)


Expand Down
30 changes: 22 additions & 8 deletions src/docs-2.x/getting_started.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,14 +85,28 @@ Modes change the fundamental behavior of the Omniperf command line tool. Dependi
```shell
$ omniperf database --help
```
### Global Options
The Omniperf command line tool has a set of 'global' options that are available across all modes.
| Argument | Description |
| :----------------- | :---------------------------------------------------------------- |
| `-v` / `--version` | Print Omniperf version and exit. |
| `-V` / `--verbose` | Increase output verbosity (use multiple times for higher levels). |
| `-q` / `--quiet` | Reduce output and run quietly. |
| `-s` / `--specs` | Print system specs and exit. |
```{note}
Omniperf also recognizes the project variable, `OMNIPERF_COLOR`, should the user choose to disable colorful output. To disable default colorful behavior, set this variable to `0`.
```
## Basic Operations
Operation | Mode | Required Arguments
:--|:--|:--
Profile a workload | profile | `--name`, `-- <profile_cmd>`
Standalone roofline analysis | profile | `--name`, `--roof-only`, `-- <profile_cmd>`
Import a workload to database | database | `--import`, `--host`, `--username`, `--workload`, `--team`
Remove a workload from database | database | `--remove`, `--host`, `--username`, `--workload`, `--team`
Launch standalone GUI from CLI | analyze | `--path`, `--gui`
Interact with profiling results from CLI | analyze | `--path`
| Operation | Mode | Required Arguments |
| :--------------------------------------- | :------- | :--------------------------------------------------------- |
| Profile a workload | profile | `--name`, `-- <profile_cmd>` |
| Standalone roofline analysis | profile | `--name`, `--roof-only`, `-- <profile_cmd>` |
| Import a workload to database | database | `--import`, `--host`, `--username`, `--workload`, `--team` |
| Remove a workload from database | database | `--remove`, `--host`, `--username`, `--workload`, `--team` |
| Launch standalone GUI from CLI | analyze | `--path`, `--gui` |
| Interact with profiling results from CLI | analyze | `--path` |
12 changes: 9 additions & 3 deletions src/docs-2.x/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,14 @@ In addition, Omniperf leverages a number of Python packages that are
documented in the top-level `requirements.txt` file. These must be
installed prior to Omniperf configuration.

```{note}
If you're interested in building docs locally or running Omniperf's CI suite via PyTest, please see documented dependencies in `requirements-doc.txt` and `requirements-test.txt`, respectively.
```{admonition} Optional packages
If you would like to build Omniperf as a developer, consider these additional requirements:
| Requirement file | Description |
| --------------------- | -------------------------------------------------------------- |
| requirements-doc.txt | Python packages required to build docs from source |
| requirements-test.txt | Python packages required to run Omniperf's CI suite via PyTest |
```

The recommended procedure for Omniperf usage is to install into a shared file system so that multiple users can access the final installation. The following steps illustrate how to install the necessary python dependencies using [pip](https://packaging.python.org/en/latest/) and Omniperf into a shared location controlled by the `INSTALL_DIR` environment variable.
Expand Down Expand Up @@ -159,7 +165,7 @@ wishes to use instead.
## Server-side Setup

```{note}
Server-side setup is not required to profile or analyze performance data from the CLI. It is provided as an additional mechanism to import performance data for examination within a detailed [Grafana](https://github.com/grafana/grafana) GUI.
Server-side setup is **not required** to profile or analyze performance data from the CLI. It is provided as an additional mechanism to import performance data for examination within a detailed [Grafana](https://github.com/grafana/grafana) GUI.
```

Omniperf server-side requires the following basic software dependencies prior to usage:
Expand Down

0 comments on commit ee4173a

Please sign in to comment.