We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 855849c commit a316815Copy full SHA for a316815
comfy/text_encoders/ace15.py
@@ -19,6 +19,7 @@ def sample_manual_loop_no_classes(
19
min_tokens: int = 1,
20
max_new_tokens: int = 2048,
21
audio_start_id: int = 151669, # The cutoff ID for audio codes
22
+ audio_end_id: int = 215669,
23
eos_token_id: int = 151645,
24
):
25
device = model.execution_device
@@ -60,6 +61,7 @@ def sample_manual_loop_no_classes(
60
61
remove_logit_value = torch.finfo(cfg_logits.dtype).min
62
# Only generate audio tokens
63
cfg_logits[:, :audio_start_id] = remove_logit_value
64
+ cfg_logits[:, audio_end_id:] = remove_logit_value
65
66
if eos_token_id is not None and eos_token_id < audio_start_id and min_tokens < step:
67
cfg_logits[:, eos_token_id] = eos_score
0 commit comments