MCPcopy Create free account
hub / github.com/UCSC-VLAA/OpenVision / func2

Function func2

src/transforms/bert_ops.py:504–504  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

502
503 def func1(): return tf.concat([padded_token_ids[:, :-1], tf.fill([count, 1], eos_token)], axis=1)
504 def func2(): return padded_token_ids
505 padded_token_ids = tf.cond(tf.equal(pad_mask[0, -1], tf.constant(1)), func1, func2)
506
507 padded_token_ids = tf.concat([padded_token_ids, tf.fill([count, 1], cls_token)], axis=1)

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected