How to find overall inertia of the clusters in kmeans clustering

there are two variables, latitude and longitude now we have to fit the kmeans and find the overall inertia of the clusters. when I am trying with kmeans.inertia func bt the test cases were failed