-
Notifications
You must be signed in to change notification settings - Fork 319
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Refactor] Refactor functional calls in losses #1707
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/rl/1707
Note: Links to docs will display an error until the docs builds have been completed. ✅ You can merge normally! (8 Unrelated Failures)As of commit 3c2e007 with merge base fa149e4 (): FLAKY - The following jobs failed but were likely due to flakiness present on trunk:
BROKEN TRUNK - The following jobs failed but were present on the merge base:👉 Rebase onto the `viable/strict` branch to avoid these failures
This comment was automatically generated by Dr. CI and updates every 15 minutes. |
|
Name | Max | Mean | Ops | Ops on Repo HEAD
|
Change |
---|---|---|---|---|---|
test_single | 63.3544ms | 62.6579ms | 15.9597 Ops/s | 15.3488 Ops/s | |
test_sync | 40.5161ms | 34.1434ms | 29.2882 Ops/s | 27.7791 Ops/s | |
test_async | 47.8996ms | 32.0428ms | 31.2082 Ops/s | 30.9770 Ops/s | |
test_simple | 0.4837s | 0.4325s | 2.3124 Ops/s | 2.3297 Ops/s | |
test_transformed | 0.6314s | 0.5920s | 1.6891 Ops/s | 1.6958 Ops/s | |
test_serial | 1.3423s | 1.2956s | 0.7718 Ops/s | 0.7773 Ops/s | |
test_parallel | 1.3421s | 1.2970s | 0.7710 Ops/s | 0.7542 Ops/s | |
test_step_mdp_speed[True-True-True-True-True] | 0.1339ms | 22.6870μs | 44.0781 KOps/s | 43.4046 KOps/s | |
test_step_mdp_speed[True-True-True-True-False] | 54.7420μs | 13.7655μs | 72.6456 KOps/s | 72.5102 KOps/s | |
test_step_mdp_speed[True-True-True-False-True] | 39.6540μs | 14.0702μs | 71.0721 KOps/s | 71.9249 KOps/s | |
test_step_mdp_speed[True-True-True-False-False] | 31.7900μs | 8.3401μs | 119.9026 KOps/s | 119.7041 KOps/s | |
test_step_mdp_speed[True-True-False-True-True] | 57.8280μs | 24.0198μs | 41.6324 KOps/s | 41.2584 KOps/s | |
test_step_mdp_speed[True-True-False-True-False] | 60.3200μs | 14.9604μs | 66.8433 KOps/s | 66.0042 KOps/s | |
test_step_mdp_speed[True-True-False-False-True] | 56.4670μs | 15.0768μs | 66.3272 KOps/s | 65.6781 KOps/s | |
test_step_mdp_speed[True-True-False-False-False] | 57.3670μs | 9.7672μs | 102.3835 KOps/s | 103.3892 KOps/s | |
test_step_mdp_speed[True-False-True-True-True] | 67.0650μs | 25.7146μs | 38.8883 KOps/s | 38.9500 KOps/s | |
test_step_mdp_speed[True-False-True-True-False] | 65.5930μs | 17.3185μs | 57.7416 KOps/s | 60.8041 KOps/s | |
test_step_mdp_speed[True-False-True-False-True] | 47.6380μs | 15.1195μs | 66.1396 KOps/s | 64.2512 KOps/s | |
test_step_mdp_speed[True-False-True-False-False] | 55.2730μs | 9.5909μs | 104.2652 KOps/s | 103.7093 KOps/s | |
test_step_mdp_speed[True-False-False-True-True] | 63.6790μs | 26.9422μs | 37.1165 KOps/s | 36.9628 KOps/s | |
test_step_mdp_speed[True-False-False-True-False] | 44.7240μs | 17.4325μs | 57.3641 KOps/s | 56.7181 KOps/s | |
test_step_mdp_speed[True-False-False-False-True] | 49.0110μs | 16.5356μs | 60.4757 KOps/s | 60.3719 KOps/s | |
test_step_mdp_speed[True-False-False-False-False] | 36.8390μs | 10.7846μs | 92.7248 KOps/s | 92.7006 KOps/s | |
test_step_mdp_speed[False-True-True-True-True] | 0.1089ms | 25.8475μs | 38.6884 KOps/s | 38.5702 KOps/s | |
test_step_mdp_speed[False-True-True-True-False] | 54.6620μs | 16.4373μs | 60.8374 KOps/s | 60.7207 KOps/s | |
test_step_mdp_speed[False-True-True-False-True] | 60.8530μs | 17.5315μs | 57.0403 KOps/s | 56.3269 KOps/s | |
test_step_mdp_speed[False-True-True-False-False] | 32.4000μs | 10.9155μs | 91.6126 KOps/s | 92.3593 KOps/s | |
test_step_mdp_speed[False-True-False-True-True] | 80.3580μs | 26.7954μs | 37.3198 KOps/s | 36.7932 KOps/s | |
test_step_mdp_speed[False-True-False-True-False] | 44.2120μs | 17.6302μs | 56.7208 KOps/s | 56.3968 KOps/s | |
test_step_mdp_speed[False-True-False-False-True] | 50.1830μs | 18.6442μs | 53.6360 KOps/s | 52.6929 KOps/s | |
test_step_mdp_speed[False-True-False-False-False] | 40.2650μs | 12.0134μs | 83.2401 KOps/s | 83.4612 KOps/s | |
test_step_mdp_speed[False-False-True-True-True] | 66.2930μs | 28.0213μs | 35.6871 KOps/s | 35.2003 KOps/s | |
test_step_mdp_speed[False-False-True-True-False] | 42.9000μs | 18.9249μs | 52.8404 KOps/s | 52.8632 KOps/s | |
test_step_mdp_speed[False-False-True-False-True] | 73.1860μs | 18.7621μs | 53.2989 KOps/s | 52.5684 KOps/s | |
test_step_mdp_speed[False-False-True-False-False] | 58.9500μs | 12.0344μs | 83.0954 KOps/s | 83.4055 KOps/s | |
test_step_mdp_speed[False-False-False-True-True] | 67.5360μs | 28.9052μs | 34.5958 KOps/s | 33.7026 KOps/s | |
test_step_mdp_speed[False-False-False-True-False] | 68.4870μs | 20.0181μs | 49.9549 KOps/s | 49.5999 KOps/s | |
test_step_mdp_speed[False-False-False-False-True] | 55.0130μs | 19.5721μs | 51.0931 KOps/s | 49.8158 KOps/s | |
test_step_mdp_speed[False-False-False-False-False] | 51.3760μs | 13.2075μs | 75.7147 KOps/s | 75.3650 KOps/s | |
test_values[generalized_advantage_estimate-True-True] | 12.5728ms | 12.2282ms | 81.7783 Ops/s | 81.5674 Ops/s | |
test_values[vec_generalized_advantage_estimate-True-True] | 35.0759ms | 26.4636ms | 37.7877 Ops/s | 37.6916 Ops/s | |
test_values[td0_return_estimate-False-False] | 0.9078ms | 0.2027ms | 4.9338 KOps/s | 5.5901 KOps/s | |
test_values[td1_return_estimate-False-False] | 27.5159ms | 26.1928ms | 38.1784 Ops/s | 39.4200 Ops/s | |
test_values[vec_td1_return_estimate-False-False] | 33.8212ms | 26.7074ms | 37.4428 Ops/s | 37.3953 Ops/s | |
test_values[td_lambda_return_estimate-True-False] | 38.6641ms | 36.0636ms | 27.7288 Ops/s | 28.1621 Ops/s | |
test_values[vec_td_lambda_return_estimate-True-False] | 34.0609ms | 26.5706ms | 37.6356 Ops/s | 37.1114 Ops/s | |
test_gae_speed[generalized_advantage_estimate-False-1-512] | 8.4218ms | 8.2214ms | 121.6340 Ops/s | 124.6551 Ops/s | |
test_gae_speed[vec_generalized_advantage_estimate-True-1-512] | 3.2025ms | 1.9703ms | 507.5448 Ops/s | 531.3416 Ops/s | |
test_gae_speed[vec_generalized_advantage_estimate-False-1-512] | 7.9911ms | 0.4393ms | 2.2766 KOps/s | 2.3709 KOps/s | |
test_gae_speed[vec_generalized_advantage_estimate-True-32-512] | 45.9765ms | 39.3389ms | 25.4201 Ops/s | 24.5393 Ops/s | |
test_gae_speed[vec_generalized_advantage_estimate-False-32-512] | 10.0811ms | 2.5008ms | 399.8694 Ops/s | 397.3265 Ops/s | |
test_dqn_speed | 64.1915ms | 1.8736ms | 533.7431 Ops/s | 696.7229 Ops/s | |
test_ddpg_speed | 11.3024ms | 3.9468ms | 253.3718 Ops/s | 330.5113 Ops/s | |
test_sac_speed | 19.5163ms | 10.9023ms | 91.7236 Ops/s | 114.0478 Ops/s | |
test_redq_speed | 24.8237ms | 17.6000ms | 56.8182 Ops/s | 66.6276 Ops/s | |
test_redq_deprec_speed | 24.3701ms | 15.9693ms | 62.6203 Ops/s | 74.2060 Ops/s | |
test_td3_speed | 20.1727ms | 11.3523ms | 88.0882 Ops/s | 104.7451 Ops/s | |
test_cql_speed | 47.9391ms | 41.9490ms | 23.8385 Ops/s | 25.6680 Ops/s | |
test_a2c_speed | 17.1457ms | 8.9578ms | 111.6346 Ops/s | 122.9191 Ops/s | |
test_ppo_speed | 17.3824ms | 9.2756ms | 107.8092 Ops/s | 121.0411 Ops/s | |
test_reinforce_speed | 15.8485ms | 7.9903ms | 125.1517 Ops/s | 141.9873 Ops/s | |
test_iql_speed | 43.2668ms | 36.0386ms | 27.7480 Ops/s | 27.5380 Ops/s | |
test_sample_rb[TensorDictReplayBuffer-ListStorage-RandomSampler-4000] | 2.3127ms | 1.8191ms | 549.7112 Ops/s | 536.4043 Ops/s | |
test_sample_rb[TensorDictReplayBuffer-LazyMemmapStorage-RandomSampler-10000] | 2.9646ms | 1.9386ms | 515.8268 Ops/s | 415.6728 Ops/s | |
test_sample_rb[TensorDictReplayBuffer-LazyTensorStorage-RandomSampler-10000] | 2.6782ms | 1.9632ms | 509.3750 Ops/s | 492.1566 Ops/s | |
test_sample_rb[TensorDictReplayBuffer-ListStorage-SamplerWithoutReplacement-4000] | 2.5658ms | 1.8449ms | 542.0388 Ops/s | 530.0365 Ops/s | |
test_sample_rb[TensorDictReplayBuffer-LazyMemmapStorage-SamplerWithoutReplacement-10000] | 3.0660ms | 1.9895ms | 502.6309 Ops/s | 494.4595 Ops/s | |
test_sample_rb[TensorDictReplayBuffer-LazyTensorStorage-SamplerWithoutReplacement-10000] | 3.0901ms | 1.9577ms | 510.8127 Ops/s | 498.1987 Ops/s | |
test_sample_rb[TensorDictPrioritizedReplayBuffer-ListStorage-None-4000] | 2.0563ms | 1.8351ms | 544.9156 Ops/s | 538.2095 Ops/s | |
test_sample_rb[TensorDictPrioritizedReplayBuffer-LazyMemmapStorage-None-10000] | 2.9427ms | 1.9341ms | 517.0245 Ops/s | 435.2448 Ops/s | |
test_sample_rb[TensorDictPrioritizedReplayBuffer-LazyTensorStorage-None-10000] | 2.9288ms | 1.9502ms | 512.7704 Ops/s | 488.2919 Ops/s | |
test_iterate_rb[TensorDictReplayBuffer-ListStorage-RandomSampler-4000] | 0.1900s | 2.1853ms | 457.6004 Ops/s | 523.0743 Ops/s | |
test_iterate_rb[TensorDictReplayBuffer-LazyMemmapStorage-RandomSampler-10000] | 3.2220ms | 1.9516ms | 512.3905 Ops/s | 486.6483 Ops/s | |
test_iterate_rb[TensorDictReplayBuffer-LazyTensorStorage-RandomSampler-10000] | 2.6593ms | 1.9601ms | 510.1695 Ops/s | 496.5075 Ops/s | |
test_iterate_rb[TensorDictReplayBuffer-ListStorage-SamplerWithoutReplacement-4000] | 2.7995ms | 1.8417ms | 542.9747 Ops/s | 532.1219 Ops/s | |
test_iterate_rb[TensorDictReplayBuffer-LazyMemmapStorage-SamplerWithoutReplacement-10000] | 2.9877ms | 1.9436ms | 514.5196 Ops/s | 494.0665 Ops/s | |
test_iterate_rb[TensorDictReplayBuffer-LazyTensorStorage-SamplerWithoutReplacement-10000] | 3.1678ms | 1.9787ms | 505.3797 Ops/s | 506.6271 Ops/s | |
test_iterate_rb[TensorDictPrioritizedReplayBuffer-ListStorage-None-4000] | 2.7417ms | 1.8646ms | 536.2996 Ops/s | 449.2304 Ops/s | |
test_iterate_rb[TensorDictPrioritizedReplayBuffer-LazyMemmapStorage-None-10000] | 2.7963ms | 1.9649ms | 508.9196 Ops/s | 491.0668 Ops/s | |
test_iterate_rb[TensorDictPrioritizedReplayBuffer-LazyTensorStorage-None-10000] | 3.1689ms | 1.9648ms | 508.9475 Ops/s | 502.4576 Ops/s | |
test_populate_rb[TensorDictReplayBuffer-ListStorage-RandomSampler-400] | 0.1957s | 20.1875ms | 49.5355 Ops/s | 48.5298 Ops/s | |
test_populate_rb[TensorDictReplayBuffer-LazyMemmapStorage-RandomSampler-400] | 0.1116s | 20.3016ms | 49.2573 Ops/s | 47.5363 Ops/s | |
test_populate_rb[TensorDictReplayBuffer-LazyTensorStorage-RandomSampler-400] | 0.1089s | 16.5009ms | 60.6027 Ops/s | 53.0951 Ops/s | |
test_populate_rb[TensorDictReplayBuffer-ListStorage-SamplerWithoutReplacement-400] | 0.1120s | 18.5078ms | 54.0311 Ops/s | 53.1619 Ops/s | |
test_populate_rb[TensorDictReplayBuffer-LazyMemmapStorage-SamplerWithoutReplacement-400] | 0.1078s | 20.1923ms | 49.5238 Ops/s | 47.0938 Ops/s | |
test_populate_rb[TensorDictReplayBuffer-LazyTensorStorage-SamplerWithoutReplacement-400] | 0.1119s | 18.4042ms | 54.3355 Ops/s | 53.0961 Ops/s | |
test_populate_rb[TensorDictPrioritizedReplayBuffer-ListStorage-None-400] | 0.1177s | 18.8177ms | 53.1415 Ops/s | 52.1033 Ops/s | |
test_populate_rb[TensorDictPrioritizedReplayBuffer-LazyMemmapStorage-None-400] | 0.1122s | 20.3038ms | 49.2519 Ops/s | 46.6908 Ops/s | |
test_populate_rb[TensorDictPrioritizedReplayBuffer-LazyTensorStorage-None-400] | 0.1068s | 18.3434ms | 54.5156 Ops/s | 53.2190 Ops/s |
|
Name | Max | Mean | Ops | Ops on Repo HEAD
|
Change |
---|---|---|---|---|---|
test_single | 0.1272s | 0.1231s | 8.1214 Ops/s | 8.1309 Ops/s | |
test_sync | 0.1037s | 0.1027s | 9.7384 Ops/s | 9.5025 Ops/s | |
test_async | 0.2731s | 99.6338ms | 10.0368 Ops/s | 9.9256 Ops/s | |
test_single_pixels | 0.1329s | 0.1326s | 7.5411 Ops/s | 6.8889 Ops/s | |
test_sync_pixels | 97.0390ms | 94.8917ms | 10.5383 Ops/s | 10.4690 Ops/s | |
test_async_pixels | 0.2460s | 91.3364ms | 10.9485 Ops/s | 10.8105 Ops/s | |
test_simple | 0.9520s | 0.8876s | 1.1266 Ops/s | 1.1395 Ops/s | |
test_transformed | 1.1949s | 1.1350s | 0.8810 Ops/s | 0.8775 Ops/s | |
test_serial | 2.4901s | 2.4226s | 0.4128 Ops/s | 0.4097 Ops/s | |
test_parallel | 2.5797s | 2.5495s | 0.3922 Ops/s | 0.3953 Ops/s | |
test_step_mdp_speed[True-True-True-True-True] | 76.2210μs | 35.0757μs | 28.5098 KOps/s | 27.9919 KOps/s | |
test_step_mdp_speed[True-True-True-True-False] | 70.5120μs | 20.9536μs | 47.7246 KOps/s | 48.9186 KOps/s | |
test_step_mdp_speed[True-True-True-False-True] | 48.4700μs | 20.9809μs | 47.6624 KOps/s | 47.1918 KOps/s | |
test_step_mdp_speed[True-True-True-False-False] | 59.9710μs | 12.5896μs | 79.4307 KOps/s | 82.4768 KOps/s | |
test_step_mdp_speed[True-True-False-True-True] | 84.9420μs | 37.3664μs | 26.7620 KOps/s | 27.6452 KOps/s | |
test_step_mdp_speed[True-True-False-True-False] | 65.2310μs | 22.5868μs | 44.2737 KOps/s | 45.2628 KOps/s | |
test_step_mdp_speed[True-True-False-False-True] | 46.6710μs | 22.8901μs | 43.6870 KOps/s | 44.4730 KOps/s | |
test_step_mdp_speed[True-True-False-False-False] | 41.1400μs | 14.2141μs | 70.3529 KOps/s | 71.8772 KOps/s | |
test_step_mdp_speed[True-False-True-True-True] | 68.6210μs | 39.0542μs | 25.6055 KOps/s | 25.6233 KOps/s | |
test_step_mdp_speed[True-False-True-True-False] | 61.3520μs | 24.4638μs | 40.8767 KOps/s | 41.1953 KOps/s | |
test_step_mdp_speed[True-False-True-False-True] | 47.7110μs | 22.7722μs | 43.9133 KOps/s | 43.6129 KOps/s | |
test_step_mdp_speed[True-False-True-False-False] | 48.8210μs | 14.0991μs | 70.9263 KOps/s | 72.2184 KOps/s | |
test_step_mdp_speed[True-False-False-True-True] | 81.8410μs | 40.4815μs | 24.7027 KOps/s | 24.3687 KOps/s | |
test_step_mdp_speed[True-False-False-True-False] | 75.4520μs | 26.4014μs | 37.8768 KOps/s | 38.3704 KOps/s | |
test_step_mdp_speed[True-False-False-False-True] | 61.0010μs | 24.6843μs | 40.5116 KOps/s | 41.0449 KOps/s | |
test_step_mdp_speed[True-False-False-False-False] | 57.5310μs | 15.8795μs | 62.9743 KOps/s | 63.4572 KOps/s | |
test_step_mdp_speed[False-True-True-True-True] | 63.2410μs | 39.4315μs | 25.3604 KOps/s | 25.7230 KOps/s | |
test_step_mdp_speed[False-True-True-True-False] | 72.8110μs | 24.6572μs | 40.5561 KOps/s | 41.4871 KOps/s | |
test_step_mdp_speed[False-True-True-False-True] | 53.7310μs | 26.2438μs | 38.1043 KOps/s | 37.7341 KOps/s | |
test_step_mdp_speed[False-True-True-False-False] | 40.8600μs | 16.0709μs | 62.2242 KOps/s | 62.1816 KOps/s | |
test_step_mdp_speed[False-True-False-True-True] | 79.7110μs | 41.2104μs | 24.2657 KOps/s | 24.3228 KOps/s | |
test_step_mdp_speed[False-True-False-True-False] | 46.7810μs | 26.6399μs | 37.5377 KOps/s | 37.9680 KOps/s | |
test_step_mdp_speed[False-True-False-False-True] | 49.9510μs | 28.1807μs | 35.4853 KOps/s | 35.0300 KOps/s | |
test_step_mdp_speed[False-True-False-False-False] | 37.2700μs | 18.0771μs | 55.3187 KOps/s | 56.7110 KOps/s | |
test_step_mdp_speed[False-False-True-True-True] | 71.2300μs | 42.8682μs | 23.3273 KOps/s | 23.1857 KOps/s | |
test_step_mdp_speed[False-False-True-True-False] | 47.0210μs | 28.1905μs | 35.4729 KOps/s | 35.4543 KOps/s | |
test_step_mdp_speed[False-False-True-False-True] | 46.3510μs | 28.0485μs | 35.6525 KOps/s | 35.2657 KOps/s | |
test_step_mdp_speed[False-False-True-False-False] | 38.4600μs | 17.8056μs | 56.1620 KOps/s | 56.6203 KOps/s | |
test_step_mdp_speed[False-False-False-True-True] | 97.1320μs | 44.0555μs | 22.6986 KOps/s | 22.8766 KOps/s | |
test_step_mdp_speed[False-False-False-True-False] | 55.8710μs | 30.4904μs | 32.7972 KOps/s | 33.2206 KOps/s | |
test_step_mdp_speed[False-False-False-False-True] | 48.0810μs | 29.6222μs | 33.7585 KOps/s | 32.8509 KOps/s | |
test_step_mdp_speed[False-False-False-False-False] | 56.0910μs | 19.6521μs | 50.8852 KOps/s | 51.3098 KOps/s | |
test_values[generalized_advantage_estimate-True-True] | 27.0504ms | 26.5452ms | 37.6717 Ops/s | 37.9039 Ops/s | |
test_values[vec_generalized_advantage_estimate-True-True] | 85.2130ms | 3.2775ms | 305.1128 Ops/s | 300.6841 Ops/s | |
test_values[td0_return_estimate-False-False] | 0.1021ms | 66.8122μs | 14.9673 KOps/s | 14.7810 KOps/s | |
test_values[td1_return_estimate-False-False] | 57.1508ms | 56.6800ms | 17.6429 Ops/s | 17.6930 Ops/s | |
test_values[vec_td1_return_estimate-False-False] | 1.9914ms | 1.7477ms | 572.1717 Ops/s | 571.9985 Ops/s | |
test_values[td_lambda_return_estimate-True-False] | 93.5276ms | 90.8014ms | 11.0130 Ops/s | 11.1376 Ops/s | |
test_values[vec_td_lambda_return_estimate-True-False] | 2.0141ms | 1.7395ms | 574.8634 Ops/s | 571.5513 Ops/s | |
test_gae_speed[generalized_advantage_estimate-False-1-512] | 25.7999ms | 25.3741ms | 39.4102 Ops/s | 39.5230 Ops/s | |
test_gae_speed[vec_generalized_advantage_estimate-True-1-512] | 0.8911ms | 0.7402ms | 1.3509 KOps/s | 1.3485 KOps/s | |
test_gae_speed[vec_generalized_advantage_estimate-False-1-512] | 0.7539ms | 0.6968ms | 1.4352 KOps/s | 1.4428 KOps/s | |
test_gae_speed[vec_generalized_advantage_estimate-True-32-512] | 1.5629ms | 1.4862ms | 672.8390 Ops/s | 670.6397 Ops/s | |
test_gae_speed[vec_generalized_advantage_estimate-False-32-512] | 0.9792ms | 0.7262ms | 1.3771 KOps/s | 1.3884 KOps/s | |
test_dqn_speed | 7.9806ms | 1.5954ms | 626.8205 Ops/s | 729.6053 Ops/s | |
test_ddpg_speed | 4.8492ms | 3.5638ms | 280.5958 Ops/s | 353.6062 Ops/s | |
test_sac_speed | 10.8326ms | 9.7829ms | 102.2193 Ops/s | 122.8423 Ops/s | |
test_redq_speed | 16.8623ms | 14.9231ms | 67.0102 Ops/s | 79.9370 Ops/s | |
test_redq_deprec_speed | 15.0597ms | 13.5837ms | 73.6174 Ops/s | 86.6342 Ops/s | |
test_td3_speed | 19.9202ms | 10.1746ms | 98.2837 Ops/s | 121.9447 Ops/s | |
test_cql_speed | 33.3472ms | 32.0871ms | 31.1652 Ops/s | 31.1017 Ops/s | |
test_a2c_speed | 8.5552ms | 7.2928ms | 137.1220 Ops/s | 141.7925 Ops/s | |
test_ppo_speed | 9.0670ms | 7.5575ms | 132.3194 Ops/s | 135.1994 Ops/s | |
test_reinforce_speed | 7.6003ms | 6.3184ms | 158.2674 Ops/s | 164.2887 Ops/s | |
test_iql_speed | 29.1471ms | 27.5878ms | 36.2479 Ops/s | 38.4647 Ops/s | |
test_sample_rb[TensorDictReplayBuffer-ListStorage-RandomSampler-4000] | 3.0569ms | 2.5682ms | 389.3836 Ops/s | 396.2351 Ops/s | |
test_sample_rb[TensorDictReplayBuffer-LazyMemmapStorage-RandomSampler-10000] | 3.6479ms | 2.7365ms | 365.4281 Ops/s | 367.9993 Ops/s | |
test_sample_rb[TensorDictReplayBuffer-LazyTensorStorage-RandomSampler-10000] | 0.1316s | 3.1128ms | 321.2511 Ops/s | 327.4765 Ops/s | |
test_sample_rb[TensorDictReplayBuffer-ListStorage-SamplerWithoutReplacement-4000] | 3.0253ms | 2.5820ms | 387.3041 Ops/s | 392.5308 Ops/s | |
test_sample_rb[TensorDictReplayBuffer-LazyMemmapStorage-SamplerWithoutReplacement-10000] | 3.6976ms | 2.7363ms | 365.4576 Ops/s | 323.4995 Ops/s | |
test_sample_rb[TensorDictReplayBuffer-LazyTensorStorage-SamplerWithoutReplacement-10000] | 4.1525ms | 2.7474ms | 363.9827 Ops/s | 366.3377 Ops/s | |
test_sample_rb[TensorDictPrioritizedReplayBuffer-ListStorage-None-4000] | 3.0553ms | 2.5739ms | 388.5099 Ops/s | 392.9060 Ops/s | |
test_sample_rb[TensorDictPrioritizedReplayBuffer-LazyMemmapStorage-None-10000] | 3.6817ms | 2.7508ms | 363.5303 Ops/s | 365.4967 Ops/s | |
test_sample_rb[TensorDictPrioritizedReplayBuffer-LazyTensorStorage-None-10000] | 4.4678ms | 2.7514ms | 363.4459 Ops/s | 365.3626 Ops/s | |
test_iterate_rb[TensorDictReplayBuffer-ListStorage-RandomSampler-4000] | 3.2962ms | 2.5823ms | 387.2456 Ops/s | 390.6897 Ops/s | |
test_iterate_rb[TensorDictReplayBuffer-LazyMemmapStorage-RandomSampler-10000] | 3.8021ms | 2.7406ms | 364.8771 Ops/s | 364.4343 Ops/s | |
test_iterate_rb[TensorDictReplayBuffer-LazyTensorStorage-RandomSampler-10000] | 4.1400ms | 2.7412ms | 364.8099 Ops/s | 364.5611 Ops/s | |
test_iterate_rb[TensorDictReplayBuffer-ListStorage-SamplerWithoutReplacement-4000] | 3.1952ms | 2.5565ms | 391.1581 Ops/s | 391.6125 Ops/s | |
test_iterate_rb[TensorDictReplayBuffer-LazyMemmapStorage-SamplerWithoutReplacement-10000] | 3.7823ms | 2.7370ms | 365.3681 Ops/s | 364.8298 Ops/s | |
test_iterate_rb[TensorDictReplayBuffer-LazyTensorStorage-SamplerWithoutReplacement-10000] | 3.5433ms | 2.7385ms | 365.1661 Ops/s | 366.6265 Ops/s | |
test_iterate_rb[TensorDictPrioritizedReplayBuffer-ListStorage-None-4000] | 2.8898ms | 2.5671ms | 389.5370 Ops/s | 392.0344 Ops/s | |
test_iterate_rb[TensorDictPrioritizedReplayBuffer-LazyMemmapStorage-None-10000] | 0.1331s | 3.1304ms | 319.4441 Ops/s | 367.8268 Ops/s | |
test_iterate_rb[TensorDictPrioritizedReplayBuffer-LazyTensorStorage-None-10000] | 3.6601ms | 2.7487ms | 363.8019 Ops/s | 363.9698 Ops/s | |
test_populate_rb[TensorDictReplayBuffer-ListStorage-RandomSampler-400] | 0.2692s | 23.3351ms | 42.8538 Ops/s | 42.6279 Ops/s | |
test_populate_rb[TensorDictReplayBuffer-LazyMemmapStorage-RandomSampler-400] | 0.1299s | 20.3319ms | 49.1839 Ops/s | 48.9236 Ops/s | |
test_populate_rb[TensorDictReplayBuffer-LazyTensorStorage-RandomSampler-400] | 0.1318s | 22.7712ms | 43.9152 Ops/s | 48.8884 Ops/s | |
test_populate_rb[TensorDictReplayBuffer-ListStorage-SamplerWithoutReplacement-400] | 0.1315s | 20.3955ms | 49.0304 Ops/s | 43.8264 Ops/s | |
test_populate_rb[TensorDictReplayBuffer-LazyMemmapStorage-SamplerWithoutReplacement-400] | 0.1299s | 20.3389ms | 49.1669 Ops/s | 48.8678 Ops/s | |
test_populate_rb[TensorDictReplayBuffer-LazyTensorStorage-SamplerWithoutReplacement-400] | 0.1308s | 20.3759ms | 49.0776 Ops/s | 48.7240 Ops/s | |
test_populate_rb[TensorDictPrioritizedReplayBuffer-ListStorage-None-400] | 0.1300s | 22.7471ms | 43.9617 Ops/s | 43.7433 Ops/s | |
test_populate_rb[TensorDictPrioritizedReplayBuffer-LazyMemmapStorage-None-400] | 0.1300s | 20.3672ms | 49.0985 Ops/s | 48.6855 Ops/s | |
test_populate_rb[TensorDictPrioritizedReplayBuffer-LazyTensorStorage-None-400] | 0.1314s | 20.3736ms | 49.0832 Ops/s | 48.8280 Ops/s |
Was this supposed to solve #1576 and #1613? Because with the script from #1576 i still get Traceback (most recent call last):
File "/Users/Matteo/PycharmProjects/BenchMARL/benchmarl/prova.py", line 15, in <module>
loss_1 = DQNLoss(value_network=model, action_space="one_hot")
File "/Users/Matteo/PycharmProjects/torchrl/torchrl/objectives/dqn.py", line 182, in __init__
self.convert_to_functional(
File "/Users/Matteo/PycharmProjects/torchrl/torchrl/objectives/common.py", line 294, in convert_to_functional
self.__dict__[module_name] = deepcopy(module)
File "/opt/homebrew/Caskroom/miniforge/base/envs/torchrl/lib/python3.9/copy.py", line 172, in deepcopy
y = _reconstruct(x, memo, *rv)
File "/opt/homebrew/Caskroom/miniforge/base/envs/torchrl/lib/python3.9/copy.py", line 270, in _reconstruct
state = deepcopy(state, memo)
File "/opt/homebrew/Caskroom/miniforge/base/envs/torchrl/lib/python3.9/copy.py", line 146, in deepcopy
y = copier(x, memo)
File "/opt/homebrew/Caskroom/miniforge/base/envs/torchrl/lib/python3.9/copy.py", line 230, in _deepcopy_dict
y[deepcopy(key, memo)] = deepcopy(value, memo)
File "/opt/homebrew/Caskroom/miniforge/base/envs/torchrl/lib/python3.9/copy.py", line 172, in deepcopy
y = _reconstruct(x, memo, *rv)
File "/opt/homebrew/Caskroom/miniforge/base/envs/torchrl/lib/python3.9/copy.py", line 296, in _reconstruct
value = deepcopy(value, memo)
File "/opt/homebrew/Caskroom/miniforge/base/envs/torchrl/lib/python3.9/copy.py", line 172, in deepcopy
y = _reconstruct(x, memo, *rv)
File "/opt/homebrew/Caskroom/miniforge/base/envs/torchrl/lib/python3.9/copy.py", line 270, in _reconstruct
state = deepcopy(state, memo)
File "/opt/homebrew/Caskroom/miniforge/base/envs/torchrl/lib/python3.9/copy.py", line 146, in deepcopy
y = copier(x, memo)
File "/opt/homebrew/Caskroom/miniforge/base/envs/torchrl/lib/python3.9/copy.py", line 230, in _deepcopy_dict
y[deepcopy(key, memo)] = deepcopy(value, memo)
File "/opt/homebrew/Caskroom/miniforge/base/envs/torchrl/lib/python3.9/copy.py", line 172, in deepcopy
y = _reconstruct(x, memo, *rv)
File "/opt/homebrew/Caskroom/miniforge/base/envs/torchrl/lib/python3.9/copy.py", line 296, in _reconstruct
value = deepcopy(value, memo)
File "/opt/homebrew/Caskroom/miniforge/base/envs/torchrl/lib/python3.9/copy.py", line 153, in deepcopy
y = copier(memo)
File "/opt/homebrew/Caskroom/miniforge/base/envs/torchrl/lib/python3.9/site-packages/torch_geometric/nn/dense/linear.py", line 115, in __deepcopy__
out.weight = copy.deepcopy(self.weight, memo)
File "/opt/homebrew/Caskroom/miniforge/base/envs/torchrl/lib/python3.9/site-packages/torch/nn/modules/module.py", line 1715, in __setattr__
raise TypeError(f"cannot assign '{torch.typename(value)}' as parameter '{name}' "
TypeError: cannot assign 'torch.meta.FloatTensor' as parameter 'weight' (torch.nn.Parameter or None expected) Also #1593 is still present |
Is this on main or on a previous version of that branch (cannot judge based on the error stack)? Edit |
It is on main, can you not reproduce with the script in #1576 ? |
Refactors functional calls in losses to
The main advantage is that it does not require any modification of the module anymore, which will for instance solve #1613.
cc @matteobettini @skandermoalla @albertbou92 @BY571