code: def print_distribution_labels(y):
      """
      helper function for printing the distribution of class labels in a dataset
      :param y: tensor of class labels given as one-hots
      :return: a dictionary of counts for each label from y
      """
      counts = {j: 0 for j in range(10)}
      for i in range(y.size()[0]):
          for j in range(10):
              if y[i][j] == 1:
                  counts[j] += 1
                  break
      print(counts)
  
file_path: pyro/examples/vae/utils/mnist_cached.py
imports: import errno
  import os
  from functools import reduce
  import numpy
  import torch
  from torch.utils.data import DataLoader
  from pyro.contrib.examples.util import MNIST, get_data_directory
label_desc: Use image node_id 5 for calling a global function with example usage: print_distribution_labels(y) without return types