With rotation

With two pictures with and without rotation. The
script/Optimal_rotation.txt is the angles after rotation.