Learning from Demonstration with Implicit Nonlinear Dynamics Models