Skip to content

Commit

Permalink
MNT Make files private in cross_decomposition (scikit-learn#15285)
Browse files Browse the repository at this point in the history
  • Loading branch information
NicolasHug authored and adrinjalali committed Oct 20, 2019
1 parent 6d38b5f commit 9e18ddd
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 4 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,9 @@ sklearn/mixture/base.py
sklearn/mixture/gaussian_mixture.py
sklearn/mixture/bayesian_mixture.py

sklearn/cross_decomposition/cca_.py
sklearn/cross_decomposition/pls_.py

sklearn/svm/base.py
sklearn/svm/classes.py
sklearn/svm/bounds.py
Expand Down
5 changes: 5 additions & 0 deletions sklearn/_build_utils/deprecated_modules.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,11 @@
('_bayesian_mixture', 'sklearn.mixture.bayesian_mixture',
'sklearn.mixture', 'BayesianGaussianMixture'),

('_cca_', 'sklearn.cross_decomposition.cca_',
'sklearn.cross_decomposition', 'CCA'),
('_pls_', 'sklearn.cross_decomposition.pls_',
'sklearn.cross_decomposition', 'PLSSVD'),

('_base', 'sklearn.svm.base', 'sklearn.svm', 'BaseLibSVM'),
('_bounds', 'sklearn.svm.bounds', 'sklearn.svm', 'l1_min_c'),
('_classes', 'sklearn.svm.classes', 'sklearn.svm', 'SVR'),
Expand Down
6 changes: 4 additions & 2 deletions sklearn/cross_decomposition/__init__.py
Original file line number Diff line number Diff line change
@@ -1,2 +1,4 @@
from .pls_ import * # noqa
from .cca_ import * # noqa
from ._pls_ import PLSCanonical, PLSRegression, PLSSVD
from ._cca_ import CCA

__all__ = ['PLSCanonical', 'PLSRegression', 'PLSSVD', 'CCA']
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from .pls_ import _PLS
from ._pls_ import _PLS
from ..base import _UnstableArchMixin

__all__ = ['CCA']
Expand Down
File renamed without changes.
3 changes: 2 additions & 1 deletion sklearn/cross_decomposition/tests/test_pls.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
assert_array_equal, assert_raise_message,
assert_warns)
from sklearn.datasets import load_linnerud
from sklearn.cross_decomposition import pls_, CCA
from sklearn.cross_decomposition import _pls_ as pls_
from sklearn.cross_decomposition import CCA
from sklearn.preprocessing import StandardScaler
from sklearn.utils import check_random_state
from sklearn.exceptions import ConvergenceWarning
Expand Down

0 comments on commit 9e18ddd

Please sign in to comment.