Skip to main content

One-command image augmentation

Project description

FastAugment 🚀

One-command image augmentation for computer vision pipelines. Apply transformations with a single function call.

PyPI version Python versions License

Features

  • 🛠️ Preset-based augmentations - Choose between "simple" or "advanced" augmentation strategies
  • 🖼️ Supports multiple input types - Works with image paths, numpy arrays, and PyTorch datasets
  • Efficient processing - Optimized OpenCV backend
  • 📁 Automatic saving - Optionally save augmented images to directory

Installation

pip install fast_augment

Quick Start

Basic Usage

from fast_augment import FastAugment
import cv2

# Load an image
image = cv2.imread("image.jpg")
image = cv2.cvtColor(image, cv2.COLOR_BGR2RGB)

# Initialize augmenter
augmenter = FastAugment(preset="advanced")

# Augment single image
augmented_image = augmenter.augment_image(image)

Dataset Augmentation

from torchvision.datasets import CIFAR10

# Load dataset
dataset = CIFAR10(root="./data", train=True)

# Augment entire dataset
augmenter = FastAugment(preset="advanced")
augmented_data = augmenter.augment_dataset(
    dataset=dataset,
    output_dir="./augmented_data",
    target_size=10000
)

Presets

Preset Transformations
simple Horizontal flips, rotations
advanced Adds cutout and brightness/contrast

Advanced Configuration

Customize individual augmentation probabilities:

# Coming in v1.1 (create feature request!)

Documentation

Full API reference available at fastaugment.readthedocs.io

Contributing

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/AmazingFeature)
  3. Commit your changes (git commit -m 'Add some amazing feature')
  4. Push to the branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

License

Distributed under the MIT License. See LICENSE for more information.

Contact

Aryan Patil - aryanator01@gmail.com


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

fast_augment-0.1.3.tar.gz (3.4 kB view details)

Uploaded Source

Built Distribution

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

fast_augment-0.1.3-py3-none-any.whl (3.7 kB view details)

Uploaded Python 3

File details

Details for the file fast_augment-0.1.3.tar.gz.

File metadata

  • Download URL: fast_augment-0.1.3.tar.gz
  • Upload date:
  • Size: 3.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.4

File hashes

Hashes for fast_augment-0.1.3.tar.gz
Algorithm Hash digest
SHA256 6b1b93e4afb2ec373406f9fa0d60c2f39dd5b13060ee16cfedc69d5fecb9f1a1
MD5 c955183aa7f9790f10babd24b715e648
BLAKE2b-256 e1d97e134c4d1a56369c8181f9e621b891aec102506ff1de736fa1062f34e72d

See more details on using hashes here.

File details

Details for the file fast_augment-0.1.3-py3-none-any.whl.

File metadata

  • Download URL: fast_augment-0.1.3-py3-none-any.whl
  • Upload date:
  • Size: 3.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.4

File hashes

Hashes for fast_augment-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 17f3f644d932949dd9babea6076dd9cbbce694b54f149754ae83b0aaf91d8d7a
MD5 bc02d3c6e6d8f9f265adac551451bc0f
BLAKE2b-256 c92956e3110ce55a1f0302bde9b6306246842d14364bb7d3c28c4570c00ecdcd

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