{"id":22220234,"url":"https://github.com/uxlfoundation/scikit-learn-intelex","last_synced_at":"2026-02-14T03:18:55.642Z","repository":{"id":37461648,"uuid":"143831524","full_name":"uxlfoundation/scikit-learn-intelex","owner":"uxlfoundation","description":" Extension for Scikit-learn is a seamless way to speed up your Scikit-learn application","archived":false,"fork":false,"pushed_at":"2025-04-18T10:42:08.000Z","size":36992,"stargazers_count":1272,"open_issues_count":88,"forks_count":182,"subscribers_count":24,"default_branch":"main","last_synced_at":"2025-04-18T18:40:28.793Z","etag":null,"topics":["ai-inference","ai-machine-learning","ai-training","analytics","big-data","data-analysis","gpu","machine-learning","machine-learning-algorithms","oneapi","python","scikit-learn","swrepo"],"latest_commit_sha":null,"homepage":"https://uxlfoundation.github.io/scikit-learn-intelex/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/uxlfoundation.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":"SECURITY.md","support":"SUPPORT.md","governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2018-08-07T06:45:41.000Z","updated_at":"2025-04-18T17:47:13.000Z","dependencies_parsed_at":"2022-07-12T16:18:09.246Z","dependency_job_id":"e56a5b13-04a6-41e9-a781-d7a587eb494f","html_url":"https://github.com/uxlfoundation/scikit-learn-intelex","commit_stats":{"total_commits":1703,"total_committers":96,"mean_commits":"17.739583333333332","dds":0.8590722254844392,"last_synced_commit":"5df8206fa5b787069a16d482febb66a34c693a10"},"previous_names":["intelpython/daal4py","uxlfoundation/scikit-learn-intelex"],"tags_count":40,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/uxlfoundation%2Fscikit-learn-intelex","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/uxlfoundation%2Fscikit-learn-intelex/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/uxlfoundation%2Fscikit-learn-intelex/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/uxlfoundation%2Fscikit-learn-intelex/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/uxlfoundation","download_url":"https://codeload.github.com/uxlfoundation/scikit-learn-intelex/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250360480,"owners_count":21417720,"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":["ai-inference","ai-machine-learning","ai-training","analytics","big-data","data-analysis","gpu","machine-learning","machine-learning-algorithms","oneapi","python","scikit-learn","swrepo"],"created_at":"2024-12-02T23:05:04.963Z","updated_at":"2025-12-11T21:04:12.398Z","avatar_url":"https://github.com/uxlfoundation.png","language":"Python","funding_links":[],"categories":["Python"],"sub_categories":[],"readme":"\u003c!--\n  ~ Copyright 2018 Intel Corporation\n  ~\n  ~ Licensed under the Apache License, Version 2.0 (the \"License\");\n  ~ you may not use this file except in compliance with the License.\n  ~ You may obtain a copy of the License at\n  ~\n  ~     http://www.apache.org/licenses/LICENSE-2.0\n  ~\n  ~ Unless required by applicable law or agreed to in writing, software\n  ~ distributed under the License is distributed on an \"AS IS\" BASIS,\n  ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n  ~ See the License for the specific language governing permissions and\n  ~ limitations under the License.\n--\u003e\n\n\u003cdiv align=\"center\"\u003e\n\n\n# Extension for Scikit-learn*\n\n\u003ch3\u003e Speed up your scikit-learn applications for CPUs and GPUs across single- and multi-node configurations\n\n[Releases](https://github.com/uxlfoundation/scikit-learn-intelex/releases)\u0026nbsp;\u0026nbsp;\u0026nbsp;|\u0026nbsp;\u0026nbsp;\u0026nbsp;[Documentation](https://uxlfoundation.github.io/scikit-learn-intelex/)\u0026nbsp;\u0026nbsp;\u0026nbsp;|\u0026nbsp;\u0026nbsp;\u0026nbsp;[Examples](https://github.com/uxlfoundation/scikit-learn-intelex/tree/master/examples/notebooks)\u0026nbsp;\u0026nbsp;\u0026nbsp;|\u0026nbsp;\u0026nbsp;\u0026nbsp;[Support](SUPPORT.md)\u0026nbsp;\u0026nbsp;\u0026nbsp;|\u0026nbsp;\u0026nbsp;[License](https://github.com/uxlfoundation/scikit-learn-intelex/blob/master/LICENSE)\u0026nbsp;\u0026nbsp;\u0026nbsp;\n\n\n[![Build Status](https://dev.azure.com/daal/daal4py/_apis/build/status/CI?branchName=main)](https://dev.azure.com/daal/daal4py/_build/latest?definitionId=9\u0026branchName=main)\n[![Coverity Scan Build Status](https://scan.coverity.com/projects/21716/badge.svg)](https://scan.coverity.com/projects/daal4py)\n[![OpenSSF Scorecard](https://api.securityscorecards.dev/projects/github.com/uxlfoundation/scikit-learn-intelex/badge)](https://securityscorecards.dev/viewer/?uri=github.com/uxlfoundation/scikit-learn-intelex)\n[![Join the community on GitHub Discussions](https://badgen.net/badge/join%20the%20discussion/on%20github/black?icon=github)](https://github.com/uxlfoundation/scikit-learn-intelex/discussions)\n[![PyPI Version](https://img.shields.io/pypi/v/scikit-learn-intelex)](https://pypi.org/project/scikit-learn-intelex/)\n[![Conda Version](https://img.shields.io/conda/vn/conda-forge/scikit-learn-intelex)](https://anaconda.org/conda-forge/scikit-learn-intelex)\n[![python version](https://img.shields.io/badge/python-3.9%20%7C%203.10%20%7C%203.11%20%7C%203.12%20%7C%203.13-blue)](https://img.shields.io/badge/python-3.9%20%7C%203.10%20%7C%203.11%20%7C%203.12%20%7C%203.13-blue)\n[![scikit-learn supported versions](https://img.shields.io/badge/sklearn-1.0%20%7C%201.4%20%7C%201.5%20%7C%201.6%20%7C%201.7-blue)](https://img.shields.io/badge/sklearn-1.0%20%7C%201.4%20%7C%201.5%20%7C%201.6%20%7C%201.7-blue)\n\n---\n\u003c/h3\u003e\n\n\u003cdiv align=\"left\"\u003e\n\n## Overview\n\nExtension for Scikit-learn is a **free software AI accelerator** designed to deliver over **10-100X** acceleration to your existing scikit-learn code.\nThe software acceleration is achieved with vector instructions, AI hardware-specific memory optimizations, threading, and optimizations.\n\n\nWith Extension for Scikit-learn, you can:\n\n* Speed up training and inference by up to 100x with equivalent mathematical accuracy\n* Benefit from performance improvements across different hardware configurations, including [GPUs](https://uxlfoundation.github.io/scikit-learn-intelex/latest/oneapi-gpu.html) and [multi-GPU](https://uxlfoundation.github.io/scikit-learn-intelex/latest/distributed-mode.html) configurations\n* Integrate the extension into your existing Scikit-learn applications without code modifications\n* Continue to use the open-source scikit-learn API\n* Enable and disable the extension with a couple of lines of code or at the command line\n\n## Acceleration\n\n![](https://raw.githubusercontent.com/uxlfoundation/scikit-learn-intelex/master/doc/sources/_static/scikit-learn-acceleration.PNG)\n\n[Benchmarks code](https://github.com/IntelPython/scikit-learn_bench)\n\n## Optimizations\n\nEasiest way to benefit from accelerations from the extension is by patching scikit-learn with it:\n\n- **Enable CPU optimizations**\n\n    ```python\n    import numpy as np\n    from sklearnex import patch_sklearn\n    patch_sklearn()\n\n    from sklearn.cluster import DBSCAN\n\n    X = np.array([[1., 2.], [2., 2.], [2., 3.],\n                  [8., 7.], [8., 8.], [25., 80.]], dtype=np.float32)\n    clustering = DBSCAN(eps=3, min_samples=2).fit(X)\n    ```\n\n- **Enable GPU optimizations**\n\n    _Note: executing on GPU has [additional system software requirements](https://www.intel.com/content/www/us/en/developer/articles/system-requirements/intel-oneapi-dpcpp-system-requirements.html) - see [details](https://uxlfoundation.github.io/scikit-learn-intelex/latest/oneapi-gpu.html)._\n\n    ```python\n    import numpy as np\n    from sklearnex import patch_sklearn, config_context\n    patch_sklearn()\n\n    from sklearn.cluster import DBSCAN\n\n    X = np.array([[1., 2.], [2., 2.], [2., 3.],\n                  [8., 7.], [8., 8.], [25., 80.]], dtype=np.float32)\n    with config_context(target_offload=\"gpu:0\"):\n        clustering = DBSCAN(eps=3, min_samples=2).fit(X)\n    ```\n\n:eyes: Check out available [notebooks](https://github.com/uxlfoundation/scikit-learn-intelex/tree/master/examples/notebooks) for more examples.\n\n### Usage without patching\n\nAlternatively, all functionalities are also available under a separate module which can be imported directly, without involving any patching.\n\n* To run on CPU:\n\n  ```python\n  import numpy as np\n  from sklearnex.cluster import DBSCAN\n\n  X = np.array([[1., 2.], [2., 2.], [2., 3.],\n                [8., 7.], [8., 8.], [25., 80.]], dtype=np.float32)\n  clustering = DBSCAN(eps=3, min_samples=2).fit(X)\n  ```\n\n* To run on GPU:\n\n  ```python\n  import numpy as np\n  from sklearnex import config_context\n  from sklearnex.cluster import DBSCAN\n\n  X = np.array([[1., 2.], [2., 2.], [2., 3.],\n                [8., 7.], [8., 8.], [25., 80.]], dtype=np.float32)\n  with config_context(target_offload=\"gpu:0\"):\n      clustering = DBSCAN(eps=3, min_samples=2).fit(X)\n  ```\n\n## Installation\n\nTo install Extension for Scikit-learn, run:\n\n```shell\npip install scikit-learn-intelex\n```\n\nPackage is also offered through other channels such as conda-forge. See all installation instructions in the [Installation Guide](https://github.com/uxlfoundation/scikit-learn-intelex/blob/main/INSTALL.md).\n\n## Integration\n\nThe easiest way of accelerating scikit-learn workflows with the extension is through through [patching](https://uxlfoundation.github.io/scikit-learn-intelex/latest/quick-start.html#patching), which replaces the stock scikit-learn algorithms with their optimized versions provided by the extension using the same namespaces in the same modules as scikit-learn.\n\nThe patching only affects [supported algorithms and their parameters](https://uxlfoundation.github.io/scikit-learn-intelex/latest/algorithms.html).\nYou can still use not supported ones in your code, the package simply fallbacks into the stock version of scikit-learn.\n\n\u003e **_TIP:_** Enable [verbose mode](https://uxlfoundation.github.io/scikit-learn-intelex/latest/verbose.html) to see which implementation of the algorithm is currently used.\n\nTo patch scikit-learn, you can:\n* Use the following command-line flag:\n  ```shell\n  python -m sklearnex my_application.py\n  ```\n* Add the following lines to the script:\n  ```python\n  from sklearnex import patch_sklearn\n  patch_sklearn()\n  ```\n\n:eyes: Read about [other ways to patch scikit-learn](https://uxlfoundation.github.io/scikit-learn-intelex/latest/quick-start.html#patching).\n\nAs an alternative, accelerated classes from the extension can also be imported directly without patching, thereby allowing to keep them separate from stock scikit-learn ones - for example:\n\n```python\nfrom sklearnex.cluster import DBSCAN as exDBSCAN\nfrom sklearn.cluster import DBSCAN as stockDBSCAN\n\n# ...\n```\n\n## Documentation\n\n* [Quick Start](https://uxlfoundation.github.io/scikit-learn-intelex/latest/quick-start.html)\n* [Documentation and Tutorials](https://uxlfoundation.github.io/scikit-learn-intelex/latest/index.html)\n* [Release Notes](https://github.com/uxlfoundation/scikit-learn-intelex/releases)\n* [Medium Blogs](https://uxlfoundation.github.io/scikit-learn-intelex/latest/blogs.html)\n* [Code of Conduct](https://github.com/uxlfoundation/scikit-learn-intelex/blob/master/CODE_OF_CONDUCT.md)\n\n### Extension and oneDAL\n\nAcceleration in patched scikit-learn classes is achieved by replacing calls to scikit-learn with calls to oneDAL (oneAPI Data Analytics Library) behind the scenes:\n- [oneAPI Data Analytics Library](https://github.com/uxlfoundation/oneDAL)\n\n## Samples \u0026 Examples\n\n* [Examples](https://github.com/uxlfoundation/scikit-learn-intelex/tree/master/examples/notebooks)\n* [Samples](https://uxlfoundation.github.io/scikit-learn-intelex/latest/samples.html)\n* [Kaggle Kernels](https://uxlfoundation.github.io/scikit-learn-intelex/latest/kaggle.html)\n\n\n## How to Contribute\n\nWe welcome community contributions, check our [Contributing Guidelines](https://github.com/uxlfoundation/scikit-learn-intelex/blob/master/CONTRIBUTING.md) to learn more.\n\n------------------------------------------------------------------------\n\\* The Intel logo, and other Intel marks are trademarks of Intel Corporation or its subsidiaries. Other names and brands may be claimed as the property of others.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fuxlfoundation%2Fscikit-learn-intelex","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fuxlfoundation%2Fscikit-learn-intelex","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fuxlfoundation%2Fscikit-learn-intelex/lists"}