Commit Graph

251 Commits

Author SHA1 Message Date
Rüdiger Busche d300f406ae MAINT Simplify super() calls (#12812) 2019-01-10 22:27:06 +01:00
Andreas Mueller 952ef6637a MRG Drop legacy python / remove six dependencies (#12639) 2019-01-03 15:50:05 +02:00
Hanmin Qin bfc4a56642 MNT Duplicate import 2018-11-14 20:34:40 +08:00
Hanmin Qin 43e3a02085
MNT Remove unused assert_true imports (#12560) 2018-11-11 11:08:37 +08:00
Yaroslav Halchenko 362cb3bcab TST autoreplace assert_true(...==...) with plain assert (#12547) 2018-11-11 09:05:34 +08:00
Olivier Grisel 036dfdde21 Fix inconsistent labels returned by BayesianGaussianMixture.fit_predict (#12451) 2018-11-04 00:56:50 +11:00
jeremiedbb e50fc2af94 TST Fix test gaussian mixture warm start (#12452) 2018-10-25 13:58:22 +02:00
Oleksandr Pavlyk 63e5ae6319 TST Use same random seeds for both GaussianMixture.fit (#12307) 2018-10-07 11:13:32 +02:00
TakingItCasual 1e052e9da9 Converting http to https (2)... (#12292) 2018-10-04 23:06:14 +02:00
ZJ Poh adddf00433 [MRG] np.ones -> np.full (#11628) 2018-07-23 09:49:01 +02:00
Aurélien Geron beb2aa0395 [MRG+1] Fix lower_bound_ not equal to max lower bound in mixture models when n_init > 1 (#10870)
* Set lower_bound_ to max lower bound at the end of BaseMixture.fit(), fixes #10869

* Use a local lower_bound variable rather than self.lower_bound_ during training, in BaseMixture.fit()

* Remove extra empty line

* Update documentation and reduce test_init() iterations from 100 to 25

* Update whats_new/v0.20.rst to add mention of issue 10869, and reformat file to fit on 80 columns

* Remove extra line in whats_new/v0.20.rst

* Add tests for convergence detection in Gaussian mixtures when warm_start=True

* Remove unnecessary catch_exception blocks

* Fix tests since n_iter_ was recently fixed to be increased by 1

* Revert changes unrelated to PR 10870 in doc/whats_new/v0.20.rst

* Replace assert_* with plain asserts because of the move to pytest

* Remove comment in whats_new/v0.20.rst that will be added upon merging

* Replace single backticks with double backticks in doc string

* Limit is 79 characters per line, not 80.

* Remove the false convergence fix to treat it in a separate PR
2018-07-16 14:47:07 +02:00
Shu Haoran c303ed8ef2 ENH adding fit_predict to mixture models (#11281)
Fixes #10336
2018-07-03 12:43:26 +10:00
Andreas Mueller eec7649236 MAINT Complete 0.20 deprecations (#9570) 2018-06-24 23:06:26 +10:00
Joel Nothman 14764061f8
[MRG] DOC fix some sphinx warnings (#11241) 2018-06-21 20:43:21 +10:00
Roman Yurchak e8d8b8eeb0 TST: parametrize unit tests (#11074)
yield tests are deprecated in pytest and will be removed in pytest 4.0.
They all have been replaced by parametrize.
2018-06-08 14:59:33 +02:00
Guillaume Lemaitre a38067093f [MRG+1] FIX make n_iter_ being the number of iteration performed (#11015)
*
2018-04-24 07:24:53 +10:00
Loïc Estève 20661b5018
TST: only run doctests on numpy 1.14. (#10835)
Fix doctests due to numpy 1.14 formatting changes.
2018-03-27 07:44:40 +02:00
Félix Raimundo 9920bf98da Remove dp-derivation.rst. (#10857)
sklearn.mixture.dpgmm.py is deprecated and will be removed in version 0.20.
2018-03-22 16:09:27 +01:00
Mohamed Ali Jamaoui 58f84694a8 DOC Add reference to the glossary in the warm_start parameter description of public APIs (#10699) 2018-02-26 20:21:17 +08:00
Joel Nothman c3bdc0a89a
DOC clean up assorted type specifications (#10441) 2018-01-11 09:11:17 +11:00
Joel Nothman b939b5a29a FIX missing return in deprecated function 2017-10-10 09:57:08 +11:00
Albert Thomas 45dc891c96 [MRG+2] Clean common tests (#9340)
* rm dupes

* add check_supervised_y_no_nan in classifier checks: this implies changes for Ridge classifiers

* fix docstrings/comments

* FIX check fitting 1d X array raises error and FIX check fitting 2d array with only 1 feature either works or returns informative message

* modify check_fit2d_1sample in common tests so that it checks fitting either works or returns an informative message

* rm SpectralClustering case for the moment

* uniformize error messages for 1 sample case and fix SpectralClustering with ensure_min_samples=2

* add unit test for mean_shift when n_samples * quantile < 1

* FIX travis with ensure_min_samples=2 in _PLS

* try fix for failing tSNE test

* typos

* take @agramfort's review into account

* sc to fix string in gaussian_process

* add the class that is present to preserve information of previous message in gpc.py
2017-09-26 18:13:15 +02:00
Hanmin Qin 32ac22870d [MRG+1] Fix warnings in lgtm.com (remove redundant code) (#9719) 2017-09-14 11:42:58 +02:00
Joan Massich 76494a1462 [MRG+1] Remove hard dependency on nose (#9670) 2017-09-10 13:21:40 +10:00
Taehoon Lee 4ff7e8e658 Fix typos (#9476) 2017-08-02 14:02:59 +10:00
Balakumaran Manoharan 04be1a9799 [MRG + 1] DOC Fix Sphinx errors (#9420)
* Fix Rouseeuw1984 broken link

* Change label vbgmm to bgmm
Previously modified with PR #6651

* Change tag name
Old refers to new tag added with PR #7388

* Remove prefix underscore to match tag

* Realign to fit 80 chars

* Link to metrics.rst.
pairwise metrics yet to be documented

* Remove tag as LSHForest is deprecated

* Remove all references to randomized_l1 and sphx_glr_auto_examples_linear_model_plot_sparse_recovery.py.
It is deprecated.

* Fix few Sphinx warnings

* Realign to 80 chars

* Changes based on PR review

* Remove unused ref in calibration

* Fix link ref in covariance.rst

* Fix linking issues

* Differentiate Rouseeuw1999 tag within file.

* Change all duplicate Rouseeuw1999 tags

* Remove numbers from tag Rousseeuw
2017-07-30 15:22:10 +10:00
Taehoon Lee 28ad450a43 DOC Fix typos (#9386) 2017-07-17 15:51:46 +10:00
Melanie Goetz 8d61ccde63 Adding note to the docstring that BayesianGaussianMixture parameter weight_concentration_prior is commonly called gamma in the literature, per https://github.com/scikit-learn/scikit-learn/issues/8631 (#9371)
[MRG+2] BayesianGaussianMixture docstring change: weight_concentration_prior is commonly called gamma
2017-07-15 14:31:20 -07:00
Thomas Moreau cb1b6c4734 FIX t-SNE memory usage and many other optimizer issues (#9032)
Use a sparse matrix representation of the neighbors.
Re-factored the QuadTree implementation to avoid insertion errors.
Various fixes in the gradient descent schedule to get the Barnes Hut and exact solvers to behave more robustly and consistently.
2017-07-12 22:56:02 +02:00
Jean Helie ac41281451 [MRG+1] Fix alerts found with lgtm (#9278)
* compare values rather than references

* add __ne__ to class

* add missing self parameter

* properly initialise child class using super()

* remove useless loop variables and assigments

* remove useless return statements

* respect PEP8 style

* fix another flake8 check
2017-07-05 17:22:21 +10:00
Joel Nothman 73bf55f614 COSMIT do not set unused variable 2017-07-05 15:23:39 +10:00
Andreas Mueller 5271a193c3 MRG Sphinx fixes (#9155) 2017-06-28 17:00:13 +02:00
midinas fbcbc1b76c Documentation fix in mixture/base.py (#9237)
Documentation of the shape of _estimate_weighted_log_prob() function's return value is (n_samples, n_component)
2017-06-27 20:31:00 -07:00
Taehoon Lee d69395f4fb DOC Fix typos (#9229) 2017-06-27 11:58:46 +10:00
(Venkat) Raghav, Rajagopalan 763d93b72e [MRG+1] Do not transform y (#9180)
* we do not transform y

* more

* added Deprecation Warning to transform() to remove Y parameter

* more

* ENH ensure FunctionTransformer's transform/inverse_transform doesn't permit y

* Undo changes to pls_. It will be done in a separate PR (see #9160)

* flake8

* Update whatsnew

* Fully undo PLS changes
2017-06-22 23:24:12 +02:00
Naoya Kanai 95aa2952e1 Add logsumexp and comb to utils.fixes (#9046) 2017-06-10 15:01:02 +02:00
Christian Danielsen 7476c4e328 Change short description of predict_proba in sklearn.mixture (#8690) (#8719) 2017-06-08 13:51:53 +02:00
Naoya Kanai bd0fc236e0 [MRG+1] MAINT drop SciPy < 0.13 (#8854)
Remove sklearn.utils.fixes functions that are not needed for scipy >= 0.13 and keep deprecated wrappers in other modules.
2017-06-02 23:36:33 +02:00
Guillaume Lemaitre e3c9ae204f [MRG+1] DOC improve description and consistency of random_state (#8689)
* DOC improve description of random_state in train_test_split

* DOC Make random_state consistent through documentation

* FIX reverse doc mistake

* FIX address comment of Tom

* DOC address comments

* DOC remove empty line

* DOC remove unecessary white spaces
2017-04-05 17:43:21 -07:00
Quentin Hibon f548128e83 Fix typo in BaseMixture warning (#8616) 2017-03-22 16:32:43 +01:00
Thierry Guillemot 4f21607e54 Correct default value of reg_covar in gaussian_mixture. (#8462) 2017-02-27 11:14:30 +01:00
Loïc Estève e542efafe2 TST Ensure that attributes ending _ are not set in __init__ (#7464) 2016-12-12 21:57:43 +11:00
Joel Nothman 8570622a44 [MRG+1] DOC insert spaces before colons in parameter lists (#7920)
* DOC insert spaces before colons in parameter lists

Complies with numpydoc to improve rendering and automatic quality
assurance such as #7793. Affects listings of Parameters Attributes,
Returns.

Performed with the help of:

    grep -nE '^(    )+[a-zA-Z][a-zA-Z0-9_]*: ' sklearn -R | grep -v -e
    externals -e tests | grep -v -e default: -e else: -e Warning: -e Note:
    -e TRAIN: -e Default: -e True: -e False: -e DOI: -e In: | gsed
    's|\([^:]*\):\([0-9]*\):\([^:]*\):\(.*\)|--- a/\1\n+++ b/\1\n@@ -\2,1
    +\2,1 @@\n-\3:\4\n+\3 :\4|' | git apply --unidiff-zero -

* DOC fix numpydoc format for param
2016-11-25 10:59:22 +01:00
David Kirkby f1ec4300c3 Fix docstring typo (#7844) n_features --> n_components 2016-11-09 09:45:05 +01:00
Alexandre Gramfort 72724144f8 DOC : fix docstring of AIC/BIC in GMM 2016-11-07 21:36:03 +01:00
waterponey 6e50c8f35e [MRG+2] DOC framework for keeping API refs for deprecated classes/funcs (#7725)
* DOC framework for keeping API refs for deprecated classes/funcs

* DOC tagging deprecated for 0.20

* suggestion for LDA/QDA deprecation

* simplify deprecation message for GaussianProcess

* simplify deprecation messages

* fixup avoid import QuadraticDiscriminantAnalysis in qda.QDA (and similar for LDA).

* fixup test alias lda.LDA is instance of LinearDiscriminantAnalysis
2016-10-30 16:04:35 +01:00
Kai 379f54be68 [MRG+2] DOC correct docstring for sample_gaussian (#6957)
* DOC correct docstring for sample_gaussian

Docstring did not match function behaviour. Caused some trouble trying to implement a compatible version for a different distribution.

* MAINT Use _sample_gaussian internally

This avoids triggering the deprecation warning. sample_gaussian is just a thin
wrapper.

* Fix _sample_gaussian test path

_sample_gaussian is not publicly exported in mixture, so use gmm module.
2016-10-26 16:27:15 +02:00
Loïc Estève 4e1c101892 Use n_components=3 to test actual regression
n_components and n_features were equal and one was used for the other in
some places.
2016-10-20 16:56:38 +02:00
ljwolf 55672f91b2 add shape assertions to test 2016-10-19 21:53:42 -07:00
ljwolf cfc280d658 switch to multinomial composition for mixture sampling 2016-10-19 21:53:42 -07:00