Skip to content
Snippets Groups Projects
Commit b75849f8 authored by Tamas Gal's avatar Tamas Gal :speech_balloon:
Browse files

Save extra ztplot with more than 4 unique DOMs

parent eaef8945
No related branches found
No related tags found
No related merge requests found
......@@ -120,6 +120,7 @@ class ZTPlot(Module):
def create_plot(self, event_info, hits):
print(self.__class__.__name__ + ": updating plot.")
dus = set(hits.du)
doms = set(hits.dom_id)
fontsize = 16
time_offset = np.min(hits[hits.triggered == True].time)
......@@ -186,6 +187,8 @@ class ZTPlot(Module):
f = os.path.join(self.plots_path, filename + '.png')
f_tmp = os.path.join(self.plots_path, filename + '_tmp.png')
plt.savefig(f_tmp, dpi=120, bbox_inches="tight")
if len(doms) > 4:
plt.savefig(os.path.join(self.plots_path, filename + '_5doms.png'))
plt.close('all')
shutil.move(f_tmp, f)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment