Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit e73ceae

Browse files
Log exception.
Change: 149800303
1 parent db75516 commit e73ceae

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

tensorflow/contrib/learn/python/learn/metric_spec.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -426,6 +426,6 @@ def _get_dict(name, dict_or_tensor, key):
426426
labels=label,
427427
predictions=prediction,
428428
weights=inputs[self.weight_key] if self.weight_key else None)
429-
except: # pylint: disable=bare-except
430-
logging.error('Could not create metric ops for %s.' % self)
429+
except Exception as ex:
430+
logging.error('Could not create metric ops for %s, %s.' % (self, ex))
431431
raise

0 commit comments

Comments
 (0)