Learning is a lifelong process. But you must know what, where, and how to learn? What skills to develop? What skills will help you boost your career? If not, you are at the right place! Our tutorial section at CoderzColumn is dedicated to providing you with all the practical lessons. It will give you the experience to learn Python for different purposes and code on your own. Our tutorials cover:
For an in-depth understanding of the above concepts, check out the sections below.
An in-depth guide on how to use Python ML library catboost which provides an implementation of gradient boosting on decision trees algorithm. Tutorial covers majority of features of library with simple and easy-to-understand examples. Apart from training models & making predictions, topics like hyperparameters tuning, cross-validation, saving & loading models, plotting training loss/metric values, early stopping training to prevent overfitting, creating custom loss function & evaluation metrics, etc are covered in detail.
An in-depth guide on how to use Python ML library LightGBM which provides an implementation of gradient boosting on decision trees algorithm. Tutorial covers majority of features of library with simple and easy-to-understand examples. Apart from training models & making predictions, topics like cross-validation, saving & loading models, plotting features importances, early stopping training to prevent overfitting, creating custom loss function & evaluation metrics, etc are covered in detail.
Tutorial explains how to use scikit-learn models/estimators with large datasets that do not fit into main memory of the computer. Majority of sklearn estimators can work with datasets that fit into main memory only. But there are few that can work with data in batches. All these models provide "partial_fit()" method that can be called more than once to update model weights. We have explained these kinds of models for solving ML tasks regression, classification, clustering, dimensionality reduction, and preprocessing.
A detailed guide on how to use Python library joblib for parallel computing in Python. Tutorial explains how to submit tasks to joblib pool and then retrieve results. It even explains how to use various parallel computing backend like loky, threading, multiprocessing, dask, etc.
An in-depth guide to configure loggers from dictionary and config files. Python module "logging.config" provides us with various methods to create loggers from configuration details available through dictionary and config files. The tutorial explains methods (dictConfig() & fileConfig()) of module with simple examples.
A simple guide to profile Python code using libraries cProfile and profile. Both are available through standard python installation. They let us measure execution time of function calls made. Tutorial explains how to use libraries to profile code in Python script/program, from command line/shell, and in Jupyter Notebook as well.
A brief guide on how to use various ML metrics/scoring functions available from "metrics" module of scikit-learn to evaluate model performance. It covers a guide on using metrics for different ML tasks like classification, regression, and clustering. It even explains how to create custom metrics and use them with scikit-learn API.
A detailed guide on how to use logging module of Python to log events. Tutorial provides an explanation of how to log events of different types (warning, error, info, debug, etc), format error messages, log messages to files, filter log messages, etc. It is useful for basic logging as well as advanced logging for application with many sub-modules.
A comprehensive guide on how to use Python module tracemalloc to profile memory usage by Python code/script/program. Introduced in v3.4, it is a memory profiler that comes with default Python installation. Tutorial explains whole API of tracemalloc with simple examples.
A brief guide to using magic commands available in Jupyter notebooks. Magic commands are special commands starting with a single or double percent sign (%) that let us perform tasks that otherwise need a shell or another tool. Both line magic commands (%) and cell magic commands (%%) are covered in tutorial.
Parallel Computing is a type of computation where tasks are assigned to individual processes for completion. These processes can be running on a single computer or cluster of computers. Parallel Computing makes multi-tasking super fast.
Python provides different libraries (joblib, dask, ipyparallel, etc) for performing parallel computing.
Concurrent computing is a type of computing where multiple tasks are executed concurrently. Concurrent programming is a type of programming where we divide a big task into small tasks and execute these tasks in parallel. These tasks can be executed in parallel using threads or processes.
Python provides various libraries (threading, multiprocessing, concurrent.futures, asyncio, etc) to create concurrent code.
Once our Machine Learning model is trained, we need some way to evaluate its performance. We need to know whether our model has generalized or not.
For this, various metrics (confusion matrix, ROC AUC curve, precision-recall curve, silhouette Analysis, elbow method, etc) are designed over time. These metrics help us understand the performance of our models trained on various tasks like classification, regression, clustering, etc.
Python has various libraries (scikit-learn, scikit-plot, yellowbrick, interpret-ml, interpret-text, etc) to calculate and visualize these metrics.
After training ML Model, we generally evaluate the performance of model by calculating and visualizing various ML Metrics (confusion matrix, ROC AUC curve, precision-recall curve, silhouette Analysis, elbow method, etc).
These metrics are normally a good starting point. But in many situations, they don’t give a 100% picture of model performance. E.g., A simple cat vs dog image classifier can be using background pixels to classify images instead of actual object (cat or dog) pixels.
In these situations, our ML metrics will give good results. But we should always be a little skeptical of model performance.
We can dive further deep and try to understand how our model is performing on an individual example by interpreting results. Various algorithms have been developed over time to interpret predictions of ML models and many Python libraries (lime, eli5, treeinterpreter, shap, etc) provide their implementation.
Data Visualization is a field of graphical representation of information / data. It is one of the most efficient ways of communicating information with users as humans are quite good at capturing patterns in data.
Python has a bunch of libraries that can help us create data visualizations. Some of these libraries (matplotlib, seaborn, plotnine, etc) generate static charts whereas others (bokeh, plotly, bqplot, altair, holoviews, cufflinks, hvplot, etc) generate interactive charts. Majority of basic visualizations like bar charts, line charts, scatter plots, histograms, box plots, pie charts, etc are supported by all libraries. Many libraries also support advanced visualization, widgets, and dashboards.
Basic Data Visualizations like bar charts, line charts, scatter plots, histograms, box plots, pie charts, etc are quite good at representing information and exploring relationships between data variables.
But sometimes these visualizations are not enough and we need to analyze data from different perspectives. For this purpose, many advanced visualizations are developed over time like Sankey diagrams, candlestick charts, network charts, chord diagrams, sunburst charts, radar charts, parallel coordinates charts, etc. Python has many data visualization libraries that let us create such advanced data visualizations.
Deep learning is a field in Machine Learning that uses deep neural networks to solve tasks. The neural networks with generally more than one hidden layer are referred to as deep neural networks.
Many real-world tasks like object detection, image classification, image segmentation, etc can not be solved with simple machine learning models (decision trees, random forest, logistic regression, etc). Research has shown that neural networks with many layers are quite good at solving these kinds of tasks involving unstructured data (Image, text, audio, video, etc). Deep neural networks nowadays can have different kinds of layers like convolution, recurrent, etc apart from dense layers.
Python has many famous deep learning libraries (PyTorch, Keras, JAX, Flax, MXNet, Tensorflow, Sonnet, Haiku, PyTorch Lightning, Scikeras, Skorch, etc) that let us create deep neural networks to solve complicated tasks.
Image classification is a sub-field under computer vision and image processing that identifies an object present in an image and assigns a label to an image based on it. Image classification generally works on an image with a single object present in it.
Over the years, many deep neural networks (VGG, ResNet, AlexNet, MobileNet, etc) were developed that solved image classification task with quite a high accuracy. Due to the high accuracy of these algorithms, many Python deep learning libraries started providing these neural networks. We can simply load these networks with weights and make predictions using them.
Python libraries PyTorch and MXNet have helper modules named 'torchvision' and 'gluoncv’ respectively that provide an implementation of image classification networks.