{"id":22495219,"url":"https://github.com/osbm/monai-prostate158-inference","last_synced_at":"2025-03-27T21:16:05.347Z","repository":{"id":187288283,"uuid":"674836568","full_name":"osbm/monai-prostate158-inference","owner":"osbm","description":null,"archived":false,"fork":false,"pushed_at":"2023-08-23T16:36:38.000Z","size":9,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-01T23:38:28.509Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/osbm.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":"2023-08-04T23:17:50.000Z","updated_at":"2023-08-16T20:59:17.000Z","dependencies_parsed_at":null,"dependency_job_id":"5601d662-590c-487b-a445-7bacbc035e88","html_url":"https://github.com/osbm/monai-prostate158-inference","commit_stats":null,"previous_names":["osbm/monai-prostate158-inference"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/osbm%2Fmonai-prostate158-inference","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/osbm%2Fmonai-prostate158-inference/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/osbm%2Fmonai-prostate158-inference/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/osbm%2Fmonai-prostate158-inference/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/osbm","download_url":"https://codeload.github.com/osbm/monai-prostate158-inference/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245924507,"owners_count":20694730,"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":[],"created_at":"2024-12-06T19:26:25.172Z","updated_at":"2025-03-27T21:16:05.307Z","avatar_url":"https://github.com/osbm.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n# Steps to reproduce scores\n\n## Install requirements\n\n```\npip install -r requirements.txt\n```\n\n## Download the dataset\nDownload and unzip [this file](https://huggingface.co/datasets/osbm/prostate158/blob/main/data.zip).\n\n```python\nfrom huggingface_hub import hf_hub_download\npath = hf_hub_download(repo_id=\"osbm/prostate158\", filename=\"data.zip\", repo_type=\"dataset\")\n!unzip {path} -d .\n```\n\n## Download the model\n\nDownload the `anatomy.pt` file from this [zenodo repository](https://zenodo.org/record/6397057)\n\nYou can use my zenodo file downloader for this step:\n```python\nfrom datasets import load_dataset\nload_dataset(\"osbm/zenodo\", \"7040585_anatomy.pt\")\n```\n\n## Run the inference script\n\nIn this step, the produced masks will be saved to the `test` folder as `predicted.nii.gz` files for every case.\n\n- This step takes about 5 minutes in cpu.\n\n```\npython inference.py\n```\n\n## Run score calculator script\n\n```\npython score.py\n```\n# Results\n\nDICE scores:\n\n| Case | Background | Inner Prostate | Outer Prostate |\n| ---| ---| ---| --- |\n|1 |0.99 |  0.792 | 0.81  |\n| 2|0.993 | 0.897 | 0.703 |\n|3 |0.992 | 0.917 | 0.757 |\n| 4|0.994 | 0.838 | 0.725 |\n|5 |0.994 | 0.899 | 0.771 |\n| 6|0.995 | 0.871 | 0.77  |\n|7 |0.995 | 0.892 | 0.761 |\n| 8|0.996 | 0.87 |  0.78  |\n|9 |0.996 | 0.847 | 0.722 |\n| 10|0.988 | 0.841 | 0.693 |\n|11 |0.996 | 0.839 | 0.825 |\n| 12 |0.994 | 0.831 | 0.817 |\n| 13 |0.993 | 0.823 | 0.744 |\n| 14 |0.996 | 0.859 | 0.842 |\n| 15 |0.995 | 0.889 | 0.767 |\n| 16 |0.996 | 0.83 |  0.684 |\n| 17 |0.995 | 0.864 | 0.779 |\n| 18 |0.989 | 0.857 | 0.636 |\n| 19 |0.995 | 0.915 | 0.636 |\n| Mean | 0.99378947 | 0.86163158 | 0.74852632 |\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fosbm%2Fmonai-prostate158-inference","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fosbm%2Fmonai-prostate158-inference","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fosbm%2Fmonai-prostate158-inference/lists"}