[D] How to make padding to max sequence lengths in batch with dataset api?
So i want to pad shorter sequences to max lengths in generated batch so that all sequences are the same length and i can pass it to model.
I find this https://www.tensorflow.org/api_docs/python/tf/data/experimental/bucket_by_sequence_length
But can’t find example of use.
Or maybe i need some another function.
submitted by /u/hadaev
[link] [comments]