code: def one_hot(x, K):
      return np.array(x[:, None] == np.arange(K)[None, :], dtype=int)
  
imports: import os
  import argparse
  import logging
  import time
  import numpy
  import torch
  import torch.nn
  from torch.utils.data import DataLoader
  import torchvision.datasets
  import torchvision.transforms
label_desc: Use image node_id 7 for calling a global function with example usage: one_hot(x, K) and returns: np