args = parser.parse_args() job_ids=args.jobids data_file_name = args.file con = mdb.connect(server, user, password, table); with con: cur = con.cursor() plot_xlabel = "benchmarks solved" plot_ylabel = "cummulative time" gnuplot_command = cStringIO.StringIO() data_file = open(data_file_name, 'w') util.setupPlot(gnuplot_command, plot_xlabel, plot_ylabel, "") util.setupCanvasPlot(gnuplot_command, "gnuplot_canvas") util.setupCactusPlot(gnuplot_command) util.startPlot(gnuplot_command) for i in range(len(job_ids)) : job_id = job_ids[i] result_i = util.getSortedResults(cur, job_id) util.dumpCactusToFile(data_file, util.getJobName(cur, job_id), result_i) for i in range(len(job_ids)) : util.plotOneCactus(gnuplot_command, data_file_name, i, 1, 2) if ( i < len(job_ids) - 1) : util.plotSeparator(gnuplot_command)
with con: cur = con.cursor() plot_xlabel = "benchmarks solved" plot_ylabel = "cummulative time" base_name = path + generateCactusBaseName(job_ids) gnuplot_file_name = base_name + ".gnuplot" gnuplot_file = open(gnuplot_file_name, 'w') data_file_name = base_name + ".dat" data_file = open(data_file_name, 'w') pdf_file_name = base_name + ".pdf" util.setupPlot(gnuplot_file, plot_xlabel, plot_ylabel, "") util.setupPdfPlot(gnuplot_file, pdf_file_name) util.setupCactusPlot(gnuplot_file) util.startPlot(gnuplot_file) for i in range(len(job_ids)) : job_id = job_ids[i] result_i = util.getSortedResults(cur, job_id) util.dumpCactusToFile(data_file, util.getJobName(cur, job_id), result_i) for i in range(len(job_ids)) : util.plotOneCactus(gnuplot_file, data_file_name, i, 1, 2) if ( i < len(job_ids) - 1) : util.plotSeparator(gnuplot_file)
filtered_results.append((path, xvalue, yvalue)) return filtered_results con = mdb.connect(server, user, password, database); with con: cur = con.cursor() plot_xlabel = util.getJobName(cur, xjob) + " ("+ str(xjob) + ")" plot_ylabel = util.getJobName(cur, yjob) + " ("+ str(yjob) + ")" plot_title = plot_xlabel + " vs " + plot_ylabel data_file = open(data_file_name, 'w') javascript_file = open(javascript_file_name, 'w') gnuplot_command = cStringIO.StringIO() util.setupPlot(gnuplot_command, plot_xlabel, plot_ylabel, plot_title) util.setupCanvasPlot(gnuplot_command, "gnuplot_canvas") util.startPlot(gnuplot_command) results_and_answers = util.getRunTimesAndAnswer(cur, xjob, yjob) results = filterUnknowns(results_and_answers) families = util.groupByFamilies(results) if input_family == None or input_family == "": run_over_families = families else: if input_family[0] == '-': input_family = input_family[1:] exclude_families = input_family.split(',') run_over_families = [item for item in families if item not in exclude_families] else:
plot_xlabel = util.getJobName(cur, xjob) plot_ylabel = util.getJobName(cur, yjob) plot_title = plot_xlabel + " vs " + plot_ylabel base_name = path + generateScatterBaseName(xjob, yjob, xfield, yfield) gnuplot_file_name = base_name + ".gnuplot" gnuplot_file = open(gnuplot_file_name, 'w') data_file_name = base_name + ".dat" data_file = open(data_file_name, 'w') pdf_file_name = base_name + ".pdf" util.setupPlot(gnuplot_file, plot_xlabel, plot_ylabel, plot_title) util.setupPdfPlot(gnuplot_file, pdf_file_name) util.startPlot(gnuplot_file) results = util.selectAllResult(cur, xjob, yjob, xfield, yfield) families = util.groupByFamilies(results) for family in families: family_results = families[family] util.dumpFamilyToFile(data_file, family, family_results) for i in range(len(families)): util.plotOneScatter(gnuplot_file, data_file_name, i, 2, 3) util.plotSeparator(gnuplot_file)