Skip to content

Commit

Permalink
restore tutorials
Browse files Browse the repository at this point in the history
  • Loading branch information
sarahmish committed Nov 15, 2024
1 parent 1d8879d commit 298ee43
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ X_train, X_test, y_train, y_test = train_test_split(dataset, label, stratify=lab
primitives = [
'mlprimitives.custom.preprocessing.ClassEncoder',
'mlprimitives.custom.feature_extraction.CategoricalEncoder',
# 'sklearn.impute.SimpleImputer',
'sklearn.impute.SimpleImputer',
'xgboost.XGBClassifier',
'mlprimitives.custom.preprocessing.ClassDecoder'
]
Expand Down
2 changes: 1 addition & 1 deletion examples/tutorials/1. Using and MLPipeline.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -361,7 +361,7 @@
"primitives = [\n",
" 'mlprimitives.custom.preprocessing.ClassEncoder',\n",
" 'mlprimitives.custom.feature_extraction.CategoricalEncoder',\n",
" # 'sklearn.impute.SimpleImputer',\n",
" 'sklearn.impute.SimpleImputer',\n",
" 'xgboost.XGBClassifier',\n",
" 'mlprimitives.custom.preprocessing.ClassDecoder'\n",
"]\n",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@
"primitives = [\n",
" 'mlprimitives.custom.preprocessing.ClassEncoder',\n",
" 'mlprimitives.custom.feature_extraction.CategoricalEncoder',\n",
" # 'sklearn.impute.SimpleImputer',\n",
" 'sklearn.impute.SimpleImputer',\n",
" 'xgboost.XGBClassifier',\n",
" 'mlprimitives.custom.preprocessing.ClassDecoder'\n",
"]\n",
Expand Down
2 changes: 1 addition & 1 deletion examples/tutorials/4. Saving and Loading a Pipeline.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
"primitives = [\n",
" 'mlprimitives.custom.preprocessing.ClassEncoder',\n",
" 'mlprimitives.custom.feature_extraction.CategoricalEncoder',\n",
" # 'sklearn.impute.SimpleImputer',\n",
" 'sklearn.impute.SimpleImputer',\n",
" 'xgboost.XGBClassifier',\n",
" 'mlprimitives.custom.preprocessing.ClassDecoder'\n",
"]\n",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@
"primitives = [\n",
" 'mlprimitives.custom.preprocessing.ClassEncoder',\n",
" 'mlprimitives.custom.feature_extraction.CategoricalEncoder',\n",
" # 'sklearn.impute.SimpleImputer',\n",
" 'sklearn.impute.SimpleImputer',\n",
" 'xgboost.XGBClassifier',\n",
" 'mlprimitives.custom.preprocessing.ClassDecoder'\n",
"]\n",
Expand Down
12 changes: 6 additions & 6 deletions examples/tutorials/6. Flexible outputs specification.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@
"primitives = [\n",
" 'mlprimitives.custom.preprocessing.ClassEncoder',\n",
" 'mlprimitives.custom.feature_extraction.CategoricalEncoder',\n",
" # 'sklearn.impute.SimpleImputer',\n",
" 'sklearn.impute.SimpleImputer',\n",
" 'xgboost.XGBClassifier',\n",
" 'mlprimitives.custom.preprocessing.ClassDecoder'\n",
"]\n",
Expand Down Expand Up @@ -432,11 +432,11 @@
],
"source": [
"output_spec = [\n",
" # 'sklearn.impute.SimpleImputer#1.X',\n",
" 'sklearn.impute.SimpleImputer#1.X',\n",
" 'mlprimitives.custom.preprocessing.ClassEncoder#1.y',\n",
" 'mlprimitives.custom.preprocessing.ClassEncoder#1.classes',\n",
"]\n",
"y, classes = pipeline.fit(X_train, y_train, output_=output_spec)"
"X, y, classes = pipeline.fit(X_train, y_train, output_=output_spec)"
]
},
{
Expand All @@ -463,11 +463,11 @@
"source": [
"output_spec = [\n",
" 'mlprimitives.custom.feature_extraction.CategoricalEncoder#1.X',\n",
" # 'sklearn.impute.SimpleImputer#1.X',\n",
" 'sklearn.impute.SimpleImputer#1.X',\n",
" 'mlprimitives.custom.preprocessing.ClassEncoder#1.y',\n",
" 'mlprimitives.custom.preprocessing.ClassEncoder#1.classes',\n",
"]\n",
"X_1, y, classes = pipeline.fit(X_train, y_train, output_=output_spec)"
"X_1, X_2, y, classes = pipeline.fit(X_train, y_train, output_=output_spec)"
]
},
{
Expand Down Expand Up @@ -507,7 +507,7 @@
}
],
"source": [
"X_1.shape"
"X_2.shape"
]
}
],
Expand Down

0 comments on commit 298ee43

Please sign in to comment.