{"id":15063988,"url":"https://github.com/bgu-cs-vil/pdc-dp-means","last_synced_at":"2025-04-10T11:50:23.495Z","repository":{"id":49344166,"uuid":"504111840","full_name":"BGU-CS-VIL/pdc-dp-means","owner":"BGU-CS-VIL","description":"\"Revisiting DP-Means: Fast Scalable Algorithms via Parallelism and Delayed Cluster Creation\" [Dinari and Freifeld, UAI 2022]","archived":false,"fork":false,"pushed_at":"2024-07-20T21:02:24.000Z","size":567,"stargazers_count":17,"open_issues_count":1,"forks_count":4,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-24T10:38:51.405Z","etag":null,"topics":["clustering","dpmeans","kmeans","machine-learning","minibatch","scikit-learn"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/BGU-CS-VIL.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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":"2022-06-16T10:30:19.000Z","updated_at":"2024-10-14T13:01:37.000Z","dependencies_parsed_at":"2023-01-21T22:15:45.534Z","dependency_job_id":"71a8d1a6-ed2d-43f9-8c9b-79fdb6da9df9","html_url":"https://github.com/BGU-CS-VIL/pdc-dp-means","commit_stats":{"total_commits":98,"total_committers":2,"mean_commits":49.0,"dds":"0.10204081632653061","last_synced_commit":"3899526f85c21584f30fc206ad7a6c224b498bc4"},"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BGU-CS-VIL%2Fpdc-dp-means","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BGU-CS-VIL%2Fpdc-dp-means/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BGU-CS-VIL%2Fpdc-dp-means/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BGU-CS-VIL%2Fpdc-dp-means/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/BGU-CS-VIL","download_url":"https://codeload.github.com/BGU-CS-VIL/pdc-dp-means/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248215192,"owners_count":21066619,"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","dpmeans","kmeans","machine-learning","minibatch","scikit-learn"],"created_at":"2024-09-25T00:09:54.212Z","updated_at":"2025-04-10T11:50:23.475Z","avatar_url":"https://github.com/BGU-CS-VIL.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Parallel Delayed Cluster DP-Means\n\n[Paper](https://openreview.net/pdf?id=rnzVBD8jqlq) \u003cbr\u003e\n\n### Introduction\nThe PDC-DP-Means package presents a highly optimized version of the DP-Means algorithm, introducing a new parallel algorithm, Parallel Delayed Cluster DP-Means (PDC-DP-Means), and a MiniBatch implementation for enhanced speed. These features cater to scalable and efficient cluster analysis where the number of clusters is unknown.\n\nIn addition to offering major speed improvements, the PDC-DP-Means algorithm supports an optional online mode for real-time data processing. Its scikit-learn-like interface is user-friendly and designed for easy integration into existing data workflows. PDC-DP-Means outperforms other nonparametric methods, establishing its efficiency and scalability in the realm of clustering algorithms.\n\nSee the paper for more details.\n\n\n### Installation\n`pip install pdc-dp-means`\n\n### Quick Start\n\n    from sklearn.datasets import make_blobs\n    from pdc_dp_means import DPMeans\n\n    # Generate sample data\n    X, y_true = make_blobs(n_samples=300, centers=4, cluster_std=0.60, random_state=0)\n\n    # Apply DPMeans clustering\n    dpmeans = DPMeans(n_clusters=1,n_init=10, delta=10)  # n_init and delta parameters\n    dpmeans.fit(X)\n\n    # Predict the cluster for each data point\n    y_dpmeans = dpmeans.predict(X)\n\n    # Plotting clusters and centroids\n    import matplotlib.pyplot as plt\n\n    plt.scatter(X[:, 0], X[:, 1], c=y_dpmeans, s=50, cmap='viridis')\n    centers = dpmeans.cluster_centers_\n    plt.scatter(centers[:, 0], centers[:, 1], c='black', s=200, alpha=0.5)\n    plt.show()\n\nOne thing to note is that we replace the `\\lambda` parameter from the paper with `delta` in the code, as `lambda` is a reserved word in python.\n\n### Usage\nPlease refer to the documentation: https://pdc-dp-means.readthedocs.io/en/latest/\n\n### Paper Code\nPlease refer to https://github.com/BGU-CS-VIL/pdc-dp-means/tree/main/paper_code for the code used in the paper.\n\n### Citing this work\nIf you use this code for your work, please cite the following:\n\n```\n@inproceedings{dinari2022revisiting,\n  title={Revisiting {DP}-Means: Fast Scalable Algorithms via Parallelism and Delayed Cluster Creation},\n  author={Dinari, Or and Freifeld, Oren},\n  booktitle={The 38th Conference on Uncertainty in Artificial Intelligence},\n  year={2022}\n}\n```\n### License \nOur code is licensed under the BDS-3-Clause license.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbgu-cs-vil%2Fpdc-dp-means","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbgu-cs-vil%2Fpdc-dp-means","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbgu-cs-vil%2Fpdc-dp-means/lists"}