title: Train CNN model with multiple folders and sub-folders
body: <p>I am developing a convolution neural network (CNN) model to predict whether a patient in category 1,2,3 or 4. I use Keras on top of TensorFlow.</p>
  
  <p>I have 64 breast cancer patient data, classified into four category (1=no disease, 2= …., 3=….., 4=progressive disease). In each patient's data, I have 3 set of MRI scan images taken at different dates and inside each MRI folder, I have 7 to 8 sub folders containing MRI images in different plane (such as coronal plane/sagittal plane etc). </p>
  
  <p>I learned how to deal with basic “Cat-Dog-CNN-Classifier”, it was easy as I put all the cat &amp; dog images into a single folder to train the network. But how do I tackle the problem in my breast cancer patient data? It has multiple folders and sub-solders.</p>
  
  <p>Please suggest.</p>