mdp_playground.envs.rl_toy_env.dist_of_pt_from_line

mdp_playground.envs.rl_toy_env.dist_of_pt_from_line(pt, ptA, ptB)[source]

Returns shortest distance of a point from a line defined by 2 points - ptA and ptB. Based on: https://softwareengineering.stackexchange.com/questions/168572/distance-from-point-to-n-dimensional-line