Open Source Computer Vision Library
Go to file
Yuantao Feng 4d918ba40b
Merge pull request #23047 from fengyuentau:layer_norm
dnn: add layer normalization for vision transformers

* add layer norm onnx parser, impl and tests

* add onnx graph simplifier for layer norm expanded

* handle the case when constants are of type Initializer

* add test case for layer norm expanded with initializers

* use CV_Assert & CV_CheckType in place of CV_Assert_N; use forward_fallback for OCL_FP16

* use const ref / ref in parameters of invoker::run; extract inner const if from nested loop; use size_t in place of ull

* template hasBias

* remove trailing whitespace

* use pointer parameter with null check; move normSize division & mean_square division outside of loop; use std::max to ensure positive value before std::sqrt

* refactor implementation, optimize parallel_for

* disable layer norm expanded

* remove the removal of layer norm optional outputs
2023-01-27 16:35:59 +03:00
.github Added ARM64 debug configuration to CI. 2022-10-25 13:41:10 +03:00
3rdparty ffmpeg/4.x: update FFmpeg wrapper 2022.12 2022-12-25 18:55:19 +00:00
apps Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2023-01-23 00:11:12 +00:00
cmake Merge pull request #23095 from fengyuentau:fix_omp_macos 2023-01-16 12:44:13 +03:00
data Merge pull request #22727 from su77ungr:patch-1 2022-11-17 06:54:25 +00:00
doc Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2023-01-23 00:11:12 +00:00
include exclude opencv_contrib modules 2020-02-26 15:12:45 +03:00
modules Merge pull request #23047 from fengyuentau:layer_norm 2023-01-27 16:35:59 +03:00
platforms fix typo: stetDictionary to setDictionary 2023-01-08 23:58:54 -06:00
samples Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2023-01-23 00:11:12 +00:00
.editorconfig add .editorconfig 2018-10-11 17:57:51 +00:00
.gitattributes cmake: generate and install ffmpeg-download.ps1 2018-06-09 13:19:48 +03:00
.gitignore Merge pull request #17165 from komakai:objc-binding 2020-06-08 18:32:53 +00:00
CMakeLists.txt dnn: add the CANN backend (#22634) 2022-12-21 09:04:41 +03:00
CONTRIBUTING.md migration: github.com/opencv/opencv 2016-07-12 12:51:12 +03:00
COPYRIGHT copyright: 2023 (update) 2023-01-09 09:49:22 +00:00
LICENSE copyright: 2022 2022-01-04 12:48:27 +00:00
README.md fix 4.x links 2021-12-22 13:24:30 +00:00
SECURITY.md Added SECURITY.md 2019-11-07 13:10:42 +03:00

OpenCV: Open Source Computer Vision Library

Resources

Contributing

Please read the contribution guidelines before starting work on a pull request.

Summary of the guidelines:

  • One pull request per issue;
  • Choose the right base branch;
  • Include tests and documentation;
  • Clean up "oops" commits before submitting;
  • Follow the coding style guide.