MCPcopy Index your code
hub / github.com/tensorlayer/TensorLayer / save_validation_log

Method save_validation_log

tensorlayer/db.py:434–452  ·  view source on GitHub ↗

Saves the validation log, timestamp will be added automatically. Parameters ----------- kwargs : logging information Events, such as accuracy, loss, step number and etc. Examples --------- >>> db.save_validation_log(accuracy=0.33, loss=0.

(self, **kwargs)

Source from the content-addressed store, hash-verified

432 logging.info("[Database] train log: " + _log)
433
434 def save_validation_log(self, **kwargs):
435 """Saves the validation log, timestamp will be added automatically.
436
437 Parameters
438 -----------
439 kwargs : logging information
440 Events, such as accuracy, loss, step number and etc.
441
442 Examples
443 ---------
444 >>> db.save_validation_log(accuracy=0.33, loss=0.98)
445
446 """
447
448 self._fill_project_info(kwargs)
449 kwargs.update({'time': datetime.utcnow()})
450 _result = self.db.ValidLog.insert_one(kwargs)
451 _log = self._print_dict(kwargs)
452 logging.info("[Database] valid log: " + _log)
453
454 def save_testing_log(self, **kwargs):
455 """Saves the testing log, timestamp will be added automatically.

Callers

nothing calls this directly

Calls 3

_fill_project_infoMethod · 0.95
_print_dictMethod · 0.95
updateMethod · 0.45

Tested by

no test coverage detected