Refining scan positions in Ptychography through error minimisation and potential application of Machine Learning