- Author
- Karel Lenc
-
Andrea Vedaldi
-
Michal Perdoch
scalespace.h implements a Gaussian scale space, a data structure representing an image at multiple resolutions [33] [13] [14] . Scale spaces have many use, including the detection of co-variant local features [15] such as SIFT, Hessian-Affine, Harris-Affine, Harris-Laplace, etc. Getting started demonstreates how to use the C API to compute the scalespace of an image. For further details refer to:
Getting started
Given an input image image, the following example uses the VlScaleSpace object to compute its Gaussian scale space and return the image level at scale (o,s), where o is the octave and s is the octave subdivision or sublevel:
float* level ;
float * vl_scalespace_get_level(VlScaleSpace *self, vl_index o, vl_index s)
Get the data of a scale space level.
Definition scalespace.c:390
void vl_scalespace_put_image(VlScaleSpace *self, float const *image)
Initialise Scale space with new image.
Definition scalespace.c:812
VlScaleSpace * vl_scalespace_new(vl_size width, vl_size height)
Create a new scale space object.
Definition scalespace.c:536
The image level is obtained by convolving image by a Gaussian filter of isotropic standard deviation given by
double sigma = vl_scalespace_get_sigma(ss, o, s) ;
The resolution of level is in general different from the resolution of image and is determined by the octave o. It can be obtained as follows:
VlScaleSpaceOctaveGeometry vl_scalespace_get_octave_geometry(VlScaleSpace const *self, vl_index o)
Get the geometry of an octave of the scalespace.
Definition scalespace.c:369
Geometry of one octave of a scale space.
Definition scalespace.h:54
vl_size height
Definition scalespace.h:56
double step
Definition scalespace.h:57
vl_size width
Definition scalespace.h:55
The parameter ogeom.step is the sampling step relatively to the sampling of the input image image. The ranges of valid octaves and scale sublevels can be obtained as
VlScaleSpaceGeometry vl_scalespace_get_geometry(VlScaleSpace const *self)
Get the geometry of the scale space.
Definition scalespace.c:357
Geometry of a scale space.
Definition scalespace.h:32
vl_index lastOctave
Definition scalespace.h:36
vl_index octaveLastSubdivision
Definition scalespace.h:39
vl_size octaveResolution
Definition scalespace.h:37
vl_index octaveFirstSubdivision
Definition scalespace.h:38
vl_index firstOctave
Definition scalespace.h:35
So for example o minimum value is geom.firstOctave and maximum value is geom.lastOctave. The subdivision index s naturally spans the range 0 to geom.octaveResolution-1. However, the scale space object is flexible in that it allows different ranges of subdivisions to be computed and s varies in the range geom.octaveFirstSubdivision to geom.octaveLastSubdivision. See Gaussian scale space fundamentals for further details.
The geometry of the scale space can be customized upon creation, as follows:
VlScaleSpace * vl_scalespace_new_with_geometry(VlScaleSpaceGeometry geom)
Create a new scale space with the specified geometry.
Definition scalespace.c:558
VlScaleSpaceGeometry vl_scalespace_get_default_geometry(vl_size width, vl_size height)
Get the default geometry for a given image size.
Definition scalespace.c:306