Skip to main content

Robust arXiv LaTeX cleaner with DPI-based image rescaling.

Project description

arxivit 🧹

image

Robust arXiv LaTeX cleaner with DPI-based image rescaling.

Installation

pip install arxivit

Usage

# Create an uploadable archive: /path/to/paper.arxiv.tar.gz
arxivit /path/to/paper/main.tex

# Convert images to JPEG at max 300 DPI in the final PDF and save to dir /path/to/output
arxivit /path/to/paper/main.tex --image-options 'jpeg,300dpi' --output /path/to/output

# Convert images to max 300 DPI in the final PDF, images in figures/pca/ to max 1000px
arxivit /path/to/paper/main.tex --image-options '300dpi' --image-options 'figures/pca/*:1000px'

For more options, run:

arxivit --help

Q&A

Why Not arxiv-latex-cleaner?

arxiv-latex-cleaner statically analyzes LaTeX source code, which has some limitations:

  1. It does not reliably track dependencies in all scenarios—e.g., when images are included via complex macros that obscure their filenames in the source code.
  2. It only supports fixed-size image rescaling, without considering how large an image appears in the final compiled PDF.

How Does arxivit Work?

arxivit takes a different approach:

  • It uses latexmk to compile the LaTeX source code.
  • It analyzes the compilation log to determine which .tex files and images are included, as well as their sizes in the final PDF.
  • It rescales images to the desired DPI based on their actual dimensions in the final document, ensuring uniform sharpness while minimizing file size.
  • It uses latexpand to strip comments from .tex files.

Related Projects

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

arxivit-0.7.1.tar.gz (22.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

arxivit-0.7.1-py3-none-any.whl (8.3 kB view details)

Uploaded Python 3

File details

Details for the file arxivit-0.7.1.tar.gz.

File metadata

  • Download URL: arxivit-0.7.1.tar.gz
  • Upload date:
  • Size: 22.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for arxivit-0.7.1.tar.gz
Algorithm Hash digest
SHA256 25566ec799b9823aaa86d0387c106893a42f97685505657282e425fc557f73bc
MD5 aa358fc550c2f3f9ecb05c12013c4213
BLAKE2b-256 d738b3979397603e8e94f139ed498a49cbcc08177d5a5e753b4b2a53ad4a1654

See more details on using hashes here.

Provenance

The following attestation bundles were made for arxivit-0.7.1.tar.gz:

Publisher: python-publish.yml on kabouzeid/arxivit

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file arxivit-0.7.1-py3-none-any.whl.

File metadata

  • Download URL: arxivit-0.7.1-py3-none-any.whl
  • Upload date:
  • Size: 8.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for arxivit-0.7.1-py3-none-any.whl
Algorithm Hash digest
SHA256 26664c5a0f1dc42ca1cdff54177e28060ef076d8ef70e93f126c14ce58a3d2a9
MD5 88ab68a7eb39a0e91ff4bcd3b944421e
BLAKE2b-256 7225a86e153497bdd6a684d1296102e0bd001ce9bfbb0d5b54d8f8b6fc67c799

See more details on using hashes here.

Provenance

The following attestation bundles were made for arxivit-0.7.1-py3-none-any.whl:

Publisher: python-publish.yml on kabouzeid/arxivit

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page