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

Beam search in inference #50

Open
Germany321 opened this issue Sep 18, 2024 · 0 comments
Open

Beam search in inference #50

Germany321 opened this issue Sep 18, 2024 · 0 comments

Comments

@Germany321
Copy link

hidden_states = generate_output.hidden_states last_hidden_states = [item[-1][0] for item in hidden_states] last_hidden_states = torch.cat(last_hidden_states, dim=0) seg_hidden_states = get_seg_hidden_states( last_hidden_states, generate_output.sequences[0][:-1], seg_id=omg_llava.seg_token_idx )
I notice that your code does not consider beam search process in the inference. Will it reduce the quality of generated text without beam search?

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