From 969ab30b83d18c94c32ce04841cc1d699a93c657 Mon Sep 17 00:00:00 2001 From: "Anthony D. Blaom" Date: Thu, 7 Apr 2022 12:35:43 +1200 Subject: [PATCH 1/5] fixes to Learning MLJ --- docs/src/learning_mlj.md | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/docs/src/learning_mlj.md b/docs/src/learning_mlj.md index f88c924f6..a2e7736bb 100644 --- a/docs/src/learning_mlj.md +++ b/docs/src/learning_mlj.md @@ -7,7 +7,7 @@ See also [Getting help and reporting problems](@ref). The present document, although littered with examples, is primarily intended as a complete reference. -### Where to start? +## Where to start? ### Completely new to Julia? [Julia's learning resources page](https://julialang.org/learning/) | @@ -28,10 +28,9 @@ intended as a complete reference. [MLJTutorial](https://github.com/ablaom/MLJTutorial.jl) -### Other resources +## Other resources -- [Data Science -Tutorials](https://juliaai.github.io/DataScienceTutorials.jl): MLJ tutorials including end-to-end examples, and "Introduction to Statistical Learning" labs +- [Data Science Tutorials](https://juliaai.github.io/DataScienceTutorials.jl): MLJ tutorials including end-to-end examples, and "Introduction to Statistical Learning" labs - [Analyzing the Glass Dataset](https://towardsdatascience.com/part-i-analyzing-the-glass-dataset-c556788a496f): A gentle introduction to data science using Julia and MLJ (three-part blog post) From 24632e3c95468c84f32158345eb0f5d38722e0b3 Mon Sep 17 00:00:00 2001 From: "Anthony D. Blaom" Date: Thu, 7 Apr 2022 13:06:22 +1200 Subject: [PATCH 2/5] further doc fixes --- docs/src/adding_models_for_general_use.md | 4 ++-- docs/src/common_mlj_workflows.md | 2 +- docs/src/controlling_iterative_models.md | 2 +- docs/src/getting_started.md | 4 ++++ docs/src/learning_mlj.md | 3 +-- docs/src/mlj_cheatsheet.md | 2 +- 6 files changed, 10 insertions(+), 7 deletions(-) diff --git a/docs/src/adding_models_for_general_use.md b/docs/src/adding_models_for_general_use.md index faacf0315..3f7198a26 100755 --- a/docs/src/adding_models_for_general_use.md +++ b/docs/src/adding_models_for_general_use.md @@ -1089,7 +1089,7 @@ MMI.save(model::SomeModel, fitresult; kwargs...) -> serializable_fitresult Implement this method to return a persistent serializable representation of the `fitresult` component of the `MMI.fit` return -value.below). +value. The fallback of `save` performs no action and returns `fitresult`. @@ -1110,7 +1110,7 @@ The fallback of `restore` performs no action and returns `serializable_fitresult #### Example For an example, refer to the model implementations at -[MLJXGBoostInterface.jl](https://github.com/JuliaAI/MLJXGBoostInterface.jl/blob/master/src/MLJXGBoostInterface.jl) +[MLJXGBoostInterface.jl](https://github.com/JuliaAI/MLJXGBoostInterface.jl/blob/42afbd2974bd3bd734994004e367c98964ed1262/src/MLJXGBoostInterface.jl#L679). ### Document strings diff --git a/docs/src/common_mlj_workflows.md b/docs/src/common_mlj_workflows.md index 0c8d1b9c7..de08be9a7 100644 --- a/docs/src/common_mlj_workflows.md +++ b/docs/src/common_mlj_workflows.md @@ -143,7 +143,7 @@ info("RidgeRegressor", pkg="MultivariateStats") # a model type in multiple packa Extracting the model document string: -```@example``` +```@example workflows doc("DecisionTreeClassifier", pkg="DecisionTree") ``` diff --git a/docs/src/controlling_iterative_models.md b/docs/src/controlling_iterative_models.md index 7a57068ff..619cfc058 100644 --- a/docs/src/controlling_iterative_models.md +++ b/docs/src/controlling_iterative_models.md @@ -116,7 +116,7 @@ control | description [`WithReportDo`](@ref MLJIteration.WithReportDo)`(f->e->@info("report: $e))`| Call `f(r)` where `r` is the training machine report | yes [`WithModelDo`](@ref MLJIteration.WithModelDo)`(f->m->@info("model: $m))`| Call `f(m)` where `m` is the model, which may be mutated by `f` | yes [`WithMachineDo`](@ref MLJIteration.WithMachineDo)`(f->mach->@info("report: $mach))`| Call `f(mach)` wher `mach` is the training machine in its current state | yes -[`Save`](@ref MLJIteration.Save)`(filename="machine.jlso")`|Save current training machine to `machine1.jlso`, `machine2.jslo`, etc | yes +[`Save`](@ref MLJIteration.Save)`(filename="machine.jls")`|Save current training machine to `machine1.jls`, `machine2.jsl`, etc | yes > Table 1. Atomic controls. Some advanced options omitted. diff --git a/docs/src/getting_started.md b/docs/src/getting_started.md index cc11c2636..fc613b613 100644 --- a/docs/src/getting_started.md +++ b/docs/src/getting_started.md @@ -3,6 +3,10 @@ For an outline of MLJ's **goals** and **features**, see [About MLJ](@ref). +This page introduces some MLJ basics, assuming some familiarity with +machine learning. For a complete list of other MLJ learning resources, +see [Learning MLJ](@ref). + This section introduces only the most basic MLJ operations and concepts. It assumes MJL has been successfully installed. See [Installation](@ref) if this is not the case. diff --git a/docs/src/learning_mlj.md b/docs/src/learning_mlj.md index a2e7736bb..00ebd4210 100644 --- a/docs/src/learning_mlj.md +++ b/docs/src/learning_mlj.md @@ -36,8 +36,7 @@ intended as a complete reference. - [Lightning Tour](https://github.com/alan-turing-institute/MLJ.jl/blob/dev/examples/lightning_tour/lightning_tour.ipynb): A compressed demonstration of key MLJ functionality -- [MLJ JuliaCon2020 Workshop](https://github.com/ablaom/MachineLearningInJulia2020): older version of [MLJTutorial](https://github.com/ablaom/MLJTutorial.jl) with [video -](https://www.youtube.com/watch?time_continue=27&v=qSWbCn170HU&feature=emb_title) +- [MLJ JuliaCon2020 Workshop](https://github.com/ablaom/MachineLearningInJulia2020): older version of [MLJTutorial](https://github.com/ablaom/MLJTutorial.jl) with [video](https://www.youtube.com/watch?time_continue=27&v=qSWbCn170HU&feature=emb_title) - [Learning Networks](@ref): For advanced MLJ users wanting to wrap workflows more complicated than linear pipelines diff --git a/docs/src/mlj_cheatsheet.md b/docs/src/mlj_cheatsheet.md index 7a0a7a4c5..52f08d9f0 100644 --- a/docs/src/mlj_cheatsheet.md +++ b/docs/src/mlj_cheatsheet.md @@ -164,7 +164,7 @@ pkg="MultivariateStats")` gets all properties (aka traits) of registered models ## Saving and retrieving machines using Julia serializer -`MLJ.save("trained_for_five_days.jls", mach)` to save machine `mach` +`MLJ.save("trained_for_five_days.jls", mach)` to save machine `mach` (without data) `predict_only_mach = machine("trained_for_five_days.jlso")` to deserialize. From 5216f088748c9836c46c78c8521dea9bc2d4083d Mon Sep 17 00:00:00 2001 From: "Anthony D. Blaom" Date: Thu, 7 Apr 2022 13:33:26 +1200 Subject: [PATCH 3/5] re-export `doc` --- src/MLJ.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/MLJ.jl b/src/MLJ.jl index 6f55b0a0c..93c4ac28c 100644 --- a/src/MLJ.jl +++ b/src/MLJ.jl @@ -125,7 +125,7 @@ export Grid, RandomSearch, Explicit, TunedModel, LatinHypercube, learning_curve!, learning_curve # re-export from MLJModels: -export models, localmodels, @load, @iload, load, info, +export models, localmodels, @load, @iload, load, info, doc, ConstantRegressor, ConstantClassifier, # builtins/Constant.jl FeatureSelector, UnivariateStandardizer, # builtins/Transformers.jl Standardizer, UnivariateBoxCoxTransformer, From 6c5373d610381d14be80d8fe0e70c9497d26fba2 Mon Sep 17 00:00:00 2001 From: "Anthony D. Blaom" Date: Thu, 7 Apr 2022 13:35:19 +1200 Subject: [PATCH 4/5] bump 0.18.1 --- Project.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Project.toml b/Project.toml index c8792cd56..b53d97086 100644 --- a/Project.toml +++ b/Project.toml @@ -1,7 +1,7 @@ name = "MLJ" uuid = "add582a8-e3ab-11e8-2d5e-e98b27df1bc7" authors = ["Anthony D. Blaom "] -version = "0.18.0" +version = "0.18.1" [deps] CategoricalArrays = "324d7699-5711-5eae-9e2f-1d82baa6b597" From db8f099652760724f0ea9854722aff9858c660fb Mon Sep 17 00:00:00 2001 From: "Anthony D. Blaom" Date: Thu, 7 Apr 2022 13:36:57 +1200 Subject: [PATCH 5/5] bump compat MLJModels = "0.15.5" to support `doc` --- Project.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Project.toml b/Project.toml index b53d97086..df7a476be 100644 --- a/Project.toml +++ b/Project.toml @@ -30,7 +30,7 @@ Distributions = "0.21,0.22,0.23, 0.24, 0.25" MLJBase = "0.20" MLJEnsembles = "0.3" MLJIteration = "0.5" -MLJModels = "0.15" +MLJModels = "0.15.5" MLJTuning = "0.7" OpenML = "0.2" ProgressMeter = "1.1"