Giter VIP home page Giter VIP logo

pdf-translator's Introduction

PDF英文转中文

生成的PDF是中英对照的。

概述

Thanks to PDF Translator EN-JA

为了方便看英文文献,在网上找了一些PDF翻译器,最后Fork上面的仓库,做了点修改。

需要配置本地运行环境,运行main.py即可,需要下载模型到本地。使用paddleOCR提取文本,使用hugging face模型进行中英文翻译。完全离线。

使用方法:

按顺序执行以下操作(仅在windows11 x64进行了使用操作,不保证支持其他平台): 0. 确保控制台cmd或powershell可以运行python,并具有git,cd到你常用的工作目录下

  1. git clone https://github.com/babakara/pdf-translator
  2. cd pdf-translator
  3. python -m venv venv
  4. pip install -r requirements.txt
  5. python main.py

补充说明

如果要更换示例的PDF文件,替换"translate_pdf/123.pdf"。 生成的中间文件在"temp"文件夹下 合并结果PDF在"outputs\translated.pdf"

pdf-translator's People

Contributors

discus0434 avatar babakara avatar stn avatar

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.