weecology / weecology/DeepForest
Allow users to modify input size
Open
Nobody has claimed this yet.
Ideas for Machine Learning!
- Dominant language
- Python
- Stars
- 774
- Forks
- 265
- PR merge metrics
- No merged PRs in 30d
Description
def create_model(num_classes, nms_thresh, score_thresh, backbone = None):
"""Create a retinanet model
Args:
num_classes (int): number of classes in the model
nms_thresh (float): non-max suppression threshold for intersection-over-union [0,1]
score_thresh (float): minimum prediction score to keep during prediction [0,1]
Returns:
model: a pytorch nn module
"""
if not backbone:
resnet = load_backbone()
backbone = resnet.backbone
model = RetinaNet(backbone=backbone, num_classes=num_classes)
model.nms_thresh = nms_thresh
model.score_thresh = score_thresh
# Optionally allow anchor generator parameters to be created here
# https://pytorch.org/vision/stable/_modules/torchvision/models/detection/retinanet.html
return model
This is poorly documented in torchvision,
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the create_model entry point shown in the issue, then read torchvision's detection/transform.py at the linked location to understand how input dimensions are handled. Define how callers should provide the input size and verify that the resulting RetinaNet model accepts it; the issue does not identify tests or a repository file to update.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python, pytorch
- Domain
- machine-learning
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100