7from __future__
import print_function, division
8from factory
import APIFactory
12from builtins
import range
14from argparse
import ArgumentParser
15from array
import array
20 opts, args = getopt.getopt(sys.argv[1:],
"l:s:",[])
21except getopt.GetoptError:
23 print(
' enter -l: level or -s: subdetector')
36conditionsDB = api_factory.construct_DB_API(
"/home/eric/snd-soft-23april-2021/sndsw/conditionsDatabase/config.yml")
44 result = conditionsDB.list_detectors(detector)
47 print (
"snd subdetectors:",result)
49 print (
"subdetectors inside",detector,
" :",result)
52 for j
in range(len(result)):
55 print (
"No more subdetectors below subdetector/channel:",detector)
60result = conditionsDB.get_conditions(sd)
61print (
"Conditions of subdetector ",sd,
" are ",result)
This class creates an instance of the specified database API.
showdetectors(detector, count, level)