Skip to content

Commit

Permalink
Linear regression layer returns loss as GPUArray, not float, to be co…
Browse files Browse the repository at this point in the history
…nsistent with SoftmaxLayer
  • Loading branch information
Wainberg committed Feb 21, 2015
1 parent 6847eae commit 97a2f5a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion hebel/layers/linear_regression_layer.py
Original file line number Diff line number Diff line change
Expand Up @@ -189,5 +189,5 @@ def squared_loss(self, input_data, targets, average=True,
matrix_sum_out_axis((targets - activations) ** 2, 1))

if average: loss = loss.mean()
return float(loss.get())
return loss
train_error = squared_loss

0 comments on commit 97a2f5a

Please sign in to comment.