diff --git a/test/prsim_plot.py b/test/prsim_plot.py index 4ca78a9..525dde8 100755 --- a/test/prsim_plot.py +++ b/test/prsim_plot.py @@ -159,7 +159,14 @@ Use -exclude='regex' to specify signals to exclude (or -ex).""") plt.arrow(t0, s1, 0, s0-s1 + 0.2*np.sign(s0-s1), head_width = 0, width = 0.2, ec = "none", lw = 0, fc = "black", length_includes_head = True) plt.scatter((t0),(s0), c = "black", s = 30) - file_out_path = file_path.replace(".out",".pdf") + + output_type = ".pdf" + for arg in argv: + if arg == "-png": output_type = ".png" + + file_out_path = file_path.replace(".out",output_type) + + plt.savefig(file_out_path, bbox_inches = "tight")