This commit is contained in:
Lukas Prause
2022-03-16 14:24:38 +01:00
parent e3d3c755a4
commit e65b5c77b5
2 changed files with 17 additions and 6 deletions

View File

@@ -105,7 +105,7 @@ if __name__ == "__main__":
plot_single_transmission("{}/{}".format(args.folder, csv)) plot_single_transmission("{}/{}".format(args.folder, csv))
if len(all_delays_dict) > 0: if len(all_delays_dict) > 0:
fig, axes = plt.subplots() #fig, axes = plt.subplots()
label_list = list() label_list = list()
unit = None unit = None
datas = list() datas = list()
@@ -119,9 +119,16 @@ if __name__ == "__main__":
unit = "Gbit/s" unit = "Gbit/s"
label_list.append(bitrate.replace("K", "").replace("M", "").replace("G", "")) label_list.append(bitrate.replace("K", "").replace("M", "").replace("G", ""))
datas.append(l) datas.append(l)
axes.boxplot(datas) print("Bitrate: {}, len: {}".format(bitrate, len(l)))
#print(datas[1])
print(len(datas))
plt.boxplot(datas[1])
#plt.xticks(range(1, len(label_list) + 1), label_list, rotation=-45)
#axes.set_xticklabels(label_list) #axes.set_xticklabels(label_list)
axes.set_xlabel("cbr bitrate [{}]".format(unit)) plt.xlabel("cbr bitrate [{}]".format(unit))
axes.set_ylabel("delay [s]") plt.ylabel("delay [s]")
fig.suptitle("CBR {}".format(direction)) plt.title("CBR {}".format(direction))
fig.savefig("{}/all_delays_{}_boxplot.pdf".format(args.folder, direction)) plt.show()
plt.savefig("{}/all_delays_{}_boxplot.pdf".format(args.folder, direction))

View File

@@ -1,4 +1,8 @@
#!/usr/bin/env python3 #!/usr/bin/env python3
# Master: ptpd -i {PTP Interface des Masters} -M -u {IP des Slaves}
# Slave: ptpd -i {PTP Interface des Slaves} -s -u {IP des Masters}
import json import json
import requests import requests
import os import os