Skip to content
Snippets Groups Projects
Commit 78529eca authored by Whi Kwon's avatar Whi Kwon Committed by Kai Chen
Browse files

Fix typo activatation -> activation (#2007)

parent b5d62ef9
No related branches found
No related tags found
No related merge requests found
...@@ -93,7 +93,7 @@ class ConvModule(nn.Module): ...@@ -93,7 +93,7 @@ class ConvModule(nn.Module):
assert set(order) == set(['conv', 'norm', 'act']) assert set(order) == set(['conv', 'norm', 'act'])
self.with_norm = norm_cfg is not None self.with_norm = norm_cfg is not None
self.with_activatation = activation is not None self.with_activation = activation is not None
# if the conv layer is before a norm layer, bias is unnecessary. # if the conv layer is before a norm layer, bias is unnecessary.
if bias == 'auto': if bias == 'auto':
bias = False if self.with_norm else True bias = False if self.with_norm else True
...@@ -135,7 +135,7 @@ class ConvModule(nn.Module): ...@@ -135,7 +135,7 @@ class ConvModule(nn.Module):
self.add_module(self.norm_name, norm) self.add_module(self.norm_name, norm)
# build activation layer # build activation layer
if self.with_activatation: if self.with_activation:
# TODO: introduce `act_cfg` and supports more activation layers # TODO: introduce `act_cfg` and supports more activation layers
if self.activation not in ['relu']: if self.activation not in ['relu']:
raise ValueError('{} is currently not supported.'.format( raise ValueError('{} is currently not supported.'.format(
...@@ -162,6 +162,6 @@ class ConvModule(nn.Module): ...@@ -162,6 +162,6 @@ class ConvModule(nn.Module):
x = self.conv(x) x = self.conv(x)
elif layer == 'norm' and norm and self.with_norm: elif layer == 'norm' and norm and self.with_norm:
x = self.norm(x) x = self.norm(x)
elif layer == 'act' and activate and self.with_activatation: elif layer == 'act' and activate and self.with_activation:
x = self.activate(x) x = self.activate(x)
return x return x
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment