Machine Learning

ssl.SSLCertVerificationError [SSL CERTIFICATE_VERIFY_FAILED] certificate verify failed

ssl.SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed

Summary: Error occurs when Python cannot verify the SSL/TLS certificate of a remote server while making HTTPS requests, installing packages using pip or calling APIs in scripts, virtual environments, Docker containers or production servers.   Checkout cool headphones on Amazon What does ssl certificate_verify_failed mean ? While making an HTTPS request using Python we need

ssl.SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed Read More »

Solve ValueError: Found Input Variables with Inconsistent Numbers of Sample

The error “ValueError: Found input variables with inconsistent numbers of samples” comes in python libraries like scikit-learn because our feature matrix (X) and target vector (y) do not have the same number of rows. Solution to the error is to verify dataset shapes and remove misaligned rows and have the same number of records for

Solve ValueError: Found Input Variables with Inconsistent Numbers of Sample Read More »

Get attributes of object in Python

Get attributes of object Python

While working with objects in Python, we will often need to inspect, list or access attributes dynamically. Whether we are debugging, building frameworks, or designing dynamic systems, understanding how to get attributes of objects in Python is a must have skill. In this tutorial we will explore multiple ways to get all attributes of object

Get attributes of object Python Read More »

xgb feature importance

XGB feature importance

XGBoost or XGB stands for extreme gradient boosting. In XGB, feature importance points to how much a particular feature contributes to the model’s predictions. It is very important to know which features contribute most to the models’s prediction when we have a large number of columns in the dataset. XGBoost provides several ways to compute

XGB feature importance Read More »

truncate decimal number

How to truncate decimals in Python

When we are working with numbers in Python, we sometimes come across situations where we get numbers like 34.00001, 10000.2358, etc. But in certain situations, these decimal points don’t add value to our calculation and we want to round or truncate the decimals. In this blog, we will see several techniques for truncating decimals using

How to truncate decimals in Python Read More »