MCPcopy Create free account
hub / github.com/PointCloudLibrary/pcl / get_Q

Method get_Q

ml/src/svm.cpp:1587–1609  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1585 }
1586
1587 Qfloat*
1588 get_Q(int i, int len) const override
1589 {
1590 Qfloat* data;
1591 int j, real_i = index[i];
1592
1593 if (cache->get_data(real_i, &data, l) < l) {
1594 for (j = 0; j < l; j++)
1595 data[j] = static_cast<Qfloat>((this->*kernel_function)(real_i, j));
1596 }
1597
1598 // reorder and copy
1599 Qfloat* buf = buffer[next_buffer];
1600
1601 next_buffer = 1 - next_buffer;
1602
1603 schar si = sign[i];
1604
1605 for (j = 0; j < len; j++)
1606 buf[j] = static_cast<Qfloat>(si) * static_cast<Qfloat>(sign[j]) * data[index[j]];
1607
1608 return buf;
1609 }
1610
1611 double*
1612 get_QD() const override

Callers

nothing calls this directly

Calls 1

get_dataMethod · 0.80

Tested by

no test coverage detected