Coder Social home page Coder Social logo

ocrvisualizer's Introduction

OCR Visualizer

OCRVisualizer is a tool to visualize Microsoft Cognitive Services OCR API json output to get familiar with bounding boxes of Regions, Lines and Words. It's written in C#/WPF.

This tool will be helful for your data discovery, if you use OCR with your documents.

The new preview OCR engine is integrated (through "Recognize Text" API operation) with even better text recognition results for English.

Main Functinality

In this version;

  • You can see bounding boxes of Regions, Lines and Words
  • You can select layers of bounding boxes to visualize under OCR Text Visibility menu
  • You can see extracted text over your original document
  • You can extract full text as output
  • You extract Key-Value Pairs
  • Better results with new preview OCR engine (through "Recognize Text", only in English)

Run Executable File

If you would like to test OCR visualizer on your local, download Setup File and update with your subscription Key and endpoint in OCR Settings. After defining your endpoint you can visualize your OCR documents via Browse.

Build the project

Please change in App.config file below code snippet with your Cognitive Services Computer Vision API subscription key and if your service hosted other than northeurope region, change the region with yours.

Microsoft Cognitive Services Computer Vision Endpoint details.

<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <startup>
    <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6.1" />
  </startup>
  <appSettings>
    <add key="subscriptionKey" value="YOUR_COMPUTER_VISION_API_KEY" />
    <add key="endpointRegion" value="https://northeurope.api.cognitive.microsoft.com/vision/v2.0/ocr" />
    <add key="documentLanguage" value="unk" />
    <add key="searchValues" value="Number,Field,Source" />
    <add key="searchValuesWidth" value="300" />
  </appSettings>
</configuration>

Field Extraction - Key-Value Pairs

If you're looking for a specific value of a field, you can use this feature. After defining your field names, it'll look for a certain pixel to retrieve group of text as a value. Here is how it works.

Now you can define your Field Extraction under Key-Value pairs in Manage Key-Value under Field Extraction menu and values of these fields will be detected by their positions on the document and detected values will be listed in same panel.

Here are some examples of of output of documents.

Extract Key-Value Pairs

Visualize Bounding Boxes

Now you can select layers of bounding boxes to visualize under OCR Text Visibility menu

OCR for unstuctured documents.

OCR for a part of documents

OCR from full page documents

For more information about Optical character recognition (OCR) in images | Demo | Container Support

OCR Supported languages:

  • unk (AutoDetect)
  • zh-Hans (ChineseSimplified)
  • zh-Hant (ChineseTraditional)
  • cs (Czech)
  • da (Danish)
  • nl (Dutch)
  • en (English)
  • fi (Finnish)
  • fr (French)
  • de (German)
  • el (Greek)
  • hu (Hungarian)
  • it (Italian)
  • ja (Japanese)
  • ko (Korean)
  • nb (Norwegian)
  • pl (Polish)
  • pt (Portuguese,
  • ru (Russian)
  • es (Spanish)
  • sv (Swedish)
  • tr (Turkish)
  • ar (Arabic)
  • ro (Romanian)
  • sr-Cyrl (SerbianCyrillic)
  • sr-Latn (SerbianLatin)
  • sk (Slovak)

Thanks.

ocrvisualizer's People

Contributors

ikivanc avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.