A set of functions performing routine administrative I/O tasks.
|
parse_info_str(fsock)
Parse a newline separated list of "param=value" as a
dictionnary |
source code
|
|
|
mute_logger(names=[ ' madgraph ' , ' ALOHA ' , ' cmdprint ' , ' madevent ' ] ,
levels=[ 50, 50, 50, 50] )
change the logger level and restore those at their initial value at
the end of the function decorated. |
source code
|
|
|
get_pkg_info(info_str=None)
Returns the current version information of the MadGraph5_aMC@NLO
package, as written in the VERSION text file. |
source code
|
|
|
get_time_info()
Returns the present time info for use in MG5 command history header. |
source code
|
|
|
find_includes_path(start_path,
extension)
Browse the subdirectories of the path 'start_path' and returns the
first one found which contains at least one file ending with the
string extension given in argument. |
source code
|
|
|
|
|
|
|
nice_representation(var,
nb_space=0)
Return nice information on the current variable |
source code
|
|
|
|
|
compile(arg=[ ] ,
cwd=None,
mode=' fortran ' ,
job_specs=True,
nb_core=1,
**opt)
compile a given directory |
source code
|
|
|
|
|
mod_compilator(directory,
new=' gfortran ' ,
current=None,
compiler_type=' gfortran ' ) |
source code
|
|
|
detect_current_compiler(path,
compiler_type=' fortran ' )
find the current compiler for the current directory |
source code
|
|
|
find_makefile_in_dir(directory)
return a list of all file starting with makefile in the given
directory |
source code
|
|
|
|
|
|
|
|
|
|
|
|
|
call(arg,
*args,
**opt)
nice way to call an external program with nice error treatment |
source code
|
|
|
Popen(arg,
*args,
**opt)
nice way to call an external program with nice error treatment |
source code
|
|
|
|
|
tail(f,
n,
offset=None)
Reads a n lines from f with an offset of offset lines. |
source code
|
|
|
get_last_line(fsock)
return the last line of a file |
source code
|
|
|
write_PS_input(filePath,
PS)
Write out in file filePath the PS point to be read by the MadLoop. |
source code
|
|
|
format_timer(running_time)
return a nicely string representing the time elapsed. |
source code
|
|
|
gunzip(path,
keep=False,
stdout=None)
a standard replacement for os.system('gunzip -f %s.gz ' % event_path) |
source code
|
|
|
gzip(path,
stdout=None,
error=True)
a standard replacement for os.system('gzip %s ' % path) |
source code
|
|
|
is_executable(path)
check if a path is executable |
source code
|
|
|
sprint(*args,
**opt)
Returns the current line number in our program. |
source code
|
|
|
equal(a,
b,
sig_fig=6,
zero_limit=True)
function to check if two float are approximatively equal |
source code
|
|
|
|