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.4.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.4-py3-none-any.whl (3.7 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: fast_augment-0.1.4.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.4.tar.gz
Algorithm Hash digest
SHA256 d9242d86a9d5cc96f705d88ce33bbf08065f2e9b4ec90ed36ca18c2739cc6f1e
MD5 14412e37463e0f084b18b70f98ae33d3
BLAKE2b-256 cdd272daed4d7bddb603ba57617a9088f0295586408e90743605aa30ac307d36

See more details on using hashes here.

File details

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

File metadata

  • Download URL: fast_augment-0.1.4-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.4-py3-none-any.whl
Algorithm Hash digest
SHA256 9e4b3d0a3d079d4f9953e3abe9e53823ef37c91ec454f664eef8845d8fcb330d
MD5 797c8561d8eb3079bfb52e0999b802c5
BLAKE2b-256 a997d115dd318938ee0e28597bccb9100f4d372b1314c3714f6e640b1f46caab

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