code: def test_masks(self):
      for input_dim in [1, 3, 5]:
          for observed_dim in [0, 3]:
              for num_layers in [1, 3]:
                  for output_dim_multiplier in [1, 2, 3]:
                      # NOTE: the hidden dimension must be greater than the input_dim for the
                      # masks to be well-defined!
                      hidden_dim = input_dim * 5
                      permutation = torch.randperm(
                          input_dim, device="cpu"
                      )
                      self._test_masks(
                          input_dim,
                          observed_dim,
                          [hidden_dim] * num_layers,
                          permutation,
                          output_dim_multiplier,
                      )
  
file_path: pyro/tests/nn/test_autoregressive.py
imports: from unittest import TestCase
  import pytest
  import torch
  from pyro.nn import AutoRegressiveNN, ConditionalAutoRegressiveNN
  from pyro.nn.auto_reg_nn import create_mask
label_desc: Use image node_id 5 for calling the AutoRegressiveNNTests obj's underlying member method code with example usage: obj.test_masks() without return types