TrainingExtensions/torch/src/python/aimet_torch/meta/connectedgraph.py
def _generate_module_lookup_table(self, model: torch.nn.Module):
        """
        Generates a look up dictionary for getting modules from their names.
        :param model: Pytorch model
        """
        for name, module in model.named_modules(prefix=self._model_name):
            self._name_to_module[name] = module
            self._module_to_name[module] = name

        Generates a look up dictionary for getting modules from their names.
        :param model: Pytorch model
        
Generates a look up dictionary for getting modules from their names.
Generates a look up dictionary for getting modules from their names .
def _generate_module_lookup_table(self, model: torch.nn.Module):
        for name, module in model.named_modules(prefix=self._model_name):
            self._name_to_module[name] = module
            self._module_to_name[module] = name
def _generate_module_lookup_table ( self , model : torch . nn . Module ) : for name , module in model . named_modules ( prefix = self . _model_name ) : self . _name_to_module [ name ] = module self . _module_to_name [ module ] = name
Generates a look up dictionary for getting modules from their names.
Generates a look up dictionary for getting modules from their names .
"""
        Generates a look up dictionary for getting modules from their names.
        :param model: Pytorch model
        """
self
model
torch.nn.Module
None