Invalid validation data. For a recurrent layer with output mode 'last', responses must be a categorical column vector.

조회 수: 1 (최근 30일)
I am trying to train LSTM network following the example given in mathworks entitled "Classify Videos Using Deep Learning". But I am getting an error. I am attaching here the screenshot of the error.
In this screenshot the error is responses must be a categorical column vector. In my case, as you can see in the code (line no. 154) responses are named as labelsTrain. In the workspace you can see labelsTrain is categorical. I am not getting the reason behind this error and hence unable to find a way out of it. Please suggest some solution for this.
If my query is not clear, feel free to comment.

채택된 답변

Walter Roberson
Walter Roberson 2021년 8월 19일
Your Validation Data responses that you are passing through your options is a categorical row vector, but needs to be a categorical column vector.
  댓글 수: 3
Walter Roberson
Walter Roberson 2021년 8월 19일
You transpose the training label data in line 154. That is not the validation data. The validation data is line 149.
NAVNEET NAYAN
NAVNEET NAYAN 2021년 8월 19일
Aah... Got it. I was making a silly mistake. Thank You for your time and response.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Image Data Workflows에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by