26int main(
int argc,
char** argv)
29 unsigned int ell = 500;
30 unsigned int tests = 10000;
34 size_t budgetSize = 16;
51 kernelBudgetedSGDtrainer.
setEpochs(epochs);
54 std::cout <<
"Training the " << kernelBudgetedSGDtrainer.
name() <<
" on the problem with a budget of " << budgetSize <<
" and " << epochs <<
" Epochs..." << std::endl;
55 kernelBudgetedSGDtrainer.
train(kernelClassifier, trainingData);
58 std::cout <<
"We have " << nSupportVectors <<
" support vectors in our model.\n";
63 double train_error = loss.
eval(trainingData.
labels(), output);
64 cout <<
"training error:\t" << train_error << endl;
65 output = kernelClassifier(testData.
inputs());
66 double test_error = loss.
eval(testData.
labels(), output);
67 cout <<
"test error:\t" << test_error << endl;