def gen_pdf_c(path, l, f, nr, list_cases): mpl.rcParams = get_rcParams() filter_dict = {'lang': [l], 'format' : [f], 'NR' : [nr], 'Q' : [0.4]} list_sub_cases = ['GR', 'GC', 'LGR', 'LGC', 'BGR', 'BGC', 'CPT'] COI = 'nodes' con = sqlite3.connect(OUTPUT_DB) m, coi_set = dr.matrix_relation(con, filter_dict, list_cases, list_sub_cases, COI, VOI, 'auto', [STAT]) coi_set = sorted(coi_set, key=float) fig = plot.plot_axis(m, coi_set, STAT, 'Nodes (Cores)', 'Time (s)', list_cases, False) plot.plot_axis_add_cores_to_node_count(fig, coi_set, NCPN) output_file_base = path + f'fig_pangea2_c_nr{nr}_l'+ l + '_f' + f plot.save(fig, output_file_base + '.pdf') table.table(m, output_file_base + '.tex', list_cases) print(output_file_base + '.pdf') con.close()
def gen_pdf_ws(path, l, f, nr, list_cases, nodes, ylabel, yscale): mpl.rcParams = get_rcParams() filter_dict = {'lang': [l], 'format' : [f], 'C' : [300], 'nodes' : nodes} list_sub_cases = ['GR', 'GC', 'LGR', 'LGC', 'BGR', 'BGC', 'CPT'] COI = 'nodes' con = sqlite3.connect(OUTPUT_DB) m, coi_set = dr.matrix_relation(con, filter_dict, list_cases, list_sub_cases, COI, VOI, 'auto', [STAT], [f'nodes,NR,{nr}']) coi_set = sorted(coi_set, key=float) fig = plot.plot_axis(m, coi_set, STAT, 'Nodes (Cores)', ylabel, list_cases, False, yscale = yscale) #fig = plot.plot_ratios_axis(m, coi_set, STAT, 'Nodes (Cores)', 'Weak Scaling Efficiency', list_cases, False) #fig = plot.plot_ratios2_axis(m, coi_set, STAT, 'Nodes (Cores)', 'Ratio Tn/T1', list_cases, False) plot.plot_axis_add_cores_to_node_count(fig, coi_set, NCPN) output_file_base = path + f'fig_pangea2_ws_nr{nr}_l'+ l + '_f' + f plot.save(fig, output_file_base + '.pdf') table.table(m, output_file_base + '.tex', list_cases) print(output_file_base + '.pdf') con.close()
def gen_pdf_ss(lang, modifier, nx, ny): mpl.rcParams = get_rcParams() filter_dict = {'lang': lang, 'nx': [nx], 'ny': [ny]} list_cases = ['lang'] list_sub_cases = [] COI = 'nodes' con = sqlite3.connect(OUTPUT_DB) m, coi_set = dr.matrix_relation(con, filter_dict, list_cases, list_sub_cases, COI, VOI, 'auto', [STAT]) coi_set = sorted(coi_set, key=float) fig = plot.plot_axis(m, coi_set, STAT, 'Nodes (Cores)', 'Time (s)', list_cases, False) plot.plot_axis_add_cores_to_node_count(fig, coi_set, NCPN) output_file_base = PATH_PREFIX + f'fig_pangea2_ss{modifier}_nx{nx}_ny{ny}' plot.save(fig, output_file_base + '.pdf') table.table(m, output_file_base + '.tex', list_cases) con.close()