Solved by Nikronic in post #2 
              
              
                I have asked something similar to your question and I find out writing a custom dataset based on Dataset abstract class is the best idea and fastest! 
This is a sample as an answer to my question: 
 
 
And if you are in full implemented of my work, here is the link to my Github of a simple CNN for e…