My project is in the field of image processing. The output of a certain program would print the x and y coordinates in the image. I calculate the arithmetic mean of the points to get the mean coordinate. But some times I get one or two wrong points which in turn affects my arithmetic mean drastically. How do I find this point which occurs very much away from my ideal points.
ideal case scenario: output is (1,1),(0,5),(5,0) and the center point becomes (2,2)
real time scenario: output is (1,1),(0,5),(56,87) and the center becomes (19,31)
In this case I want to ignore (56,87) so that the center becomes (0.3,2)
If you could suggest a library in python to deal with the same I'd be very happy.