File tree 1 file changed +3
-6
lines changed
src/main/java/org/encog/neural/networks
1 file changed +3
-6
lines changed Original file line number Diff line number Diff line change 29
29
import org .encog .engine .network .activation .ActivationFunction ;
30
30
import org .encog .engine .network .activation .ActivationSigmoid ;
31
31
import org .encog .engine .network .activation .ActivationTANH ;
32
+ import org .encog .mathutil .randomize .ConsistentRandomizer ;
32
33
import org .encog .mathutil .randomize .NguyenWidrowRandomizer ;
33
34
import org .encog .mathutil .randomize .Randomizer ;
34
35
import org .encog .mathutil .randomize .RangeRandomizer ;
@@ -619,16 +620,12 @@ public void reset() {
619
620
620
621
/**
621
622
* Reset the weight matrix and the bias values. This will use a
622
- * Nguyen-Widrow randomizer with a range between -1 and 1. If the network
623
- * does not have an input, output or hidden layers, then Nguyen-Widrow
624
- * cannot be used and a simple range randomize between -1 and 1 will be
625
- * used. Use the specified seed.
623
+ * RangeRandomizer with a range between -1 and 1.
626
624
*
627
625
*/
628
626
@ Override
629
627
public void reset (final int seed ) {
630
- Randomizer randomizer = getRandomizer ();
631
- randomizer .randomize (this );
628
+ (new ConsistentRandomizer (-1 ,1 ,seed )).randomize (this );
632
629
}
633
630
634
631
/**
You can’t perform that action at this time.
0 commit comments