Skip to content
Snippets Groups Projects

Add acoustics monitoring

Merged Carlo Guidi requested to merge cguidi/km3mon:undefined into master
1 unresolved thread
Compare and Show latest version
1 file
+ 8
16
Compare changes
  • Side-by-side
  • Inline
+ 8
16
@@ -16,13 +16,12 @@ Options:
"""
import numpy as np
import matplotlib.pyplot as plt
import argparse
import time
import os
import matplotlib
from matplotlib import colors
from datetime import datetime
from docopt import docopt
import km3pipe as kp
@@ -31,19 +30,12 @@ def diff(first, second):
return [item for item in first if item not in second]
parser = argparse.ArgumentParser(description = 'Online_monitoring')
parser.add_argument('-d', dest = 'det_id', type = str, nargs = 1, required = True,
help = 'The detector ID (e.g. D_ORCA005)')
parser.add_argument('-ndu', dest = 'n_dus', type = int, nargs = 1, required = True,
help = 'Number of DUs (e.g. 5)')
parser.add_argument('-o', dest = 'plot_dir', type = str, nargs = 1, required = True,
help = 'Directory in which the plot is saved')
args = parser.parse_args()
detid = args.det_id[0]
directory = args.plot_dir[0]
N_DUS = args.n_dus[0]
args = docopt(__doc__)
detid = args['-d']
directory = args['-o']
N_DUS = args['-n']
N_DUS = int(N_DUS)
db = kp.db.DBManager()
sds = kp.db.StreamDS()
@@ -230,8 +222,8 @@ while check:
print(time.time())
check = False
check_time=time.time() - now
check_time = time.time() - now
print(check_time)
time.sleep(abs(TIT - check_time))
check = True
check = True
Loading