{"id":18408826,"url":"https://github.com/codeplaysoftware/sycl-ml","last_synced_at":"2025-04-07T09:33:18.997Z","repository":{"id":39228991,"uuid":"114899435","full_name":"codeplaysoftware/SYCL-ML","owner":"codeplaysoftware","description":"SYCL-ML is a C++ library, implementing classical machine learning algorithms using SYCL.","archived":false,"fork":false,"pushed_at":"2020-01-08T16:15:56.000Z","size":274,"stargazers_count":66,"open_issues_count":1,"forks_count":5,"subscribers_count":24,"default_branch":"master","last_synced_at":"2025-03-22T16:23:49.482Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"C++","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/codeplaysoftware.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-12-20T14:56:14.000Z","updated_at":"2025-01-27T10:07:18.000Z","dependencies_parsed_at":"2022-09-07T10:03:08.059Z","dependency_job_id":null,"html_url":"https://github.com/codeplaysoftware/SYCL-ML","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codeplaysoftware%2FSYCL-ML","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codeplaysoftware%2FSYCL-ML/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codeplaysoftware%2FSYCL-ML/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codeplaysoftware%2FSYCL-ML/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/codeplaysoftware","download_url":"https://codeload.github.com/codeplaysoftware/SYCL-ML/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247626634,"owners_count":20969340,"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":[],"created_at":"2024-11-06T03:21:43.254Z","updated_at":"2025-04-07T09:33:18.567Z","avatar_url":"https://github.com/codeplaysoftware.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# SYCL-ML\n\n## What is it?\nSYCL-ML is a framework providing simple classical machine learning algorithms using SYCL.\nIt is meant to be accelerated on any OpenCL device supporting SPIR or SPIR-V.\nThe following links give more details on what SYCL is:\n- https://www.khronos.org/sycl\n- https://developer.codeplay.com/computecppce/latest/sycl-guide-introduction\n\n## What can it do?\nSome linear algebra operations had to be implemented such as:\n- **Matrix inversion**\n- **SVD decomposition**\n- **QR decomposition**\n\nIn terms of machine learning related algorithms it includes:\n- **Principal Component Analysis**: used to reduce the dimensionality of a problem.\n- **Linear Classifier** (see naive Bayes classifier): classify assuming all variables are equally as important.\n- **Gaussian Classifier**: classify using the Gaussian distribution.\n- **Gaussian Mixture Model**: based on the EM algorithm, uses multiple Gaussian distribution for each labels.\n- **Support Vector Machine**: C-SVM with any kernel function.\n\nSYCL-ML is a header only library which makes it easy to integrate.\n\nMore details on what the project implements and how it works can be found on our [website](https://www.codeplay.com/portal/12-21-17-alternative-machine-learning-algorithms-using-sycl-and-opencl).\n\n## TODO list\n- Optimize **SVD** decomposition for faster PCA. The algorithm probably needs to be changed to compute eigenpairs differently.\n- Optimize **SVM** for GPU. More recent papers on SVM for GPU should be experimented.\n- Implement an **LDA** (or dimensionality reduction algorithms) which would be used as a preprocessing step similarly to a PCA.\n- Implement a **K-means** (or other clustering algorithms) which could be used to improve the initialization of the EM.\n- Add a proper way to select a SYCL device.\n\n## Prerequisites\nSYCL-ML has been tested with:\n- Ubuntu 16.04, amdgpu pro driver 17.40\n- CMake 3.0\n- g++ 5.4\n- ComputeCpp 1.2.0\n\nComputeCpp can be downloaded from the [CodePlay](https://www.codeplay.com/products/computesuite/computecpp) website.\nOnce extracted, ComputeCpp path should be set as an environment variable to `COMPUTECPP_DIR` (usually `/usr/local/computecpp`).\nAlternatively, it can be given as an argument to cmake with `-DComputeCpp_DIR=path/to/computecpp`.\n\n## Building\nBuild all the targets with:\n```bash\nmkdir build\ncd build\ncmake ..\nmake\n```\nCMake will take care of downloading the Eigen dependency and MNIST dataset.\nOn Unix it will automatically extract the MNIST dataset using `gunzip`.\n\nIt is recommended to run the tests before running the examples:\n```bash\ncd build/tests\nctest --output-on-failure\n```\n\nThe documentation can be built with `doxygen`. It requires `dot` from the `graphviz` package. Simply run:\n```bash\ndoxygen\n```\n\n## Contributing\nThe project is under the Apache 2.0 license. Any contribution is welcome! Also feel free to raise an issue for any\nquestions or suggestions.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodeplaysoftware%2Fsycl-ml","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcodeplaysoftware%2Fsycl-ml","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodeplaysoftware%2Fsycl-ml/lists"}