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.6.3.tar.gz (21.0 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.6.3-py3-none-any.whl (7.8 kB view details)

Uploaded Python 3

File details

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

File metadata

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

File hashes

Hashes for arxivit-0.6.3.tar.gz
Algorithm Hash digest
SHA256 de5216812b70486f4019b5a8992151efde07e8cc48739c5ea401c2e4944f0fab
MD5 c4a593534c2109e0f42fb8cccfab3a8f
BLAKE2b-256 70828269056b9d4e915ecb2f38023588b8ee590f2bfc3181e7992950a387a7ac

See more details on using hashes here.

Provenance

The following attestation bundles were made for arxivit-0.6.3.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.6.3-py3-none-any.whl.

File metadata

  • Download URL: arxivit-0.6.3-py3-none-any.whl
  • Upload date:
  • Size: 7.8 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.6.3-py3-none-any.whl
Algorithm Hash digest
SHA256 c10c8fce3608cc491667eaf91c7571e23a2b27a3e5c4d14916b862c0e7deb3e9
MD5 59e2a03dacedf685004f824d41a2bd2f
BLAKE2b-256 c64b01c33746e5ef001368184b8a2ed27c922f32f3e66c10169ae7a5c3c45745

See more details on using hashes here.

Provenance

The following attestation bundles were made for arxivit-0.6.3-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