Skip to main content

Video to Image frames converter

Project description

VIDEO TO IMAGE

A Python pip package for converting videos to sequential image frames


AVAILABLE ON PIP

https://pypi.org/project/videotooimage/

pip install videotooimage



PURPOSE

  • videotooimage is a Python package that provides functionality to convert video files into sequences of images.
  • It utilizes the OpenCV library (cv2) to process video files and extract frames.
  • This package is useful for tasks such as video analysis, object detection, and machine learning model training using video data.


FEATURES

  • Convert video files (e.g., .mp4, .avi, .mov) into sequences of images.
  • Works with various video codecs and formats supported by OpenCV.
  • No need to create sub folders for directories manually, It will be created automatically.
  • Very useful for machine learning training purposes, the original folder structure is kept as is it.


PROCESSING

1 sec = 1 frame = 1 image file (.jpg format)


INSTALLATION

You can install videotooimage via pip:

pip install videotooimage



USAGE

Python3

import videotooimage
result = videotooimage.video_too_image("path/to/video/directory","path/to/output/directory")
print(result)



OUTPUT

Processing done, Check the folders : /output/folder


WORKING

  • Folder structure of videos directory (Input)
/project
    /videos
        /happy
            person1.mp4
            person2.mp4
            person3.mp4
        /sad
            person1.mp4
            person2.mp4
            person3.mp4
  • After conversion
    Folder structure of output directory
/output/folder/
    /v2i_images
        /happy
            person1(frame_number_1).jpg
            person1(frame_number_2).jpg
            person2.mp4
            person3.mp4
            ...
        /sad
            person1(frame_number_1).jpg
            person1(frame_number_2).jpg
            person2.jpg
            person3.jpg
            ... 



AUTHOR

Name: Raghava
GitHub: https://github.com/raghavtwenty/
Email: raghavtwenty@gmail.com
Date Created: March 18, 2024 | Last Updated: May 14, 2024


LICENSE

This package is licensed under the MIT License.


CONTRIBUTIONS

Contributions and feedback are welcome!
Please submit issues or pull requests on GitHub.

GitHub: https://github.com/raghavtwenty/videotooimage/

END OF README

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

videotooimage-2024.5.14.1.0.0.tar.gz (3.9 kB view details)

Uploaded Source

Built Distribution

videotooimage-2024.5.14.1.0.0-py3-none-any.whl (4.2 kB view details)

Uploaded Python 3

File details

Details for the file videotooimage-2024.5.14.1.0.0.tar.gz.

File metadata

File hashes

Hashes for videotooimage-2024.5.14.1.0.0.tar.gz
Algorithm Hash digest
SHA256 2e5eda7782a882323fb74342d08513d363a04c24ca8c29be1b3070b10550dbbf
MD5 c3f2b92c928b02fbda49592d568df861
BLAKE2b-256 c64e69f831108452a75560db4e106c85f1d34d45636679ecafc58bc5e5ad45eb

See more details on using hashes here.

File details

Details for the file videotooimage-2024.5.14.1.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for videotooimage-2024.5.14.1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 559c146c466768c0e14358eb1d4a240302c1267d7368a65866c9cad1dd68621c
MD5 833426fd0b7b85b09ae27e373f278005
BLAKE2b-256 e58c7f308634bdd6a4276d114b1644f4d4562446a88b97ef50dde5fb4cc6592f

See more details on using hashes here.

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