Object Detection using Template

- Main Page
- Packages
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

All Classes Namespaces Files Functions Variables
Public Member Functions | Private Member Functions | Private Attributes | List of all members
cz.vutbr.feec.novak68.HOG Class Reference
Collaboration diagram for cz.vutbr.feec.novak68.HOG:
[legend]

## Public Member Functions
| HOG (ImagePlus img, int cellSizeX, int cellSizeY, int numOfBins)
void | compute ()
void | compute (boolean normalize)
void | useFilter (HOGFilter filter)
ImagePlus | displayAngles ()
void | drawGrid (ImagePlus img)
void | displayStrenghtOnly ()
ImagePlus | showGradientX ()
ImagePlus | showGradientY ()
ImagePlus | showMagnification ()
ImagePlus | showOrientation ()
float | getMagnitude (int x, int y, int angleBin)
float[][][] | getCells ()
int[] | getImageSize ()
void | normalizeL2 ()

## Private Member Functions
void | computeBins (int cellSizeX, int cellSizeY, int numOfBins)
void | computeOrientationAndMagnitude (ImagePlus img2)
void | drawAngle (ImagePlus result, int x, int y, double angleDegrees, double strength)

## Private Attributes
ImagePlus | img
int | cellSizeX
int | cellSizeY
int | numOfBins
FloatProcessor | magnitude
FloatProcessor | orientation
int | cellCountX
int | cellCountY
ImageProcessor | dX
ImageProcessor | dY
float[][][] | cells
float[][][] | cellsCopy
final int | DISP_WIDTH = 30
int | DISP_HEIGHT = 30

## Detailed Description

This class support HOG method. Compute HOG from input image.

Author
  burgetrm, xnovak68

Definition at line 19 of file HOG.java.

## Constructor & Destructor Documentation

cz.vutbr.feec.novak68.HOG.HOG | ( | ImagePlus | img,
|  | int | cellSizeX,
|  | int | cellSizeY,
|  | int | numOfBins
| ) |  |

Definition at line 36 of file HOG.java.

References cz.vutbr.feec.novak68.HOG.cellSizeX, cz.vutbr.feec.novak68.HOG.cellSizeY, cz.vutbr.feec.novak68.HOG.img, and cz.vutbr.feec.novak68.HOG.numOfBins.

## Member Function Documentation

void cz.vutbr.feec.novak68.HOG.compute | ( |  | ) |

This method compute HOG.

Definition at line 47 of file HOG.java.

References cz.vutbr.feec.novak68.HOG.compute().

Referenced by cz.vutbr.feec.novak68.HOG.compute().

Here is the call graph for this function:

void cz.vutbr.feec.novak68.HOG.compute | ( | boolean | normalize | ) |

Definition at line 48 of file HOG.java.

References cz.vutbr.feec.novak68.HOG.cellSizeX, cz.vutbr.feec.novak68.HOG.cellSizeY, cz.vutbr.feec.novak68.HOG.computeBins(), cz.vutbr.feec.novak68.HOG.computeOrientationAndMagnitude(), cz.vutbr.feec.novak68.HOG.img, cz.vutbr.feec.novak68.HOG.normalizeL2(), and cz.vutbr.feec.novak68.HOG.numOfBins.

Here is the call graph for this function:

void cz.vutbr.feec.novak68.HOG.computeBins | ( | int | cellSizeX,
|  | int | cellSizeY,
|  | int | numOfBins
| ) |  |
| private

This method will compute bins of angles for the input image.

Parameters

  cellSizeX |
  cellSizeY |
  numOfBins |

Definition at line 61 of file HOG.java.

References cz.vutbr.feec.novak68.HOG.cellCountX, cz.vutbr.feec.novak68.HOG.cellCountY, cz.vutbr.feec.novak68.HOG.cells, cz.vutbr.feec.novak68.HOG.cellSizeX, cz.vutbr.feec.novak68.HOG.cellSizeY, cz.vutbr.feec.novak68.HOG.img, cz.vutbr.feec.novak68.HOG.numOfBins, and cz.vutbr.feec.novak68.HOG.orientation.

Referenced by cz.vutbr.feec.novak68.HOG.compute().

