| The Gaudi Framework v28r2-patches (bc4ad17a)

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions | Public Attributes | Static Public Attributes | Private Member Functions | List of all members
GaudiHive.precedence.RndBiased10BooleanValue Class Reference
Inheritance diagram for GaudiHive.precedence.RndBiased10BooleanValue:
[legend]
Collaboration diagram for GaudiHive.precedence.RndBiased10BooleanValue:
[legend]

## Public Member Functions
def | __init__ (self, useBuiltinPattern=True)
def | get (self)
def | get_pattern (self)

## Public Attributes
| pattern
| generator

## Static Public Attributes
list | builtinPattern = [True, False, False, True, False, False, False, False, False, False, False, False, False, False, False, False, True, False, False, True, False, False, False, False, False, False, False, False, False, True, False, False, False, False, False, False, False, False, False, False, False, True, False, False, False, False, False, False, False, False, True, False, False, False, False, False, False, False, False, True, False, False, False, False, False, False, False, False, False, False, False, False, False, False, True, False, True, False, True, False, False, False, False, False, False, False, False, True, False, True, False, False, True, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, True, False, False, False, False, False, False, False, False, False, True, False, False, False, False, True, True, False, False, False, False, False, False, False, False, False, False, True, True, False, True, False, False, False, False, False, False, False, False, False, False, True, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, True, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, True, False, False, False, False, False, False, False, False, False, False, False, True, False, False, False, False, False, False, False, False, False, False, False, True, False, False, False, True, False, False, False, False, False, False, False, False, True, False, False, False, False, False, False, False, False, False, False, False, True, False, True]
list | pattern = []

## Private Member Functions
def | _create_generator (self, pattern)

## Detailed Description

    Provides randomly distributed boolean value with True taking only 10%.
    The distribution has only 276 values and is reproducible, if no pattern re-generation is requested.

Definition at line 79 of file precedence.py.

## Constructor & Destructor Documentation

def GaudiHive.precedence.RndBiased10BooleanValue.__init__ | ( |  | self,
|  |  | useBuiltinPattern = `True`
| ) |  |

Definition at line 89 of file precedence.py.

89 def __init__(self, useBuiltinPattern=True):
90
91 if useBuiltinPattern:
92 self.pattern = self.builtinPattern
93 else:
94 # 278 values, biased approximately as 90% to 10% (276 precedence graph algorithms, plus two algorithms added manually - DstWriter and Framework)
95 self.pattern = [False for i in range(249)] + [True for i in range(29)]
96 random.shuffle(self.pattern)
97
98 self.generator = self._create_generator(self.pattern)
99
GaudiHive.precedence.RndBiased10BooleanValue.generator
generator
Definition: precedence.py:98
GaudiHive.precedence.RndBiased10BooleanValue._create_generator
def _create_generator(self, pattern)
Definition: precedence.py:100
Gaudi::Functional::details::zip::range
decltype(auto) range(Args &&...args)
Zips multiple containers together to form a single range.
Definition: FunctionalDetails.h:57
GaudiHive.precedence.RndBiased10BooleanValue.__init__
def __init__(self, useBuiltinPattern=True)
Definition: precedence.py:89
GaudiHive.precedence.RndBiased10BooleanValue.pattern
list pattern
Definition: precedence.py:87
GaudiHive.precedence.RndBiased10BooleanValue.builtinPattern
list builtinPattern
Definition: precedence.py:86

## Member Function Documentation

def GaudiHive.precedence.RndBiased10BooleanValue._create_generator | ( |  | self,
|  |  | pattern
| ) |  |
| private

Definition at line 100 of file precedence.py.

100 def _create_generator(self, pattern):
101
102 for b in pattern:
103 yield b
104
GaudiHive.precedence.RndBiased10BooleanValue._create_generator
def _create_generator(self, pattern)
Definition: precedence.py:100

def GaudiHive.precedence.RndBiased10BooleanValue.get | ( |  | self | ) |

Definition at line 105 of file precedence.py.

105 def get(self):
106
107 return next(self.generator)
108
GaudiHive.precedence.RndBiased10BooleanValue.generator
generator
Definition: precedence.py:98
GaudiHive.precedence.RndBiased10BooleanValue.get
def get(self)
Definition: precedence.py:105

def GaudiHive.precedence.RndBiased10BooleanValue.get_pattern | ( |  | self | ) |

Definition at line 109 of file precedence.py.

109 def get_pattern(self):
110
111 return self.pattern
112
113
GaudiHive.precedence.RndBiased10BooleanValue.get_pattern
def get_pattern(self)
Definition: precedence.py:109
GaudiHive.precedence.RndBiased10BooleanValue.pattern
list pattern
Definition: precedence.py:87

## Member Data Documentation

list GaudiHive.precedence.RndBiased10BooleanValue.builtinPattern = [True, False, False, True, False, False, False, False, False, False, False, False, False, False, False, False, True, False, False, True, False, False, False, False, False, False, False, False, False, True, False, False, False, False, False, False, False, False, False, False, False, True, False, False, False, False, False, False, False, False, True, False, False, False, False, False, False, False, False, True, False, False, False, False, False, False, False, False, False, False, False, False, False, False, True, False, True, False, True, False, False, False, False, False, False, False, False, True, False, True, False, False, True, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, True, False, False, False, False, False, False, False, False, False, True, False, False, False, False, True, True, False, False, False, False, False, False, False, False, False, False, True, True, False, True, False, False, False, False, False, False, False, False, False, False, True, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, True, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, True, False, False, False, False, False, False, False, False, False, False, False, True, False, False, False, False, False, False, False, False, False, False, False, True, False, False, False, True, False, False, False, False, False, False, False, False, True, False, False, False, False, False, False, False, False, False, False, False, True, False, True]
| static

Definition at line 86 of file precedence.py.

GaudiHive.precedence.RndBiased10BooleanValue.generator

Definition at line 98 of file precedence.py.

list GaudiHive.precedence.RndBiased10BooleanValue.pattern = []
| static

Definition at line 87 of file precedence.py.

GaudiHive.precedence.RndBiased10BooleanValue.pattern

Definition at line 92 of file precedence.py.

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

- GaudiHive/python/GaudiHive/precedence.py