Coder Social home page Coder Social logo

objectsizemeasurer's Introduction

Measure size of objects in an image using JavaCV

The project provides a script to read an image and draw objects contours.

Constraints

  1. Shadow effect: use dark background
  2. Object boundry: use contrasting background

Getting Started

Prerequisites

  1. Java 8 (maybe or higher)
  2. Maven

Installing

  1. Clone repository
  • git clone https://github.com/evosystem-jp/objectSizeMeasurer.git
  1. Install dependencies
  • mvn install

Run

For image file

mvn exec:java -Dexec.mainClass="jp.evosystem.objectSizeMeasurer.mains.ImageFileObjectSize"

For video file

mvn exec:java -Dexec.mainClass="jp.evosystem.objectSizeMeasurer.mains.VideoFileObjectSize"

For web camera image

mvn exec:java -Dexec.mainClass="jp.evosystem.objectSizeMeasurer.mains.WebCameraObjectSize"

Algorithm

  1. Image pre-processing
  • Read an image and convert it it no grayscale
  • Blur the image using Gaussian Kernel to remove un-necessary edges
  • Edge detection using Canny edge detector
  • Perform morphological closing operation to remove noisy contours
  1. Object Segmentation
  • Find contours
  • Remove small contours by calculating its area (threshold used here is 100)
  • Sort contours from left to right to find the reference objects
  1. Compute results
  • Draw bounding boxes around each object and calculate its height and width

Results

Result

Authors

  • Evosystem, Inc.

Acknowledgments

objectsizemeasurer's People

Contributors

cyrus07424 avatar dependabot-preview[bot] avatar dependabot[bot] 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.