Giter Site home page Giter Site logo

luxi-huang / geometric-whisker-parameter-extraction Goto Github PK

View Code? Open in Web Editor NEW
1.0 3.0 0.0 1.58 MB

This project is extracting whisker parameters automatically from images.

Home Page: https://luxi-huang.github.io/portfolio/

MATLAB 100.00%
whisker image-processing computer-vision parameter-extracting whisker-parameters 2d-whisker 2d-images

geometric-whisker-parameter-extraction's Introduction

2D Whisker Parameter Analysis

Introduction

The code is desiged to automatically extract 2D seal whisker parameters and saved on data under SealWhisker.mat file, and the program is setup to automatically detect black or green background.

Parameters Saved Under SealWhisker.mat

Parameters Name Explanation
Whisker Length Length of Seal whisker
row Row number of whisker
col Col number of Whisker
SealNum Harbor number of Whisker
Side Left/right side of whisker (1/0)
D_base Base diameter
D_tip Tip diameter
Ratio_R D_base/D_tip
whisker_xx All x positions alonge the centerline
whisker_yy All y positions alonge the centerline
Valid valid or not valid whisker (1/0), it is automatically set to valid value (1), but user can changed value directly from SealWhisker.mat files after running the program
dis_tip_base The stright line length from tip to base
Std_upper_concave_xx concave x positions on upper side of whisker
Std_upper_concave_yy concave y positions on upper side of whisker
Std_upper_convex _xx convex x positions on upper side of whisker
Std_upper_convex_yy convex y positions on upper side of whisker
Std_upper_concave_xx concave x positions on upper side of whisker
Std_upper_concave_yy concave y positions on upper side of whisker
Std_upper_convex _xx convex x positions on upper side of whisker
Std_upper_convex_yy convex y positions on upper side of whisker

How to use code

Running new_whisker_parameters.m

  • Step1 : user needs to edit the whisker infomation
    • Whiker numbers (Row, col, left/right )
    • Harbor number
  • Step2 : crop the ruler image with 11 bars (users need to double clicks the mouse after they cropped the image)
  • Step3 : crop the whisker which one needs to be extracted the parameters (users need to double clicks the mouse after they cropped the image)
  • Step4 : On croppted whisker image, find the whisker's base and tip position by pressing enter key (two times)
    • First time press enter key, the mouth arrow would changed to cross shape
    • The second time press enter key, to locate base/tip position (base must be the first to locate)

Optional Steps - if you think the whisker is not valid

  • Option 1 : open SealWhisker.mat file, and find the ifvalid variable, change last row value from 1 to 0;
  • Option 2 : Delete last row for all vairbales under SealWhisker.mat by runing delet_row.m file

Reference image

The follow images are whisker with extracted concave/convex points

Hierarchy

Figure 2: whisker and centerlines.png

Hierarchy

Figure 2: rotated_whiskers.png

geometric-whisker-parameter-extraction's People

Contributors

hannahemnett avatar luxi-huang avatar mady-c avatar

Stargazers

 avatar

Watchers

 avatar  avatar  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.