File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1515 - TEST_DIR=/tmp/test_dir/
1616 - MODULE=openml
1717 matrix :
18- - DISTRIB="conda" PYTHON_VERSION="2.7" NUMPY_VERSION="1.11" SCIPY_VERSION="0.17.0" CYTHON_VERSION="0.21" SKLEARN_VERSION="0.18"
19- - DISTRIB="conda" PYTHON_VERSION="3.4" NUMPY_VERSION="1.11" SCIPY_VERSION="0.17.0" CYTHON_VERSION="0.23.4" SKLEARN_VERSION="0.18"
20- - DISTRIB="conda" PYTHON_VERSION="3.5" COVERAGE="true" NUMPY_VERSION="1.11" SCIPY_VERSION="0.17.0" CYTHON_VERSION="0.23.4" SKLEARN_VERSION="0.18"
18+ - DISTRIB="conda" PYTHON_VERSION="2.7" NUMPY_VERSION="1.11" SCIPY_VERSION="0.17.0" CYTHON_VERSION="0.21" SKLEARN_VERSION="0.18.1"
19+ - DISTRIB="conda" PYTHON_VERSION="3.4" NUMPY_VERSION="1.11" SCIPY_VERSION="0.17.0" CYTHON_VERSION="0.23.4" SKLEARN_VERSION="0.18.1"
20+ - DISTRIB="conda" PYTHON_VERSION="3.5" NUMPY_VERSION="1.11" SCIPY_VERSION="0.17.0" CYTHON_VERSION="0.23.4" SKLEARN_VERSION="0.18.1"
21+ - DISTRIB="conda" PYTHON_VERSION="3.6" COVERAGE="true" NUMPY_VERSION="1.12.1" SCIPY_VERSION="0.19.0" CYTHON_VERSION="0.25.2" SKLEARN_VERSION="0.18.1"
22+
2123install : source ci_scripts/install.sh
2224script : bash ci_scripts/test.sh
2325after_success : source ci_scripts/success.sh
Original file line number Diff line number Diff line change @@ -49,6 +49,9 @@ def sklearn_to_flow(o, parent_model=None):
4949 rval = o
5050 elif isinstance (o , dict ):
5151 # TODO: explain what type of parameter is here
52+ if not isinstance (o , OrderedDict ):
53+ o = OrderedDict ([(key , value ) for key , value in sorted (o .items ())])
54+
5255 rval = OrderedDict ()
5356 for key , value in o .items ():
5457 if not isinstance (key , six .string_types ):
@@ -133,7 +136,7 @@ def flow_to_sklearn(o, **kwargs):
133136 else :
134137 rval = OrderedDict ((flow_to_sklearn (key , ** kwargs ),
135138 flow_to_sklearn (value , ** kwargs ))
136- for key , value in o .items ())
139+ for key , value in sorted ( o .items () ))
137140 elif isinstance (o , (list , tuple )):
138141 rval = [flow_to_sklearn (element , ** kwargs ) for element in o ]
139142 if isinstance (o , tuple ):
Original file line number Diff line number Diff line change @@ -209,7 +209,8 @@ def test_sklearn_to_upload_to_flow(self):
209209 y = iris .target
210210
211211 # Test a more complicated flow
212- ohe = sklearn .preprocessing .OneHotEncoder (categorical_features = [1 ])
212+ ohe = sklearn .preprocessing .OneHotEncoder (categorical_features = [1 ],
213+ handle_unknown = 'ignore' )
213214 scaler = sklearn .preprocessing .StandardScaler (with_mean = False )
214215 pca = sklearn .decomposition .TruncatedSVD ()
215216 fs = sklearn .feature_selection .SelectPercentile (
You can’t perform that action at this time.
0 commit comments