フィルターのクリア

What does a colon followed by comma do to an image?

1 回表示 (過去 30 日間)
Recap
Recap 2016 年 3 月 9 日
コメント済み: Recap 2016 年 3 月 14 日
I don't quite understand what the following code is doing.
numFolder=fullfile('NumberZero/','Zero/');
for i=1:10;
numName=sprintf('%d.bmp',i);
image1=imread([numFolder, numName]);
im1(:,:,i)=image1; % what is this line doing?
end

採用された回答

Adam
Adam 2016 年 3 月 9 日
編集済み: Adam 2016 年 3 月 9 日
im1(:,:,i)
means take all elements of your 3d array in the first and 2nd dimensions and only the i'th value in the 3rd dimension.
So basically it turns your data from 3d to 2d in this case by extracting just one slice from the 3rd dimension of a volume.
doc colon
The comma is just the standard syntax for separating the dimensions of your matrix which is why in your case I could easily see that im1 is 3d.
  10 件のコメント
Adam
Adam 2016 年 3 月 14 日
I'm not really familiar with neural networks so I'm not sure I would be able to help with that.
Recap
Recap 2016 年 3 月 14 日
The code is there and general comments of what its doing. except that i dont get what its exactly the algorithms are doing because im not familiar with matlab syntax. You can have a look at it from my dropbox if your interested.
https://www.dropbox.com/s/gg0fnxewv72od17/NeuroTrainingNumbers.m?dl=0

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeImage Data Workflows についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by