Mercurial > repos > bgruening > sklearn_ensemble
annotate README.rst @ 38:407495139a09 draft
"planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sklearn commit d970dae980fbe349414fc0889f719d875d999c5b"
author | bgruening |
---|---|
date | Fri, 27 Aug 2021 10:24:55 +0000 |
parents | 92b9d68579af |
children |
rev | line source |
---|---|
0
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
1 Galaxy wrapper for scikit-learn library |
17
92b9d68579af
planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sklearn commit cfc9fe24b7975fc5838bb3e456646202898eb977
bgruening
parents:
0
diff
changeset
|
2 *************************************** |
0
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
3 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
4 Contents |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
5 ======== |
17
92b9d68579af
planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sklearn commit cfc9fe24b7975fc5838bb3e456646202898eb977
bgruening
parents:
0
diff
changeset
|
6 |
0
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
7 - `What is scikit-learn?`_ |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
8 - `Scikit-learn main package groups`_ |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
9 - `Tools offered by this wrapper`_ |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
10 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
11 - `Machine learning workflows`_ |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
12 - `Supervised learning workflows`_ |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
13 - `Unsupervised learning workflows`_ |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
14 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
15 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
16 ____________________________ |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
17 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
18 |
17
92b9d68579af
planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sklearn commit cfc9fe24b7975fc5838bb3e456646202898eb977
bgruening
parents:
0
diff
changeset
|
19 .. _What is scikit-learn?: |
0
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
20 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
21 What is scikit-learn? |
17
92b9d68579af
planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sklearn commit cfc9fe24b7975fc5838bb3e456646202898eb977
bgruening
parents:
0
diff
changeset
|
22 ===================== |
0
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
23 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
24 Scikit-learn is an open-source machine learning library for the Python programming language. It offers various algorithms for performing supervised and unsupervised learning as well as data preprocessing and transformation, model selection and evaluation, and dataset utilities. It is built upon SciPy (Scientific Python) library. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
25 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
26 Scikit-learn source code can be accessed at https://github.com/scikit-learn/scikit-learn. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
27 Detailed installation instructions can be found at http://scikit-learn.org/stable/install.html |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
28 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
29 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
30 .. _Scikit-learn main package groups: |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
31 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
32 Scikit-learn main package groups |
17
92b9d68579af
planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sklearn commit cfc9fe24b7975fc5838bb3e456646202898eb977
bgruening
parents:
0
diff
changeset
|
33 ================================ |
0
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
34 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
35 Scikit-learn provides the users with several main groups of related operations. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
36 These are: |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
37 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
38 - Classification |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
39 - Identifying to which category an object belongs. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
40 - Regression |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
41 - Predicting a continuous-valued attribute associated with an object. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
42 - Clustering |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
43 - Automatic grouping of similar objects into sets. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
44 - Preprocessing |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
45 - Feature extraction and normalization. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
46 - Model selection and evaluation |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
47 - Comparing, validating and choosing parameters and models. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
48 - Dimensionality reduction |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
49 - Reducing the number of random variables to consider. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
50 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
51 Each group consists of a number of well-known algorithms from the category. For example, one can find hierarchical, spectral, kmeans, and other clustering methods in sklearn.cluster package. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
52 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
53 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
54 .. _Tools offered by this wrapper: |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
55 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
56 Available tools in the current wrapper |
17
92b9d68579af
planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sklearn commit cfc9fe24b7975fc5838bb3e456646202898eb977
bgruening
parents:
0
diff
changeset
|
57 ====================================== |
0
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
58 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
59 The current release of the wrapper offers a subset of the packages from scikit-learn library. You can find: |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
60 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
61 - A subset of classification metric functions |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
62 - Linear and quadratic discriminant classifiers |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
63 - Random forest and Ada boost classifiers and regressors |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
64 - All the clustering methods |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
65 - All support vector machine classifiers |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
66 - A subset of data preprocessing estimator classes |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
67 - Pairwise metric measurement functions |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
68 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
69 In addition, several tools for performing matrix operations, generating problem-specific datasets, and encoding text and extracting features have been prepared to help the user with more advanced operations. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
70 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
71 .. _Machine learning workflows: |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
72 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
73 Machine learning workflows |
17
92b9d68579af
planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sklearn commit cfc9fe24b7975fc5838bb3e456646202898eb977
bgruening
parents:
0
diff
changeset
|
74 ========================== |
0
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
75 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
76 Machine learning is about processes. No matter what machine learning algorithm we use, we can apply typical workflows and dataflows to produce more robust models and better predictions. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
77 Here we discuss supervised and unsupervised learning workflows. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
78 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
79 .. _Supervised learning workflows: |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
80 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
81 Supervised machine learning workflows |
17
92b9d68579af
planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sklearn commit cfc9fe24b7975fc5838bb3e456646202898eb977
bgruening
parents:
0
diff
changeset
|
82 ===================================== |
0
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
83 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
84 **What is supervised learning?** |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
85 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
86 In this machine learning task, given sample data which are labeled, the aim is to build a model which can predict the labels for new observations. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
87 In practice, there are five steps which we can go through to start from raw input data and end up getting reasonable predictions for new samples: |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
88 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
89 1. Preprocess the data:: |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
90 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
91 * Change the collected data into the proper format and datatype. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
92 * Adjust the data quality by filling the missing values, performing |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
93 required scaling and normalizations, etc. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
94 * Extract features which are the most meaningfull for the learning task. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
95 * Split the ready dataset into training and test samples. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
96 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
97 2. Choose an algorithm:: |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
98 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
99 * These factors help one to choose a learning algorithm: |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
100 - Nature of the data (e.g. linear vs. nonlinear data) |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
101 - Structure of the predicted output (e.g. binary vs. multilabel classification) |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
102 - Memory and time usage of the training |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
103 - Predictive accuracy on new data |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
104 - Interpretability of the predictions |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
105 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
106 3. Choose a validation method |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
107 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
108 Every machine learning model should be evaluated before being put into practicical use. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
109 There are numerous performance metrics to evaluate machine learning models. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
110 For supervised learning, usually classification or regression metrics are used. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
111 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
112 A validation method helps to evaluate the performance metrics of a trained model in order |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
113 to optimize its performance or ultimately switch to a more efficient model. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
114 Cross-validation is a known validation method. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
115 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
116 4. Fit a model |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
117 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
118 Given the learning algorithm, validation method, and performance metric(s) |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
119 repeat the following steps:: |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
120 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
121 * Train the model. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
122 * Evaluate based on metrics. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
123 * Optimize unitl satisfied. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
124 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
125 5. Use fitted model for prediction:: |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
126 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
127 This is a final evaluation in which, the optimized model is used to make predictions |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
128 on unseen (here test) samples. After this, the model is put into production. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
129 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
130 .. _Unsupervised learning workflows: |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
131 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
132 Unsupervised machine learning workflows |
17
92b9d68579af
planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/sklearn commit cfc9fe24b7975fc5838bb3e456646202898eb977
bgruening
parents:
0
diff
changeset
|
133 ======================================= |
0
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
134 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
135 **What is unsupervised learning?** |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
136 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
137 Unlike supervised learning and more liklely in real life, here the initial data is not labeled. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
138 The task is to extract the structure from the data and group the samples based on their similarities. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
139 Clustering and dimensionality reduction are two famous examples of unsupervised learning tasks. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
140 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
141 In this case, the workflow is as follows:: |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
142 |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
143 * Preprocess the data (without splitting to train and test). |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
144 * Train a model. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
145 * Evaluate and tune parameters. |
569eefee7ed8
planemo upload for repository https://github.com/bgruening/galaxytools/tools/sklearn commit 0e582cf1f3134c777cce3aa57d71b80ed95e6ba9
bgruening
parents:
diff
changeset
|
146 * Analyse the model and test on real data. |