void cz.vutbr.feec.novak68.HOG.computeOrientationAndMagnitude | ( | ImagePlus | img2 | ) |
| private

This method will compute orientation and magnitude from the input image img2.

Parameters

  img2 |

Definition at line 94 of file HOG.java.

References cz.vutbr.feec.novak68.HOG.dX, cz.vutbr.feec.novak68.HOG.dY, cz.vutbr.feec.novak68.HOG.img, cz.vutbr.feec.novak68.HOG.magnitude, and cz.vutbr.feec.novak68.HOG.orientation.

Referenced by cz.vutbr.feec.novak68.HOG.compute().

ImagePlus cz.vutbr.feec.novak68.HOG.displayAngles | ( |  | ) |

This method shows angles with its votes. This method is not yet finished.

Definition at line 168 of file HOG.java.

References cz.vutbr.feec.novak68.HOG.cellCountX, cz.vutbr.feec.novak68.HOG.cellCountY, cz.vutbr.feec.novak68.HOG.cells, cz.vutbr.feec.novak68.HOG.DISP_HEIGHT, cz.vutbr.feec.novak68.HOG.DISP_WIDTH, cz.vutbr.feec.novak68.HOG.drawAngle(), and cz.vutbr.feec.novak68.HOG.numOfBins.

Referenced by cz.vutbr.feec.novak68.HOGExample.getHOGTemplate().

Here is the call graph for this function:

void cz.vutbr.feec.novak68.HOG.displayStrenghtOnly | ( |  | ) |

This method compute Sthrengest bin of the cell and displays only Sthrengest bins

Definition at line 237 of file HOG.java.

References cz.vutbr.feec.novak68.HOG.cellCountX, cz.vutbr.feec.novak68.HOG.cellCountY, cz.vutbr.feec.novak68.HOG.cellsCopy, cz.vutbr.feec.novak68.HOG.DISP_HEIGHT, cz.vutbr.feec.novak68.HOG.DISP_WIDTH, cz.vutbr.feec.novak68.HOG.drawAngle(), and cz.vutbr.feec.novak68.HOG.numOfBins.

Here is the call graph for this function:

void cz.vutbr.feec.novak68.HOG.drawAngle | ( | ImagePlus | result,
|  | int | x,
|  | int | y,
|  | double | angleDegrees,
|  | double | strength
| ) |  |
| private

This method draws angle to result ImagePlus

Parameters

  result |
  x | position on X axis
  y | position on Y axis
  angleDegrees | angle in degrees
  strength | magnitude of angle

Definition at line 286 of file HOG.java.

References cz.vutbr.feec.novak68.HOG.DISP_HEIGHT, and cz.vutbr.feec.novak68.HOG.DISP_WIDTH.

Referenced by cz.vutbr.feec.novak68.HOG.displayAngles(), and cz.vutbr.feec.novak68.HOG.displayStrenghtOnly().

void cz.vutbr.feec.novak68.HOG.drawGrid | ( | ImagePlus | img | ) |

This method Creates Grid in input ImagePlus with parameters set in this HOG class.

Parameters

  img |

Definition at line 210 of file HOG.java.

References cz.vutbr.feec.novak68.HOG.cellCountX, cz.vutbr.feec.novak68.HOG.cellCountY, cz.vutbr.feec.novak68.HOG.DISP_HEIGHT, and cz.vutbr.feec.novak68.HOG.DISP_WIDTH.

float [][][] cz.vutbr.feec.novak68.HOG.getCells | ( |  | ) |

Definition at line 345 of file HOG.java.

References cz.vutbr.feec.novak68.HOG.cells.

Referenced by cz.vutbr.feec.novak68.extractors.SimpleHOGcellExtractor.computeBinCount(), cz.vutbr.feec.novak68.extractors.SimpleHOGcellExtractor.computeBinCountMore(), cz.vutbr.feec.novak68.hogcomparators.SimpleHogComparator.getDistance(), cz.vutbr.feec.novak68.hogcomparators.SimpleSthrenghtHOGComparator.getDistance(), cz.vutbr.feec.novak68.hogcomparators.OtherElementComparator.getDistance(), cz.vutbr.feec.novak68.hogcomparators.AllElementComparator.getDistance(), cz.vutbr.feec.novak68.hogcomparators.VerticalElementComparator.getDistance(), cz.vutbr.feec.novak68.hogcomparators.HorizontalElementComparator.getDistance(), cz.vutbr.feec.novak68.hogcomparators.SimpleXSymetryComparator.getDistance(), cz.vutbr.feec.novak68.hogcomparators.SimpleYSymetryComparator.getDistance(), cz.vutbr.feec.novak68.hogcomparators.SimpleSymetryComparator.getDistance(), and cz.vutbr.feec.novak68.hogcomparators.SimpleHogComparator.hogSizeEquals().

int [] cz.vutbr.feec.novak68.HOG.getImageSize | ( |  | ) |

Returns
  int array [Width, Height]

Definition at line 351 of file HOG.java.

References cz.vutbr.feec.novak68.HOG.img.

Referenced by cz.vutbr.feec.novak68.hogcomparators.SimpleHogComparator.hogSizeEquals().

float cz.vutbr.feec.novak68.HOG.getMagnitude | ( | int | x,
|  | int | y,
|  | int | angleBin
| ) |  |

Definition at line 342 of file HOG.java.

References cz.vutbr.feec.novak68.HOG.cells.

Referenced by cz.vutbr.feec.novak68.hogcomparators.SimpleHogComparator.getDistance().

void cz.vutbr.feec.novak68.HOG.normalizeL2 | ( |  | ) |

Normalize HOG according to dallal's L2 normalization

Definition at line 358 of file HOG.java.

References cz.vutbr.feec.novak68.HOG.cells.

Referenced by cz.vutbr.feec.novak68.HOG.compute().

ImagePlus cz.vutbr.feec.novak68.HOG.showGradientX | ( |  | ) |

Draw and show derivation in X axis

Definition at line 304 of file HOG.java.

References cz.vutbr.feec.novak68.HOG.dX.

Referenced by cz.vutbr.feec.novak68.HOGExample.getHOGTemplate().

ImagePlus cz.vutbr.feec.novak68.HOG.showGradientY | ( |  | ) |

Draw and show derivation in Y axis

Definition at line 315 of file HOG.java.

References cz.vutbr.feec.novak68.HOG.dY.

Referenced by cz.vutbr.feec.novak68.HOGExample.getHOGTemplate().

ImagePlus cz.vutbr.feec.novak68.HOG.showMagnification | ( |  | ) |

Draw and show Magnitude

Definition at line 325 of file HOG.java.

References cz.vutbr.feec.novak68.HOG.magnitude.

Referenced by cz.vutbr.feec.novak68.HOGExample.getHOGTemplate().

ImagePlus cz.vutbr.feec.novak68.HOG.showOrientation | ( |  | ) |

Draw and show derivation orientation

Definition at line 335 of file HOG.java.

References cz.vutbr.feec.novak68.HOG.orientation.

Referenced by cz.vutbr.feec.novak68.HOGExample.getHOGTemplate().

void cz.vutbr.feec.novak68.HOG.useFilter | ( | HOGFilter | filter | ) |

This method use filter for current HOG

Parameters

  filter |

Definition at line 161 of file HOG.java.

References cz.vutbr.feec.novak68.HOG.cells.

## Member Data Documentation

int cz.vutbr.feec.novak68.HOG.cellCountX
| private

Definition at line 27 of file HOG.java.

Referenced by cz.vutbr.feec.novak68.HOG.computeBins(), cz.vutbr.feec.novak68.HOG.displayAngles(), cz.vutbr.feec.novak68.HOG.displayStrenghtOnly(), and cz.vutbr.feec.novak68.HOG.drawGrid().

int cz.vutbr.feec.novak68.HOG.cellCountY
| private

Definition at line 28 of file HOG.java.

Referenced by cz.vutbr.feec.novak68.HOG.computeBins(), cz.vutbr.feec.novak68.HOG.displayAngles(), cz.vutbr.feec.novak68.HOG.displayStrenghtOnly(), and cz.vutbr.feec.novak68.HOG.drawGrid().

float [][][] cz.vutbr.feec.novak68.HOG.cells
| private

Definition at line 31 of file HOG.java.

