Skip to content

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Repository files navigation

Simple Image Augmenter

The goal of this project is to use VHDL to create a Simple Image Augmenter that can be implemented on an FPGA. Because FPGAs can be customized for specific tasks, they can often perform those tasks more efficiently than a general-purpose computer. This makes them well-suited for performing simple, concurrent operations, like those involved in image augmentation.

The Simple Image Augmenter is a tool for performing basic image transformations, such as flipping, rotating, and adjusting brightness. It uses a finite state machine to define the different augmentation states, which can be triggered by user input (e.g. pressing a button). The FPGA reads in an image from a text file, applies the desired transformations, and then writes the augmented image back out to a text file. A Python script is used to convert the text file to an image format that can be viewed by the user.

Installation

Clone the repository

For scripts, use pip to install argparse and PIL

On terminal :

pip install argparse Pillow

Usage

Convert image to txt

On terminal (Path to Simple Image Augmenter):

python .\scripts\image2txt.py --img .\images\yourimage --txt .\images\textfile

Example : alt text

Convert txt to image

On terminal (Path to Simple Image Augmenter):

python .\scripts\txt2image.py --aug .\images\augmentedimage --txt .\images\textfile 

Example : alt text

For VHDL (Simulation) : Add the .vhd files on the VHDL folder to a ModelSim project Compile in order : TypeDeclarations.vhd -> SimpleImageAugmenter_functions.vhd -> SimpleImageAugmenter.vhd (top level) -> SimpleImageAugmenter_tb.vhd (testbench, optional)

Compile Steps (ModelSim) : alt text

Test Results

Synthesize (Cyclone V) :

alt text

Waveform (ModelSim) :

alt text

Example :

alt text

The images were checked using the augmentation software, and no differences were found. The normal image is shown in the top left, the X-mirrored image is in the middle left, the Y-mirrored image is in the bottom left, and the rotated image is on the right.

For more information, see our report in this project

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages