Hi! I’ve just set up the first notebook, and was executing the cells, but one cell was giving me the error:
AttributeError Traceback (most recent call last)
in ()
2 batches = vgg.get_batches(path + ‘train’, batch_size = batch_size)
3 val_batches = vgg.get_batches(path + ‘valid’, batch_size = batch_size * 2)
----> 4 vgg.finetune(batches)
5 vgg.fit(batches, val_batches, nb_epoch = 1)
~\Documents\Jupyter Notebooks\Assignments\vgg16.py in finetune(self, batches)
175 See definition for get_batches().
176 “”"
–> 177 self.ft(batches.num_class)
178 classes = list(iter(batches.class_indices)) # get a list of all the class labels
179
AttributeError: ‘DirectoryIterator’ object has no attribute ‘num_class’
I tried this but it didn’t change anything. Even changing the vgg16 file line 177 to self.ft(batches.nb_class) but it still gives the same error. Can someone please help me out here?