How do I create a "TimeDistributed TensorFlow-Keras" deep network layer in MATLAB?

조회 수: 7 (최근 30일)
I am trying to create a neural network that performs sequence-to-sequence classification and would like to create the equivalent of a "TimeDistributed TensorFlow-Keras" deep network layer. How can I create such a layer in MATLAB?

채택된 답변

MathWorks Support Team
MathWorks Support Team 2024년 1월 8일
A "TimeDistributed TensorFlow-Keras" deep network layer can be implemented in MATLAB by wrapping an operation between "sequenceFoldingLayer" and "sequenceUnfoldingLayer" layers from the Deep Learning Toolbox.
1. The "sequenceFoldingLayer" layer brings the batch and time dimensions to a single batch dimension. Please refer to the following documentation page for more information on the layer: 
2. The operation (e.g., a fully connected layer) will be time-distributed since these operations are independent for each batch, and the time dimension is now wrapped in the batch dimension.
3. The "sequenceUnfoldingLayer" layer reintroduces the time dimension by reverting the collapse operation in the sequence folding layer. Please refer to the following documentation page for more information on the layer: 

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Deep Learning Toolbox에 대해 자세히 알아보기

제품


릴리스

R2023b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by