Permalink
Browse files

Still print predicted_best_cost even when predicted_best_uncertainty …

…isn't set
  • Loading branch information...
1 parent e30906a commit e6d371aabb5da883c46a0654debbd0bf2696a039 @charmasaur charmasaur committed Dec 9, 2016
Showing with 5 additions and 2 deletions.
  1. +5 −2 mloop/controllers.py
View
@@ -763,8 +763,11 @@ def print_results(self):
super(MachineLearnerController,self).print_results()
try:
self.log.info('Predicted best parameters:' + str(self.predicted_best_parameters))
- self.log.info('Predicted best cost:' + str(self.predicted_best_cost) + ' +/- ' + str(self.predicted_best_uncertainty))
-
+ try:
+ errorstring = ' +/- ' + str(self.predicted_best_uncertainty)
+ except AttributeError:
+ errorstring = ''
+ self.log.info('Predicted best cost:' + str(self.predicted_best_cost) + errorstring)
except AttributeError:
pass
try:

0 comments on commit e6d371a

Please sign in to comment.