DEV Community

Cover image for How To Use AugLy On Image, Video, Audio, and Text?

How To Use AugLy On Image, Video, Audio, and Text?

Avi Arora
Machine Learning | Computer Vision | Python | React.js | Data Science Writer
・2 min read

Read the full article here:

Introduction to Data Augmentation

Facebook just recently released the AugLy package to the public domain. In this article, we will take a dive into the package. Just before data however, let's take some time to understand what data augmentation is about. 

Many coding examples are shown below. You can view the complete notebook on Github.

Article Overview

  • What is data augmentation?
  • About AugLy
  • How AugLy Works
  • Why AugLy
  • Image Data Augmentation
  • Textual Data Augmentation
  • Audio Data Augmentation
  • Video Data Augmentation

About AugLy

AugLy is a recently released open source project in python that can be used for data augmentation. The aim is to help AI models have an improved robustness during training and evaluation. Data augmentation in images can involve processes such as cropping of images or changing the pitch of a voice in an audio file. AugLy helps to automatically create such variations of the data. 

According to Facebook, AugLy is the first of its kind tool in the open source domain that has several modalities such as images, videos, audio, texts, etc, which is immensely important for emerging AI research. It utilizes real operations that people do to images on Facebook and Instagram to generate over 100 variations of the data. For instance, overlapping emojis, texts or screenshots is a popular thing many individuals do and so AugLy performs such transformations for its data augmentation. 

Another operation humans now perform is the combination of data of different modalities. For instance, the text 'you look good' may sound like a compliment. However, by adding an emoji, say the emoji of a clown, completely changes how the initial text was perceived. The 'compliment' would undoubtedly be seen as an insult. This is just the same way people take in information in today's world and AugLy takes those eventualities into cognizance. As more and more data modalities are combined, there is a need to ensure all the data augmentation and transformation can be done under a library or API. 

Facebook iterates the data augmentation done by the library in consonance with the transformation users of Facebook, Instagram and WhatsApp typically do. Thus, it would be a particularly useful function for folks working on AI models for social media applications. 

Discussion (0)