parameters: (self, seed=None)
docstring: Generate a value, possibly based on a seed.
  
          If seed is not None, use it as the seed. Otherwise, if the seeds
          constraint is non-empty, pick a random element as the seed.
  
          If there are no seeds, return the result of randomize()
  
          If there are seeds, use the p_random constraint to determine the
          chance of returning the result of randomize() and use the p_fuzz
          constraint to determine the chance of returning the result of fuzz(seed)
          Otherwise, return the seed.
docstring_summary: Generate a value, possibly based on a seed.
docstring_tokens: Generate a value possibly based on a seed .
function: def generate(self, seed=None):
          """Generate a value, possibly based on a seed.
  
          If seed is not None, use it as the seed. Otherwise, if the seeds
          constraint is non-empty, pick a random element as the seed.
  
          If there are no seeds, return the result of randomize()
  
          If there are seeds, use the p_random constraint to determine the
          chance of returning the result of randomize() and use the p_fuzz
          constraint to determine the chance of returning the result of fuzz(seed)
          Otherwise, return the seed.
          """
          if seed is None:
              seeds = self.constraints['seeds']
          else:
              seeds = [seed]
  
          if not seeds or (random.random() < self.constraints['p_random']):
              return self._randomize()
  
          seed = random.choice(seeds)
  
          if random.random() < self.constraints['p_fuzz']:
              return self._fuzz(seed)
          else:
              return self.eval_seed(seed)
function_tokens: def generate ( self , seed = None ) : if seed is None : seeds = self . constraints [ 'seeds' ] else : seeds = [ seed ] if not seeds or ( random . random ( ) < self . constraints [ 'p_random' ] ) : return self . _randomize ( ) seed = random . choice ( seeds ) if random . random ( ) < self . constraints [ 'p_fuzz' ] : return self . _fuzz ( seed ) else : return self . eval_seed ( seed )