code: def validate_type(obj, expected_type, object_label=None):
      if not isinstance(obj, expected_type):
          type_error(expected_type, type(obj), object_label)
  
file_path: snips-nlu/snips_nlu/common/dataset_utils.py
imports: from snips_nlu.constants import INTENTS, UTTERANCES, DATA, SLOT_NAME, ENTITY
  from snips_nlu.exceptions import DatasetFormatError
label_desc: Use image node_id 2 for calling a global function with example usage: validate_type(obj, expected_type, object_label) without return types