{"id":15936719,"url":"https://github.com/abdulfatir/subkmeans","last_synced_at":"2026-05-09T14:33:58.300Z","repository":{"id":82220314,"uuid":"124094854","full_name":"abdulfatir/subKmeans","owner":"abdulfatir","description":"Numpy and pyCUDA implementation of subKmeans","archived":false,"fork":false,"pushed_at":"2018-04-20T11:12:09.000Z","size":2037,"stargazers_count":1,"open_issues_count":0,"forks_count":2,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-02-09T07:41:31.353Z","etag":null,"topics":["clustering","cuda","kdd","kmeans","numpy","pycuda","python","subspace-clustering"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/abdulfatir.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2018-03-06T15:02:08.000Z","updated_at":"2023-06-04T05:14:27.000Z","dependencies_parsed_at":null,"dependency_job_id":"f5b4698a-413f-45fe-bdb0-da35d0758c1e","html_url":"https://github.com/abdulfatir/subKmeans","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/abdulfatir%2FsubKmeans","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/abdulfatir%2FsubKmeans/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/abdulfatir%2FsubKmeans/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/abdulfatir%2FsubKmeans/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/abdulfatir","download_url":"https://codeload.github.com/abdulfatir/subKmeans/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247064957,"owners_count":20877678,"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":["clustering","cuda","kdd","kmeans","numpy","pycuda","python","subspace-clustering"],"created_at":"2024-10-07T04:40:32.177Z","updated_at":"2026-05-09T14:33:53.262Z","avatar_url":"https://github.com/abdulfatir.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Fast Subspace Clustering\n## A GPU Implementation of *subKMeans*\u003csup\u003e[1]\u003c/sup\u003e\n\nThis is a CPU and GPU implementation of the KDD 2017 paper **Towards an Optimal Subspace for K-Means**\u003csup\u003e[1]\u003c/sup\u003e. \nThe CPU implementation (`mode=cpu`) is written in Numpy. \nThere are 2 GPU implementations:    \n1. Using only PyCUDA and scikit-cuda API (`mode=gpu`)\n2. Using PyCUDA with custom kernels optimized for this algorithm (`mode=gpu_custom`)\n\n### Dependencies\n\n* Numpy\n* PyCUDA: `pip install pycuda`\n* scikit-cuda: Install from source as described [here](https://github.com/lebedov/scikit-cuda/blob/master/docs/source/install.rst).\nWe tested using [commit #249538c](https://github.com/lebedov/scikit-cuda/commit/249538c95e68d891e2477d93eeff57941c99eb93).\n* Matplotlib (for plots)\n* scikit-learn (for computing NMI score)\n\nNote: We tested this implementation only on Python 2. There are some issues with the GPU version on Python 3.\n\n### Usage\n\nGo to `src/`\n```bash\npython main.py -d=\u003cdataset_name\u003e -k=\u003cnumber_of_clusters\u003e -mode=\u003cmode\u003e\n```\nFor help: `python main.py -h`\n\n3 available modes: `cpu`, `gpu`, `gpu_custom`\n\n#### Example Usage\n`python main.py -d=wine -k=3 -mode=cpu`\n##### Sample Output\n```\n[i] Itr 1: 24 points changed\n[i] Itr 2: 7 points changed\n[i] Itr 3: 7 points changed\n[i] Itr 4: 2 points changed\n[i] Itr 5: 1 points changed\n[i] Itr 6: 0 points changed\n\n[i] Results\n[*] m: 2\n[*] NMI: 0.87590\n```\n\n\n\n### References\n[1] *Mautz et. al.* Towards an Optimal Subspace for K-Means\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fabdulfatir%2Fsubkmeans","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fabdulfatir%2Fsubkmeans","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fabdulfatir%2Fsubkmeans/lists"}