GET get_text

Given a list of image file paths, retrieve the associated text data from the index.

Resource URL

https://wineengine.tineye.com/<company>/rest/get_text/

Notes

The text data returned for each image will include the text lines and their location information so that you can highlight them in your images.

The locations returned by WineEngine will always refer to the image stored in the index and are provided as bounding boxes described using four corners.

Please note that if your image has solid color borders, those might be cropped out by WineEngine. In that case the locations returned will only refer to the cropped version of the image.

Each request accepts maximum 10 filepaths.

Parameters

In addition to the Common parameters there are:

Filepath

Key

Description

filepath

Text data will be returned for this filepath.

Filepaths

Key

Description

filepaths[0]

Text data will be returned for this filepath.

filepaths[n] (optional)

Text data will be returned for this filepath.

Request example

curl https://wineengine.tineye.com/<company>/rest/get_text/   \
     -d "filepath=path/folder/1.jpg"

or

curl https://wineengine.tineye.com/<company>/rest/get_text/   \
     -d "filepaths[0]=path/folder/image1.jpg"                 \
     -d "filepaths[1]=path/folder/image2.jpg"

Response examples

JSON

{
    "method": "get_text",
    "status": "ok",
    "error": [],
    "result": [
        {
            "filepath": "path/folder/image1.jpg",
            "text_lines": [
                "LOUIS JADOT",
                "2015",
                "FONDEE EN 1859",
                "BOURGOGNE",
                "PINOT NOIR"
           ]
        },
        {
            "filepath": "path/folder/image2.jpg",
            "text_lines": [
                "Beronia",
                "RIOJA",
                "DENOMINACIÓN DE ORIGEN CALIFICADA",
                "Product of Spain",
                "TEMPRANILLO",
                "2013",
                "BOTTLED BY/MIS ENBOUTEILLE PAR",
                "Bodegas Beronia",
                "OLLAURI-ESPAÑA",
                "RE.5229-LO"
            ]
        }
    ],
    "stats": {
        "time_get_text": 4.29,
        "time_total": 4.75
    }
}

XML

<?xml version="1.0" encoding="utf-8"?>
<data>
    <method>get_text</method>
    <status>ok</status>
    <error/>
    <result>
        <item>
            <filepath>path/folder/image1.jpg</filepath>
            <text_lines>
                <item>LOUIS JADOT</item>
                <item>2015</item>
                <item>FONDEE EN 1859</item>
                <item>BOURGOGNE</item>
                <item>PINOT NOIR</item>
            </text_lines>
        </item>
        <item>
            <filepath>path/folder/image2.jpg</filepath>
            <text_lines>
                <item>Beronia</item>
                <item>RIOJA</item>
                <item>DENOMINACIÓN DE ORIGEN CALIFICADA</item>
                <item>Product of Spain</item>
                <item>TEMPRANILLO</item>
                <item>2013</item>
                <item>BOTTLED BY/MIS ENBOUTEILLE PAR</item>
                <item>Bodegas Beronia</item>
                <item>OLLAURI-ESPAÑA</item>
                <item>RE.5229-LO</item>
            </text_lines>
        </item>
    </result>
    <stats>
        <time_get_text>4.29</time_get_text>
        <time_total>4.75</time_total>
    </stats>
</data>