Attempt to grow array along ambiguous dimension.

조회 수: 8 (최근 30일)
William Rerung
William Rerung 2023년 7월 8일
답변: Bruno Luong 2023년 7월 8일
i got error from segmentation hand gesture..i don't know what the mean is. can community give me the solution are??
  댓글 수: 1
Bruno Luong
Bruno Luong 2023년 7월 8일
Do not post screenshot. It is useless for people who wants to reproduce part of the code.

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

답변 (2개)

DGM
DGM 2023년 7월 8일
편집: DGM 2023년 7월 8일
My guess is that either binaryFrame has 3 channels, or handGesture only has 1 channel. Either way, the expanded mask is deeper than the array you're trying to address with the mask. If backgroundModel is RGB, it will force expansion when you take the frame difference.
If it's not that, you'll have to fill us in with actual code and information about the working images.

Bruno Luong
Bruno Luong 2023년 7월 8일
Replace the problematic line of code with
handGesture(repmat(~binaryFrame,1,1,size(handGesture,3))) = 0;

Community Treasure Hunt

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

Start Hunting!

Translated by