Giter Site home page Giter Site logo

composite_image's Introduction

composite_image

This repo provide a python script to create a composite image from a video.

Dependency

pip install opencv-python

Example

1 VAR Mode (Recommend)

python composite_image.py --video_path=./example_video.mp4 --start_t=0.0 --end_t=99.0 --skip_frame=2 --mode=VAR

image-20230909002327059

2 MIN Mode

python composite_image.py --video_path=./example_video.mp4 --start_t=0.0 --end_t=99.0 --skip_frame=2 --mode=MIN

image-20230909002235029

3 MAX Mode

python composite_image.py --video_path=./example_video.mp4 --start_t=0.0 --end_t=99.0 --skip_frame=2 --mode=MAX

image-20230909002149494

Parameter

  • --video_path: The path of the input video.
  • --start_t: the start time of the composite image.
  • --end_t: the end time of the composite image.
  • --skip_frame: skip frame number when extracting frames, input 1 for not skipping any frame.
  • --mode: mode of image merging, three choices is implemented:
    • VAR (Recommend): Use the pixel that is furthest from the mean of the image
    • MAX: Keep the lightest pixel.
    • MIN: Keep the darkest.

composite_image's People

Contributors

renyunfan avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.