From 2ab4a9adb3f191a6554184560f791418cbf7a3f0 Mon Sep 17 00:00:00 2001 From: Qian Chen Date: Thu, 24 Jun 2021 11:56:25 +0800 Subject: [PATCH] Set self.fitted = True instead of self._fitted. --- qlib/contrib/model/pytorch_nn.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qlib/contrib/model/pytorch_nn.py b/qlib/contrib/model/pytorch_nn.py index 15ee7ef71..868ab1513 100644 --- a/qlib/contrib/model/pytorch_nn.py +++ b/qlib/contrib/model/pytorch_nn.py @@ -297,7 +297,7 @@ class DNNModelPytorch(Model): _model_path = os.path.join(model_dir, _model_name) # Load model self.dnn_model.load_state_dict(torch.load(_model_path)) - self._fitted = True + self.fitted = True class AverageMeter: