Skip to content

Commit 3d96a61

Browse files
committed
a few fixes
1 parent b37d6d1 commit 3d96a61

3 files changed

Lines changed: 9 additions & 3 deletions

File tree

onnx_diagnostic/ci_models/export_qwen25_vl.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@
5959
import os
6060
import sys
6161
import time
62+
import warnings
6263
from typing import Any, Dict, List, Tuple
6364
from .ci_helpers import (
6465
check_for_discrepancies_and_log_everything_into_a_json_file,
@@ -301,7 +302,11 @@ def main(
301302
print(f"-- config._attn_implementation={model.config._attn_implementation}")
302303
print(f"-- model.dtype={model.dtype}")
303304
print(f"-- model.device={model.device}")
304-
processor = AutoProcessor.from_pretrained(model_id, use_fast=True)
305+
try:
306+
processor = AutoProcessor.from_pretrained(model_id, use_fast=True)
307+
except OSError as e:
308+
warnings.warn(f"Unable to access internet due to {e!r}", ResourceWarning, stacklevel=0)
309+
return
305310
print(f"-- processor={type(processor)}")
306311

307312
export_inputs, other_inputs = None, None

onnx_diagnostic/torch_export_patches/patches/patch_transformers.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
from ._patch_transformers_idefics import patched_IdeficsEmbedding, patched_IdeficsAttention
2121
from ._patch_transformers_sam_mask_decoder import patched_SamMaskDecoder
2222

23-
# transformers dependant patches
23+
# transformers dependent patches
2424

2525
from ._patch_transformers_cache_utils import patch_parse_processor_args
2626

@@ -41,7 +41,7 @@
4141
patched_sdpa_mask_recent_torch,
4242
)
4343

44-
# transformers models dependant patches
44+
# transformers models dependent patches
4545

4646
if _has_transformers("4.51"):
4747
from ._patch_transformers_rotary_embedding import patched_Phi3RotaryEmbedding

onnx_diagnostic/torch_models/hghub/hub_data.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@
5151
EsmModel,feature-extraction
5252
FalconMambaForCausalLM,text-generation
5353
FunnelBaseModel,feature-extraction
54+
FuyuForCausalLM,image-text-to-text
5455
GLPNModel,image-feature-extraction
5556
GPT2LMHeadModel,text-generation
5657
GPTBigCodeModel,feature-extraction

0 commit comments

Comments
 (0)