diff --git a/train.py b/train.py index 7548e4e1..fa5dead6 100644 --- a/train.py +++ b/train.py @@ -8,7 +8,7 @@ from utils.utils import * parser = argparse.ArgumentParser() parser.add_argument('-epochs', type=int, default=100, help='number of epochs') -parser.add_argument('-batch_size', type=int, default=2, help='size of each image batch') +parser.add_argument('-batch_size', type=int, default=16, help='size of each image batch') parser.add_argument('-data_config_path', type=str, default='cfg/coco.data', help='data config file path') parser.add_argument('-cfg', type=str, default='cfg/yolov3.cfg', help='cfg file path') parser.add_argument('-multi_scale', default=False, help='random image sizes per batch 320 - 608') diff --git a/utils/utils.py b/utils/utils.py index dd261c7d..c4884f45 100755 --- a/utils/utils.py +++ b/utils/utils.py @@ -442,12 +442,13 @@ def plot_results(): import matplotlib.pyplot as plt plt.figure(figsize=(16, 8)) s = ['X', 'Y', 'Width', 'Height', 'Objectness', 'Classification', 'Total Loss', 'Precision', 'Recall', 'mAP'] - for f in ('results.txt', + for f in ('results_64.txt','results_642.txt' ): results = np.loadtxt(f, usecols=[2, 3, 4, 5, 6, 7, 8, 17, 18, 16]).T # column 16 is mAP + n = results.shape[1] for i in range(10): plt.subplot(2, 5, i + 1) - plt.plot(results[i, :250], marker='.', label=f) + plt.plot(range(1,n), results[i, 1:], marker='.', label=f) plt.title(s[i]) if i == 0: plt.legend() @@ -466,4 +467,4 @@ def plot_results(): # plt.plot(results, marker='.', label=f) # plt.title(s[i]) # if i == 0: -# plt.legend() \ No newline at end of file +# plt.legend()