Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add GroupNorm forward operation #2623

Merged
merged 42 commits into from
Jan 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
42 commits
Select commit Hold shift + click to select a range
90d6426
add groupnorm
kyeonghwanryu Dec 6, 2023
f488624
fix failing driver
kyeonghwanryu Dec 7, 2023
65db841
rename miopenLayerNormMode_t to miopenNormMode_t
kyeonghwanryu Dec 8, 2023
75bae98
add groupnorm doc
kyeonghwanryu Dec 8, 2023
a135310
rename norm solver directory to layernorm
kyeonghwanryu Dec 8, 2023
a2061bf
rename norm to layernorm
kyeonghwanryu Dec 8, 2023
fc860c8
make groupnorm use solver
kyeonghwanryu Dec 11, 2023
100e4f1
fix wrong type for num_groups
kyeonghwanryu Dec 11, 2023
3852629
fix typo
kyeonghwanryu Dec 14, 2023
3022c03
update local wk dim
kyeonghwanryu Dec 14, 2023
af48e8c
fix local mem size check
kyeonghwanryu Dec 14, 2023
375def1
add size condition to solver
kyeonghwanryu Dec 14, 2023
efa309d
fix test failure
kyeonghwanryu Dec 18, 2023
cef6e7c
remove .gitignore
kyeonghwanryu Dec 20, 2023
06ab15b
add groupnorm
kyeonghwanryu Dec 6, 2023
f97e759
fix failing driver
kyeonghwanryu Dec 7, 2023
76f2c62
rename miopenLayerNormMode_t to miopenNormMode_t
kyeonghwanryu Dec 8, 2023
e3612ce
add groupnorm doc
kyeonghwanryu Dec 8, 2023
bd33522
rename norm solver directory to layernorm
kyeonghwanryu Dec 8, 2023
52beeac
rename norm to layernorm
kyeonghwanryu Dec 8, 2023
f681374
make groupnorm use solver
kyeonghwanryu Dec 11, 2023
e5059b3
fix wrong type for num_groups
kyeonghwanryu Dec 11, 2023
e7c8e71
fix typo
kyeonghwanryu Dec 14, 2023
67a3555
update local wk dim
kyeonghwanryu Dec 14, 2023
0cb16fe
fix local mem size check
kyeonghwanryu Dec 14, 2023
fc8cb18
add size condition to solver
kyeonghwanryu Dec 14, 2023
a01e808
fix test failure
kyeonghwanryu Dec 18, 2023
12befaf
remove .gitignore
kyeonghwanryu Dec 20, 2023
1081c25
Merge branch 'impl_groupnorm' of https://github.com/ROCmSoftwarePlatf…
kyeonghwanryu Dec 21, 2023
520f682
apply clang-format
kyeonghwanryu Dec 21, 2023
cb1b93d
fix docs error
kyeonghwanryu Dec 21, 2023
0e00c3f
Merge branch 'develop' into impl_groupnorm
junliume Dec 22, 2023
cf6c33a
modify groupnorm applicable condition
kyeonghwanryu Jan 8, 2024
a428264
apply review comments
kyeonghwanryu Jan 9, 2024
202ccd8
add groupnorm description in docs
kyeonghwanryu Jan 12, 2024
ece1e83
apply review comments
kyeonghwanryu Jan 16, 2024
882037d
Merge branch 'develop' into impl_groupnorm
kyeonghwanryu Jan 16, 2024
8d74e04
Merge branch 'develop' into impl_groupnorm
junliume Jan 17, 2024
f65ae77
fix tiny clang format issue
junliume Jan 17, 2024
66ff289
apply review comments
kyeonghwanryu Jan 23, 2024
0adc0b7
Merge branch 'develop' into impl_groupnorm
kyeonghwanryu Jan 23, 2024
bb0f5ba
Merge branch 'develop' into impl_groupnorm
kyeonghwanryu Jan 30, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions docs/apireference.rst
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,5 @@ API Reference
layernorm
sum
argmax
groupnorm

20 changes: 20 additions & 0 deletions docs/groupnorm.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@

GroupNorm Layer(experimental)
=============================

The groupnorm types and functions.
It splits input channels into num_group groups and do normalize for each group.

To enable this, define MIOPEN_BETA_API before including miopen.h.


miopenNormMode_t
-----------------------

.. doxygenenum:: miopenNormMode_t

miopenGroupNormForward
----------------------------------

.. doxygenfunction:: miopenGroupNormForward

4 changes: 2 additions & 2 deletions docs/layernorm.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ The layernorm types and functions.
To enable this, define MIOPEN_BETA_API before including miopen.h.


miopenLayerNormMode_t
miopenNormMode_t
-----------------------

.. doxygenenum:: miopenLayerNormMode_t
.. doxygenenum:: miopenNormMode_t

miopenLayerNormForward
----------------------------------
Expand Down
3 changes: 2 additions & 1 deletion driver/driver.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ inline void PadBufferSize(size_t& sz, int datatype_sz)
"pool[fp16], lrn[fp16], "
"activ[fp16], softmax[fp16], bnorm[fp16], rnn[fp16], gemm[fp16], ctc, dropout[fp16], "
"tensorop[fp16], reduce[fp16|fp64], layernorm[bfp16|fp16], sum[bfp16|fp16], "
"argmax[bfp16|fp16]\n");
"argmax[bfp16|fp16], groupnorm[bfp16|fp16]\n");
exit(0); // NOLINT (concurrency-mt-unsafe)
}

Expand All @@ -175,6 +175,7 @@ inline std::string ParseBaseArg(int argc, char* argv[])
arg != "reduce" && arg != "reducefp16" && arg != "reducefp64" && arg != "layernorm" &&
arg != "layernormfp16" && arg != "layernormbfp16" && arg != "sum" && arg != "sumfp16" &&
arg != "sumbfp16" && arg != "argmax" && arg != "argmaxfp16" && arg != "argmaxbfp16" &&
arg != "groupnorm" && arg != "groupnormfp16" && arg != "groupnormbfp16" &&
arg != "--version")
{
printf("FAILED: Invalid Base Input Argument\n");
Expand Down
Loading