ctpn

Use Case and High-Level Description

Detecting Text in Natural Image with Connectionist Text Proposal Network. For details see paper.

Specification

Metric

Value

Type

Object detection

GFlops

55.813

MParams

17.237

Source framework

TensorFlow*

Accuracy

Metric

Value

hmean

73.67%

Input

Original Model

Image, name: image_tensor, shape: 1, 600, 600, 3, format: B, H, W, C, where:

  • B - batch size

  • H - image height

  • W - image width

  • C - number of channels

Expected color order: BGR. Mean values: [102.9801, 115.9465, 122.7717].

Converted Model

Image, name: Placeholder, shape: 1, 3, 600, 600, format: B, C, H, W, where:

  • B - batch size

  • C - number of channels

  • H - image height

  • W - image width

Expected color order: BGR.

Output

Original Model

  1. Detection boxes, name: rpn_bbox_pred/Reshape_1, contains predicted regions, in format B, H, W, A, where:

    • B - batch size

    • H - image height

    • W - image width

    • A - vector of 4*N coordinates, where N is the number of detected anchors.

  2. Probability, name: Reshape_2, contains probabilities for predicted regions in a [0,1] range in format B, H, W, A, where:

    • B - batch size

    • H - image height

    • W - image width

    • A - vector of 4*N coordinates, where N is the number of detected anchors.

Converted Model

  1. Detection boxes, name: rpn_bbox_pred/Reshape_1/Transpose, shape: 1, 40, 18, 18 contains predicted regions, format: B, A, H, W, where:

    • B - batch size

    • A - vector of 4*N coordinates, where N is the number of detected anchors.

    • H - image height

    • W - image width

  2. Probability, name: Reshape_2/Transpose, shape: 1, 20, 18, 18, contains probabilities for predicted regions in a[0,1] range in format B, A, H, W, where:

    • B - batch size

    • A - vector of 2*N class probabilities (0 class for background, 1 class for text), where N is the number of detected anchors.

    • H - image height

    • W - image width

Download a Model and Convert it into Inference Engine Format

You can download models and if necessary convert them into Inference Engine format using the Model Downloader and other automation tools as shown in the examples below.

An example of using the Model Downloader:

python3 <omz_dir>/tools/downloader/downloader.py --name <model_name>

An example of using the Model Converter:

python3 <omz_dir>/tools/downloader/converter.py --name <model_name>