nnsvs.train_util.collate_fn_random_segments
- nnsvs.train_util.collate_fn_random_segments(batch, max_time_frames=256)[source]
Collate function with random segments
Use segmented frames instead of padded entire frames. No padding is performed.
Warning
max_time_frames must be larger than the shortest sequence in the training data.
- Parameters:
- Returns:
- Tuple of batch
x (FloatTensor) : Network inputs (B, max(T), D_in)
y (FloatTensor) : Network targets (B, max(T), D_out)
lengths (LongTensor): Input lengths
- Return type: