Skip to content

A simple GPU-based image-enhancing tool for YOLO-labeled images written in python.

Notifications You must be signed in to change notification settings

CristianDavideConte/data-augmentation

Repository files navigation

Data Augmentation

A simple GPU-based image-enhancing tool for YOLO-labeled images written in python.
The image-enhancer are called Augmenters and they all implement the abstract class Augmenter.

Each augmenter has:

  • an __init__ constructor
  • a transform method which takes in a PIL Image and returns the transformed image as a NumPy array
  • a get_transformed_YOLO_values method which takes the original YOLO label values of an image and returns the transformed ones
  • a get_augmenter_signature method which returns a string containing the abbreviated name of the augmenter

The base Augmenter abstract class also defines some utility methods to convert images to NumPy arrays and viceversa.

The currently available augmenters are:

  • AugmenterBlur
  • AugmenterContrastBrightness
  • AugmenterGrayscale
  • AugmenterHFlip
  • AugmenterVFlip
  • AugmenterHShear
  • AugmenterVShear
  • AugmenterNoise
  • AugmenterRotate
  • AugmenterScale
  • AugmenterSharp
  • AugmenterTraslate

The project also contains the ImageManager and the LabelManager abstract classes which extend the FileManager abstract class and that define many files/images/YOLO labels manipulation methods to smooth out the file-system related part of the data-augmentation/image-enhancement.

The available implementations of these classes are called:

  • ImageManagerImpl
  • LabelManagerImpl

A high level class for directly transforming images and their labels is also provided and it's called WorkerImpl which is based upon the Worker abstrac class and exposes the transform_images_and_YOLO_labels method.

Testers can be found in the Testers directory.


Authors

Cristian Davide Conte
Simone Morelli

About

A simple GPU-based image-enhancing tool for YOLO-labeled images written in python.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages