Skip to content

Commit

Permalink
delete unused parameter init_weights.
Browse files Browse the repository at this point in the history
  • Loading branch information
chenyaofo committed Jul 1, 2021
1 parent 9751dd0 commit 266dba1
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions pytorch_cifar_models/repvgg.py
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ def forward(self, inputs):

# This func derives the equivalent kernel and bias in a DIFFERENTIABLE way.
# You can get the equivalent kernel and bias at any time and do whatever you want,
# for example, apply some penalties or constraints during training, just like you do to the other models.
# for example, apply some penalties or constraints during training, just like you do to the other models.
# May be useful for quantization or pruning.


Expand Down Expand Up @@ -220,8 +220,6 @@ def convert_to_inference_model(self, do_copy=False):
def _repvgg(arch: str, num_blocks: List[int], width_multiplier: List[float],
model_urls: Dict[str, str],
pretrained: bool = False, progress: bool = True, **kwargs: Any) -> RepVGG:
if pretrained:
kwargs['init_weights'] = False
model = RepVGG(num_blocks=num_blocks, width_multiplier=width_multiplier,
override_groups_map=None, **kwargs)
if pretrained:
Expand Down

0 comments on commit 266dba1

Please sign in to comment.