For transfer learning I am using a ResNet50 model pre trained on ImageNet. After removing the last layer I want to use outputs of the layer before the last layer (as the last layer is removed by making top = False) as a feature extractor to train a Logistic Regression classifier. I got this UserWarning (mentioned in the question's title) for the line below:
model = ResNet50(weights='imagenet', include_top = False)
Why this is happening?
I got the same problem after giving the "include_top = False". Then first I set "incude_top = True", the dataset is downloaded. After that, I set the "include_top = False", the dataset is downloaded and there is no error.