Referenced by cz.vutbr.feec.novak68.HOG.computeBins(), cz.vutbr.feec.novak68.HOG.displayAngles(), cz.vutbr.feec.novak68.HOG.getCells(), cz.vutbr.feec.novak68.HOG.getMagnitude(), cz.vutbr.feec.novak68.HOG.normalizeL2(), and cz.vutbr.feec.novak68.HOG.useFilter().

float [][][] cz.vutbr.feec.novak68.HOG.cellsCopy
| private

Definition at line 32 of file HOG.java.

Referenced by cz.vutbr.feec.novak68.HOG.displayStrenghtOnly().

int cz.vutbr.feec.novak68.HOG.cellSizeX
| private

Definition at line 21 of file HOG.java.

Referenced by cz.vutbr.feec.novak68.HOG.compute(), cz.vutbr.feec.novak68.HOG.computeBins(), and cz.vutbr.feec.novak68.HOG.HOG().

int cz.vutbr.feec.novak68.HOG.cellSizeY
| private

Definition at line 22 of file HOG.java.

Referenced by cz.vutbr.feec.novak68.HOG.compute(), cz.vutbr.feec.novak68.HOG.computeBins(), and cz.vutbr.feec.novak68.HOG.HOG().

int cz.vutbr.feec.novak68.HOG.DISP_HEIGHT = 30
| private

Definition at line 34 of file HOG.java.

Referenced by cz.vutbr.feec.novak68.HOG.displayAngles(), cz.vutbr.feec.novak68.HOG.displayStrenghtOnly(), cz.vutbr.feec.novak68.HOG.drawAngle(), and cz.vutbr.feec.novak68.HOG.drawGrid().

final int cz.vutbr.feec.novak68.HOG.DISP_WIDTH = 30
| private

Definition at line 33 of file HOG.java.

Referenced by cz.vutbr.feec.novak68.HOG.displayAngles(), cz.vutbr.feec.novak68.HOG.displayStrenghtOnly(), cz.vutbr.feec.novak68.HOG.drawAngle(), and cz.vutbr.feec.novak68.HOG.drawGrid().

ImageProcessor cz.vutbr.feec.novak68.HOG.dX
| private

Definition at line 29 of file HOG.java.

Referenced by cz.vutbr.feec.novak68.HOG.computeOrientationAndMagnitude(), and cz.vutbr.feec.novak68.HOG.showGradientX().

ImageProcessor cz.vutbr.feec.novak68.HOG.dY
| private

Definition at line 30 of file HOG.java.

Referenced by cz.vutbr.feec.novak68.HOG.computeOrientationAndMagnitude(), and cz.vutbr.feec.novak68.HOG.showGradientY().

ImagePlus cz.vutbr.feec.novak68.HOG.img
| private

Definition at line 20 of file HOG.java.

Referenced by cz.vutbr.feec.novak68.HOG.compute(), cz.vutbr.feec.novak68.HOG.computeBins(), cz.vutbr.feec.novak68.HOG.computeOrientationAndMagnitude(), cz.vutbr.feec.novak68.HOG.getImageSize(), and cz.vutbr.feec.novak68.HOG.HOG().

FloatProcessor cz.vutbr.feec.novak68.HOG.magnitude
| private

Definition at line 25 of file HOG.java.

Referenced by cz.vutbr.feec.novak68.HOG.computeOrientationAndMagnitude(), and cz.vutbr.feec.novak68.HOG.showMagnification().

int cz.vutbr.feec.novak68.HOG.numOfBins
| private

Definition at line 23 of file HOG.java.

Referenced by cz.vutbr.feec.novak68.HOG.compute(), cz.vutbr.feec.novak68.HOG.computeBins(), cz.vutbr.feec.novak68.HOG.displayAngles(), cz.vutbr.feec.novak68.HOG.displayStrenghtOnly(), and cz.vutbr.feec.novak68.HOG.HOG().

FloatProcessor cz.vutbr.feec.novak68.HOG.orientation
| private

Definition at line 26 of file HOG.java.

Referenced by cz.vutbr.feec.novak68.HOG.computeBins(), cz.vutbr.feec.novak68.HOG.computeOrientationAndMagnitude(), and cz.vutbr.feec.novak68.HOG.showOrientation().

The documentation for this class was generated from the following file:

- src/cz/vutbr/feec/novak68/HOG.java