Skip to content

Strange problem - most of returned lines from getComponents from recognized texts prefixed with a character #138

Open
@zbyszek-matuszewski

Description

@zbyszek-matuszewski

About a month ago I had a problem with Google Android Vision OCR when text detector returned items which after getting lines by getComponents() method of TextBlock had a "(' character added at the beginning. It wasn't the case for all the lines though.

Now I have very similar problem but now it is "8". It happens to about 1/3 - 1/2 of recognized lines.
How to approach such problem?

I get texts like that in receiveDetections method:

SparseArray<TextBlock> items = detections.getDetectedItems();
List<Text> all_lines = new ArrayList<>();

for (int i = 0; i < items.size(); ++i) {
    TextBlock item = items.valueAt(i);
    List<? extends Text> texts = item.getComponents();
    for (Text t: texts) all_lines.add(t);
}

This is example how it looks

2016-10-03 19_05_43-clipboard

It is on Samsung Galaxy J5. On other phones it is ok though. It was also ok few hours ago.
Recompiling the app from clean build, reinstaling it, turning off and on again didn't work.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions