Python scripts to draw curve