9 import Configuration.Applications
10 from Configuration.Applications.ConfigBuilder
import ConfigBuilder
15 configBuilder =
ConfigBuilder(options, with_output =
True, with_input =
True)
23 if hasattr( options,
"era" )
and options.era
is not None :
24 from Configuration.StandardSequences.Eras
import eras
25 for eraName
in options.era.split(
',') :
26 getattr( eras, eraName )._setChosen()
28 configBuilder.prepare()
30 config = open(options.python_filename,
"w")
31 config.write(configBuilder.pythonCfgCode)
35 if options.dump_python:
36 status_code = os.system(
'edmConfigDump -o {f} {f}'.
format(f=options.python_filename))
37 if status_code: sys.exit(status_code)
38 print(
"Expanded config file", options.python_filename,
"created")
41 if options.no_exec_flag:
42 print(
"Config file "+options.python_filename+
" created")
45 commandString = options.prefix+
" cmsRun "+options.suffix
46 print(
"Starting "+commandString+
' '+options.python_filename)
47 commands = commandString.lstrip().
split()
49 os.execvpe(commands[0],commands+[options.python_filename],os.environ)
53 def OptionsFromCommandLine()
void print(TMatrixD &m, const char *label=nullptr, bool mathematicaFormat=false)
def split(sequence, size)