Skip to content
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

Update ddrnet.py #3635

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 2 additions & 1 deletion mmseg/models/backbones/ddrnet.py
Expand Up @@ -7,6 +7,7 @@
from mmseg.registry import MODELS
from mmseg.utils import OptConfigType

import math

@MODELS.register_module()
class DDRNet(BaseModule):
Expand Down Expand Up @@ -180,7 +181,7 @@ def _make_layer(self, block, inplanes, planes, num_blocks, stride=1):

def forward(self, x):
"""Forward function."""
out_size = (x.shape[-2] // 8, x.shape[-1] // 8)
out_size = (math.ceil(x.shape[-2] // 8), math.ceil(x.shape[-1] // 8))

# stage 0-2
x = self.stem(x)
Expand Down