From f782fdaa28d7245f932ff8f6424097cb10acf86d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?F=C3=A9lix=20Marty?= <9808326+fxmarty@users.noreply.github.com> Date: Tue, 9 Jan 2024 11:34:03 +0100 Subject: [PATCH] remove unwanted output --- optimum/exporters/onnx/model_patcher.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/optimum/exporters/onnx/model_patcher.py b/optimum/exporters/onnx/model_patcher.py index c534664010..db52493b6f 100644 --- a/optimum/exporters/onnx/model_patcher.py +++ b/optimum/exporters/onnx/model_patcher.py @@ -762,6 +762,8 @@ def patched_forward(input_ids, attention_mask): del result["input_ids"] if "attention_mask" in result: del result["attention_mask"] + if "all_layer_embeddings" in result: + del result["all_layer_embeddings"] return result