Skip to content

Implement haversine metric in pairwise, document properly #4453

Closed

Description

@amueller

See #4452.
The haversine metric is implemented in the neighbors trees, but not in pairwise module, which results in odd crashes.
Also, the neighbors module does not list the haversine metric as one of the available metrics in the docstring.

Activity

  1. added
    Easy
    on Mar 26, 2015
  2. added 4 commits that reference this issue on Mar 28, 2015
    3dba895
    c9a02bd
    334f34e
    aedd2de
  3. dshieble commented on Dec 6, 2015

    @dshieble

    Hi @amueller, does this issue still need someone? I'd be happy to work on this.

  4. amueller commented on Dec 10, 2015

    @amueller
    MemberAuthor

    there is a pull request at #dshieble. You can see if you can help there, though.

  5. modified the milestones: 0.19, 0.20 on Jun 14, 2017
  6. jnothman commented on Jun 14, 2017

    @jnothman
    Member

    We should probably have a test that every metric supported by neighbors is supported by pairwise_distances, no?

  7. jzf2101 commented on Jul 12, 2017

    @jzf2101

    Haversine pairwise distances seems only to be directly accessible through sklearn.neighbors.DistanceMetric.get_metric('haversine').pairwise. This method doesn't use joblib, unlike pairiwise?

  8. modified the milestones: 0.20, 0.21 on Jun 13, 2018
  9. rth commented on Nov 9, 2018

    @rth
    Member

    We should probably have a test that every metric supported by neighbors is supported by pairwise_distances, no?

    Having a test would certainly help, and by default maybe we should ideed fall back to DistanceMetric.get_metric(metric_name).pairwise in this case.

    #4458 needs benchmarking

    There is also some related discussion in #12552

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Easy

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions