louwrentius / fio-plot

Create charts from FIO storage benchmark tool output
BSD 3-Clause "New" or "Revised" License
370 stars 87 forks source link

fio_plot: ZeroDivisionError: division by zero #27

Closed jodykpw closed 4 years ago

jodykpw commented 4 years ago

./bench_fio -d /data -t directory -s 1g --mode randread -o /data/benchmarks --iodepth 1 2 4 8 16 32 64 --numjobs 1 --block-size 16k

./fio_plot/fio_plot -i /data/benchmarks/data/16k -T "Apple SSD AP0256M BLOCK_SIZE 16K On Vagrant" -s https://louwrentius.com -l -n 1 -r randread

Traceback (most recent call last): File "/app/fio_plot/fio_plot", line 151, in main() File "/app/fio_plot/fio_plot", line 139, in main uses_json_files[item](settings, parsed_data) File "/app/fio_plot/fiolib/bar2d.py", line 14, in chart_2dbarchart_jsonlogdata data = shared.get_record_set(settings, dataset, dataset_types, File "/app/fio_plot/fiolib/shared_chart.py", line 99, in get_record_set lat_stddev_percent = supporting.raw_stddev_to_percent( File "/app/fio_plot/fiolib/supporting.py", line 222, in raw_stddev_to_percent percent = round((int(y) / int(x)) * 100, 0) ZeroDivisionError: division by zero

louwrentius commented 4 years ago

Can you share the benchmark data in a compressed file?

louwrentius commented 4 years ago

I have committed a possible fix to the master branch. Can you verify the issue is solved?

jodykpw commented 4 years ago

Sorry, I don't have those benchmark data anymore, just tried again is fine now.

louwrentius commented 4 years ago

Thanks for the feedback.