CMS 3D CMS Logo

Namespaces | Classes | Functions | Variables
python Namespace Reference

Namespaces

 cmscompleter
 
 cmstools
 
 diff_provenance
 
 diffProv
 
 iterators
 
 LumiList
 
 namespaceDict
 
 ParticleDecayDrawer
 
 read_provenance
 
 readProv
 
 rootplot
 
 XML2Python
 

Classes

class  Events
 
class  Handle
 
class  Lumis
 
class  Runs
 

Functions

def setQuietWarn (quiet=True)
 
def warn (*args, **kwargs)
 

Variables

 quietWarn
 

Function Documentation

◆ setQuietWarn()

def python.setQuietWarn (   quiet = True)

Definition at line 17 of file __init__.py.

17 def setQuietWarn (quiet = True):
18  global quietWarn
19  quietWarn = quiet
20 

◆ warn()

def python.warn ( args,
**  kwargs 
)
print out warning with line number and rest of arguments

Definition at line 21 of file __init__.py.

21 def warn (*args, **kwargs):
22  """print out warning with line number and rest of arguments"""
23  if quietWarn: return
24  frame = inspect.stack()[1]
25  filename = frame[1]
26  lineNum = frame[2]
27  #print "after '%s'" % filename
28  blankLines = kwargs.get('blankLines', 0)
29  if blankLines:
30  print('\n' * blankLines)
31  spaces = kwargs.get('spaces', 0)
32  if spaces:
33  print(' ' * spaces, end=' ')
34  if len (args):
35  print("%s (%s): " % (filename, lineNum), end=' ')
36  for arg in args:
37  print(arg, end=' ')
38  print()
39  else:
40  print("%s (%s):" % (filename, lineNum))
41 

References print().

Referenced by ClusterSummary.getModuleLocation().

Variable Documentation

◆ quietWarn

python.quietWarn

Definition at line 15 of file __init__.py.

python.warn
def warn(*args, **kwargs)
Definition: __init__.py:21
print
void print(TMatrixD &m, const char *label=nullptr, bool mathematicaFormat=false)
Definition: Utilities.cc:46
python.setQuietWarn
def setQuietWarn(quiet=True)
Definition: __init__.py:17