Commit d1743b33 authored by Remi Mommsen's avatar Remi Mommsen Committed by Dainius Simelevicius
Browse files

references #180: add option to use writeDelete mode

parent 2dd8353e
...@@ -137,7 +137,7 @@ class Configuration(): ...@@ -137,7 +137,7 @@ class Configuration():
class ConfigFromFile(Configuration): class ConfigFromFile(Configuration):
def __init__(self,symbolMap,configFile,fixPorts,useNuma,generateAtRU,dropAtRU,dropAtSocket,dropAtStream,dropAtBU,hlt,ferolMode,ferolsOnly,maxTriggerRate): def __init__(self,symbolMap,configFile,fixPorts,useNuma,generateAtRU,dropAtRU,dropAtSocket,dropAtStream,dropAtBU,writeDelete,hlt,ferolMode,ferolsOnly,maxTriggerRate):
self.frlPorts = [] self.frlPorts = []
self.fedId2Port = {} self.fedId2Port = {}
Configuration.__init__(self,symbolMap,useNuma) Configuration.__init__(self,symbolMap,useNuma)
...@@ -182,10 +182,11 @@ class ConfigFromFile(Configuration): ...@@ -182,10 +182,11 @@ class ConfigFromFile(Configuration):
if endpoint.attrib['port'] not in self.frlPorts: if endpoint.attrib['port'] not in self.frlPorts:
self.frlPorts.append(endpoint.attrib['port']) self.frlPorts.append(endpoint.attrib['port'])
if isAMD: #if 'rubu' in hostinfo['soapHostname']:
context.policyElements = self.getPolicyForRUBUonAMD(hostinfo) # if isAMD:
else: # context.policyElements = self.getPolicyForRUBUonAMD(hostinfo)
context.policyElements = self.getPolicyForRUBUonSkylake(hostinfo) # else:
# context.policyElements = self.getPolicyForRUBUonSkylake(hostinfo)
for application in c.findall(QN(self.xcns,'Application').text): ## all 'Application's of this context for application in c.findall(QN(self.xcns,'Application').text): ## all 'Application's of this context
if ferolsOnly and not application.attrib['class'].startswith(('ferol::','ferol40::')): if ferolsOnly and not application.attrib['class'].startswith(('ferol::','ferol40::')):
...@@ -229,6 +230,8 @@ class ConfigFromFile(Configuration): ...@@ -229,6 +230,8 @@ class ConfigFromFile(Configuration):
elif app.params['class'] == 'evb::BU': elif app.params['class'] == 'evb::BU':
if dropAtBU: if dropAtBU:
self.dropAtBU(app) self.dropAtBU(app)
elif writeDelete:
self.writeDelete(app)
elif hlt: elif hlt:
self.noDelete(app,hostinfo['whitelist']) self.noDelete(app,hostinfo['whitelist'])
if generateAtRU: if generateAtRU:
...@@ -362,6 +365,18 @@ class ConfigFromFile(Configuration): ...@@ -362,6 +365,18 @@ class ConfigFromFile(Configuration):
app.properties = newProp app.properties = newProp
def writeDelete(self,app):
if app.params['class'] in ('evb::BU'):
newProp = []
for prop in app.properties:
if prop[0] not in ('dropEventData','deleteRawDataFiles','ignoreResourceSummary'):
newProp.append(prop)
newProp.append(('dropEventData','boolean','false'))
newProp.append(('deleteRawDataFiles','boolean','true'))
newProp.append(('ignoreResourceSummary','boolean','true'))
app.properties = newProp
def noDelete(self,app,whitelist): def noDelete(self,app,whitelist):
if app.params['class'] in ('evb::BU'): if app.params['class'] in ('evb::BU'):
newProp = [] newProp = []
...@@ -578,7 +593,7 @@ if __name__ == "__main__": ...@@ -578,7 +593,7 @@ if __name__ == "__main__":
symbolMap = SymbolMap.SymbolMap(os.environ["EVB_TESTER_HOME"]+"/cdaq/20170131/canon_1str_4x4/symbolMap.txt") symbolMap = SymbolMap.SymbolMap(os.environ["EVB_TESTER_HOME"]+"/cdaq/20170131/canon_1str_4x4/symbolMap.txt")
config = ConfigFromFile(symbolMap,os.environ["EVB_TESTER_HOME"]+"/cdaq/20170131/canon_1str_4x4/canon_1str_4x4.xml", config = ConfigFromFile(symbolMap,os.environ["EVB_TESTER_HOME"]+"/cdaq/20170131/canon_1str_4x4/canon_1str_4x4.xml",
fixPorts=False,useNuma=True,generateAtRU=False,dropAtRU=False,dropAtSocket=False,dropAtStream=False,dropAtBU=True, fixPorts=False,useNuma=True,generateAtRU=False,dropAtRU=False,dropAtSocket=False,dropAtStream=False,dropAtBU=True,
hlt=False,ferolMode=True,ferolsOnly=False,maxTriggerRate=None) writeDelete=False,hlt=False,ferolMode=True,ferolsOnly=False,maxTriggerRate=None)
#print(config.contexts) #print(config.contexts)
for key in config.contexts.keys(): for key in config.contexts.keys():
config.getConfigCmd(key) config.getConfigCmd(key)
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
swt=/DAQ3_Official_folded/StandAlone/StandAlone_40g_infini_dropAtBU swt=/DAQ3_Official_folded/StandAlone/StandAlone_40g_infini_dropAtBU
#swt=/Test/Remi/StandAlone/StandAlone_40g_infini_dropAtBU #swt=/Test/Remi/StandAlone/StandAlone_40g_infini_dropAtBU
hwcfg=/daq3val/eq_200904 hwcfg=/daq3val/eq_200904
dir=../daq3val/20200903 dir=../daq3val/20200915
mkdir -p $dir mkdir -p $dir
( (
...@@ -27,7 +27,7 @@ d3vrubu-c2e34-27-01.cms ...@@ -27,7 +27,7 @@ d3vrubu-c2e34-27-01.cms
EOF EOF
) > /tmp/hostlist.txt ) > /tmp/hostlist.txt
for nbFEDs in '4' '8' '12' '16' '20' '27' '36' ; do for nbFEDs in '4' '8' '12' '16' '20' '27' ; do
#for nbFEDs in '4' ; do #for nbFEDs in '4' ; do
fbSet=$hwcfg/evb/fb_1x${nbFEDs} fbSet=$hwcfg/evb/fb_1x${nbFEDs}
./createConfig.py $fbSet $swt 2 $dir/${nbFEDs}x1x2 -s /tmp/fed1022_$$.txt --daqval -p $HOME/configurator/CONFIGURATOR_DAQ2VAL.properties --hostList /tmp/hostlist.txt ./createConfig.py $fbSet $swt 2 $dir/${nbFEDs}x1x2 -s /tmp/fed1022_$$.txt --daqval -p $HOME/configurator/CONFIGURATOR_DAQ2VAL.properties --hostList /tmp/hostlist.txt
......
...@@ -33,7 +33,8 @@ class RunScans(TestRunner): ...@@ -33,7 +33,8 @@ class RunScans(TestRunner):
parser.add_argument("--dropAtSocket",action='store_true',help="drop data at pt::blit socket callback") parser.add_argument("--dropAtSocket",action='store_true',help="drop data at pt::blit socket callback")
parser.add_argument("--dropAtStream",action='store_true',help="drop data at the FEROL stream thread") parser.add_argument("--dropAtStream",action='store_true',help="drop data at the FEROL stream thread")
parser.add_argument("--dropAtBU",action='store_true',help="drop events after they have bene built at the BU") parser.add_argument("--dropAtBU",action='store_true',help="drop events after they have bene built at the BU")
parser.add_argument("--hlt",action='store_true',help="don't delete output files") parser.add_argument("--writeDelete",action='store_true',help="write events to files, but delete files instead of making them available to HLT")
parser.add_argument("--hlt",action='store_true',help="send events to HLT")
parser.add_argument("--ferolMode",action='store_true',help="generate data on FEROL instead of FRL") parser.add_argument("--ferolMode",action='store_true',help="generate data on FEROL instead of FRL")
parser.add_argument("--ferolsOnly",action='store_true',help="only start the FEROLs, no EvB applications") parser.add_argument("--ferolsOnly",action='store_true',help="only start the FEROLs, no EvB applications")
parser.add_argument("--waitForStateTransitions",action='store_true',help="wait for a key stroke before each state command") parser.add_argument("--waitForStateTransitions",action='store_true',help="wait for a key stroke before each state command")
...@@ -125,7 +126,7 @@ class RunScans(TestRunner): ...@@ -125,7 +126,7 @@ class RunScans(TestRunner):
config = ConfigFromFile(symbolMap,configFile,self.args['fixPorts'],self.args['numa'], config = ConfigFromFile(symbolMap,configFile,self.args['fixPorts'],self.args['numa'],
self.args['generateAtRU'],self.args['dropAtRU'], self.args['generateAtRU'],self.args['dropAtRU'],
self.args['dropAtSocket'],self.args['dropAtStream'], self.args['dropAtSocket'],self.args['dropAtStream'],
self.args['dropAtBU'],self.args['hlt'], self.args['dropAtBU'],self.args['writeDelete'],self.args['hlt'],
ferolMode,self.args['ferolsOnly'], ferolMode,self.args['ferolsOnly'],
self.args['maxTriggerRate']) self.args['maxTriggerRate'])
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment