Commit Graph

639 Commits

Author SHA1 Message Date
Lars Buitinck 77b4670b6a COSMIT use np.clip in SGD 2012-10-29 00:47:00 +01:00
Mathieu Blondel f65efcf8eb More use sklearn.utils.testing.
My model is training :)
2012-10-25 21:21:22 +09:00
Andreas Mueller 66fc97708a ENH don't use deprecated interface in PPCA & cosmit 2012-10-18 14:09:48 +02:00
Andreas Mueller e64cea0342 ENH add random seed to logistic regression 2012-10-18 13:48:10 +02:00
Lars Buitinck 60ae168464 COSMIT rm unused import 2012-10-16 14:36:49 +02:00
Andreas Mueller a06c367ba2 ENH sparse matrix support in randomized logistic regression 2012-10-16 14:34:48 +02:00
Fabian Pedregosa 8d3c75feff Store X as an ordered array.
This simplifies and makes more efficient the `fit` and transform
method (re-ordering in transform is no longer needed).
2012-10-16 14:18:43 +02:00
Fabian Pedregosa 04251e155d Better tests + cosmetic changes. 2012-10-16 14:18:43 +02:00
Fabian Pedregosa 342c5be9f1 ENH: Consider order in X for IsotonicRegression.
Before, IsotonicRegression assumed X was an increasing sequence. This
allows to shuffle both X, y (see the test) and obtain the same
result. This makes IsotonicRegression behave more like a standard
Regression (which is what I would expect).
2012-10-16 14:18:43 +02:00
Lars Buitinck 53b220358c COSMIT correct error msgs in SGD and make them more consistent 2012-10-14 12:09:59 +02:00
Lars Buitinck 97ed66151a BUG + DOC l1_ratio in SGD and CD
SGD{Classifier,Regressor} treated l1_ratio as previously rho. Docstrings
stated that l1_ratio must be >0, which means pure L2 regularization would
not be possible.
2012-10-14 11:43:26 +02:00
Andreas Mueller 72e71bb439 ENH address @agramfort's comments, fix some doctests 2012-10-11 20:56:03 +01:00
Andreas Mueller b39609af4e ENH rename rho in SGD 2012-10-11 20:56:03 +01:00
Andreas Mueller 16aabc7c3f ENH rename rho to l1_ratio in ElasticNet and friends 2012-10-11 20:56:03 +01:00
Lars Buitinck 9423e9c808 DOC various typos and other minor stuff 2012-10-11 11:26:22 +02:00
Andreas Mueller 57001002bb COSMIT pep8 2012-10-10 09:38:10 +02:00
Immanuel Bayer 03b8829a83 extend eps_ description 2012-10-08 19:35:39 +02:00
Immanuel Bayer 9701bb81ac add dual_gap_ and eps_ to Enet and Lasso docstring 2012-10-08 17:04:59 +02:00
Gael Varoquaux 55ef1d617a DOC: protect `classes_` for valid rst 2012-10-07 16:39:40 +02:00
Luis Pedro Coelho 0984a2a59f cd_fast: use square norm directly
Previously the ℓ₂ norm was computed (which uses a sqrt), then squared.
Also, ℓ₂ norm is computed using np.dot.
2012-10-03 19:12:47 -07:00
Olivier Grisel 244e8a68fa Merge pull request #1187 from ogrisel/bugfix-logistic-ovr-probabilities
MRG: FIX: wrong probabilities for OvR LogisticRegression
2012-09-30 06:09:51 -07:00
Gael Varoquaux db37872f5e DOC: Enet alpha=0 => advice to use LinearRegression 2012-09-29 18:50:34 +02:00
Mathieu Blondel 0c2b07f492 Fix warning message. 2012-09-29 02:16:06 +09:00
Mathieu Blondel 2a7ebd955f Cosmit: not a fan of defining a function in a loop :) 2012-09-29 02:16:06 +09:00
Mathieu Blondel 7575410adc PEP8! 2012-09-29 02:16:06 +09:00
Mathieu Blondel 71fd662f63 Better documentation on the choice of solver. 2012-09-29 02:16:06 +09:00
Mathieu Blondel 15ce0557b2 lsqr is not available in old scipy versions... 2012-09-29 02:16:06 +09:00
Mathieu Blondel 1e117305b6 Fall back to dense_cholesky if sample_weight is given. 2012-09-29 02:16:05 +09:00
Mathieu Blondel c5892aabb8 Fix damp parameter. 2012-09-29 02:16:05 +09:00
Mathieu Blondel ec07896195 Add minimalistic test for each solver. 2012-09-29 02:16:05 +09:00
Mathieu Blondel abee624bf6 Fix docstrings and doctests. 2012-09-29 02:16:05 +09:00
Mathieu Blondel 047109233f BUG: transmit parameters correctly from Ridge to ridge_regression. 2012-09-29 02:16:05 +09:00
Mathieu Blondel 107abb6f3e Add lsqr solver. 2012-09-29 02:16:05 +09:00
Mathieu Blondel 2cae34b059 Move solver option to constructor. 2012-09-29 02:16:05 +09:00
Olivier Grisel fa93e209ff FIX: wrong probabilities for OvR LogisticRegression 2012-09-28 19:13:46 +02:00
Gael Varoquaux e0d45a99f8 BUG: remove leftout debug prints
Bad bad bad @GaelVaroquaux
2012-09-28 09:41:31 +02:00
Gael Varoquaux 7842748cf7 BUG: copy and keep ordering
This is due to a change in behavior in numpy that now does
not keep the ordering by default when copying.

