Automating the Learning of Inverse Kinematics for Robotic Arms with Redundant DoFs