Python code for Kaggle competitions