Fixes #1186
2012-09-28 09:32:03 +02:00
Andreas Mueller 3941a4b34a COSMIT pep8 2012-09-23 18:03:07 +01:00
Andreas Mueller c0a057843c ENH rename Scaler to StandardScaler everywhere 2012-09-23 17:31:15 +01:00
Fabian Pedregosa b5339a9f24 Added the paper I used to implement isotonic_regression. 2012-09-22 22:06:55 +02:00
Lars Buitinck a164d57e74 TST writable coef_ and intercept_ on LogisticRegression
Solves issue #470.
2012-09-20 23:04:52 +02:00
Lars Buitinck 3ca3e95b72 DOC rm references to deprecated stuff 2012-09-20 22:15:39 +02:00
Lars Buitinck 77e69edcec COSMIT rm deprecated stuff -- lots of it 2012-09-20 21:40:33 +02:00
Lars Buitinck 46f4c55787 Merge pull request #1169 from larsmans/ridge-cg
Ridge CG performance improvements
2012-09-20 12:01:27 -07:00
Andreas Mueller 1313f25cda COSMIT pep8 2012-09-20 14:49:14 +01:00
Lars Buitinck d93b33ed1a ENH add max_iter argument to Ridge estimators 2012-09-19 14:08:52 +02:00
Fabian Pedregosa 33efa17665 ENH Improve Ridge's conjugate gradient descent
Reorder terms in the algorithm so that X'X is not explicitly computed and
add LinearOperator as accepted types. This improves precedent code in two ways:

    * Speed: I get speedups ranging from 2.5x to more than 10x.
      Benchmark suite can be seen here: https://gist.github.com/1322711
      where I print the time spent for various sizes and densities.

    * Interface. By allowing a LinearOperator type, we can use the
      conjugate gradient method almost for free on dense matrices with
      special structure, pytables, etc., about anything that
      implements a fast matrix-vector product.
2012-09-19 14:08:52 +02:00
Lars Buitinck 35704c8351 COSMIT rm deprecated class_weight from fit in Ridge 2012-09-19 14:08:41 +02:00
Lars Buitinck 4183cb3b34 COSMIT use LinearClassifierMixin in RidgeClassifier
Had to change a test due to different tie breaking.
2012-09-17 23:22:16 +02:00
Lars Buitinck 88a0e5dccf TST improve Ridge test 2012-09-17 23:22:16 +02:00