Commit Graph

382 Commits

Author SHA1 Message Date
Rémy Léone 9b7176dd9d [DOC] Fix broken links 2016-03-23 12:45:34 -07:00
Andreas Mueller fb123ed24b More doc fixes. Latex builds again. 2015-11-20 16:30:45 -05:00
Preston Parry 77665e3c31 removes extra spaces from error message
I unfortunately got to know this error message too well when my data-formatting pipeline encountered a bug :)
2015-11-04 21:44:35 -08:00
KamalakerDadi f2e35411fa Added more versions of 0.17 2015-11-04 00:02:52 +01:00
yelite fea218e5cf In tree, min_samples_split and min_samples_leaf now accept float number as percentage. 2015-10-24 23:18:52 +02:00
Raghav R V 3f8743f47b Main Commits - Major
--------------------

* ENH Reogranize classes/fn from grid_search into search.py
* ENH Reogranize classes/fn from cross_validation into split.py
* ENH Reogranize cls/fn from cross_validation/learning_curve into validate.py

* MAINT Merge _check_cv into check_cv inside the model_selection module
* MAINT Update all the imports to point to the model_selection module
* FIX use iter_cv to iterate throught the new style/old style cv objs
* TST Add tests for the new model_selection members
* ENH Wrap the old-style cv obj/iterables instead of using iter_cv

* ENH Use scipy's binomial coefficient function comb for calucation of nCk
* ENH Few enhancements to the split module
* ENH Improve check_cv input validation and docstring
* MAINT _get_test_folds(X, y, labels) --> _get_test_folds(labels)
* TST if 1d arrays for X introduce any errors
* ENH use 1d X arrays for all tests;
* ENH X_10 --> X (global var)

Minor
-----

* ENH _PartitionIterator --> _BaseCrossValidator;
* ENH CVIterator --> CVIterableWrapper
* TST Import the old SKF locally
* FIX/TST Clean up the split module's tests.
* DOC Improve documentation of the cv parameter
* COSMIT consistently hyphenate cross-validation/cross-validator
* TST Calculate n_samples from X
* COSMIT Use separate lines for each import.
* COSMIT cross_validation_generator --> cross_validator

Commits merged manually
-----------------------

* FIX Document the random_state attribute in RandomSearchCV
* MAINT Use check_cv instead of _check_cv
* ENH refactor OVO decision function, use it in SVC for sklearn-like
  decision_function shape
* FIX avoid memory cost when sampling from large parameter grids

ENH Major to Minor incremental enhancements to the model_selection

Squashed commit messages - (For reference)

Major
-----

* ENH p --> n_labels
* FIX *ShuffleSplit: all float/invalid type errors at init and int error at split
* FIX make PredefinedSplit accept test_folds in constructor; Cleanup docstrings
* ENH+TST KFold: make rng to be generated at every split call for reproducibility
* FIX/MAINT KFold: make shuffle a public attr
* FIX Make CVIterableWrapper private.
* FIX reuse len_cv instead of recalculating it
* FIX Prevent adding *SearchCV estimators from the old grid_search module
* re-FIX In all_estimators: the sorting to use only the 1st item (name)
    To avoid collision between the old and the new GridSearch classes.
* FIX test_validate.py: Use 2D X (1D X is being detected as a single sample)
* MAINT validate.py --> validation.py
* MAINT make the submodules private
* MAINT Support old cv/gs/lc until 0.19
* FIX/MAINT n_splits --> get_n_splits
* FIX/TST test_logistic.py/test_ovr_multinomial_iris:
    pass predefined folds as an iterable
* MAINT expose BaseCrossValidator
* Update the model_selection module with changes from master
  - From #5161
  -  - MAINT remove redundant p variable
  -  - Add check for sparse prediction in cross_val_predict
  - From #5201 - DOC improve random_state param doc
  - From #5190 - LabelKFold and test
  - From #4583 - LabelShuffleSplit and tests
  - From #5300 - shuffle the `labels` not the `indxs` in LabelKFold + tests
  - From #5378 - Make the GridSearchCV docs more accurate.
  - From #5458 - Remove shuffle from LabelKFold
  - From #5466(#4270) - Gaussian Process by Jan Metzen
  - From #4826 - Move custom error / warnings into sklearn.exception

Minor
-----

* ENH Make the KFold shuffling test stronger
* FIX/DOC Use the higher level model_selection module as ref
* DOC in check_cv "y : array-like, optional"
* DOC a supervised learning problem --> supervised learning problems
* DOC cross-validators --> cross-validation strategies
* DOC Correct Olivier Grisel's name ;)
* MINOR/FIX cv_indices --> kfold
* FIX/DOC Align the 'See also' section of the new KFold, LeaveOneOut
* TST/FIX imports on separate lines
* FIX use __class__ instead of classmethod
* TST/FIX import directly from model_selection
* COSMIT Relocate the random_state documentation
* COSMIT remove pass
* MAINT Remove deprecation warnings from old tests
* FIX correct import at test_split
* FIX/MAINT Move P_sparse, X, y defns to top; rm unused W_sparse, X_sparse
* FIX random state to avoid doctest failure
* TST n_splits and split wrapping of _CVIterableWrapper
* FIX/MAINT Use multilabel indicator matrix directly
* TST/DOC clarify why we conflate classes 0 and 1
* DOC add comment that this was taken from BaseEstimator
* FIX use of labels is not needed in stratified k fold
* Fix cross_validation reference
* Fix the labels param doc

FIX/DOC/MAINT Addressing the review comments by Arnaud and Andy

COSMIT Sort the members alphabetically
COSMIT len_cv --> n_splits
COSMIT Merge 2 if; FIX Use kwargs
DOC Add my name to the authors :D
DOC make labels parameter consistent
FIX Remove hack for boolean indices; + COSMIT idx --> indices; DOC Add Returns
COSMIT preds --> predictions
DOC Add Returns and neatly arrange X, y, labels
FIX idx(s)/ind(s)--> indice(s)
COSMIT Merge if and else to elif
COSMIT n --> n_samples
COSMIT Use bincount only once
COSMIT cls --> class_i / class_i (ith class indices) -->
perm_indices_class_i

FIX/ENH/TST Addressing the final reviews

COSMIT c --> count
FIX/TST make check_cv raise ValueError for string cv value
TST nested cv (gs inside cross_val_score) works for diff cvs
FIX/ENH Raise ValueError when labels is None for label based cvs;
TST if labels is being passed correctly to the cv and that the
ValueError is being propagated to the cross_val_score/predict and grid
search
FIX pass labels to cross_val_score
FIX use make_classification
DOC Add Returns; COSMIT Remove scaffolding
TST add a test to check the _build_repr helper
REVERT the old GS/RS should also be tested by the common tests.
ENH Add a tuple of all/label based CVS
FIX raise VE even at get_n_splits if labels is None
FIX Fabian's comments
PEP8
2015-10-23 17:28:08 +02:00
Arnaud Joly 409c888aed Raise appropriate error if y is sparse 2015-10-23 17:28:07 +02:00
Alexandre Gramfort 5a58e56826 Merge pull request #5487 from arjoly/example-node
[MRG+1] Add an example and a method to analyse the decision tree stucture
2015-10-22 13:31:49 +02:00
Arnaud Joly bc02bd5243 ENH rename decision_paths to decision_path 2015-10-21 17:05:56 +02:00
Arnaud Joly 317281bf22 take glouppe comment 2015-10-21 17:05:55 +02:00
Arnaud Joly f6d605ff96 Implement decision path in tree 2015-10-21 17:05:55 +02:00
hlin117 d62e316882 #5322: Resolving Random Forest build errors (bad input shape) 2015-10-20 10:36:47 -05:00
hlin117 a5860a1df2 #5322: Fixed build for tree failures, fixing estimator_checks.check_estimator 2015-10-20 10:36:47 -05:00
hlin117 7745319e33 #5322: Added check for DecisionTreeRegressor 2015-10-20 10:34:56 -05:00
Raghav R V e3afc0e8c9 MAINT move custom error/warning classes into sklearn.exceptions
ENH NonBLASDotWarning -> EfficiencyWarning; Improve error message
DOC Add exceptions module to modules/classes.rst
MAINT Move ConvergenceWarning, UndefinedMetricWarning et al into exceptions
MAINT Remove ChangedBehaviorWarning from base
DOC/FIX Improve DataConversionWarning's docstring
2015-10-19 22:35:35 +02:00
Jiali Mei 85223b9bcc a common test to check if classifiers fail when fed regression targets 2015-10-14 14:46:13 -04:00
Jacob Schreiber 02c0029baa ENH gbt sparse support 2015-09-28 13:44:12 -07:00
Jacob Schreiber 5978c0bbdf ENH split _tree.pyx into several files 2015-09-09 11:28:24 +02:00
rasbt 93464798ef note about variance reduction 2015-07-11 16:03:20 -04:00
Tian Wang 9f06156f20 add a new int array to store indices 2015-06-24 11:22:01 -04:00
Andreas Mueller 0650d5502e DOC adding backlinks to docstrings 2015-06-03 00:24:04 -04:00
Andreas Mueller eedc1cddab Use more natural class_weight="auto" heuristic 2015-06-01 12:49:53 -04:00
Arnaud Joly 64e553398b DOC document missing attributes 2015-05-12 15:00:38 +02:00
Arnaud Joly 92bda9794f DOC use same error message in decision tree and random forest 2015-04-20 17:27:58 +02:00
Arnaud Joly 294a6219e2 FIX properly raised not fitted error 2015-04-20 17:27:58 +02:00
Arnaud Joly 4ffbf34588 Factorize input validation 2015-04-20 17:27:58 +02:00
Arnaud Joly 4e6346ef62 FIX raise error properly when n_features differ in fit and apply 2015-04-20 17:27:58 +02:00
Andreas Mueller a5f0159ea5 don't to input validation in each tree for RandomForest.predict 2015-04-13 19:30:02 -04:00
Gilles Louppe 29dddc7d30 DOC: better documentation tree.apply 2015-04-11 15:53:41 +02:00
Gilles Louppe 1aa4249bf3 ENH: raise NotFittedError instead of ValueError 2015-04-08 12:16:09 +02:00
Gilles Louppe 28a0994bf2 ENH: public apply method for decision trees 2015-04-08 12:10:27 +02:00
Daniel Galvez cfe4e15f54 Added tests of apply() for valid and invalid inputs. Fixed style. 2015-04-02 11:15:11 +02:00
Daniel Galvez fdb42ea4d7 Added indentation to docstring 2015-04-02 11:13:10 +02:00
Daniel Galvez cb687fd7e4 Added docstring 2015-04-02 11:13:10 +02:00
Daniel Galvez 98dfdc6101 Make apply method of trees public. Added test for concistency with private method. 2015-04-02 11:13:10 +02:00
Loïc Estève a13a5859e8 DOC remove sphinx warnings when generating the doc
and fixes a few other doc problems while I was at it.

