Lines Matching refs:sample_count
413 sample_count = _sample_count; in create()
431 buf[i] = (Qfloat*)cvMemStorageAlloc( storage, sample_count*2*sizeof(buf[i][0]) ); in create()
452 cache_line_size = sample_count*sizeof(Qfloat); in create()
455 cache_size = MAX( cache_line_size*sample_count/4, CV_SVM_MIN_CACHE_SIZE ); in create()
458 rows_hdr_size = sample_count*sizeof(rows[0]); in create()
476 int i1 = i < sample_count ? i : i - sample_count; in get_row_base()
506 kernel->calc( sample_count, var_count, samples, samples[i1], row->data ); in get_row_base()
521 int j, len = sample_count; in get_row_svc()
522 assert( _y && i < sample_count ); in get_row_svc()
547 int j, len = sample_count; in get_row_svr()
965 for( i = 0; i < sample_count; i++ ) in solve_c_svc()
974 for( i = 0; i < sample_count; i++ ) in solve_c_svc()
993 sum_pos = kernel->params->nu * sample_count * 0.5; in solve_nu_svc()
994 sum_neg = kernel->params->nu * sample_count * 0.5; in solve_nu_svc()
996 for( i = 0; i < sample_count; i++ ) in solve_nu_svc()
1016 for( i = 0; i < sample_count; i++ ) in solve_nu_svc()
1040 y = (schar*)cvMemStorageAlloc( storage, sample_count*sizeof(y[0]) ); in solve_one_class()
1041 n = cvRound( nu*sample_count ); in solve_one_class()
1043 for( i = 0; i < sample_count; i++ ) in solve_one_class()
1050 if( n < sample_count ) in solve_one_class()
1051 alpha[n] = nu * sample_count - n; in solve_one_class()
1053 alpha[n-1] = nu * sample_count - (n-1); in solve_one_class()
1071 y = (schar*)cvMemStorageAlloc( storage, sample_count*2*sizeof(y[0]) ); in solve_eps_svr()
1074 for( i = 0; i < sample_count; i++ ) in solve_eps_svr()
1080 alpha[i+sample_count] = 0; in solve_eps_svr()
1081 b[i+sample_count] = p + _y[i]; in solve_eps_svr()
1082 y[i+sample_count] = -1; in solve_eps_svr()
1088 for( i = 0; i < sample_count; i++ ) in solve_eps_svr()
1089 _alpha[i] = alpha[i] - alpha[i+sample_count]; in solve_eps_svr()
1107 y = (schar*)cvMemStorageAlloc( storage, sample_count*2*sizeof(y[0]) ); in solve_nu_svr()
1109 sum = C * _kernel->params->nu * sample_count * 0.5; in solve_nu_svr()
1111 for( i = 0; i < sample_count; i++ ) in solve_nu_svr()
1113 alpha[i] = alpha[i + sample_count] = MIN(sum, C); in solve_nu_svr()
1119 b[i + sample_count] = _y[i]; in solve_nu_svr()
1120 y[i + sample_count] = -1; in solve_nu_svr()
1126 for( i = 0; i < sample_count; i++ ) in solve_nu_svr()
1127 _alpha[i] = alpha[i] - alpha[i+sample_count]; in solve_nu_svr()
1282 bool CvSVM::train1( int sample_count, int var_count, const float** samples, in train1() argument
1297 …ok = svm_type == C_SVC ? solver->solve_c_svc( sample_count, var_count, samples, (schar*)_responses, in train1()
1299 … svm_type == NU_SVC ? solver->solve_nu_svc( sample_count, var_count, samples, (schar*)_responses, in train1()
1301 svm_type == ONE_CLASS ? solver->solve_one_class( sample_count, var_count, samples, in train1()
1303 … svm_type == EPS_SVR ? solver->solve_eps_svr( sample_count, var_count, samples, (float*)_responses, in train1()
1305 … svm_type == NU_SVR ? solver->solve_nu_svr( sample_count, var_count, samples, (float*)_responses, in train1()
1316 bool CvSVM::do_train( int svm_type, int sample_count, int var_count, const float** samples, in do_train() argument
1337 if( !train1( sample_count, var_count, samples, svm_type == ONE_CLASS ? 0 : in do_train()
1341 for( i = 0; i < sample_count; i++ ) in do_train()
1348 for( i = k = 0; i < sample_count; i++ ) in do_train()
1385 CV_CALL( sv_tab = (int*)cvMemStorageAlloc( temp_storage, sample_count*sizeof(sv_tab[0]) )); in do_train()
1386 memset( sv_tab, 0, sample_count*sizeof(sv_tab[0]) ); in do_train()
1390 sample_count*sizeof(temp_samples[0]))); in do_train()
1391 CV_CALL( temp_y = (schar*)cvMemStorageAlloc( temp_storage, sample_count)); in do_train()
1483 for( i = 0, k = 0; i < sample_count; i++ ) in do_train()
1492 for( i = 0, k = 0; i < sample_count; i++ ) in do_train()
1537 int svm_type, sample_count, var_count, sample_size; in train() local
1552 false, &samples, &sample_count, &var_count, &var_all, in train()
1560 block_size = MAX( block_size, sample_count*(int)sizeof(CvSVMKernelRow)); in train()
1561 block_size = MAX( block_size, sample_count*2*(int)sizeof(double) + 1024 ); in train()
1566 CV_CALL( alpha = (double*)cvMemStorageAlloc(temp_storage, sample_count*sizeof(double))); in train()
1571 if( !do_train( svm_type, sample_count, var_count, samples, responses, temp_storage, alpha )) in train()
1605 int svm_type, sample_count, var_count, sample_size; in train_auto() local
1705 false, &samples, &sample_count, &var_count, &var_all, in train_auto()
1712 block_size = MAX( block_size, sample_count*(int)sizeof(CvSVMKernelRow)); in train_auto()
1713 block_size = MAX( block_size, sample_count*2*(int)sizeof(double) + 1024 ); in train_auto()
1718 CV_CALL(alpha = (double*)cvMemStorageAlloc(temp_storage, sample_count*sizeof(double))); in train_auto()
1724 const int testset_size = sample_count/k_fold; in train_auto()
1725 const int trainset_size = sample_count - testset_size; in train_auto()
1726 const int last_testset_size = sample_count - testset_size*(k_fold-1); in train_auto()
1727 const int last_trainset_size = sample_count - last_testset_size; in train_auto()
1740 for( i = 0; i < sample_count; i++ ) in train_auto()
1742 int i1 = cvRandInt( &rng ) % sample_count; in train_auto()
1743 int i2 = cvRandInt( &rng ) % sample_count; in train_auto()
1790 sizeof(samples[0])*(sample_count - testset_size*(k+1)) ); in train_auto()
1795 sizeof(samples[0])*(sample_count - testset_size*(k+1)) ); in train_auto()
1850 min_error /= (float) sample_count; in train_auto()
1859 …CV_CALL(ok = do_train( svm_type, sample_count, var_count, samples, responses, temp_storage, alpha … in train_auto()