(self)
Sample the parameter, returning a random value in its range.

    Returns:
      A value drawn uniformly at random between `min_value` and `max_value`.
Sample the parameter, returning a random value in its range.
Sample the parameter returning a random value in its range .
def sample(self):
    """Sample the parameter, returning a random value in its range.

    Returns:
      A value drawn uniformly at random between `min_value` and `max_value`.
    """
    if self.scale == 'linear':
      return random.uniform(self.min_value, self.max_value)
    else:
      log_min_value = math.log(self.min_value)
      log_max_value = math.log(self.max_value)
      return math.exp(random.uniform(log_min_value, log_max_value))
def sample ( self ) : if self . scale == 'linear' : return random . uniform ( self . min_value , self . max_value ) else : log_min_value = math . log ( self . min_value ) log_max_value = math . log ( self . max_value ) return math . exp ( random . uniform ( log_min_value , log_max_value ) )