def seed(range=10, hash=None):
    if hash is None:
        hash = __grains__['id']

    random.seed(hash)
    return random.randrange(range)
Save best model from each cross-validation fold.
dataset/ETHPy150Open saltstack/salt/salt/modules/mod_random.py/seed--crossover with--dataset/ETHPy150Open lisa-lab/pylearn2/pylearn2/cross_validation/train_cv_extensions.py/MonitorBasedSaveBestCV.on_save