Skip to content

Commit 6a85dc6

Browse files
committed
Minor fix.
1 parent 01f0f08 commit 6a85dc6

File tree

1 file changed

+1
-1
lines changed
  • neural_structured_learning/research/gam/models

1 file changed

+1
-1
lines changed

neural_structured_learning/research/gam/models/cnn.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -320,7 +320,7 @@ def get_loss(self,
320320
loss = tf.losses.softmax_cross_entropy(targets, predictions)
321321

322322
# Weight decay loss.
323-
if weight_decay:
323+
if weight_decay is not None:
324324
for var in reg_params.values():
325325
loss += weight_decay * tf.nn.l2_loss(var)
326326
return loss

0 commit comments

Comments
 (0)