Skip to content

Commit

Permalink
Upgrade Siglip to opset=14
Browse files Browse the repository at this point in the history
  • Loading branch information
xenova committed Aug 29, 2024
1 parent d4321b6 commit fe140c6
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion optimum/exporters/onnx/model_configs.py
Original file line number Diff line number Diff line change
Expand Up @@ -1087,7 +1087,9 @@ class SiglipNormalizedConfig(CLIPNormalizedConfig):

class SiglipOnnxConfig(CLIPOnnxConfig):
NORMALIZED_CONFIG_CLASS = SiglipNormalizedConfig
DEFAULT_ONNX_OPSET = 13
# torch.onnx.errors.UnsupportedOperatorError: Exporting the operator 'aten::scaled_dot_product_attention' to ONNX opset version 13 is not supported.
# Support for this operator was added in version 14, try exporting with this version.
DEFAULT_ONNX_OPSET = 14

@property
def inputs(self) -> Dict[str, Dict[int, str]]:
Expand Down

0 comments on commit fe140c6

Please sign in to comment.