@@ -538,6 +538,7 @@ impl PaddleOCRVLModel {
538538 current_ids = Tensor :: new ( & [ next_token] , & self . device ) ?. unsqueeze ( 0 ) ?;
539539
540540 // Subsequent forward passes (text only, using KV cache)
541+ #[ allow( clippy:: explicit_counter_loop) ]
541542 for _ in 1 ..max_new_tokens {
542543 let logits = self . forward ( & current_ids, None , None , seqlen_offset) ?;
543544 let next_token = logits
@@ -600,6 +601,7 @@ impl PaddleOCRVLModel {
600601
601602 // Subsequent forward passes (text only, using KV cache)
602603 // Uses same incremental decoding as single-image generation
604+ #[ allow( clippy:: explicit_counter_loop) ]
603605 for _ in 1 ..max_new_tokens {
604606 let logits = self . forward ( & current_ids, None , None , seqlen_offset) ?;
605607 let next_token = logits
@@ -665,6 +667,7 @@ impl PaddleOCRVLModel {
665667 current_ids = Tensor :: new ( & [ next_token] , & self . device ) ?. unsqueeze ( 0 ) ?;
666668
667669 // Subsequent forward passes (text only, using KV cache)
670+ #[ allow( clippy:: explicit_counter_loop) ]
668671 for _ in 1 ..max_new_tokens {
669672 let logits = self . forward ( & current_ids, None , None , seqlen_offset) ?;
670673 let next_token = logits
@@ -871,6 +874,7 @@ impl PaddleOCRVLModel {
871874 current_ids = Tensor :: new ( & [ next_token] , & self . device ) ?. unsqueeze ( 0 ) ?;
872875
873876 // Subsequent forward passes (text only, using KV cache)
877+ #[ allow( clippy:: explicit_counter_loop) ]
874878 for _ in 1 ..max_new_tokens {
875879 let logits = self . forward ( & current_ids, None , None , seqlen_offset) ?;
876880 let logits = apply_repetition_penalty ( & logits, & generated_tokens, repetition_penalty) ?;
@@ -1047,6 +1051,7 @@ impl PaddleOCRVLModel {
10471051 let mut seqlen_offset = input_ids. dim ( 1 ) ?;
10481052 let mut current_ids = Tensor :: new ( & [ next_token] , & self . device ) ?. unsqueeze ( 0 ) ?;
10491053
1054+ #[ allow( clippy:: explicit_counter_loop) ]
10501055 for step in 1 ..max_steps {
10511056 // Compute position for M-RoPE
10521057 let pos = seqlen_offset as i64 + self . mrope_position_delta ;
0 commit comments