Public Member Functions | Public Attributes | Protected Member Functions | Protected Attributes | Friends
sdet_detector Class Reference

#include <sdet_detector.h>

Inheritance diagram for sdet_detector:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 sdet_detector (sdet_detector_params &params)
 Constructors.
 sdet_detector (vil1_image, float smoothSigma=1.0, float noiseSigma=2.0, float contourFactor=1.0, float junctionFactor=1.5, int minLength=6, float maxGap=2.23606, float minJump=1.0)
 sdet_detector (vil_image_resource_sptr &, float smoothSigma=1.0, float noiseSigma=2.0, float contourFactor=1.0, float junctionFactor=1.5, int minLength=6, float maxGap=2.23606, float minJump=1.0)
 ~sdet_detector ()
 Destructor.
bool DoContour ()
 Detect the contour, a list of edges and vertices are generated.
void DoFoldContourDetector (vil1_image image, vcl_vector< vtol_edge_2d_sptr > &edgels)
void DoFoldContourDetector (vil_image_resource_sptr const &image, vcl_vector< vtol_edge_2d_sptr > &edgels)
void DoBreakCorners (vcl_vector< vtol_edge_2d_sptr > &in_edgels, vcl_vector< vtol_edge_2d_sptr > &out_edgels)
bool DoFoldContour ()
 Detect the fold contour, a list of edges and vertices are generated.
bool DoCorner (float angle=10, float separation=1, int length=5, int cycle=2, int ndimension=2)
 number of dimension
bool DoStep ()
 Detect step profiles in the image, using dG+NMS+extension.
bool DoFold ()
gevd_bufferxy * GetBufferFromImage ()
 vil1 image conversion
gevd_bufferxy * GetBufferFromVilImage ()
 vil image conversion
vcl_vector< vtol_vertex_2d_sptr > * GetVertices ()
vcl_vector< vtol_edge_2d_sptr > * GetEdges ()
bool get_vdgl_edges (vcl_vector< vdgl_digital_curve_sptr > &edges)
bool get_vsol_edges (vcl_vector< vsol_digital_curve_2d_sptr > &edges)
void SetImage (vil1_image img)
 The last type set is used in the execution if both types are valid.
void SetImage (vil_image_resource_sptr const &img)
void SetImage (vil_image_resource_sptr const &img, brip_roi const &roi)
void print (vcl_ostream &strm=vcl_cout) const
bool SanityCheck ()
 Checks that parameters are within acceptable bounds.
void set_noise_weight (float noise_weight)
void set_noise_multiplier (float noise_multiplier)
void set_automatic_threshold (bool automatic_threshold)
void set_aggressive_junction_closure (int aggressive_junction_closure)
void set_close_borders (bool close_borders)

Public Attributes

float smooth
 Smoothing kernel sigma.
float noise_weight
 The weight between sensor noise and texture noise.
float noise_multiplier
 The overal noise threshold scale factor.
bool automatic_threshold
 Determine the threshold values from image.
int aggressive_junction_closure
 Close junctions aggressively.
int minLength
 minimum chain length
float contourFactor
 Threshold along contours.
float junctionFactor
 Threshold at junctions.
bool junctionp
 recover missing junctions
float minJump
 change in strength at junction
float maxGap
 Bridge small gaps up to max_gap across.
bool spacingp
 equalize spacing?
bool borderp
 insert virtual border for closure?
bool peaks_only
 Only return peaks, d^2I/dn^2 < 0, n is normal dir to ridge.
bool valleys_only
 Only return valeys, d^2I/dn^2 > 0.
float corner_angle
 smallest angle at corner
float separation
 |mean1-mean2|/sigma
int min_corner_length
 min length to find corners
int cycle
 number of corners in a cycle
int ndimension
 spatial dimension of edgel chains.

Protected Member Functions

void ClearData ()
 clear buffer
void InitParams (float smooth_sigma, float noise_w, float noise_m, bool automatic_t, int aggressive_jc, int minl, float maxgp, float minjmp, float contour_f, float junction_f, bool recover_j, bool equal_spacing, bool follow_b, bool peaks_only, bool valleys_only, float ang, float sep, int min_corner_len, int cyc, int ndim)

Protected Attributes

bool use_vil_image
bool use_roi_
vil1_image image
vil_image_resource_sptr vimage
brip_roi roi_
float noise
 noise estimation/threshold
gevd_bufferxy * edgel
 output from DoStep
gevd_bufferxy * direction
gevd_bufferxy * locationx
gevd_bufferxy * locationy
gevd_bufferxy * grad_mag
gevd_bufferxy * angle
 detect step/fold
int * junctionx
int * junctiony
int njunction
 junctions found
vcl_vector< vtol_vertex_2d_sptr > * vertices
 network of linked
vcl_vector< vtol_edge_2d_sptr > * edges
 edges and vertices
float filterFactor
 factor in convolution filter
float hysteresisFactor
 hysteresis factor
float noiseThreshold

Friends

vcl_ostream & operator<< (vcl_ostream &, const sdet_detector_params &dp)

Detailed Description

Definition at line 86 of file sdet_detector.h.


