From 7901e0b383b8cd2ca80e8099918aa64ecdc24546 Mon Sep 17 00:00:00 2001 From: tangwei12 Date: Wed, 1 Apr 2020 08:39:09 +0000 Subject: [PATCH] add trainer.py for examples --- examples/train.py | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 examples/train.py diff --git a/examples/train.py b/examples/train.py new file mode 100644 index 00000000..7c0f34df --- /dev/null +++ b/examples/train.py @@ -0,0 +1,11 @@ + +import yaml +from .. trainer.factory import TrainerFactory + +if __name__ == "__main__": + + with open('ctr-dnn_train.yaml', 'r') as rb: + global_config = yaml.load(rb.read()) + + trainer = TrainerFactory.craete(global_config) + trainer.run() -- GitLab