From a4f792d0cc1627e9d27c6b2d3437cea65b8ac33d Mon Sep 17 00:00:00 2001 From: Ou <47025953+ouyhlan@users.noreply.github.com> Date: Thu, 2 Dec 2021 20:25:12 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8DTester=E5=88=9D=E5=A7=8B?= =?UTF-8?q?=E5=8C=96bug=20(#401)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: ouyhlan --- fastNLP/core/tester.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fastNLP/core/tester.py b/fastNLP/core/tester.py index 55ffd9cf..cb05f82d 100644 --- a/fastNLP/core/tester.py +++ b/fastNLP/core/tester.py @@ -148,7 +148,7 @@ class Tester(object): self._predict_func = self._model.predict self._predict_func_wrapper = self._model.predict else: - if _model_contains_inner_module(model): + if _model_contains_inner_module(self._model): self._predict_func_wrapper = self._model.forward self._predict_func = self._model.module.forward else: