Giter Club home page Giter Club logo

esearch-ocr's People

Contributors

xushengfeng avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

esearch-ocr's Issues

安装运行环境运行后报错

Symbol search path is: *** Invalid ***


  • Symbol loading may be unreliable without a symbol search path. *
  • Use .symfix to have the debugger choose a symbol path. *
  • After setting your symbol path, use .reload to refresh symbol locations. *

Executable search path is:
Windows 8 Version 9600 MP (2 procs) Free x64
Product: WinNt, suite: SingleUserTS
Built by: 6.3.9600.17031 (winblue_gdr.140221-1952)
Machine Name:
Debug session time: Mon Jul 11 10:05:04.000 2022 (UTC + 8:00)
System Uptime: not available
Process Uptime: 0 days 0:00:01.000
............................................
This dump file has an exception of interest stored in it.
The stored exception information can be accessed via .ecxr.
(1c80.1fd8): Unknown exception - code c0000142 (first/second chance not available)
*** ERROR: Symbol file could not be found. Defaulted to export symbols for ntdll.dll -
ntdll!RtlRaiseStatus+0x20:
00007ffb04c0cdd0 488b85b8000000 mov rax,qword ptr [rbp+0B8h] ss:00000001a1ccf3d8=00007ffb04c0cdd0

浏览器环境部署报错 Uncaught ReferenceError: require is not defined

感谢作者在 PaddleOCR 的 js 部署方面做的工作,我尝试使用 esearch-OCR 在浏览器环境部署,但是遇到了一些问题,不知道应该如何解决。

主要操作:

import * as ocr from "esearch-ocr";
async function start() {
  const res = await axios.get("/ocr_keys_v1.txt");
  console.log(res);
  await ocr.init({
    detPath: "ocr_det.onnx",
    recPath: "ocr_rec.onnx",
    dic: res.data,
    node: false,
  });
  let img = document.getElementById("ocr-image");
  let canvas = document.createElement("canvas");
  canvas.width = img.width;
  canvas.height = img.height;
  canvas.getContext("2d").drawImage(img, 0, 0);
  const result = await ocr.ocr(
    canvas.getContext("2d").getImageData(0, 0, img.width, img.height)
  );
  setResult(result.reduce((total, cur) => total + `${cur.text}\n`));
}

本地 pnpm dev 没有问题,一旦build之后就会报错 Uncaught ReferenceError: require is not defined

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.