pythonpipvideo-intelligence-api

Cannot install google-cloud-videointelligence package


I'm trying to install Google Cloud's Video Intelligence library for Python. However, when I run the command:

pip install --upgrade google-cloud-videointelligence

I get the following error:

(video_labeler) PS C:\path> pip install google-cloud-videointelligence
Collecting google-cloud-videointelligence
  Using cached https://files.pythonhosted.org/packages/f0/32/4518904fb73fa8264c6e827df6c062e3c62b0a6dc7eb34a35b7e60d3ed93/google_cloud_videointelligence-1.11.0-py2.py3-none-any.whl
Requirement already satisfied: google-api-core[grpc]<2.0.0dev,>=1.14.0 in c:\path\lib\site-packages (from google-cloud-videointelligence) (1.14.3)
Requirement already satisfied: six>=1.10.0 in c:\path\lib\site-packages (from google-api-core[grpc]<2.0.0dev,>=1.14.0->google-cloud-videointelligence) (1.12.0)
Requirement already satisfied: protobuf>=3.4.0 in c:\path\lib\site-packages (from google-api-core[grpc]<2.0.0dev,>=1.14.0->google-cloud-videointelligence) (3.10.0)
Requirement already satisfied: requests<3.0.0dev,>=2.18.0 in c:\path\lib\site-packages (from google-api-core[grpc]<2.0.0dev,>=1.14.0->google-cloud-videointelligence) (2.22.0)
Requirement already satisfied: pytz in c:\path\lib\site-packages (from google-api-core[grpc]<2.0.0dev,>=1.14.0->google-cloud-videointelligence) (2019.3)
Requirement already satisfied: setuptools>=34.0.0 in c:\path\lib\site-packages (from google-api-core[grpc]<2.0.0dev,>=1.14.0->google-cloud-videointelligence) (40.8.0)
Requirement already satisfied: googleapis-common-protos<2.0dev,>=1.6.0 in c:\path\lib\site-packages (from google-api-core[grpc]<2.0.0dev,>=1.14.0->google-cloud-videointelligence) (1.6.0)
Requirement already satisfied: google-auth<2.0dev,>=0.4.0 in c:\path\lib\site-packages (from google-api-core[grpc]<2.0.0dev,>=1.14.0->google-cloud-videointelligence) (1.6.3)
Requirement already satisfied: grpcio<2.0dev,>=1.8.2; extra == "grpc" in c:\path\lib\site-packages (from google-api-core[grpc]<2.0.0dev,>=1.14.0->google-cloud-videointelligence) (1.24.1)
Requirement already satisfied: urllib3!=1.25.0,!=1.25.1,<1.26,>=1.21.1 in c:\path\lib\site-packages (from requests<3.0.0dev,>=2.18.0->google-api-core[grpc]<2.0.0dev,>=1.14.0->google-cloud-videointelligence) (1.25.6)
Requirement already satisfied: chardet<3.1.0,>=3.0.2 in c:\path\lib\site-packages (from requests<3.0.0dev,>=2.18.0->google-api-core[grpc]<2.0.0dev,>=1.14.0->google-cloud-videointelligence) (3.0.4)
Requirement already satisfied: certifi>=2017.4.17 in c:\path\lib\site-packages (from requests<3.0.0dev,>=2.18.0->google-api-core[grpc]<2.0.0dev,>=1.14.0->google-cloud-videointelligence) (2019.9.11)
Requirement already satisfied: idna<2.9,>=2.5 in c:\path\lib\site-packages (from requests<3.0.0dev,>=2.18.0->google-api-core[grpc]<2.0.0dev,>=1.14.0->google-cloud-videointelligence) (2.8)
Requirement already satisfied: pyasn1-modules>=0.2.1 in c:\path\lib\site-packages (from google-auth<2.0dev,>=0.4.0->google-api-core[grpc]<2.0.0dev,>=1.14.0->google-cloud-videointelligence) (0.2.7)
Requirement already satisfied: cachetools>=2.0.0 in c:\path\lib\site-packages (from google-auth<2.0dev,>=0.4.0->google-api-core[grpc]<2.0.0dev,>=1.14.0->google-cloud-videointelligence) (3.1.1)
Requirement already satisfied: rsa>=3.1.4 in c:\path\lib\site-packages (from google-auth<2.0dev,>=0.4.0->google-api-core[grpc]<2.0.0dev,>=1.14.0->google-cloud-videointelligence) (4.0)
Requirement already satisfied: pyasn1<0.5.0,>=0.4.6 in c:\path\lib\site-packages (from pyasn1-modules>=0.2.1->google-auth<2.0dev,>=0.4.0->google-api-core[grpc]<2.0.0dev,>=1.14.0->google-cloud-videointelligence) (0.4.7)
Installing collected packages: google-cloud-videointelligence
ERROR: Could not install packages due to an EnvironmentError: [Errno 2] No such file or directory: 'c:\\path\\Lib\\site-packages\\google\\cloud\\videointelligence_v1p1beta1\\gapic\\transports\\__pycache__\\video_intelligence_service_grpc_transport.cpython-37.pyc'

This is being run in a virtualenv based on Python 3.7.

Help to fixing this will be greatly appreciated.


Solution

  • try installing in a virtualenv

    Mac/Linux

    pip install virtualenv
    virtualenv <your-env>
    source <your-env>/bin/activate
    <your-env>/bin/pip install google-cloud-videointelligence
    

    Windows

    pip install virtualenv
    virtualenv <your-env>
    <your-env>\Scripts\activate
    <your-env>\Scripts\pip.exe install google-cloud-videointelligence