フィルターのクリア

Can I extract the ROIs into separate images for classification?

4 ビュー (過去 30 日間)
Michael Cooper-Stachowsky
Michael Cooper-Stachowsky 2017 年 7 月 31 日
If I use the ROI tool to generate a bunch of ROIs, is it possible to extract those ROIs into separate images? It seems to me that some classification schemes, like the example that use HOG features, require separate images. I have one image of a bunch of resistor symbols. Rather than taking a bunch of images, it'd be nice to be able to just extract them from the ROIs themselves.
  2 件のコメント
Cong Ba
Cong Ba 2017 年 7 月 31 日
Could you clarify which ROI tool you are using? I did something like this before and used a script to save those ROIs into separate images. The logic was just like I_ROI = I_original(...) and imwrite(I_ROI). But it seems you are using more advanced tools :/
Michael Cooper-Stachowsky
Michael Cooper-Stachowsky 2017 年 7 月 31 日
I'm using the "Training image labeller" tool. However, I think you might be on to something. If I can extract the ROIs (I think I can...) then I just imwrite? How did you generate the different file names?

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

採用された回答

Cong Ba
Cong Ba 2017 年 7 月 31 日
編集済み: Cong Ba 2017 年 7 月 31 日
Try something like this: (assume you've got your ROIs as seperate matrices, I_ROI_1, I_ROI_2, etc. )
I{1} = I_ROI_1;
I{2} = I_ROI_2;
for i = 1:2
imwrite(I{i}, ['ROI_', num2str(i), '_', datestr(now,'mm-dd HH-MM'),'.jpg']);
end

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeImage Processing Toolbox についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by