Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix finetune minicpm error #579

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

jackyjinjing
Copy link

@jackyjinjing jackyjinjing commented Sep 14, 2024

fix #578
fix #581

Copy link

@RahulVadisetty91 RahulVadisetty91 left a comment

Choose a reason for hiding this comment

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

43d

The second if statement should be properly indented to match the first if block’s level.

if input_ids.shape[-1] > max_length:
if ids.shape[-1] > max_length:
ids = ids[:max_length]
context = context[:max_length]
logger.warning(f"The input length ({input_ids.shape[-1]}) exceeds the model's maximum length ({max_length}), so it has been truncated")

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants