Skip to content

Commit

Permalink
fix fx tracer to support alpha in RepVGGBlock
Browse files Browse the repository at this point in the history
  • Loading branch information
twmht committed Aug 29, 2023
1 parent 106bec4 commit 3c61e21
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion mmyolo/models/layers/yolo_bricks.py
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,7 @@ def __init__(self,
else:
self.se = nn.Identity()

self.use_alpha=use_alpha
if use_alpha:
alpha = torch.ones([
1,
Expand Down Expand Up @@ -246,7 +247,7 @@ def forward(self, inputs: Tensor) -> Tensor:
id_out = 0
else:
id_out = self.rbr_identity(inputs)
if self.alpha:
if self.use_alpha:
return self.nonlinearity(
self.se(
self.rbr_dense(inputs) +
Expand Down

0 comments on commit 3c61e21

Please sign in to comment.