"vscode:/vscode.git/clone" did not exist on "8f163b16533bc272cb24a93dd44699b386d0642c"
Unverified Commit c1588f00 authored by derekjchow's avatar derekjchow Committed by GitHub
Browse files

Merge pull request #4761 from sauercrowd/doc-object_detection-proto_installation

Object detection: Added explanation how to manually download and use protoc
parents 4a0ee4a2 7e56d628
...@@ -48,15 +48,14 @@ pip install --user jupyter ...@@ -48,15 +48,14 @@ pip install --user jupyter
pip install --user matplotlib pip install --user matplotlib
``` ```
Note that sometimes "sudo apt-get install protobuf-compiler" will install **Note**: sometimes "sudo apt-get install protobuf-compiler" will install
Protobuf 3+ versions for you and some users have issues when using 3.5. Protobuf 3+ versions for you and some users have issues when using 3.5.
If that is your case, you're suggested to download and install Protobuf 3.0.0 If that is your case, try the [manual](#Manual-protobuf-compiler-installation-and-usage) installation.
(available [here](https://github.com/google/protobuf/releases/tag/v3.0.0)).
## COCO API installation ## COCO API installation
Download the Download the
<a href="https://github.com/cocodataset/cocoapi" target=_blank>cocoapi</a> and [cocoapi](https://github.com/cocodataset/cocoapi) and
copy the pycocotools subfolder to the tensorflow/models/research directory if copy the pycocotools subfolder to the tensorflow/models/research directory if
you are interested in using COCO evaluation metrics. The default metrics are you are interested in using COCO evaluation metrics. The default metrics are
based on those used in Pascal VOC evaluation. To use the COCO object detection based on those used in Pascal VOC evaluation. To use the COCO object detection
...@@ -85,6 +84,23 @@ the tensorflow/models/research/ directory: ...@@ -85,6 +84,23 @@ the tensorflow/models/research/ directory:
protoc object_detection/protos/*.proto --python_out=. protoc object_detection/protos/*.proto --python_out=.
``` ```
**Note**: If you're getting errors while compiling, you might be using an incompatible protobuf compiler. If that's the case, use the following manual installation
## Manual protobuf-compiler installation and usage
Download and install the 3.0 release of protoc, then unzip the file.
```bash
# From tensorflow/models/research/
wget -O protobuf.zip https://github.com/google/protobuf/releases/download/v3.0.0/protoc-3.0.0-linux-x86_64.zip
unzip protobuf.zip
```
Run the compilation process again, but use the downloaded version of protoc
```bash
# From tensorflow/models/research/
./bin/protoc object_detection/protos/*.proto --python_out=.
```
## Add Libraries to PYTHONPATH ## Add Libraries to PYTHONPATH
When running locally, the tensorflow/models/research/ and slim directories When running locally, the tensorflow/models/research/ and slim directories
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment