diff --git a/Makefile b/Makefile index 3d0ea90..06a7cf4 100644 --- a/Makefile +++ b/Makefile @@ -15,6 +15,14 @@ pdf: $(TEXFILE) $(TEX) -shell-escape $< $(TEX) -shell-escape $< +watch: + $(info ************ WATCHING FOR CHANGES ************) + watchman watch $(shell pwd) + watchman -- trigger $(shell pwd) pyfiles 'figures/*.py' -- ls -l +unwatch: + $(info ************ CANCELLING WATCH ************) + watchman watch-del "$(shell pwd)" + clean: rm -f \ $(TEXFILE:.tex=.pdf) \ diff --git a/figures/cpu_matvec.pdf b/figures/cpu_matvec.pdf index 2cd1276..ece220f 100644 Binary files a/figures/cpu_matvec.pdf and b/figures/cpu_matvec.pdf differ diff --git a/figures/cpu_matvec.png b/figures/cpu_matvec.png index 8bdfeb8..7ba64cf 100644 Binary files a/figures/cpu_matvec.png and b/figures/cpu_matvec.png differ diff --git a/figures/kernels.pdf b/figures/kernels.pdf index 2ee3d86..5ea5e87 100644 Binary files a/figures/kernels.pdf and b/figures/kernels.pdf differ diff --git a/figures/kernels.png b/figures/kernels.png index 3178b7b..96e2f94 100644 Binary files a/figures/kernels.png and b/figures/kernels.png differ diff --git a/figures/mlfmm_bw.pdf b/figures/mlfmm_bw.pdf index bab88f6..3ba9300 100644 Binary files a/figures/mlfmm_bw.pdf and b/figures/mlfmm_bw.pdf differ diff --git a/figures/mlfmm_minsky.pdf b/figures/mlfmm_minsky.pdf index f87a2ca..229004b 100644 Binary files a/figures/mlfmm_minsky.pdf and b/figures/mlfmm_minsky.pdf differ diff --git a/figures/plots.py b/figures/plots.py index f384805..5519558 100644 --- a/figures/plots.py +++ b/figures/plots.py @@ -8,7 +8,7 @@ DPI=600 def autolabel(ax, rect): """ - Attach a text label above each bar displaying its height + Attach a text label above each bar displaying its height """ height = rect.get_height() ax.text(rect.get_x() + rect.get_width()/2., 1.05*height, @@ -17,24 +17,60 @@ def autolabel(ax, rect): path = 'figures/cpu_matvec' fig, ax = plt.subplots() -systems = ('BW (32T)', "Minsky (160T)") +systems = ('BW (32T)', "S822LC (160T)") mlfmm = (8.65e4, 4.84e4) total = (1.2e5, 5.77e4) x_pos = np.arange(len(systems)) -ax.bar(x_pos, mlfmm, color='darkgray', label='MLFMM') -ax.bar(x_pos, [i-j for i,j in zip(total, mlfmm)], color='lightgray', bottom=mlfmm, label='Other Operations') +ax.bar(x_pos, mlfmm, color='0.4', label='MLFMM') +ax.bar(x_pos, [i-j for i,j in zip(total, mlfmm)], color='0.8', bottom=mlfmm, label='Non-MLFMM') ax.set_xticks(x_pos) ax.set_xticklabels(systems) ax.set_ylabel("Execution Time (ms)") handles, labels = ax.get_legend_handles_labels() ax.legend(handles, labels) +sns.despine() plt.savefig(path+'.pdf') plt.savefig(path+'.png', dpi=DPI) print path +path = 'figures/kernels' +fig, ax = plt.subplots() +systems = ['BW 32T', "S822LC 160T", "BW 4 GPU" ,"S822LC 4 GPU"] +x_pos = np.arange(len(systems)) +p2m = (127.10, 72.10749, 7.73, 1.604) +m2m = (156.2506, 102.61091, 9.613814, 1.746476) +m2l = (189.615, 82.67791, 18.177774, 2.671025) +l2l = (91.5957, 101.56461, 20.215436, 2.611185) +l2p = (196.2115, 68.38529, 6.994, 1.395) +p2p = (1117.368, 590.4818, 90.619, 18.265) +total = [sum(i) for i in zip(p2m,m2m,m2l,l2l,l2p,p2p)] +p2m_ratio = [i/j for i,j in zip(p2m, total)] +m2m_ratio = [i/j for i,j in zip(m2m, total)] +m2l_ratio = [i/j for i,j in zip(m2l, total)] +l2l_ratio = [i/j for i,j in zip(l2l, total)] +l2p_ratio = [i/j for i,j in zip(l2p, total)] +p2p_ratio = [i/j for i,j in zip(p2p, total)] +ax.bar(x_pos, p2p_ratio, color='0', label='p2p') +ax.bar(x_pos, l2p_ratio, color='0.1', label='l2p', bottom=p2p_ratio) +ax.bar(x_pos, l2l_ratio, color='0.25', label='l2l', bottom=[sum(i) for i in zip(l2p_ratio,p2p_ratio)]) +ax.bar(x_pos, m2l_ratio, color='0.40', label='m2l', bottom=[sum(i) for i in zip(l2l_ratio, l2p_ratio,p2p_ratio)]) +ax.bar(x_pos, m2m_ratio, color='0.55', label='m2m', bottom=[sum(i) for i in zip(m2l_ratio, l2l_ratio, l2p_ratio,p2p_ratio)]) +ax.bar(x_pos, p2m_ratio, color='0.8', label='p2m', bottom=[sum(i) for i in zip(m2m_ratio, m2l_ratio, l2l_ratio, l2p_ratio,p2p_ratio)]) +ax.set_xticks(x_pos) +ax.set_xticklabels(systems) +ax.set_ylabel("MLFMM Kernel Breakdown") +handles, labels = ax.get_legend_handles_labels() +ax.legend(handles, labels) +# plt.ylim([1, 1e4]) +# ax.set_title('How fast do you want to go today?') +sns.despine() +plt.savefig(path+'.pdf') +plt.savefig(path+'.png', dpi=DPI) +print path + path='figures/mlfmm_bw' width=0.33 fig, ax = plt.subplots() @@ -95,39 +131,5 @@ print path -fig, ax = plt.subplots() -systems = ['BW 32T', "Minsky 160T", "BW 4 GPU" ,"Minsky 4 GPU"] -p2m = (127.10, 72.10749, 7.73, 1.604) -m2m = (156.2506, 102.61091, 9.613814, 1.746476) -m2l = (189.615, 82.67791, 18.177774, 2.671025) -l2l = (91.5957, 101.56461, 20.215436, 2.611185) -l2p = (196.2115, 68.38529, 6.994, 1.395) -p2p = (1117.368, 590.4818, 90.619, 18.265) -total = [sum(i) for i in zip(p2m,m2m,m2l,l2l,l2p,p2p)] -p2m_ratio = [i/j for i,j in zip(p2m, total)] -m2m_ratio = [i/j for i,j in zip(m2m, total)] -m2l_ratio = [i/j for i,j in zip(m2l, total)] -l2l_ratio = [i/j for i,j in zip(l2l, total)] -l2p_ratio = [i/j for i,j in zip(l2p, total)] -p2p_ratio = [i/j for i,j in zip(p2p, total)] - -path = 'figures/kernels' -x_pos = np.arange(len(systems)) -ax.bar(x_pos, p2p_ratio, color='0', label='p2p') -ax.bar(x_pos, l2p_ratio, color='0.15', label='l2p', bottom=p2p_ratio) -ax.bar(x_pos, l2l_ratio, color='0.3', label='l2l', bottom=[sum(i) for i in zip(l2p_ratio,p2p_ratio)]) -ax.bar(x_pos, m2l_ratio, color='0.45', label='m2l', bottom=[sum(i) for i in zip(l2l_ratio, l2p_ratio,p2p_ratio)]) -ax.bar(x_pos, m2m_ratio, color='0.6', label='m2m', bottom=[sum(i) for i in zip(m2l_ratio, l2l_ratio, l2p_ratio,p2p_ratio)]) -ax.bar(x_pos, p2m_ratio, color='0.75', label='p2m', bottom=[sum(i) for i in zip(m2m_ratio, m2l_ratio, l2l_ratio, l2p_ratio,p2p_ratio)]) -ax.set_xticks(x_pos) -ax.set_xticklabels(systems) -ax.set_ylabel("MLFMM Kernel Breakdown") -handles, labels = ax.get_legend_handles_labels() -ax.legend(handles, labels) -# plt.ylim([1, 1e4]) -# ax.set_title('How fast do you want to go today?') -plt.savefig(path+'.pdf') -plt.savefig(path+'.png', dpi=DPI) -print path \ No newline at end of file