code: def _get_transpose_conv_dilated_padding(
      filter_dim, stride, dilation, padding
  ):
      """Zero-padding for inputs dilated by strides."""
      tot_filter_dim = filter_dim + (filter_dim - 1) * (dilation - 1)
      if padding == "VALID":
          tot_pad = (
              tot_filter_dim
              + stride
              - 2
              + ps.maximum(tot_filter_dim - stride, 0)
          )
      elif padding == "SAME":
          tot_pad = tot_filter_dim + stride - 2
      return ps.cond(
          filter_dim >= stride,
          lambda: (tot_pad - tot_pad // 2 - stride + 1, tot_pad // 2),
          lambda: (filter_dim - stride, tot_pad - filter_dim + 1),
      )
  
imports: import tensorflow.compat.v2
  from tensorflow_probability.python.experimental.nn.util import utils
  from tensorflow_probability.python.internal import assert_util
  from tensorflow_probability.python.internal import dtype_util
  from tensorflow_probability.python.internal import prefer_static
label_desc: Use image node_id 11 for calling a global function with example usage: _get_transpose_conv_dilated_padding(filter_dim, stride, dilation, padding) and returns: ps