Skip to main content

Multi-purpose processing library for downstream use

Project description

procslib

ci documentation pypi version gitter

Multi-purpose processing library for various inference tasks.
Generated with copier-uv.


Installation

pip install procslib

Or using uv:

uv tool install procslib

Quick Usage

Below is a minimal example of how to infer images with procslib:

from procslib import get_model_keys, get_model

# List available models
print(get_model_keys())

# Create a model, e.g. "twitter_logfav"
model = get_model("twitter_logfav")

# Infer on some images
image_paths = ["path/to/image1.jpg", "path/to/image2.jpg"]
results_df = model.infer_many(image_paths)
print(results_df.head())

Supported Models

You can retrieve a model via get_model(key). Here’s a quick reference:

Key Description
twitter_logfav A model predicting Twitter favorites (log-scaled) for anime images
weakm_v2 A previous version of numeric aesthetics scoring (anime)
siglip_aesthetic A Siglip-based aesthetic model for general images (requires a newer transformers)
pixiv_compound_score A numeric aesthetics score model trained on pixiv data
cv2_metrics Basic image metrics (noise, exposure, clarity, edge count, etc.) (No GPU usage)
complexity_ic9600 A complexity-measuring model for images
rtmpose Detects body parts in images (RTMDet-based)
depth MiDaS-based depth estimation (returns a “depthness” metric)
q_align_quality Q-Align model for quality assessment (requires transformers==4.36.1)
q_align_aesthetics Q-Align model for aesthetics (also needs that older transformers)
laion_watermark A fast watermark (text detection) model from LAION
clip_aesthetic Caches CLIP embeddings and calculates aesthetic scores and 0-shot classifications from embeddings

Note: Q-Align and Siglip Aesthetics are incompatible with each other’s transformers version. If you need both, see Docs: Handling Conflicting Dependencies.

Development

For development tasks (testing, formatting, releasing), see Dev Guide or run:

make setup   # one-time
make format  # auto-format
make test
make check
make changelog
make release version=x.y.z

Documentation

To learn more, visit our MkDocs-based docs or run:

make docs host=0.0.0.0

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

procslib-0.4.2.tar.gz (66.2 kB view details)

Uploaded Source

Built Distribution

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

procslib-0.4.2-py3-none-any.whl (53.4 kB view details)

Uploaded Python 3

File details

Details for the file procslib-0.4.2.tar.gz.

File metadata

  • Download URL: procslib-0.4.2.tar.gz
  • Upload date:
  • Size: 66.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.13.0

File hashes

Hashes for procslib-0.4.2.tar.gz
Algorithm Hash digest
SHA256 f7210391b92c4bd1fc85eed97645dee4464a0aadcf340b1b8a0db873f6a5279a
MD5 ee07f27c68f5849aa9516f35fa130ad6
BLAKE2b-256 c6e0b9d2c71c2daa6d841418ef727ee7476cef24b8b409cc5e3575fc4e818628

See more details on using hashes here.

File details

Details for the file procslib-0.4.2-py3-none-any.whl.

File metadata

  • Download URL: procslib-0.4.2-py3-none-any.whl
  • Upload date:
  • Size: 53.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.13.0

File hashes

Hashes for procslib-0.4.2-py3-none-any.whl
Algorithm Hash digest
SHA256 cf1f7b2fdf59c704d9e2b6b39453aecb605569bbf7f14dd9ded4ae4945f250a8
MD5 773c33f5049b112347477dd6f4a7b68c
BLAKE2b-256 3b2e1adec2eb90ba09d35bc1367700fbfec7c2ba5e8b53598ad483b4890d3bf3

See more details on using hashes here.

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