docstr: Tests that fqn_to_module operates as inverse
  of module_to_fqn
docstr_tok: ["Tests","that","fqn_to_module","operates","as","inverse","of","module_to_fqn"]
code: def test_fqn_to_module(self):
      """
      Tests that fqn_to_module operates as inverse
      of module_to_fqn
      """
      for model_class in model_list:
          model = model_class()
          list_of_modules = [m for _, m in model.named_modules()] + [
              model
          ]
          for module in list_of_modules:
              fqn = module_to_fqn(model, module)
              check_module = fqn_to_module(model, fqn)
              self.assertEqual(module, check_module)
  
file_path: pytorch/test/ao/sparsity/test_sparsity_utils.py
imports: import logging
  import torch
  from torch.ao.pruning.sparsifier.utils import fqn_to_module, get_arg_info_from_tensor_fqn, module_to_fqn
  from torch.testing._internal.common_quantization import ConvBnReLUModel, ConvModel, FunctionalLinear, LinearAddModel, ManualEmbeddingBagLinear, SingleLayerLinearModel, TwoLayerLinearModel
  from torch.testing._internal.common_utils import TestCase
label_desc: Use image node_id 4 for calling the TestSparsityUtilFunctions obj's underlying member method code with example usage: obj.test_fqn_to_module() without return types