no such option: –use-feature while installing tensorflow object detection api

Question:

I’m trying to install Tensorflow Object Detection API, following the steps at this link, which is the official installation’s documentation for Tensorflow 2.

git clone https://github.com/tensorflow/models.git
> everything is ok
cd models/research/
> everything is ok
protoc object_detection/protos/*.proto --python_out=.
> everything is ok
cp object_detection/packages/tf2/setup.py .
> everything is ok
python -m pip install --use-feature=2020-resolver .

> Usage:   
>   /opt/anaconda3/envs/ml/bin/python -m pip install [options] <requirement specifier> [package-> index-options] ...
>   /opt/anaconda3/envs/ml/bin/python -m pip install [options] -r <requirements file> [package-index-options] ...
>   /opt/anaconda3/envs/ml/bin/python -m pip install [options] [-e] <vcs project url> ...
>   /opt/anaconda3/envs/ml/bin/python -m pip install [options] [-e] <local project path> ...
>   /opt/anaconda3/envs/ml/bin/python -m pip install [options] <archive url/path> ...

> no such option: --use-feature

Can someone help me understand why the installation stops as it does? I’m using macOS Mojave, Python 3.6 (on a conda virtual env), and Tensorflow 2.3.0.

Asked By: Giuppox

||

Answers:

just needed to upgrade pip from version 20.0.2 to 20.2.2. An issue on github has also been opened (here)

Answered By: Giuppox

I had the same problem, I upgraded pip version from 20.0.2 to 20.2.2, then it worked.

An issue was opened on github on this matter, check here.

Use python -m pip install --upgrade pip to upgrade pip.

Answered By: Catalina Chircu

For the Tensorflow installation, you can simply remove this option and use:

python -m pip install .

Read this:

pip 20.1 included an alpha version of the new resolver (hidden behind an optional –unstable-feature=resolver flag). pip 20.2 removes that flag, and includes a robust beta of the new resolver (hidden behind an optional –use-feature=2020-resolver flag) that we encourage you to test. We will continue to improve the pip dependency resolver in response to testers’ feedback. Please give us feedback through the resolver testing survey. This will help us prepare to release pip 20.3, with the new resolver on by default, in October.

Answered By: Nicolas Gervais

This is what i did and it worked

python -m pip install –user –use-feature=fast-deps .

Answered By: Sibonginkosi Nkashe