Administrative Information
Title | Lab session: SVMs and Kernels |
Duration | 2x45 |
Module | A |
Lesson Type | Practical |
Focus | Practical - AI Modelling |
Topic | AI Modelling |
Keywords
support vector machine,kernel function,RBF,model complexity,
Learning Goals
- To be able to design and use a linear SVM
- To be able to design ad use a non-linear SVM, using a kernel
- To design and optmize a SVM (cookbook approach)
Expected Preparation
Learning Events to be Completed Before
Obligatory for Students
- Review of basic Python.
- Review of using scikit-learn models.
Optional for Students
None.
References and background for students
- Hands on Machine Learning with Scikit-Learn and Tensorflow by Aurélién Géron
- Introduction to Machine Learning with Python by Andreas C. Müller and Sarah Guido
- Udemy course – Machine Learning – A Z by Kirill Eremenko and Hadelin de Ponteves
- Udemy course – Feature Engineering for Machine Learning by Soledad Galli
- Support-vector machine on wikipedia
- https://www.datacamp.com/community/tutorials/svm-classification-scikit-learn-python
- http://dataaspirant.com/2017/01/13/support-vector-machine-algorithm/
- https://www.ritchieng.com/machine-learning-evaluate-classification-model/
- https://en.wikipedia.org/wiki/Kernel_method
- https://en.wikipedia.org/wiki/Polynomial_kernel
- https://en.wikipedia.org/wiki/Radial_basis_function_kernel
- https://data-flair.training/blogs/svm-kernel-functions/
Recommended for Teachers
- A review of how the pandas and scikit-learn functions used in the notebook are parameterized.
Lesson materials
Instructions for Teachers
This learning event consist of laboratory tasks that shall be solved by the students with the help of the leading instructor.
Prepare a notebook environment with numpy, matplotlib, sns and scikit-learn installed.
Outline/time schedule
Duration (min) | Description | Concepts |
---|---|---|
5 | Brief of the tasks to be conducted | |
25 | Data exploration and preprocessing | data description, missing values, feature distributions, outlier detection |
30 | Fitting SVM models | data scaling, linear SVM, RBF, model complexity |
30 | Model evaluation | hyperparameter optimization, underfitting, overfitting, ROC curve |
Acknowledgements
The Human-Centered AI Masters programme was Co-Financed by the Connecting Europe Facility of the European Union Under Grant №CEF-TC-2020-1 Digital Skills 2020-EU-IA-0068.