Skip to content

erolrecep/moviebarcode

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

89 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Moviebarcode Generator

movie_barcode_diagram

Project Setup

Create a Python virtual environment.

$ mkvirtualenv moviebarcode -p python3

Install required libraries

$ (moviebarcode) pip install -r requirements.txt

Usage

Generate Moviebarcode with video2moviebarcode.py

$ (moviebarcode) python video2moviebarcode.py -v "video_path"

Use Moviebarcode module in your code

from src.moviebarcode import Moviebarcode
moviebarcode = Moviebarcode(video_path=video_path)
moviebarcode.generate()
moviebarcode.display_barcode()
# Create an image, .png file
moviebarcode.make_image()

Sample barcode outputs

g8vHhgh6oM0.png moviebarcode

Generate Eventbarcode with video2eventbarcode.py

$ (moviebarcode) python video2eventbarcode.py -f "json_files_path"
from src.eventbarcode import EventBarcode
eb = EventBarcode(
            json_folder_path="json_files_path",
            barcode_width=5,
            no_of_colors=5,
            verbose=True,
            criteria='dominant'
        )
eb.build(file_name="eventbarcode.png")

Or

from src.eventbarcode import EventBarcode
eb = EventBarcode(
            json_folder_path=None,
            barcode_width=5,
            no_of_colors=5,
            verbose=True,
            criteria='dominant'
        )
eb.json_files = [...] # Sorted list of json files to generate eventbarcode
eb.build(file_name="eventbarcode.png")

Sample Eventbarcode Images

dominant_aus_eventbarcode.png first_aus_eventbarcode.png random_aus_eventbarcode.png

Releases

No releases published

Packages

No packages published

Languages