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
ColossalAI
Commits
c4928698
Commit
c4928698
authored
Jul 06, 2023
by
klhhhhh
Committed by
Hongxin Liu
Aug 15, 2023
Browse files
[shardformer] vit test finish and support
parent
f60162b2
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
1 deletion
+0
-1
tests/test_shardformer/test_model/test_shard_vit.py
tests/test_shardformer/test_model/test_shard_vit.py
+0
-1
No files found.
tests/test_shardformer/test_model/test_shard_vit.py
View file @
c4928698
...
...
@@ -56,7 +56,6 @@ def check_forward_backward(org_model, sharded_model, data_gen_fn, output_transfo
@
parameterize
(
'enable_tensor_parallelism'
,
[
True
,
False
])
def
run_vit_test
(
enable_fused_normalization
,
enable_tensor_parallelism
):
sub_model_zoo
=
model_zoo
.
get_sub_registry
(
'transformers_vit'
)
print
(
sub_model_zoo
)
for
name
,
(
model_fn
,
data_gen_fn
,
output_transform_fn
,
loss_fn
,
_
)
in
sub_model_zoo
.
items
():
org_model
,
sharded_model
=
build_model
(
model_fn
,
enable_fused_normalization
,
enable_tensor_parallelism
)
check_forward_backward
(
org_model
,
sharded_model
,
data_gen_fn
,
output_transform_fn
,
loss_fn
)
...
...
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