From a51a1be3203ae99664f934e5e0dafd66aef6f93f Mon Sep 17 00:00:00 2001 From: allegroai <> Date: Wed, 17 Jun 2020 01:01:31 +0300 Subject: [PATCH] Add manual model tracking example --- examples/reporting/model_config.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/examples/reporting/model_config.py b/examples/reporting/model_config.py index 1f882266..a0d401e6 100644 --- a/examples/reporting/model_config.py +++ b/examples/reporting/model_config.py @@ -2,7 +2,7 @@ # import os -from trains import Task +from trains import Task, OutputModel task = Task.init(project_name='examples', task_name='Model configuration example') @@ -31,6 +31,9 @@ model_config_dict['value'] *= model_config_dict['new value'] labels = {'background': 0, 'cat': 1, 'dog': 2} task.connect_label_enumeration(labels) +# Manually log a local model file +OutputModel().update_weights('my_best_model.bin') + # storing a model: Any saved model (keras / pytorch / tensorflow / etc.) # will have the task network configuration and label enumeration print('Any model stored from this point onwards, will contain both model_config and label_enumeration')