ATLAS Offline Software
Loading...
Searching...
No Matches
python.samplers.LogSampler Class Reference
Inheritance diagram for python.samplers.LogSampler:
Collaboration diagram for python.samplers.LogSampler:

Public Types

typedef HLT::TypeInformation::for_each_type_c< typenameEDMLIST::map, my_functor, my_result<>, my_arg< HLT::TypeInformation::get_cont, CONTAINER > >::type result

Public Member Functions

 __init__ (self, low, high)
 shoot (self)
 __call__ (self)

Public Attributes

 low = float(low)
 high = float(high)

Detailed Description

Definition at line 146 of file samplers.py.

Member Typedef Documentation

◆ result

Definition at line 90 of file EDM_MasterSearch.h.

Constructor & Destructor Documentation

◆ __init__()

python.samplers.LogSampler.__init__ ( self,
low,
high )

Definition at line 149 of file samplers.py.

149 def __init__(self, low, high):
150 self.low = float(low)
151 self.high = float(high)
152

Member Function Documentation

◆ __call__()

python.samplers.Sampler.__call__ ( self)
inherited
This is the call method that will actually be used (so that normal
functions can also be passed in as samplers).

Definition at line 17 of file samplers.py.

17 def __call__(self):
18 """This is the call method that will actually be used (so that normal
19 functions can also be passed in as samplers)."""
20 return self.shoot()
21

◆ shoot()

python.samplers.LogSampler.shoot ( self)

Reimplemented from python.samplers.Sampler.

Definition at line 153 of file samplers.py.

153 def shoot(self):
154 rand = random.random()
155 logval = rand * math.log(self.high) + (1 - rand) * math.log(self.low)
156 val = math.exp(logval)
157 return val
158
159

Member Data Documentation

◆ high

python.samplers.LogSampler.high = float(high)

Definition at line 151 of file samplers.py.

◆ low

python.samplers.LogSampler.low = float(low)

Definition at line 150 of file samplers.py.


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