Some random Python functions for my projects