Variational Optimization of finite Projected Entangled Pair States