github.com/Oyster-zx/tendermint@v0.34.24-fork/scripts/qa/reporting/README.md (about) 1 # Reporting Scripts 2 3 This directory contains just one utility script at present that is used in 4 reporting/QA. 5 6 ## Latency vs Throughput Plotting 7 8 [`latency_throughput.py`](./latency_throughput.py) is a Python script that uses 9 [matplotlib] to plot a graph of transaction latency vs throughput rate based on 10 the CSV output generated by the [loadtime reporting 11 tool](../../../test/loadtime/cmd/report/). 12 13 ### Setup 14 15 Execute the following within this directory (the same directory as the 16 `latency_throughput.py` file). 17 18 ```bash 19 # Create a virtual environment into which to install your dependencies 20 python3 -m venv .venv 21 22 # Activate the virtual environment 23 source .venv/bin/activate 24 25 # Install dependencies listed in requirements.txt 26 pip install -r requirements.txt 27 28 # Show usage instructions and parameters 29 ./latency_throughput.py --help 30 ``` 31 32 ### Running 33 34 ```bash 35 # Do the following while ensuring that the virtual environment is activated (see 36 # the Setup steps). 37 # 38 # This will generate a plot in a PNG file called 'tm034.png' in the current 39 # directory based on the reporting tool CSV output in the "raw.csv" file. The 40 # '-t' flag overrides the default title at the top of the plot. 41 42 ./latency_throughput.py \ 43 -t 'Tendermint v0.34.x Latency vs Throughput' \ 44 ./tm034.png \ 45 /path/to/csv/files/raw.csv 46 ``` 47 48 [matplotlib]: https://matplotlib.org/