The main take-home message is to remember that you need a backslash when
your parameter type description exceeds one line.
2015-03-18 15:49:30 +01:00
Christof Angermueller 6ff4e14395 Update documentation of predict_proba in tree module 2015-03-05 15:33:26 -05:00
trevorstephens f75c98b872 refactor forests & trees class_weight calc 2015-01-31 18:27:29 -08:00
Andreas Mueller c970fb51e7 COSMIT spelling 2015-01-15 15:09:35 -05:00
trevorstephens 35c2535bfc rename cw option to subsample & refactor its implementation 2015-01-12 21:27:13 -08:00
trevorstephens b541191754 Merge branch 'master' into rf-class_weight
Conflicts:
	doc/whats_new.rst
	sklearn/ensemble/forest.py
	sklearn/tree/tree.py
2015-01-12 19:15:21 -08:00
Raghav R V abd31d2cad MAINT Make uniform the error raised for not fitted condition 2015-01-12 00:33:40 +05:30
trevorstephens cad87b578c rename vars & copy sample_weight 2015-01-10 11:49:42 -08:00
trevorstephens 9c7566e5df Merge branch 'master' into rf-class_weight
Conflicts:
	doc/whats_new.rst
2015-01-08 07:56:19 -08:00
trevorstephens ac9ab961bb Y-org rename & whats_new update 2015-01-08 02:31:24 -08:00
trevorstephens 2b24ccefa0 parameter validation checks & tests for errors 2015-01-03 13:15:42 -08:00
akshayah3 e77aac8e58 Documentation of max depth parameter
Changed the docstring

Few docstring changes
2014-12-29 20:04:25 +05:30
trevorstephens 085d677ea2 add class_weight to trees, expand tests & minor refactor 2014-12-22 16:50:58 -08:00
Arnaud Joly c03c01a504 ENH Bring sparse input support to tree-based methods
Author:     Arnaud Joly <arnaud.v.joly@gmail.com>
            Fares Hedayati <fares.hedayati@gmail.com>
2014-11-06 13:58:28 +01:00
Joel Nothman b3bdb08964 DOC fix formatting of attributes etc. in docstrings 2014-07-28 19:04:59 +10:00