User Tools

Site Tools


haversine

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
haversine [2020/10/15 20:23] prasanthihaversine [2020/10/18 02:53] (current) – [link dump] prasanthi
Line 1: Line 1:
-==== dummy ==== 
-  * https://en.wikipedia.org/wiki/Haversine_formula 
-  * https://en.wikipedia.org/wiki/Great_circle - has a picture of the great circle (in the context of a sphere). 
-  * https://en.wikipedia.org/wiki/Versine#Haversine - has a picture that shows how trigonometric functions can be constructed geometrically using unit circle. Contains a table of derivative and integral formulas for various types of versines. 
-  * http://rosettacode.org/wiki/Haversine_formula#Python - gives barebones python code. In practice, we are probably better off using scikit-learn functions? 
-  * https://stackoverflow.com/questions/34557898/pairwise-haversine-distance-calculation - In practice, we are probably better off using scikit-learn functions. But the discussion, sample code here is probably useful? 
  
 ==== scikit-learn functions ==== ==== scikit-learn functions ====
 +
 +Documentation:-
 +  * https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise.haversine_distances.html
 +
 +Code references:-
 +  * https://github.com/scikit-learn/scikit-learn/blob/master/sklearn/metrics/tests/test_pairwise.py -> test_haversine_distances() shows a sample call. This function also contains a slower implementation. Afterwards, compare the timings of the native scikit-learn function and its slower implementation.
 +  * https://github.com/scikit-learn/scikit-learn/blob/0.23.2/sklearn/metrics/pairwise.py -> haversine_distances() shows the implementation.
 +
 +History:-
   * The sklearn.metrics.pairwise.haversine_distances function was added in 0.21.0   * The sklearn.metrics.pairwise.haversine_distances function was added in 0.21.0
   * The 0.21.0 was released on 2019-05   * The 0.21.0 was released on 2019-05
Line 13: Line 16:
   * https://scikit-learn.org/dev/whats_new/v0.21.html#version-0-21-0 - shows the release date   * https://scikit-learn.org/dev/whats_new/v0.21.html#version-0-21-0 - shows the release date
  
-Code references:- +==== link dump ==== 
-  * https://github.com/scikit-learn/scikit-learn/blob/master/sklearn/metrics/tests/test_pairwise.py -> test_haversine_distances() shows sample call. This function also contains a slower implementation. Afterwards, compare the timings of the native scikit-learn function and its slower implementation+  * https://en.wikipedia.org/wiki/Haversine_formula 
-  * https://github.com/scikit-learn/scikit-learn/blob/0.23.2/sklearn/metrics/pairwise.py -> haversine_distances() shows the implementation. +  * https://en.wikipedia.org/wiki/Great_circle has nice picture of the great circle (in the context of sphere)
- +  * https://en.wikipedia.org/wiki/Versine#Haversine has a picture that shows how trigonometric functions can be constructed geometrically using unit circle. Contains a table of derivative and integral formulas for various types of versines. 
-Documentation:+  * http://rosettacode.org/wiki/Haversine_formula#Python gives bare bones python codeIn practice, we are probably better off using scikit-learn functions? 
-  * https://scikit-learn.org/stable/modules/generated/sklearn.metrics.pairwise.haversine_distances.html+  * https://stackoverflow.com/questions/34557898/pairwise-haversine-distance-calculation - In practice, we are probably better off using scikit-learn functionsBut the discussion, sample code here is probably useful?
  
haversine.1602793415.txt.gz · Last modified: 2020/10/15 20:23 by prasanthi