Hi,
your machine is missing/gaining steps badly.
In the first instance double and then triple check the stepper to ballscrew connections.
If they are OK run the same program but above the material, ie not cutting, with the spindle off. Does it still lose/gain
steps?
If its OK with the spindle off there are two possibilities:
1) Electrical noise from the spindle is interfering with your stepper signals (step/dir)
2) The cutting forces are exceeding the torque capability of your steppers.
Craig