Home
last modified time | relevance | path

Searched refs:coef_ (Results 1 – 25 of 185) sorted by relevance

12345678

/dports/science/py-scikit-learn/scikit-learn-1.0.2/sklearn/linear_model/tests/
H A Dtest_logistic.py496 assert_array_almost_equal(lr1.coef_, lr2.coef_)
500 assert_array_almost_equal(lr1.coef_, lr3.coef_)
595 assert_array_almost_equal(lr.coef_, lr_cv.coef_)
672 assert_array_almost_equal(lr.coef_, lr_str.coef_)
674 assert_array_almost_equal(lr_cv.coef_, lr_cv_str.coef_)
698 assert_array_almost_equal(clfs.coef_, clf.coef_)
763 assert_allclose(clf.coef_[2][np.newaxis, :], clf1.coef_)
791 assert clf.coef_.shape == clf_multi.coef_.shape
1103 assert_allclose(ref_i.coef_, clf_i.coef_, rtol=1e-2)
1324 assert_array_almost_equal(lr_cv.coef_, lr.coef_)
[all …]
H A Dtest_coordinate_descent.py714 assert_array_almost_equal(clf2.coef_, clf.coef_)
809 assert_array_almost_equal(clf.coef_[0], clf.coef_[1])
912 assert_almost_equal(clf.coef_, clf1.coef_[0])
924 assert_almost_equal(clf.coef_, clf1.coef_[0])
998 assert_allclose(clf1.coef_, clf2.coef_)
1195 assert_array_equal(clf.coef_, clf_float.coef_)
1313 assert_array_almost_equal(clf2.coef_, clf.coef_)
1474 assert_allclose(reg1.coef_, reg2.coef_)
1532 assert_allclose(reg_sw.coef_, reg.coef_)
1705 assert_allclose(ridge.coef_, enet.coef_)
[all …]
H A Dtest_quantile.py82 assert_allclose(model.coef_[0], coef, atol=1e-2)
84 assert model.coef_[0] >= 1
85 assert model.coef_[0] <= 10
96 assert_allclose(huber.coef_, quant.coef_, atol=1e-1)
168 assert_allclose(model.coef_, coef, rtol=0.6)
174 model_coef = np.r_[model.intercept_, model.coef_]
191 assert_allclose(model.coef_, res.x[1:])
220 assert_allclose(model2.coef_, a * model1.coef_, rtol=1e-5)
225 assert_allclose(model2.coef_, -a * model1.coef_, rtol=1e-5)
232 assert_allclose(model2.coef_, model1.coef_ + g_coef, rtol=1e-6)
[all …]
H A Dtest_huber.py37 assert_almost_equal(huber.coef_, lr.coef_, 3)
78 huber_coef = huber.coef_
88 assert_array_almost_equal(huber.coef_ / scale, huber_coef / scale)
95 huber_coef = huber.coef_
102 assert_array_almost_equal(huber.coef_ / scale, huber_coef / scale)
109 assert_array_almost_equal(huber_sparse.coef_ / scale, huber_coef / scale)
120 assert_array_almost_equal(huber_sparse.coef_, huber.coef_)
166 assert_array_almost_equal(huber.coef_, sgdreg.coef_, 1)
174 huber_warm_coef = huber_warm.coef_.copy()
179 assert_array_almost_equal(huber_warm.coef_, huber_warm_coef, 1)
[all …]
H A Dtest_sparse_coordinate_descent.py23 clf.coef_ = [1, 2, 3]
26 assert clf.sparse_coef_.toarray().tolist()[0] == clf.coef_
40 assert_array_almost_equal(clf_dense.coef_, clf_sparse.coef_)
50 assert_array_almost_equal(clf.coef_, [0])
69 assert_array_almost_equal(clf.coef_, [1])
83 assert_array_almost_equal(clf.coef_, [0.45454], 3)
108 assert_array_almost_equal(clf.coef_, [1])
122 assert_array_almost_equal(clf.coef_, [0.45454], 3)
196 assert_almost_equal(s_clf.coef_, d_clf.coef_, 5)
231 assert np.sum(s_clf.coef_ != 0.0) == n_informative
[all …]
H A Dtest_sgd.py288 assert_array_almost_equal(clf3.coef_, clf.coef_)
294 assert_array_almost_equal(clf3.coef_, clf2.coef_)
332 assert_array_equal(clf.coef_, clf2.coef_)
505 assert_array_equal(clf1.coef_, clf2.coef_)
964 assert_almost_equal(clf1.coef_, clf2.coef_)
1201 assert clf.coef_[0] == clf.coef_[1]
1513 assert_allclose(clf3.coef_, clf.coef_)
1519 assert_allclose(clf3.coef_, clf2.coef_)
1539 assert_array_equal(clf.coef_, clf2.coef_)
1772 assert_array_almost_equal(est_en.coef_, est_l1.coef_)
[all …]
H A Dtest_omp.py157 assert omp.coef_.shape == (n_features,)
159 assert np.count_nonzero(omp.coef_) <= n_nonzero_coefs
162 assert omp.coef_.shape == (n_targets, n_features)
166 coef_normalized = omp.coef_[0].copy()
169 assert_array_almost_equal(coef_normalized, omp.coef_)
173 assert np.count_nonzero(omp.coef_) <= n_nonzero_coefs
174 assert omp.coef_.shape == (n_features,)
178 assert omp.coef_.shape == (n_targets, n_features)
250 assert_array_almost_equal(ompcv.coef_, gamma_)
255 assert_array_almost_equal(ompcv.coef_, omp.coef_)
[all …]
H A Dtest_least_angle.py75 res = y - np.dot(X, coef_)
95 res = y - np.dot(X, coef_)
246 output_2 = clf.fit(X, y).coef_
268 coef_lars_ = lars.fit(X, y).coef_
300 err = linalg.norm(clf1.coef_ - clf2.coef_)
414 lars_coef_ = lars.coef_
465 estimator.coef_,
654 err = linalg.norm(clf1.coef_ - clf2.coef_)
865 assert np.mean((est.coef_ - est_jitter.coef_) ** 2) > 0.1
908 assert model.coef_.dtype == dtype
[all …]
H A Dtest_ridge.py300 assert_almost_equal(ridge.coef_, ols.coef_)
304 assert_almost_equal(ridge.coef_, ols.coef_)
539 assert_allclose(gcv_ridge.coef_, loo_ridge.coef_, rtol=1e-3)
569 assert_allclose(gcv_ridge.coef_, loo_ridge.coef_, rtol=1e-3)
641 assert_allclose(gcv_ridge.coef_, kfold.coef_, rtol=1e-3)
1004 assert_array_almost_equal(reg.coef_, rega.coef_)
1017 assert_almost_equal(reg1.coef_, reg2.coef_)
1027 assert_almost_equal(reg1.coef_, reg2.coef_)
1034 assert_almost_equal(reg1.coef_, reg2.coef_)
1304 assert np.allclose(dense_ridge.coef_, sparse_ridge.coef_)
[all …]
H A Dtest_theil_sen.py169 assert np.abs(lstq.coef_ - w) > 0.9
172 assert_array_almost_equal(theil_sen.coef_, w, 1)
180 assert np.abs(lstq.coef_ - w - c) > 0.5
183 assert_array_almost_equal(theil_sen.coef_, w + c, 1)
194 assert norm(lstq.coef_ - w) > 1.0
197 assert_array_almost_equal(theil_sen.coef_, w, 1)
241 assert_array_almost_equal(theil_sen.coef_, w, 1)
250 assert_array_almost_equal(theil_sen.coef_, lstq.coef_, 9)
265 assert norm(lstq.coef_ - w) > 1.0
270 assert_array_almost_equal(theil_sen.coef_, w, 1)
[all …]
/dports/science/py-scikit-learn/scikit-learn-1.0.2/sklearn/linear_model/
H A D_bayes.py311 coef_old_ = np.copy(coef_)
383 coef_ = np.linalg.multi_dot(
387 coef_ = np.linalg.multi_dot(
393 return coef_, rmse_
625 coef_ = np.zeros(n_features)
657 return coef_
667 coef_ = update_coeff(X, y, coef_, alpha_, keep_lambda, sigma_)
681 coef_[~keep_lambda] = 0
700 coef_old_ = np.copy(coef_)
708 coef_ = update_coeff(X, y, coef_, alpha_, keep_lambda, sigma_)
[all …]
H A D_base.py369 self.coef_ = self.coef_ / X_scale
370 self.intercept_ = y_offset - np.dot(X_offset, self.coef_.T)
471 if sp.issparse(self.coef_):
472 self.coef_ = self.coef_.toarray()
503 self.coef_ = sp.csr_matrix(self.coef_)
685 self.coef_, self._residues = optimize.nnls(X, y)
691 self.coef_, self._residues = map(np.vstack, zip(*outs))
707 self.coef_ = out[0]
715 self.coef_ = np.vstack([out[0] for out in outs])
719 self.coef_ = self.coef_.T
[all …]
H A D_coordinate_descent.py610 coef_,
634 coef_,
1027 coef_ = self.coef_
1029 coef_ = coef_[np.newaxis, :]
1067 self.coef_ = coef_[0]
1070 self.coef_ = coef_
1076 self.coef_ = np.asarray(self.coef_, dtype=X.dtype)
1719 self.coef_ = model.coef_
2430 self.coef_ = np.asfortranarray(self.coef_) # coef contiguous in memory
2437 self.coef_,
[all …]
H A D_stochastic_gradient.py72 est.coef_ = coef.reshape(1, -1)
208 self.coef_ = coef_init
336 coef = est.coef_.ravel()
345 coef = est.coef_[i]
665 self.coef_ = None
1479 self.coef_ = None
1613 coef = self.coef_
1661 self.coef_ = coef
2174 coef = self.coef_
2223 self.coef_ = coef
[all …]
/dports/math/xlife++/xlifepp-sources-v2.0.1-2018-05-09/src/term/
H A DSymbolicTermMatrix.cpp64 coef_=S.coef_; in SymbolicTermMatrix()
88 coef_=S.coef_; in operator =()
186 {S.coef_*=c; return S;} in operator *()
189 {S.coef_*=c; return S;} in operator *()
192 {S.coef_/=c; return S;} in operator /()
204 if (coef_.imag()==0) out<< coef_.real(); in asString()
205 else out<<coef_; in asString()
270 if (S.coef_.imag()==0) R*=S.coef_.real(); in multMatrixVector()
271 else R*=S.coef_; in multMatrixVector()
294 if(S.coef_.imag()==0) R*=S.coef_.real(); in multVectorMatrix()
[all …]
/dports/science/py-scikit-learn/scikit-learn-1.0.2/examples/cluster/
H A Dplot_feature_agglomeration_vs_univariate_selection.py74 coef_ = clf.best_estimator_.steps[-1][1].coef_ variable
75 coef_ = clf.best_estimator_.steps[0][1].inverse_transform(coef_) variable
76 coef_agglomeration_ = coef_.reshape(size, size)
85 coef_ = clf.best_estimator_.steps[-1][1].coef_ variable
86 coef_ = clf.best_estimator_.steps[0][1].inverse_transform(coef_.reshape(1, -1)) variable
87 coef_selection_ = coef_.reshape(size, size)
/dports/science/py-scikit-learn/scikit-learn-1.0.2/examples/linear_model/
H A Dplot_huber_vs_ridge.py50 coef_ = huber.coef_ * x + huber.intercept_ variable
51 plt.plot(x, coef_, colors[k], label="huber loss, %s" % epsilon)
56 coef_ridge = ridge.coef_
57 coef_ = ridge.coef_ * x + ridge.intercept_ variable
58 plt.plot(x, coef_, "g-", label="ridge regression")
H A Dplot_lasso_and_elasticnet.py62 np.where(enet.coef_)[0],
63 enet.coef_[enet.coef_ != 0],
70 np.where(lasso.coef_)[0],
71 lasso.coef_[lasso.coef_ != 0],
H A Dplot_lasso_dense_vs_sparse_data.py40 % linalg.norm(sparse_lasso.coef_ - dense_lasso.coef_)
68 % linalg.norm(sparse_lasso.coef_ - dense_lasso.coef_)
/dports/science/py-scikit-learn/scikit-learn-1.0.2/sklearn/linear_model/_glm/tests/
H A Dtest_glm.py192 assert_allclose(glm.coef_, coef, rtol=1e-12)
210 coef = glm.coef_.copy()
215 assert_allclose(glm.coef_, coef, rtol=1e-12)
220 assert_allclose(glm.coef_, coef, rtol=1e-12)
227 coef1 = glm.coef_.copy()
229 assert_allclose(glm.coef_, coef1, rtol=1e-12)
243 assert_allclose(glm1.coef_, glm2.coef_)
272 assert_allclose(res.coef_, coef, rtol=2e-6)
305 assert_allclose(glm1.coef_, glm2.coef_, rtol=1e-5)
366 assert glm.coef_.shape == (X.shape[1],)
[all …]
/dports/math/symengine/symengine-0.8.1/symengine/
H A Dmul.cpp11 : coef_{coef}, dict_{std::move(dict)} in Mul()
82 hash_combine<Basic>(seed, *coef_); in __hash__()
92 if (is_a<Mul>(o) and eq(*coef_, *(down_cast<const Mul &>(o).coef_)) in __eq__()
108 int cmp = coef_->__cmp__(*s.coef_); in compare()
293 or (neq(*m->coef_, *one) and neq(*m->coef_, *minus_one))) { in dict_add_term_new()
466 new_coef = pow(coef_, exp); in power_num()
480 if (coef_->is_negative()) { in power_num()
486 } else if (coef_->is_positive() and not coef_->is_one()) { in power_num()
502 imulnum(coef, tmp->coef_); in power_num()
516 if (not coef_->is_one()) { in get_args()
[all …]
/dports/science/py-scikit-learn/scikit-learn-1.0.2/sklearn/svm/tests/
H A Dtest_sparse.py62 assert sparse.issparse(sparse_svm.coef_)
63 assert_array_almost_equal(dense_svm.coef_, sparse_svm.coef_.toarray())
130 svm.SVC(kernel="linear", probability=True, random_state=0).fit(X, y).coef_
135 coef_sorted = sparse_svc.coef_
158 coef_unsorted = unsorted_svc.coef_
190 assert_array_almost_equal(clf.coef_, sp_clf.coef_.toarray())
203 dec = safe_sparse_dot(iris.data, clf.coef_.T) + clf.intercept_
209 dec = np.dot(X, clf.coef_.T) + clf.intercept_
246 assert_array_almost_equal(clf.coef_, sp_clf.coef_, decimal=4)
254 assert_array_almost_equal(clf.coef_, sp_clf.coef_, decimal=4)
[all …]
/dports/science/mpqc/mpqc-2.3.1/src/lib/chemistry/molecule/
H A Dcoor.cc412 coef_.resize(n); in SumIntCoor()
415 s.get(coef_[i]); in SumIntCoor()
427 int n = coef_.size(); in save_data_state()
432 s.put(coef_[i]); in save_data_state()
440 return coef_.size(); in n()
464 coef_[l] = coef; in add()
480 int n = coef_.size(); in normalize()
485 norm += coef_[i] * coef_[i]; in normalize()
486 if (fabs(biggest) < fabs(coef_[i])) biggest = coef_[i]; in normalize()
491 coef_[i] = coef_[i]*norm; in normalize()
[all …]
/dports/science/mpqc/mpqc-2.3.1/src/lib/chemistry/qc/mbpt/
H A Dmp2extrap.cc63 coef_[0] = 0.184090909090909; in MP2BasisExtrap()
64 coef_[1] = -1.551515151515153; in MP2BasisExtrap()
65 coef_[2] = 2.367424242424244; in MP2BasisExtrap()
133 val += coef_[i] * mbpt2[i]->corr_energy(); in compute()
144 coef_[i], mbpt2[i]->corr_energy()) in compute()
161 gradientvec.accumulate(coef_[i] * mbpt2[i]->corr_energy_gradient()); in compute()
/dports/science/py-hiphive/hiphive-0.7.1/hiphive/fitting/
H A Dfit_methods.py157 results['parameters'] = lasso.coef_
202 results['parameters'] = lassoCV.coef_
242 x_new = lasso.coef_ / weights
315 results['parameters'] = ridge.coef_
339 results['parameters'] = brr.coef_
472 results['parameters'] = ardr.coef_
530 self.coef_ = None
535 self.coef_ = results['parameters']
543 return np.dot(A, self.coef_)
654 parameters = ompcv.coef_
[all …]

12345678