From d376d85247a81e0c8881eed20efa11d107795950 Mon Sep 17 00:00:00 2001 From: Hugo Le Belzic Date: Thu, 25 Apr 2024 03:45:35 +0200 Subject: [PATCH] fix: update qgpt2_class.py to fix typo This commit fixes a bug in use_cases_examples/llm/qgpt2_class.py demo where `simulate` was not called properly. It raised `TypeError: unsupported operand type(s) for /: 'method' and 'int'` because `` was not called. --- use_case_examples/llm/qgpt2_class.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/use_case_examples/llm/qgpt2_class.py b/use_case_examples/llm/qgpt2_class.py index 846068f7c..d85817698 100644 --- a/use_case_examples/llm/qgpt2_class.py +++ b/use_case_examples/llm/qgpt2_class.py @@ -129,7 +129,7 @@ def run_torch(self, inputs: torch.Tensor, fhe: str = "disable", true_float: bool q_x = np.expand_dims(q_x, axis=0) if fhe == "simulate": - q_y = self.circuit.simulate + q_y = self.circuit.simulate(q_x) elif fhe == "execute": q_y = self.circuit.encrypt_run_decrypt(q_x)