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

how to optimize setfit inference #519

Closed
geraldstanje opened this issue May 3, 2024 · 0 comments
Closed

how to optimize setfit inference #519

geraldstanje opened this issue May 3, 2024 · 0 comments

Comments

@geraldstanje
Copy link

geraldstanje commented May 3, 2024

hi,

im currently investigating what the options we have to optimize setfit inference and have a few questions about it:

model.model_body[0].auto_model = torch.compile(model.model_body[0].auto_model)

info above was provided by Tom Aarsen.

does torch.compile also work for cpu? edit: looks like it should work for cpu too...

https://pytorch.org/docs/stable/generated/torch.compile.html
does torch compile change anything about the accuracy of the model inference?

i see different modes here:
Can be either “default”, “reduce-overhead”, “max-autotune” or “max-autotune-no-cudagraphs” ... so far reduce-overhead gives best results....

are there any other resources to speedup setfit model inference? where can you run a setFit model except torchServe?

Thanks,
Gerald

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