def local_random():
 global _local_random
 if (_local_random is None):
  _local_random = random.Random()
 return _local_random

def local_random ( ) : global _local_random if ( _local_random is None ) : _local_random = random . Random ( ) return _local_random
get the local random number generator .