Deploy Django with Postgres, Nginx, and Gunicorn on Ubuntu 18.04

This a copy of https://www.digitalocean.com/community/tutorials/how-to-set-up-django-with-postgres-nginx-and-gunicorn-on-ubuntu-18-04 . Introduction Django is a powerful web framework that can help you get your Python […]

Logging in Python Tutorial

Adding logging to your Python program is as easy as this: import logging With the logging module imported, you can […]

Python Exceptions Best Practices

How do I manually throw/raise an exception in Python? Use the most specific Exception constructor that semantically fits your issue. […]

Basic Tutorial of Cython

The Basics of Cython The fundamental nature of Cython can be summed up as follows: Cython is Python with C […]

Compiling C extension modules on Windows (Cython)

Compiling C extension modules on Windows This page describes how to compile a Cython extension (works for CPython extensions also) […]

Cythonize setup.py for several .pyx files

Concept Distutils is the standard way to build Cython extension modules for large projects. Typically one invokes setup(…) which then […]

Kernel Density Estimation in Python

Kernel Density Estimation In statistics, kernel density estimation (KDE) is a non-parametric way to estimate the probability density function of […]

Implementations of Mutual Information (MI) and Entropy computation in Python

In probability theory and information theory, the mutual information (MI) of two random variables is a measure of the mutual […]