Datasets, Transforms and Models specific to Computer Vision
This report summarizes scanner evidence for pytorch/vision, a Python project with 17,951 GitHub stars. SynthScan examined 120,011 lines of code across 426 source files, recording 1675 pattern matches distributed across 18 syntactic categories. The legacy adjusted pattern signal is 15.7 (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? 902 finding(s).
Are imports declared and package/API names verified? 587 finding(s).
Are wrappers, guards, and repeated structures necessary? 815 finding(s).
Which changes need focused human review? 1675 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 1675 distinct pattern matches across 18 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 | 319 | def make_image_stable_extension(): | CODE |
| LOW | test/smoke_test.py | 24 | def smoke_test_torchvision_read_decode() -> None: | CODE |
| LOW | test/smoke_test.py | 69 | def smoke_test_torchvision_decode_jpeg(device: str = "cpu"): | CODE |
| LOW | test/test_utils.py | 42 | def test_make_grid_not_inplace(): | CODE |
| LOW | test/test_utils.py | 56 | def test_normalize_in_make_grid(): | CODE |
| LOW | test/test_utils.py | 83 | def test_save_image_single_pixel(): | CODE |
| LOW | test/test_utils.py | 91 | def test_save_image_file_object(): | CODE |
| LOW | test/test_utils.py | 103 | def test_save_image_single_pixel_file_object(): | CODE |
| LOW | test/test_utils.py | 138 | def test_draw_boxes_with_coloured_labels(): | CODE |
| LOW | test/test_utils.py | 153 | def test_draw_boxes_with_coloured_label_backgrounds(): | CODE |
| LOW | test/test_utils.py | 170 | def test_draw_boxes_with_coloured_label_text_boxes(): | CODE |
| LOW | test/test_utils.py | 208 | def test_draw_rotated_boxes_fill(): | CODE |
| LOW | test/test_utils.py | 262 | def test_draw_boxes_grayscale(): | CODE |
| LOW | test/test_utils.py | 321 | def test_draw_segmentation_masks(colors, alpha, device): | CODE |
| LOW | test/test_utils.py | 363 | def test_draw_segmentation_masks_dtypes(): | CODE |
| LOW | test/test_utils.py | 384 | def test_draw_segmentation_masks_errors(device): | CODE |
| LOW | test/test_utils.py | 421 | def test_draw_no_segmention_mask(device): | CODE |
| LOW | test/test_utils.py | 430 | def test_draw_keypoints_vanilla(): | CODE |
| LOW | test/test_utils.py | 465 | def test_draw_keypoints_colored(colors): | CODE |
| LOW | test/test_utils.py | 492 | def test_draw_keypoints_visibility(connectivity, vis): | CODE |
| LOW | test/test_utils.py | 531 | def test_draw_keypoints_visibility_default(): | CODE |
| LOW | test/test_utils.py | 555 | def test_draw_keypoints_dtypes(): | CODE |
| LOW | test/test_utils.py | 571 | def test_draw_keypoints_errors(): | CODE |
| LOW | test/test_utils.py | 636 | def test_flow_to_image_errors(input_flow, match): | CODE |
| LOW | test/conftest.py | 25 | def pytest_collection_modifyitems(items): | CODE |
| LOW | test/test_transforms_video.py | 40 | def test_random_resized_crop_video(self): | CODE |
| LOW | test/test_transforms_video.py | 116 | def samples_from_standard_normal(tensor): | CODE |
| LOW | test/test_transforms_video.py | 164 | def test_random_horizontal_flip_video(self, p): | CODE |
| LOW | test/test_datasets_utils.py | 50 | def test_get_redirect_url_max_hops_exceeded(self, mocker): | CODE |
| LOW | test/test_datasets_utils.py | 82 | def test_get_google_drive_file_id(self): | CODE |
| LOW | test/test_datasets_utils.py | 89 | def test_get_google_drive_file_id_invalid_url(self): | CODE |
| LOW | test/test_datasets_utils.py | 117 | def test_detect_file_type_incompatible(self, file): | CODE |
| LOW | test/test_datasets_utils.py | 146 | def test_decompress_no_compression(self): | CODE |
| LOW | test/test_datasets_utils.py | 151 | def test_decompress_remove_finished(self, tmpdir, use_pathlib): | CODE |
| LOW | test/test_datasets_utils.py | 179 | def test_extract_archive_defer_to_decompress(self, extension, remove_finished, mocker): | CODE |
| LOW | test/test_datasets_utils.py | 212 | def test_extract_tar_path_traversal(self, tmpdir, member_name): | CODE |
| LOW | test/test_datasets_utils.py | 289 | def test_make_dataset_no_valid_files(tmpdir, kwargs, expected_error_msg): | CODE |
| LOW | test/test_datasets.py | 149 | def _create_annotation_folder(self, root, name, file_name_fn, num_examples): | CODE |
| LOW | test/test_datasets.py | 385 | def test_feature_types_target_color(self): | CODE |
| LOW | test/test_datasets.py | 391 | def test_feature_types_target_polygon(self): | CODE |
| LOW | test/test_datasets.py | 1053 | def test_not_found_or_corrupted(self): | CODE |
| LOW | test/test_datasets.py | 1330 | def test_not_found_or_corrupted(self): | CODE |
| LOW | test/test_datasets.py | 1700 | def _is_valid_file_to_extensions(self, is_valid_file): | CODE |
| LOW | test/test_datasets.py | 1992 | def test_tv_decode_image_support(self): | CODE |
| LOW | test/test_datasets.py | 2727 | def _meta_to_split_and_classification_ann(self, meta, idx): | CODE |
| LOW | test/test_datasets.py | 3403 | def _create_annotation_folder(num_examples: int, root_dir: str): | CODE |
| LOW | test/test_datasets.py | 3511 | def test_augmented_view_usage(self): | CODE |
| LOW | test/test_datasets_video_utils.py | 72 | def test_video_clips_custom_fps(self, tmpdir): | CODE |
| LOW | test/test_datasets_video_utils.py | 83 | def test_compute_clips_for_video(self): | CODE |
| LOW | test/test_backbone_utils.py | 98 | def _create_feature_extractor(self, *args, **kwargs): | CODE |
| LOW | test/test_backbone_utils.py | 131 | def test_build_fx_feature_extractor(self, model_name): | CODE |
| LOW | test/test_backbone_utils.py | 162 | def test_node_name_conventions(self): | CODE |
| LOW | test/test_backbone_utils.py | 186 | def test_feature_extraction_methods_equivalence(self): | CODE |
| LOW | test/test_backbone_utils.py | 207 | def test_jit_forward_backward(self, model_name): | CODE |
| LOW | test/test_backbone_utils.py | 294 | def test_leaf_module_and_function(self): | CODE |
| LOW | test/test_transforms_tensor.py | 31 | def _test_transform_vs_scripted(transform, s_transform, tensor, msg=None): | CODE |
| LOW | test/test_transforms_tensor.py | 39 | def _test_transform_vs_scripted_on_batch(transform, s_transform, batch_tensors, msg=None): | CODE |
| LOW | test/test_transforms_tensor.py | 140 | def test_color_jitter_brightness(self, brightness, device, channels): | CODE |
| LOW | test/test_transforms_tensor.py | 154 | def test_color_jitter_contrast(self, contrast, device, channels): | CODE |
| LOW | test/test_transforms_tensor.py | 168 | def test_color_jitter_saturation(self, saturation, device, channels): | CODE |
| 526 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | hubconf.py | 4 | CODE | |
| LOW | hubconf.py | 4 | CODE | |
| LOW | hubconf.py | 5 | CODE | |
| LOW | hubconf.py | 6 | CODE | |
| LOW | hubconf.py | 6 | CODE | |
| LOW | hubconf.py | 6 | CODE | |
| LOW | hubconf.py | 6 | CODE | |
| LOW | hubconf.py | 7 | CODE | |
| LOW | hubconf.py | 7 | CODE | |
| LOW | hubconf.py | 7 | CODE | |
| LOW | hubconf.py | 7 | CODE | |
| LOW | hubconf.py | 8 | CODE | |
| LOW | hubconf.py | 8 | CODE | |
| LOW | hubconf.py | 8 | CODE | |
| LOW | hubconf.py | 8 | CODE | |
| LOW | hubconf.py | 8 | CODE | |
| LOW | hubconf.py | 8 | CODE | |
| LOW | hubconf.py | 8 | CODE | |
| LOW | hubconf.py | 8 | CODE | |
| LOW | hubconf.py | 8 | CODE | |
| LOW | hubconf.py | 8 | CODE | |
| LOW | hubconf.py | 8 | CODE | |
| LOW | hubconf.py | 21 | CODE | |
| LOW | hubconf.py | 22 | CODE | |
| LOW | hubconf.py | 23 | CODE | |
| LOW | hubconf.py | 24 | CODE | |
| LOW | hubconf.py | 24 | CODE | |
| LOW | hubconf.py | 24 | CODE | |
| LOW | hubconf.py | 24 | CODE | |
| LOW | hubconf.py | 25 | CODE | |
| LOW | hubconf.py | 26 | CODE | |
| LOW | hubconf.py | 26 | CODE | |
| LOW | hubconf.py | 27 | CODE | |
| LOW | hubconf.py | 27 | CODE | |
| LOW | hubconf.py | 28 | CODE | |
| LOW | hubconf.py | 28 | CODE | |
| LOW | hubconf.py | 28 | CODE | |
| LOW | hubconf.py | 28 | CODE | |
| LOW | hubconf.py | 28 | CODE | |
| LOW | hubconf.py | 28 | CODE | |
| LOW | hubconf.py | 28 | CODE | |
| LOW | hubconf.py | 28 | CODE | |
| LOW | hubconf.py | 28 | CODE | |
| LOW | hubconf.py | 28 | CODE | |
| LOW | hubconf.py | 28 | CODE | |
| LOW | hubconf.py | 28 | CODE | |
| LOW | hubconf.py | 28 | CODE | |
| LOW | hubconf.py | 28 | CODE | |
| LOW | hubconf.py | 28 | CODE | |
| LOW | hubconf.py | 45 | CODE | |
| LOW | hubconf.py | 45 | CODE | |
| LOW | hubconf.py | 45 | CODE | |
| LOW | hubconf.py | 45 | CODE | |
| LOW | hubconf.py | 45 | CODE | |
| LOW | hubconf.py | 45 | CODE | |
| LOW | hubconf.py | 45 | CODE | |
| LOW | hubconf.py | 45 | CODE | |
| LOW | hubconf.py | 45 | CODE | |
| LOW | hubconf.py | 45 | CODE | |
| LOW | hubconf.py | 57 | CODE | |
| 527 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | references/classification/utils.py | 0 | track a series of values and provide access to smoothed values over a window or the global series average. | STRING |
| HIGH | references/depth/stereo/utils/logger.py | 0 | track a series of values and provide access to smoothed values over a window or the global series average. | STRING |
| HIGH | references/segmentation/utils.py | 0 | track a series of values and provide access to smoothed values over a window or the global series average. | STRING |
| HIGH | references/video_classification/utils.py | 0 | track a series of values and provide access to smoothed values over a window or the global series average. | STRING |
| HIGH | references/optical_flow/utils.py | 0 | track a series of values and provide access to smoothed values over a window or the global series average. | STRING |
| HIGH | references/detection/utils.py | 0 | track a series of values and provide access to smoothed values over a window or the global series average. | STRING |
| HIGH | references/classification/utils.py | 0 | this function disables printing when not in master process | STRING |
| HIGH | references/segmentation/utils.py | 0 | this function disables printing when not in master process | STRING |
| HIGH | references/video_classification/utils.py | 0 | this function disables printing when not in master process | STRING |
| HIGH | references/detection/utils.py | 0 | this function disables printing when not in master process | STRING |
| HIGH | torchvision/datasets/stl10.py | 0 | args: index (int): index returns: tuple: (image, target) where target is index of the target character class. | STRING |
| HIGH | torchvision/datasets/usps.py | 0 | args: index (int): index returns: tuple: (image, target) where target is index of the target character class. | STRING |
| HIGH | torchvision/datasets/svhn.py | 0 | args: index (int): index returns: tuple: (image, target) where target is index of the target character class. | STRING |
| HIGH | torchvision/datasets/semeion.py | 0 | args: index (int): index returns: tuple: (image, target) where target is index of the target character class. | STRING |
| HIGH | torchvision/datasets/cifar.py | 0 | args: index (int): index returns: tuple: (image, target) where target is index of the target character class. | STRING |
| HIGH | torchvision/datasets/caltech.py | 0 | args: index (int): index returns: tuple: (image, target) where target is index of the target character class. | STRING |
| HIGH | torchvision/datasets/mnist.py | 0 | args: index (int): index returns: tuple: (image, target) where target is index of the target character class. | STRING |
| HIGH | torchvision/datasets/folder.py | 0 | args: index (int): index returns: tuple: (image, target) where target is index of the target character class. | STRING |
| HIGH | torchvision/datasets/fakedata.py | 0 | args: index (int): index returns: tuple: (image, target) where target is index of the target character class. | STRING |
| HIGH | torchvision/datasets/omniglot.py | 0 | args: index (int): index returns: tuple: (image, target) where target is index of the target character class. | STRING |
| HIGH | torchvision/models/shufflenetv2.py | 0 | these weights were trained from scratch by using torchvision's `new training recipe <https://pytorch.org/blog/how-to-tra | STRING |
| HIGH | torchvision/models/mnasnet.py | 0 | these weights were trained from scratch by using torchvision's `new training recipe <https://pytorch.org/blog/how-to-tra | STRING |
| HIGH | torchvision/models/resnet.py | 0 | these weights were trained from scratch by using torchvision's `new training recipe <https://pytorch.org/blog/how-to-tra | STRING |
| HIGH | torchvision/models/regnet.py | 0 | these weights reproduce closely the results of the paper using a simplified training recipe. | STRING |
| HIGH | torchvision/models/squeezenet.py | 0 | these weights reproduce closely the results of the paper using a simplified training recipe. | STRING |
| HIGH | torchvision/models/resnet.py | 0 | these weights reproduce closely the results of the paper using a simplified training recipe. | STRING |
| HIGH | torchvision/models/mobilenetv2.py | 0 | these weights reproduce closely the results of the paper using a simplified training recipe. | STRING |
| HIGH | torchvision/models/swin_transformer.py | 0 | these weights reproduce closely the results of the paper using a simplified training recipe. | STRING |
| HIGH | torchvision/models/alexnet.py | 0 | these weights reproduce closely the results of the paper using a simplified training recipe. | STRING |
| HIGH | torchvision/models/regnet.py | 0 | these weights improve marginally upon the results of the original paper by using a modified version of torchvision's `ne | STRING |
| HIGH | torchvision/models/efficientnet.py | 0 | these weights improve marginally upon the results of the original paper by using a modified version of torchvision's `ne | STRING |
| HIGH | torchvision/models/mobilenetv2.py | 0 | these weights improve marginally upon the results of the original paper by using a modified version of torchvision's `ne | STRING |
| HIGH | torchvision/models/convnext.py | 0 | these weights improve marginally upon the results of the original paper by using a modified version of torchvision's `ne | STRING |
| HIGH | torchvision/models/mobilenetv3.py | 0 | these weights improve marginally upon the results of the original paper by using a modified version of torchvision's `ne | STRING |
| HIGH | torchvision/models/segmentation/fcn.py | 0 | these weights were trained on a subset of coco, using only the 20 categories that are present in the pascal voc dataset. | STRING |
| HIGH | torchvision/models/segmentation/lraspp.py | 0 | these weights were trained on a subset of coco, using only the 20 categories that are present in the pascal voc dataset. | STRING |
| HIGH | torchvision/models/segmentation/deeplabv3.py | 0 | these weights were trained on a subset of coco, using only the 20 categories that are present in the pascal voc dataset. | STRING |
| HIGH | torchvision/models/quantization/shufflenetv2.py | 0 | fuse conv/bn/relu modules in resnet models fuse conv+bn+relu/ conv+relu/conv+bn modules to prepare for quantization. mod | STRING |
| HIGH | torchvision/models/quantization/googlenet.py | 0 | fuse conv/bn/relu modules in resnet models fuse conv+bn+relu/ conv+relu/conv+bn modules to prepare for quantization. mod | STRING |
| HIGH | torchvision/models/quantization/inception.py | 0 | fuse conv/bn/relu modules in resnet models fuse conv+bn+relu/ conv+relu/conv+bn modules to prepare for quantization. mod | STRING |
| HIGH | torchvision/models/quantization/resnet.py | 0 | fuse conv/bn/relu modules in resnet models fuse conv+bn+relu/ conv+relu/conv+bn modules to prepare for quantization. mod | STRING |
| HIGH | torchvision/models/quantization/shufflenetv2.py | 0 | these weights were produced by doing quantization aware training (eager mode) on top of the unquantized weights listed b | STRING |
| HIGH | torchvision/models/quantization/googlenet.py | 0 | these weights were produced by doing quantization aware training (eager mode) on top of the unquantized weights listed b | STRING |
| HIGH | torchvision/models/quantization/inception.py | 0 | these weights were produced by doing quantization aware training (eager mode) on top of the unquantized weights listed b | STRING |
| HIGH | torchvision/models/quantization/resnet.py | 0 | these weights were produced by doing quantization aware training (eager mode) on top of the unquantized weights listed b | STRING |
| HIGH | torchvision/models/quantization/mobilenetv2.py | 0 | these weights were produced by doing quantization aware training (eager mode) on top of the unquantized weights listed b | STRING |
| HIGH | torchvision/models/quantization/mobilenetv3.py | 0 | these weights were produced by doing quantization aware training (eager mode) on top of the unquantized weights listed b | STRING |
| HIGH | torchvision/models/detection/ssdlite.py | 0 | these weights were produced by following a similar training recipe as on the paper. | STRING |
| HIGH | torchvision/models/detection/ssd.py | 0 | these weights were produced by following a similar training recipe as on the paper. | STRING |
| HIGH | torchvision/models/detection/faster_rcnn.py | 0 | these weights were produced by following a similar training recipe as on the paper. | STRING |
| HIGH | torchvision/models/detection/fcos.py | 0 | these weights were produced by following a similar training recipe as on the paper. | STRING |
| HIGH | torchvision/models/detection/mask_rcnn.py | 0 | these weights were produced by following a similar training recipe as on the paper. | STRING |
| HIGH | torchvision/models/detection/retinanet.py | 0 | these weights were produced by following a similar training recipe as on the paper. | STRING |
| HIGH | torchvision/models/detection/keypoint_rcnn.py | 0 | these weights were produced by following a similar training recipe as on the paper. | STRING |
| HIGH | torchvision/models/detection/faster_rcnn.py | 0 | implements keypoint r-cnn. the input to the model is expected to be a list of tensors, each of shape [c, h, w], one for | STRING |
| HIGH | torchvision/models/detection/mask_rcnn.py | 0 | implements keypoint r-cnn. the input to the model is expected to be a list of tensors, each of shape [c, h, w], one for | STRING |
| HIGH | torchvision/models/detection/keypoint_rcnn.py | 0 | implements keypoint r-cnn. the input to the model is expected to be a list of tensors, each of shape [c, h, w], one for | STRING |
| HIGH | torchvision/models/detection/faster_rcnn.py | 0 | these weights were produced using an enhanced training recipe to boost the model accuracy. | STRING |
| HIGH | torchvision/models/detection/mask_rcnn.py | 0 | these weights were produced using an enhanced training recipe to boost the model accuracy. | STRING |
| HIGH | torchvision/models/detection/retinanet.py | 0 | these weights were produced using an enhanced training recipe to boost the model accuracy. | STRING |
| 6 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | gallery/others/plot_optical_flow.py | 51 | # -------------------------------- | COMMENT |
| MEDIUM | gallery/others/plot_optical_flow.py | 112 | # ---------------------------------- | COMMENT |
| MEDIUM | gallery/others/plot_optical_flow.py | 152 | # --------------------------- | COMMENT |
| MEDIUM | gallery/others/plot_optical_flow.py | 174 | # --------------------------------------- | COMMENT |
| MEDIUM | gallery/others/plot_visualization_utils.py | 39 | # ---------------------------- | COMMENT |
| MEDIUM | gallery/others/plot_visualization_utils.py | 57 | # -------------------------- | COMMENT |
| MEDIUM | gallery/others/plot_visualization_utils.py | 105 | # ------------------------------ | COMMENT |
| MEDIUM | gallery/others/plot_visualization_utils.py | 357 | # ------------------------------ | COMMENT |
| MEDIUM | gallery/others/plot_repurposing_annotations.py | 62 | # ----------------------------------------------- | COMMENT |
| MEDIUM | gallery/others/plot_repurposing_annotations.py | 162 | # ---------------------------------------------------- | COMMENT |
| MEDIUM | gallery/transforms/plot_cutmix_mixup.py | 32 | # ----------------------- | COMMENT |
| MEDIUM | gallery/transforms/plot_cutmix_mixup.py | 69 | # ----------------------------- | COMMENT |
| MEDIUM | gallery/transforms/plot_cutmix_mixup.py | 125 | # ------------------------- | COMMENT |
| MEDIUM | gallery/transforms/plot_transforms_getting_started.py | 36 | # ---------- | COMMENT |
| MEDIUM | gallery/transforms/plot_transforms_getting_started.py | 49 | # -------------------------------------- | COMMENT |
| MEDIUM | gallery/transforms/plot_transforms_getting_started.py | 83 | # ------------------------------- | COMMENT |
| MEDIUM | gallery/transforms/plot_transforms_getting_started.py | 128 | # -------------------- | COMMENT |
| MEDIUM | gallery/transforms/plot_transforms_getting_started.py | 156 | # ------------------------ | COMMENT |
| MEDIUM | gallery/transforms/plot_transforms_getting_started.py | 225 | # ------------------------------------------ | COMMENT |
| MEDIUM | gallery/transforms/plot_custom_transforms.py | 24 | # =============================================================== | COMMENT |
| MEDIUM | gallery/transforms/plot_custom_transforms.py | 84 | # ===================================== | COMMENT |
| MEDIUM | gallery/transforms/plot_custom_transforms.py | 113 | # ----------------------------------------- | COMMENT |
| MEDIUM | gallery/transforms/plot_custom_transforms.py | 151 | # -------------------------------------- | COMMENT |
| MEDIUM | gallery/transforms/plot_keypoints_transforms.py | 43 | # ------------------------------- | COMMENT |
| MEDIUM | gallery/transforms/plot_keypoints_transforms.py | 75 | # ------------------------ | COMMENT |
| MEDIUM | gallery/transforms/plot_transforms_illustrations.py | 37 | # -------------------- | COMMENT |
| MEDIUM | gallery/transforms/plot_transforms_illustrations.py | 141 | # ---------------------- | COMMENT |
| MEDIUM | gallery/transforms/plot_transforms_illustrations.py | 253 | # ----------------------- | COMMENT |
| MEDIUM | gallery/transforms/plot_transforms_illustrations.py | 299 | # --------------------------- | COMMENT |
| MEDIUM | gallery/transforms/plot_rotated_box_transforms.py | 41 | # ------------------------------- | COMMENT |
| MEDIUM | gallery/transforms/plot_rotated_box_transforms.py | 64 | # ------------------------ | COMMENT |
| MEDIUM | gallery/transforms/plot_rotated_box_transforms.py | 97 | # ------------------------------------------- | COMMENT |
| MEDIUM | gallery/transforms/plot_rotated_box_transforms.py | 169 | # -------------------------- | COMMENT |
| MEDIUM | gallery/transforms/plot_tv_tensors.py | 35 | # ------------------- | COMMENT |
| MEDIUM | gallery/transforms/plot_tv_tensors.py | 58 | # ------------------------------ | COMMENT |
| MEDIUM | gallery/transforms/plot_tv_tensors.py | 69 | # ------------------------------ | COMMENT |
| MEDIUM | gallery/transforms/plot_tv_tensors.py | 137 | # ----------------------------------------------- | COMMENT |
| MEDIUM | gallery/transforms/plot_transforms_e2e.py | 43 | # ------------------- | COMMENT |
| MEDIUM | gallery/transforms/plot_transforms_e2e.py | 93 | # ---------- | COMMENT |
| MEDIUM | gallery/transforms/plot_transforms_e2e.py | 142 | # ------------------------------ | COMMENT |
| MEDIUM | gallery/transforms/plot_transforms_e2e.py | 172 | # ------------------- | COMMENT |
| MEDIUM | gallery/transforms/plot_custom_tv_tensors.py | 93 | # ----------------------------------------------------------------------- | COMMENT |
| MEDIUM | gallery/transforms/plot_custom_tv_tensors.py | 125 | # ------------------------------ | COMMENT |
| MEDIUM | torchvision/_autograd_registrations.py | 8 | # ===================================================================== | COMMENT |
| MEDIUM | torchvision/_autograd_registrations.py | 10 | # ===================================================================== | COMMENT |
| MEDIUM | torchvision/_autograd_registrations.py | 218 | # ===================================================================== | COMMENT |
| MEDIUM | torchvision/_autograd_registrations.py | 220 | # ===================================================================== | COMMENT |
| MEDIUM | torchvision/_autograd_registrations.py | 338 | # ===================================================================== | COMMENT |
| MEDIUM | torchvision/_autograd_registrations.py | 340 | # ===================================================================== | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | packaging/cut_release.sh | 1 | #!/usr/bin/env bash | COMMENT |
| LOW | test/smoke_test.py | 41 | # if torch.cuda.is_available(): | COMMENT |
| LOW | test/conftest.py | 21 | config.addinivalue_line("markers", "dont_collect: mark for tests that should not be collected") | COMMENT |
| LOW | test/conftest.py | 81 | COMMENT | |
| LOW | test/test_image.py | 1001 | # type dispatch until we get to the C++ version of decode_image(). We could | COMMENT |
| LOW | test/test_models.py | 841 | # We first try to assert the entire output if possible. This is not | COMMENT |
| LOW | test/test_transforms_v2.py | 7161 | ], | COMMENT |
| LOW | references/depth/stereo/transforms.py | 481 | ) | COMMENT |
| LOW | gallery/others/plot_optical_flow.py | 121 | # If you can, run this example on a GPU, it will be a lot faster. | COMMENT |
| LOW | gallery/others/plot_optical_flow.py | 141 | # vertical displacement of each pixel from the first image to the second image. | COMMENT |
| LOW | gallery/others/plot_optical_flow.py | 181 | COMMENT | |
| LOW | gallery/others/plot_visualization_utils.py | 101 | show(dogs_with_boxes) | COMMENT |
| LOW | gallery/others/plot_visualization_utils.py | 161 | # 1]``. To get boolean masks, we can do the following: | COMMENT |
| LOW | gallery/others/plot_visualization_utils.py | 241 | # Instance segmentation models | COMMENT |
| LOW | gallery/others/plot_visualization_utils.py | 281 | # associated to those keys has ``num_instances`` elements in it. In our case | COMMENT |
| LOW | gallery/others/plot_visualization_utils.py | 341 | COMMENT | |
| LOW | gallery/others/plot_visualization_utils.py | 381 | # As we see the output contains a list of dictionaries. | COMMENT |
| LOW | gallery/others/plot_visualization_utils.py | 421 | # As we see, the keypoints appear as colored circles over the image. | COMMENT |
| LOW | gallery/others/plot_visualization_utils.py | 441 | # | COMMENT |
| LOW | gallery/others/plot_visualization_utils.py | 501 | # So we definitely don't want to display those keypoints and connections, and you don't have to. | COMMENT |
| LOW | gallery/others/plot_visualization_utils.py | 521 | # The :func:`~torchvision.models.detection.keypointrcnn_resnet50_fpn` model, | COMMENT |
| LOW | gallery/others/plot_scripted_tensor_transforms.py | 61 | # <v1_or_v2>` way to use transforms in your code. | COMMENT |
| LOW | gallery/others/plot_repurposing_annotations.py | 41 | COMMENT | |
| LOW | gallery/others/plot_repurposing_annotations.py | 161 | # Converting Segmentation Dataset to Detection Dataset | COMMENT |
| LOW | gallery/transforms/plot_cutmix_mixup.py | 61 | print(f"{images.shape = }, {labels.shape = }") | COMMENT |
| LOW | gallery/transforms/plot_cutmix_mixup.py | 81 | mixup = v2.MixUp(num_classes=NUM_CLASSES) | COMMENT |
| LOW | gallery/transforms/plot_cutmix_mixup.py | 121 | break | COMMENT |
| LOW | gallery/transforms/plot_transforms_getting_started.py | 61 | COMMENT | |
| LOW | gallery/transforms/plot_transforms_getting_started.py | 121 | # answer these in the next sections. | COMMENT |
| LOW | gallery/transforms/plot_transforms_getting_started.py | 141 | img_dp = tv_tensors.Image(torch.randint(0, 256, (3, 256, 256), dtype=torch.uint8)) | COMMENT |
| LOW | gallery/transforms/plot_transforms_getting_started.py | 181 | # %% | COMMENT |
| LOW | gallery/transforms/plot_transforms_getting_started.py | 201 | # :class:`~torchvision.tv_tensors.Image` class at all, and yet our images | COMMENT |
| LOW | gallery/transforms/plot_transforms_getting_started.py | 221 | # | COMMENT |
| LOW | gallery/transforms/plot_transforms_getting_started.py | 241 | # TVTensors, so they don't return TVTensors out of the box. | COMMENT |
| LOW | gallery/transforms/plot_transforms_getting_started.py | 261 | # | COMMENT |
| LOW | gallery/transforms/plot_custom_transforms.py | 21 | COMMENT | |
| LOW | gallery/transforms/plot_custom_transforms.py | 81 | # :ref:`tv_tensor_unwrapping_behaviour` | COMMENT |
| LOW | gallery/transforms/plot_custom_transforms.py | 141 | # ``structured_input``, the input is flattened and then each individual part is | COMMENT |
| LOW | gallery/transforms/plot_custom_transforms.py | 181 | _ = my_random_transform(structured_input) # doesn't transform | COMMENT |
| LOW | gallery/transforms/plot_transforms_illustrations.py | 41 | # | COMMENT |
| LOW | gallery/transforms/plot_transforms_illustrations.py | 61 | # ~~~~~~~~~~ | COMMENT |
| LOW | gallery/transforms/plot_transforms_illustrations.py | 81 | # (see also :func:`~torchvision.transforms.functional.perspective`) | COMMENT |
| LOW | gallery/transforms/plot_transforms_illustrations.py | 101 | # (see also :func:`~torchvision.transforms.functional.affine`) | COMMENT |
| LOW | gallery/transforms/plot_transforms_illustrations.py | 121 | # The :class:`~torchvision.transforms.RandomCrop` transform | COMMENT |
| LOW | gallery/transforms/plot_transforms_illustrations.py | 141 | # ---------------------- | COMMENT |
| LOW | gallery/transforms/plot_transforms_illustrations.py | 161 | # ~~~~~~~~~~~ | COMMENT |
| LOW | gallery/transforms/plot_transforms_illustrations.py | 181 | # The :class:`~torchvision.transforms.RandomInvert` transform | COMMENT |
| LOW | gallery/transforms/plot_transforms_illustrations.py | 201 | # ~~~~~~~~~~~~~~ | COMMENT |
| LOW | gallery/transforms/plot_transforms_illustrations.py | 221 | # RandomAutocontrast | COMMENT |
| LOW | gallery/transforms/plot_transforms_illustrations.py | 241 | # JPEG | COMMENT |
| LOW | gallery/transforms/plot_transforms_illustrations.py | 281 | # ~~~~~~~~~~~~~~~~~~ | COMMENT |
| LOW | gallery/transforms/plot_transforms_illustrations.py | 301 | # The following transforms are randomly-applied given a probability ``p``. That is, given ``p = 0.5``, | COMMENT |
| LOW | gallery/transforms/plot_rotated_box_transforms.py | 81 | resized_imgs = [ | COMMENT |
| LOW | gallery/transforms/plot_rotated_box_transforms.py | 101 | # transformed (cropped) image. In general, this may happen on most of the | COMMENT |
| LOW | gallery/transforms/plot_rotated_box_transforms.py | 161 | print(soft_center_crops_and_boxes) | COMMENT |
| LOW | gallery/transforms/plot_tv_tensors.py | 41 | COMMENT | |
| LOW | gallery/transforms/plot_tv_tensors.py | 61 | # Everything that is supported on a plain :class:`torch.Tensor` like ``.sum()`` or | COMMENT |
| LOW | gallery/transforms/plot_tv_tensors.py | 81 | # Similar to other PyTorch creations ops, the constructor also takes the ``dtype``, ``device``, and ``requires_grad`` | COMMENT |
| LOW | gallery/transforms/plot_tv_tensors.py | 121 | # into a TVTensor. This is useful when you already have an object of the | COMMENT |
| LOW | gallery/transforms/plot_tv_tensors.py | 181 | # Why is this happening? | COMMENT |
| 60 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | setup.py | 407 | CODE | |
| LOW | packaging/wheel/relocate.py | 282 | CODE | |
| LOW | test/conftest.py | 25 | CODE | |
| LOW | test/test_datasets.py | 292 | CODE | |
| LOW | test/test_datasets.py | 1002 | CODE | |
| LOW | test/test_datasets.py | 1763 | CODE | |
| LOW | test/test_datasets.py | 2530 | CODE | |
| LOW | test/test_datasets_download.py | 80 | CODE | |
| LOW | test/test_extended_models.py | 244 | CODE | |
| LOW | test/test_transforms_v2.py | 7195 | CODE | |
| LOW | test/test_transforms_v2.py | 1790 | CODE | |
| LOW | test/test_transforms_v2.py | 4239 | CODE | |
| LOW | test/test_ops.py | 292 | CODE | |
| LOW | test/test_ops.py | 342 | CODE | |
| LOW | test/test_ops.py | 429 | CODE | |
| LOW | test/test_ops.py | 690 | CODE | |
| LOW | test/test_ops.py | 1166 | CODE | |
| LOW | test/common_utils.py | 410 | CODE | |
| LOW | test/common_utils.py | 54 | CODE | |
| LOW | test/datasets_utils.py | 971 | CODE | |
| LOW | test/datasets_utils.py | 483 | CODE | |
| LOW | test/datasets_utils.py | 576 | CODE | |
| LOW | test/datasets_utils.py | 709 | CODE | |
| LOW | references/classification/presets.py | 21 | CODE | |
| LOW | references/depth/stereo/transforms.py | 519 | CODE | |
| LOW | references/depth/stereo/train.py | 36 | CODE | |
| LOW | references/depth/stereo/train.py | 267 | CODE | |
| LOW | references/depth/stereo/cascade_evaluation.py | 109 | CODE | |
| LOW | references/optical_flow/train.py | 13 | CODE | |
| LOW | references/optical_flow/train.py | 133 | CODE | |
| LOW | references/detection/presets.py | 21 | CODE | |
| LOW | gallery/transforms/helpers.py | 9 | CODE | |
| LOW | torchvision/utils.py | 25 | CODE | |
| LOW | torchvision/utils.py | 177 | CODE | |
| LOW | torchvision/utils.py | 285 | CODE | |
| LOW | torchvision/utils.py | 418 | CODE | |
| LOW | torchvision/utils.py | 487 | CODE | |
| LOW | torchvision/utils.py | 722 | CODE | |
| LOW | torchvision/datasets/flickr.py | 40 | CODE | |
| LOW | torchvision/datasets/folder.py | 49 | CODE | |
| LOW | torchvision/datasets/lfw.py | 137 | CODE | |
| LOW | torchvision/datasets/celeba.py | 175 | CODE | |
| LOW | torchvision/datasets/_stereo_matching.py | 579 | CODE | |
| LOW | torchvision/datasets/widerface.py | 113 | CODE | |
| LOW | torchvision/datasets/_optical_flow.py | 349 | CODE | |
| LOW | torchvision/datasets/inaturalist.py | 142 | CODE | |
| LOW | torchvision/datasets/inaturalist.py | 209 | CODE | |
| LOW | torchvision/models/googlenet.py | 32 | CODE | |
| LOW | torchvision/models/mnasnet.py | 112 | CODE | |
| LOW | torchvision/models/vgg.py | 36 | CODE | |
| LOW | torchvision/models/regnet.py | 297 | CODE | |
| LOW | torchvision/models/vision_transformer.py | 789 | CODE | |
| LOW | torchvision/models/vision_transformer.py | 54 | CODE | |
| LOW | torchvision/models/densenet.py | 152 | CODE | |
| LOW | torchvision/models/inception.py | 29 | CODE | |
| LOW | torchvision/models/feature_extraction.py | 369 | CODE | |
| LOW | torchvision/models/efficientnet.py | 366 | CODE | |
| LOW | torchvision/models/efficientnet.py | 234 | CODE | |
| LOW | torchvision/models/resnet.py | 167 | CODE | |
| LOW | torchvision/models/mobilenetv2.py | 68 | CODE | |
| 36 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | test/datasets_utils.py | 881 | Create a video file from random data. Args: root (Union[str, pathlib.Path]): Root directory the video file | STRING |
| HIGH | test/datasets_utils.py | 929 | Create a folder of random videos. Args: root (Union[str, pathlib.Path]): Root directory the video folder wi | STRING |
| HIGH | references/classification/utils.py | 324 | This method can be used to prepare weights files for new models. It receives as input a model architecture and | STRING |
| HIGH | torchvision/utils.py | 728 | Parses a specification of colors for a set of objects. Args: colors: A specification of colors for the | STRING |
| HIGH | torchvision/datasets/places365.py | 13 | `Places365 <http://places2.csail.mit.edu/index.html>`_ classification dataset. Args: root (str or ``pathlib | STRING |
| HIGH | torchvision/datasets/folder.py | 174 | Generates a list of samples of a form (path_to_sample, class). This can be overridden to e.g. read files from a | STRING |
| HIGH | torchvision/datasets/folder.py | 208 | Find the class folders in a dataset structured as follows:: directory/ ├── class_x | STRING |
| HIGH | torchvision/datasets/utils.py | 253 | Detect the archive type and/or compression of a file. Args: file (str): the filename Returns: | STRING |
| HIGH | torchvision/datasets/kinetics.py | 23 | `Generic Kinetics <https://www.deepmind.com/open-source/kinetics>`_ dataset. Kinetics-400/600/700 are action re | STRING |
| HIGH | torchvision/models/feature_extraction.py | 210 | Dev utility to return node names in order of execution. See note on node names under :func:`create_feature_extr | STRING |
| HIGH | torchvision/transforms/functional.py | 217 | Convert a tensor image to the given ``dtype`` and scale the values accordingly This function does not support PIL Im | STRING |
| HIGH | torchvision/ops/deform_conv.py | 24 | Performs Deformable Convolution v2, described in `Deformable ConvNets v2: More Deformable, Better Results < | STRING |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | test/datasets_utils.py | 38 | __all__ = [ | CODE |
| LOW | references/depth/stereo/utils/losses.py | 95 | def set_gamma(self, gamma: float) -> None: | CODE |
| LOW | references/depth/stereo/utils/losses.py | 373 | def set_gamma(self, gamma: float) -> None: | CODE |
| LOW | torchvision/utils.py | 13 | __all__ = [ | CODE |
| LOW | torchvision/datasets/samplers/clip_sampler.py | 102 | def set_epoch(self, epoch: int) -> None: | CODE |
| LOW | torchvision/io/__init__.py | 49 | __all__ = [ | CODE |
| LOW | torchvision/io/video.py | 14 | __all__ = [ | CODE |
| LOW | torchvision/models/shufflenetv2.py | 15 | __all__ = [ | CODE |
| LOW | torchvision/models/googlenet.py | 18 | __all__ = ["GoogLeNet", "GoogLeNetOutputs", "_GoogLeNetOutputs", "GoogLeNet_Weights", "googlenet"] | CODE |
| LOW | torchvision/models/mnasnet.py | 16 | __all__ = [ | CODE |
| LOW | torchvision/models/vgg.py | 14 | __all__ = [ | CODE |
| LOW | torchvision/models/regnet.py | 17 | __all__ = [ | CODE |
| LOW | torchvision/models/vision_transformer.py | 17 | __all__ = [ | CODE |
| LOW | torchvision/models/squeezenet.py | 15 | __all__ = ["SqueezeNet", "SqueezeNet1_0_Weights", "SqueezeNet1_1_Weights", "squeezenet1_0", "squeezenet1_1"] | CODE |
| LOW | torchvision/models/_api.py | 18 | __all__ = ["WeightsEnum", "Weights", "get_model", "get_model_builder", "get_model_weights", "get_weight", "list_models"] | CODE |
| LOW | torchvision/models/densenet.py | 18 | __all__ = [ | CODE |
| LOW | torchvision/models/inception.py | 17 | __all__ = ["Inception3", "InceptionOutputs", "_InceptionOutputs", "Inception_V3_Weights", "inception_v3"] | CODE |
| LOW | torchvision/models/feature_extraction.py | 17 | __all__ = ["create_feature_extractor", "get_graph_node_names"] | CODE |
| LOW | torchvision/models/efficientnet.py | 20 | __all__ = [ | CODE |
| LOW | torchvision/models/resnet.py | 15 | __all__ = [ | CODE |
| LOW | torchvision/models/mobilenetv2.py | 15 | __all__ = ["MobileNetV2", "MobileNet_V2_Weights", "mobilenet_v2"] | CODE |
| LOW | torchvision/models/mobilenetv3.py | 16 | __all__ = [ | CODE |
| LOW | torchvision/models/swin_transformer.py | 18 | __all__ = [ | CODE |
| LOW | torchvision/models/alexnet.py | 14 | __all__ = ["AlexNet", "AlexNet_Weights", "alexnet"] | CODE |
| LOW | torchvision/models/maxvit.py | 19 | __all__ = [ | CODE |
| LOW | torchvision/models/convnext.py | 18 | __all__ = [ | CODE |
| LOW | torchvision/models/video/s3d.py | 15 | __all__ = [ | CODE |
| LOW | torchvision/models/video/resnet.py | 15 | __all__ = [ | CODE |
| LOW | torchvision/models/video/mvit.py | 19 | __all__ = [ | CODE |
| LOW | torchvision/models/video/swin_transformer.py | 21 | __all__ = [ | CODE |
| LOW | torchvision/models/segmentation/fcn.py | 14 | __all__ = ["FCN", "FCN_ResNet50_Weights", "FCN_ResNet101_Weights", "fcn_resnet50", "fcn_resnet101"] | CODE |
| LOW | torchvision/models/segmentation/lraspp.py | 16 | __all__ = ["LRASPP", "LRASPP_MobileNet_V3_Large_Weights", "lraspp_mobilenet_v3_large"] | CODE |
| LOW | torchvision/models/segmentation/deeplabv3.py | 19 | __all__ = [ | CODE |
| LOW | torchvision/models/quantization/shufflenetv2.py | 22 | __all__ = [ | CODE |
| LOW | torchvision/models/quantization/googlenet.py | 18 | __all__ = [ | CODE |
| LOW | torchvision/models/quantization/inception.py | 19 | __all__ = [ | CODE |
| LOW | torchvision/models/quantization/resnet.py | 24 | __all__ = [ | CODE |
| LOW | torchvision/models/quantization/mobilenetv2.py | 16 | __all__ = [ | CODE |
| LOW | torchvision/models/quantization/mobilenetv3.py | 23 | __all__ = [ | CODE |
| LOW | torchvision/models/detection/ssdlite.py | 23 | __all__ = [ | CODE |
| LOW | torchvision/models/detection/ssd.py | 22 | __all__ = [ | CODE |
| LOW | torchvision/models/detection/faster_rcnn.py | 24 | __all__ = [ | CODE |
| LOW | torchvision/models/detection/fcos.py | 24 | __all__ = [ | CODE |
| LOW | torchvision/models/detection/mask_rcnn.py | 18 | __all__ = [ | CODE |
| LOW | torchvision/models/detection/retinanet.py | 25 | __all__ = [ | CODE |
| LOW | torchvision/models/detection/keypoint_rcnn.py | 18 | __all__ = [ | CODE |
| LOW | torchvision/models/detection/_utils.py | 397 | def set_low_quality_matches_(self, matches: Tensor, all_matches: Tensor, match_quality_matrix: Tensor) -> None: | CODE |
| LOW | torchvision/transforms/transforms.py | 20 | __all__ = [ | CODE |
| LOW | torchvision/transforms/_presets.py | 14 | __all__ = [ | CODE |
| LOW | torchvision/transforms/autoaugment.py | 10 | __all__ = ["AutoAugmentPolicy", "AutoAugment", "RandAugment", "TrivialAugmentWide", "AugMix"] | CODE |
| LOW | torchvision/transforms/_transforms_video.py | 12 | __all__ = [ | CODE |
| LOW | torchvision/tv_tensors/_dataset_wrapper.py | 16 | __all__ = ["wrap_dataset_for_transforms_v2"] | CODE |
| LOW | torchvision/ops/__init__.py | 33 | __all__ = [ | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | test/common_extended_utils.py | 186 | CODE | |
| LOW | test/common_utils.py | 313 | CODE | |
| LOW | references/classification/presets.py | 21 | CODE | |
| LOW | references/depth/stereo/presets.py | 45 | CODE | |
| LOW | references/depth/stereo/cascade_evaluation.py | 109 | CODE | |
| LOW | references/optical_flow/presets.py | 23 | CODE | |
| LOW | torchvision/utils.py | 285 | CODE | |
| LOW | torchvision/datasets/video_utils.py | 102 | CODE | |
| LOW | torchvision/datasets/ucf101.py | 54 | CODE | |
| LOW | torchvision/datasets/hmdb51.py | 61 | CODE | |
| LOW | torchvision/datasets/kinetics.py | 91 | CODE | |
| LOW | torchvision/io/image.py | 111 | CODE | |
| LOW | torchvision/io/image.py | 187 | CODE | |
| LOW | torchvision/io/image.py | 220 | CODE | |
| LOW | torchvision/io/image.py | 473 | CODE | |
| LOW | torchvision/models/shufflenetv2.py | 101 | CODE | |
| LOW | torchvision/models/densenet.py | 218 | CODE | |
| LOW | torchvision/models/resnet.py | 105 | CODE | |
| LOW | torchvision/models/resnet.py | 163 | CODE | |
| LOW | torchvision/models/swin_transformer.py | 528 | CODE | |
| LOW | torchvision/models/maxvit.py | 211 | CODE | |
| LOW | torchvision/models/maxvit.py | 224 | CODE | |
| LOW | torchvision/models/maxvit.py | 590 | CODE | |
| LOW | torchvision/models/video/s3d.py | 89 | CODE | |
| LOW | torchvision/models/video/resnet.py | 121 | CODE | |
| LOW | torchvision/models/video/resnet.py | 170 | CODE | |
| LOW | torchvision/models/video/mvit.py | 426 | CODE | |
| LOW | torchvision/models/video/swin_transformer.py | 386 | CODE | |
| LOW | torchvision/models/quantization/shufflenetv2.py | 49 | CODE | |
| LOW | torchvision/models/quantization/resnet.py | 57 | CODE | |
| LOW | torchvision/models/quantization/resnet.py | 88 | CODE | |
| LOW | torchvision/models/detection/ssd.py | 186 | CODE | |
| LOW | torchvision/models/detection/faster_rcnn.py | 167 | CODE | |
| LOW | torchvision/models/detection/fcos.py | 365 | CODE | |
| LOW | torchvision/models/detection/mask_rcnn.py | 165 | CODE | |
| LOW | torchvision/models/detection/retinanet.py | 417 | CODE | |
| LOW | torchvision/models/detection/keypoint_rcnn.py | 164 | CODE | |
| LOW | torchvision/transforms/_functional_tensor.py | 255 | CODE | |
| LOW | torchvision/ops/misc.py | 70 | CODE | |
| LOW | torchvision/ops/misc.py | 145 | CODE | |
| LOW | torchvision/ops/misc.py | 194 | CODE | |
| LOW | torchvision/ops/roi_align.py | 200 | CODE | |
| LOW | torchvision/ops/feature_pyramid_network.py | 204 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | setup.py | 63 | except Exception: | CODE |
| HIGH | test/test_datasets.py | 1012 | except FileNotFoundError: | CODE |
| HIGH | torchvision/__init__.py | 21 | except ImportError: | CODE |
| HIGH | torchvision/datasets/sbu.py | 111 | except OSError: | CODE |
| HIGH | torchvision/io/__init__.py | 18 | except ImportError: | CODE |
| HIGH | torchvision/io/__init__.py | 27 | except ImportError: | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | test/conftest.py | 63 | # TODO: something more robust would be to do that only in a sandcastle instance, | COMMENT |
| MEDIUM | test/test_models.py | 253 | # This may be caused by the harness environment (e.g. num classes, input initialization | COMMENT |
| LOW | test/test_transforms_v2.py | 156 | # Most kernels just return a tensor, but some also return some additional metadata | COMMENT |
| LOW | test/test_transforms_v2.py | 175 | # Most kernels just return a tensor, but some also return some additional metadata | COMMENT |
| LOW | references/detection/transforms.py | 464 | # Let's just return (image, target) | COMMENT |
| MEDIUM | gallery/transforms/plot_transforms_e2e.py | 99 | # dataset so that they can leverage multi-processing from the | COMMENT |
| MEDIUM | torchvision/datasets/caltech.py | 126 | # can be more robust and check hash of files | COMMENT |
| MEDIUM | torchvision/datasets/caltech.py | 226 | # can be more robust and check hash of files | COMMENT |
| LOW | torchvision/transforms/v2/_transform.py | 155 | # are JIT scriptable, and we made sure that for single image inputs v1 and v2 are equivalent, we just return the | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | gallery/transforms/plot_rotated_box_transforms.py | 40 | # Creating a Rotated Bounding Box | COMMENT |
| MEDIUM | torchvision/transforms/v2/_transform.py | 129 | # This method is called after subclassing has happened, i.e. `cls` is the subclass, e.g. `Resize`. | COMMENT |
| MEDIUM | torchvision/transforms/v2/_transform.py | 134 | # This method is called by `__prepare_scriptable__` to instantiate the equivalent v1 transform from the current | COMMENT |
| MEDIUM | torchvision/transforms/v2/_transform.py | 153 | # This method is called early on when `torch.jit.script`'ing an `nn.Module` instance. If it succeeds, the return | COMMENT |
| MEDIUM | torchvision/transforms/v2/functional/_color.py | 263 | # Create a view on the underlying output while pointing at the same data. We do this to avoid indexing twice. | COMMENT |
| MEDIUM | docs/source/conf.py | 6 | # This file is execfile()d with the current directory set to its | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | setup.py | 63 | except Exception: | CODE |
| LOW | test/test_extended_models.py | 398 | except Exception: | CODE |
| LOW | test/test_models.py | 992 | except Exception as e: | CODE |
| MEDIUM | test/test_transforms_v2.py | 106 | def _script(obj): | CODE |
| LOW | test/test_transforms_v2.py | 109 | except Exception as error: | CODE |
| LOW | test/common_utils.py | 249 | except Exception as exc: | CODE |
| LOW | torchvision/utils.py | 192 | except Exception: | CODE |
| LOW | torchvision/datasets/video_utils.py | 327 | except Exception: | CODE |
| LOW⚡ | release/apply-release-changes.py | 46 | except Exception as e: | CODE |
| MEDIUM⚡ | release/apply-release-changes.py | 47 | print(f"Error processing {file_path}: {e}") | CODE |
| MEDIUM | release/apply-release-changes.py | 71 | print("Error: Exactly one version parameter is required") | CODE |
| MEDIUM | release/apply-release-changes.py | 83 | print("Error: Not inside a git repository. Please run from within a git repository.") | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW⚡ | test/smoke_test.py | 93 | # Step 1: Initialize model with the best available weights | COMMENT |
| LOW⚡ | test/smoke_test.py | 98 | # Step 2: Initialize the inference transforms | COMMENT |
| LOW⚡ | test/smoke_test.py | 101 | # Step 3: Apply inference preprocessing transforms | COMMENT |
| LOW⚡ | test/smoke_test.py | 104 | # Step 4: Use the model and print the predicted category | COMMENT |
| LOW | torchvision/csrc/ops/box_iou_rotated_utils.h | 182 | // Step 1: | COMMENT |
| LOW | torchvision/csrc/ops/box_iou_rotated_utils.h | 194 | // Step 2: | COMMENT |
| LOW | torchvision/csrc/ops/box_iou_rotated_utils.h | 205 | // Step 3: | COMMENT |
| LOW | torchvision/csrc/ops/box_iou_rotated_utils.h | 262 | // Step 4: | COMMENT |
| LOW | torchvision/csrc/ops/box_iou_rotated_utils.h | 279 | // Step 5: | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | packaging/pre_build_script_arm64.sh | 25 | # Set vcpkg to only build release packages | COMMENT |
| LOW | test/test_utils.py | 132 | # Check if modification is not in place | COMMENT |
| LOW | test/test_utils.py | 257 | # Check if modification is not in place | COMMENT |
| LOW | test/test_transforms.py | 1743 | # Check if content in center of both image and cropped output is same. | COMMENT |
| LOW⚡ | references/similarity/loss.py | 102 | # Check if labels[i] == labels[j] | COMMENT |
| LOW | torchvision/models/detection/roi_heads.py | 423 | # Set shape to [batchxCxHxW] | COMMENT |
| LOW | torchvision/models/detection/roi_heads.py | 449 | # Set shape to [batchxCxHxW] | COMMENT |
| LOW⚡ | release/apply-release-changes.py | 56 | # Check if .git directory exists | COMMENT |
| LOW | release/apply-release-changes.py | 69 | # Check if version is provided as command line argument | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW⚡ | test/smoke_test.py | 93 | # Step 1: Initialize model with the best available weights | COMMENT |
| LOW⚡ | test/smoke_test.py | 98 | # Step 2: Initialize the inference transforms | COMMENT |
| LOW⚡ | test/smoke_test.py | 101 | # Step 3: Apply inference preprocessing transforms | COMMENT |
| LOW⚡ | test/smoke_test.py | 104 | # Step 4: Use the model and print the predicted category | COMMENT |
| LOW | torchvision/transforms/v2/functional/_meta.py | 276 | # NOTE: This function cannot modify the input tensor inplace as it requires a dimension change. | COMMENT |
| LOW | torchvision/transforms/v2/functional/_meta.py | 301 | # NOTE: This function cannot modify the input tensor inplace as it requires a dimension change. | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | references/depth/stereo/train.py | 527 | # make sure to disable shuffling since the dataset is already shuffled | COMMENT |
| LOW | gallery/transforms/plot_custom_transforms.py | 79 | # While working with TVTensor classes in your code, make sure to | COMMENT |
| MEDIUM | gallery/transforms/plot_tv_tensors.py | 172 | # Alternatively, you can use the :func:`~torchvision.tv_tensors.set_return_type` | COMMENT |
| LOW | torchvision/transforms/v2/_augment.py | 191 | # after an image or video. However, we need to handle them in _transform, so we make sure to set them to True | COMMENT |
| MEDIUM | scripts/release_notes/retrieve_prs_data.py | 207 | # Then you can use classify_prs.py (as a notebook) | STRING |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | references/depth/stereo/utils/losses.py | 305 | # which should be consistent with the previous step. In this implementation, we simplify the overall loss | COMMENT |