What just happened? Over the past few years, people have been watching---sometimes in horror---as Boston Dynamics' bipedal robot Atlas becomes increasingly agile. Now, the machine can complete an impressive gymnastics routine, which could be put to good use in a few decades when it hunts humans in a post-apocalyptic landscape.

There was a time when Atlas could barely put one foot in front of another, but by 2017 it was performing parkour and backflips. A year later, we saw Atlas jogging, leaping over logs, and bounding from one 40cm step to another, using its legs, arms, and torso to drive its jumps and for balancing.

In its latest video, Boston Dynamics shows its machine performing a gymnastics routine that most average people couldn't do. We see Atlas complete a handstand, jumping rolls, a 360-degree spinning jump, and a split leap.

Boston Dynamics explains that Atlas can carry out these moves thanks to an optimization algorithm that "transforms high-level descriptions of each maneuver into dynamically-feasible reference motions."

"Then Atlas tracks the motions using a model predictive controller that smoothly blends from one maneuver to the next."

While Atlas' agility is very impressive, it doesn't get things right every time. The video's description notes that the robot has a success rate of about 80 percent, so it does fall over 20 percent of the time.

Yesterday, Boston Dynamics announced it would be selling its quadruped 'Spot' robot (formerly SpotMini) to companies in "select industries." With a limited number of units available, each robot costs about as much as a luxury vehicle.