Skip to main content

MLDatasetBuilder is a python package which is helping to prepare the image for your ML dataset.

Project description

MLDatasetBuilder

MLDatasetBuilder is a python package that is helping to prepare images for your ML dataset. Whenever we begin a machine learning project, the first thing that we need is a dataset. Datasets will be the pillar of the training model. You can build the dataset either automatically or manually.

python version PyPI

Author: Karthick Nagarajan

Email: karthick965938@gmail.com

Installation

We can install MLDatasetBuilder package using this command

pip install MLDatasetBuilder

Available Operations

  1. Remove unwanted format images and Rename image files
PrepareImage(folder_name, image_name)
#PrepareImage('images', 'dog')
  1. Extract images from video file
ExtractImages(video_path, filename, framesize)
#ExtractImages('video.mp4', 'frame', 10)

Remove unwanted format images and Rename image files

we can get images from Google. Using the Download All Images browser extension we can easily get images in a few minutes. You can check out here for more details about this extension!

step_1

Once you have downloaded the images using this extension, you can create a python file called test_python_file.py the same directory as below.

download_image_folder/
   _14e839ba-9691-11ea-a968-2ed746e9a968.jpg
   5e5f7af12600004018b602c0.jpeg
   A471529_Alice_b-1.jpg
   image1.png
   image2.png
   ...
test_python_file.py

Inside the images folder, you can see lots of png images and random filenames.

PrepareImage(folder_name, image_name)
#PrepareImage('images', 'dog')
download_image_folder/
   dog_0.jpg
   dog_1.jpg
   dog_2.jpg
   dog_3.png
   dog_4.png
   ...
test.py

step_1

This process very helps to annotate your images while labeling. And of course, it will be like one of the standardized things.

Extract images from video file

download_image_folder/
video.mp4
test.py
ExtractImages(video_path, folder_name, framesize)
#ExtractImages('video.mp4', 'frame', 10)
ExtractImages(video_path, folder_name)
#ExtractImages('video.mp4', 'frame')
download_image_folder/
dog/
   dog_0.jpg
   dog_1.jpg
   dog_2.jpg
   dog_3.png
   dog_4.png
   ...
dog.mp4
test.py

step_1

Contact

MLDatasetBuilder was created by Karthick Nagarajan. Feel free to reach out on Twitter or through Email!

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

MLDatasetBuilder-0.0.9.tar.gz (3.8 kB view hashes)

Uploaded Source

Built Distribution

MLDatasetBuilder-0.0.9-py3-none-any.whl (5.0 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page