Page 1 of 1

multithreading doesn't work with AMD CPU when estimating ICLV model

Posted: 29 Sep 2021, 09:20
by YGao
Dear Apollo team,

Thank you for producing this wonderful library!
Please forgive my poor writing, I am not from a English speaking country.

I am encountering a strange problem during the estimation of ICLV models.

I have 2 computers, one laptop with Inter i7-1065G7, and a desktop with AMD Ryzen 5600x. Both of them are using R4.1.1 on windows 10, with Apollo version 0.2.5. I found that Apollo on my AMD platform estimating the ICLV model far slower than my Inter Laptop, which is theoretically unlikely.

To ensure the problem doesn't come from my coding, I run example 24 on Apollo homepage, only changing the nCores in apollo_control to enable multi-threading. During the estimation, I can tell from the windows Task manager that the Intel CPU utilization is always at 100% for all 8 cores, while the AMD CPU utilization is only around 2%-10% for all 12 cores. None of the AMD cores get fully used.

By the way I also do the same test based on Apollo example 16, and the multi-threading works perfectly on both CPU platforms... this completely confused me.

Is this a bug? Or did I do something wrong in setting my environment for the AMD platform?
Any feedback would be appreciated.

Best Regards,
Gao

Re: multithreading doesn't work with AMD CPU when estimating ICLV model

Posted: 30 Sep 2021, 09:33
by stephanehess
Gao

it doesn't make sense that this problem happens with hybrid choice but not with mixed logit, as the multi-threading part of the code is the same.

Can I suggest that you run some tests using the apollo_speedTest function on both machines, for both of the below examples, and then send us the output in reply to this post.

Stephane

Re: multithreading doesn't work with AMD CPU when estimating ICLV model

Posted: 18 Oct 2021, 07:57
by YGao
Hi, Professor Stephane

My apologies for the late reply. I actually solve this myself by resetting my windows 10... so I cannot reproduce this problem currently. Once I met the problem again (I hope not) I will try to run apollo_speedTest and show you the results.

Sorry to bother you.

Best regards,
gao