# Reporting Scripts This directory contains just one utility script at present that is used in reporting/QA. ## Latency vs Throughput Plotting [`latency_throughput.py`](./latency_throughput.py) is a Python script that uses [matplotlib] to plot a graph of transaction latency vs throughput rate based on the CSV output generated by the [loadtime reporting tool](../../../test/loadtime/cmd/report/). ### Setup Execute the following within this directory (the same directory as the `latency_throughput.py` file). ```bash # Create a virtual environment into which to install your dependencies python3 -m venv .venv # Activate the virtual environment source .venv/bin/activate # Install dependencies listed in requirements.txt pip install -r requirements.txt # Show usage instructions and parameters ./latency_throughput.py --help ``` ### Running ```bash # Do the following while ensuring that the virtual environment is activated (see # the Setup steps). # # This will generate a plot in a PNG file called 'tm034.png' in the current # directory based on the reporting tool CSV output in the "raw.csv" file. The # '-t' flag overrides the default title at the top of the plot. ./latency_throughput.py \ -t 'Tendermint v0.34.x Latency vs Throughput' \ ./tm034.png \ /path/to/csv/files/raw.csv ``` [matplotlib]: https://matplotlib.org/