Split an ImageDatastore with every 'pth' file per label
    3 Ansichten (letzte 30 Tage)
  
       Ältere Kommentare anzeigen
    
    kowshik Thopalli
      
 am 26 Feb. 2017
  
    
    
    
    
    Beantwortet: Ankita Nargundkar
    
      
 am 6 Mär. 2017
            Hi, the splitEachLabel() for the imageDatastore() when used as
if true
  [imds1,imds2] = splitEachLabel(imds,p)
end
the code above, if p is an integer, the new datastore imds1 contains the first p files from each label and imds2 contains the remaining files from each label. However, I wish to divide my Image Datastore into two data stores the first one with every 'p'th file from each label. I.e., if p=2 every second file of the label should be stored in imds1 and the rest in imds2. How to do this?
0 Kommentare
Akzeptierte Antwort
  Ankita Nargundkar
    
      
 am 6 Mär. 2017
        There is no built option to do this. You will have to write custom function.splitEachValue method is works on ImageDataStore class. So, you can create a custom function and pass the ImageDataStore object into it and inside the function implementation you can access the IDS object and create new IDSs based on his requirement
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
				Mehr zu Get Started with Deep Learning Toolbox finden Sie in Help Center und File Exchange
			
	Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!

