Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ def calculate_dimensions(target_area, ratio):
class Qwen25_VLForConditionalGeneration_TextEncoder:
def __init__(self, config):
self.config = config
self.tokenizer_max_length = 1024
self.tokenizer_max_length = config.get("tokenizer_max_length", 4096)
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

The tokenizer_max_length configuration is currently only applied to the text-only encoding path (line 221). The processor call used for the i2i task (line 202) does not utilize this parameter, which leads to inconsistent truncation behavior between tasks. If a user configures a specific max length, it should ideally be respected across all encoding paths to ensure predictable behavior and memory usage.

self.prompt_template_encode = config["prompt_template_encode"]
self.prompt_template_encode_start_idx = config["prompt_template_encode_start_idx"]
"""
Expand Down
Loading