Live data from Hacker News

Tesseract.js – A Javascript port of the Tesseract OCR engine

tesseract.projectnaptha.com

11–20 of 38 posts

Re: Tesseract.js – A Javascript port of the Tesseract OCR engine

#12
post #8

> Tesseract.js wraps an emscripten port of the Tesseract OCR Engine Calling this “pure JavaScript” seems misleading

Yes, it's kind of weird, since there's no benefit to claiming false things like "Tesseract.js is a pure Javascript port [...]". Say it's WASM, since people associate that with speed and newness (and heavyweight dependencies, but there's no hiding that).

Skimming the download, this does indeed use wasm, but it's also possible to build to pure JS with emscripten (in WASM=0 mode, wasm2js compiles the wasm to JS). Perhaps that's what they used to do and the docs have not been updated or something like that.

Re: Tesseract.js – A Javascript port of the Tesseract OCR engine

#13
post #7

The total size of the download seems to be 3-4MB (based on https://github.com/naptha/tesseract.js/blob/master/docs/loca... ), which is actually less than I expected.

It could be even smaller, it seems, as the wasm file is base64-encoded (so that it all fits in a single file - which is convenient, but larger).

Re: Tesseract.js – A Javascript port of the Tesseract OCR engine

#15
post #12
post #8

Earlier quoted context omitted.

Yes, it's kind of weird, since there's no benefit to claiming false things like "Tesseract.js is a pure Javascript port [...]". Say it's WASM, since people associate that with speed and newness (and heavyweight dependencies, but there's no hiding that).

Skimming the download, this does indeed use wasm, but it's also possible to build to pure JS with emscripten (in WASM=0 mode, wasm2js compiles the wasm to JS). Perhaps that's what they used to do and the docs have not been updated or something like that.

Still not a "port" though.

Re: Tesseract.js – A Javascript port of the Tesseract OCR engine

#16
post #7

The total size of the download seems to be 3-4MB (based on https://github.com/naptha/tesseract.js/blob/master/docs/loca... ), which is actually less than I expected.

Only English language support is included. Additional downloads are required for other languages.

Re: Tesseract.js – A Javascript port of the Tesseract OCR engine

#18
post #6

Nice stuff! I found an error in the chinese demo, with the example you provided (4th character wasn't the same). I know no OCR is perfect, but IMHO at least your own demo should be free of errors.

> at least your own demo should be free of errors

:) That would be a dishonest demo.

You try to show how well it works, not that it works perfectly well (which is false). Edit: especially since we know that OCR is hardly perfect - we expect errors to be minimized, not absent, and the first interest is to see where the engine fails.

Re: Tesseract.js – A Javascript port of the Tesseract OCR engine

#19
post #2

Congrats! Why would one create such a project with JS given all of the languages available to them?

Ease of deployment. Deploying a client-side JavaScript application remains far, far easier and less expensive than anything that runs server-side (or native compiled) code.

Also privacy: running OCR in someone's browser rather than sending the images back to the server keeps them fully in control of the data they are working with.

Post reply on HN