Learning Environment And Dynamics Representations For Autonomous Robot Navigation