Constructor & Destructor Documentation

sdet_detector::sdet_detector ( sdet_detector_params params)

Constructors.

Definition at line 25 of file sdet_detector.cxx.

sdet_detector::sdet_detector ( vil1_image  img,
float  smoothSigma = 1.0,
float  noiseSigma = 2.0,
float  contourFactor = 1.0,
float  junctionFactor = 1.5,
int  minLength = 6,
float  maxGap = 2.23606,
float  minJump = 1.0 
)

Definition at line 44 of file sdet_detector.cxx.

sdet_detector::sdet_detector ( vil_image_resource_sptr img,
float  smoothSigma = 1.0,
float  noiseSigma = 2.0,
float  contourFactor = 1.0,
float  junctionFactor = 1.5,
int  minLength = 6,
float  maxGap = 2.23606,
float  minJump = 1.0 
)

Definition at line 63 of file sdet_detector.cxx.

sdet_detector::~sdet_detector ( )

Destructor.

Caller has an obligation to clear all the created edges and vertices.

Definition at line 85 of file sdet_detector.cxx.


Member Function Documentation

void sdet_detector::ClearData ( ) [protected]

clear buffer

Clear data buffer. Protected.

Definition at line 93 of file sdet_detector.cxx.

void sdet_detector::DoBreakCorners ( vcl_vector< vtol_edge_2d_sptr > &  in_edgels,
vcl_vector< vtol_edge_2d_sptr > &  out_edgels 
)

Definition at line 433 of file sdet_detector.cxx.

bool sdet_detector::DoContour ( )

Detect the contour, a list of edges and vertices are generated.

Definition at line 111 of file sdet_detector.cxx.

bool sdet_detector::DoCorner ( float  angle = 10,
float  separation = 1,
int  length = 5,
int  cycle = 2,
int  ndimension = 2 
)

number of dimension

Parameters:
anglesmallest angle at corner
separation|mean1-mean2|/sigma
lengthmin length to find cornersxo
cyclenumber of corners in a cycle
bool sdet_detector::DoFold ( )
bool sdet_detector::DoFoldContour ( )

Detect the fold contour, a list of edges and vertices are generated.

Definition at line 170 of file sdet_detector.cxx.

void sdet_detector::DoFoldContourDetector ( vil1_image  image,
vcl_vector< vtol_edge_2d_sptr > &  edgels 
)
void sdet_detector::DoFoldContourDetector ( vil_image_resource_sptr const &  image,
vcl_vector< vtol_edge_2d_sptr > &  edgels 
)
bool sdet_detector::DoStep ( )

Detect step profiles in the image, using dG+NMS+extension.

Definition at line 216 of file sdet_detector.cxx.

bool sdet_detector::get_vdgl_edges ( vcl_vector< vdgl_digital_curve_sptr > &  edges)

Definition at line 460 of file sdet_detector.cxx.

bool sdet_detector::get_vsol_edges ( vcl_vector< vsol_digital_curve_2d_sptr > &  edges)

Definition at line 485 of file sdet_detector.cxx.

gevd_bufferxy * sdet_detector::GetBufferFromImage ( )

vil1 image conversion

Transform data in the image as float buffer.

two versions so as not to break anything from the ancient code JLM vil1_image version

Definition at line 295 of file sdet_detector.cxx.

gevd_bufferxy * sdet_detector::GetBufferFromVilImage ( )

vil image conversion

Definition at line 351 of file sdet_detector.cxx.

vcl_vector<vtol_edge_2d_sptr>* sdet_detector::GetEdges ( ) [inline]

Definition at line 137 of file sdet_detector.h.

vcl_vector<vtol_vertex_2d_sptr>* sdet_detector::GetVertices ( ) [inline]

Definition at line 136 of file sdet_detector.h.

void sdet_detector_params::InitParams ( float  smooth_sigma,
float  noise_w,
float  noise_m,
bool  automatic_t,
int  aggressive_jc,
int  minl,
float  maxgp,
float  minjmp,
float  contour_f,
float  junction_f,
bool  recover_j,
bool  equal_spacing,
bool  follow_b,
bool  peaks_only,
bool  valleys_only,
float  ang,
float  sep,
int  min_corner_len,
int  cyc,
int  ndim 
) [protected, inherited]

Definition at line 44 of file sdet_detector_params.cxx.

void sdet_detector::print ( vcl_ostream &  strm = vcl_cout) const

Definition at line 401 of file sdet_detector.cxx.

bool sdet_detector_params::SanityCheck ( ) [inherited]

Checks that parameters are within acceptable bounds.

This method is always called after a parameter modifier has changed the prms.

Definition at line 125 of file sdet_detector_params.cxx.

void sdet_detector_params::set_aggressive_junction_closure ( int  aggressive_junction_closure) [inherited]

Definition at line 109 of file sdet_detector_params.cxx.

void sdet_detector_params::set_automatic_threshold ( bool  automatic_threshold) [inherited]

Definition at line 104 of file sdet_detector_params.cxx.

void sdet_detector_params::set_close_borders ( bool  close_borders) [inherited]

Definition at line 114 of file sdet_detector_params.cxx.

