Learning Dynamics from Data Using Optimal Transport Techniques and Applications