Robot Learning from Demonstration Using Elastic Maps