void sdet_detector_params::set_noise_multiplier ( float  noise_multiplier) [inherited]

Definition at line 99 of file sdet_detector_params.cxx.

void sdet_detector_params::set_noise_weight ( float  noise_weight) [inherited]

Definition at line 94 of file sdet_detector_params.cxx.

void sdet_detector::SetImage ( vil1_image  img)

The last type set is used in the execution if both types are valid.

Definition at line 439 of file sdet_detector.cxx.

void sdet_detector::SetImage ( vil_image_resource_sptr const &  img)

Definition at line 453 of file sdet_detector.cxx.

void sdet_detector::SetImage ( vil_image_resource_sptr const &  img,
brip_roi const &  roi 
)

Definition at line 445 of file sdet_detector.cxx.


Friends And Related Function Documentation

vcl_ostream& operator<< ( vcl_ostream &  os,
const sdet_detector_params dp 
) [friend, inherited]

Definition at line 235 of file sdet_detector_params.cxx.


Member Data Documentation

Close junctions aggressively.

Definition at line 148 of file sdet_detector_params.h.

gevd_bufferxy * sdet_detector::angle [protected]

detect step/fold

Definition at line 160 of file sdet_detector.h.

Determine the threshold values from image.

Definition at line 147 of file sdet_detector_params.h.

insert virtual border for closure?

Definition at line 157 of file sdet_detector_params.h.

Threshold along contours.

Definition at line 150 of file sdet_detector_params.h.

smallest angle at corner

Definition at line 166 of file sdet_detector_params.h.

int sdet_detector_params::cycle [inherited]

number of corners in a cycle

Definition at line 169 of file sdet_detector_params.h.

gevd_bufferxy * sdet_detector::direction [protected]

Definition at line 160 of file sdet_detector.h.

gevd_bufferxy* sdet_detector::edgel [protected]

output from DoStep

Definition at line 160 of file sdet_detector.h.

vcl_vector<vtol_edge_2d_sptr >* sdet_detector::edges [protected]

edges and vertices

Definition at line 165 of file sdet_detector.h.

float sdet_detector::filterFactor [protected]

factor in convolution filter

Reimplemented from sdet_detector_params.

Definition at line 167 of file sdet_detector.h.

gevd_bufferxy * sdet_detector::grad_mag [protected]

Definition at line 160 of file sdet_detector.h.

hysteresis factor

Definition at line 168 of file sdet_detector.h.

vil1_image sdet_detector::image [protected]

Definition at line 155 of file sdet_detector.h.

Threshold at junctions.

Definition at line 151 of file sdet_detector_params.h.

recover missing junctions

Definition at line 153 of file sdet_detector_params.h.

int* sdet_detector::junctionx [protected]

Definition at line 162 of file sdet_detector.h.

int * sdet_detector::junctiony [protected]

Definition at line 162 of file sdet_detector.h.

gevd_bufferxy * sdet_detector::locationx [protected]

Definition at line 160 of file sdet_detector.h.

gevd_bufferxy * sdet_detector::locationy [protected]

Definition at line 160 of file sdet_detector.h.

float sdet_detector_params::maxGap [inherited]

Bridge small gaps up to max_gap across.

Definition at line 155 of file sdet_detector_params.h.

min length to find corners

Definition at line 168 of file sdet_detector_params.h.

float sdet_detector_params::minJump [inherited]

change in strength at junction

Definition at line 154 of file sdet_detector_params.h.

minimum chain length

Definition at line 149 of file sdet_detector_params.h.

spatial dimension of edgel chains.

Definition at line 170 of file sdet_detector_params.h.

int sdet_detector::njunction [protected]

junctions found

Definition at line 162 of file sdet_detector.h.

float sdet_detector::noise [protected]

noise estimation/threshold

Definition at line 158 of file sdet_detector.h.

The overal noise threshold scale factor.

Definition at line 146 of file sdet_detector_params.h.

The weight between sensor noise and texture noise.

Definition at line 145 of file sdet_detector_params.h.

float sdet_detector::noiseThreshold [protected]

Definition at line 169 of file sdet_detector.h.

Only return peaks, d^2I/dn^2 < 0, n is normal dir to ridge.

Definition at line 161 of file sdet_detector_params.h.

Definition at line 157 of file sdet_detector.h.

|mean1-mean2|/sigma

Definition at line 167 of file sdet_detector_params.h.

float sdet_detector_params::smooth [inherited]

Smoothing kernel sigma.

Definition at line 144 of file sdet_detector_params.h.

equalize spacing?

Definition at line 156 of file sdet_detector_params.h.

bool sdet_detector::use_roi_ [protected]

Definition at line 154 of file sdet_detector.h.

bool sdet_detector::use_vil_image [protected]

Definition at line 153 of file sdet_detector.h.

Only return valeys, d^2I/dn^2 > 0.

Definition at line 162 of file sdet_detector_params.h.

vcl_vector<vtol_vertex_2d_sptr >* sdet_detector::vertices [protected]

network of linked

Definition at line 164 of file sdet_detector.h.

Definition at line 156 of file sdet_detector.h.


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