ATLAS Offline Software
base_data.py
Go to the documentation of this file.
1 # Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
2 
3 
4 from __future__ import print_function
5 
6 from DataQualityUtils.DQWebDisplayConfig import DQWebDisplayConfig
7 import os
8 from ._resolve_data_path import resolve_data_path
9 
10 hcfg_dir = resolve_data_path('DataQualityConfigurations')
11 if hcfg_dir:
12  print ("Found DataQualityConfigurations data directory %s, using it" % hcfg_dir)
13 else:
14  hcfg_dir = os.getcwd()
15  print ("DataQualityConfigurations data directory not found, attempting to use $PWD instead.")
16 print ("Looking for collisions_*.hcfg files in %s" % (hcfg_dir))
17 
18 isprod = os.environ.get('DQPRODUCTION') == '1'
19 
20 dqconfig = DQWebDisplayConfig()
21 dqconfig.config = "Collisions Data"
22 dqconfig.hcfg = os.environ.get('DQC_HCFG_COLLISIONS_RUN', "%s/collisions_run.hcfg" % hcfg_dir)
23 dqconfig.hcfg_min10 = os.environ.get('DQC_HCFG_COLLISIONS_MINUTES10', "%s/collisions_minutes10.hcfg" % hcfg_dir)
24 dqconfig.hcfg_min30 = os.environ.get('DQC_HCFG_COLLISIONS_MINUTES30', "%s/collisions_minutes30.hcfg" % hcfg_dir)
25 serverstring = os.environ.get('DQC_SERVERS', "aiatlas016.cern.ch,aiatlas011.cern.ch")
26 if serverstring == '':
27  dqconfig.server = []
28 else:
29  dqconfig.server = serverstring.split(',') if isprod else []
30 dqconfig.eosResultsDir = "root://eosatlas.cern.ch//eos/atlas/atlascerngroupdisk/data-dqm/han_results/tier0/collisions/" if isprod else ""
31 dqconfig.histogramCache = "/afs/cern.ch/user/a/atlasdqm/w1/histogram_web_display_cache" if isprod else ''
32 dqconfig.hanResultsDir = "/dqmdisk0/han_results/tier0/collisions" if isprod else '/afs/cern.ch/user/a/atlasdqm/dqmdisk/han_results/test'
33 dqconfig.doHandi = False
34 dqconfig.htmlDir = "/dqmdisk0/www/tier0/collisions" if isprod else '/afs/cern.ch/user/a/atlasdqm/dqmdisk/www/test'
35 dqconfig.htmlWeb = "http://atlasdqm.cern.ch/tier0/collisions"
36 dqconfig.runlist = "runlist_collisions.xml"
37 dqconfig.indexFile = "results_collisions.html"
38 dqconfig.lockFile = "DQWebDisplay_collisions.lock"
39 dqconfig.webHandoffDir = '/afs/cern.ch/user/a/atlasdqm/maxidisk/webHandoff' if isprod else ''
40 
41 dqconfig.filemap = { 'RPCDQMFOFFLINE.db': '/afs/cern.ch/user/m/muoncali/w0/RPC/DQAresults',
42  'RPCConditionDB.db': '/afs/cern.ch/user/m/muoncali/w0/RPC/DQAresults',
43  'MDTDQMFOFFLINE_DEAD.db': '/afs/cern.ch/user/m/muoncali/w0/RPC/DQAresults',
44  'MDTDQMFOFFLINE_NOISY.db': '/afs/cern.ch/user/m/muoncali/w0/RPC/DQAresults',
45  'zrate.csv': 'root://eosatlas.cern.ch//eos/atlas/atlascerngroupdisk/data-dqm/zlumi',
46  'zlumi.root': 'root://eosatlas.cern.ch//eos/atlas/atlascerngroupdisk/data-dqm/zlumi',
47  'zlumi.csv': 'root://eosatlas.cern.ch//eos/atlas/atlascerngroupdisk/data-dqm/zlumi',
48  }
49 
50 dqconfig.dbConnection = "oracle://ATLAS_COOLPROD;schema=ATLAS_COOLOFL_GLOBAL;dbname=CONDBR2;"
51 dqconfig.dqmfOfl = "/GLOBAL/DETSTATUS/DQMFOFL"
52 dqconfig.dbTagName = "DetStatusDQMFOFL-%(stream)s-pass1"
53 dqconfig.dbTagNameESn = "DetStatusDQMFOFL-%(stream)s-ES%(procpass)s"
54 dqconfig.shiftOfl = "/GLOBAL/DETSTATUS/SHIFTOFL"
55 
56 #authentication file at Tier0 (uncomment this option at Tier0 only)
57 dqconfig.auth = "/afs/cern.ch/atlas/project/tzero/var"
python._resolve_data_path.resolve_data_path
def resolve_data_path(fin)
Definition: DataQualityConfigurations/python/_resolve_data_path.py:6