setup.py 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. from pathlib import Path
  2. from pdf2zh import __version__, __author__
  3. from setuptools import setup
  4. root_dir = Path(__file__).parent
  5. with open(root_dir / "README.md", encoding='utf-8') as f:
  6. readme = f.read()
  7. setup(
  8. name="pdf2zh",
  9. long_description=readme,
  10. long_description_content_type="text/markdown",
  11. description="Latex PDF Translator",
  12. license="AGPLv3",
  13. version=__version__,
  14. author=__author__,
  15. author_email="byaidux@gmail.com",
  16. url="https://github.com/Byaidu/PDFMathTranslate",
  17. packages=["pdf2zh"],
  18. install_requires=[
  19. "charset-normalizer",
  20. "cryptography",
  21. "requests",
  22. "pymupdf",
  23. "tqdm",
  24. "tenacity",
  25. "doclayout-yolo",
  26. "numpy",
  27. "ollama",
  28. "deepl<1.19.1",
  29. "openai",
  30. "azure-ai-translation-text<=1.0.1",
  31. "gradio",
  32. "huggingface_hub",
  33. "torch",
  34. ],
  35. classifiers=[
  36. "Programming Language :: Python :: 3",
  37. "Operating System :: OS Independent",
  38. ],
  39. entry_points={
  40. 'console_scripts': [
  41. 'pdf2zh=pdf2zh.pdf2zh:main',
  42. ]
  43. },
  44. )