code: def set_data(self, test_data):
      self.inputs = Attributes()
  
      with lzma.open(test_data, "rb") as fid:
          solution_book = pickle.load(fid)
      self.test_book = solution_book["tests"]
  
      if any(
          [
              file not in os.listdir(self.image_data_dir)
              for file in solution_book["inputs"]["images"].keys()
          ]
      ):
          raise FileNotFoundError("Cannot find {} in {}.").format(
              ", ".join(
                  [
                      file
                      for file in solution_book["inputs"][
                          "images"
                      ].keys()
                      if file not in os.listdir(self.image_data_dir)
                  ],
                  self.image_data_dir,
              )
          )
      images = {
          os.path.splitext(file)[0]: {
              key: np.asarray(
                  PIL.Image.open(
                      os.path.join(self.image_data_dir, file)
                  ).crop(crop_box)
              )[:, :, ::-1]
              for (key, crop_box) in page.items()
          }
          for (file, page) in solution_book["inputs"]["images"].items()
      }
  
      (
          english_mini_bgr,
          english_mini_gray,
      ) = self.easyocr.utils.reformat_input(images["english"]["mini"])
      (
          english_small_bgr,
          english_small_gray,
      ) = self.easyocr.utils.reformat_input(images["english"]["small"])
      images["english"].update(
          {
              "mini_bgr": english_mini_bgr,
              "mini_gray": english_mini_gray,
              "small_bgr": english_small_bgr,
              "small_gray": english_small_gray,
          }
      )
  
      setattr(self.inputs, "images", self.dict2attr(images))
      setattr(
          self.inputs,
          "easyocr_config",
          self.dict2attr(solution_book["inputs"]["easyocr_config"]),
      )
  
imports: import os
  import sys
  import importlib
  import pickle
  import lzma
  import PIL.Image
  import numpy
  import torch
label_desc: Use image node_id 2 for calling the UnitTest obj's underlying member method code with example usage: obj.set_data(test_data) without return types