Optimize an R-FCN Int8 Inference TensorFlow* Model Package

Published: 11/09/2020  

Last Updated: 06/15/2022

Download Command

wget https://storage.googleapis.com/intel-optimized-tensorflow/models/v2_3_0/rfcn-int8-inference.tar.gz

Description

The COCO validation dataset is used in these R-FCN quick start scripts. The inference quick start scripts use raw images, and the accuracy quick start scripts require the dataset to be converted into the TF records format. See the COCO dataset for instructions on downloading and preprocessing the COCO validation dataset.

Quick Start Scripts

Script name Description
int8_inference Runs inference on a directory of raw images for 500 steps and outputs performance metrics.
int8_accuracy Processes the TF records to run inference and check accuracy on the results.

Bare Metal

To run on bare metal, the following prerequisites must be installed in your environment:

git clone https://github.com/tensorflow/models.git tensorflow-models
cd tensorflow-models
git checkout 6c21084503b27a9ab118e1db25f79957d5ef540b
git apply ../rfcn-int8-inference/models/object_detection/tensorflow/rfcn/inference/tf-2.0.patch

You must also install the dependencies and run the protobuf compilation described in the object detection installation instructions from the TensorFlow Model Garden Repository.

After installing the prerequisites, download and untar the model package.

wget https://storage.googleapis.com/intel-optimized-tensorflow/models/v2_3_0/rfcn-int8-inference.tar.gz
tar -xzf rfcn-int8-inference.tar.gz

Set environment variables for the TensorFlow Model Garden directory to TF_MODELS_DIR, the path to your DATASET_DIR and an OUTPUT_DIR where log files will be written, then run a quick start script.

To run inference with performance metrics:

DATASET_DIR=<path to the coco val2017 directory>
OUTPUT_DIR=<directory where log files will be written>
TF_MODELS_DIR=<directory where TensorFlow Model Garden is cloned>

cd rfcn-int8-inference
quickstart/int8_inference.sh

To get accuracy metrics:

DATASET_DIR=<path to the COCO validation TF record directory>
OUTPUT_DIR=<directory where log files will be written>
TF_MODELS_DIR=<directory where TensorFlow Model Garden is cloned>

cd rfcn-int8-inference
quickstart/int8_accuracy.sh

 

Documentation and Sources

Get Started​
Main GitHub*
Readme
Release Notes
Get Started Guide

Code Sources
Report Issue


License Agreement

LEGAL NOTICE: By accessing, downloading or using this software and any required dependent software (the “Software Package”), you agree to the terms and conditions of the software license agreements for the Software Package, which may also include notices, disclaimers, or license terms for third party software included with the Software Package. Please refer to the license file for additional details.


Related Containers and Solutions

R-FCN Int8 Inference TensorFlow* Container

View All Containers and Solutions 🡢

 

Product and Performance Information

1

Performance varies by use, configuration and other factors. Learn more at www.Intel.com/PerformanceIndex.