Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

tesseract

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

tesseract

Tesseract OCR bindings for Node.js

  • 0.0.3
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
160
increased by30.08%
Maintainers
1
Weekly downloads
 
Created
Source

node-tesseract

Tesseract OCR bindings for Node.js.

I started developing of this module when had a need to have Tesseract working with Node.js. But found that existing modules do call tesseract command-line tool. And I have a need in fully customizable API. I started from this article and now working with Tesseract 3.02 API documentation. So soon will have much more things implemented! :wink:

Example

var tesseract = require("tesseract")
  , tess = new tesseract.BaseApi()
  , pix;

// set language
tess.init("eng");
// set image
tess.setImage("some-image.png");
// run recognition
tess.recognize();
// get recognized text
console.log(tess.getText());

// clear results
tess.clear();

// create Pix object (wrapper for Leptonica PIX structure)
pix = new tesseract.Pix("other-image.png");
// Pix can be used in BaseApi::SetImage() too
tess.setImage(pix);
// again recognize and get text
tess.recognize();
console.log(tess.getText());

// finish him! - free memory of underlying TessBaseAPI object
tess.end();

TODO

  • Make class BaseApi support more of TessBaseAPI
  • Make tests
  • Changelog
  • Support of other Tesseract APIs (someday)!

Keywords

FAQs

Package last updated on 12 Mar 2015

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc