Skip to content

Commit

Permalink
fix(onnx/granite): Use LlamaOnnxConfig as the base for GraniteOnnxConfig
Browse files Browse the repository at this point in the history
Branch: OnnxGranite

Signed-off-by: Gabe Goodhart <[email protected]>
  • Loading branch information
gabe-l-hart committed Oct 22, 2024
1 parent e4f8707 commit 3a96b22
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions optimum/exporters/onnx/model_configs.py
Original file line number Diff line number Diff line change
Expand Up @@ -290,14 +290,8 @@ class GemmaOnnxConfig(LlamaOnnxConfig):
pass


class GraniteOnnxConfig(TextDecoderOnnxConfig):
# GG TODO: Bump past 4.44.2 once the next release is out
MIN_TRANSFORMERS_VERSION = version.parse("4.44.2")
DEFAULT_ONNX_OPSET = 14 # Granite follows Llama's default

DUMMY_INPUT_GENERATOR_CLASSES = (DummyTextInputGenerator, MistralDummyPastKeyValuesGenerator)
DUMMY_PKV_GENERATOR_CLASS = MistralDummyPastKeyValuesGenerator
NORMALIZED_CONFIG_CLASS = NormalizedTextConfig
class GraniteOnnxConfig(LlamaOnnxConfig):
MIN_TRANSFORMERS_VERSION = version.parse("4.45.0")


class PhiOnnxConfig(TextDecoderWithPositionIdsOnnxConfig):
Expand Down

0 comments on commit 3a96b22

Please sign in to comment.