From 14c854543b1a3cf344a371a5b45595657f95786b Mon Sep 17 00:00:00 2001 From: leochanj105 Date: Tue, 26 Oct 2021 13:22:32 -0400 Subject: add deadlines and costs --- SD-VBS/benchmarks/svm/src/c/getAlphaFromTrainSet.c | 98 ---------------------- 1 file changed, 98 deletions(-) delete mode 100644 SD-VBS/benchmarks/svm/src/c/getAlphaFromTrainSet.c (limited to 'SD-VBS/benchmarks/svm/src/c/getAlphaFromTrainSet.c') diff --git a/SD-VBS/benchmarks/svm/src/c/getAlphaFromTrainSet.c b/SD-VBS/benchmarks/svm/src/c/getAlphaFromTrainSet.c deleted file mode 100644 index 681f2c6..0000000 --- a/SD-VBS/benchmarks/svm/src/c/getAlphaFromTrainSet.c +++ /dev/null @@ -1,98 +0,0 @@ -/******************************** -Author: Sravanthi Kota Venkata -********************************/ - -#include "svm.h" - -alphaRet* getAlphaFromTrainSet(int N, F2D* trn1, F2D* trn2, int iterations) -{ - float tolerance, C, eps, *b; - F2D *a_result, *b_result; - int NumChanged, r, ExamineAll, cnt, d, dim, ret, iter, i; - F2D *X, *Y; - F2D *a, *e; - - b = malloc(sizeof(float)); - alphaRet* alpha; - alpha = (alphaRet*)malloc(sizeof(alphaRet)); - tolerance = 0.001; - C = 0.05; - d = -1; - dim = 256; - eps = 0.001; - a_result = fSetArray(iterations, N, 0); - b_result = fSetArray(iterations, 1, 0); - ret = 0; - - X = usps_read_partial( trn1, trn2, 0, 1, (N/iterations), iterations); - - for(iter=0; iter0 || ExamineAll == 1) - { - cnt = cnt + 1; - NumChanged = 0; - if(ExamineAll == 1) - { - for(i=0; i 0 && asubsref(a,i) C = C; - alpha->d = d; - alpha->dim = dim; - alpha->eps = eps; - alpha->a_result = a_result; - alpha->b_result = b_result; - alpha->a = a; - alpha->b = arrayref(b,0); - alpha->X = X; - alpha->tolerance = tolerance; - alpha->ret; - - free(b); - - return alpha; - -} - - - - -- cgit v1.2.2