code: def _get_combination_dim(combination, tensor_dims):
      if combination.isdigit():
          index = int(combination) - 1
          return tensor_dims[index]
      else:
          if len(combination) != 3:
              raise ConfigurationError(
                  "Invalid combination: " + combination
              )
          first_tensor_dim = _get_combination_dim(
              combination[0], tensor_dims
          )
          second_tensor_dim = _get_combination_dim(
              combination[2], tensor_dims
          )
          operation = combination[1]
          if first_tensor_dim != second_tensor_dim:
              raise ConfigurationError(
                  'Tensor dims must match for operation "{}"'.format(
                      operation
                  )
              )
          return first_tensor_dim
  
imports: from __future__ import division
  from __future__ import absolute_import
  from collections import defaultdict
  import logging
  import math
  import torch
  from allennlp.common.checks import ConfigurationError
label_desc: Use image node_id 23 for calling a global function with example usage: _get_combination_dim(combination, tensor_dims) and returns: tensor_dims, first_tensor_dim