-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
large memory used when infer #11185
Comments
I meet this situation too. In addition, when i use the inference by multi-thread way with "export OPENBLAS_NUM_THREADS=1", the program may end with the "Aborted" error! |
@ChinaLiuHao |
Paddle/paddle/fluid/memory/detail/buddy_allocator.cc Lines 188 to 192 in 666c94e
This should be the reason. |
After debugging we can found there is a flag to choose how much memory we would like to use at the first time. Default it would use about 3.2%(1/32) of your total memory. usage:
The track back should be like this: Paddle/paddle/fluid/platform/cpu_info.cc Lines 26 to 28 in 666c94e
Paddle/paddle/fluid/platform/cpu_info.cc Lines 54 to 58 in 666c94e
Paddle/paddle/fluid/platform/cpu_info.cc Lines 65 to 69 in 666c94e
Paddle/paddle/fluid/memory/malloc.cc Lines 32 to 36 in 666c94e
|
@ChinaLiuHao |
This is an issue of NLP online service.
When run inference, the memory usage is always kept as about 6G, which is definitely larger than actually needed.
The text was updated successfully, but these errors were encountered: