Documentation - C API
svmdataset.c File Reference

Svm Dataset - Definition. More...

#include "svmdataset.h"
#include <string.h>
#include <math.h>
#include "svmdataset.c"
#include "float.th"

Functions

VlSvmDatasetvl_svmdataset_new (void *data, vl_size dimension)
 Create a new SVM dataset structure.
void vl_svmdataset_set_map (VlSvmDataset *data, void *map, VlSvmDatasetFeatureMap mapFunc, vl_size order)
 Set feature map.
void vl_svmdataset_delete (VlSvmDataset *dataset)
 Delete a SVM dataset structure.

Detailed Description

Author:
Daniele Perrone

Function Documentation

void vl_svmdataset_delete ( VlSvmDataset dataset)
Parameters:
datasetSVM dataset to delete.

The function frees the resources allocated by vl_svmdataset_new(). Notice that only the structure will be freed and not the raw data referred by the pointer .

VlSvmDataset* vl_svmdataset_new ( void *  data,
vl_size  dimension 
)
Parameters:
datapointer to data.
dimensiondata point dimension.
Returns:
the new SVM dataset structure.

The function allocates and returns a new SVM dataset structure.

The data pointed by is not replicated, so the caller should keep the data allocated for the full usage of the structure.

See also:
vl_svmdataset_delete().
void vl_svmdataset_set_map ( VlSvmDataset data,
void *  map,
VlSvmDatasetFeatureMap  mapFunc,
vl_size  order 
)
Parameters:
dataSVM dataset Structure
mappointer to Feature Map Object
mapFuncfunction that perform the feature map
orderorder of the map

The function sets a feature map to the SVM dataset . The dimension of the extended data points is /f$2*order + 1/f$.