fig, axes = plt.subplots(1, 3, True, True) axes[0].set_ylabel("Edge sharpness") axes[1].set_xlabel("Frames") for ax, title in zip(axes, ["unfiltered", "prefiltered", "postfiltered"]): ax.set_title(title) """ for fm, name in FILTER_MODES.items(): fig, ax = plt.subplots(1, 1) #ax = axes[fm] # current subplot axis. fm_selection = fmode == fm for fl in fluxes: fl_selection = flux[fm_selection] == fl frms_sorting = np.argsort(frms[fm_selection][fl_selection]) flux_str = mant_exp_from_int(fl)[2] ax.errorbar( frms[fm_selection][fl_selection][frms_sorting], sharpness[fm_selection][fl_selection][frms_sorting], yerr=uncertainty[fm_selection][fl_selection][frms_sorting], fmt=".-", label=flux_str, markersize=1.0 ) ax.grid(True) ax.set_ylim(ylim) ax.set_xlim(200, 1039) ax.set_xlabel("Frames") if fm == 0: ax.set_ylabel("Edge sharpness") if fm == legendfm:
) FLUXES = [5e5, 5e6, 5e7, 5e8] FRAMES = [359, 719] fig, axes = plt.subplots(1, len(FRAMES), True, True) for i, fr in enumerate(FRAMES): ax = axes[i] fr_selection = frames == fr for fl in FLUXES: fl_selection = fluxes[fr_selection] == fl tvGrad_sorting = np.argsort(tvGrads[fr_selection][fl_selection]) ax.plot( tvGrads[fr_selection][fl_selection][tvGrad_sorting], rmses[fr_selection][fl_selection][tvGrad_sorting], "o-", markersize=1, label=mant_exp_from_int(fl)[2], ) ax.set_title("{} frames".format(fr)) ax.grid(True) ax.semilogx() ax.set_xlabel("TV parameter") if i == 0: ax.set_ylabel("RMSE") ax.legend(loc="upper center", ncol=2) # plt.show() # """ save_tex( __file__, addFigureDims=True, subdir="jaw",