opencv/modules/dnn/perf
alexlyulkov aa52dafc90
Merge pull request #26127 from alexlyulkov:al/blob-from-images
Faster implementation of blobFromImages for cpu nchw output #26127

Faster implementation of blobFromImage and blobFromImages for
HWC cv::Mat images -> NCHW cv::Mat
case

Running time on my pc in ms:

**blobFromImage**
```
image size            old        new   speed-up
32x32x3             0.008      0.002       4.0x
64x64x3             0.021      0.009       2.3x
128x128x3           0.164      0.037       4.4x
256x256x3           0.728      0.158       4.6x
512x512x3           3.310      0.628       5.2x
1024x1024x3        14.503      3.124       4.6x
2048x2048x3        61.647     28.049       2.2x
```

**blobFromImages**
```
image size            old        new   speed-up
16x32x32x3          0.122      0.041       3.0x
16x64x64x3          0.790      0.165       4.8x
16x128x128x3        3.313      0.652       5.1x
16x256x256x3       13.495      3.127       4.3x
16x512x512x3       58.795     28.127       2.1x
16x1024x1024x3    251.135    121.955       2.1x
16x2048x2048x3   1023.570    487.188       2.1x
```


### Pull Request Readiness Checklist

See details at https://github.com/opencv/opencv/wiki/How_to_contribute#making-a-good-pull-request

- [x] I agree to contribute to the project under Apache 2 License.
- [x] To the best of my knowledge, the proposed patch is not based on a code under GPL or another license that is incompatible with OpenCV
- [x] The PR is proposed to the proper branch
- [ ] There is a reference to the original bug report and related work
- [ ] There is accuracy test, performance test and test data in opencv_extra repository, if applicable
      Patch to opencv_extra has the same branch name.
- [x] The feature is well documented and sample code can be built with the project CMake
2024-12-23 10:04:34 +03:00
..
perf_caffe.cpp Merge pull request #24120 from dkurt:actualize_dnn_links 2023-08-16 15:46:11 +03:00
perf_common.cpp cmake: fix build of dnn tests with shared common code 2019-03-31 08:52:25 +00:00
perf_convolution1d.cpp Merge pull request #18783 from sl-sergei:fix_conv1d 2020-11-13 22:22:10 +00:00
perf_convolution3d.cpp Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2020-11-13 22:29:14 +00:00
perf_convolution.cpp dnn(test): skip very long debug tests, reduce test time 2023-12-25 08:44:06 +00:00
perf_einsum.cpp Merge pull request #24509 from Abdurrahheem:ash/dev_einsum_fast_gemm 2023-11-16 16:20:17 +03:00
perf_gemm.cpp Merge pull request #24694 from fengyuentau:matmul_refactor 2023-12-19 19:36:41 +03:00
perf_layer.cpp Merge pull request #23279 from fengyuentau:add_topk 2024-08-21 17:03:24 +03:00
perf_main.cpp build: made environment access a separate feature 2024-10-30 18:37:22 +03:00
perf_net.cpp Fix proto and weights mess in dnn performance tests. 2024-02-07 09:16:09 +03:00
perf_precomp.hpp dnn(perf): fix and merge Convolution tests 2018-08-31 15:02:19 +03:00
perf_recurrent.cpp Merge pull request #20658 from smbz:lstm_optimisation 2021-11-29 21:43:00 +00:00
perf_utils.cpp Merge pull request #26127 from alexlyulkov:al/blob-from-images 2024-12-23 10:04:34 +03:00