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
mmgeneration
Commits
c9a48a52
Commit
c9a48a52
authored
Jun 16, 2025
by
limm
Browse files
add tests code
parent
b7536f78
Pipeline
#2778
canceled with stages
Changes
64
Pipelines
1
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
307 additions
and
0 deletions
+307
-0
tests/test_modules/test_wgangp_archs.py
tests/test_modules/test_wgangp_archs.py
+185
-0
tests/test_ops/test_conv_gradfix.py
tests/test_ops/test_conv_gradfix.py
+48
-0
tests/test_ops/test_stylegan3_ops.py
tests/test_ops/test_stylegan3_ops.py
+62
-0
tests/test_utils/test_io_utils.py
tests/test_utils/test_io_utils.py
+12
-0
No files found.
tests/test_modules/test_wgangp_archs.py
0 → 100644
View file @
c9a48a52
This diff is collapsed.
Click to expand it.
tests/test_ops/test_conv_gradfix.py
0 → 100644
View file @
c9a48a52
This diff is collapsed.
Click to expand it.
tests/test_ops/test_stylegan3_ops.py
0 → 100644
View file @
c9a48a52
This diff is collapsed.
Click to expand it.
tests/test_utils/test_io_utils.py
0 → 100644
View file @
c9a48a52
# Copyright (c) OpenMMLab. All rights reserved.
import
os
from
tempfile
import
TemporaryDirectory
from
mmgen.utils
import
download_from_url
def
test_download_from_file
():
img_url
=
'https://user-images.githubusercontent.com/12726765/114528756-de55af80-9c7b-11eb-94d7-d3224ada1585.png'
# noqa
with
TemporaryDirectory
()
as
temp_dir
:
local_file
=
download_from_url
(
url
=
img_url
,
dest_dir
=
temp_dir
)
assert
os
.
path
.
exists
(
local_file
)
Prev
1
2
3
4
Next
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