How to tune an XGBRegressor model with Optuna

The XGBRegressor regression model in XGBoost is one of the most effective regression models used in machine learning. As with the other XGBoost models, XGBRegressor is a gradient boosting model...

How to create and tune an AdaBoost classification model

AdaBoost is a boosting algorithm that combines multiple weak learners into a strong learner. It is a sequential technique that works by fitting a classifier on the original dataset and...

How to zip files and directories with Python

The zipfile module in Python provides a way to compress files and directories into a single zip file. This is useful for reducing the size of files and directories that...

How to list files and directories with Python

When working with Python you’ll often need to access files and directories on your computer. Python includes a useful os module that gives you access to your computer or server’s...

How to use a .gitignore file

The .gitignore file is a special file added to a Git repository to define the files and directories you do not wish to commit to your Git repository. This is...

How to use Spacy for POS tagging in Pandas

Spacy is one of the most popular Python packages for Natural Language Processing. Alongside the Natural Language Toolkit (NLTK), Spacy provides a huge range of functionality for a wide variety...

How to convert a column list of dictionaries to a Pandas dataframe

When working with Pandas dataframes, you may sometimes encounter a column that contains a list of Python dictionaries or JSON objects. While this format doesn’t take up much space and...

How to transcribe YouTube videos with OpenAI Whisper

OpenAI Whisper is a new open source automatic speech recognition (ASR) model from Elon Musk’s OpenAI project that has also brought us the incredible GPT-3 language models. Like GPT-3, it’s...

How to create a Shopify price tracker with Python

In ecommerce, it’s very common for retailers to need to monitor the prices of their competitors. Prices make a big difference to sales and if they’re set too high then...