I wonder if there are some bugs in the pytorch’s data.loader API, The problem I found is that the system could be freeze when loading data using data.loader in training or validation process, almost with probability of 0.5. This is not affordable because the freeze can’t be solved even after 1 hour, the system seems to be almost dead. The only solution seems to forced physical shutdown, but I can’t always rely on this way, because I was told that it could cause the crash of system.
I thought may the reason is multi-thread, but I set num_workers=1 and the problem is still there. I found that when the system froze because data.loader, the music can be played as usual, so I think it’s not because the RAM or other resource are used up. When I forced physical shudown and restarted the system, the freeze occurred again while the fans were quiet, so the temperature seems not the reason.
My system is ubuntu 16.04, the version of python is 2.7, and pytorch’s version is 0.5.0.  I heard that others have met the same question using version 1.0, so the version of pytorch seems not the reason as well.
I searched the solution from google and this forum, but it seems nobody meet this question. okey… Could  you figure out the possible culprit? Please share some advice if possible. Thank you very much.