示例#1
0
 def generate(self, plot: pyplot, data: Any) -> None:
     # [("gcc", "ref", 184585549)]
     series: Dict[str, List[float]] = {}
     for row in data:
         label = " ".join(row[0:2])
         if label not in series:
             series[label] = []
         series[label].append(row[2])
     values = list(series.values())
     values.sort(key=lambda x: numpy.std(x), reverse=True)
     keys = list(series.keys())
     keys.sort(key=lambda x: numpy.std(series[x]), reverse=True)
     plot.boxplot(values, showfliers=False)
     plot.gcf().axes[0].yaxis.get_major_formatter().set_scientific(False)
     plot.gcf().axes[0].set_xticklabels(keys)
     plot.title("")
     plot.ylabel(self.options.event)
     plot.xlabel("Optimizations")
示例#2
0
 def generate(self, plot: pyplot, data: Any) -> None:
     # [("Modern Workstation", "gcc", "ref", 34579902)]
     series: Dict[str, List[float]] = {}
     for row in data:
         label = "{} {}".format(row[1], row[2])
         if label not in series:
             series[label] = []
         series[label].append(row[3] / 1e6)
     values = list(series.values())
     values.sort(key=lambda x: min(x), reverse=True)
     keys = list(series.keys())
     keys.sort(key=lambda x: min(series[x]), reverse=True)
     plot.boxplot(values, showfliers=False)
     plot.gcf().axes[0].yaxis.get_major_formatter().set_scientific(False)
     plot.gcf().axes[0].set_xticklabels(keys)
     plot.title("")
     plot.ylabel("Duration (ms)")
     plot.xlabel("Optimizations")