Skip to content

Commit 74eb09a

Browse files
committed
Remove loss_fn name
1 parent e1d0a8e commit 74eb09a

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

setup.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020

2121
MAJOR = 0
2222
MINOR = 5
23-
PATCH = 2
23+
PATCH = 3
2424
PRE_RELEASE = ''
2525
# Use the following formatting: (major, minor, patch, prerelease)
2626
VERSION = (MAJOR, MINOR, PATCH, PRE_RELEASE)

tensorlayerx/model/core.py

+4-4
Original file line numberDiff line numberDiff line change
@@ -307,7 +307,7 @@ def tf_train(
307307
val_loss, val_acc, n_iter = 0, 0, 0
308308
for X_batch, y_batch in test_dataset:
309309
_logits = network(X_batch) # is_train=False, disable dropout
310-
val_loss += loss_fn(_logits, y_batch, name='eval_loss')
310+
val_loss += loss_fn(_logits, y_batch)
311311
if metrics:
312312
metrics.update(_logits, y_batch)
313313
val_acc += metrics.result()
@@ -360,7 +360,7 @@ def ms_train(
360360
val_loss, val_acc, n_iter = 0, 0, 0
361361
for X_batch, y_batch in test_dataset:
362362
_logits = network(X_batch)
363-
val_loss += loss_fn(_logits, y_batch, name='eval_loss')
363+
val_loss += loss_fn(_logits, y_batch)
364364
if metrics:
365365
metrics.update(_logits, y_batch)
366366
val_acc += metrics.result()
@@ -414,7 +414,7 @@ def pd_train(
414414
val_loss, val_acc, n_iter = 0, 0, 0
415415
for X_batch, y_batch in test_dataset:
416416
_logits = network(X_batch) # is_train=False, disable dropout
417-
val_loss += loss_fn(_logits, y_batch, name='eval_loss')
417+
val_loss += loss_fn(_logits, y_batch)
418418
if metrics:
419419
metrics.update(_logits, y_batch)
420420
val_acc += metrics.result()
@@ -468,7 +468,7 @@ def th_train(
468468
val_loss, val_acc, n_iter = 0, 0, 0
469469
for X_batch, y_batch in test_dataset:
470470
_logits = network(X_batch) # is_train=False, disable dropout
471-
val_loss += loss_fn(_logits, y_batch, name='eval_loss')
471+
val_loss += loss_fn(_logits, y_batch)
472472
if metrics:
473473
metrics.update(_logits, y_batch)
474474
val_acc += metrics.result()

tensorlayerx/package_info.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
MAJOR = 0
66
MINOR = 5
7-
PATCH = 2
7+
PATCH = 3
88
PRE_RELEASE = ''
99
# Use the following formatting: (major, minor, patch, prerelease)
1010
VERSION = (MAJOR, MINOR, PATCH, PRE_RELEASE)

0 commit comments

Comments
 (0)