A modular, primitive-first, python-first PyTorch library for Reinforcement Learning.
This report summarizes scanner evidence for pytorch/rl, a Python project with 3,595 GitHub stars. SynthScan examined 587,908 lines of code across 1365 source files, recording 10987 pattern matches distributed across 26 syntactic categories. The legacy adjusted pattern signal is 24.4 (Elevated pattern signal); it is not an authorship estimate.
Use the findings to ask whether maintainers can explain intent, verify dependencies, simplify unnecessary scaffolding, and focus review effort. Risk Payload v1 adds ownership, supply-chain, over-engineering, and review-effort vectors when available. These are prompts for human verification, not probabilities, security findings, or measured maintenance costs.
Use each vector to guide manual verification of the underlying findings.
Can maintainers explain intent, assumptions, and trade-offs? 6339 finding(s).
Are imports declared and package/API names verified? 2538 finding(s).
Are wrappers, guards, and repeated structures necessary? 6631 finding(s).
Which changes need focused human review? 10987 finding(s).
This chart tracks the legacy adjusted pattern score across scan runs. Changes can reflect source changes, scan coverage, or detector/scoring versions; they do not measure AI adoption or prove that a team refactored code. Compare runs only when their scoring versions are compatible. The dashed line tracks the raw pattern-hit count.
Groups findings by configured severity weight. Severity is not a confidence estimate, security rating, or proof that a package is missing. Verify imports against the project's manifests and inspect each finding in its local design context.
This horizontal bar chart shows where configured pattern scores accumulate across directories. Treat the bars as locations to inspect, not as evidence of authorship or code quality. Use the file-level findings to decide whether a directory needs a focused ownership, dependency, complexity, or review check.
The scanner identified 10987 distinct pattern matches across 26 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a detector match to inspect in context. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.
Reading the findings table: The Severity column indicates the configured finding weight (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — legacy comment-context matches receive a ×1.5 score weight. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier under the legacy scoring model.
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | setup.py | 145 | def _check_and_clean_stale_builds(): | CODE |
| LOW | AGENTS.md | 156 | def test_something_cuda_specific(): | CODE |
| LOW | CLAUDE.md | 156 | def test_something_cuda_specific(): | CODE |
| LOW | test/test_configs.py | 188 | def _make_resume_test_trainer( | CODE |
| LOW | test/test_configs.py | 451 | def test_wrapped_class_kwargs_have_config_fields(self, config_name): | CODE |
| LOW | test/test_configs.py | 470 | def test_wrapped_class_kwarg_defaults_match_config(self, config_name): | CODE |
| LOW | test/test_configs.py | 524 | def test_vmas_env_config_instantiation(self): | CODE |
| LOW | test/test_configs.py | 560 | def test_async_env_shared_exchange_config(self): | CODE |
| LOW | test/test_configs.py | 585 | def test_batched_env_config_omegaconf_schema(self): | CODE |
| LOW | test/test_configs.py | 609 | def test_batched_env_config_validation(self, field, value): | CODE |
| LOW | test/test_configs.py | 640 | def test_round_robin_writer_config(self): | CODE |
| LOW | test/test_configs.py | 664 | def test_random_sampler_config(self): | CODE |
| LOW | test/test_configs.py | 699 | def test_tensor_storage_config(self): | CODE |
| LOW | test/test_configs.py | 720 | def test_tensordict_replay_buffer_config(self): | CODE |
| LOW | test/test_configs.py | 761 | def test_replay_buffer_config(self): | CODE |
| LOW | test/test_configs.py | 815 | def test_tensordict_replay_buffer_config_optional_fields(self): | CODE |
| LOW | test/test_configs.py | 832 | def test_writer_ensemble_config(self): | CODE |
| LOW | test/test_configs.py | 851 | def test_tensor_dict_max_value_writer_config(self): | CODE |
| LOW | test/test_configs.py | 868 | def test_tensor_dict_round_robin_writer_config(self): | CODE |
| LOW | test/test_configs.py | 887 | def test_immutable_dataset_writer_config(self): | CODE |
| LOW | test/test_configs.py | 929 | def test_sampler_ensemble_config(self, strategy, expected_members): | CODE |
| LOW | test/test_configs.py | 949 | def test_sampler_ensemble_config_member_samplers(self): | CODE |
| LOW | test/test_configs.py | 968 | def test_sampler_ensemble_config_conflicting_strategy(self): | CODE |
| LOW | test/test_configs.py | 985 | def test_prioritized_slice_sampler_config(self): | CODE |
| LOW | test/test_configs.py | 1039 | def test_slice_sampler_without_replacement_config(self): | CODE |
| LOW | test/test_configs.py | 1076 | def test_slice_sampler_config(self): | CODE |
| LOW | test/test_configs.py | 1114 | def test_slice_sampler_structured_config_instantiation(self): | CODE |
| LOW | test/test_configs.py | 1131 | def test_streaming_slice_sampler_config(self): | CODE |
| LOW | test/test_configs.py | 1144 | def test_prioritized_sampler_config(self): | CODE |
| LOW | test/test_configs.py | 1169 | def test_sampler_without_replacement_config(self): | CODE |
| LOW | test/test_configs.py | 1188 | def test_storage_ensemble_writer_config(self): | CODE |
| LOW | test/test_configs.py | 1209 | def test_lazy_stack_storage_config(self): | CODE |
| LOW | test/test_configs.py | 1227 | def test_storage_ensemble_config(self): | CODE |
| LOW | test/test_configs.py | 1244 | def test_lazy_memmap_storage_config(self): | CODE |
| LOW | test/test_configs.py | 1265 | def test_lazy_tensor_storage_config(self): | CODE |
| LOW | test/test_configs.py | 1294 | def test_complex_replay_buffer_configuration(self): | CODE |
| LOW | test/test_configs.py | 1357 | def test_controller_deployment_from_config(self): | CODE |
| LOW | test/test_configs.py | 1726 | def test_rssm_state_estimator_nested_config(self): | CODE |
| LOW | test/test_configs.py | 1832 | def test_tensor_dict_module_config(self): | CODE |
| LOW | test/test_configs.py | 1854 | def test_tanh_normal_model_config(self): | CODE |
| LOW | test/test_configs.py | 1888 | def test_tanh_normal_model_config_defaults(self): | CODE |
| LOW | test/test_configs.py | 1909 | def test_tanh_normal_model_config_bounds(self, bounds): | CODE |
| LOW | test/test_configs.py | 1936 | def test_tensordict_sequential_config(self): | CODE |
| LOW | test/test_configs.py | 2066 | def test_qmixer_network_config(self): | CODE |
| LOW | test/test_configs.py | 2080 | def test_additive_gaussian_module_config(self): | CODE |
| LOW | test/test_configs.py | 2120 | def test_generic_collector_backend_fields(self): | CODE |
| LOW | test/test_configs.py | 2143 | def test_multi_collector_config_without_policy(self, collector): | CODE |
| LOW | test/test_configs.py | 2247 | def test_collector_auto_configures_exploration_modules(self, factory, collector): | CODE |
| LOW | test/test_configs.py | 2337 | def test_gae_config_instantiates_nested_group_key(self): | CODE |
| LOW | test/test_configs.py | 2356 | def test_gae_config_average_gae_default_matches_gae(self): | CODE |
| LOW | test/test_configs.py | 2466 | def test_ppo_loss_config_delay_actor(self, loss_type): | CODE |
| LOW | test/test_configs.py | 2685 | def test_reinforce_loss_config(self): | CODE |
| LOW | test/test_configs.py | 2769 | def test_wandb_logger_config_instantiation(self, monkeypatch, tmp_path): | CODE |
| LOW | test/test_configs.py | 2798 | def test_trackio_logger_config(self): | CODE |
| LOW | test/test_configs.py | 2817 | def test_trackio_logger_config_instantiation(self, monkeypatch): | CODE |
| LOW | test/test_configs.py | 2869 | def test_checkpoint_config_parity(self, config_name, field_name): | CODE |
| LOW | test/test_configs.py | 3004 | def test_nested_key_normalization_for_hydra_lists(self): | CODE |
| LOW | test/test_configs.py | 3060 | def test_ppo_telemetry_config_and_factory_parity(self): | CODE |
| LOW | test/test_configs.py | 3137 | def test_reinforce_trainer_config(self): | CODE |
| LOW | test/test_configs.py | 3167 | def test_ppo_trainer_config_optional_fields(self): | CODE |
| 4169 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM⚡ | test/test_inference_server.py | 196 | # ============================================================================= | COMMENT |
| MEDIUM⚡ | test/test_inference_server.py | 198 | # ============================================================================= | COMMENT |
| MEDIUM⚡ | test/test_inference_server.py | 2498 | # ============================================================================= | COMMENT |
| MEDIUM⚡ | test/test_inference_server.py | 2500 | # ============================================================================= | COMMENT |
| MEDIUM⚡ | test/test_inference_server.py | 4863 | # ============================================================================= | COMMENT |
| MEDIUM⚡ | test/test_inference_server.py | 4865 | # ============================================================================= | COMMENT |
| MEDIUM⚡ | test/test_inference_server.py | 4906 | # ============================================================================= | COMMENT |
| MEDIUM⚡ | test/test_inference_server.py | 4908 | # ============================================================================= | COMMENT |
| MEDIUM | test/test_inference_server.py | 103 | # ============================================================================= | COMMENT |
| MEDIUM | test/test_inference_server.py | 105 | # ============================================================================= | COMMENT |
| MEDIUM | test/test_inference_server.py | 1396 | # ============================================================================= | COMMENT |
| MEDIUM | test/test_inference_server.py | 1398 | # ============================================================================= | COMMENT |
| MEDIUM | test/test_inference_server.py | 1497 | # ============================================================================= | COMMENT |
| MEDIUM | test/test_inference_server.py | 1499 | # ============================================================================= | COMMENT |
| MEDIUM | test/test_inference_server.py | 1589 | # ============================================================================= | COMMENT |
| MEDIUM | test/test_inference_server.py | 1591 | # ============================================================================= | COMMENT |
| MEDIUM | test/test_inference_server.py | 2248 | # ============================================================================= | COMMENT |
| MEDIUM | test/test_inference_server.py | 2250 | # ============================================================================= | COMMENT |
| MEDIUM | test/test_inference_server.py | 2438 | # ============================================================================= | COMMENT |
| MEDIUM | test/test_inference_server.py | 2440 | # ============================================================================= | COMMENT |
| MEDIUM | test/test_inference_server.py | 2755 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | test/test_inference_server.py | 2757 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | test/test_inference_server.py | 4749 | # ============================================================================= | COMMENT |
| MEDIUM | test/test_inference_server.py | 4751 | # ============================================================================= | COMMENT |
| MEDIUM⚡ | test/test_collectors.py | 7952 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM⚡ | test/test_collectors.py | 7954 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM⚡ | test/test_collectors.py | 8274 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM⚡ | test/test_collectors.py | 8276 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM⚡ | test/test_collectors.py | 8602 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM⚡ | test/test_collectors.py | 8604 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM⚡ | test/test_collectors.py | 8806 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM⚡ | test/test_collectors.py | 8808 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM⚡ | test/test_collectors.py | 8908 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM⚡ | test/test_collectors.py | 8910 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM⚡ | test/test_collectors.py | 8957 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM⚡ | test/test_collectors.py | 8959 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM⚡ | test/test_collectors.py | 9065 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM⚡ | test/test_collectors.py | 9067 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM⚡ | test/test_collectors.py | 9317 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM⚡ | test/test_collectors.py | 9319 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM | test/test_collectors.py | 7936 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM | test/test_collectors.py | 7938 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM⚡ | test/test_rnd.py | 98 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | test/test_rnd.py | 100 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | test/test_rnd.py | 230 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | test/test_rnd.py | 232 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | test/test_rnd.py | 20 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | test/test_rnd.py | 22 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | test/test_rnd.py | 35 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM | test/test_rnd.py | 37 | # --------------------------------------------------------------------------- | COMMENT |
| MEDIUM⚡ | test/llm/test_wrapper.py | 1630 | # ================================================ | COMMENT |
| MEDIUM⚡ | test/llm/test_wrapper.py | 1632 | # ================================================ | COMMENT |
| MEDIUM⚡ | test/llm/test_wrapper.py | 1708 | # ================================================ | COMMENT |
| MEDIUM⚡ | test/llm/test_wrapper.py | 1710 | # ================================================ | COMMENT |
| MEDIUM⚡ | test/llm/test_wrapper.py | 4160 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM⚡ | test/llm/test_wrapper.py | 4162 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM⚡ | test/llm/test_wrapper.py | 4331 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM⚡ | test/llm/test_wrapper.py | 4333 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM⚡ | test/llm/test_wrapper.py | 4586 | # ------------------------------------------------------------------ | COMMENT |
| MEDIUM⚡ | test/llm/test_wrapper.py | 4588 | # ------------------------------------------------------------------ | COMMENT |
| 928 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | setup.py | 1 | CODE | |
| LOW | test/test_configs.py | 6 | CODE | |
| LOW | test/test_shared.py | 5 | CODE | |
| LOW | test/test_exploration.py | 5 | CODE | |
| LOW | test/smoke_test.py | 5 | CODE | |
| LOW | test/test_utils.py | 5 | CODE | |
| LOW | test/conftest.py | 5 | CODE | |
| LOW | test/opengl_rendering.py | 26 | CODE | |
| LOW | test/opengl_rendering.py | 33 | CODE | |
| LOW | test/opengl_rendering.py | 71 | CODE | |
| LOW | test/test_docstring_args_checker.py | 1 | CODE | |
| LOW | test/test_offline_to_online.py | 5 | CODE | |
| LOW | test/test_custom_envs.py | 5 | CODE | |
| LOW | test/test_inference_server.py | 5 | CODE | |
| LOW | test/test_loggers.py | 5 | CODE | |
| LOW | test/test_rlhf.py | 5 | CODE | |
| LOW | test/test_postprocs.py | 5 | CODE | |
| LOW | test/test_specs.py | 5 | CODE | |
| LOW | test/smoke_test_deps.py | 5 | CODE | |
| LOW | test/smoke_test_deps.py | 33 | CODE | |
| LOW | test/smoke_test_deps.py | 34 | CODE | |
| LOW | test/smoke_test_deps.py | 35 | CODE | |
| LOW | test/smoke_test_deps.py | 36 | CODE | |
| LOW | test/smoke_test_deps.py | 108 | CODE | |
| LOW | test/test_render.py | 5 | CODE | |
| LOW | test/test_distributions.py | 5 | CODE | |
| LOW | test/test_collectors.py | 5 | CODE | |
| LOW | test/test_helpers.py | 5 | CODE | |
| LOW | test/test_distributed.py | 9 | CODE | |
| LOW | test/test_trainer.py | 5 | CODE | |
| LOW | test/test_rnd.py | 5 | CODE | |
| LOW | test/test_checkpoint.py | 5 | CODE | |
| LOW | test/collectors/test_evaluator.py | 5 | CODE | |
| LOW | test/llm/test_vllm.py | 5 | CODE | |
| LOW | test/llm/test_llm_objectives.py | 5 | CODE | |
| LOW | test/llm/test_wrapper.py | 5 | CODE | |
| LOW | test/llm/smoke_test_llm.py | 5 | CODE | |
| LOW | test/llm/test_sglang_updaters.py | 6 | CODE | |
| LOW | test/llm/test_sglang.py | 6 | CODE | |
| LOW | test/llm/test_vllm_plugin.py | 5 | CODE | |
| LOW | test/llm/test_llm_envs.py | 5 | CODE | |
| LOW | test/llm/smoke_test_llm_deps.py | 5 | CODE | |
| LOW | test/llm/test_llm_transforms.py | 6 | CODE | |
| LOW | test/llm/test_llm_collectors.py | 5 | CODE | |
| LOW | test/llm/test_llm_updaters.py | 5 | CODE | |
| LOW | test/llm/test_llm_updaters.py | 30 | CODE | |
| LOW | test/llm/test_data.py | 6 | CODE | |
| LOW | test/llm/libs/test_mlgym.py | 5 | CODE | |
| LOW | test/objectives/test_controllers.py | 6 | CODE | |
| LOW | test/objectives/test_loss_module.py | 6 | CODE | |
| LOW | test/objectives/test_loss_module.py | 79 | CODE | |
| LOW | test/objectives/test_loss_module.py | 79 | CODE | |
| LOW | test/objectives/conftest.py | 5 | CODE | |
| LOW | test/objectives/test_mappo.py | 12 | CODE | |
| LOW | test/objectives/test_cql.py | 6 | CODE | |
| LOW | test/objectives/test_cql.py | 28 | CODE | |
| LOW | test/objectives/test_cql.py | 28 | CODE | |
| LOW | test/objectives/test_cql.py | 28 | CODE | |
| LOW | test/objectives/test_bc.py | 5 | CODE | |
| LOW | test/objectives/_objectives_common.py | 5 | CODE | |
| 2355 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | test/opengl_rendering.py | 98 | except error.GLError: | CODE |
| HIGH | test/test_inference_server.py | 4927 | except Exception: | CODE |
| HIGH | test/test_collectors.py | 5580 | except Exception: | CODE |
| HIGH | test/test_collectors.py | 5611 | except Exception: | CODE |
| HIGH | test/test_distributed.py | 898 | except Exception: | CODE |
| HIGH | test/test_distributed.py | 1784 | except Exception: | CODE |
| HIGH | test/llm/conftest.py | 32 | except ImportError: | CODE |
| HIGH | test/llm/test_wrapper.py | 3543 | except Exception: | CODE |
| HIGH | test/transforms/test_device_transforms.py | 127 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_device_transforms.py | 183 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_device_transforms.py | 328 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_device_transforms.py | 352 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_action_transforms.py | 183 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_action_transforms.py | 193 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_action_transforms.py | 203 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_action_transforms.py | 566 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_action_transforms.py | 586 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_action_transforms.py | 687 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_action_transforms.py | 707 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_action_transforms.py | 3096 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_action_transforms.py | 3116 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_action_transforms.py | 3317 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_action_transforms.py | 3337 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_action_transforms.py | 3593 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_action_transforms.py | 3615 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_action_transforms.py | 3804 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_action_transforms.py | 3816 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_action_transforms.py | 3826 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_action_transforms.py | 3838 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_key_transforms.py | 139 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_key_transforms.py | 165 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_key_transforms.py | 377 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_key_transforms.py | 403 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_key_transforms.py | 614 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_key_transforms.py | 635 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_key_transforms.py | 702 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_key_transforms.py | 719 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_key_transforms.py | 954 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_key_transforms.py | 1135 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_key_transforms.py | 1181 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_key_transforms.py | 1408 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_key_transforms.py | 1440 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_clip_transform.py | 241 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_clip_transform.py | 276 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_encoder_transforms.py | 524 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_encoder_transforms.py | 545 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_observation_transforms.py | 183 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_observation_transforms.py | 210 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_observation_transforms.py | 1123 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_observation_transforms.py | 1141 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_observation_transforms.py | 1332 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_observation_transforms.py | 1352 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_observation_transforms.py | 1409 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_observation_transforms.py | 1435 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_observation_transforms.py | 1685 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_observation_transforms.py | 1707 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_observation_transforms.py | 1816 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_observation_transforms.py | 1846 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_observation_transforms.py | 2407 | except RuntimeError: | CODE |
| HIGH | test/transforms/test_observation_transforms.py | 2427 | except RuntimeError: | CODE |
| 205 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | …ta-implementations/vla_grpo/openvla_oft/train_utils.py | 59 | Find a specific checkpoint file matching a pattern. Args: pretrained_checkpoint: Path to the checkpoin | STRING |
| HIGH | sota-implementations/dreamer/dreamer_utils.py | 85 | Allocate CUDA devices for collectors, reserving cuda:0 for training. Device allocation strategy: - Training alw | STRING |
| HIGH | sota-implementations/grpo/grpo_utils.py | 111 | Creates and configures the training model with LoRA adapters. This function initializes the main training model wit | STRING |
| HIGH | sota-implementations/grpo/grpo_utils.py | 196 | Creates the inference model for fast generation. This function initializes a model server (vLLM or SGLang) for effi | STRING |
| HIGH | sota-implementations/grpo/grpo_utils.py | 540 | Creates and configures a HuggingFace model with optional optimizations. Args: model_name (str): HuggingFace | STRING |
| HIGH | sota-implementations/redq/utils.py | 177 | Creates a Trainer instance given its constituents. Args: collector (BaseCollector): A data collector to be | STRING |
| HIGH | sota-implementations/expert-iteration/ei_utils.py | 107 | Creates and configures the training model with LoRA adapters. This function initializes the main training model wit | STRING |
| HIGH | sota-implementations/expert-iteration/ei_utils.py | 188 | Creates the vLLM-based inference model for fast generation. This function initializes a vLLM model server for effic | STRING |
| HIGH | sota-implementations/expert-iteration/ei_utils.py | 342 | Creates and configures a HuggingFace model with optional optimizations. Args: model_name (str): HuggingFace | STRING |
| HIGH | torchrl/_utils.py | 1171 | Return the available accelerator device, or CPU if none is found. Checks for accelerator availability in the follow | STRING |
| HIGH | torchrl/_utils.py | 1292 | Compile a model with warm-up. This function wraps :func:`~torch.compile` to add a warm-up phase. During the warm-up | STRING |
| HIGH | torchrl/_utils.py | 1470 | Return current CUDA memory statistics for ``device`` in gigabytes. Wraps :func:`torch.cuda.memory_allocated`, :func | STRING |
| HIGH | torchrl/_utils.py | 1856 | Merge user-provided ray_init_config with default runtime_env excludes. This function ensures that the default Torch | STRING |
| HIGH | torchrl/weight_update/utils.py | 32 | Resolve an attribute path like 'policy' or 'env.value_net' to actual object. Also processes getitem notation like ' | STRING |
| HIGH | torchrl/collectors/_base.py | 764 | Execute a method on a nested attribute of this collector. This method allows remote callers to invoke methods o | STRING |
| HIGH | torchrl/collectors/_base.py | 797 | Get a nested attribute of this collector. This method allows remote callers to retrieve attributes from nested | STRING |
| HIGH | torchrl/collectors/_base.py | 828 | Apply a method to each set of arguments. This method executes a method on the collector with different argument | STRING |
| HIGH | torchrl/collectors/_base.py | 1099 | Update policy weights for the data collector. This method synchronizes the policy weights used by the collector | STRING |
| HIGH | torchrl/collectors/_base.py | 1380 | Receive and apply weights to the collector's policy. This method applies weights to the local policy. When rece | STRING |
| HIGH | torchrl/collectors/_multi_base.py | 1335 | Receive from a pipe while periodically checking worker health. This method prevents the main process from hangi | STRING |
| HIGH | torchrl/collectors/_multi_base.py | 2126 | Sets the seeds of the environments stored in the DataCollector. Args: seed: integer representing th | STRING |
| HIGH | torchrl/collectors/_multi_base.py | 2304 | Get an attribute from the policy of the first worker. Args: attr (str): The attribute name to retri | STRING |
| HIGH | torchrl/collectors/_multi_base.py | 2330 | Get an attribute from the environment of the first worker. Args: attr (str): The attribute name to | STRING |
| HIGH | torchrl/collectors/_multi_base.py | 2360 | Get model instance by ID (for weight sync schemes). Args: model_id: Model identifier (e.g., "policy | STRING |
| HIGH | torchrl/collectors/utils.py | 98 | A util function for trajectory separation. Takes a tensordict with a key traj_ids that indicates the id of each tra | STRING |
| HIGH | torchrl/collectors/_single.py | 1758 | Sets the seeds of the environments stored in the DataCollector. Args: seed (int): integer represent | STRING |
| HIGH | torchrl/collectors/_single.py | 2606 | Get model instance by ID (for weight sync schemes). Args: model_id: Model identifier (e.g., "policy | STRING |
| HIGH | torchrl/collectors/distributed/default_configs.py | 61 | Create a TCPStore with retry logic for handling port conflicts. This function attempts to create a TCPStore, and if | STRING |
| HIGH | torchrl/checkpoint/_hydra.py | 30 | Return the configuration of a run resumed from ``checkpoint_path``. The configuration saved with the checkpoint und | STRING |
| HIGH | torchrl/checkpoint/_checkpoint.py | 1157 | Return one component's stored payload without a live object. State-dict components return the decoded state dic | STRING |
| HIGH | torchrl/checkpoint/_checkpoint.py | 1800 | Return the checkpoint at ``path`` or the newest checkpoint of a rotation directory. Args: path: A checkpoin | STRING |
| HIGH | torchrl/record/recorder.py | 333 | Convert recorded frames to a Matplotlib animation. This helper is intended for tutorials and notebooks where th | STRING |
| HIGH | torchrl/render/checkpoint.py | 52 | Writes a checkpoint in the layout expected by rlrender factories. The model weights are stored under the canonical | STRING |
| HIGH | torchrl/render/mujoco_wasm.py | 57 | Writes a local Vite viewer for MuJoCo WASM notebook rendering. Args: output_dir: Directory that will contai | STRING |
| HIGH | torchrl/render/mujoco_wasm.py | 125 | Starts and displays a generated MuJoCo WASM viewer in a notebook. Args: viewer_dir: Directory produced by : | STRING |
| HIGH | torchrl/render/mujoco_wasm.py | 184 | Sends one qpos vector to a live MuJoCo WASM notebook viewer. Args: qpos: Iterable of joint position values. | STRING |
| HIGH | torchrl/render/mujoco_wasm.py | 235 | Plays a qpos trajectory in a live MuJoCo WASM notebook viewer. Args: qpos: Iterable of waypoints, each cont | STRING |
| HIGH | torchrl/render/mujoco_wasm.py | 312 | Extracts a qpos trajectory from a rollout TensorDict. Args: rollout: Rollout TensorDict saved by ``rlrender | STRING |
| HIGH | torchrl/render/backends/mujoco.py | 53 | Returns a detached snapshot of the environment's MuJoCo state. Args: env: TorchRL-native MuJoCo env | STRING |
| HIGH | torchrl/objectives/dreamer_v3.py | 88 | Return DreamerV3 dynamics and representation KL losses. The dynamics term stops gradients through the posterior and | STRING |
| HIGH | torchrl/objectives/dreamer_v3.py | 136 | KL divergence with balancing between posterior and prior. Computes: loss = alpha * KL(sg(posterior) || prio | STRING |
| HIGH | torchrl/objectives/dreamer_v3.py | 1225 | Compute the DreamerV3 critic loss on a replay sequence. The return of each replay state uses the reward of the | STRING |
| HIGH | torchrl/objectives/common.py | 870 | Value-function constructor. If the non-default value function is wanted, it must be built using this me | STRING |
| HIGH | torchrl/objectives/llm/distillation.py | 28 | Per-token k3 estimate of the KL divergence to a target distribution. Uses the k3 estimator ``exp(d) - 1 - d`` with | STRING |
| HIGH | torchrl/objectives/value/advantages.py | 1171 | Computes the TD(0) advantage given the data in tensordict. If a functional module is provided, a nested TensorD | STRING |
| HIGH | torchrl/objectives/value/advantages.py | 1470 | Computes the TD(1) advantage given the data in tensordict. If a functional module is provided, a nested TensorD | STRING |
| HIGH | torchrl/objectives/value/advantages.py | 1793 | Computes the TD(:math:`\lambda`) advantage given the data in tensordict. If a functional module is provided, a | STRING |
| HIGH | torchrl/objectives/value/advantages.py | 2153 | Construct GAE with correctness-first recurrent-network defaults. This constructor disables ``vmap`` and uses th | STRING |
| HIGH | torchrl/objectives/value/advantages.py | 2402 | Computes the GAE given the data in tensordict. If a functional module is provided, a nested TensorDict containi | STRING |
| HIGH | torchrl/objectives/value/advantages.py | 3174 | Computes the V-Trace correction given the data in tensordict. If a functional module is provided, a nested Tens | STRING |
| HIGH | torchrl/objectives/value/functional.py | 1396 | Compute the discounted cumulative sum of rewards given multiple trajectories and the episode ends. Args: re | STRING |
| HIGH | torchrl/_comm/backends.py | 79 | Return the canonical spelling of a TorchRL service backend. The long ``threading`` and ``multiprocessing`` spelling | STRING |
| HIGH | torchrl/_comm/backends.py | 104 | Return the canonical spelling of a TorchRL payload transport. Args: backend: Transport selector to validate | STRING |
| HIGH | torchrl/trainers/trainers.py | 3092 | Resolve a module from a trainer using a string path. Args: trainer (Trainer): The trainer instance to resol | STRING |
| HIGH | torchrl/trainers/algorithms/ppo.py | 77 | Build a PPO trainer from an environment, actor and critic. Constructs a :class:`~torchrl.collectors.Collector`, | STRING |
| HIGH | torchrl/trainers/algorithms/configs/entrypoint.py | 24 | Instantiate ``cfg.trainer``, resuming from ``cfg.resume`` when it is set. Without ``resume`` this is :func:`hydra.u | STRING |
| HIGH | torchrl/trainers/helpers/models.py | 67 | DQN constructor helper function. Args: proof_environment (EnvBase): a dummy environment to retrieve the obs | STRING |
| HIGH | torchrl/trainers/helpers/trainers.py | 90 | Creates a Trainer instance given its constituents. Args: collector (BaseCollector): A data collector to be | STRING |
| HIGH | torchrl/modules/functional.py | 12 | Apply the element-wise symmetric logarithm transform. The transform is defined as ``sign(value) * log(1 + abs(v | STRING |
| HIGH | torchrl/modules/functional.py | 42 | Apply the inverse symmetric exponential transform element-wise. Args: value (torch.Tensor): Input tensor in | STRING |
| 125 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | test/test_configs.py | 1303 | # Create a complex configuration | COMMENT |
| MEDIUM | test/test_configs.py | 3658 | # Create a test script that follows the pattern | COMMENT |
| MEDIUM | test/test_configs.py | 3679 | # Create the config directory structure | STRING |
| MEDIUM | test/test_exploration.py | 688 | # Create a policy with exploration module that has spec=None | COMMENT |
| MEDIUM | test/test_exploration.py | 1132 | # Create a simple network with NoisyLinear using new behavior | COMMENT |
| MEDIUM | test/test_utils.py | 690 | # Create a tensor with batch dimension | COMMENT |
| MEDIUM | test/test_postprocs.py | 230 | # Create a sample TensorDict | COMMENT |
| MEDIUM | test/test_postprocs.py | 244 | # Create an instance of LastRewardToTraj | COMMENT |
| MEDIUM⚡ | test/test_specs.py | 4760 | # Create a OneHot spec with a mask that varies across batch dimension | COMMENT |
| MEDIUM | test/smoke_test_deps.py | 16 | # This file is a smoke test for optional deps. All optional-dep imports must | COMMENT |
| MEDIUM | test/test_collectors.py | 6962 | # Create a ParallelEnv factory - this is the key component that was failing | COMMENT |
| MEDIUM | test/test_collectors.py | 6980 | # Create the multi-collector with ParallelEnv and replay_buffer | COMMENT |
| MEDIUM | test/test_collectors.py | 7052 | # Create a simple dummy environment | COMMENT |
| MEDIUM | test/test_collectors.py | 7058 | # Create a simple dummy policy | COMMENT |
| MEDIUM | test/test_collectors.py | 7366 | # Create a deterministic policy (linear, no bias) so zeroing weights → zero actions | COMMENT |
| MEDIUM⚡ | test/llm/test_conversions.py | 116 | # Create a batch of ChatHistory objects | COMMENT |
| MEDIUM⚡ | test/llm/test_conversions.py | 427 | # Create a 2x2 batch | COMMENT |
| MEDIUM⚡ | test/llm/test_conversions.py | 429 | # Create a 2x2 batch of ChatHistory objects | COMMENT |
| MEDIUM | test/llm/test_conversions.py | 62 | # Create a batch of ChatHistory objects | COMMENT |
| MEDIUM | test/llm/test_conversions.py | 181 | # Create a batch of ChatHistory objects | COMMENT |
| MEDIUM | test/llm/test_conversions.py | 233 | # Create a batch of ChatHistory objects | COMMENT |
| MEDIUM | test/llm/test_conversions.py | 310 | # Create a batch of ChatHistory objects | COMMENT |
| MEDIUM | test/llm/test_conversions.py | 408 | # Create a batch of ChatHistory objects | COMMENT |
| MEDIUM | test/llm/test_vllm.py | 118 | # Create a transformer policy with the same model | COMMENT |
| MEDIUM | test/llm/test_vllm.py | 153 | # Create a proper collector mock that provides access to the AsyncVLLM service | COMMENT |
| MEDIUM | test/llm/test_wrapper.py | 2741 | # Create a custom mask matching the logits shape | COMMENT |
| MEDIUM | test/llm/test_wrapper.py | 3392 | # Create a simple mock function to test the decorator | COMMENT |
| MEDIUM | test/llm/test_wrapper.py | 3400 | # Create a mock self object with batching attributes | COMMENT |
| MEDIUM | test/llm/test_llm_envs.py | 987 | # Define a simple calculator tool | COMMENT |
| MEDIUM | test/llm/test_llm_envs.py | 996 | # Define the tool schema | COMMENT |
| MEDIUM | test/llm/test_llm_envs.py | 1107 | # Define a tool that waits for a random amount of time | COMMENT |
| MEDIUM | test/llm/test_llm_envs.py | 1120 | # Define the tool schema | COMMENT |
| MEDIUM | test/llm/test_data.py | 577 | # Create a simple history | COMMENT |
| MEDIUM | test/llm/test_data.py | 726 | # Create a custom template (trivially different from Qwen) | COMMENT |
| MEDIUM | test/llm/test_data.py | 1009 | # Create a batch of 2 prompt histories | COMMENT |
| MEDIUM⚡ | test/objectives/test_loss_module.py | 1371 | # Create a value estimator instance | COMMENT |
| MEDIUM⚡ | test/objectives/test_loss_module.py | 1377 | # Create a loss module that supports value estimation | COMMENT |
| MEDIUM⚡ | test/objectives/test_loss_module.py | 1470 | # Create a GAE instance | COMMENT |
| MEDIUM⚡ | test/objectives/test_loss_module.py | 1477 | # Create a PPO loss | COMMENT |
| MEDIUM | test/objectives/test_loss_module.py | 1398 | # Create a loss module | COMMENT |
| MEDIUM | test/objectives/test_loss_module.py | 1424 | # Create a loss module | COMMENT |
| MEDIUM | test/objectives/test_loss_module.py | 1446 | # Create a PPO loss which supports GAE | COMMENT |
| MEDIUM | test/libs/test_envpool.py | 234 | # Create the first env, set the seed, and perform a sequence of operations | COMMENT |
| MEDIUM | test/libs/test_envpool.py | 248 | # Create a new env, set the seed, and repeat same operations | COMMENT |
| MEDIUM | test/libs/test_isaac.py | 992 | # Create a fresh env with InitTracker (required for LSTM) | COMMENT |
| MEDIUM | test/libs/test_isaac.py | 1023 | # Create a simple policy using the LSTM and move to correct device | COMMENT |
| MEDIUM⚡ | test/transforms/test_reward_transforms.py | 1208 | # Create a simple env with multi-objective rewards | COMMENT |
| MEDIUM⚡ | test/transforms/test_reward_transforms.py | 1211 | # Create a composed transform with LineariseRewards and RewardScaling | COMMENT |
| MEDIUM | test/transforms/test_reward_transforms.py | 1250 | # Create a dummy env that produces nested rewards | COMMENT |
| MEDIUM | test/transforms/test_compose_and_env.py | 666 | # Create a Compose transform that renames "action" to "action_1" and then to "action_2" | COMMENT |
| MEDIUM⚡ | test/transforms/test_module_transforms.py | 322 | # Create a simple module that adds a learnable bias to observations | COMMENT |
| MEDIUM | test/rb/test_samplers.py | 2044 | # Create a new buffer with the loaded storage but NEW sampler | COMMENT |
| MEDIUM | test/rb/test_storages.py | 433 | # Create a list of tensordicts (like a collector would produce) | COMMENT |
| MEDIUM | test/rb/test_storages.py | 771 | # Create an instance of LazyStackStorage with given parameters | COMMENT |
| MEDIUM | test/rb/test_storages.py | 773 | # Create a ReplayBuffer using the created storage | COMMENT |
| MEDIUM | test/rb/test_storages.py | 1736 | # Create a script that creates a storage and exits normally | COMMENT |
| MEDIUM | test/rb/test_storages.py | 1767 | # Create a script that sleeps and can be interrupted | COMMENT |
| MEDIUM | …ta-implementations/vla_grpo/openvla_oft/train_utils.py | 9 | # Create a tensor marking positions of IGNORE_INDEX | COMMENT |
| MEDIUM | …ta-implementations/vla_grpo/openvla_oft/train_utils.py | 15 | # Create the mask | COMMENT |
| MEDIUM | …ta-implementations/vla_grpo/openvla_oft/train_utils.py | 26 | # Create a tensor marking positions of IGNORE_INDEX | COMMENT |
| 138 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | setup.py | 145 | CODE | |
| LOW | packaging/wheel/relocate.py | 76 | CODE | |
| LOW | test/test_configs.py | 2171 | CODE | |
| LOW | test/test_configs.py | 3654 | CODE | |
| LOW | test/test_utils.py | 445 | CODE | |
| LOW | test/opengl_rendering.py | 87 | CODE | |
| LOW | test/test_inference_server.py | 4397 | CODE | |
| LOW | test/test_inference_server.py | 4448 | CODE | |
| LOW | test/test_specs.py | 3666 | CODE | |
| LOW | test/test_specs.py | 3712 | CODE | |
| LOW | test/test_specs.py | 2094 | CODE | |
| LOW | test/test_specs.py | 2429 | CODE | |
| LOW | test/test_specs.py | 2714 | CODE | |
| LOW | test/test_specs.py | 3010 | CODE | |
| LOW | test/test_collectors.py | 1717 | CODE | |
| LOW | test/test_collectors.py | 1799 | CODE | |
| LOW | test/test_collectors.py | 2689 | CODE | |
| LOW | test/test_collectors.py | 3068 | CODE | |
| LOW | test/test_collectors.py | 3972 | CODE | |
| LOW | test/test_collectors.py | 4411 | CODE | |
| LOW | test/test_collectors.py | 4572 | CODE | |
| LOW | test/test_collectors.py | 4787 | CODE | |
| LOW | test/test_collectors.py | 4853 | CODE | |
| LOW | test/test_collectors.py | 5931 | CODE | |
| LOW | test/test_collectors.py | 5952 | CODE | |
| LOW | test/test_collectors.py | 5982 | CODE | |
| LOW | test/test_collectors.py | 6548 | CODE | |
| LOW | test/test_collectors.py | 7030 | CODE | |
| LOW | test/test_collectors.py | 7192 | CODE | |
| LOW | test/test_collectors.py | 7447 | CODE | |
| LOW | test/test_collectors.py | 9322 | CODE | |
| LOW | test/test_collectors.py | 9379 | CODE | |
| LOW | test/test_mcts.py | 107 | CODE | |
| LOW | test/test_mcts.py | 853 | CODE | |
| LOW | test/test_distributed.py | 442 | CODE | |
| LOW | test/test_distributed.py | 568 | CODE | |
| LOW | test/test_distributed.py | 784 | CODE | |
| LOW | test/test_distributed.py | 1524 | CODE | |
| LOW | test/test_distributed.py | 1623 | CODE | |
| LOW | test/test_trainer.py | 738 | CODE | |
| LOW | test/test_trainer.py | 1115 | CODE | |
| LOW | test/test_trainer.py | 1506 | CODE | |
| LOW | test/llm/test_vllm.py | 116 | CODE | |
| LOW | test/llm/test_wrapper.py | 476 | CODE | |
| LOW | test/llm/test_wrapper.py | 2344 | CODE | |
| LOW | test/llm/test_llm_envs.py | 202 | CODE | |
| LOW | test/llm/test_llm_collectors.py | 244 | CODE | |
| LOW | test/llm/test_llm_collectors.py | 351 | CODE | |
| LOW | test/llm/test_data.py | 494 | CODE | |
| LOW | test/objectives/test_loss_module.py | 182 | CODE | |
| LOW | test/objectives/test_cql.py | 174 | CODE | |
| LOW | test/objectives/_objectives_common.py | 208 | CODE | |
| LOW | test/objectives/_objectives_common.py | 209 | CODE | |
| LOW | test/objectives/test_dreamer_v3.py | 2926 | CODE | |
| LOW | test/objectives/test_iql.py | 289 | CODE | |
| LOW | test/objectives/test_iql.py | 544 | CODE | |
| LOW | test/objectives/test_iql.py | 1205 | CODE | |
| LOW | test/objectives/test_iql.py | 1378 | CODE | |
| LOW | test/objectives/test_fql.py | 209 | CODE | |
| LOW | test/objectives/test_ddpg.py | 375 | CODE | |
| 535 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | setup.py | 353 | except Exception: | CODE |
| MEDIUM | setup.py | 346 | def _git_output(args) -> str | None: | CODE |
| LOW | test/test_configs.py | 3733 | except Exception: | STRING |
| LOW | test/test_setup.py | 216 | except Exception as err: | CODE |
| MEDIUM | test/test_inference_server.py | 1662 | def run(idx): | CODE |
| MEDIUM | test/test_inference_server.py | 2060 | def run(idx): | CODE |
| MEDIUM | test/test_inference_server.py | 3055 | def _hammer(server, fn_name): | CODE |
| LOW | test/test_inference_server.py | 1668 | except Exception as exc: # noqa: BLE001 | CODE |
| LOW | test/test_inference_server.py | 2067 | except Exception as exc: # noqa: BLE001 | CODE |
| LOW | test/test_inference_server.py | 3060 | except Exception as exc: | CODE |
| LOW | test/test_inference_server.py | 4927 | except Exception: | CODE |
| LOW | test/test_loggers.py | 1095 | except Exception: | CODE |
| LOW | test/smoke_test_deps.py | 109 | except Exception: # pragma: no cover | CODE |
| LOW | test/smoke_test_deps.py | 113 | except Exception as err: # gymnasium.error.NamespaceNotFound and similar | CODE |
| MEDIUM | test/smoke_test_deps.py | 89 | def test_gym(): | CODE |
| MEDIUM | test/test_collectors.py | 2634 | def test_cudagraph_policy_stochastic_diversity(self): | CODE |
| LOW⚡ | test/test_collectors.py | 5565 | except Exception: | CODE |
| LOW⚡ | test/test_collectors.py | 5580 | except Exception: | CODE |
| LOW | test/test_collectors.py | 5530 | except Exception as e: | CODE |
| LOW | test/test_collectors.py | 5611 | except Exception: | CODE |
| MEDIUM | test/test_distributed.py | 309 | def _test_distributed_collector_basic(cls, queue, frames_per_batch): | CODE |
| MEDIUM | test/test_distributed.py | 355 | def _test_distributed_collector_mult(cls, queue, frames_per_batch): | CODE |
| MEDIUM | test/test_distributed.py | 398 | def _test_distributed_collector_sync(cls, queue, sync): | CODE |
| MEDIUM | test/test_distributed.py | 517 | def _test_distributed_collector_class(cls, queue, collector_class): | CODE |
| MEDIUM | test/test_distributed.py | 568 | def _test_distributed_collector_updatepolicy( | CODE |
| MEDIUM | test/test_distributed.py | 895 | def reset_process_group(self): | CODE |
| MEDIUM | test/test_distributed.py | 1781 | def reset_process_group(self): | CODE |
| LOW | test/test_distributed.py | 329 | except Exception as e: | CODE |
| LOW | test/test_distributed.py | 374 | except Exception as e: | CODE |
| LOW | test/test_distributed.py | 418 | except Exception as e: | CODE |
| LOW | test/test_distributed.py | 479 | except Exception as e: | CODE |
| LOW | test/test_distributed.py | 537 | except Exception as e: | CODE |
| LOW | test/test_distributed.py | 630 | except Exception as e: | CODE |
| LOW | test/test_distributed.py | 698 | except Exception as e: | CODE |
| LOW | test/test_distributed.py | 830 | except Exception as e: | CODE |
| LOW | test/test_distributed.py | 898 | except Exception: | CODE |
| LOW | test/test_distributed.py | 1784 | except Exception: | CODE |
| LOW | test/llm/test_llm_objectives.py | 1636 | except Exception as e: | CODE |
| LOW | test/llm/test_wrapper.py | 116 | except Exception as e: | CODE |
| LOW | test/llm/test_wrapper.py | 149 | except Exception as e: | CODE |
| LOW | test/llm/test_wrapper.py | 595 | except Exception as e: | CODE |
| LOW | test/llm/test_wrapper.py | 2897 | except Exception as e: | CODE |
| LOW | test/llm/test_wrapper.py | 3162 | except Exception as e: | CODE |
| LOW | test/llm/test_wrapper.py | 3316 | except Exception as e: | CODE |
| LOW | test/llm/test_wrapper.py | 3543 | except Exception: | CODE |
| LOW | test/llm/test_sglang_updaters.py | 255 | except Exception as e: | CODE |
| LOW | test/llm/test_llm_envs.py | 1437 | except Exception as e: | CODE |
| LOW | test/llm/test_llm_updaters.py | 135 | except Exception as e: | CODE |
| LOW | test/llm/test_llm_updaters.py | 272 | except Exception as e: | CODE |
| LOW | test/llm/test_llm_updaters.py | 346 | except Exception as e: | CODE |
| LOW | test/llm/test_llm_updaters.py | 400 | except Exception as e: | CODE |
| LOW | test/llm/test_data.py | 691 | except Exception as e: | CODE |
| LOW | test/libs/conftest.py | 33 | except Exception: | CODE |
| LOW | test/libs/test_datasets.py | 450 | except Exception as err: | CODE |
| LOW | test/libs/test_datasets.py | 620 | except Exception: | CODE |
| LOW | test/libs/test_datasets.py | 625 | except Exception: | CODE |
| MEDIUM | test/libs/test_gym.py | 121 | def get_gym_pixel_wrapper(): | CODE |
| LOW | test/libs/test_gym.py | 70 | except Exception: | CODE |
| LOW | test/libs/test_gym.py | 127 | except Exception: | CODE |
| LOW | test/libs/test_gym.py | 141 | except Exception: | CODE |
| 350 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | build_nightly.sh | 41 | # PyPI rejects PEP 440 local version identifiers (e.g. "+g<sha>"). Pin the | COMMENT |
| LOW | pyproject.toml | 261 | first_party_detection = false | COMMENT |
| LOW | packaging/pkg_helpers.bash | 1 | # A set of useful bash functions for common functionality we need to do in | COMMENT |
| LOW | packaging/pkg_helpers.bash | 21 | # /usr/local/cuda-* | COMMENT |
| LOW | packaging/pkg_helpers.bash | 201 | COMMENT | |
| LOW | test/opengl_rendering.py | 1 | # Copyright (c) Meta Platforms, Inc. and affiliates. | COMMENT |
| LOW | test/opengl_rendering.py | 41 | COMMENT | |
| LOW | test/test_collectors.py | 481 | COMMENT | |
| LOW | test/test_collectors.py | 3121 | COMMENT | |
| LOW | test/test_collectors.py | 3761 | collector.shutdown() | COMMENT |
| LOW | test/test_collectors.py | 3781 | # if IS_WINDOWS and PYTHON_3_7: | COMMENT |
| LOW | test/test_collectors.py | 3801 | # # 1226: faster execution | COMMENT |
| LOW | test/test_collectors.py | 3821 | # total_frames=20000, | COMMENT |
| LOW | test/test_collectors.py | 3841 | # device=_device, | COMMENT |
| LOW | test/test_collectors.py | 3861 | # | COMMENT |
| LOW | test/test_collectors.py | 3881 | # return env | COMMENT |
| LOW | test/test_collectors.py | 3901 | # del collector | COMMENT |
| LOW | test/test_collectors.py | 3921 | # frames_per_batch=20, | COMMENT |
| LOW | test/test_collectors.py | 4021 | COMMENT | |
| LOW | test/test_collectors.py | 4041 | # for i, data in enumerate(collector): # noqa: B007 | COMMENT |
| LOW | test/llm/test_wrapper.py | 2841 | result_packed = wrapper_packed(td) | COMMENT |
| LOW | test/llm/test_wrapper.py | 2861 | # wrapper_class._batching_lock.release() | COMMENT |
| LOW | test/objectives/test_loss_module.py | 1181 | class TestBuffer: | COMMENT |
| LOW | test/libs/test_isaac.py | 461 | # "AnymalTerrain", | COMMENT |
| LOW | test/libs/test_isaac.py | 501 | try: | COMMENT |
| LOW | test/modules/test_td_module.py | 221 | COMMENT | |
| LOW | test/envs/test_env_base.py | 661 | COMMENT | |
| LOW | test/rb/conftest.py | 1 | # Copyright (c) Meta Platforms, Inc. and affiliates. | COMMENT |
| LOW | test/rb/test_storage_map.py | 561 | node_id = vertex.node_id | COMMENT |
| LOW | sota-implementations/reward_model_training/utils.py | 81 | vocab_size=256, | COMMENT |
| LOW | sota-implementations/multiagent/utils/__init__.py | 1 | # Copyright (c) Meta Platforms, Inc. and affiliates. | COMMENT |
| LOW | sota-implementations/vla_grpo/openvla.py | 61 | PROMPT_TEMPLATE = "In: What action should the robot take to {instruction}?\nOut:" | COMMENT |
| LOW | sota-implementations/vla_grpo/openvla_oft/__init__.py | 1 | # Vendored from SimpleVLA-RL (https://github.com/PRIME-RL/SimpleVLA-RL), | COMMENT |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 521 | dtype=labels.dtype, | COMMENT |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 541 | # proprio=None, | COMMENT |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 561 | COMMENT | |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 581 | # # === Handle Unimodal Forward === | COMMENT |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 601 | # assert past_key_values is None, "Unexpected key `past_key_values` provided during multimodal forward!" | COMMENT |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 621 | # # Add proprioceptive state if provided | COMMENT |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 641 | # noisy_actions = noisy_actions.reshape(B, -1).unsqueeze(-1) | COMMENT |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 661 | # # Build labels for multimodal sequence if needed | COMMENT |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 681 | COMMENT | |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 821 | output_hidden_states=False, | COMMENT |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 841 | COMMENT | |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 861 | COMMENT | |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 881 | # #print("!!!!!!!!!!!!!!Entering forward!!!!!!!!!!") | COMMENT |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 901 | # # Add stop token to sequence (needed in non-causal bi-directional self-attention, as it appears at train time) | COMMENT |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 921 | # #test | COMMENT |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 941 | COMMENT | |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 961 | # newline_positions = labels != IGNORE_INDEX | COMMENT |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 981 | COMMENT | |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 1001 | # projected_patch_embeddings, proprio, proprio_projector | COMMENT |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 1021 | # # Run diffusion-based prediction | COMMENT |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 1041 | # # labels, | COMMENT |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 1061 | # (projected_patch_embeddings.shape[0], projected_patch_embeddings.shape[1]), | COMMENT |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 1081 | COMMENT | |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 1281 | else: | COMMENT |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 1641 | # if action_head is not None: | COMMENT |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 1661 | device = language_model_output.logits.device | COMMENT |
| LOW | …a-implementations/vla_grpo/config/vla_grpo_libero.yaml | 1 | # SimpleVLA-RL (arXiv:2509.09674) on LIBERO: OpenVLA-OFT token variant (7B), | COMMENT |
| 468 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | setup.py | 26 | logger = logging.getLogger(__name__) | CODE |
| LOW | packaging/prepare_nightly_build.py | 7 | logger = logging.getLogger(__name__) | CODE |
| LOW | test/conftest.py | 81 | def set_warnings() -> None: | STRING |
| LOW | test/test_render.py | 162 | def _set_seed(self, seed: int | None) -> None: | CODE |
| LOW | test/test_collectors.py | 1924 | def _set_seed(self, seed: Optional[int]) -> None: | CODE |
| LOW | test/test_collectors.py | 3404 | def _set_seed(self, seed: int | None = None) -> None: | CODE |
| LOW | test/test_collectors.py | 3461 | def _set_seed(self, seed: int | None = None) -> None: | CODE |
| LOW | test/test_collectors.py | 3636 | def _set_seed(self, seed: int | None) -> None: | CODE |
| LOW | test/test_collectors.py | 4747 | def _set_seed(self, seed: int | None) -> None: | CODE |
| LOW | test/collectors/test_evaluator.py | 1041 | def set_extra_state(self, state: OrderedDict) -> None: | CODE |
| LOW | test/objectives/_objectives_common.py | 132 | def _set_seed(self, seed: int | None) -> None: | CODE |
| LOW | test/libs/test_gym.py | 197 | def _set_seed(self, seed: int | None) -> None: | CODE |
| LOW⚡ | test/transforms/test_action_transforms.py | 160 | def _set_seed(self, seed: int | None) -> None: | CODE |
| LOW⚡ | test/transforms/test_key_transforms.py | 95 | def _set_seed(self, seed: int | None) -> None: | CODE |
| LOW⚡ | test/transforms/test_key_transforms.py | 333 | def _set_seed(self, seed: int | None) -> None: | CODE |
| LOW⚡ | test/transforms/test_key_transforms.py | 934 | def _set_seed(self, seed: int | None) -> None: | CODE |
| LOW | test/transforms/test_reward_transforms.py | 1284 | def _set_seed(self, seed: int | None = None) -> None: | CODE |
| LOW | test/transforms/test_reward_transforms.py | 1344 | def _set_seed(self, seed: int | None = None) -> None: | CODE |
| LOW | test/transforms/test_compose_and_env.py | 175 | def _set_seed(self, seed: int) -> None: | CODE |
| LOW | test/transforms/test_compose_and_env.py | 1208 | def _set_seed(self, seed: int | None) -> None: | CODE |
| LOW | test/transforms/test_env_transforms.py | 441 | def _set_seed(self, seed: int | None) -> None: | CODE |
| LOW | test/transforms/test_env_transforms.py | 553 | def _set_seed(self, seed: int | None) -> None: | CODE |
| LOW | test/transforms/test_normalization.py | 79 | def _set_seed(self, seed: int | None) -> None: | CODE |
| LOW | test/modules/test_planners.py | 139 | def _set_seed(self, seed: int | None) -> None: | CODE |
| LOW | test/envs/test_env_base.py | 142 | def _set_seed(self, seed: int | None) -> None: | CODE |
| LOW | test/envs/test_env_base.py | 318 | def _set_seed(self, seed: int | None) -> None: | CODE |
| LOW | sota-implementations/multiagent/utils/utils.py | 9 | __all__ = ["DoneTransform"] | CODE |
| LOW | …implementations/vla_grpo/compare_simplevla_rollouts.py | 229 | def _set_seed(seed: int) -> None: | CODE |
| LOW⚡ | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 395 | def set_input_embeddings(self, value: nn.Module) -> None: | CODE |
| LOW⚡ | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 401 | def set_output_embeddings(self, new_embeddings: nn.Module) -> None: | CODE |
| LOW⚡ | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 407 | def set_decoder(self, decoder: nn.Module) -> None: | CODE |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 43 | logger = logging.getLogger(__name__) | CODE |
| LOW | …ementations/vla_grpo/openvla_oft/modeling_prismatic.py | 199 | def set_num_images_in_input(self, num_images_in_input: int) -> None: | CODE |
| LOW | sota-implementations/bandits/dqn.py | 91 | def _set_seed(self, seed: int | None) -> None: | CODE |
| LOW | examples/replay-buffers/filter-imcomplete-trajs.py | 33 | def _update_repertoire(self, tensordict: TensorDictBase) -> None: | CODE |
| LOW | examples/rlhf/models/actor_critic.py | 15 | __all__ = ["init_actor_critic"] | CODE |
| LOW | examples/rlhf/data/__init__.py | 3 | __all__ = ["get_prompt_dataloader_tldr"] | CODE |
| LOW | examples/envs/benchmark_compile_step_and_maybe_reset.py | 110 | def _set_seed(self, seed: int | None) -> None: | CODE |
| LOW | benchmarks/conftest.py | 143 | def set_warnings() -> None: | STRING |
| LOW | benchmarks/test_collectors_benchmark.py | 286 | def _set_seed(self, seed: int | None) -> None: | CODE |
| LOW | benchmarks/bench_collectors.py | 150 | def _set_seed(self, seed: int) -> None: | CODE |
| LOW | torchrl/__init__.py | 143 | __all__ = [ | CODE |
| LOW | torchrl/_utils.py | 460 | def set_profiling_enabled(enabled: bool) -> None: | CODE |
| LOW | torchrl/_utils.py | 1220 | def set_mode(self, type: Any | None) -> None: | CODE |
| LOW | torchrl/weight_update/weight_sync_schemes.py | 23 | __all__ = [ | CODE |
| LOW | torchrl/weight_update/__init__.py | 20 | __all__ = [ | CODE |
| LOW | torchrl/weight_update/_shared.py | 266 | def _update_single_worker(self, worker_idx: int, weights: TensorDictBase) -> None: | CODE |
| LOW⚡ | torchrl/weight_update/_ray.py | 163 | def set_model(self, model: Any) -> None: | CODE |
| LOW⚡ | torchrl/weight_update/_ray.py | 171 | def set_process_group(self, process_group, store=None) -> None: | CODE |
| LOW⚡ | torchrl/weight_update/_ray.py | 176 | def set_model_version(self, model_version: int | None) -> None: | CODE |
| LOW | torchrl/weight_update/_ray.py | 534 | def _set_model_version(self, model_version: int) -> None: | CODE |
| LOW | torchrl/weight_update/_ray.py | 971 | def _set_transform(self, ray_transform) -> None: | CODE |
| LOW | torchrl/weight_update/llm/vllm_nccl.py | 641 | def update_weights(self, weights: Any | None = None) -> None: | CODE |
| LOW | torchrl/weight_update/llm/__init__.py | 26 | __all__ = [ | CODE |
| LOW | torchrl/weight_update/llm/vllm_double_buffer.py | 260 | def update_weights(self, weights: Any | None = None) -> None: | CODE |
| LOW | torchrl/collectors/_constants.py | 26 | __all__ = [ | CODE |
| LOW | torchrl/collectors/_base.py | 1322 | def _set_received_policy_version(self, model_version: int | None) -> None: | CODE |
| LOW | torchrl/collectors/collectors.py | 31 | __all__ = [ | CODE |
| LOW | torchrl/collectors/__init__.py | 27 | __all__ = [ | CODE |
| LOW | torchrl/collectors/_multi_base.py | 1016 | def _setup_preemptive_threshold(self, preemptive_threshold: float | None) -> None: | CODE |
| 312 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | test/llm/test_llm_objectives.py | 0 | create transformers model and tokenizer for testing. | STRING |
| HIGH | test/llm/test_wrapper.py | 0 | create transformers model and tokenizer for testing. | STRING |
| HIGH | test/llm/test_llm_envs.py | 0 | create transformers model and tokenizer for testing. | STRING |
| HIGH | test/objectives/test_cql.py | 0 | regression test for target_entropy='auto' should be -dim(a). | STRING |
| HIGH | test/objectives/test_dt.py | 0 | regression test for target_entropy='auto' should be -dim(a). | STRING |
| HIGH | test/objectives/test_sac.py | 0 | regression test for target_entropy='auto' should be -dim(a). | STRING |
| HIGH | test/libs/test_dm_control.py | 0 | smoke test that setting seed and reset works (seed forwarded into build). | STRING |
| HIGH | test/libs/test_gym.py | 0 | smoke test that setting seed and reset works (seed forwarded into build). | STRING |
| HIGH | test/libs/test_habitat.py | 0 | smoke test that setting seed and reset works (seed forwarded into build). | STRING |
| HIGH | sota-implementations/sac/sac.py | 0 | crossq example. this is a simple self-contained example of a crossq training script. it supports state environments like | STRING |
| HIGH | sota-implementations/discrete_sac/discrete_sac.py | 0 | crossq example. this is a simple self-contained example of a crossq training script. it supports state environments like | STRING |
| HIGH | sota-implementations/ddpg/ddpg.py | 0 | crossq example. this is a simple self-contained example of a crossq training script. it supports state environments like | STRING |
| HIGH | sota-implementations/td3/td3.py | 0 | crossq example. this is a simple self-contained example of a crossq training script. it supports state environments like | STRING |
| HIGH | sota-implementations/crossq/crossq.py | 0 | crossq example. this is a simple self-contained example of a crossq training script. it supports state environments like | STRING |
| HIGH | sota-implementations/cql/cql_offline.py | 0 | decision transformer example. this is a self-contained example of an offline decision transformer training script. the h | STRING |
| HIGH | sota-implementations/cql/discrete_cql_offline.py | 0 | decision transformer example. this is a self-contained example of an offline decision transformer training script. the h | STRING |
| HIGH | sota-implementations/iql/iql_offline.py | 0 | decision transformer example. this is a self-contained example of an offline decision transformer training script. the h | STRING |
| HIGH | sota-implementations/td3_bc/td3_bc.py | 0 | decision transformer example. this is a self-contained example of an offline decision transformer training script. the h | STRING |
| HIGH | sota-implementations/decision_transformer/online_dt.py | 0 | decision transformer example. this is a self-contained example of an offline decision transformer training script. the h | STRING |
| HIGH | sota-implementations/decision_transformer/dt.py | 0 | decision transformer example. this is a self-contained example of an offline decision transformer training script. the h | STRING |
| HIGH | sota-implementations/cql/cql_online.py | 0 | iql example. this is a self-contained example of an online iql training script. it works across gym and mujoco over a va | STRING |
| HIGH | sota-implementations/iql/discrete_iql.py | 0 | iql example. this is a self-contained example of an online iql training script. it works across gym and mujoco over a va | STRING |
| HIGH | sota-implementations/iql/iql_online.py | 0 | iql example. this is a self-contained example of an online iql training script. it works across gym and mujoco over a va | STRING |
| HIGH | sota-implementations/impala/impala_multi_node_ray.py | 0 | this script reproduces the impala algorithm results from espeholt et al. 2018 for the on atari environments. | STRING |
| HIGH | sota-implementations/impala/impala_single_node.py | 0 | this script reproduces the impala algorithm results from espeholt et al. 2018 for the on atari environments. | STRING |
| HIGH | …a-implementations/impala/impala_multi_node_submitit.py | 0 | this script reproduces the impala algorithm results from espeholt et al. 2018 for the on atari environments. | STRING |
| HIGH | sota-implementations/grpo/grpo-async.py | 0 | setup required environment variables and configurations. | STRING |
| HIGH | sota-implementations/grpo/grpo-sync.py | 0 | setup required environment variables and configurations. | STRING |
| HIGH | …lementations/expert-iteration/expert-iteration-sync.py | 0 | setup required environment variables and configurations. | STRING |
| HIGH | …ementations/expert-iteration/expert-iteration-async.py | 0 | setup required environment variables and configurations. | STRING |
| HIGH | examples/distributed/collectors/single_machine/sync.py | 0 | rpc data collection on a single node. the default configuration works fine on machines equipped with 4 gpus, but can be | STRING |
| HIGH | …mples/distributed/collectors/single_machine/generic.py | 0 | rpc data collection on a single node. the default configuration works fine on machines equipped with 4 gpus, but can be | STRING |
| HIGH | examples/distributed/collectors/single_machine/rpc.py | 0 | rpc data collection on a single node. the default configuration works fine on machines equipped with 4 gpus, but can be | STRING |
| HIGH | torchrl/record/loggers/mlflow.py | 0 | logs a scalar value to the tensorboard. args: name (str): the name of the scalar. value (float): the value of the scalar | STRING |
| HIGH | torchrl/record/loggers/trackio.py | 0 | logs a scalar value to the tensorboard. args: name (str): the name of the scalar. value (float): the value of the scalar | STRING |
| HIGH | torchrl/record/loggers/csv.py | 0 | logs a scalar value to the tensorboard. args: name (str): the name of the scalar. value (float): the value of the scalar | STRING |
| HIGH | torchrl/record/loggers/tensorboard.py | 0 | logs a scalar value to the tensorboard. args: name (str): the name of the scalar. value (float): the value of the scalar | STRING |
| HIGH | torchrl/record/loggers/mlflow.py | 0 | logs the hyperparameters of the experiment. args: cfg (dictconfig or dict): the configuration of the experiment. | STRING |
| HIGH | torchrl/record/loggers/wandb.py | 0 | logs the hyperparameters of the experiment. args: cfg (dictconfig or dict): the configuration of the experiment. | STRING |
| HIGH | torchrl/record/loggers/trackio.py | 0 | logs the hyperparameters of the experiment. args: cfg (dictconfig or dict): the configuration of the experiment. | STRING |
| HIGH | torchrl/record/loggers/csv.py | 0 | logs the hyperparameters of the experiment. args: cfg (dictconfig or dict): the configuration of the experiment. | STRING |
| HIGH | torchrl/record/loggers/tensorboard.py | 0 | logs the hyperparameters of the experiment. args: cfg (dictconfig or dict): the configuration of the experiment. | STRING |
| HIGH | torchrl/objectives/td3.py | 0 | maintains default values for all configurable tensordict keys. this class defines which tensordict keys can be set using | STRING |
| HIGH | torchrl/objectives/td3_bc.py | 0 | maintains default values for all configurable tensordict keys. this class defines which tensordict keys can be set using | STRING |
| HIGH | torchrl/objectives/iql.py | 0 | maintains default values for all configurable tensordict keys. this class defines which tensordict keys can be set using | STRING |
| HIGH | torchrl/objectives/crossq.py | 0 | maintains default values for all configurable tensordict keys. this class defines which tensordict keys can be set using | STRING |
| HIGH | torchrl/objectives/deprecated.py | 0 | maintains default values for all configurable tensordict keys. this class defines which tensordict keys can be set using | STRING |
| HIGH | torchrl/objectives/redq.py | 0 | maintains default values for all configurable tensordict keys. this class defines which tensordict keys can be set using | STRING |
| HIGH | torchrl/objectives/sac.py | 0 | maintains default values for all configurable tensordict keys. this class defines which tensordict keys can be set using | STRING |
| HIGH | torchrl/objectives/ddpg.py | 0 | maintains default values for all configurable tensordict keys. this class defines which tensordict keys can be set using | STRING |
| HIGH | torchrl/objectives/cql.py | 0 | maintains default values for all configurable tensordict keys. this class defines which tensordict keys can be set using | STRING |
| HIGH | torchrl/objectives/dqn.py | 0 | maintains default values for all configurable tensordict keys. this class defines which tensordict keys can be set using | STRING |
| HIGH | torchrl/objectives/multiagent/qmixer.py | 0 | maintains default values for all configurable tensordict keys. this class defines which tensordict keys can be set using | STRING |
| HIGH | torchrl/_comm/distributed.py | 0 | return ``true`` when the result can be read without blocking. | STRING |
| HIGH | torchrl/_comm/mailbox.py | 0 | return ``true`` when the result can be read without blocking. | STRING |
| HIGH | torchrl/modules/inference_server/_shared_memory.py | 0 | return ``true`` when the result can be read without blocking. | STRING |
| HIGH | torchrl/modules/llm/policies/vllm_wrapper.py | 0 | returns a new version of the module with altered parameters. for instance, the generate parameter can be altered to enab | STRING |
| HIGH | torchrl/modules/llm/policies/common.py | 0 | returns a new version of the module with altered parameters. for instance, the generate parameter can be altered to enab | STRING |
| HIGH | torchrl/modules/llm/policies/transformers_wrapper.py | 0 | returns a new version of the module with altered parameters. for instance, the generate parameter can be altered to enab | STRING |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | test/test_postprocs.py | 300 | CODE | |
| LOW | test/test_trainer.py | 312 | CODE | |
| LOW | test/llm/test_llm_objectives.py | 670 | CODE | |
| LOW | test/llm/test_wrapper.py | 643 | CODE | |
| LOW | test/objectives/test_iql.py | 199 | CODE | |
| LOW | test/objectives/test_iql.py | 1111 | CODE | |
| LOW | test/objectives/test_dqn.py | 90 | CODE | |
| LOW | test/objectives/test_dqn.py | 1082 | CODE | |
| LOW | test/objectives/test_ddpg.py | 138 | CODE | |
| LOW | test/objectives/test_ddpg.py | 179 | CODE | |
| LOW | test/objectives/test_ddpg.py | 907 | CODE | |
| LOW | test/objectives/test_ddpg.py | 1829 | CODE | |
| LOW | test/objectives/test_ppo.py | 112 | CODE | |
| LOW | test/objectives/test_ppo.py | 300 | CODE | |
| LOW | test/objectives/test_ppo.py | 352 | CODE | |
| LOW | test/objectives/test_ppo.py | 2231 | CODE | |
| LOW | test/objectives/test_ppo.py | 2383 | CODE | |
| LOW | test/objectives/test_sac.py | 75 | CODE | |
| LOW | test/objectives/test_sac.py | 257 | CODE | |
| LOW | test/objectives/test_sac.py | 1585 | CODE | |
| LOW | test/objectives/test_sac.py | 2420 | CODE | |
| LOW | test/objectives/test_sac.py | 3295 | CODE | |
| LOW | test/libs/test_datasets.py | 1200 | CODE | |
| LOW | test/libs/test_envpool.py | 150 | CODE | |
| LOW | sota-implementations/vla_grpo/utils.py | 529 | CODE | |
| LOW | sota-implementations/vla_grpo/utils.py | 584 | CODE | |
| LOW | sota-implementations/vla_grpo/openvla.py | 186 | CODE | |
| LOW | sota-implementations/vla_grpo/openvla.py | 476 | CODE | |
| LOW | sota-implementations/vla_grpo/openvla.py | 815 | CODE | |
| LOW | sota-implementations/vla_grpo/openvla.py | 1101 | CODE | |
| LOW | …ations/vla_grpo/openvla_oft/configuration_prismatic.py | 76 | CODE | |
| LOW | sota-implementations/grpo/grpo_utils.py | 518 | CODE | |
| LOW | sota-implementations/decision_transformer/lamb.py | 38 | CODE | |
| LOW | sota-implementations/ppo/utils_mujoco.py | 43 | CODE | |
| LOW | sota-implementations/redq/utils.py | 560 | CODE | |
| LOW | sota-implementations/expert-iteration/ei_utils.py | 319 | CODE | |
| LOW | examples/microduck/heuristic_gait.py | 270 | CODE | |
| LOW | examples/microduck/ppo_mujoco.py | 122 | CODE | |
| LOW | examples/microduck/ppo_mujoco.py | 694 | CODE | |
| LOW | examples/satellite/_utils.py | 443 | CODE | |
| LOW | examples/satellite/_utils.py | 538 | CODE | |
| LOW | examples/menagerie/ppo.py | 633 | CODE | |
| LOW | torchrl/weight_update/_shared.py | 386 | CODE | |
| LOW | torchrl/weight_update/_shared.py | 511 | CODE | |
| LOW | torchrl/weight_update/_mp.py | 83 | CODE | |
| LOW | torchrl/collectors/_base.py | 581 | CODE | |
| LOW | torchrl/collectors/_single_async.py | 175 | CODE | |
| LOW | torchrl/collectors/_multi_base.py | 422 | CODE | |
| LOW | torchrl/collectors/_async_batched.py | 846 | CODE | |
| LOW | torchrl/collectors/_single.py | 683 | CODE | |
| LOW | torchrl/collectors/_single.py | 1782 | CODE | |
| LOW | torchrl/collectors/_evaluator.py | 289 | CODE | |
| LOW | torchrl/collectors/_runner.py | 57 | CODE | |
| LOW | torchrl/collectors/llm/ray_collector.py | 84 | CODE | |
| LOW | torchrl/collectors/llm/base.py | 151 | CODE | |
| LOW | torchrl/collectors/distributed/sync.py | 288 | CODE | |
| LOW | torchrl/collectors/distributed/generic.py | 546 | CODE | |
| LOW | torchrl/collectors/distributed/ray.py | 360 | CODE | |
| LOW | torchrl/collectors/distributed/rpc.py | 320 | CODE | |
| LOW | torchrl/record/recorder.py | 142 | CODE | |
| 232 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | test/test_inference_server.py | 2611 | ws.push(new_weights) | CODE |
| HIGH | test/test_inference_server.py | 2640 | ws.push(new_weights) | CODE |
| HIGH | test/envs/test_special.py | 323 | board.push(move) | CODE |
| HIGH | sota-implementations/dreamer_v3/dreamer_v3_utils.py | 97 | f"optimization.compile_rssm must be null, 'step' or 'scan', got {rssm!r}." | CODE |
| HIGH | .github/scripts/generate_dashboard.py | 310 | document.getElementById('new-flaky-count').textContent = report.summary.new_flaky_count || 0; | CODE |
| HIGH | .github/scripts/generate_dashboard.py | 311 | document.getElementById('resolved-count').textContent = report.summary.resolved_count || 0; | CODE |
| HIGH | .github/scripts/generate_dashboard.py | 344 | if (!flakyTests || flakyTests.length === 0) { | CODE |
| HIGH | .github/scripts/generate_dashboard.py | 370 | const lastFailed = test.recent_failures && test.recent_failures.length > 0 | CODE |
| HIGH | torchrl/_extension.py | 59 | " - make sure you ran `python setup.py clean && python setup.py develop` and that no error was raised\n" | CODE |
| HIGH⚡ | torchrl/render/mujoco_wasm.py | 863 | let model = null; | CODE |
| HIGH⚡ | torchrl/render/mujoco_wasm.py | 864 | let data = null; | CODE |
| HIGH⚡ | torchrl/render/mujoco_wasm.py | 865 | let mujoco = null; | CODE |
| HIGH⚡ | torchrl/render/mujoco_wasm.py | 868 | let threeScene = null; | CODE |
| HIGH⚡ | torchrl/render/mujoco_wasm.py | 869 | let renderer = null; | CODE |
| HIGH⚡ | torchrl/render/mujoco_wasm.py | 870 | let camera = null; | CODE |
| HIGH⚡ | torchrl/render/mujoco_wasm.py | 871 | let controls = null; | CODE |
| HIGH⚡ | torchrl/render/mujoco_wasm.py | 874 | let trajectoryPlayback = null; | CODE |
| HIGH⚡ | torchrl/render/mujoco_wasm.py | 1121 | jointControls.push({name, jointId, qposAddress, slider, output}); | CODE |
| HIGH⚡ | torchrl/render/mujoco_wasm.py | 1128 | if (!trajectoryUrl || params.get("autoplay") === "0") return; | CODE |
| HIGH⚡ | torchrl/render/mujoco_wasm.py | 1133 | const result = applyTrajectoryMessage(payload, null); | CODE |
| HIGH⚡ | torchrl/render/mujoco_wasm.py | 1138 | if (!value || typeof value !== "object") return null; | CODE |
| HIGH⚡ | torchrl/render/mujoco_wasm.py | 1138 | if (!value || typeof value !== "object") return null; | CODE |
| HIGH⚡ | torchrl/render/mujoco_wasm.py | 1139 | if (value.type !== "torchrl:mujoco_wasm:setQpos" && value.type !== "torchrl:mujoco_wasm:playTrajectory") return null; | CODE |
| HIGH⚡ | torchrl/render/mujoco_wasm.py | 1244 | if (renderer && camera) renderer.render(rendererScene(), camera); | CODE |
| HIGH⚡ | torchrl/render/mujoco_wasm.py | 1252 | if (!playback.loop && framePosition >= finalIndex) { | CODE |
| HIGH⚡ | torchrl/render/mujoco_wasm.py | 1254 | trajectoryPlayback = null; | CODE |
| HIGH | torchrl/render/mujoco_wasm.py | 643 | if (requestId && callbackUrl) {{ | CODE |
| HIGH | torchrl/render/mujoco_wasm.py | 650 | if (message.ok === false || done || cancelled) {{ | CODE |
| HIGH | torchrl/render/mujoco_wasm.py | 1026 | visuals.push({geomId, object: mesh}); | CODE |
| HIGH | torchrl/render/mujoco_wasm.py | 1047 | return null; | CODE |
| HIGH | torchrl/render/mujoco_wasm.py | 1087 | if (jointType !== HINGE_JOINT_TYPE && jointType !== SLIDE_JOINT_TYPE) continue; | CODE |
| HIGH | torchrl/render/mujoco_wasm.py | 1192 | if (out.length !== model.nq && out.length !== jointControls.length) throw new Error(`qpos must have model.nq (${model. | CODE |
| HIGH | torchrl/render/mujoco_wasm.py | 1211 | if (message.dt !== undefined) { | CODE |
| HIGH | torchrl/render/mujoco_wasm.py | 1216 | if (message.fps !== undefined) { | CODE |
| HIGH | torchrl/render/mujoco_wasm.py | 1283 | trajectoryPlayback = null; | CODE |
| HIGH | torchrl/render/mujoco_wasm.py | 1293 | if (!data || homeQpos.length < 3) return; | CODE |
| HIGH | torchrl/render/mujoco_wasm.py | 1366 | while (end < bytes.length && bytes[end] !== 0) end++; | CODE |
| HIGH | torchrl/objectives/dreamer_v3.py | 140 | + (1 - alpha) * KL(posterior || sg(prior)) | STRING |
| HIGH | torchrl/objectives/llm/distillation.py | 38 | ``KL(sampling distribution || target distribution)``, and the direction | STRING |
| HIGH | torchrl/objectives/llm/distillation.py | 119 | - ``"reverse"`` (default): minimizes ``KL(student || teacher)``. This is | CODE |
| HIGH | torchrl/objectives/llm/distillation.py | 122 | - ``"forward"``: minimizes ``KL(teacher || student)``. Here the scored | CODE |
| HIGH | torchrl/envs/common.py | 885 | - The number of actions can be undefined, e.g., ``Categorical(n=-1)``; | STRING |
| HIGH | torchrl/envs/transforms/_reward.py | 336 | """Maps the reward to a binary value (0 or 1) if the reward is null or non-null, respectively. | STRING |
| HIGH | torchrl/envs/custom/chess.py | 522 | board.push(move) | CODE |
| HIGH | torchrl/data/tensor_specs.py | 3852 | n (int): number of possible outcomes. If set to -1, the cardinality of the categorical spec is undefined, | STRING |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | README.md | 143 | # Nested keys make multi-agent, recurrent, and next-state data explicit. | COMMENT |
| MEDIUM | test/libs/test_mujoco_playground.py | 67 | # Cached environment dims for the multi-agent test env, avoiding O(n_tests) | COMMENT |
| MEDIUM | examples/multiagent/mappo_vmas.py | 148 | # multi-agent value estimator broadcasts the latter across agents. | COMMENT |
| MEDIUM | torchrl/envs/utils.py | 641 | # "multi-agent-emergence-environments": None, | COMMENT |
| MEDIUM | torchrl/envs/utils.py | 642 | # OpenAI, https://github.com/openai/multi-agent-emergence-environments | COMMENT |
| MEDIUM | torchrl/envs/libs/meltingpot.py | 312 | # Create multi-agent specs | COMMENT |
| MEDIUM | torchrl/envs/libs/vmas.py | 429 | # Create multi-agent specs | COMMENT |
| MEDIUM | torchrl/envs/libs/mujoco_playground.py | 220 | # Predefined multi-agent partitionings for common MuJoCo locomotion tasks. | COMMENT |
| MEDIUM | torchrl/envs/model_based/world_model_env.py | 229 | # done structure (e.g. multi-agent dones) consistent with the spec. | COMMENT |
| MEDIUM | torchrl/data/postprocs/postprocs.py | 45 | # Note: rewards could have a different shape than done (e.g. multi-agent with a single | COMMENT |
| MEDIUM⚡ | …orials/sphinx-tutorials/multiagent_competitive_ddpg.py | 936 | # - How to create a competitive multi-group multi-agent environment in TorchRL, how its specs work, and how it integrate | COMMENT |
| MEDIUM⚡ | …orials/sphinx-tutorials/multiagent_competitive_ddpg.py | 937 | # - How to create multi-agent network architectures in TorchRL for multiple groups; | COMMENT |
| MEDIUM⚡ | …orials/sphinx-tutorials/multiagent_competitive_ddpg.py | 938 | # - How we can use :class:`tensordict.TensorDict` to carry multi-agent multi-group data; | COMMENT |
| MEDIUM⚡ | …orials/sphinx-tutorials/multiagent_competitive_ddpg.py | 939 | # - How we can tie all the library components (collectors, modules, replay buffers, and losses) in a multi-agent multi-g | COMMENT |
| MEDIUM⚡ | …orials/sphinx-tutorials/multiagent_competitive_ddpg.py | 941 | # Now that you are proficient with multi-agent DDPG, you can check out all the TorchRL multi-agent implementations in th | COMMENT |
| MEDIUM | …orials/sphinx-tutorials/multiagent_competitive_ddpg.py | 63 | # This approach has been extended to multi-agent learning in `Multi-Agent Actor-Critic for Mixed Cooperative-Competitive | COMMENT |
| MEDIUM | …orials/sphinx-tutorials/multiagent_competitive_ddpg.py | 65 | # In multi-agent settings, things are a bit different. We now have multiple policies :math:`\mathbf{\pi}`, | COMMENT |
| MEDIUM | …orials/sphinx-tutorials/multiagent_competitive_ddpg.py | 88 | # 2. Subsequently, we will construct a multi-agent environment, utilizing TorchRL's | COMMENT |
| MEDIUM | …orials/sphinx-tutorials/multiagent_competitive_ddpg.py | 196 | # TorchRL API allows integrating various types of multi-agent environment flavors. | COMMENT |
| MEDIUM | …orials/sphinx-tutorials/multiagent_competitive_ddpg.py | 311 | # (``"done", "terminated", "truncated"``), which do not have a leading multi-agent dimension. | COMMENT |
| MEDIUM | …orials/sphinx-tutorials/multiagent_competitive_ddpg.py | 333 | # We stress that, in multi-agent contexts, it is paramount to provide explicitly the keys to modify. | COMMENT |
| MEDIUM | …orials/sphinx-tutorials/multiagent_competitive_ddpg.py | 612 | # **From this point on, the multi-agent-specific components have been instantiated, and we will simply use the same | COMMENT |
| MEDIUM | …orials/sphinx-tutorials/multiagent_competitive_ddpg.py | 677 | ), # We will store up to memory_size multi-agent transitions | CODE |
| MEDIUM | tutorials/sphinx-tutorials/getting-started-0.py | 180 | # multiple copies across various processes, a multi-agent environment, or even | COMMENT |
| MEDIUM | tutorials/sphinx-tutorials/getting-started-0.py | 243 | # :ref:`multi-agent environment API <MARL-environment-API>` | COMMENT |
| MEDIUM | tutorials/sphinx-tutorials/getting-started-4.py | 20 | # The final chapter of this series before we orchestrate everything in a | COMMENT |
| MEDIUM⚡ | tutorials/sphinx-tutorials/multiagent_ppo.py | 190 | # TorchRL API allows integrating various types of multi-agent environment flavors. | COMMENT |
| MEDIUM⚡ | tutorials/sphinx-tutorials/multiagent_ppo.py | 192 | # For more information on how the multi-agent environments API works in TorchRL, you can check out the dedicated | COMMENT |
| MEDIUM⚡ | tutorials/sphinx-tutorials/multiagent_ppo.py | 205 | # The multi-agent task we will solve today is *Navigation* (see animated figure above). | COMMENT |
| MEDIUM⚡ | tutorials/sphinx-tutorials/multiagent_ppo.py | 532 | # **From this point on, the multi-agent-specific components have been instantiated, and we will simply use the same | COMMENT |
| MEDIUM⚡ | tutorials/sphinx-tutorials/multiagent_ppo.py | 773 | # - How to create a multi-agent environment in TorchRL, how its specs work, and how it integrates with the library; | COMMENT |
| MEDIUM⚡ | tutorials/sphinx-tutorials/multiagent_ppo.py | 775 | # - How to create different multi-agent network architectures in TorchRL (e.g., using parameter sharing, centralised cri | COMMENT |
| MEDIUM⚡ | tutorials/sphinx-tutorials/multiagent_ppo.py | 776 | # - How we can use :class:`tensordict.TensorDict` to carry multi-agent data; | COMMENT |
| MEDIUM⚡ | tutorials/sphinx-tutorials/multiagent_ppo.py | 777 | # - How we can tie all the library components (collectors, modules, replay buffers, and losses) in a multi-agent MAPPO/I | COMMENT |
| MEDIUM⚡ | tutorials/sphinx-tutorials/multiagent_ppo.py | 779 | # Now that you are proficient with multi-agent DDPG, you can check out all the TorchRL multi-agent implementations in th | COMMENT |
| MEDIUM⚡ | tutorials/sphinx-tutorials/multiagent_ppo.py | 784 | # You can also check out our other multi-agent tutorial on how to train competitive | COMMENT |
| MEDIUM⚡ | tutorials/sphinx-tutorials/multiagent_ppo.py | 787 | # If you are interested in creating or wrapping your own multi-agent environments in TorchRL, | COMMENT |
| MEDIUM | tutorials/sphinx-tutorials/multiagent_ppo.py | 76 | # In multi-agent settings, things are a bit different. We now have multiple policies :math:`\mathbf{\pi}`, | COMMENT |
| MEDIUM | tutorials/sphinx-tutorials/multiagent_ppo.py | 98 | # 2. Next, we will create a vectorized multi-agent environment, using TorchRL's | COMMENT |
| MEDIUM | tutorials/sphinx-tutorials/multiagent_ppo.py | 301 | # We stress that, in multi-agent contexts, it is paramount to provide explicitly the keys to modify. | COMMENT |
| MEDIUM | tutorials/sphinx-tutorials/getting-started-2.py | 47 | # module orchestrates the various components of your algorithm and | COMMENT |
| MEDIUM⚡ | tutorials/sphinx-tutorials/low_level_controller.py | 267 | # :class:`~torchrl.modules.GRUModule`, and the multi-agent PPO tutorial. | COMMENT |
| MEDIUM | tutorials/sphinx-tutorials/pendulum.py | 292 | # it (for example, in multi-agent settings we may want to indicate which agents need | COMMENT |
| MEDIUM | tutorials/sphinx-tutorials/coding_dqn.py | 172 | # the training script. The trainer is there to orchestrate everything for you! | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | build_nightly.sh | 4 | # Check if we're in a nightly build | COMMENT |
| LOW | packaging/verify_nightly_version.py | 15 | # Check if __version__ attribute exists | COMMENT |
| LOW | packaging/verify_nightly_version.py | 53 | # Check if it's the nightly version by looking at the version | COMMENT |
| LOW | packaging/verify_nightly_version.py | 57 | # Check if it's a nightly version (either date format or contains 'd' followed by date) | COMMENT |
| LOW | packaging/verify_nightly_version.py | 68 | # Check if it's a stable version that should not be used in nightly builds | COMMENT |
| LOW⚡ | test/test_collectors.py | 5574 | # Check if there was an exception even with exitcode 0 | COMMENT |
| LOW | test/test_mcts.py | 451 | ): # Check if action_prob_key was also populated | CODE |
| LOW⚡ | test/llm/test_conversions.py | 109 | # Check if it's a nested tensor by checking if it has the _values attribute | COMMENT |
| LOW⚡ | test/llm/test_conversions.py | 126 | # Check if it's a nested tensor | COMMENT |
| LOW | test/llm/test_conversions.py | 144 | # Check if they're nested tensors | COMMENT |
| LOW | test/llm/conftest.py | 78 | # Check if test already has a timeout marker | COMMENT |
| LOW | test/llm/test_llm_envs.py | 107 | # Set list to stack for tensordict | COMMENT |
| LOW | test/objectives/test_loss_module.py | 1529 | # Assign float to entropy_coeff | COMMENT |
| LOW | test/transforms/test_module_transforms.py | 248 | # Check if ray is initialized | COMMENT |
| LOW | sota-implementations/vla_grpo/openvla_oft/constants.py | 90 | # Assign constants to global variables | COMMENT |
| LOW | sota-implementations/dreamer/dreamer.py | 462 | # Check if profiling is complete and we should exit | COMMENT |
| LOW | sota-implementations/dreamer/dreamer_utils.py | 233 | # Check if we should stop profiling | COMMENT |
| LOW | sota-implementations/grpo/grpo-async.py | 272 | # Check if num_devices is set | COMMENT |
| LOW | sota-implementations/grpo/grpo-sync.py | 251 | # Check if num_devices is set | COMMENT |
| LOW | …lementations/expert-iteration/expert-iteration-sync.py | 407 | # Check if num_devices is set | COMMENT |
| LOW | …ementations/expert-iteration/expert-iteration-async.py | 408 | # Check if num_devices is set | COMMENT |
| LOW | sota-check/submitit-release-check.sh | 19 | # Check if the script is called with --help or without any arguments | COMMENT |
| LOW⚡ | examples/agents/recurrent_actor.py | 126 | # Print result: | COMMENT |
| LOW | .github/unittest/linux_libs/scripts_isaaclab/isaac.sh | 42 | # Check if isaaclab.sh exists | COMMENT |
| LOW | .github/workflows/auto-tag.yml | 100 | # Check if title starts with [...] | COMMENT |
| LOW | .github/workflows/release.yml | 151 | # Check if it's on a release branch matching the version | COMMENT |
| LOW | .github/workflows/release.yml | 437 | # Check if the version folder exists | COMMENT |
| LOW | .github/workflows/release.yml | 480 | # Check if changes were made | COMMENT |
| LOW | .github/workflows/release.yml | 546 | # Check if release already exists | COMMENT |
| LOW | .github/workflows/nightly_status_collector.yml | 151 | # Check if success rate dropped below 70% in last 7 days | COMMENT |
| LOW | .github/scripts/td_script.sh | 16 | # Check if ARCH is set to aarch64 | COMMENT |
| LOW | torchrl/_utils.py | 57 | # Check if user has explicitly set a global start method | COMMENT |
| LOW | torchrl/weight_update/_rpc.py | 256 | # Check if all futures are complete | COMMENT |
| LOW | torchrl/weight_update/_shared.py | 211 | # Check if per-worker weights dict is provided | COMMENT |
| LOW | torchrl/weight_update/_shared.py | 581 | # Check if policy factories are uniform or distinct | COMMENT |
| LOW | torchrl/weight_update/_shared.py | 936 | # Check if per-worker weights dict is provided | COMMENT |
| LOW | torchrl/weight_update/_shared.py | 1108 | # Check if already shutdown | COMMENT |
| LOW | torchrl/weight_update/_distributed.py | 478 | # Check if we have weights to send | COMMENT |
| LOW | torchrl/weight_update/_distributed.py | 549 | # Check if already shutdown | COMMENT |
| LOW | torchrl/weight_update/_distributed.py | 716 | # Check if all futures are complete | STRING |
| LOW | torchrl/weight_update/llm/vllm_double_buffer.py | 326 | # Check if this is an AsyncVLLM instance (uses RPC to coordinate workers) | COMMENT |
| LOW | torchrl/collectors/_multi_base.py | 1371 | # Check if any worker has died | COMMENT |
| LOW | torchrl/collectors/_multi_base.py | 1673 | # Check if it's an error dict from worker | COMMENT |
| LOW⚡ | torchrl/collectors/_single.py | 1108 | # Check if policy has meta-device parameters (sent from weight sync schemes) | COMMENT |
| LOW⚡ | torchrl/collectors/_single.py | 1245 | # Check if we need to cast to env device | COMMENT |
| LOW | torchrl/collectors/_single.py | 1449 | # Check if policy has meta-device parameters (not yet initialized) | COMMENT |
| LOW | torchrl/collectors/llm/weight_update/vllm.py | 311 | # Check if it's a LoRA model | COMMENT |
| LOW | torchrl/collectors/llm/weight_update/vllm.py | 339 | # Check if the model has a LoRA adapter | COMMENT |
| LOW | torchrl/collectors/llm/weight_update/vllm_v2.py | 119 | # Check if it's a LoRA model | COMMENT |
| LOW | torchrl/collectors/llm/weight_update/vllm_v2.py | 126 | # Check if it's a LoRA model | COMMENT |
| LOW | torchrl/collectors/llm/weight_update/vllm_v2.py | 290 | # Check if it's a LoRA model | COMMENT |
| LOW | torchrl/collectors/llm/weight_update/vllm_v2.py | 297 | # Check if it's a LoRA model | COMMENT |
| LOW | torchrl/trainers/trainers.py | 2006 | # Check if we've reached the target frames | COMMENT |
| LOW | torchrl/trainers/trainers.py | 2114 | # Check if enough frames have passed since last logging for this key | COMMENT |
| LOW | torchrl/modules/llm/backends/vllm/vllm_async.py | 254 | # Check if it's a list of lists or a single list | COMMENT |
| LOW | torchrl/modules/llm/backends/vllm/vllm_async.py | 832 | # Check if this is actually a single prompt represented as token IDs | COMMENT |
| LOW | torchrl/modules/llm/backends/vllm/vllm_async.py | 966 | # Check if this is a batch request | COMMENT |
| LOW | torchrl/modules/llm/backends/vllm/vllm_async.py | 1797 | # Check if preferred actor is overloaded | COMMENT |
| LOW | torchrl/modules/llm/backends/vllm/vllm_async.py | 2050 | # Set tensor_parallel_size to num_devices if not set | COMMENT |
| LOW | torchrl/modules/llm/backends/sglang/sglang_utils.py | 87 | # Check if subprocess died | COMMENT |
| 23 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW⚡ | test/llm/test_wrapper.py | 2396 | # Step 1: Generate the canonical response tokens with vLLM. | COMMENT |
| LOW⚡ | test/llm/test_wrapper.py | 2402 | # Step 2: Extract generated tokens and create new input for log-probs computation | COMMENT |
| LOW | test/llm/test_wrapper.py | 2445 | # Step 3: Create log-probs only wrappers | COMMENT |
| LOW | test/llm/test_wrapper.py | 2464 | # Step 4: Compute log-probs for the full sequence (original + generated) | COMMENT |
| LOW⚡ | benchmarks/test_storage_write_benchmark.py | 142 | # Step 1: Stack to contiguous (this allocates new memory) | COMMENT |
| LOW⚡ | benchmarks/test_storage_write_benchmark.py | 144 | # Step 2: Write to storage | COMMENT |
| LOW⚡ | benchmarks/test_storage_write_benchmark.py | 176 | # Step 1: Create lazy stack (no allocation, just wrapping) | COMMENT |
| LOW⚡ | benchmarks/test_storage_write_benchmark.py | 178 | # Step 2: Write to storage (storage handles the lazy stack) | COMMENT |
| LOW | .github/RELEASE_AGENT_PROMPT.md | 60 | ## Step 1: Analyze Commits for Release Notes | COMMENT |
| LOW | .github/RELEASE_AGENT_PROMPT.md | 167 | ## Step 2: Draft Release Notes | COMMENT |
| LOW | .github/RELEASE_AGENT_PROMPT.md | 231 | ## Step 3: Update Version Files | COMMENT |
| LOW | .github/RELEASE_AGENT_PROMPT.md | 270 | ## Step 4: Commit Version Changes on the main branch (Major releases only) | COMMENT |
| LOW | .github/RELEASE_AGENT_PROMPT.md | 284 | ## Step 5: Create Release Branch | COMMENT |
| LOW | .github/RELEASE_AGENT_PROMPT.md | 298 | ## Step 6: Commit Version Changes (Minor releases only) | COMMENT |
| LOW | .github/RELEASE_AGENT_PROMPT.md | 309 | ## Step 7: Create and Push Tag | COMMENT |
| LOW | .github/RELEASE_AGENT_PROMPT.md | 322 | ## Step 8: Trigger Release Workflow | COMMENT |
| LOW | .github/RELEASE_AGENT_PROMPT.md | 337 | ## Step 9: Create Draft GitHub Release | COMMENT |
| LOW | .github/RELEASE_AGENT_PROMPT.md | 350 | ## Step 10: Monitor Workflow | COMMENT |
| LOW⚡ | torchrl/weight_update/_rpc.py | 181 | # Step 1: Signal the remote collector via RPC to start receiving (async) | COMMENT |
| LOW⚡ | torchrl/weight_update/_rpc.py | 185 | # Step 2: Send weights via torch.distributed (blocks until receiver calls recv()) | COMMENT |
| LOW⚡ | torchrl/weight_update/_rpc.py | 188 | # Step 3: Wait for RPC to complete (receiver has applied weights) | COMMENT |
| LOW⚡ | torchrl/weight_update/_rpc.py | 207 | # Step 1: Signal the remote collector via RPC to start receiving (async) | COMMENT |
| LOW⚡ | torchrl/weight_update/_rpc.py | 213 | # Step 2: Send weights asynchronously via torch.distributed | COMMENT |
| LOW⚡ | torchrl/weight_update/_ray.py | 206 | # Step 1: Signal the remote actor via Ray to start receiving (async) | COMMENT |
| LOW⚡ | torchrl/weight_update/_ray.py | 214 | # Step 2: Send weights via torch.distributed (async) | COMMENT |
| LOW⚡ | torchrl/weight_update/_ray.py | 218 | # Step 3: Wait for the Ray call to complete (receiver has applied weights) | COMMENT |
| LOW⚡ | torchrl/weight_update/_ray.py | 232 | # Step 1: Signal the actor via Ray to start receiving (async) | COMMENT |
| LOW⚡ | torchrl/weight_update/_ray.py | 242 | # Step 2: Send weights via torch.distributed (async) | COMMENT |
| LOW⚡ | torchrl/weight_update/llm/sglang_nccl.py | 604 | # Step 1: Send a single HTTP request with all weight metadata. | COMMENT |
| LOW⚡ | torchrl/weight_update/llm/sglang_nccl.py | 614 | # Step 2: Broadcast each weight tensor via NCCL in the same order. | COMMENT |
| LOW⚡ | torchrl/weight_update/llm/sglang_nccl.py | 623 | # Step 3: Wait for the HTTP response confirming server received all weights | COMMENT |
| LOW⚡ | torchrl/modules/llm/backends/vllm/vllm_async.py | 1190 | # Step 1: Start trainer NCCL group in a background thread — it blocks | COMMENT |
| LOW⚡ | torchrl/modules/llm/backends/vllm/vllm_async.py | 1204 | # Step 2: Dispatch init_weight_transfer_engine to all vLLM actors | COMMENT |
| LOW⚡ | torchrl/modules/llm/backends/vllm/vllm_async.py | 1220 | # Step 3: Wait for both sides to complete | COMMENT |
| LOW⚡ | torchrl/modules/llm/backends/vllm/vllm_async.py | 1293 | # Step 1: Tell all actors to start receiving weights | COMMENT |
| LOW⚡ | torchrl/modules/llm/backends/vllm/vllm_async.py | 1298 | # Step 2: Send weights from trainer side | COMMENT |
| LOW | torchrl/modules/llm/backends/vllm/vllm_async.py | 1317 | # Step 3: Wait for all actors to finish receiving | COMMENT |
| LOW⚡ | torchrl/modules/llm/backends/sglang/sglang_server.py | 707 | # Step 1: Signal server to expect this weight | COMMENT |
| LOW⚡ | torchrl/modules/llm/backends/sglang/sglang_server.py | 712 | # Step 2: Broadcast the weight via NCCL | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/llm_browser.py | 81 | # Step 1: Basic Environment Configuration | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/llm_browser.py | 189 | # Step 2: Tool Execution Helper | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/llm_browser.py | 262 | # Step 3: Starting the Interaction | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/llm_browser.py | 292 | # Step 4: Performing the Search | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/llm_browser.py | 321 | # Step 5: Providing the Answer | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/trl_interop.py | 50 | # Step 1: build and populate a replay buffer | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/trl_interop.py | 77 | # Step 2: wrap the buffer as an IterableDataset | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/trl_interop.py | 109 | # Step 3: key filtering | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/trl_interop.py | 124 | # Step 4: device placement | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/trl_interop.py | 137 | # Step 5: nested keys | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/trl_interop.py | 181 | # Step 1: define a stand-in reward model | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/trl_interop.py | 216 | # Step 2: wrap with default TorchRL token keys | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/trl_interop.py | 234 | # Step 3: run a batch through the wrapper | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/trl_interop.py | 256 | # Step 4: custom keys and nested reward key | COMMENT |
| LOW | knowledge_base/FLAKY_TESTS.md | 42 | ## Step 1: Gather Flaky Test Information | COMMENT |
| LOW | knowledge_base/FLAKY_TESTS.md | 96 | ## Step 2: Identify Non-Deterministic Failure Causes | COMMENT |
| LOW | knowledge_base/FLAKY_TESTS.md | 131 | ## Step 3: Implement the Fix | COMMENT |
| LOW | knowledge_base/FLAKY_TESTS.md | 184 | ## Step 4: Create a PR with the Fix AND Test Validation | COMMENT |
| LOW | knowledge_base/FLAKY_TESTS.md | 274 | ## Step 5: Monitor the CI Run | COMMENT |
| LOW | knowledge_base/FLAKY_TESTS.md | 302 | ## Step 6: Verify the Fix | COMMENT |
| LOW | knowledge_base/FLAKY_TESTS.md | 328 | ## Step 7: Cleanup Before Merging | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | test/llm/test_llm_collectors.py | 644 | # We have the tokens, let's just use them | COMMENT |
| LOW | sota-implementations/expert-iteration/ei_utils.py | 88 | # we can just use 0 here. | COMMENT |
| LOW | …lementations/expert-iteration/expert-iteration-sync.py | 433 | # we can just set a big number, the buffer will be emptied anyway | COMMENT |
| MEDIUM | examples/agents/recurrent_actor.py | 182 | # its recurrent connections to maintain state across time steps. This mode may utilize CuDNN to accelerate the processin | COMMENT |
| MEDIUM | benchmarks/dreamer_v3.yaml | 31 | # The harness sets inference_backend per series; chunking follows the | COMMENT |
| MEDIUM | benchmarks/dreamer_v3.yaml | 91 | max_time: 600.0 # Safety ceiling; the harness stops after its measured rounds. | CODE |
| MEDIUM | .github/scripts/compare_pr_benchmarks.py | 45 | """Return a rate based on the robust per-round duration statistic.""" | STRING |
| LOW | torchrl/weight_update/_shared.py | 909 | # If no shared transport, just return the fresh weights | COMMENT |
| MEDIUM | torchrl/collectors/_single.py | 1810 | # this way of checking cuda is robust to lazy stacks with mismatching shapes | COMMENT |
| MEDIUM | torchrl/objectives/tdmpc2.py | 99 | """Track the robust value scale used by the TD-MPC2 policy objective.""" | STRING |
| MEDIUM | torchrl/objectives/common.py | 492 | # To make it robust to device casting, we must register list of | COMMENT |
| LOW | torchrl/objectives/llm/grpo.py | 620 | # TODO: eventually, we want to always use `get_dist` and just pass the key of the mask | COMMENT |
| MEDIUM | torchrl/objectives/llm/grpo.py | 1503 | # Cat is the most robust way to combine the trajs | COMMENT |
| MEDIUM | torchrl/trainers/algorithms/on_policy.py | 596 | # Set up comprehensive logging for on-policy training | COMMENT |
| MEDIUM | torchrl/trainers/algorithms/sac.py | 258 | # Set up comprehensive logging for SAC training | COMMENT |
| LOW | torchrl/modules/llm/policies/common.py | 747 | # For log-prob distributions, we just return the pre-computed log-probs | COMMENT |
| MEDIUM | torchrl/modules/llm/policies/transformers_wrapper.py | 1042 | # We are going to map this tokens_in to a tensordict to facilitate the padding in case we need it | COMMENT |
| MEDIUM | torchrl/modules/llm/policies/transformers_wrapper.py | 1465 | # We are going to map this tokens_in to a tensordict to facilitate the padding in case we need it | COMMENT |
| LOW | torchrl/modules/mcts/scores.py | 425 | # Don't update weights for zero probability - just return | COMMENT |
| LOW | torchrl/envs/utils.py | 1489 | # case we just return the data | COMMENT |
| MEDIUM | torchrl/envs/utils.py | 200 | """Represents the keys as a tree to facilitate iteration.""" | STRING |
| LOW | torchrl/envs/libs/dm_control.py | 318 | # just use a common EGL_DEVICE_ID environment variable for all processes. | COMMENT |
| MEDIUM | torchrl/envs/transforms/_normalization.py | 711 | # to facilitate the computation of the stats using TD internals. | COMMENT |
| MEDIUM | torchrl/envs/transforms/_misc.py | 75 | """Calls pin_memory on the tensordict to facilitate writing on CUDA devices.""" | STRING |
| MEDIUM | torchrl/data/llm/topk.py | 122 | # Cat is the most robust way to combine the trajs | COMMENT |
| MEDIUM | torchrl/data/replay_buffers/utils.py | 1200 | # We currently ignore out in this call but we should leverage that | COMMENT |
| LOW | torchrl/data/replay_buffers/utils.py | 1379 | # if Tensor, we just create a MemoryMappedTensor of the desired shape, device and dtype | COMMENT |
| LOW | torchrl/data/replay_buffers/utils.py | 1396 | # if Tensor, we just create a MemoryMappedTensor of the desired shape, device and dtype | COMMENT |
| LOW | torchrl/data/replay_buffers/storages/tensor.py | 1125 | # if Tensor, we just create a MemoryMappedTensor of the desired shape, device and dtype | COMMENT |
| MEDIUM | tutorials/sphinx-tutorials/dqn_with_rnn.py | 229 | # values for these attributes to facilitate its construction. | COMMENT |
| MEDIUM | tutorials/sphinx-tutorials/torchrl_envs.py | 655 | # One can therefore think carefully about the transform design to leverage the | COMMENT |
| LOW | tutorials/sphinx-tutorials/torchrl_envs.py | 344 | # To compose transforms, simply use the ``Compose`` class: | COMMENT |
| MEDIUM⚡ | tutorials/sphinx-tutorials/getting-started-1.py | 26 | # Accommodating all these scenarios can be quite intricate. In this succinct | COMMENT |
| MEDIUM⚡ | tutorials/sphinx-tutorials/getting-started-1.py | 27 | # tutorial, we will delve into the core functionality of TorchRL in terms of | COMMENT |
| MEDIUM | …orials/sphinx-tutorials/multiagent_competitive_ddpg.py | 337 | # Essentially we just say that the | COMMENT |
| LOW | …orials/sphinx-tutorials/multiagent_competitive_ddpg.py | 612 | # **From this point on, the multi-agent-specific components have been instantiated, and we will simply use the same | COMMENT |
| MEDIUM | tutorials/sphinx-tutorials/getting-started-0.py | 79 | # Essentially, :class:`~tensordict.TensorDict` is a generic key-based data | COMMENT |
| MEDIUM | tutorials/sphinx-tutorials/getting-started-3.py | 144 | # Data collectors are very useful when it comes to coding state-of-the-art | COMMENT |
| MEDIUM⚡ | tutorials/sphinx-tutorials/multiagent_ppo.py | 200 | # This allows leveraging the Single Instruction Multiple Data (SIMD) paradigm of GPUs and significantly | COMMENT |
| MEDIUM | tutorials/sphinx-tutorials/multiagent_ppo.py | 224 | # We will also use ``num_vmas_envs`` vectorized environments, to leverage batch simulation. | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/multiagent_ppo.py | 532 | # **From this point on, the multi-agent-specific components have been instantiated, and we will simply use the same | COMMENT |
| LOW | tutorials/sphinx-tutorials/rb_tutorial.py | 387 | # To enable multithreaded sampling, just pass a positive integer to the | COMMENT |
| MEDIUM | tutorials/sphinx-tutorials/coding_ddpg.py | 577 | # To leverage the vectorization capabilities of PyTorch, we adopt | COMMENT |
| LOW | tutorials/sphinx-tutorials/coding_ddpg.py | 184 | # accessible but this will just return a **detached** version of the | COMMENT |
| LOW | tutorials/sphinx-tutorials/coding_ddpg.py | 430 | # are collected by :func:`env.step()`, simply pass the ``from_pixels=True`` | COMMENT |
| MEDIUM | tutorials/sphinx-tutorials/pendulum.py | 170 | # To facilitate the reading and writing from that ``tensordict`` and to make sure | COMMENT |
| MEDIUM | tutorials/sphinx-tutorials/coding_dqn.py | 67 | # past, we can still pass it in conjunction with the various actions available | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | README.md | 217 | processes, weight updaters, evaluator loops, profiling hooks, and fake-data | CODE |
| LOW | test/llm/test_llm_objectives.py | 48 | "Lorem ipsum dolor sit amet,", | CODE |
| LOW | test/llm/test_llm_objectives.py | 48 | "Lorem ipsum dolor sit amet,", | CODE |
| LOW⚡ | test/objectives/test_dreamer.py | 421 | loss_td, fake_data = loss_module(tensordict.reshape(-1)) | CODE |
| LOW⚡ | test/objectives/test_dreamer.py | 422 | assert not fake_data.requires_grad | CODE |
| LOW⚡ | test/objectives/test_dreamer.py | 423 | assert fake_data.shape == torch.Size([tensordict.numel(), imagination_horizon]) | CODE |
| LOW | test/objectives/test_dreamer.py | 450 | loss_td, fake_data = loss_module(tensordict) | CODE |
| LOW | test/objectives/test_dreamer.py | 452 | assert not fake_data.requires_grad | CODE |
| LOW⚡ | test/objectives/test_dreamer_v3.py | 814 | loss_td, fake_data = loss_module( | CODE |
| LOW⚡ | test/objectives/test_dreamer_v3.py | 819 | fake_data.select(*actor_model.in_keys).detach() | CODE |
| LOW⚡ | test/objectives/test_dreamer_v3.py | 822 | fake_data["discount_weight"] * distribution.entropy().unsqueeze(-1) | CODE |
| LOW⚡ | test/objectives/test_dreamer_v3.py | 908 | loss_td, fake_data = loss_module( | CODE |
| LOW⚡ | test/objectives/test_dreamer_v3.py | 914 | fake_data["discount_weight"][0, :, 0], expected_weight | CODE |
| LOW⚡ | test/objectives/test_dreamer_v3.py | 917 | fake_data["next", "continuation"], | CODE |
| LOW⚡ | test/objectives/test_dreamer_v3.py | 918 | torch.full_like(fake_data["next", "continuation"], 0.5), | CODE |
| LOW⚡ | test/objectives/test_dreamer_v3.py | 920 | assert not fake_data["discount_weight"].requires_grad | CODE |
| LOW⚡ | test/objectives/test_dreamer_v3.py | 926 | actor_inputs = fake_data.select(*actor_model.in_keys, strict=False).detach() | CODE |
| LOW⚡ | test/objectives/test_dreamer_v3.py | 928 | log_prob = distribution.log_prob(fake_data["action"].detach()) | CODE |
| LOW⚡ | test/objectives/test_dreamer_v3.py | 929 | log_prob = _match_trailing_dim(log_prob, fake_data["lambda_target"]) | CODE |
| LOW⚡ | test/objectives/test_dreamer_v3.py | 930 | baseline_td = fake_data.select(*value_model.in_keys, strict=False) | CODE |
| LOW⚡ | test/objectives/test_dreamer_v3.py | 932 | advantage = (fake_data["lambda_target"] - baseline_td["state_value"]).detach() | CODE |
| LOW⚡ | test/objectives/test_dreamer_v3.py | 933 | expected_loss = -(fake_data["discount_weight"] * log_prob * advantage).mean() | CODE |
| LOW⚡ | test/objectives/test_dreamer_v3.py | 943 | value_loss(fake_data.detach()) | CODE |
| LOW⚡ | test/objectives/test_dreamer_v3.py | 2090 | loss_td, fake_data = loss_module( | CODE |
| LOW⚡ | test/objectives/test_dreamer_v3.py | 2093 | baseline_td = fake_data.select(*value_model.in_keys, strict=False) | CODE |
| LOW⚡ | test/objectives/test_dreamer_v3.py | 2095 | advantage = (fake_data["lambda_target"] - baseline_td["state_value"]).detach() | CODE |
| LOW⚡ | test/objectives/test_dreamer_v3.py | 2097 | fake_data["action_log_prob"], fake_data["lambda_target"] | CODE |
| LOW | test/objectives/test_dreamer_v3.py | 792 | loss_td, fake_data = loss_module(tensordict.reshape(-1)) | CODE |
| LOW | test/objectives/test_dreamer_v3.py | 868 | loss_td, fake_data = loss_module(tensordict) | CODE |
| LOW | test/objectives/test_dreamer_v3.py | 873 | assert fake_data.shape == (tensordict.shape[0], 3) | CODE |
| LOW | test/objectives/test_dreamer_v3.py | 1111 | loss_td, fake_data = actor_loss( | CODE |
| LOW | test/objectives/test_dreamer_v3.py | 1115 | assert fake_data["lambda_target"].shape[-1] == 1 | CODE |
| LOW | test/objectives/test_dreamer_v3.py | 2109 | compiled_scale(fake_data["lambda_target"]), | CODE |
| LOW | test/objectives/test_dreamer_v3.py | 2132 | loss_td, fake_data = loss_module( | CODE |
| LOW | test/objectives/test_dreamer_v3.py | 2135 | expected = -(fake_data["lambda_target"] / 10.0).mean() | CODE |
| LOW | test/objectives/test_dreamer_v3.py | 2154 | loss_td, fake_data = loss_module( | CODE |
| LOW | test/objectives/test_dreamer_v3.py | 2158 | fake_data["lambda_target"].detach(), | CODE |
| LOW | test/objectives/test_dreamer_v3.py | 2179 | loss_td, fake_data = loss_module( | CODE |
| LOW | test/objectives/test_dreamer_v3.py | 2183 | fake_data["lambda_target"].detach(), | CODE |
| LOW⚡ | test/transforms/test_module_transforms.py | 308 | dummy_data = TensorDict(observation=torch.zeros(2, 3), batch_size=[2]) | CODE |
| LOW⚡ | test/transforms/test_module_transforms.py | 311 | assert (module(dummy_data)["action"] == 2).all() | CODE |
| LOW⚡ | test/transforms/test_module_transforms.py | 319 | assert (module(dummy_data)["action"] == 1).all() | CODE |
| LOW⚡ | benchmarks/test_llm.py | 64 | "Lorem ipsum dolor sit amet", | CODE |
| LOW⚡ | benchmarks/test_llm.py | 64 | "Lorem ipsum dolor sit amet", | CODE |
| LOW⚡ | benchmarks/test_llm.py | 72 | "Lorem ipsum dolor sit amet", | CODE |
| LOW⚡ | benchmarks/test_llm.py | 72 | "Lorem ipsum dolor sit amet", | CODE |
| LOW⚡ | torchrl/objectives/dreamer.py | 299 | fake_data = self.model_based_env.rollout( | CODE |
| LOW⚡ | torchrl/objectives/dreamer.py | 305 | next_tensordict = step_mdp(fake_data, keep_other=True) | CODE |
| LOW⚡ | torchrl/objectives/dreamer.py | 309 | reward = fake_data.get(("next", self.tensor_keys.reward)) | CODE |
| LOW⚡ | torchrl/objectives/dreamer.py | 312 | fake_data.set("lambda_target", lambda_target) | CODE |
| LOW | torchrl/objectives/dreamer.py | 325 | return loss_tensordict, fake_data.data | CODE |
| LOW⚡ | torchrl/objectives/dreamer.py | 427 | def forward(self, fake_data) -> torch.Tensor: | CODE |
| LOW⚡ | torchrl/objectives/dreamer.py | 428 | lambda_target = fake_data.get("lambda_target") | CODE |
| LOW⚡ | torchrl/objectives/dreamer.py | 430 | tensordict_select = fake_data.select(*self.value_model.in_keys, strict=False) | CODE |
| LOW | torchrl/objectives/dreamer.py | 463 | self._clear_weakrefs(fake_data, loss_tensordict) | CODE |
| LOW | torchrl/objectives/dreamer.py | 465 | return loss_tensordict, fake_data | CODE |
| LOW⚡ | torchrl/objectives/dreamer_v3.py | 810 | fake_data = self.model_based_env.rollout( | CODE |
| LOW⚡ | torchrl/objectives/dreamer_v3.py | 819 | next_tensordict = step_mdp(fake_data, keep_other=True) | CODE |
| LOW⚡ | torchrl/objectives/dreamer_v3.py | 824 | reward = fake_data.get(("next", self.tensor_keys.reward)) | CODE |
| LOW⚡ | torchrl/objectives/dreamer_v3.py | 830 | first_td = fake_data[..., :1].select( | CODE |
| 15 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW⚡ | test/llm/test_wrapper.py | 2396 | # Step 1: Generate the canonical response tokens with vLLM. | COMMENT |
| LOW⚡ | test/llm/test_wrapper.py | 2402 | # Step 2: Extract generated tokens and create new input for log-probs computation | COMMENT |
| LOW | test/llm/test_wrapper.py | 2445 | # Step 3: Create log-probs only wrappers | COMMENT |
| LOW | test/llm/test_wrapper.py | 2464 | # Step 4: Compute log-probs for the full sequence (original + generated) | COMMENT |
| LOW⚡ | benchmarks/test_storage_write_benchmark.py | 142 | # Step 1: Stack to contiguous (this allocates new memory) | COMMENT |
| LOW⚡ | benchmarks/test_storage_write_benchmark.py | 144 | # Step 2: Write to storage | COMMENT |
| LOW⚡ | benchmarks/test_storage_write_benchmark.py | 176 | # Step 1: Create lazy stack (no allocation, just wrapping) | COMMENT |
| LOW⚡ | benchmarks/test_storage_write_benchmark.py | 178 | # Step 2: Write to storage (storage handles the lazy stack) | COMMENT |
| LOW⚡ | torchrl/weight_update/_rpc.py | 181 | # Step 1: Signal the remote collector via RPC to start receiving (async) | COMMENT |
| LOW⚡ | torchrl/weight_update/_rpc.py | 185 | # Step 2: Send weights via torch.distributed (blocks until receiver calls recv()) | COMMENT |
| LOW⚡ | torchrl/weight_update/_rpc.py | 188 | # Step 3: Wait for RPC to complete (receiver has applied weights) | COMMENT |
| LOW⚡ | torchrl/weight_update/_rpc.py | 207 | # Step 1: Signal the remote collector via RPC to start receiving (async) | COMMENT |
| LOW⚡ | torchrl/weight_update/_rpc.py | 213 | # Step 2: Send weights asynchronously via torch.distributed | COMMENT |
| LOW⚡ | torchrl/weight_update/_ray.py | 206 | # Step 1: Signal the remote actor via Ray to start receiving (async) | COMMENT |
| LOW⚡ | torchrl/weight_update/_ray.py | 214 | # Step 2: Send weights via torch.distributed (async) | COMMENT |
| LOW⚡ | torchrl/weight_update/_ray.py | 218 | # Step 3: Wait for the Ray call to complete (receiver has applied weights) | COMMENT |
| LOW⚡ | torchrl/weight_update/_ray.py | 232 | # Step 1: Signal the actor via Ray to start receiving (async) | COMMENT |
| LOW⚡ | torchrl/weight_update/_ray.py | 242 | # Step 2: Send weights via torch.distributed (async) | COMMENT |
| LOW⚡ | torchrl/weight_update/llm/sglang_nccl.py | 604 | # Step 1: Send a single HTTP request with all weight metadata. | COMMENT |
| LOW⚡ | torchrl/weight_update/llm/sglang_nccl.py | 614 | # Step 2: Broadcast each weight tensor via NCCL in the same order. | COMMENT |
| LOW⚡ | torchrl/weight_update/llm/sglang_nccl.py | 623 | # Step 3: Wait for the HTTP response confirming server received all weights | COMMENT |
| LOW⚡ | torchrl/modules/llm/backends/vllm/vllm_async.py | 1190 | # Step 1: Start trainer NCCL group in a background thread — it blocks | COMMENT |
| LOW⚡ | torchrl/modules/llm/backends/vllm/vllm_async.py | 1204 | # Step 2: Dispatch init_weight_transfer_engine to all vLLM actors | COMMENT |
| LOW⚡ | torchrl/modules/llm/backends/vllm/vllm_async.py | 1220 | # Step 3: Wait for both sides to complete | COMMENT |
| LOW⚡ | torchrl/modules/llm/backends/vllm/vllm_async.py | 1293 | # Step 1: Tell all actors to start receiving weights | COMMENT |
| LOW⚡ | torchrl/modules/llm/backends/vllm/vllm_async.py | 1298 | # Step 2: Send weights from trainer side | COMMENT |
| LOW | torchrl/modules/llm/backends/vllm/vllm_async.py | 1317 | # Step 3: Wait for all actors to finish receiving | COMMENT |
| LOW⚡ | torchrl/modules/llm/backends/sglang/sglang_server.py | 707 | # Step 1: Signal server to expect this weight | COMMENT |
| LOW⚡ | torchrl/modules/llm/backends/sglang/sglang_server.py | 712 | # Step 2: Broadcast the weight via NCCL | COMMENT |
| LOW | torchrl/modules/distributions/discrete.py | 844 | # For token-level masking, we need to check if specific tokens are masked | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/llm_browser.py | 81 | # Step 1: Basic Environment Configuration | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/llm_browser.py | 189 | # Step 2: Tool Execution Helper | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/llm_browser.py | 262 | # Step 3: Starting the Interaction | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/llm_browser.py | 292 | # Step 4: Performing the Search | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/llm_browser.py | 321 | # Step 5: Providing the Answer | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/trl_interop.py | 50 | # Step 1: build and populate a replay buffer | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/trl_interop.py | 77 | # Step 2: wrap the buffer as an IterableDataset | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/trl_interop.py | 109 | # Step 3: key filtering | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/trl_interop.py | 124 | # Step 4: device placement | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/trl_interop.py | 137 | # Step 5: nested keys | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/trl_interop.py | 181 | # Step 1: define a stand-in reward model | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/trl_interop.py | 216 | # Step 2: wrap with default TorchRL token keys | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/trl_interop.py | 234 | # Step 3: run a batch through the wrapper | COMMENT |
| LOW⚡ | tutorials/sphinx-tutorials/trl_interop.py | 256 | # Step 4: custom keys and nested reward key | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | torchrl/envs/transforms/_base.py | 212 | - Don't forget to edits the specs if needed: top level: :meth:`~torchrl.envs.Transform.transform_output_spec`, | STRING |
| MEDIUM | torchrl/data/llm/history.py | 316 | >>> # Now you can use it with auto-detection | CODE |
| MEDIUM | tutorials/sphinx-tutorials/dqn_with_rnn.py | 266 | # As mentioned earlier, we still need a | COMMENT |
| LOW | tutorials/sphinx-tutorials/dqn_with_rnn.py | 61 | # If you are running this in Google Colab, make sure you install the following dependencies: | COMMENT |
| LOW | tutorials/sphinx-tutorials/torchrl_envs.py | 280 | # To run this part of the tutorial, make sure you have installed dm_control: | COMMENT |
| MEDIUM | tutorials/sphinx-tutorials/getting-started-1.py | 310 | # - Have a look at how you can use an RNN within the policy (a | COMMENT |
| MEDIUM⚡ | …orials/sphinx-tutorials/multiagent_competitive_ddpg.py | 948 | # Finally, you can modify the parameters of this tutorial to try many other configurations and scenarios | COMMENT |
| MEDIUM⚡ | …orials/sphinx-tutorials/multiagent_competitive_ddpg.py | 952 | # Here are a few videos of some possible scenarios you can try in VMAS. | COMMENT |
| MEDIUM | …orials/sphinx-tutorials/multiagent_competitive_ddpg.py | 663 | # To store your buffer on the GPU, you can use :class:`~torchrl.data.replay_buffers.LazyTensorStorage`, passing the desi | COMMENT |
| LOW | …orials/sphinx-tutorials/multiagent_competitive_ddpg.py | 43 | # If you are running this in Google Colab, make sure you install the following dependencies: | COMMENT |
| MEDIUM | tutorials/sphinx-tutorials/getting-started-4.py | 31 | # portable CSV logger (:class:`~torchrl.record.loggers.csv.CSVLogger`) that you can use | COMMENT |
| MEDIUM | tutorials/sphinx-tutorials/export.py | 335 | # Here's an example of how you can use AOTInductor to export your policy, inspired by the | COMMENT |
| MEDIUM⚡ | tutorials/sphinx-tutorials/multiagent_ppo.py | 791 | # Finally, you can modify the parameters of this tutorial to try many other configurations and scenarios | COMMENT |
| MEDIUM⚡ | tutorials/sphinx-tutorials/multiagent_ppo.py | 793 | # Here are a few videos of some possible scenarios you can try in VMAS. | COMMENT |
| LOW | tutorials/sphinx-tutorials/multiagent_ppo.py | 43 | # If you are running this in Google Colab, make sure you install the following dependencies: | COMMENT |
| LOW | tutorials/sphinx-tutorials/coding_ddpg.py | 286 | # When computing this value, we must make sure to take the value parameters out | COMMENT |
| LOW | tutorials/sphinx-tutorials/getting-started-2.py | 111 | # loss. If you want to make sure you're fully in control of what is happening, | COMMENT |
| LOW | tutorials/sphinx-tutorials/coding_ppo.py | 39 | # If you are running this in Google Colab, make sure you install the following dependencies: | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| CRITICAL⚡ | test/test_render.py | 1356 | env.base_env.unwrapped.data.qpos.copy(), | CODE |
| CRITICAL⚡ | test/test_render.py | 1362 | env.base_env.unwrapped.data.qpos.copy(), | CODE |
| CRITICAL | torchrl/envs/libs/gym.py | 819 | return gym.envs.registration.registry.env_specs.keys() | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | test/objectives/test_bc.py | 41 | CODE | |
| MEDIUM | test/objectives/test_bc.py | 42 | CODE | |
| MEDIUM | torchrl/envs/common.py | 1069 | CODE | |
| MEDIUM | torchrl/envs/transforms/_normalization.py | 912 | CODE | |
| MEDIUM | torchrl/envs/transforms/_normalization.py | 913 | CODE | |
| MEDIUM | torchrl/envs/transforms/_normalization.py | 915 | CODE | |
| MEDIUM | torchrl/envs/transforms/_normalization.py | 916 | CODE | |
| MEDIUM | torchrl/envs/transforms/_normalization.py | 917 | CODE | |
| MEDIUM | torchrl/envs/transforms/_normalization.py | 918 | CODE | |
| MEDIUM | torchrl/envs/transforms/_normalization.py | 919 | CODE | |
| MEDIUM | torchrl/envs/transforms/_normalization.py | 924 | CODE | |
| MEDIUM | torchrl/envs/transforms/_normalization.py | 925 | CODE | |
| MEDIUM | torchrl/envs/transforms/_normalization.py | 937 | CODE | |
| MEDIUM | torchrl/envs/transforms/_normalization.py | 938 | CODE | |
| MEDIUM | torchrl/envs/transforms/_normalization.py | 939 | CODE | |
| MEDIUM | torchrl/envs/transforms/_normalization.py | 941 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | tutorials/sphinx-tutorials/rb_tutorial.py | 807 | # ``("collector", "traj_ids")``. In this example, we construct data | COMMENT |
| HIGH | tutorials/sphinx-tutorials/pendulum.py | 307 | # In this example, we do not pass a done state as this is not mandatory | COMMENT |
| HIGH | tutorials/sphinx-tutorials/pendulum.py | 852 | # In this example, we will train a simple policy using the reward as a | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | docs/build_local.sh | 4 | # Usage: | COMMENT |
| LOW | …b/unittest/helpers/assert_torch_tensordict_versions.sh | 4 | # Usage: | COMMENT |
| LOW | .github/unittest/helpers/assert_torch_version.sh | 4 | # Usage: | COMMENT |
| LOW | .github/workflows/auto-tag.yml | 3 | # Usage: | COMMENT |
| LOW | .github/workflows/assign.yml | 3 | # Usage: | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | torchrl/envs/llm/libs/mlgym.py | 228 | # TODO: implement add commands method in environment | COMMENT |
| LOW | torchrl/data/map/tree.py | 228 | # TODO: implement specs | COMMENT |
| LOW | torchrl/data/map/tree.py | 245 | # TODO: implement specs | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | test/test_docstring_args_checker.py | 31 | def helper(first, second): | STRING |
| LOW | test/test_docstring_args_checker.py | 71 | def helper(first, second, *, mode="strict", retries=0): | STRING |
| LOW | test/test_docstring_args_checker.py | 93 | def helper(first, second, *, mode="strict", retries=0): | STRING |
| LOW | torchrl/_utils.py | 250 | >>> def my_function(): | STRING |
| LOW | torchrl/_utils.py | 1372 | ... def my_function(): | STRING |