Fine tuning dot python