Problem when running CosmoMC with several threads.

Use of Healpix, camb, CLASS, cosmomc, compilers, etc.
Post Reply
Tian Qiu
Posts: 12
Joined: June 01 2017
Affiliation: University of Science and Technology of China

Problem when running CosmoMC with several threads.

Post by Tian Qiu » April 13 2018

For CosmoMC, I have set the num_threads such as 8, 24, etc. and it ran well at beginning. However, when it had been going to converge down, for example, R-1 from about 50 to 10 or less, sometimes it would run only with one thread rather than what I had set. But if R-1 remained around a large number and did not go down, it would not happen. Even if I stopped running and restarted the chains with checkpoints, it would happen again.

Since it ran with one thread, it was quite inefficient. I have no idea to deal with the problem.

Thanks advanced.

Tian Qiu
Posts: 12
Joined: June 01 2017
Affiliation: University of Science and Technology of China

Problem when running CosmoMC with several threads.

Post by Tian Qiu » April 23 2018

Everything went well at beginning, but it could never stop and only one chain would continue. I have tried lots of times and it happened every time.
Chain:2 drag accpt: 0.4499022 fast/slow 142.6955 slow: 4273
Chain:7 drag accpt: 0.4695652 fast/slow 144.7206 slow: 4231
Chain:4 drag accpt: 0.4498346 fast/slow 143.8469 slow: 4265
Chain:5 drag accpt: 0.4810015 fast/slow 144.7060 slow: 4242
Chain:3 drag accpt: 0.4287599 fast/slow 144.3663 slow: 4273
Chain:6 drag accpt: 0.4420122 fast/slow 146.0141 slow: 4255
Chain:0 drag accpt: 0.4298741 fast/slow 143.0158 slow: 4316
Chain:2 drag accpt: 0.4509341 fast/slow 142.6484 slow: 4326
Chain:7 drag accpt: 0.4688503 fast/slow 144.6615 slow: 4298
Chain:5 drag accpt: 0.4818754 fast/slow 144.6505 slow: 4292
Chain:4 drag accpt: 0.4500000 fast/slow 143.7895 slow: 4328
Chain:1 drag accpt: 0.4451613 fast/slow 142.5981 slow: 4354
Chain:3 drag accpt: 0.4297808 fast/slow 144.3404 slow: 4330
Chain:6 drag accpt: 0.4417254 fast/slow 146.0000 slow: 4304
Chain:2 drag accpt: 0.4529024 fast/slow 142.6506 slow: 4370
Chain 3 MPI communicating
Chain 6 MPI communicating
Chain 2 MPI communicating
Chain 8 MPI communicating
Chain 5 MPI communicating
Chain 7 MPI communicating
Chain 4 MPI communicating
Chain 1 MPI communicating
Current convergence R-1 = 21.13658 chain steps = 4689
slow changes 4393 power changes 0
updating proposal density
Chain:0 drag accpt: 0.4268422 fast/slow 142.8537 slow: 4409
Chain:5 drag accpt: 0.4776056 fast/slow 144.5816 slow: 4350
Chain:7 drag accpt: 0.4665826 fast/slow 144.4332 slow: 4365
Chain:2 drag accpt: 0.4536862 fast/slow 142.6120 slow: 4420
Chain:6 drag accpt: 0.4394710 fast/slow 145.8835 slow: 4361
Chain:4 drag accpt: 0.4435058 fast/slow 143.5266 slow: 4438
Chain:5 drag accpt: 0.4750000 fast/slow 144.5144 slow: 4409
Chain:7 drag accpt: 0.4655493 fast/slow 144.3880 slow: 4428
Chain:6 drag accpt: 0.4409136 fast/slow 145.7571 slow: 4462
Chain:4 drag accpt: 0.4394471 fast/slow 143.4757 slow: 4526
Chain:2 drag accpt: 0.4474002 fast/slow 142.5385 slow: 4557
Chain:5 drag accpt: 0.4744526 fast/slow 144.4235 slow: 4508
Chain:7 drag accpt: 0.4670441 fast/slow 144.2503 slow: 4527
Chain:0 drag accpt: 0.4166667 fast/slow 142.7983 slow: 4576
Chain:3 drag accpt: 0.4195804 fast/slow 144.0562 slow: 4556
Chain:6 drag accpt: 0.4370629 fast/slow 145.6869 slow: 4535
Chain:5 drag accpt: 0.4746645 fast/slow 144.4093 slow: 4556
Chain:2 drag accpt: 0.4467832 fast/slow 142.5396 slow: 4613
Chain:7 drag accpt: 0.4662283 fast/slow 144.2381 slow: 4583
Chain:4 drag accpt: 0.4306220 fast/slow 143.4334 slow: 4631
Chain:3 drag accpt: 0.4154958 fast/slow 144.0475 slow: 4628
Chain:5 drag accpt: 0.4738401 fast/slow 144.3897 slow: 4601
Chain:6 drag accpt: 0.4363636 fast/slow 145.6216 slow: 4598
Chain:2 drag accpt: 0.4460094 fast/slow 142.5211 slow: 4665
Chain:0 drag accpt: 0.4123506 fast/slow 142.7958 slow: 4687
Chain:5 drag accpt: 0.4723032 fast/slow 144.3572 slow: 4647
Chain:7 drag accpt: 0.4627099 fast/slow 144.0715 slow: 4674
Chain:6 drag accpt: 0.4354383 fast/slow 145.5636 slow: 4658
Chain:3 drag accpt: 0.4124116 fast/slow 143.9662 slow: 4702
Chain:2 drag accpt: 0.4448296 fast/slow 142.5122 slow: 4729
Chain:4 drag accpt: 0.4271504 fast/slow 143.4003 slow: 4712
Chain:5 drag accpt: 0.4726225 fast/slow 144.3325 slow: 4701
Chain:7 drag accpt: 0.4606526 fast/slow 144.0229 slow: 4721
Chain:6 drag accpt: 0.4354298 fast/slow 145.5126 slow: 4711
Chain:2 drag accpt: 0.4435178 fast/slow 142.4737 slow: 4777
Chain:0 drag accpt: 0.4074505 fast/slow 142.7434 slow: 4798
Chain:7 drag accpt: 0.4583176 fast/slow 143.9530 slow: 4766
Chain:5 drag accpt: 0.4734741 fast/slow 144.3333 slow: 4753
Chain:2 drag accpt: 0.4437371 fast/slow 142.4565 slow: 4826
Chain:6 drag accpt: 0.4352617 fast/slow 145.4276 slow: 4771
Chain:3 drag accpt: 0.4067991 fast/slow 143.8855 slow: 4813
Chain:4 drag accpt: 0.4214923 fast/slow 143.4026 slow: 4819
Chain:7 drag accpt: 0.4572491 fast/slow 143.9483 slow: 4821
Chain:2 drag accpt: 0.4431315 fast/slow 142.4039 slow: 4882
Chain:6 drag accpt: 0.4347826 fast/slow 145.3592 slow: 4825
Chain:5 drag accpt: 0.4706761 fast/slow 144.2605 slow: 4833
Chain:7 drag accpt: 0.4562111 fast/slow 143.8774 slow: 4877
Chain:0 drag accpt: 0.4009789 fast/slow 142.6619 slow: 4925
Chain:6 drag accpt: 0.4354059 fast/slow 145.3331 slow: 4872
Chain:5 drag accpt: 0.4713494 fast/slow 144.2162 slow: 4876
Chain:4 drag accpt: 0.4142121 fast/slow 143.2860 slow: 4913
Chain:3 drag accpt: 0.4023096 fast/slow 143.7561 slow: 4916
Chain:2 drag accpt: 0.4398190 fast/slow 142.3366 slow: 4959
Chain:7 drag accpt: 0.4542996 fast/slow 143.8334 slow: 4933
Chain:6 drag accpt: 0.4357067 fast/slow 145.2932 slow: 4925
Chain:5 drag accpt: 0.4709748 fast/slow 144.1521 slow: 4931
Chain:0 drag accpt: 0.3983035 fast/slow 142.5754 slow: 5026
Chain:2 drag accpt: 0.4376445 fast/slow 142.2540 slow: 5023
Chain:4 drag accpt: 0.4094092 fast/slow 143.1566 slow: 4999
Chain:7 drag accpt: 0.4539790 fast/slow 143.7894 slow: 4985
Chain:6 drag accpt: 0.4362299 fast/slow 145.2398 slow: 4979
Chain:5 drag accpt: 0.4697624 fast/slow 144.1359 slow: 4997
Chain:2 drag accpt: 0.4373024 fast/slow 142.1742 slow: 5068
Chain:7 drag accpt: 0.4539856 fast/slow 143.7530 slow: 5040
Chain:6 drag accpt: 0.4368175 fast/slow 145.2239 slow: 5025
Chain:3 drag accpt: 0.3941685 fast/slow 143.5896 slow: 5088
Chain:5 drag accpt: 0.4689998 fast/slow 144.0590 slow: 5052
Chain:4 drag accpt: 0.4041288 fast/slow 143.1004 slow: 5090
Chain:2 drag accpt: 0.4358354 fast/slow 142.0540 slow: 5126
Chain:7 drag accpt: 0.4537552 fast/slow 143.6663 slow: 5097
Chain:6 drag accpt: 0.4370929 fast/slow 145.1786 slow: 5074
Chain:0 drag accpt: 0.3940266 fast/slow 142.5027 slow: 5150
Chain:5 drag accpt: 0.4658873 fast/slow 143.9904 slow: 5116
Chain:2 drag accpt: 0.4360465 fast/slow 142.0403 slow: 5186
Chain:7 drag accpt: 0.4518227 fast/slow 143.6259 slow: 5149
Chain:6 drag accpt: 0.4371400 fast/slow 145.1054 slow: 5125
Chain:4 drag accpt: 0.3981623 fast/slow 143.0283 slow: 5203
Chain:2 drag accpt: 0.4350025 fast/slow 142.0036 slow: 5237
Chain:7 drag accpt: 0.4505569 fast/slow 143.5708 slow: 5200
Chain:3 drag accpt: 0.3881119 fast/slow 143.4442 slow: 5221
Chain:5 drag accpt: 0.4644762 fast/slow 143.9433 slow: 5182
Chain:0 drag accpt: 0.3920876 fast/slow 142.4329 slow: 5251
Chain:6 drag accpt: 0.4371127 fast/slow 145.0675 slow: 5184
Chain:2 drag accpt: 0.4355081 fast/slow 141.9536 slow: 5285
Chain:7 drag accpt: 0.4515050 fast/slow 143.5215 slow: 5246
Chain:6 drag accpt: 0.4361474 fast/slow 144.9983 slow: 5238
Chain:3 drag accpt: 0.3871967 fast/slow 143.4051 slow: 5292
Chain:2 drag accpt: 0.4365801 fast/slow 141.9290 slow: 5328
Chain:0 drag accpt: 0.3892733 fast/slow 142.3729 slow: 5336
Chain:7 drag accpt: 0.4510905 fast/slow 143.4601 slow: 5295
Chain:4 drag accpt: 0.3932305 fast/slow 142.8963 slow: 5321
Chain:6 drag accpt: 0.4344289 fast/slow 145.0026 slow: 5306
Chain:2 drag accpt: 0.4354208 fast/slow 141.8970 slow: 5397
Chain:3 drag accpt: 0.3839677 fast/slow 143.2028 slow: 5375
Chain:7 drag accpt: 0.4501713 fast/slow 143.4138 slow: 5357
Chain:0 drag accpt: 0.3828073 fast/slow 142.3322 slow: 5424
Chain:6 drag accpt: 0.4352733 fast/slow 144.9320 slow: 5353
Chain:4 drag accpt: 0.3919007 fast/slow 142.8141 slow: 5405
Chain:2 drag accpt: 0.4348526 fast/slow 141.8599 slow: 5460
Chain:7 drag accpt: 0.4500000 fast/slow 143.4031 slow: 5416
Chain:3 drag accpt: 0.3812510 fast/slow 143.1440 slow: 5457
Chain:6 drag accpt: 0.4347826 fast/slow 144.8695 slow: 5419
Chain:0 drag accpt: 0.3746959 fast/slow 142.3529 slow: 5495
Chain:7 drag accpt: 0.4506232 fast/slow 143.3901 slow: 5460
Chain:2 drag accpt: 0.4351985 fast/slow 141.8128 slow: 5508
Chain:4 drag accpt: 0.3902988 fast/slow 142.8188 slow: 5496
Chain 8 MPI communicating
Chain 7 MPI communicating
Chain 3 MPI communicating
Chain 5 MPI communicating
Chain 4 MPI communicating
Chain:0 drag accpt: 0.3689688 fast/slow 142.3378 slow: 5601
Chain:0 drag accpt: 0.3624962 fast/slow 142.1080 slow: 5750
Chain:0 drag accpt: 0.3605227 fast/slow 142.0561 slow: 5850
Chain:0 drag accpt: 0.3596803 fast/slow 142.0228 slow: 5919
Chain:0 drag accpt: 0.3565217 fast/slow 141.9303 slow: 6025
Chain:0 drag accpt: 0.3520430 fast/slow 141.9188 slow: 6155
Chain:0 drag accpt: 0.3463441 fast/slow 141.8962 slow: 6320
Chain:0 drag accpt: 0.3428802 fast/slow 141.8466 slow: 6435
Chain:0 drag accpt: 0.3392505 fast/slow 141.8550 slow: 6551
Chain:0 drag accpt: 0.3358209 fast/slow 141.7403 slow: 6681

Post Reply