Developing AI-controlled machines with good sim-to-real transfer