Skip to content

get_pipeline function passes Path object rather than PretrainedTokenizer #105

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

Open
jpang32 opened this issue Oct 1, 2023 · 0 comments
Open

Comments

@jpang32
Copy link

jpang32 commented Oct 1, 2023

When using certain pipeline tasks (e.g., "image-to-text") the get_pipeline function passes in model_dir as the tokenizer ink wargs. However, the Pipeline class expects a PretrainedTokenizer object instead. Because model_dir is being passed, when the tokenizer is decoded in the subclass it gives the error "message": "str object has no attribute decode".

This should be changed so that this function is using the proper tokenizer for the task.

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

No branches or pull requests

1 participant