    def get_validation_batches(self, batch_size):
        """ Returns a batch for each image in the validation set. """
        
        if self.n_validation_samples:
            batches = []
            for idx in range(self.n_validation_samples):
                batches.append(self.get_batch(batch_size, idx, flatness=0.0))
            return batches
        else:
            self.logger.error(
                'No validation set size specified. (not operating in a validation set?)'
            )
            raise ValueError(
                'No validation set size specified. (not operating in a validation set?)'
            )
Returns a batch for each image in the validation set.
ISR/utils/datahandler.py