I love fancy machine learning algorithms as much as anyone. But sometimes, you just need to count things. And Python’s built-in data structures make this really easy. Let’s say we have a list of strings: With a list like this, you might care about a few different counts. What’s the … Read more
This post describes a trick for installing/upgrading Python packages in a Jupyter notebook. It’s useful for scratch code, but don’t do this when you need reproducible code.
Using and suppressing scientific notation in Python and NumPy.
The best way to sort a list of tuples in Python.
There are lots of ways to generate combinations in Python. This post will show you all of them.
A few ideas if you’re having trouble upgrading pip on macOS
Once in a while, a Python package gets corrupted on your machine and you need to force pip to reinstall it. As of pip 10.0, you can run the following…
There are lots of ways to install TensorFlow, which means (unfortunately) there is no one-size-fits-all solution for uninstalling it.
You can use youtube-dl to download arbitrary YouTube videos from the command line. This is useful for doing machine learning on new videos.