e8caea8ea26a18f93c49ceb6e8d9a48403ca9e30,lxmls/deep_learning/numpy_models/log_linear.py,NumpyLogLinear,log_forward,#NumpyLogLinear#,17
Before Change
z = np.dot(input, self.weight.T) + self.bias
// Softmax implemented in log domain
log_tilde_z = z - logsumexp(z, axis=1)[:, None]
return log_tilde_z
def predict(self, input=None):
After Change
z = np.dot(input, self.weight.T) + self.bias
// Softmax implemented in log domain
log_tilde_z = z - logsumexp(z, axis=1, keepdims=True)
return log_tilde_z
def predict(self, input=None):

In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 4
Instances
Project Name: LxMLS/lxmls-toolkit
Commit Name: e8caea8ea26a18f93c49ceb6e8d9a48403ca9e30
Time: 2018-02-12
Author: ramon@astudillo.com
File Name: lxmls/deep_learning/numpy_models/log_linear.py
Class Name: NumpyLogLinear
Method Name: log_forward
Project Name: LxMLS/lxmls-toolkit
Commit Name: e8caea8ea26a18f93c49ceb6e8d9a48403ca9e30
Time: 2018-02-12
Author: ramon@astudillo.com
File Name: lxmls/deep_learning/numpy_models/mlp.py
Class Name: NumpyMLP
Method Name: log_forward
Project Name: LxMLS/lxmls-toolkit
Commit Name: e8caea8ea26a18f93c49ceb6e8d9a48403ca9e30
Time: 2018-02-12
Author: ramon@astudillo.com
File Name: lxmls/deep_learning/numpy_models/rnn.py
Class Name: NumpyRNN
Method Name: log_forward