Python code utilities and samples