Command lines#

  1. Converts a profile stored by nvprof into json

  2. check

Converts a profile stored by nvprof into json

The sqlite dump is generated with a command line similar to:

nvprof -o gpu_profile.sql python plot_gpu_training.py

The command produces a json file following the Trace Event Format.

<<<

python -m onnxcustom nvprof2json --help

>>>

usage: nvprof2json [-h] [-f FILENAME] [-o OUTPUT] [-t TEMPORARY_FILE]
                   [-v VERBOSE]

Converts traces produced by `nvprof` and saved with format `sqlite3`
(extension `.sql`).

optional arguments:
  -h, --help            show this help message and exit
  -f FILENAME, --filename FILENAME
                        filename (default: None)
  -o OUTPUT, --output OUTPUT
                        output file, if left empty, the result is printed on
                        the standard output (default: )
  -t TEMPORARY_FILE, --temporary_file TEMPORARY_FILE
                        if the file needs to be unzipped, this file will be
                        created to be the unzipped file, it is not cleaned
                        after the unzipping. (default: )
  -v VERBOSE, --verbose VERBOSE
                        verbosity (default: 1)

(original entry : profiling.py:docstring of onnxcustom.cli.profiling.nvprof2json, line 14)

check

Checks the module works as expected.

<<<

python -m onnxcustom check --help

>>>

usage: check [-h] [-v VERBOSE]

Runs a couple of functions to check the module is working.

optional arguments:
  -h, --help            show this help message and exit
  -v VERBOSE, --verbose VERBOSE
                        0 to hide the standout output (default: 1)

(original entry : doc.rst, line 24)