{"id":13417858,"url":"https://github.com/mlpack/mlpack","last_synced_at":"2025-05-13T17:04:08.102Z","repository":{"id":24737025,"uuid":"28149409","full_name":"mlpack/mlpack","owner":"mlpack","description":"mlpack: a fast, header-only C++ machine learning library","archived":false,"fork":false,"pushed_at":"2025-05-01T19:47:54.000Z","size":275049,"stargazers_count":5340,"open_issues_count":16,"forks_count":1657,"subscribers_count":186,"default_branch":"master","last_synced_at":"2025-05-06T16:11:55.190Z","etag":null,"topics":["c-plus-plus","deep-learning","hacktoberfest","machine-learning","machine-learning-library","nearest-neighbor-search","regression","scientific-computing"],"latest_commit_sha":null,"homepage":"https://www.mlpack.org/","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mlpack.png","metadata":{"files":{"readme":"README.md","changelog":"HISTORY.md","contributing":"CONTRIBUTING.md","funding":".github/FUNDING.yml","license":"LICENSE.txt","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":"GOVERNANCE.md","roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null},"funding":{"github":["numfocus"],"custom":"https://numfocus.org/donate-to-mlpack"}},"created_at":"2014-12-17T18:16:59.000Z","updated_at":"2025-05-06T06:49:05.000Z","dependencies_parsed_at":"2023-01-16T22:15:25.550Z","dependency_job_id":"d2fe6b3a-4d06-4fed-89d0-b3ce21bebc99","html_url":"https://github.com/mlpack/mlpack","commit_stats":{"total_commits":27791,"total_committers":371,"mean_commits":74.90835579514825,"dds":0.7421827210247922,"last_synced_commit":"5b0167b67e3834abda1a80696f7b703ecccc2a08"},"previous_names":[],"tags_count":51,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mlpack%2Fmlpack","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mlpack%2Fmlpack/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mlpack%2Fmlpack/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mlpack%2Fmlpack/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mlpack","download_url":"https://codeload.github.com/mlpack/mlpack/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253990453,"owners_count":21995773,"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":["c-plus-plus","deep-learning","hacktoberfest","machine-learning","machine-learning-library","nearest-neighbor-search","regression","scientific-computing"],"created_at":"2024-07-30T22:00:54.178Z","updated_at":"2025-05-13T17:04:08.024Z","avatar_url":"https://github.com/mlpack.png","language":"C++","readme":"\u003ch2 align=\"center\"\u003e\n  \u003ca href=\"https://mlpack.org\"\u003e\u003cimg src=\"https://cdn.jsdelivr.net/gh/mlpack/mlpack.org@e7d36ed8/mlpack-black.svg\" style=\"background-color:rgba(0,0,0,0);\" height=230 alt=\"mlpack: a fast, header-only machine learning library\"\u003e\u003c/a\u003e\n  \u003cbr\u003ea fast, header-only machine learning library\u003cbr\u003e\n\u003c/h2\u003e\n\n\u003ch5 align=\"center\"\u003e\n  \u003ca href=\"https://mlpack.org\"\u003eHome\u003c/a\u003e |\n  \u003ca href=\"https://www.mlpack.org/download.html\"\u003eDownload\u003c/a\u003e |\n  \u003ca href=\"https://www.mlpack.org/doc/index.html\"\u003eDocumentation\u003c/a\u003e |\n  \u003ca href=\"https://www.mlpack.org/questions.html\"\u003eHelp\u003c/a\u003e |\n\u003c/h5\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://dev.azure.com/mlpack/mlpack/_build?definitionId=1\"\u003e\u003cimg alt=\"Azure DevOps builds (job)\" src=\"https://img.shields.io/azure-devops/build/mlpack/84320e87-76e3-4b6e-8b6e-3adaf6b36eed/1/master?job=Linux\u0026label=Linux%20Build\u0026style=flat-square\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://opensource.org/license/BSD-3-Clause\"\u003e\u003cimg src=\"https://img.shields.io/badge/License-BSD%203--Clause-blue.svg?style=flat-square\" alt=\"License\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://numfocus.org/donate-to-mlpack\"\u003e\u003cimg src=\"https://img.shields.io/badge/sponsored%20by-NumFOCUS-orange.svg?style=flat-square\u0026colorA=E1523D\u0026colorB=007D8A\" alt=\"NumFOCUS\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cem\u003e\n    Download:\n    \u003ca href=\"https://www.mlpack.org/files/mlpack-4.6.0.tar.gz\"\u003ecurrent stable version (4.6.0)\u003c/a\u003e\n  \u003c/em\u003e\n\u003c/p\u003e\n\n**mlpack** is an intuitive, fast, and flexible header-only C++ machine learning\nlibrary with bindings to other languages.  It is meant to be a machine learning\nanalog to LAPACK, and aims to implement a wide array of machine learning methods\nand functions as a \"swiss army knife\" for machine learning researchers.\n\nmlpack's lightweight C++ implementation makes it ideal for deployment, and it\ncan also be used for interactive prototyping via C++ notebooks (these can be\nseen in action on mlpack's [homepage](https://www.mlpack.org/)).\n\nIn addition to its powerful C++ interface, mlpack also provides command-line\nprograms, Python bindings, Julia bindings, Go bindings and R bindings.\n\n***Quick links:***\n\n - Quickstart guides: [C++](doc/quickstart/cpp.md),\n   [CLI](doc/quickstart/cli.md), [Python](doc/quickstart/python.md),\n   [R](doc/quickstart/r.md), [Julia](doc/quickstart/julia.md),\n   [Go](doc/quickstart/go.md)\n - [mlpack homepage](https://www.mlpack.org/)\n - [mlpack documentation](https://www.mlpack.org/doc/index.html)\n - [Examples repository](https://github.com/mlpack/examples/)\n - [Tutorials](doc/user/tutorials.md)\n - [Development Site (Github)](https://github.com/mlpack/mlpack/)\n\n[//]: # (numfocus-fiscal-sponsor-attribution)\n\nmlpack uses an [open governance model](./GOVERNANCE.md) and is fiscally\nsponsored by [NumFOCUS](https://numfocus.org/).  Consider making a\n[tax-deductible donation](https://numfocus.org/donate-to-mlpack) to help the\nproject pay for developer time, professional services, travel, workshops, and a\nvariety of other needs.\n\n\u003cdiv align=\"center\"\u003e\n  \u003ca href=\"https://numfocus.org/\"\u003e\n    \u003cimg height=\"60\"\n         src=\"https://raw.githubusercontent.com/numfocus/templates/master/images/numfocus-logo.png\"\n         align=\"middle\"\n         alt=\"NumFOCUS logo\"\u003e\n  \u003c/a\u003e\n\u003c/div\u003e\n\u003cbr\u003e\n\n## 0. Contents\n\n 1. [Citation details](#1-citation-details)\n 2. [Dependencies](#2-dependencies)\n 3. [Installation](#3-installation)\n 4. [Usage from C++](#4-usage-from-c)\n     1. [Reducing compile time](#41-reducing-compile-time)\n 5. [Building mlpack's test suite](#5-building-mlpacks-test-suite)\n 6. [Further resources](#6-further-resources)\n\n## 1. Citation details\n\nIf you use mlpack in your research or software, please cite mlpack using the\ncitation below (given in BibTeX format):\n\n    @article{mlpack2023,\n        title     = {mlpack 4: a fast, header-only C++ machine learning library},\n        author    = {Ryan R. Curtin and Marcus Edel and Omar Shrit and \n                     Shubham Agrawal and Suryoday Basak and James J. Balamuta and \n                     Ryan Birmingham and Kartik Dutt and Dirk Eddelbuettel and \n                     Rishabh Garg and Shikhar Jaiswal and Aakash Kaushik and \n                     Sangyeon Kim and Anjishnu Mukherjee and Nanubala Gnana Sai and \n                     Nippun Sharma and Yashwant Singh Parihar and Roshan Swain and \n                     Conrad Sanderson},\n        journal   = {Journal of Open Source Software},\n        volume    = {8},\n        number    = {82},\n        pages     = {5026},\n        year      = {2023},\n        doi       = {10.21105/joss.05026},\n        url       = {https://doi.org/10.21105/joss.05026}\n    }\n\nCitations are beneficial for the growth and improvement of mlpack.\n\n## 2. Dependencies\n\n**mlpack** requires the following additional dependencies:\n\n - C++17 compiler\n - [Armadillo](https://arma.sourceforge.net)      \u0026nbsp;\u0026emsp;\u003e= 10.8\n - [ensmallen](https://ensmallen.org)      \u0026emsp;\u003e= 2.10.0\n - [cereal](http://uscilab.github.io/cereal/)         \u0026ensp;\u0026nbsp;\u0026emsp;\u0026emsp;\u003e= 1.1.2\n\nIf the STB library headers are available, image loading support will be\navailable.\n\nIf you are compiling Armadillo by hand, ensure that LAPACK and BLAS are enabled.\n\n## 3. Installation\n\nDetailed installation instructions can be found on the\n[Installing mlpack](doc/user/install.md) page.\n\n## 4. Usage from C++\n\nOnce headers are installed with `make install`, using mlpack in an application\nconsists only of including it.  So, your program should include mlpack:\n\n```c++\n#include \u003cmlpack.hpp\u003e\n```\n\nand when you link, be sure to link against Armadillo.  If your example program\nis `my_program.cpp`, your compiler is GCC, and you would like to compile with\nOpenMP support (recommended) and optimizations, compile like this:\n\n```sh\ng++ -O3 -std=c++17 -o my_program my_program.cpp -larmadillo -fopenmp\n```\n\nNote that if you want to serialize (save or load) neural networks, you should\nadd `#define MLPACK_ENABLE_ANN_SERIALIZATION` before including `\u003cmlpack.hpp\u003e`.\nIf you don't define `MLPACK_ENABLE_ANN_SERIALIZATION` and your code serializes a\nneural network, a compilation error will occur.\n\n***Warning:*** older versions of OpenBLAS (0.3.26 and older) compiled to use\npthreads may use too many threads for computation, causing significant slowdown.\nOpenBLAS versions compiled with OpenMP do not suffer from this issue.  See the\n[test build guide](doc/user/install.md#build-tests) for more details and simple\nworkarounds.\n\nSee also:\n\n * the [test program compilation section](doc/user/install.md#compiling-a-test-program)\n   of the installation documentation,\n * the [C++ quickstart](doc/quickstart/cpp.md), and\n * the [examples repository](https://github.com/mlpack/examples) repository for\n   some examples of mlpack applications in C++, with corresponding `Makefile`s.\n\n### 4.1. Reducing compile time\n\nmlpack is a template-heavy library, and if care is not used, compilation time of\na project can be very high.  Fortunately, there are a number of ways to reduce\ncompilation time:\n\n * Include individual headers, like `\u003cmlpack/methods/decision_tree.hpp\u003e`, if you\n   are only using one component, instead of `\u003cmlpack.hpp\u003e`.  This reduces the\n   amount of work the compiler has to do.\n\n * Only use the `MLPACK_ENABLE_ANN_SERIALIZATION` definition if you are\n   serializing neural networks in your code.  When this define is enabled,\n   compilation time will increase significantly, as the compiler must generate\n   code for every possible type of layer.  (The large amount of extra\n   compilation overhead is why this is not enabled by default.)\n\n * If you are using mlpack in multiple .cpp files, consider using [`extern\n   templates`](https://isocpp.org/wiki/faq/cpp11-language-templates) so that the\n   compiler only instantiates each template once; add an explicit template\n   instantiation for each mlpack template type you want to use in a .cpp file,\n   and then use `extern` definitions elsewhere to let the compiler know it\n   exists in a different file.\n\nOther strategies exist too, such as precompiled headers, compiler options,\n[`ccache`](https://ccache.dev), and others.\n\n## 5. Building mlpack's test suite\n\nSee the [installation instruction section](doc/user/install.md#build-tests).\n\n## 6. Further Resources\n\nMore documentation is available for both users and developers.\n\n * [Documentation homepage](https://www.mlpack.org/doc/index.html)\n\nTo learn about the development goals of mlpack in the short- and medium-term\nfuture, see the [vision document](https://www.mlpack.org/papers/vision.pdf).\n\nIf you have problems, find a bug, or need help, you can try visiting\nthe [mlpack help](https://www.mlpack.org/questions.html) page, or [mlpack on\nGithub](https://github.com/mlpack/mlpack/).  Alternately, mlpack help can be\nfound on Matrix at `#mlpack`; see also the\n[community](https://www.mlpack.org/doc/developer/community.html) page.\n","funding_links":["https://github.com/sponsors/numfocus","https://numfocus.org/donate-to-mlpack"],"categories":["TODO scan for Android support in followings","C++","Machine Learning","The Data Science Toolbox","机器学习框架","Machine Learning Framework","Uncategorized","其他_机器学习与深度学习","Data Mining, Machine Learning, and Deep Learning"],"sub_categories":["General Machine Learning Packages","General Purpose Machine Learning","General Purpose Framework","Uncategorized","日志","Automatic Plotting"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmlpack%2Fmlpack","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmlpack%2Fmlpack","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmlpack%2Fmlpack/lists"}