{"id":20665392,"url":"https://github.com/rohit1901/py-cluster","last_synced_at":"2026-05-05T15:40:17.137Z","repository":{"id":195336270,"uuid":"692059466","full_name":"rohit1901/py-cluster","owner":"rohit1901","description":"Classifier and Cluster Analysis in Data Science","archived":false,"fork":false,"pushed_at":"2023-09-17T11:56:37.000Z","size":126,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-17T12:55:26.884Z","etag":null,"topics":["classification","clustering","data-science","k-means-clustering","machine-learning","pytest","python","python3","ruff","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":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/rohit1901.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}},"created_at":"2023-09-15T13:21:58.000Z","updated_at":"2023-09-17T11:58:04.000Z","dependencies_parsed_at":"2023-09-17T15:01:45.273Z","dependency_job_id":null,"html_url":"https://github.com/rohit1901/py-cluster","commit_stats":null,"previous_names":["rohit1901/py-cluster"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rohit1901%2Fpy-cluster","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rohit1901%2Fpy-cluster/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rohit1901%2Fpy-cluster/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rohit1901%2Fpy-cluster/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rohit1901","download_url":"https://codeload.github.com/rohit1901/py-cluster/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":242832769,"owners_count":20192621,"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":["classification","clustering","data-science","k-means-clustering","machine-learning","pytest","python","python3","ruff","scikit-learn"],"created_at":"2024-11-16T19:30:40.292Z","updated_at":"2026-05-05T15:40:17.096Z","avatar_url":"https://github.com/rohit1901.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# K-Means Clustering Application\n![Python](https://img.shields.io/badge/python-3670A0?style=for-the-badge\u0026logo=python\u0026logoColor=ffdd54)\n\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)\n![Rohit](https://github.com/rohit1901/py-cluster/actions/workflows/test.yml/badge.svg)\nThis Python application demonstrates K-Means clustering on various datasets and provides a modularized structure for loading data and performing clustering. The code is organized into two modules: `data_loader` and `clustering`.\n\n## Getting Started\n\nThese instructions will help you set up and run the project on your local machine.\n\n### Prerequisites\n\n- Python 3.x\n- NumPy\n- scikit-learn\n- seaborn\n- matplotlib\n- ruff\n- pytest\n\nYou can install the required dependencies using pip:\n\n```\npip install numpy scikit-learn seaborn matplotlib ruff pytest\n```\n\n### Installation\n\n1. Clone the repository:\n\n```\ngit clone https://github.com/rohit1901/py-cluster.git\ncd py-cluster\n```\n\n2. Run the main script:\n\n```\npython main_1.py\npython main_2.py\n```\n\n## Code Structure\n\n- `data_utils` module: Responsible for loading data and extracting dimensions and samples.\n- `clustering` module: Implements K-Means clustering and related functions.\n- `classify_unknown_samples` module: Implements a function to classify unknown samples using a trained model.\n- `main_1` script: Demonstrates classification of unknown samples using nearest neighbour classification.\n- `main_2` script: Demonstrates K-Means clustering on various datasets.\n\n## Testing\n\nTo run unit tests for the application, use the following commands:\n\n```\npytest\n```\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n\n## Acknowledgments\n\n- This project was inspired by the need to understand K-Means clustering and its implementation in Python.\n- Thanks to the contributors and open-source libraries that made this project possible.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frohit1901%2Fpy-cluster","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frohit1901%2Fpy-cluster","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frohit1901%2Fpy-cluster/lists"}