Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
OpenDAS
vllm_cscc
Commits
2059b8d9
Unverified
Commit
2059b8d9
authored
Aug 25, 2024
by
Isotr0py
Committed by
GitHub
Aug 25, 2024
Browse files
[Misc] Remove snapshot_download usage in InternVL2 test (#7835)
parent
8aaf3d53
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
9 deletions
+3
-9
tests/models/test_internvl.py
tests/models/test_internvl.py
+3
-9
No files found.
tests/models/test_internvl.py
View file @
2059b8d9
...
...
@@ -3,7 +3,6 @@ from typing import List, Optional, Tuple, Type
import
pytest
import
torch
from
huggingface_hub
import
snapshot_download
from
PIL.Image
import
Image
from
transformers
import
AutoConfig
...
...
@@ -25,17 +24,12 @@ HF_IMAGE_PROMPTS = IMAGE_ASSETS.prompts({
"<|im_start|>User
\n
<image>
\n
What is the season?<|im_end|>
\n
<|im_start|>Assistant
\n
"
,
# noqa: E501
})
# we use snapshot_download to prevent conflicts between
# dynamic_module and trust_remote_code for hf_runner
DOWNLOAD_PATTERN
=
[
"*.json"
,
"*.py"
,
"*.safetensors"
,
"*.txt"
,
"*.model"
]
models
=
[
snapshot_download
(
"OpenGVLab/InternVL2-1B"
,
allow_patterns
=
DOWNLOAD_PATTERN
),
snapshot_download
(
"OpenGVLab/InternVL2-2B"
,
allow_patterns
=
DOWNLOAD_PATTERN
),
"OpenGVLab/InternVL2-1B"
,
"OpenGVLab/InternVL2-2B"
,
# Broken due to outdated implementation of Phi-3
# See: https://huggingface.co/OpenGVLab/InternVL2-4B/discussions/3
#
snapshot_download(
"OpenGVLab/InternVL2-4B"
)
,
# "OpenGVLab/InternVL2-4B",
]
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment