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
为什么新样本首次推理速度都会慢? #279
Comments
第一次模型预热 |
比如我第一次输了样本a需要5秒,第二次0.95秒,然后继续输入样本b也需要5秒?这事没太理解,那以后给用户使用,推理前我都得先后台跑一次?
Get Outlook for Android<https://aka.ms/AAb9ysg>
…________________________________
From: zhoujun ***@***.***>
Sent: Friday, November 10, 2023 1:57:57 PM
To: WenmuZhou/PytorchOCR ***@***.***>
Cc: Damon Li ***@***.***>; Author ***@***.***>
Subject: Re: [WenmuZhou/PytorchOCR] 为什么第一次推理速度会慢? (Issue #279)
第一次模型预热
―
Reply to this email directly, view it on GitHub<#279 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AE4MZPHEJ6XO5MZLWYYYFW3YDW66LAVCNFSM6AAAAAA7FPUBKOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQMBVGE2DKMRTHA>.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
第一次5s,后续的都是0.95s,也就是说加载模型后的第一次运行会慢,其他都ok |
不是的,换一个新样本进行推理,第一次还是5s?重复predict才变到0.95? |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
如上图,我开了gpu,第一次推理很慢,同一个实例第二次推理非常快,什么原理请问?
关掉服务重启也一样。
尝试新的实例都一样,第一次都会很慢,第二次就很快,为什么呢?
The text was updated successfully, but these errors were encountered: