code: def test_onehot_encoding_shape(self, num_classes: int, shape: tuple):
      labels = [1, 0, 2]
      to_onehot = ToOneHotEncoding(num_classes=num_classes)
      output = to_onehot(labels)
      assert output.shape == shape
  
file_path: pykale/tests/prepdata/test_tabular_transform.py
imports: import logging
  import numpy
  import pandas
  import pytest
  import torch
  from kale.prepdata.tabular_transform import apply_confidence_inversion, generate_struct_for_qbin, ToOneHotEncoding, ToTensor
  from kale.utils.seed import set_seed
label_desc: Use image node_id 2 for calling the TestToOneHotEncoding obj's underlying member method code with example usage: obj.test_onehot_encoding_shape(num_classes, shape) without return types