Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- IKernel kernel = new DynamicTimeWarping(dimension);
- var machine = new MulticlassSupportVectorMachine(0, kernel, 2);
- // Create the Multi-class learning algorithm for the machine
- var teacher = new MulticlassSupportVectorLearning(machine, inputs.ToArray(), outputs.ToArray());
- // Configure the learning algorithm to use SMO to train the
- // underlying SVMs in each of the binary class subproblems.
- teacher.Algorithm = (svm, classInputs, classOutputs, i, j) =>
- new SequentialMinimalOptimization(svm, classInputs, classOutputs)
- {
- Complexity = 1.5
- };
- // Run the learning algorithm
- double error = teacher.Run();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement