'DirectoryIterator' object has no attribute 'num_class'


(Aashish Gulabani) #1

I am trying to run the first model of lesson 1 which is vgg16 model. It runs fine till getting batches and validation batches, but it gives me an error

'DirectoryIterator' object has no attribute 'num_class'

Initially, it gave the same error for nb_class but as suggested on the forum, I changed my vgg16.py file and replaced nb_class with num_class. But the error persists.
I am using Anaconda on python 3+.
Did anyone face similar issue? How do I overcome this error?
TIA


(Aashish Gulabani) #2

@jeremy… can you please help on this?


(Katharina) #3

hey, I had the same issue. You have to use num_classes, checkout the new keras stile for such issues.