import sys from read_log import read_file from analysis import compare if __name__ == '__main__': if len(sys.argv) == 3: hand_g = read_file(sys.argv[1]) auto_g = read_file(sys.argv[2]) compare(auto_g, hand_g) else: print('Please pass two paths to comparing log files of process simulation')
def plot_yolo_cifar_mnst_cnn(): keys = sorted(inferences.keys()) print keys yolo = [inferences[x]['YOLO'] for x in keys] mnist = [inferences[x]['MNIST'] for x in keys] cifar = [inferences[x]['CIFAR10'] for x in keys] ind = np.arange(len(yolo)) width = 0.27 plt.bar(ind - width, yolo, width, label='Yolo') plt.bar(ind, cifar, width, label='Cifar10') plt.bar(ind + width, mnist, width, label='Mnist') plt.ylabel('Inferences') plt.xticks(ind, keys) # plt.legend(bbox_to_anchor=(1, 1), loc='5') plt.legend(loc='lower right') plt.show() if __name__ == "__main__": data = read_log.read_file(sys.argv[1]) inferences = start(data) plot_yolo_cifar_mnst_cnn()