class_docstr: MobileOne building block.
  
  This block has a multi-branched architecture at train-time
  and plain-CNN style architecture at inference time
  For more details, please refer to our paper:
  `An Improved One millisecond Mobile Backbone` -
  https://arxiv.org/pdf/2206.04040.pdf
class_docstr_tok: ["MobileOne","building","block",".","This","block","has","a","multi-branched","architecture","at","train-time","and","plain-CNN","style","architecture","at","inference","time","For","more","details",",","please","refer","to","our","paper",":","`","An","Improved","One","millisecond","Mobile","Backbone","`","-","https",":","\/\/arxiv.org\/pdf\/2206.04040.pdf"]
docstr: Following works like `RepVGG: Making VGG-style ConvNets Great Again` -
  https://arxiv.org/pdf/2101.03697.pdf. We re-parameterize multi-branched
  architecture used at training time to obtain a plain CNN-like structure
  for inference.
docstr_tok: ["Following","works","like","`","RepVGG",":","Making","VGG-style","ConvNets","Great","Again","`","-","https",":","\/\/arxiv.org\/pdf\/2101.03697.pdf",".","We","re-parameterize","multi-branched","architecture","used","at","training","time","to","obtain","a","plain","CNN-like","structure","for","inference","."]
code: def reparameterize(self):
      """Following works like `RepVGG: Making VGG-style ConvNets Great Again` -
      https://arxiv.org/pdf/2101.03697.pdf. We re-parameterize multi-branched
      architecture used at training time to obtain a plain CNN-like structure
      for inference.
      """
      if self.inference_mode:
          return
      kernel, bias = self._get_kernel_bias()
      self.reparam_conv = nn.Conv2d(
          in_channels=self.in_channels,
          out_channels=self.out_channels,
          kernel_size=self.kernel_size,
          stride=self.stride,
          padding=self.padding,
          dilation=self.dilation,
          groups=self.groups,
          bias=True,
      )
      self.reparam_conv.weight.data = kernel
      self.reparam_conv.bias.data = bias
  
      # Delete un-used branches
      for para in self.parameters():
          para.detach_()
      self.__delattr__("rbr_conv")
      self.__delattr__("rbr_scale")
      if hasattr(self, "rbr_skip"):
          self.__delattr__("rbr_skip")
  
      self.inference_mode = True
  
file_path: ml-fastvit/models/modules/mobileone.py
imports: from typing import Union, Tuple
  import copy
  import torch
  import torch.nn
  import torch.nn.functional
label_desc: Use image node_id 3 for calling the MobileOneBlock obj's underlying member method code with example usage: obj.reparameterize() without return types