Explain Codes LogoExplain Codes Logo

Python

Save classifier to disk in scikit-learn

python
scikit-learn
model-saving
data-science

Display help message with Python argparse when script is called without any arguments

python
prompt-engineering
best-practices
tools

'too many values to unpack', iterating over a dict. key=>string, value=>list

python
dictionary-iteration
python-3
unpacking-in-for-loops

How to remove axis, legends, and white padding

python
plotting
matplotlib
image-processing

How to get the return value from a thread?

python
threading
concurrent-futures
asyncio

Importerror: No module named requests

python
importerror
pip-installation
virtual-environments

Load data from txt with pandas

python
dataframe
pandas
data-manipulation

What is a clean "pythonic" way to implement multiple constructors?

python
best-practices
pythonic-way
constructor-patterns

Appending to an empty DataFrame in Pandas?

python
dataframe
pandas
data-manipulation

Mkdir -p functionality in Python

python
pathlib
mkdir
file-system

How to check if a string is a substring of items in a list of strings

python
list-comprehensions
regex
optimization

Querying Spark SQL DataFrame with complex types

python
dataframe
higher-order-functions
data-structures

Write to UTF-8 file in Python

python
utf-8
encoding
unicode

Lazy Method for Reading Big File in Python?

python
performance
best-practices
tools

How to make a datetime object aware (not naive)

python
timezone
datetime
pytz

How do I use brew installed Python as the default Python?

python
venv
best-practices
tools

Convert int to binary string in Python

python
format-specifiers
f-strings
binary-conversion

Find nearest value in numpy array

python
numpy
vectorization
data-analysis

Difference between exit() and sys.exit() in Python

python
system-exit
exit-function
python-modules

Log exception with traceback in Python

python
logging
exception-handling
best-practices