I have a 2 CPU Xeon 2620 v3 (6 cores each). I am using it for ML projects. I have created a virtual environment using intel python v 3.6.
I have 2 similar scripts script1.py and script2.py. Both files are in the attached zip file.
The first script script1.py automatically takes all 12 cores and I see very good speed.
Howerver script2.py never goes beyond 1 core.
I don't use any complex equations in these scripts. Just usual pandas data frames. Can someone tell me why one script automatically executes on all 12 cores and the other one uses only one core. I would like to speed up the second script as well.