ATLAS Offline Software
Loading...
Searching...
No Matches
AODElectronContainerReader.py
Go to the documentation of this file.
1#!/usr/bin/env python
2# Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
3#
4# python script for launching AODReader job
5#
6
7__version__ = '$Revision: 484742 $'
8__author__ = 'Radist Morse radist.morse@gmail.com'
9__doc__ = 'Script for launching AODReader job'
10
11import os
12from sys import exit
13from os.path import isfile
14
15from optparse import OptionParser
16parser = OptionParser(usage = "usage: %prog [options] input1 [...]", version="%prog v0.0.1 $Id: AODElectronContainerReader.py,v 0.1 2010-11-10 13:00:12 Morse Exp $")
17
18parser.add_option("-o","--outputFile",dest="output",default='ntuple.root',help="select the output file name (default: %default)")
19
20(options, args) = parser.parse_args()
21
22for arg in args :
23 if (not isfile (arg)) :
24 print ("ERROR: wrong input: nonexistent file:",arg)
25 exit(1)
26
27exec = __file__.replace("AODElectronContainerReader.py","AODElectronContainerReaderBody.py")
28os.system('athena -c "args={:s}" {:s}'.format(str(args),exec))