Skip to content
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

[Feature] adding tensor classes annotation for loss functions #1905

Open
wants to merge 28 commits into
base: main
Choose a base branch
from

review changes

9b5f4e6
Select commit
Loading
Failed to load commit list.
Open

[Feature] adding tensor classes annotation for loss functions #1905

review changes
9b5f4e6
Select commit
Loading
Failed to load commit list.
PyTorch Bot / Dr.CI completed Mar 18, 2024 in 0s

Dr.CI classification results

{"FAILED":[{"workflowId":8331204279,"id":22797549905,"runnerName":"GitHub Actions 323","authorEmail":"[email protected]","name":"Continuous Benchmark (PR) / CPU Pytest benchmark","jobName":"CPU Pytest benchmark","conclusion":"failure","completed_at":"2024-03-18T17:49:45Z","html_url":"https://github.com/pytorch/rl/actions/runs/8331204279/job/22797549905","head_branch":"tensorclass-losses","pr_number":1905,"head_sha":"9b5f4e64ac273260c612c153018c728c5a7817a1","failure_captures":["Workflow failed! Resource not accessible by integration"],"failure_lines":["##[error]Workflow failed! Resource not accessible by integration"],"failure_context":[],"time":"2024-03-18T17:49:49.587190Z"},{"workflowId":8331204279,"id":22797549063,"runnerName":"i-0a935ca348c64e314","authorEmail":"[email protected]","name":"Continuous Benchmark (PR) / GPU Pytest benchmark","jobName":"GPU Pytest benchmark","conclusion":"failure","completed_at":"2024-03-18T17:52:59Z","html_url":"https://github.com/pytorch/rl/actions/runs/8331204279/job/22797549063","head_branch":"tensorclass-losses","pr_number":1905,"head_sha":"9b5f4e64ac273260c612c153018c728c5a7817a1","failure_captures":["Workflow failed! Resource not accessible by integration"],"failure_lines":["##[error]Workflow failed! Resource not accessible by integration"],"failure_context":[],"time":"2024-03-18T17:53:05.579999Z"},{"workflowId":8331204333,"id":22797551054,"runnerName":"i-00d9b13ebd74f8a55","authorEmail":"[email protected]","name":"Habitat Tests on Linux / tests (3.9, 11.6) / linux-job","jobName":"tests (3.9, 11.6) / linux-job","conclusion":"failure","completed_at":"2024-03-18T17:54:31Z","html_url":"https://github.com/pytorch/rl/actions/runs/8331204333/job/22797551054","head_branch":"tensorclass-losses","pr_number":1905,"head_sha":"9b5f4e64ac273260c612c153018c728c5a7817a1","failure_captures":["RuntimeError: Command docker exec -t b6e60aa69af5dedf42f02bc6f5f9da53457d6e9f3602e70ed5117ff208b4a29a /exec failed with exit code 139"],"failure_lines":["RuntimeError: Command docker exec -t b6e60aa69af5dedf42f02bc6f5f9da53457d6e9f3602e70ed5117ff208b4a29a /exec failed with exit code 139"],"failure_context":["+ bash /pytorch/rl/.github/unittest/linux_libs/scripts_habitat/run_test.sh","+ bash /pytorch/rl/.github/unittest/linux_libs/scripts_habitat/install.sh","+ bash /pytorch/rl/.github/unittest/linux_libs/scripts_habitat/setup_env.sh","+ cp /pytorch/rl/.github/unittest/linux_libs/scripts_habitat/10_nvidia.json /usr/share/glvnd/egl_vendor.d/10_nvidia.json","+ this_dir=/pytorch/rl/.github/unittest/linux_libs/scripts_habitat","++ pwd","++ cd .github/unittest/linux_libs/scripts_habitat","+++ dirname .github/unittest/linux_libs/scripts_habitat/run_all.sh","+ apt-get dist-upgrade -y","+ apt-get install -y g++ gcc","+ apt-get install -y libglvnd0 libgl1 libglx0 libegl1 libgles2","+ apt-get install -y libglfw3 libgl1-mesa-glx libosmesa6 libglew-dev"],"time":"2024-03-18T17:54:35.676651Z"},{"workflowId":8331204338,"id":22797552502,"runnerName":"i-0810d2a5344f3a236","authorEmail":"[email protected]","name":"Unit-tests on Linux / tests-cpu (3.10) / linux-job","jobName":"tests-cpu (3.10) / linux-job","conclusion":"failure","completed_at":"2024-03-18T18:05:39Z","html_url":"https://github.com/pytorch/rl/actions/runs/8331204338/job/22797552502","head_branch":"tensorclass-losses","pr_number":1905,"head_sha":"9b5f4e64ac273260c612c153018c728c5a7817a1","failure_captures":["test/test_cost.py::TestDQN::test_distributional_dqn_reduction[sum-9]"],"failure_lines":["FAILED test/test_cost.py::TestDQN::test_distributional_dqn_reduction[sum-9] - TypeError: DistributionalDQNLoss.init() got an unexpected keyword argument 'reduction'"],"failure_context":["+ python .github/unittest/helpers/coverage_run_parallel.py -m pytest test --instafail --durations 200 -vv --capture no --ignore test/test_rlhf.py --ignore test/test_distributed.py --timeout=120 --mp_fork_if_no_cuda","+ '[' cpu '!=' cpu ']'","+ pytest test/smoke_test_deps.py -v --durations 200 -k 'test_gym or test_dm_control_pixels or test_dm_control or test_tb'","+ pytest test/smoke_test.py -v --durations 200","+ BATCHED_PIPE_TIMEOUT=60","+ export BATCHED_PIPE_TIMEOUT=60","+ MAX_IDLE_COUNT=100","+ export MAX_IDLE_COUNT=100","+ CKPT_BACKEND=torch","+ export CKPT_BACKEND=torch","+ MKL_THREADING_LAYER=GNU","+ export MKL_THREADING_LAYER=GNU"],"time":"2024-03-18T18:05:45.676892Z"},{"workflowId":8331204338,"id":22797553681,"runnerName":"i-0b6503c61c514d4b5","authorEmail":"[email protected]","name":"Unit-tests on Linux / tests-cpu (3.11) / linux-job","jobName":"tests-cpu (3.11) / linux-job","conclusion":"failure","completed_at":"2024-03-18T18:05:16Z","html_url":"https://github.com/pytorch/rl/actions/runs/8331204338/job/22797553681","head_branch":"tensorclass-losses","pr_number":1905,"head_sha":"9b5f4e64ac273260c612c153018c728c5a7817a1","failure_captures":["test/test_cost.py::TestDQN::test_distributional_dqn_reduction[sum-9]"],"failure_lines":["FAILED test/test_cost.py::TestDQN::test_distributional_dqn_reduction[sum-9] - TypeError: DistributionalDQNLoss.init() got an unexpected keyword argument 'reduction'"],"failure_context":["+ python .github/unittest/helpers/coverage_run_parallel.py -m pytest test --instafail --durations 200 -vv --capture no --ignore test/test_rlhf.py --ignore test/test_distributed.py --timeout=120 --mp_fork_if_no_cuda","+ '[' cpu '!=' cpu ']'","+ pytest test/smoke_test_deps.py -v --durations 200 -k 'test_gym or test_dm_control_pixels or test_dm_control or test_tb'","+ pytest test/smoke_test.py -v --durations 200","+ BATCHED_PIPE_TIMEOUT=60","+ export BATCHED_PIPE_TIMEOUT=60","+ MAX_IDLE_COUNT=100","+ export MAX_IDLE_COUNT=100","+ CKPT_BACKEND=torch","+ export CKPT_BACKEND=torch","+ MKL_THREADING_LAYER=GNU","+ export MKL_THREADING_LAYER=GNU"],"time":"2024-03-18T18:05:20.638841Z"},{"workflowId":8331204338,"id":22797554213,"runnerName":"i-0047a8ba0af2cb510","authorEmail":"[email protected]","name":"Unit-tests on Linux / tests-cpu (3.8) / linux-job","jobName":"tests-cpu (3.8) / linux-job","conclusion":"failure","completed_at":"2024-03-18T18:06:21Z","html_url":"https://github.com/pytorch/rl/actions/runs/8331204338/job/22797554213","head_branch":"tensorclass-losses","pr_number":1905,"head_sha":"9b5f4e64ac273260c612c153018c728c5a7817a1","failure_captures":["test/test_cost.py::TestDQN::test_distributional_dqn_reduction[sum-9]"],"failure_lines":["FAILED test/test_cost.py::TestDQN::test_distributional_dqn_reduction[sum-9] - TypeError: init() got an unexpected keyword argument 'reduction'"],"failure_context":["+ python .github/unittest/helpers/coverage_run_parallel.py -m pytest test --instafail --durations 200 -vv --capture no --ignore test/test_rlhf.py --ignore test/test_distributed.py --timeout=120 --mp_fork_if_no_cuda","+ '[' cpu '!=' cpu ']'","+ pytest test/smoke_test_deps.py -v --durations 200 -k 'test_gym or test_dm_control_pixels or test_dm_control or test_tb'","+ pytest test/smoke_test.py -v --durations 200","+ BATCHED_PIPE_TIMEOUT=60","+ export BATCHED_PIPE_TIMEOUT=60","+ MAX_IDLE_COUNT=100","+ export MAX_IDLE_COUNT=100","+ CKPT_BACKEND=torch","+ export CKPT_BACKEND=torch","+ MKL_THREADING_LAYER=GNU","+ export MKL_THREADING_LAYER=GNU"],"time":"2024-03-18T18:06:27.638966Z"},{"workflowId":8331204338,"id":22797555245,"runnerName":"i-09679f918e264947f","authorEmail":"[email protected]","name":"Unit-tests on Linux / tests-cpu (3.9) / linux-job","jobName":"tests-cpu (3.9) / linux-job","conclusion":"failure","completed_at":"2024-03-18T18:06:28Z","html_url":"https://github.com/pytorch/rl/actions/runs/8331204338/job/22797555245","head_branch":"tensorclass-losses","pr_number":1905,"head_sha":"9b5f4e64ac273260c612c153018c728c5a7817a1","failure_captures":["test/test_cost.py::TestDQN::test_distributional_dqn_reduction[sum-9]"],"failure_lines":["FAILED test/test_cost.py::TestDQN::test_distributional_dqn_reduction[sum-9] - TypeError: init() got an unexpected keyword argument 'reduction'"],"failure_context":["+ python .github/unittest/helpers/coverage_run_parallel.py -m pytest test --instafail --durations 200 -vv --capture no --ignore test/test_rlhf.py --ignore test/test_distributed.py --timeout=120 --mp_fork_if_no_cuda","+ '[' cpu '!=' cpu ']'","+ pytest test/smoke_test_deps.py -v --durations 200 -k 'test_gym or test_dm_control_pixels or test_dm_control or test_tb'","+ pytest test/smoke_test.py -v --durations 200","+ BATCHED_PIPE_TIMEOUT=60","+ export BATCHED_PIPE_TIMEOUT=60","+ MAX_IDLE_COUNT=100","+ export MAX_IDLE_COUNT=100","+ CKPT_BACKEND=torch","+ export CKPT_BACKEND=torch","+ MKL_THREADING_LAYER=GNU","+ export MKL_THREADING_LAYER=GNU"],"time":"2024-03-18T18:06:32.676873Z"},{"workflowId":8331204338,"id":22797556373,"runnerName":"i-02e291dbbfd7a3f5a","authorEmail":"[email protected]","name":"Unit-tests on Linux / tests-gpu (3.10, 12.1) / linux-job","jobName":"tests-gpu (3.10, 12.1) / linux-job","conclusion":"failure","completed_at":"2024-03-18T18:21:02Z","html_url":"https://github.com/pytorch/rl/actions/runs/8331204338/job/22797556373","head_branch":"tensorclass-losses","pr_number":1905,"head_sha":"9b5f4e64ac273260c612c153018c728c5a7817a1","failure_captures":["test/test_cost.py::TestDQN::test_distributional_dqn_reduction[sum-9]"],"failure_lines":["FAILED test/test_cost.py::TestDQN::test_distributional_dqn_reduction[sum-9] - TypeError: DistributionalDQNLoss.init() got an unexpected keyword argument 'reduction'"],"failure_context":["+ python .github/unittest/helpers/coverage_run_parallel.py -m pytest test --instafail --durations 200 -vv --capture no --ignore test/test_rlhf.py --timeout=120 --mp_fork_if_no_cuda","+ '[' cu121 '!=' cpu ']'","+ pytest test/smoke_test_deps.py -v --durations 200 -k 'test_gym or test_dm_control_pixels or test_dm_control or test_tb'","+ pytest test/smoke_test.py -v --durations 200","+ BATCHED_PIPE_TIMEOUT=60","+ export BATCHED_PIPE_TIMEOUT=60","+ MAX_IDLE_COUNT=100","+ export MAX_IDLE_COUNT=100","+ CKPT_BACKEND=torch","+ export CKPT_BACKEND=torch","+ MKL_THREADING_LAYER=GNU","+ export MKL_THREADING_LAYER=GNU"],"time":"2024-03-18T18:21:08.556710Z"},{"workflowId":8331204338,"id":22797557028,"runnerName":"i-0c0517c079ae2c2c7","authorEmail":"[email protected]","name":"Unit-tests on Linux / tests-olddeps (3.8, 11.6) / linux-job","jobName":"tests-olddeps (3.8, 11.6) / linux-job","conclusion":"failure","completed_at":"2024-03-18T18:13:10Z","html_url":"https://github.com/pytorch/rl/actions/runs/8331204338/job/22797557028","head_branch":"tensorclass-losses","pr_number":1905,"head_sha":"9b5f4e64ac273260c612c153018c728c5a7817a1","failure_captures":["test/test_cost.py::TestDQN::test_distributional_dqn_reduction[sum-9]"],"failure_lines":["FAILED test/test_cost.py::TestDQN::test_distributional_dqn_reduction[sum-9] - TypeError: init() got an unexpected keyword argument 'reduction'"],"failure_context":["+ bash .github/unittest/linux_olddeps/scripts_gym_0_13/batch_scripts.sh","+ bash .github/unittest/linux_olddeps/scripts_gym_0_13/setup_env.sh","+ TF_CPP_MIN_LOG_LEVEL=0","+ export TF_CPP_MIN_LOG_LEVEL=0","+ TORCH_VERSION=nightly","+ export TORCH_VERSION=nightly","+ RELEASE=0","+ export RELEASE=0","+ [[ refs/pull/1905/merge =~ release/* ]]","+ TAR_OPTIONS=--no-same-owner","+ export TAR_OPTIONS=--no-same-owner","+ CU_VERSION=cu116"],"time":"2024-03-18T18:13:15.665270Z"},{"workflowId":8331204338,"id":22797557694,"runnerName":"i-04c463df65ffe601f","authorEmail":"[email protected]","name":"Unit-tests on Linux / tests-optdeps (3.10, 12.1) / linux-job","jobName":"tests-optdeps (3.10, 12.1) / linux-job","conclusion":"failure","completed_at":"2024-03-18T18:05:22Z","html_url":"https://github.com/pytorch/rl/actions/runs/8331204338/job/22797557694","head_branch":"tensorclass-losses","pr_number":1905,"head_sha":"9b5f4e64ac273260c612c153018c728c5a7817a1","failure_captures":["test/test_cost.py::TestDQN::test_distributional_dqn_reduction[sum-9]"],"failure_lines":["FAILED test/test_cost.py::TestDQN::test_distributional_dqn_reduction[sum-9] - TypeError: DistributionalDQNLoss.init() got an unexpected keyword argument 'reduction'"],"failure_context":["+ bash /pytorch/rl/.github/unittest/linux_optdeps/scripts/run_test.sh","+ bash /pytorch/rl/.github/unittest/linux_optdeps/scripts/install.sh","+ bash /pytorch/rl/.github/unittest/linux_optdeps/scripts/setup_env.sh","+ cp /pytorch/rl/.github/unittest/linux_optdeps/scripts/10_nvidia.json /usr/share/glvnd/egl_vendor.d/10_nvidia.json","+ [[ linux-gnu != \d\a\r\w\i\n* ]]","+ this_dir=/pytorch/rl/.github/unittest/linux_optdeps/scripts","++ pwd","++ cd .github/unittest/linux_optdeps/scripts","+++ dirname .github/unittest/linux_optdeps/scripts/run_all.sh","+ apt-get install -y g++ gcc","+ '[' cu121 == cpu ']'","+ apt-get install -y libglvnd0 libgl1 libglx0 libegl1 libgles2"],"time":"2024-03-18T18:05:28.580783Z"},{"workflowId":8331204338,"id":22797558326,"runnerName":"i-0fe6f90ef773a9465","authorEmail":"[email protected]","name":"Unit-tests on Linux / tests-stable-gpu (3.10, 11.8) / linux-job","jobName":"tests-stable-gpu (3.10, 11.8) / linux-job","conclusion":"failure","completed_at":"2024-03-18T18:21:37Z","html_url":"https://github.com/pytorch/rl/actions/runs/8331204338/job/22797558326","head_branch":"tensorclass-losses","pr_number":1905,"head_sha":"9b5f4e64ac273260c612c153018c728c5a7817a1","failure_captures":["test/test_cost.py::TestDQN::test_distributional_dqn_reduction[sum-9]"],"failure_lines":["FAILED test/test_cost.py::TestDQN::test_distributional_dqn_reduction[sum-9] - TypeError: DistributionalDQNLoss.init() got an unexpected keyword argument 'reduction'"],"failure_context":["+ python .github/unittest/helpers/coverage_run_parallel.py -m pytest test --instafail --durations 200 -vv --capture no --ignore test/test_rlhf.py --timeout=120 --mp_fork_if_no_cuda","+ '[' cu118 '!=' cpu ']'","+ pytest test/smoke_test_deps.py -v --durations 200 -k 'test_gym or test_dm_control_pixels or test_dm_control or test_tb'","+ pytest test/smoke_test.py -v --durations 200","+ BATCHED_PIPE_TIMEOUT=60","+ export BATCHED_PIPE_TIMEOUT=60","+ MAX_IDLE_COUNT=100","+ export MAX_IDLE_COUNT=100","+ CKPT_BACKEND=torch","+ export CKPT_BACKEND=torch","+ MKL_THREADING_LAYER=GNU","+ export MKL_THREADING_LAYER=GNU"],"time":"2024-03-18T18:21:42.647000Z"},{"workflowId":8331204335,"id":22797552009,"runnerName":"GitHub Actions 490","authorEmail":"[email protected]","name":"Unit-tests on MacOS CPU / tests (3.11) / macos-job","jobName":"tests (3.11) / macos-job","conclusion":"failure","completed_at":"2024-03-18T18:17:12Z","html_url":"https://github.com/pytorch/rl/actions/runs/8331204335/job/22797552009","head_branch":"tensorclass-losses","pr_number":1905,"head_sha":"9b5f4e64ac273260c612c153018c728c5a7817a1","failure_captures":["test/test_cost.py::TestDQN::test_distributional_dqn_reduction[sum-9]"],"failure_lines":["FAILED test/test_cost.py::TestDQN::test_distributional_dqn_reduction[sum-9] - TypeError: DistributionalDQNLoss.init() got an unexpected keyword argument 'reduction'"],"failure_context":["+ python .github/unittest/helpers/coverage_run_parallel.py -m pytest test --instafail --durations 200 -vv --capture no --ignore test/test_rlhf.py --ignore test/test_distributed.py --timeout=120 --mp_fork_if_no_cuda","+ '[' cpu '!=' cpu ']'","+ pytest test/smoke_test_deps.py -v --durations 200 -k 'test_gym or test_dm_control_pixels or test_dm_control or test_tb'","+ pytest test/smoke_test.py -v --durations 200","+ BATCHED_PIPE_TIMEOUT=60","+ export BATCHED_PIPE_TIMEOUT=60","+ MAX_IDLE_COUNT=100","+ export MAX_IDLE_COUNT=100","+ CKPT_BACKEND=torch","+ export CKPT_BACKEND=torch","+ MKL_THREADING_LAYER=GNU","+ export MKL_THREADING_LAYER=GNU"],"time":"2024-03-18T18:17:24.584714Z"},{"workflowId":8331204335,"id":22797552879,"runnerName":"GitHub Actions 256","authorEmail":"[email protected]","name":"Unit-tests on MacOS CPU / tests (3.8) / macos-job","jobName":"tests (3.8) / macos-job","conclusion":"failure","completed_at":"2024-03-18T18:17:25Z","html_url":"https://github.com/pytorch/rl/actions/runs/8331204335/job/22797552879","head_branch":"tensorclass-losses","pr_number":1905,"head_sha":"9b5f4e64ac273260c612c153018c728c5a7817a1","failure_captures":["test/test_cost.py::TestDQN::test_distributional_dqn_reduction[sum-9]"],"failure_lines":["FAILED test/test_cost.py::TestDQN::test_distributional_dqn_reduction[sum-9] - TypeError: init() got an unexpected keyword argument 'reduction'"],"failure_context":["+ python .github/unittest/helpers/coverage_run_parallel.py -m pytest test --instafail --durations 200 -vv --capture no --ignore test/test_rlhf.py --ignore test/test_distributed.py --timeout=120 --mp_fork_if_no_cuda","+ '[' cpu '!=' cpu ']'","+ pytest test/smoke_test_deps.py -v --durations 200 -k 'test_gym or test_dm_control_pixels or test_dm_control or test_tb'","+ pytest test/smoke_test.py -v --durations 200","+ BATCHED_PIPE_TIMEOUT=60","+ export BATCHED_PIPE_TIMEOUT=60","+ MAX_IDLE_COUNT=100","+ export MAX_IDLE_COUNT=100","+ CKPT_BACKEND=torch","+ export CKPT_BACKEND=torch","+ MKL_THREADING_LAYER=GNU","+ export MKL_THREADING_LAYER=GNU"],"time":"2024-03-18T18:17:37.651025Z"},{"workflowId":8331204320,"id":22797550332,"runnerName":"i-06bad8e91cd73a10c","authorEmail":"[email protected]","name":"Unit-tests on Windows / unittests-cpu / windows-job","jobName":"unittests-cpu / windows-job","conclusion":"failure","completed_at":"2024-03-18T18:52:51Z","html_url":"https://github.com/pytorch/rl/actions/runs/8331204320/job/22797550332","head_branch":"tensorclass-losses","pr_number":1905,"head_sha":"9b5f4e64ac273260c612c153018c728c5a7817a1","failure_captures":["test/test_cost.py::TestDQN::test_distributional_dqn_reduction[sum-9]"],"failure_lines":["FAILED test/test_cost.py::TestDQN::test_distributional_dqn_reduction[sum-9] - TypeError: init() got an unexpected keyword argument 'reduction'"],"failure_context":["+ pytest --junitxml=test-results/junit.xml -v --durations 200 --ignore test/test_distributed.py --ignore test/test_rlhf.py","+ python -m torch.utils.collect_env","+ LAZY_LEGACY_OP=False","+ export LAZY_LEGACY_OP=False","+ BATCHED_PIPE_TIMEOUT=60","+ export BATCHED_PIPE_TIMEOUT=60","+ MAX_IDLE_COUNT=60","+ export MAX_IDLE_COUNT=60","+ CKPT_BACKEND=torch","+ export CKPT_BACKEND=torch","++ [[ cpu != \c\p\u ]]","++ [[ 3 -eq 5 ]]"],"time":"2024-03-18T18:52:56.575304Z"}],"FLAKY":[],"BROKEN_TRUNK":[],"UNSTABLE":[]}