[Python] SSL: CERTIFICATE_VERIFY_FAILED when installing TensorFlow Object Detection API on...

Discussão em 'Python' iniciado por Stack, Março 18, 2025.

  1. Stack

    Stack Membro Participativo

    I am trying to install the TensorFlow Object Detection API in a Python virtual environment on Windows 11, but I am getting repeated SSL errors.

    The problem occurs when I run the python setup.py install command in the models/research folder. The output ends with the following errors:

    Installed c:\users\user\projectefratsh\tf2.12_env\lib\site-packages\object_detection-0.1-py3.8.egg
    Processing dependencies for object-detection==0.1
    Searching for sacrebleu<=2.2.0
    Reading https://pypi.org/simple/sacrebleu/
    Download error on https://pypi.org/simple/sacrebleu/: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1108) -- Some packages may not be found!
    Couldn't find index page for 'sacrebleu' (maybe misspelled?)
    Scanning index of all packages (this may take a while)
    Reading https://pypi.org/simple/
    Download error on https://pypi.org/simple/: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1108) -- Some packages may not be found!
    No local packages or working download links found for sacrebleu<=2.2.0
    error: Could not find suitable distribution for Requirement.parse('sacrebleu<=2.2.0')


    More details: OS: Windows 11 Python version: 3.8 pip version: Updated TensorFlow version: 2.10 GPU GPU: : NVIDIA RTX 4050 (supported by TensorFlow GPU)

    Object Detection API: Downloaded from GitHub: https://github.com/tensorflow/models/tree/master/research/object_detection NetFri: I use NetFri web filtering, and it may be causing the problem.

    How can I resolve the SSL error and get pip to validate the pypi.org SSL certificates? Is it necessary to install specific CA certificates for NetFry? Is there an alternative solution to installing the TensorFlow Object Detection API in this situation? Is there a way to check which sites NetFry is blocking? I'm looking for a permanent solution to the SSL issue, not just a temporary one. Thanks in advance for your help!

    Continue reading...

Compartilhe esta Página