deeppavlov/core/layers/tf_layers.py
def expand_tile(units, axis):
    """Expand and tile tensor along given axis
    Args:
        units: tf tensor with dimensions [batch_size, time_steps, n_input_features]
        axis: axis along which expand and tile. Must be 1 or 2

    """
    assert axis in (1, 2)
    n_time_steps = tf.shape(units)[1]
    repetitions = [1, 1, 1, 1]
    repetitions[axis] = n_time_steps
    return tf.tile(tf.expand_dims(units, axis), repetitions)
def expand_tile(units, axis):
    """Expand and tile tensor along given axis
    Args:
        units: tf tensor with dimensions [batch_size, time_steps, n_input_features]
        axis: axis along which expand and tile. Must be 1 or 2

    """
    assert axis in (1, 2)
    n_time_steps = tf.shape(units)[1]
    repetitions = [1, 1, 1, 1]
    repetitions[axis] = n_time_steps
    return tf.tile(tf.expand_dims(units, axis), repetitions)
def expand_tile ( units , axis ) : assert axis in ( 1 , 2 ) n_time_steps = tf . shape ( units ) [ 1 ] repetitions = [ 1 , 1 , 1 , 1 ] repetitions [ axis ] = n_time_steps return tf . tile ( tf . expand_dims ( units , axis ) , repetitions )
Expand and tile tensor along given axis
    Args:
        units: tf tensor with dimensions [batch_size, time_steps, n_input_features]
        axis: axis along which expand and tile. Must be 1 or 2
Expand and tile tensor along given axis Args : units : tf tensor with dimensions [ batch_size time_steps n_input_features ] axis : axis along which expand and tile . Must be 1 or 2