{"id":13633344,"url":"https://github.com/scikit-learn-contrib/metric-learn","last_synced_at":"2025-05-14T16:14:09.990Z","repository":{"id":11574797,"uuid":"14063354","full_name":"scikit-learn-contrib/metric-learn","owner":"scikit-learn-contrib","description":"Metric learning algorithms in Python","archived":false,"fork":false,"pushed_at":"2024-08-03T19:34:12.000Z","size":12624,"stargazers_count":1397,"open_issues_count":51,"forks_count":234,"subscribers_count":46,"default_branch":"master","last_synced_at":"2024-10-29T15:17:23.918Z","etag":null,"topics":["machine-learning","metric-learning","python","scikit-learn"],"latest_commit_sha":null,"homepage":"http://contrib.scikit-learn.org/metric-learn/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/scikit-learn-contrib.png","metadata":{"files":{"readme":"README.rst","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2013-11-02T08:29:47.000Z","updated_at":"2024-10-27T15:23:30.000Z","dependencies_parsed_at":"2024-11-15T10:53:17.446Z","dependency_job_id":null,"html_url":"https://github.com/scikit-learn-contrib/metric-learn","commit_stats":{"total_commits":289,"total_committers":26,"mean_commits":"11.115384615384615","dds":0.6608996539792388,"last_synced_commit":"dc7e4499b1a9e522f03c87ba8dc249f9747cac82"},"previous_names":["all-umass/metric-learn","metric-learn/metric-learn"],"tags_count":11,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/scikit-learn-contrib%2Fmetric-learn","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/scikit-learn-contrib%2Fmetric-learn/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/scikit-learn-contrib%2Fmetric-learn/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/scikit-learn-contrib%2Fmetric-learn/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/scikit-learn-contrib","download_url":"https://codeload.github.com/scikit-learn-contrib/metric-learn/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248161242,"owners_count":21057552,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["machine-learning","metric-learning","python","scikit-learn"],"created_at":"2024-08-01T23:00:34.030Z","updated_at":"2025-04-10T04:48:39.830Z","avatar_url":"https://github.com/scikit-learn-contrib.png","language":"Python","funding_links":[],"categories":["Training","Frameworks-for-Training","Frameworks for Training","Machine Learning Framework","Table of Contents","Python","Others","其他_机器学习与深度学习"],"sub_categories":["Frameworks for Training","Popular-LLM","General Purpose Framework"],"readme":"|GitHub Actions Build Status| |License| |PyPI version| |Code coverage|\n\nmetric-learn: Metric Learning in Python\n=======================================\n\nmetric-learn contains efficient Python implementations of several popular supervised and weakly-supervised metric learning algorithms. As part of `scikit-learn-contrib \u003chttps://github.com/scikit-learn-contrib\u003e`_, the API of metric-learn is compatible with `scikit-learn \u003chttp://scikit-learn.org/stable/\u003e`_, the leading library for machine learning in Python. This allows to use all the scikit-learn routines (for pipelining, model selection, etc) with metric learning algorithms through a unified interface.\n\n**Algorithms**\n\n-  Large Margin Nearest Neighbor (LMNN)\n-  Information Theoretic Metric Learning (ITML)\n-  Sparse Determinant Metric Learning (SDML)\n-  Least Squares Metric Learning (LSML)\n-  Sparse Compositional Metric Learning (SCML)\n-  Neighborhood Components Analysis (NCA)\n-  Local Fisher Discriminant Analysis (LFDA)\n-  Relative Components Analysis (RCA)\n-  Metric Learning for Kernel Regression (MLKR)\n-  Mahalanobis Metric for Clustering (MMC)\n\n**Dependencies**\n\n-  Python 3.6+ (the last version supporting Python 2 and Python 3.5 was\n   `v0.5.0 \u003chttps://pypi.org/project/metric-learn/0.5.0/\u003e`_)\n-  numpy\u003e= 1.11.0, scipy\u003e= 0.17.0, scikit-learn\u003e=0.21.3\n\n**Optional dependencies**\n\n- For SDML, using skggm will allow the algorithm to solve problematic cases\n  (install from commit `a0ed406 \u003chttps://github.com/skggm/skggm/commit/a0ed406586c4364ea3297a658f415e13b5cbdaf8\u003e`_).\n  ``pip install 'git+https://github.com/skggm/skggm.git@a0ed406586c4364ea3297a658f415e13b5cbdaf8'`` to install the required version of skggm from GitHub.\n-  For running the examples only: matplotlib\n\n**Installation/Setup**\n\n- If you use Anaconda: ``conda install -c conda-forge metric-learn``. See more options `here \u003chttps://github.com/conda-forge/metric-learn-feedstock#installing-metric-learn\u003e`_.\n\n- To install from PyPI: ``pip install metric-learn``.\n\n- For a manual install of the latest code, download the source repository and run ``python setup.py install``. You may then run ``pytest test`` to run all tests (you will need to have the ``pytest`` package installed).\n\n**Usage**\n\nSee the `sphinx documentation`_ for full documentation about installation, API, usage, and examples.\n\n**Citation**\n\nIf you use metric-learn in a scientific publication, we would appreciate\ncitations to the following paper:\n\n`metric-learn: Metric Learning Algorithms in Python\n\u003chttp://www.jmlr.org/papers/volume21/19-678/19-678.pdf\u003e`_, de Vazelhes\n*et al.*, Journal of Machine Learning Research, 21(138):1-6, 2020.\n\nBibtex entry::\n\n  @article{metric-learn,\n    title = {metric-learn: {M}etric {L}earning {A}lgorithms in {P}ython},\n    author = {{de Vazelhes}, William and {Carey}, CJ and {Tang}, Yuan and\n              {Vauquier}, Nathalie and {Bellet}, Aur{\\'e}lien},\n    journal = {Journal of Machine Learning Research},\n    year = {2020},\n    volume = {21},\n    number = {138},\n    pages = {1--6}\n  }\n\n.. _sphinx documentation: http://contrib.scikit-learn.org/metric-learn/\n\n.. |GitHub Actions Build Status| image:: https://github.com/scikit-learn-contrib/metric-learn/workflows/CI/badge.svg\n   :target: https://github.com/scikit-learn-contrib/metric-learn/actions?query=event%3Apush+branch%3Amaster\n.. |License| image:: http://img.shields.io/:license-mit-blue.svg?style=flat\n   :target: http://badges.mit-license.org\n.. |PyPI version| image:: https://badge.fury.io/py/metric-learn.svg\n   :target: http://badge.fury.io/py/metric-learn\n.. |Code coverage| image:: https://codecov.io/gh/scikit-learn-contrib/metric-learn/branch/master/graph/badge.svg\n   :target: https://codecov.io/gh/scikit-learn-contrib/metric-learn\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fscikit-learn-contrib%2Fmetric-learn","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fscikit-learn-contrib%2Fmetric-learn","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fscikit-learn-contrib%2Fmetric-learn/lists"}