zhanghang1989 / zhanghang1989/PyTorch-Encoding

About the crop size for training and testing

Open
#86 7 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
2k
Forks
448
PR merge metrics
No merged PRs in 30d

Description

class BaseNet(nn.Module):
    def __init__(self, nclass, backbone, aux, se_loss, dilated=True, norm_layer=None,
                 base_size=576, crop_size=608, mean=[.485, .456, .406],
                 std=[.229, .224, .225], root='~/.encoding/models'):

Previously, I noticed that you choose base_size=520, crop_size=480 and now you change them to base_size=576, crop_size=608.

However, I still have a concern about it, the 608 should be larger than the largest highth or width in your dataset, so we should increase this parameter if we are dealing with larger datasets.

Besides, I noticed that you mentioned that your MultiEvalModule only support single image evalution, but you also provide the batch size parameter, which is contradictory....... I guess we can only set the batch size as 1 during testing phase.

  def forward(self, image):
        """Mult-size Evaluation"""
        # only single image is supported for evaluation

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the BaseNet.init entry point and the MultiEvalModule.forward method shown in the issue. Compare the crop-size defaults with the dataset image dimensions and verify how the evaluation batch-size parameter relates to the stated single-image support. Done means the intended crop-size and evaluation batch-size behavior is resolved and documented or corrected.

Written by the indexing model from the issue text.

Assessment

Tech stack
python, pytorch
Domain
computer-vision, machine-learning
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
28/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.