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

Batch inference #93

Open
mtsysin opened this issue Jun 13, 2024 · 2 comments
Open

Batch inference #93

mtsysin opened this issue Jun 13, 2024 · 2 comments

Comments

@mtsysin
Copy link

mtsysin commented Jun 13, 2024

Hi!

I'm evaluating the model on a relatively large dataset (single question, single answer). I was able to fine-tune the Bunny-1.1-Llama-3-8B-V model using one of the scripts provided. What is the best strategy to implement batch inference?

@Isaachhh
Copy link
Collaborator

Isaachhh commented Jul 6, 2024

Sorry for that we don't support batch inference currently. You may split the dataset into multiple parts and launch a model on each GPU, like evaluating on VQA, GQA and SEED-Bench.

@Isaachhh
Copy link
Collaborator

Isaachhh commented Aug 2, 2024

@mtsysin

You may refer to batch_inference.py.

However, we failed to set the attention_mask of left-padding tokens to be 0. So the attention_mask of inputs are all 1 and the outputs may be a little different from single-sample inference.

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

2 participants