class_docstr: Diet 2 Diet transformer implementation.
class_docstr_tok: ["Diet","2","Diet","transformer","implementation","."]
code: def _check_data(self) -> None:
      if TEXT not in self.data_signature:
          raise InvalidConfigException(
              f"No text features specified. "
              f"Cannot train '{self.__class__.__name__}' model."
          )
      if LABEL not in self.data_signature:
          raise InvalidConfigException(
              f"No label features specified. "
              f"Cannot train '{self.__class__.__name__}' model."
          )
      if (
          self.config[SHARE_HIDDEN_LAYERS]
          and self.data_signature[TEXT][SENTENCE]
          != self.data_signature[LABEL][SENTENCE]
      ):
          raise ValueError(
              "If hidden layer weights are shared, data signatures "
              "for text_features and label_features must coincide."
          )
  
imports: from __future__ import annotations
  import copy
  import logging
  from rasa.nlu.featurizers.featurizer import Featurizer
  import numpy
  import tensorflow
  from typing import Any, Dict, Optional, Text, Tuple, Union, List, Type
  from rasa.engine.graph import ExecutionContext
  from rasa.engine.recipes.default_recipe import DefaultV1Recipe
  from rasa.engine.storage.resource import Resource
  from rasa.engine.storage.storage import ModelStorage
  from rasa.shared.constants import DIAGNOSTIC_DATA
  from rasa.shared.nlu.training_data import util
  import rasa.shared.utils.io
  from rasa.shared.exceptions import InvalidConfigException
  from rasa.shared.nlu.training_data.training_data import TrainingData
  from rasa.shared.nlu.training_data.message import Message
  from rasa.nlu.classifiers.diet_classifier import DIET, LABEL_KEY, LABEL_SUB_KEY, SENTENCE, SEQUENCE, DIETClassifier
  from rasa.nlu.extractors.extractor import EntityTagSpec
  from rasa.utils.tensorflow import rasa_layers
  from rasa.utils.tensorflow.constants import LABEL, HIDDEN_LAYERS_SIZES, SHARE_HIDDEN_LAYERS, TRANSFORMER_SIZE, NUM_TRANSFORMER_LAYERS, NUM_HEADS, BATCH_SIZES, BATCH_STRATEGY, EPOCHS, RANDOM_SEED, LEARNING_RATE, RANKING_LENGTH, RENORMALIZE_CONFIDENCES, LOSS_TYPE, SIMILARITY_TYPE, NUM_NEG, SPARSE_INPUT_DROPOUT, DENSE_INPUT_DROPOUT, MASKED_LM, ENTITY_RECOGNITION, INTENT_CLASSIFICATION, EVAL_NUM_EXAMPLES, EVAL_NUM_EPOCHS, UNIDIRECTIONAL_ENCODER, DROP_RATE, DROP_RATE_ATTENTION, CONNECTION_DENSITY, NEGATIVE_MARGIN_SCALE, REGULARIZATION_CONSTANT, SCALE_LOSS, USE_MAX_NEG_SIM, MAX_NEG_SIM, MAX_POS_SIM, EMBEDDING_DIMENSION, BILOU_FLAG, KEY_RELATIVE_ATTENTION, VALUE_RELATIVE_ATTENTION, MAX_RELATIVE_POSITION, RETRIEVAL_INTENT, USE_TEXT_AS_LABEL, CROSS_ENTROPY, AUTO, BALANCED, TENSORBOARD_LOG_DIR, TENSORBOARD_LOG_LEVEL, CONCAT_DIMENSION, FEATURIZERS, CHECKPOINT_MODEL, DENSE_DIMENSION, CONSTRAIN_SIMILARITIES, MODEL_CONFIDENCE, SOFTMAX
  from rasa.nlu.constants import RESPONSE_SELECTOR_PROPERTY_NAME, RESPONSE_SELECTOR_RETRIEVAL_INTENTS, RESPONSE_SELECTOR_RESPONSES_KEY, RESPONSE_SELECTOR_PREDICTION_KEY, RESPONSE_SELECTOR_RANKING_KEY, RESPONSE_SELECTOR_UTTER_ACTION_KEY, RESPONSE_SELECTOR_DEFAULT_INTENT, DEFAULT_TRANSFORMER_SIZE
  from rasa.shared.nlu.constants import TEXT, INTENT, RESPONSE, INTENT_RESPONSE_KEY, INTENT_NAME_KEY, PREDICTED_CONFIDENCE_KEY
  from rasa.utils.tensorflow.model_data import RasaModelData
  from rasa.utils.tensorflow.models import RasaModel
label_desc: Use image node_id 1 for calling the DIET2DIET obj's underlying member method code with example usage: obj._check_data() without return types