code: def test_multi_label_dot_product_loss__construct_label_padding_mask(
      label_ids: List[List[int]],
      num_candidates: int,
      expected_pos_label_mask: List[List[int]],
  ):
      actual_label_mask = (
          MultiLabelDotProductLoss._construct_mask_for_label_padding(
              np.expand_dims(label_ids, -1), num_candidates
          ).numpy()
      )
  
      pos_label_columns = np.array(label_ids).shape[1]
  
      # First check if the mask corresponding to guaranteed positive label ids is correct.
      assert np.all(
          actual_label_mask[:, :pos_label_columns]
          == np.array(expected_pos_label_mask).astype(np.float32)
      )
  
      # Next check if the mask corresponding to sampled candidates is correct.
      assert np.all(
          actual_label_mask[:, pos_label_columns:]
          == np.ones((len(label_ids), num_candidates), dtype=np.float32)
      )
  
imports: from typing import Text, List, Tuple, Union, Optional
  import pytest
  from _pytest.monkeypatch import MonkeyPatch
  import numpy
  import tensorflow
  from rasa.utils.tensorflow.layers import DotProductLoss, MultiLabelDotProductLoss, RandomlyConnectedDense, DenseForSparse
  from rasa.utils.tensorflow.constants import INNER, SOFTMAX, LABEL, LABEL_PAD_ID
  import rasa.utils.tensorflow.layers_utils
  from rasa.shared.nlu.constants import TEXT, INTENT, ACTION_NAME, ACTION_TEXT, FEATURE_TYPE_SENTENCE, FEATURE_TYPE_SEQUENCE
  from rasa.core.constants import DIALOGUE
label_desc: Use image node_id 3 for calling a global function with example usage: test_multi_label_dot_product_loss__construct_label_padding_mask(label_ids, num_candidates, expected_pos_label_mask) without return types