human
I wrote the below code

    features = tf.parse_example(serialized, features={'encode': tf.VarLenFeature(dtype=tf.int64), 'decode_pre': tf.VarLenFeature(dtype=tf.int64), 'decode_post': tf.VarLenFeature(dtype=tf.int64)})
    def _sparse_to_batch(sparse):
        ids = tf.sparse_tensor_to_dense(sparse)
        mask = tf.sparse_to_dense(sparse.indices, sparse.dense_shape, tf.ones_like(sparse.values, dtype=tf.int32))
        return SentenceBatch(ids=ids, mask=mask)
    output_names = ('encode', 'decode_pre', 'decode_post')
    return tuple((_sparse_to_batch(features[x]) for x in output_names))

What's a good function header?

=====
Here's a good function header?
assistant
#Here's a good function header.

def parse_example_batch(serialized):