{"id":27126045,"url":"https://github.com/khyatimahendru/dimensionality-reduction","last_synced_at":"2025-04-07T15:58:41.157Z","repository":{"id":263371538,"uuid":"199123177","full_name":"KhyatiMahendru/Dimensionality-Reduction","owner":"KhyatiMahendru","description":"This is an implementation of 3 dimensionality reduction techniques - PCA, SVD, and tSNE for visualization of high dimensional data in 2D and 3D.  ","archived":false,"fork":false,"pushed_at":"2020-07-14T15:06:09.000Z","size":6074,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-11-18T06:27:39.946Z","etag":null,"topics":["data-visualization","dimensionality-reduction","mnist","mnist-classification","pca","svd","tsne","tsne-algorithm"],"latest_commit_sha":null,"homepage":null,"language":"Jupyter Notebook","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/KhyatiMahendru.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":"2019-07-27T05:58:27.000Z","updated_at":"2024-08-04T12:16:31.000Z","dependencies_parsed_at":"2024-11-18T09:35:07.485Z","dependency_job_id":null,"html_url":"https://github.com/KhyatiMahendru/Dimensionality-Reduction","commit_stats":null,"previous_names":["khyatimahendru/dimensionality-reduction"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KhyatiMahendru%2FDimensionality-Reduction","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KhyatiMahendru%2FDimensionality-Reduction/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KhyatiMahendru%2FDimensionality-Reduction/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KhyatiMahendru%2FDimensionality-Reduction/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/KhyatiMahendru","download_url":"https://codeload.github.com/KhyatiMahendru/Dimensionality-Reduction/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247685625,"owners_count":20979085,"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":["data-visualization","dimensionality-reduction","mnist","mnist-classification","pca","svd","tsne","tsne-algorithm"],"created_at":"2025-04-07T15:58:40.582Z","updated_at":"2025-04-07T15:58:41.146Z","avatar_url":"https://github.com/KhyatiMahendru.png","language":"Jupyter Notebook","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Dimensionality-Reduction\nThis is an implementation of 3 dimensionality reduction techniques - PCA, SVD, and tSNE for visualization of high dimensional data in 2D and 3D.  \n\nIn this notebook, I have used 3 methods of Dimensionality Reduction:\n\n- Principal Component Analysis\n- Singular Value Decomposition\n- t-distributed Stochastic Neighbor Embedding\n\nI have used these techniques on two datasets:\n\n- The Digits Dataset from sklearn\n- MNIST Dataset - The \"Hello World\" of Computer Vision\n\nt-SNE is an O(n^2) algorithm and the MNIST dataset was too large for it. I randomly sampled 10000 images from MNIST for visualization both in 2D and 3D.\n\n## Performance Table\n| Algorithm         | Digits Dataset         | MNIST Dataset (10000 images)  |\n| ------------- |:--------------|:-----|\n| PCA - 2 Components | 21.7 ms | 428 ms |\n| SVD - 2 Components | 30.2 ms | 392 ms |\n| tSNE - 2 Components | 10.4 s | 4 min 8 s |\n| PCA - 3 Components | 29.9 ms | 457 ms |\n| SVD - 3 Components | 26.8 ms | 336 ms |\n| tSNE - 3 Components | 43.4 s | 12 min 35 s |\n\n\n# Visualizations\n\n## The Digits Dataset\n\n### In 2 Dimensions\n![Digits-PCA-2-Components](https://github.com/KhyatiMahendru/Dimensionality-Reduction/blob/master/Visualizations/digits-pca-2.png)\n![Digits-SVD-2-Components](https://github.com/KhyatiMahendru/Dimensionality-Reduction/blob/master/Visualizations/digits-svd-2.png)\n![Digits-TSNE-2-Components](https://github.com/KhyatiMahendru/Dimensionality-Reduction/blob/master/Visualizations/digits-tsne-2.png)\n\n### In 3 Dimensions\n![Digits-PCA-3-Components](https://github.com/KhyatiMahendru/Dimensionality-Reduction/blob/master/Visualizations/digits-pca-3.png)\n![Digits-SVD-3-Components](https://github.com/KhyatiMahendru/Dimensionality-Reduction/blob/master/Visualizations/digits-svd-3.png)\n![Digits-TSNE-3-Components](https://github.com/KhyatiMahendru/Dimensionality-Reduction/blob/master/Visualizations/digits-tsne-3.png)\n\n\n## The MNIST Dataset (10000 images)\n\n### In 2 Dimensions\n![MNIST-PCA-2-Components](https://github.com/KhyatiMahendru/Dimensionality-Reduction/blob/master/Visualizations/mnist-pca-2.png)\n![MNIST-SVD-2-Components](https://github.com/KhyatiMahendru/Dimensionality-Reduction/blob/master/Visualizations/mnist-svd-2.png)\n![MNIST-TSNE-2-Components](https://github.com/KhyatiMahendru/Dimensionality-Reduction/blob/master/Visualizations/mnist-tsne-2.png)\n\n### In 3 Dimensions\n![MNIST-PCA-3-Components](https://github.com/KhyatiMahendru/Dimensionality-Reduction/blob/master/Visualizations/mnist-pca-3.png)\n![MNIST-SVD-3-Components](https://github.com/KhyatiMahendru/Dimensionality-Reduction/blob/master/Visualizations/mnist-svd-3.png)\n![MNIST-TSNE-3-Components](https://github.com/KhyatiMahendru/Dimensionality-Reduction/blob/master/Visualizations/mnist-tsne-3.png)\n\n# Conclusion\nAlthough tSNE was slow, it lead to the most impressive and clearly clustered visualizations in both 2D and 3D.\nTo reduce the time for tSNE, PCA or SVD may be used as a primary step.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkhyatimahendru%2Fdimensionality-reduction","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkhyatimahendru%2Fdimensionality-reduction","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkhyatimahendru%2Fdimensionality-reduction/lists"}