Definition at line 1323 of file svm.cpp.
◆ ONE_CLASS_Q()
Definition at line 1326 of file svm.cpp.
1327 :
Kernel(prob.l, prob.x, param)
1328 {
1329 cache =
new Cache(prob.l,(
long int)(param.cache_size*(1<<20)));
1330 QD = new double[prob.l];
1331 for(int i=0;i<prob.l;i++)
1332 QD[i] = (this->*kernel_function)(i,i);
1333 }
◆ ~ONE_CLASS_Q()
ONE_CLASS_Q::~ONE_CLASS_Q |
( |
| ) |
|
|
inline |
Definition at line 1359 of file svm.cpp.
1360 {
1361 delete cache;
1362 delete[] QD;
1363 }
◆ get_Q()
Qfloat * ONE_CLASS_Q::get_Q |
( |
int |
i, |
|
|
int |
len |
|
) |
| const |
|
inlinevirtual |
Implements Kernel.
Definition at line 1335 of file svm.cpp.
1336 {
1337 Qfloat *data;
1338 int start, j;
1339 if((start = cache->get_data(i,&data,len)) < len)
1340 {
1341 for(j=start;j<len;j++)
1342 data[j] = (Qfloat)(this->*kernel_function)(i,j);
1343 }
1344 return data;
1345 }
◆ get_QD()
double * ONE_CLASS_Q::get_QD |
( |
| ) |
const |
|
inlinevirtual |
Implements Kernel.
Definition at line 1347 of file svm.cpp.
1348 {
1349 return QD;
1350 }
◆ swap_index()
void ONE_CLASS_Q::swap_index |
( |
int |
i, |
|
|
int |
j |
|
) |
| const |
|
inlinevirtual |
Reimplemented from Kernel.
Definition at line 1352 of file svm.cpp.
1353 {
1354 cache->swap_index(i,j);
1355 Kernel::swap_index(i,j);
1356 swap(QD[i],QD[j]);
1357 }
The documentation for this class was generated from the following file:
- /usr/src/slapt-src/gis/pktools/PKTOOLS-2.6.7.6/src/algorithms/svm.cpp