{"id":20886461,"url":"https://github.com/gsurma/histopathologic_cancer_detector","last_synced_at":"2025-10-13T10:13:31.915Z","repository":{"id":90787589,"uuid":"159005782","full_name":"gsurma/histopathologic_cancer_detector","owner":"gsurma","description":"CNN histopathologic tumor identifier.","archived":false,"fork":false,"pushed_at":"2021-07-09T08:54:55.000Z","size":2054,"stargazers_count":27,"open_issues_count":0,"forks_count":18,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-05-12T19:49:48.517Z","etag":null,"topics":["artificial-intelligence","cancer","cancer-detection","cnn","cnn-keras","convolutional-neural-networks","jupyter-notebook","kaggle","kaggle-competition","machine-learning","network-in-network","neural-network","python","transfer-learning"],"latest_commit_sha":null,"homepage":"https://gsurma.github.io","language":"Jupyter Notebook","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/gsurma.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","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},"funding":{"patreon":"gsurma"}},"created_at":"2018-11-25T06:48:33.000Z","updated_at":"2022-12-04T16:23:40.000Z","dependencies_parsed_at":null,"dependency_job_id":"fd408e7f-f18a-465c-b446-8f7f03b5f490","html_url":"https://github.com/gsurma/histopathologic_cancer_detector","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/gsurma/histopathologic_cancer_detector","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gsurma%2Fhistopathologic_cancer_detector","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gsurma%2Fhistopathologic_cancer_detector/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gsurma%2Fhistopathologic_cancer_detector/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gsurma%2Fhistopathologic_cancer_detector/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gsurma","download_url":"https://codeload.github.com/gsurma/histopathologic_cancer_detector/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gsurma%2Fhistopathologic_cancer_detector/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279014675,"owners_count":26085554,"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","status":"online","status_checked_at":"2025-10-13T02:00:06.723Z","response_time":61,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["artificial-intelligence","cancer","cancer-detection","cnn","cnn-keras","convolutional-neural-networks","jupyter-notebook","kaggle","kaggle-competition","machine-learning","network-in-network","neural-network","python","transfer-learning"],"created_at":"2024-11-18T08:17:03.615Z","updated_at":"2025-10-13T10:13:31.911Z","avatar_url":"https://github.com/gsurma.png","language":"Jupyter Notebook","funding_links":["https://patreon.com/gsurma"],"categories":[],"sub_categories":[],"readme":"\u003ch3 align=\"center\"\u003e\n  \u003cimg src=\"assets/histopathologic_cancer_detector_icon_web.png\" width=\"300\"\u003e\n\u003c/h3\u003e\n\n\n# Histopathologic Cancer Detector\n\nPython Jupyter Notebook leveraging **Transfer Learning**  and **Convolutional Neural Networks** implemented with **Keras**. \n\nPart of the [Kaggle competition](https://www.kaggle.com/c/histopathologic-cancer-detection). \n\nSubmitted [Kernel](https://www.kaggle.com/greg115/histopathologic-cancer-detector-lb-0-958) with 0.958 LB score.\n\nCheck out corresponding Medium article:\n\n[Histopathologic Cancer Detector - Machine Learning in Medicine](https://towardsdatascience.com/histopathologic-cancer-detector-finding-cancer-cells-with-machine-learning-b77ce1ee9b0a)\n\n\n## Data\n\n**Dataset:** [Link](https://www.kaggle.com/c/histopathologic-cancer-detection/data)\n\n**Description:** Binary classification whether a given histopathologic image contains a tumor or not.\n\n**Training:** 153k (0.9) images\n\n**Validation:** 17k (0.1) images\n\n**Testing:** 57.5k images\n\n\n## Model\n\u003ch3\u003e\n  \u003cimg src=\"assets/model_plot.png\" width=\"500\"\u003e\n\u003c/h3\u003e\n\n\t__________________________________________________________________________________________________\n\tLayer (type)                    Output Shape         Param #     Connected to                     \n\t==================================================================================================\n\tinput_1 (InputLayer)            (None, 96, 96, 3)    0                                            \n\t__________________________________________________________________________________________________\n\txception (Model)                (None, 3, 3, 2048)   20861480    input_1[0][0]                    \n\t__________________________________________________________________________________________________\n\tNASNet (Model)                  (None, 3, 3, 1056)   4269716     input_1[0][0]                    \n\t__________________________________________________________________________________________________\n\tglobal_average_pooling2d_1 (Glo (None, 2048)         0           xception[1][0]                   \n\t__________________________________________________________________________________________________\n\tglobal_average_pooling2d_2 (Glo (None, 1056)         0           NASNet[1][0]                     \n\t__________________________________________________________________________________________________\n\tconcatenate_5 (Concatenate)     (None, 3104)         0           global_average_pooling2d_1[0][0] \n\t                                                                 global_average_pooling2d_2[0][0] \n\t__________________________________________________________________________________________________\n\tdropout_1 (Dropout)             (None, 3104)         0           concatenate_5[0][0]              \n\t__________________________________________________________________________________________________\n\tdense_1 (Dense)                 (None, 1)            3105        dropout_1[0][0]                  \n\t==================================================================================================\n\tTotal params: 25,134,301\n\tTrainable params: 25,043,035\n\tNon-trainable params: 91,266\n\t__________________________________________________________________________________________________\n\n\n## Training\n\n\u003ch3\u003e\n  \u003cimg src=\"assets/training.png\" width=\"500\"\u003e\n\u003c/h3\u003e\n\n\u003ch3\u003e\n  \u003cimg src=\"assets/validation.png\" width=\"500\"\u003e\n\u003c/h3\u003e\n\n\u003ch3\u003e\n  \u003cimg src=\"assets/roc.png\" width=\"500\"\u003e\n\u003c/h3\u003e\n\n## Results\n\nKaggle score: **0.958**\n\n\n## Author\n\n**Greg (Grzegorz) Surma**\n\n[**PORTFOLIO**](https://gsurma.github.io)\n\n[**GITHUB**](https://github.com/gsurma)\n\n[**BLOG**](https://medium.com/@gsurma)\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgsurma%2Fhistopathologic_cancer_detector","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgsurma%2Fhistopathologic_cancer_detector","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgsurma%2Fhistopathologic_cancer_detector/lists"}