Reputation: 11
I tried to import keras-vggface
like this:
from keras_vggface.vggface import VGGFace
But it always gives me this error
"ModuleNotFoundError: No module named 'keras_vggface".
I tried to install keras_vggface
with pip like this:
!pip install --user keras-vggface
!pip install keras-vggface
!pip install git+https://github.com/rcmalli/keras-vggface.git
Upvotes: 0
Views: 5916
Reputation: 451
Struggling with VGGFace use in colab as well, resolved your problem by specifying in colab tensor flow x1 with %tensorflow_version 1.x
as informed by colab warning VGGFace git:
"VGGFAce works only with 1.x TensorFlow backend AND without eager execution!!!"
EDIT: but you have to properly call !pip install keras_vggface
first
Upvotes: 0
Reputation: 698
I think you need to install it as below:
!pip install keras_vggface
this works like a charm. Hope it can be useful.
Upvotes: 2