[model] fix: Incorrect usage of the 'check_model_inputs' decorator#457
[model] fix: Incorrect usage of the 'check_model_inputs' decorator#457HSYZhang wants to merge 2 commits intoByteDance-Seed:mainfrom
Conversation
|
zhanglong.443 seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account. You have signed the CLA already but the status is still pending? Let us recheck it. |
There was a problem hiding this comment.
Code Review
This pull request correctly fixes the usage of the @check_model_inputs decorator across multiple model files. The decorator was being called with parentheses (@check_model_inputs()) which is incorrect for a parameter-less decorator. The fix removes the parentheses, resolving the TypeError at runtime. The change is simple, accurate, and consistently applied. The PR is well-described and ready to merge.
|
Hi @HSYZhang , thank you very much. What is your version of transformers? |

What does this PR do?
This is a parameter-less decorator, and its usage in VeOmni is incorrect, like this:

@check_model_inputs() -> @check_model_inputs
Successfully executed after the fix:

Checklist Before Starting
[{modules}] {type}: {description}(This will be checked by the CI){modules}includemisc,ci,config,docs,data,dist,omni,logging,model,optim,ckpt,release,task,perf,ops,parallel,like[ci, data, model]{type}is infeat,fix,refactor,chore,test[BREAKING]to the beginning of the title.[BREAKING][parallel, model] feat: dynamic batchingTest
API and Usage Example
# Add code snippet or script demonstrating how to use thisDesign & Code Changes
Checklist Before Submitting
Important
Please check all the following items before requesting a review, otherwise the reviewer might deprioritize this PR for review.
pre-commit install && pre-commit run --all-files --show-diff-on-failure --color=always