25694a657492c97276d201a98cff47266060254a,paysage/layers.py,ExponentialLayer,random,#ExponentialLayer#Any#,98
Before Change
return numpy.random.exponential(loc).astype(numpy.float32)
def random(self, loc):
return numpy.random.exponential(numpy.ones_like(loc)).astype(numpy.float32)
// ---- FUNCTIONS ----- //
After Change
r = self.rand.get(*loc.shape)
while r.shape != loc.shape:
r = self.rand.get(*loc.shape)
return -B.log(r)
// ---- FUNCTIONS ----- //
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 3
Instances
Project Name: drckf/paysage
Commit Name: 25694a657492c97276d201a98cff47266060254a
Time: 2016-12-23
Author: charlesfisher@Charless-MacBook-Pro.local
File Name: paysage/layers.py
Class Name: ExponentialLayer
Method Name: random
Project Name: drckf/paysage
Commit Name: 25694a657492c97276d201a98cff47266060254a
Time: 2016-12-23
Author: charlesfisher@Charless-MacBook-Pro.local
File Name: paysage/layers.py
Class Name: ExponentialLayer
Method Name: sample_state
Project Name: senarvi/theanolm
Commit Name: 86e27ba04a0e9fac580485912ea32eb7b6f4892e
Time: 2017-05-27
Author: seppo.git@marjaniemi.com
File Name: tests/theanolm/textscorer_test.py
Class Name: DummyNetwork
Method Name: __init__