JHUGen MELA  v2.4.1
Matrix element calculations as used in JHUGen. MELA is an important tool that was used for the Higgs boson discovery and for precise measurements of its structure and interactions. Please see the website https://spin.pha.jhu.edu/ and papers cited there for more details, and kindly cite those papers when using this code.
Public Member Functions | Public Attributes | List of all members
pythonmelautils.SelfDParameter Class Reference
Inheritance diagram for pythonmelautils.SelfDParameter:
Inheritance graph
[legend]
Collaboration diagram for pythonmelautils.SelfDParameter:
Collaboration graph
[legend]

Public Member Functions

def __init__ (self, arrayname, *indices)
 
def __get__ (self, obj, objtype)
 
def __set__ (self, obj, val)
 

Public Attributes

 arrayname
 
 indices
 

Detailed Description

Definition at line 158 of file pythonmelautils.py.

Constructor & Destructor Documentation

◆ __init__()

def pythonmelautils.SelfDParameter.__init__ (   self,
  arrayname,
indices 
)

Definition at line 159 of file pythonmelautils.py.

159  def __init__(self, arrayname, *indices):
160  self.arrayname = arrayname
161  self.indices = indices
162 

Member Function Documentation

◆ __get__()

def pythonmelautils.SelfDParameter.__get__ (   self,
  obj,
  objtype 
)

Definition at line 163 of file pythonmelautils.py.

163  def __get__(self, obj, objtype):
164  if obj is None: return self
165  array = getattr(obj, self.arrayname)
166  if not self.indices: return array
167  for index in self.indices[:-1]:
168  array = array[index]
169  return array[self.indices[-1]]
170 

◆ __set__()

def pythonmelautils.SelfDParameter.__set__ (   self,
  obj,
  val 
)

Definition at line 171 of file pythonmelautils.py.

171  def __set__(self, obj, val):
172  if not self.indices: return setattr(obj, self.arrayname, val)
173  array = getattr(obj, self.arrayname)
174  for index in self.indices[:-1]:
175  array = array[index]
176  array[self.indices[-1]] = val
177 

Member Data Documentation

◆ arrayname

pythonmelautils.SelfDParameter.arrayname

Definition at line 160 of file pythonmelautils.py.

◆ indices

pythonmelautils.SelfDParameter.indices

Definition at line 161 of file pythonmelautils.py.


The documentation for this class was generated from the following file: