Giter Site home page Giter Site logo

capture's Introduction

python截图+百度ocr(图片识别)+ 百度翻译

一直想用python做一个截图并自动翻译的工具,恰好最近有时间就在网上找了资料,根据资料以及自己的理解做了一个简单的截图翻译工具。整理一下并把代码放在github给大家参考。界面用python自带的GUI的tkinter,截图用的是pillow,图片识别用的是百度ocr的api,翻译用的是百度翻译api。

前期准备

python环境

window 10
python3.6

baidu-aip==2.2.18.0
certifi==2019.11.28
chardet==3.0.4
idna==2.8
Pillow==6.2.1
requests==2.22.0
urllib3==1.25.7

安装第三方包

pip install pillow
pip install baidu-aip

百度ocr的api申请步骤参考

https://ai.baidu.com/forum/topic/show/867951

百度翻译api申请步骤参考

https://www.91yun.co/archives/66

tkinter教程参考

https://morvanzhou.github.io/tutorials/python-basic/tkinter/2-07-canvas/

pillow教程参考

https://www.cnblogs.com/wbin91/p/3971079.html

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.