Git Product home page Git Product logo

pmcam's Introduction

pmcam - poor man's video capture with motion detection in Bash

This simple Bash script inspects all images in current dir, and copies those with enough change to a separate dir. The original from laurent22/pmcam grabed images from a webcam. In my case I use a tethered camera that takes images at regular intervals to a date named directory, and then use this script to copy images with enough change to a output directory. Then every now and then I clear the source dir from old pictures.

Installation

OS X

brew install imagemagick

Linux (Debian)

sudo apt-get install imagemagick

Windows

(Not tested)

Configuration

The primary config options are:

DIFF_LIMIT       cut-off for what changes should be saved
OUTPUT_DIR       where to save matching imgs
SOURCE_WILDCARD  what images to process
TIME_STAMP       imagemagick code to set a time-stamp
RESIZE           set if images should be resized

Booleans, true/false
REMOVE_SOURCE    Remove source images
DISPLAY_SKIPPED  display info about ignored images
SINGLE_PASS      run once or loop for ever

Set them as you see fit.

Usage

cd to dir where images to be processed are located, then run it as:

./pmcam.sh

To stop the script, press Ctrl + C. If REMOVE_SOURCE is set you can stop and resume at any time.

License

MIT

pmcam's People

Contributors

form-follows-function avatar jaclu avatar laurent22 avatar

Stargazers

 avatar

Watchers

 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.