Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: HRNet/HRNet-Semantic-Segmentation
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: HRNet-OCR
Choose a base ref
...
head repository: yannqi/HRNet-Semantic-Segmentation
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: HRNet-OCR
Choose a head ref
Checking mergeability… Don’t worry, you can still create the pull request.
  • 1 commit
  • 1 file changed
  • 1 contributor

Commits on Nov 17, 2022

  1. Bug fix. Change softmax dim.

    In line 64, Change the softmax dim from 2 to 1.  
    According to this line,
    `probs = F.softmax(self.scale * probs, dim=2)# batch x k x hw`
    In this code, the input dimension is [batch_size, num_class, fh\*fw].
    And the softmax dimension is 2, which means that the summation of the dimensions of the feature map (fh\*fw) is one.
    
    However, in my opinion, I thinke the softmax dimension should be 1 to make the summation of the dimension of the num_class (num_class) is one.
    
    The corrected code is as follows:
    `probs = F.softmax(self.scale * probs, dim=1)# batch x num_class x hw`
    yannqi authored Nov 17, 2022
    Configuration menu
    Copy the full SHA
    a2c7f79 View commit details
    Browse the repository at this point in the history
Loading