code: def test_channel_dependency(self):
      outdir = os.path.join(prefix, "dependency")
      os.makedirs(outdir, exist_ok=True)
      for name in model_names:
          print("Analyze channel dependency for %s" % name)
          model = getattr(models, name)
          net = model().to(device)
          dummy_input = torch.ones(1, 3, 224, 224).to(device)
          channel_depen = ChannelDependency(net, dummy_input)
          depen_sets = channel_depen.dependency_sets
          d_set_count = 0
          for d_set in depen_sets:
              if len(d_set) > 1:
                  d_set_count += 1
                  assert d_set in channel_dependency_ground_truth[name]
          assert d_set_count == len(
              channel_dependency_ground_truth[name]
          )
          fpath = os.path.join(outdir, name)
          channel_depen.export(fpath)
  
file_path: auptimizer/tests/compression/test_compression_utils.py
imports: import os
  import unittest
  from unittest import TestCase, main
  import torch
  import torch.nn
  import torchvision.models
  import numpy
  from aup.compression.torch import L1FilterPruner
  from aup.compression.torch.utils.shape_dependency import ChannelDependency
  from aup.compression.torch.utils.mask_conflict import fix_mask_conflict
  from aup.compression.torch.utils.counter import count_flops_params
label_desc: Use image node_id 1 for calling the AnalysisUtilsTest obj's underlying member method code with example usage: obj.test_channel_dependency() without return types