Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
vision
Commits
526ec93e
Unverified
Commit
526ec93e
authored
Dec 05, 2023
by
Nicolas Hug
Committed by
GitHub
Dec 05, 2023
Browse files
Skip jpeg encoding/decoding tests on MacOS (#8145)
parent
1ababf90
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
0 deletions
+3
-0
test/test_image.py
test/test_image.py
+3
-0
No files found.
test/test_image.py
View file @
526ec93e
...
...
@@ -34,6 +34,7 @@ ENCODE_JPEG = os.path.join(IMAGE_ROOT, "encode_jpeg")
INTERLACED_PNG
=
os
.
path
.
join
(
IMAGE_ROOT
,
"interlaced_png"
)
TOOSMALL_PNG
=
os
.
path
.
join
(
IMAGE_ROOT
,
"toosmall_png"
)
IS_WINDOWS
=
sys
.
platform
in
(
"win32"
,
"cygwin"
)
IS_MACOS
=
sys
.
platform
==
"darwin"
PILLOW_VERSION
=
tuple
(
int
(
x
)
for
x
in
PILLOW_VERSION
.
split
(
"."
))
...
...
@@ -419,6 +420,7 @@ def test_encode_jpeg_errors():
encode_jpeg
(
torch
.
empty
((
100
,
100
),
dtype
=
torch
.
uint8
))
@
pytest
.
mark
.
skipif
(
IS_MACOS
,
reason
=
"https://github.com/pytorch/vision/issues/8031"
)
@
pytest
.
mark
.
parametrize
(
"img_path"
,
[
pytest
.
param
(
jpeg_path
,
id
=
_get_safe_image_name
(
jpeg_path
))
for
jpeg_path
in
get_images
(
ENCODE_JPEG
,
".jpg"
)],
...
...
@@ -437,6 +439,7 @@ def test_encode_jpeg(img_path):
assert_equal
(
encoded_jpeg_torch
,
encoded_jpeg_pil
)
@
pytest
.
mark
.
skipif
(
IS_MACOS
,
reason
=
"https://github.com/pytorch/vision/issues/8031"
)
@
pytest
.
mark
.
parametrize
(
"img_path"
,
[
pytest
.
param
(
jpeg_path
,
id
=
_get_safe_image_name
(
jpeg_path
))
for
jpeg_path
in
get_images
(
ENCODE_JPEG
,
".jpg"
)],
...
...
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