Skip to content

Commit b83d1db

Browse files
Rename index for attention prior weights (#15551)
Signed-off-by: Subhankar Ghosh <subhankarg@nvidia.com>
1 parent db8e21d commit b83d1db

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

nemo/collections/tts/models/magpietts.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4210,9 +4210,9 @@ def _initialize_chunked_attn_prior(
42104210
prior_weights = self.chunked_inference_config.prior_weights_init
42114211
_attn_prior[_idx, :, :current_starting_point] = prior_epsilon * prior_epsilon
42124212
for offset, weight in enumerate(prior_weights[:5]):
4213-
idx = current_starting_point + offset
4214-
if idx < max_text_len:
4215-
_attn_prior[_idx, :, idx] = weight
4213+
current_offset_idx = current_starting_point + offset
4214+
if current_offset_idx < max_text_len:
4215+
_attn_prior[_idx, :, current_offset_idx] = weight
42164216

42174217
return _attn_prior
42184218

0 commit comments

Comments
 (0)