@@ -65,7 +65,7 @@ def test_pee_grouped_and_serial_thd_fusion_match():
6565 lengths = torch .tensor ([40 , 17 ])
6666 targets = torch .zeros (2 , 5 , _N_SPK )
6767 with torch .no_grad ():
68- serial = encoder .forward_sequence_packed (mels , lengths , spk_targets = targets , grouped = False )
68+ serial = encoder ._forward_sequence_packed (mels , lengths , spk_targets = targets , grouped = False )
6969 grouped = encoder .forward_sequence_packed (mels , lengths , spk_targets = targets )
7070 assert torch .equal (grouped .lengths , serial .lengths )
7171 assert torch .equal (grouped .cu_seqlens , serial .cu_seqlens )
@@ -240,7 +240,7 @@ def test_grouped_sequence_packed_preserves_independent_ffn_dropout_sites():
240240
241241
242242@pytest .mark .unit
243- def test_grouped_sequence_packed_non_strict_buckets_mixed_attention_features ():
243+ def test_grouped_sequence_packed_buckets_mixed_attention_features ():
244244 speech_config = toy_speech_expert_cfg ()
245245 sound_config = toy_sound_expert_cfg ()
246246 speaker_config = toy_speaker_expert_cfg ()
@@ -265,7 +265,6 @@ def test_grouped_sequence_packed_non_strict_buckets_mixed_attention_features():
265265 signal ,
266266 signal_lengths ,
267267 fused_qkv = True ,
268- strict = False ,
269268 )
270269
271270 for name in encoder .pee .expert_names :
@@ -391,18 +390,6 @@ def forward_sequence_packed(self, audio_signal, length, bypass_pre_encode=False)
391390 container .forward_all_sequence_packed (data , torch .tensor ([3 ]), fused_qkv = True )
392391
393392
394- @pytest .mark .unit
395- def test_strict_grouped_sequence_packed_rejects_multiple_attention_buckets ():
396- encoder = build_toy_pe_encoder ().eval ()
397- encoder .pee .experts ['speaker' ].attn_mode = 'causal'
398- signal , signal_lengths = encoder ._prepare_input (
399- torch .randn (2 , _MEL_FEATURES , 32 ),
400- torch .tensor ([32 , 17 ]),
401- )
402- with pytest .raises (ValueError , match = 'one compatible attention bucket' ):
403- encoder .pee .forward_grouped_sequence_packed (signal , signal_lengths , strict = True )
404-
405-
406393@pytest .mark .unit
407394def test_pee_defaults_to_sparse_ragged_grouped_packed_execution ():
408395 encoder = build_toy_pe_encoder ()
0 commit comments