tensorflow / tensorflow/models

object_detection package install fails

Open
#13,558 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

models:research type:bug
Dominant language
Python
Stars
77.7k
Forks
44.8k
PR merge metrics
No merged PRs in 30d

Description

Prerequisites

Please answer the following questions for yourself before submitting an issue.

  • [ +] I am using the latest TensorFlow Model Garden release and TensorFlow 2.
  • [ +] I am reporting the issue to the correct repository. (Model Garden official or research directory)
  • [+ ] I checked to make sure that this issue has not already been filed.

1. The entire URL of the file you are using

https://github.com/tensorflow/models/blob/master/research/object_detection/packages/tf2/setup.py

2. Describe the bug

Setup for object_detection package fails because of incompatible dependencies, even in simple colab with errors of:

TypeError: Descriptors cannot be created directly.
If this call came from a _pb2.py file, your generated code is out of date and must be regenerated with protoc >= 3.19.0.

3. Steps to reproduce

cd models/research/
protoc object_detection/protos/*.proto --python_out=.
cp object_detection/packages/tf2/setup.py .
python -m pip install .

python /content/models/research/object_detection/builders/model_builder_tf2_test.py

https://colab.research.google.com/drive/1krnCXwHeRqROVrXn55_wtHm5NWydJnXk#scrollTo=u3-XpvyWiCSB

6. System information

default google colab notebook like following:
https://colab.research.google.com/drive/1krnCXwHeRqROVrXn55_wtHm5NWydJnXk#scrollTo=u3-XpvyWiCSB

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with research/object_detection/packages/tf2/setup.py and reproduce the installation in the provided Google Colab steps. Then run object_detection/builders/model_builder_tf2_test.py to confirm the dependency failure and verify that installation succeeds without the reported protobuf error.

Written by the indexing model from the issue text.

Assessment

Tech stack
python, tensorflow
Domain
build-system
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.