parameters: (op)
return_statement: return [tensor_shape.vector(batch_size), inputs_shape]
docstring: Shape function for the CTCLoss op.
docstring_summary: Shape function for the CTCLoss op.
docstring_tokens: Shape function for the CTCLoss op .
function: def _CTCLossShape(op):
    """Shape function for the CTCLoss op."""
    # inputs, label_indices, label_values, sequence_length
    inputs_shape = op.inputs[0].get_shape().with_rank(3)
    sequence_length_shape = op.inputs[3].get_shape().with_rank(1)
    # merge batch_size
    sequence_length_shape[0].merge_with(inputs_shape[1])
    inputs_shape[1].merge_with(sequence_length_shape[0])
    batch_size = inputs_shape[1]
    labels_index_shape = op.inputs[1].get_shape().with_rank(2)
    labels_value_shape = op.inputs[2].get_shape().with_rank(1)
    labels_value_shape[0].merge_with(labels_index_shape[0])
    # loss, gradient
    return [tensor_shape.vector(batch_size), inputs_shape]
function_tokens: def _CTCLossShape ( op ) : # inputs, label_indices, label_values, sequence_length inputs_shape = op . inputs [ 0 ] . get_shape ( ) . with_rank ( 3 ) sequence_length_shape = op . inputs [ 3 ] . get_shape ( ) . with_rank ( 1 ) # merge batch_size sequence_length_shape [ 0 ] . merge_with ( inputs_shape [ 1 ] ) inputs_shape [ 1 ] . merge_with ( sequence_length_shape [ 0 ] ) batch_size = inputs_shape [ 1 ] labels_index_shape = op . inputs [ 1 ] . get_shape ( ) . with_rank ( 2 ) labels_value_shape = op . inputs [ 2 ] . get_shape ( ) . with_rank ( 1 ) labels_value_shape [ 0 ] . merge_with ( labels_index_shape [ 0 ] ) # loss, gradient return [ tensor_shape . vector ( batch_size ) , inputs_shape ]