Belle II Software development
tau_encoder Class Reference

Public Member Functions

def __init__ (self, amp_range, tau_range)
 
def encode (self, tau)
 
def decode (self, etau)
 

Public Attributes

 amp_max
 amp range
 
 tau_max
 tau range
 
 at_ratio
 at ratio
 

Detailed Description

A simple class to encode and decode tau values for network training
based on amplitude and tau ranges.

Definition at line 170 of file SVDSimBase.py.

Constructor & Destructor Documentation

◆ __init__()

def __init__ (   self,
  amp_range,
  tau_range 
)
creates the class

Definition at line 177 of file SVDSimBase.py.

177 def __init__(self, amp_range, tau_range):
178 """
179 creates the class
180 """
181
182 self.amp_min, self.amp_max = amp_range
183
184 self.tau_min, self.tau_max = tau_range
185
186 self.at_ratio = (self.amp_max - self.amp_min) / (self.tau_max - self.tau_min)
187

Member Function Documentation

◆ decode()

def decode (   self,
  etau 
)
decoder of tau values for network training

Definition at line 194 of file SVDSimBase.py.

194 def decode(self, etau):
195 """
196 decoder of tau values for network training
197 """
198 return (self.tau_min + 1.0 / self.at_ratio * (etau - self.amp_min))
199
200

◆ encode()

def encode (   self,
  tau 
)
encoder of tau values for network training

Definition at line 188 of file SVDSimBase.py.

188 def encode(self, tau):
189 """
190 encoder of tau values for network training
191 """
192 return (self.amp_min + self.at_ratio * (tau - self.tau_min))
193

Member Data Documentation

◆ amp_max

amp_max

amp range

Definition at line 182 of file SVDSimBase.py.

◆ at_ratio

at_ratio

at ratio

Definition at line 186 of file SVDSimBase.py.

◆ tau_max

tau_max

tau range

Definition at line 184 of file SVDSimBase.py.


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