Sampling from an image file without replacement

I have an image file of several hundred images and I need to sample and save 70 of these images without replacement and save them for use later in the experiment. How do I go about doing this?

Antworten (1)

Jos (10584)
Jos (10584) am 18 Mai 2018

0 Stimmen

% select 70 random indices without replacement between 1 and numImages
imIDX = randperm(numImages, 70) ;
for K = imIDX
% process image K
end

Kategorien

Mehr zu Environment and Settings finden Sie in Hilfe-Center und File Exchange

Gefragt:

am 17 Mai 2018

Beantwortet:

am 18 Mai 2018

Community Treasure Hunt

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

Start Hunting!

Translated by