TST: attempt to make test_load_refcount deterministic
TST: attempt to make test_load_refcount deterministic

Use a different strategy to detect whether np.load creates cycles.

Fixes gh-6571, I hope.

mattip/numpy,grlee77/numpy,gfyoung/numpy,rgommers/numpy,seberg/numpy,ssanderson/numpy,kiwifb/numpy,mhvk/numpy,grlee77/numpy,maniteja123/numpy,ContinuumIO/numpy,pdebuyl/numpy,rherault-insa/numpy,nbeaver/numpy,tynn/numpy,b-carter/numpy,seberg/numpy,Eric89GXL/numpy,joferkington/numpy,AustereCuriosity/numpy,grlee77/numpy,SiccarPoint/numpy,AustereCuriosity/numpy,anntzer/numpy,jorisvandenbossche/numpy,njase/numpy,ahaldane/numpy,drasmuss/numpy,ssanderson/numpy,ViralLeadership/numpy,mwiebe/numpy,jakirkham/numpy,Eric89GXL/numpy,shoyer/numpy,anntzer/numpy,mwiebe/numpy,utke1/numpy,ssanderson/numpy,mhvk/numpy,ahaldane/numpy,pdebuyl/numpy,jorisvandenbossche/numpy,WillieMaddox/numpy,rherault-insa/numpy,gmcastil/numpy,rherault-insa/numpy,simongibbons/numpy,tacaswell/numpy,pizzathief/numpy,joferkington/numpy,anntzer/numpy,pbrod/numpy,argriffing/numpy,chatcannon/numpy,WarrenWeckesser/numpy,mhvk/numpy,WillieMaddox/numpy,abalkin/numpy,SiccarPoint/numpy,rgommers/numpy,MSeifert04/numpy,bertrand-l/numpy,rgommers/numpy,Dapid/numpy,jonathanunderwood/numpy,pizzathief/numpy,madphysicist/numpy,dwillmer/numpy,SiccarPoint/numpy,grlee77/numpy,pdebuyl/numpy,jakirkham/numpy,endolith/numpy,mattip/numpy,tacaswell/numpy,mattip/numpy,mattip/numpy,stuarteberg/numpy,pbrod/numpy,WarrenWeckesser/numpy,nbeaver/numpy,ViralLeadership/numpy,behzadnouri/numpy,abalkin/numpy,madphysicist/numpy,ddasilva/numpy,ESSS/numpy,mhvk/numpy,seberg/numpy,jorisvandenbossche/numpy,argriffing/numpy,Dapid/numpy,AustereCuriosity/numpy,chiffa/numpy,ViralLeadership/numpy,charris/numpy,solarjoe/numpy,ContinuumIO/numpy,pbrod/numpy,ContinuumIO/numpy,bringingheavendown/numpy,Eric89GXL/numpy,ahaldane/numpy,utke1/numpy,charris/numpy,madphysicist/numpy,nbeaver/numpy,charris/numpy,chiffa/numpy,pyparallel/numpy,Dapid/numpy,simongibbons/numpy,pizzathief/numpy,numpy/numpy,kiwifb/numpy,tacaswell/numpy,drasmuss/numpy,WarrenWeckesser/numpy,skwbc/numpy,bringingheavendown/numpy,jorisvandenbossche/numpy,dwillmer/numpy,simongibbons/numpy,ESSS/numpy,WillieMaddox/numpy,WarrenWeckesser/numpy,jonathanunderwood/numpy,solarjoe/numpy,ahaldane/numpy,solarjoe/numpy,stuarteberg/numpy,chiffa/numpy,pyparallel/numpy,Eric89GXL/numpy,njase/numpy,madphysicist/numpy,SiccarPoint/numpy,shoyer/numpy,MSeifert04/numpy,madphysicist/numpy,ESSS/numpy,dwillmer/numpy,behzadnouri/numpy,argriffing/numpy,pizzathief/numpy,gfyoung/numpy,grlee77/numpy,joferkington/numpy,jakirkham/numpy,behzadnouri/numpy,MSeifert04/numpy,ddasilva/numpy,mwiebe/numpy,simongibbons/numpy,bertrand-l/numpy,njase/numpy,WarrenWeckesser/numpy,gfyoung/numpy,pizzathief/numpy,drasmuss/numpy,tynn/numpy,stuarteberg/numpy,anntzer/numpy,shoyer/numpy,jorisvandenbossche/numpy,tynn/numpy,chatcannon/numpy,mhvk/numpy,endolith/numpy,shoyer/numpy,b-carter/numpy,pdebuyl/numpy,dwillmer/numpy,skwbc/numpy,maniteja123/numpy,rgommers/numpy,joferkington/numpy,pbrod/numpy,stuarteberg/numpy,utke1/numpy,endolith/numpy,gmcastil/numpy,numpy/numpy,ddasilva/numpy,seberg/numpy,pbrod/numpy,numpy/numpy,skwbc/numpy,charris/numpy,pyparallel/numpy,shoyer/numpy,MSeifert04/numpy,maniteja123/numpy,MSeifert04/numpy,abalkin/numpy,simongibbons/numpy,jakirkham/numpy,endolith/numpy,gmcastil/numpy,bringingheavendown/numpy,jakirkham/numpy,chatcannon/numpy,bertrand-l/numpy,b-carter/numpy,numpy/numpy,jonathanunderwood/numpy,ahaldane/numpy,kiwifb/numpy