opencv/modules/dnn
Abduragim Shtanchaev d2143bcd44
Merge pull request #23614 from Abdurrahheem:lstm_layout_attribute
LSTM ONNX Layout Attribute Support #23614 

### Explanation

This PR contains necessary changes to support `layout` attribute. This attributes is present in [ONNX](https://github.com/onnx/onnx/blob/main/docs/Operators.md#lstm) and [Torch](https://pytorch.org/docs/stable/generated/torch.nn.LSTM.html#lstm) (in touch it is name as `batch_first=True`) libraries. When `layout = 1` input to LSTM layer is expected to have batch dimension first -> `[batch_size, sequence_length, features]` vs `layout = 0` - default `[sequence_length, batch_size, features]`

### Test Data

Test data and data generator for PR located here [#1063](https://github.com/opencv/opencv_extra/pull/1063)

### 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
- [x] 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
2023-05-17 22:46:56 +03:00
..
cmake dnn: plugin support for OpenVINO 2022-10-07 16:57:31 +00:00
include/opencv2 dnn: refactor reduce (#23613) 2023-05-17 10:03:45 +03:00
misc Update FlatBuffers source code to 23.5.9 2023-05-10 14:39:36 +03:00
perf make 'abcd op 1b11' broadcast support cuda 2023-04-23 17:46:50 +08:00
src Merge pull request #23614 from Abdurrahheem:lstm_layout_attribute 2023-05-17 22:46:56 +03:00
test Merge pull request #23614 from Abdurrahheem:lstm_layout_attribute 2023-05-17 22:46:56 +03:00
CMakeLists.txt Merge pull request #23604 from dkurt:dnn_no_protobuf 2023-05-15 12:23:18 +03:00