-
Notifications
You must be signed in to change notification settings - Fork 79
730 retinal oct rpd segmentation #748
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: dev
Are you sure you want to change the base?
730 retinal oct rpd segmentation #748
Conversation
…files.yaml. Fixed case-sensitivity for .png/.PNG in dataset/data.py. Made confidence threshold an external argument.
… instructions in readme.
@yiheng-wang-nv here is my draft PR |
@@ -0,0 +1,3 @@ | |||
# ensure that using evironment with python==3.9 | |||
pip install -r ./docs/requirements.txt #includes monai | |||
python -m pip install 'git+https://github.com/facebookresearch/detectron2.git' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @ybagdasa , could you fix the commit for the detectron2
installation?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@yiheng-wang-nv Thanks for considering the contribution. For the detectron2 installation, what is the command I should run to replicate the error you're getting? I know that the install works for python<3.10. Could this be the source of the issue for the ci install checks?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @ybagdasa ,
For the comment of this line (python -m pip install 'git+https://github.com/facebookresearch/detectron2.git'
),
based on https://github.com/Project-MONAI/model-zoo/pull/748/files#diff-6d26dc7c0d9fa894d66c944bd9d0a7c970f95371163c70631b8d6b0ed790fc81R19 detectron2 0.6
is used, thus here we can modify the install command into:
python -m pip install 'git+https://github.com/facebookresearch/detectron2.git@v0.6'
Otherwise, the command will install the latest commit, which may have incompatible issues in the future.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For the python version, can you confirm if python 3.9 is necessary?
I'm not 100% sure, but based on https://detectron2.readthedocs.io/en/latest/tutorials/install.html#requirements , it only requires to use python >= 3.7.
Currently, our repo uses python 3.10 in default for CI tests. If we do need python 3.9 for this bundle, I may consider some changes in the CI to support multiple python versions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For the CI error: https://github.com/Project-MONAI/model-zoo/actions/runs/14742610327/job/42137993317?pr=748#step:7:510 Let me push a commit to your branch to fix it. Since detectron2 cannot simply be installed via pip install detectron2
, we should consider some changes in:
https://github.com/Project-MONAI/model-zoo/blob/dev/ci/get_bundle_requirements.py#L54
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since I don't have the permission to push to your forked repo directly, I pushed the changes into: https://github.com/Project-MONAI/model-zoo/tree/730-retinalOCT_RPD_segmentation, could you help to merge it?
The branch also fixed the pre-commit ci errors.
Then we can see if there are other issues in the dependencies.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For the python version, can you confirm if python 3.9 is necessary? I'm not 100% sure, but based on https://detectron2.readthedocs.io/en/latest/tutorials/install.html#requirements , it only requires to use python >= 3.7.
Currently, our repo uses python 3.10 in default for CI tests. If we do need python 3.9 for this bundle, I may consider some changes in the CI to support multiple python versions.
My attempts to build the detectron2 wheel failed with python 3.10 and it unfortunately seems to be a common issue with their repo: facebookresearch/detectron2#5445
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, let me enable py3.9 in the CI
Hi @ybagdasa , thanks for the PR contribution. For |
Format test can be fixed according to: https://github.com/Project-MONAI/model-zoo/actions/runs/14742610314/job/42137993243?pr=748#step:7:67 |
I will look at this PR later this week |
@yiheng-wang-nv When running flake8 on the code it flags a lot of mixed-case naming conventions (N800 flags). A lot of the naming comes from the pycocotools api which used mixed-case naming for functions and variables. Having everything lowercase will probably hinder the readability of the code at this point. Is this a strict requirement or can I somehow skip it? |
@@ -0,0 +1,3 @@ | |||
# ensure that using evironment with python==3.9 | |||
pip install -r ./docs/requirements.txt #includes monai |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We may not need the requirements.txt file in the bundle, it's content is included in the metadata.json
.
Our CI can generate the requirements file directly via: https://github.com/Project-MONAI/model-zoo/blob/dev/ci/get_bundle_requirements.py#L54
Signed-off-by: Yiheng Wang <vennw@nvidia.com>
Hi @ybagdasa , sorry I cannot see the error you mentioned, the error I saw is from |
…dical-ml/monai-model-zoo into 730-retinalOCT_RPD_segmentation
@yiheng-wang-nv |
Signed-off-by: Yiheng Wang <vennw@nvidia.com>
Hi @ybagdasa , thanks for the updates and providing me the permissions. I pushed a commit to fix the black and pre-commit issues. Now, our CI can reach to the flake8 errors: https://github.com/Project-MONAI/model-zoo/actions/runs/15105923819/job/42454628204?pr=748 I think we can skip N802, N803 and N806 errors, but others may need to be solved |
Signed-off-by: Yiheng Wang <vennw@nvidia.com>
Hi @ybagdasa , I updated, and could you help to resolve other issues? Like line too long (https://github.com/Project-MONAI/model-zoo/actions/runs/15106735909/job/42456940644?pr=748) |
@yiheng-wang-nv I was able to do ./runtests.sh up through pytype. The error popped up here: |
Fixes # .
Description
This is a proposed segmentation model to add to the model zoo.
Status
Ready for review/work in progress.
Please ensure all the checkboxes:
./runtests.sh --codeformat
.version
andchangelog
inmetadata.json
if changing an existing bundle.CONTRIBUTING.md
).monai
,pytorch
andnumpy
are correct inmetadata.json
.eval_metrics
of the provided weights and TorchScript modules.large_file.yml
./home/your_name/
for"bundle_root"
).