Question about MATLAB Mask RCNN code from github.
    조회 수: 8 (최근 30일)
  
       이전 댓글 표시
    
Hello, I am trying to test the code, 'Mask RCNN with MATLAB' on the external website, 'https://github.com/matlab-deep-learning/mask-rcnn'. 
I have a question on the function, [rpnTrainingSamples.m] , 41~50 line. 
The code is : 
=====================================================================================
% Sub-sample negative samples to avoid using too much memory.
numPos = sum(positiveIndex);
negIdx = find(negativeIndex);
numNeg = numel(negIdx);
nidx   = params.RandomSelector.randperm(numNeg, min(numNeg, 5000));
% Pack data as int32 to save memory.
regionProposals = int32([regionProposals(positiveIndex, :); regionProposals(nidx, :)]);
anchorIDs       = {int32([anchorIDs(positiveIndex) anchorIDs(nidx)])};
anchorIndices   = {int32([anchorIndices(positiveIndex,:); anchorIndices(nidx,:)])};
=====================================================================================
The above packed data will be used for training samples of RPN. 
However, for the negative samples of regionProposals (and anchorIDs, etc..), those with indices 'nidx' are packed. 
As I know of, the variable 'nidx' is just a randomly shuffled numbers in the range of [1, numNeg]. 
So, I am afraid that 'regionProposals(nidx, :)' may not represent the negative samples but all the samples (positive, negative, ignored). 
Is it right? 
Thank you!
댓글 수: 0
답변 (1개)
  Prabhan Purwar
    
 2021년 8월 6일
        Hi,
Thanks for reporting the issue. As a workaround kindly consider replacing nidx with numNeg(nidx) in the above code. I have bought the issue to the notice of our developer and will try to fix it in future releases.
Thanks
댓글 수: 0
참고 항목
카테고리
				Help Center 및 File Exchange에서 Point Cloud Processing에 대해 자세히 알아보기
			
	Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!