Skip to main content

DPayOcr

PyPI version

介绍

dpayocr 可以识别支付宝微信收款码信息。例如支付类型,支付金额,支付链接。

安装

$ pip install dpayocr

使用

命令行使用

dpayocr 66.JPG

输出

PayQrCode(pay_type=1, price=66.0, url='https://qr.alipay.com/xxx')

接口

>>> from dpayocr import parse_pay_qr_code
>>> fp = '66.JPG' # 可以传入文件名或者二进制IO
>>> parse_pay_qr_code(fp)
PayQrCode(pay_type=1, price=66.0, url='https://qr.alipay.com/xxx')

问题

在虚拟环境找不到 Tesseract 命令

# If you don't have tesseract executable in your PATH, include the following:
pytesseract.pytesseract.tesseract_cmd = r'<full_path_to_your_tesseract_executable>'
# Example tesseract_cmd = r'C:\Program Files (x86)\Tesseract-OCR\tesseract'

参考链接

Release files for dpayocr 1.0.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distribution (wheel)

Table of built distributions (wheels) for dpayocr 1.0.2
File Interpreter ABI Platform
dpayocr-1.0.2-py3-none-any.whl Python 3 none any Details

Release files / dpayocr-1.0.2-py3-none-any.whl

Download URL dpayocr-1.0.2-py3-none-any.whl
Size 4.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
edfa633a078dae11b0578e21fa49854313dd22cbae8c98c58fc59310c2fcd600
BLAKE2b-256 checksum
How to use checksums
3db1fc31d7772d563808a5fbc2d45888545b19ca9f0ebb4b88af077ee1891ca6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/45.1.0 requests-toolbelt/0.9.1 tqdm/4.42.1 CPython/3.7.6

Release history Release notifications | RSS feed

This release

1.0.2 This release

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page