============================= test session starts ==============================
platform linux -- Python 3.6.10, pytest-5.4.3, py-1.9.0, pluggy-0.13.1
rootdir: /home/aryaman4/vision
collected 322 items

test/test_backbone_utils.py ..                                           [  0%]
test/test_cpp_models.py sssssssssssssssssssssssssssssss                  [ 10%]
test/test_datasets.py .....Fs..s.                                        [ 13%]
test/test_datasets_samplers.py sssss                                     [ 15%]
test/test_datasets_transforms.py ..                                      [ 15%]
test/test_datasets_utils.py ..........                                   [ 18%]
test/test_datasets_video_utils.py ..ss                                   [ 20%]
test/test_hub.py sss                                                     [ 21%]
test/test_io.py ssssssssssssss                                           [ 25%]
test/test_models.py .........Fs...F.F.F.F.F.....F....................... [ 41%]
....                                                                     [ 42%]
test/test_models_detection_negative_samples.py .....                     [ 44%]
test/test_models_detection_utils.py .FFFF                                [ 45%]
test/test_onnx.py sssssssssssssss                                        [ 50%]
test/test_ops.py ..ss...ss..ss...ss..ss...ss..ss...ssFs...ss..ssFFFF.    [ 66%]
test/test_quantized_models.py F........                                  [ 69%]
test/test_transforms.py ..........ssss....s...FFFFF.....s..F...F.ss.Fsss [ 84%]
.s..........                                                             [ 88%]
test/test_transforms_tensor.py FFFFFFFF                                  [ 90%]
test/test_transforms_video.py .s.s..                                     [ 92%]
test/test_utils.py ......                                                [ 94%]
test/test_video_reader.py ssssssssssssssssss                             [100%]

=================================== FAILURES ===================================
________________________ Tester.test_imagefolder_empty _________________________

self = <test_datasets.Tester testMethod=test_imagefolder_empty>

    def test_imagefolder_empty(self):
        with get_tmp_dir() as root:
            with self.assertRaises(RuntimeError):
                torchvision.datasets.ImageFolder(root, loader=lambda x: x)
    
            with self.assertRaises(RuntimeError):
                torchvision.datasets.ImageFolder(
>                   root, loader=lambda x: x, is_valid_file=lambda x: False
                )

test/test_datasets.py:94: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/datasets/folder.py:206: in __init__
    is_valid_file=is_valid_file)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

    def __init__(self, root, loader, extensions=None, transform=None,
                 target_transform=None, is_valid_file=None):
        super(DatasetFolder, self).__init__(root, transform=transform,
                                            target_transform=target_transform)
        classes, class_to_idx = self._find_classes(self.root)
        samples = make_dataset(self.root, class_to_idx, extensions, is_valid_file)
        if len(samples) == 0:
            raise (RuntimeError("Found 0 files in subfolders of: " + self.root + "\n"
>                               "Supported extensions are: " + ",".join(extensions)))
E           TypeError: can only join an iterable

../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/datasets/folder.py:98: TypeError
_____________ ModelTester.test_fasterrcnn_resnet50_fpn_validation ______________

self = <test_models.ModelTester testMethod=test_fasterrcnn_resnet50_fpn_validation>
model_name = 'fasterrcnn_resnet50_fpn'

    def do_validation_test(self, model_name=model_name):
>       self._test_detection_model_validation(model_name)

test/test_models.py:345: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
test/test_models.py:170: in _test_detection_model_validation
    self.assertRaises(ValueError, model, x, targets=targets)
../anaconda3/envs/vision/lib/python3.6/site-packages/torch/nn/modules/module.py:550: in __call__
    result = self.forward(*input, **kwargs)
../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/detection/generalized_rcnn.py:66: in forward
    images, targets = self.transform(images, targets)
../anaconda3/envs/vision/lib/python3.6/site-packages/torch/nn/modules/module.py:550: in __call__
    result = self.forward(*input, **kwargs)
../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/detection/transform.py:45: in forward
    image, target_index = self.resize(image, target_index)
../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/detection/transform.py:98: in resize
    bbox = resize_boxes(bbox, (h, w), image.shape[-2:])
../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/detection/transform.py:217: in resize_boxes
    for s, s_orig in zip(new_size, original_size)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

        torch.tensor(s, dtype=torch.float32, device=boxes.device) /
        torch.tensor(s_orig, dtype=torch.float32, device=boxes.device)
>       for s, s_orig in zip(new_size, original_size)
    ]
E   AttributeError: 'float' object has no attribute 'device'

../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/detection/transform.py:217: AttributeError
__________________________ ModelTester.test_googlenet __________________________

self = <test_models.ModelTester testMethod=test_googlenet>
model_name = 'googlenet'

    def do_test(self, model_name=model_name):
        input_shape = (1, 3, 224, 224)
        if model_name in ['inception_v3']:
            input_shape = (1, 3, 299, 299)
>       self._test_classification_model(model_name, input_shape)

test/test_models.py:322: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
test/test_models.py:88: in _test_classification_model
    model = models.__dict__[name](num_classes=50)
../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/googlenet.py:59: in googlenet
    return GoogLeNet(**kwargs)
../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/googlenet.py:110: in __init__
    self._initialize_weights()
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = GoogLeNet(
  (conv1): BasicConv2d(
    (conv): Conv2d(3, 64, kernel_size=(7, 7), stride=(2, 2), padding=(3, 3), bias=F..._size=(1, 1))
  (dropout): Dropout(p=0.2, inplace=False)
  (fc): Linear(in_features=1024, out_features=50, bias=True)
)

    def _initialize_weights(self):
        for m in self.modules():
            if isinstance(m, nn.Conv2d) or isinstance(m, nn.Linear):
>               import scipy.stats as stats
E               ModuleNotFoundError: No module named 'scipy'

../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/googlenet.py:115: ModuleNotFoundError
________________________ ModelTester.test_inception_v3 _________________________

self = <test_models.ModelTester testMethod=test_inception_v3>
model_name = 'inception_v3'

    def do_test(self, model_name=model_name):
        input_shape = (1, 3, 224, 224)
        if model_name in ['inception_v3']:
            input_shape = (1, 3, 299, 299)
>       self._test_classification_model(model_name, input_shape)

test/test_models.py:322: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
test/test_models.py:88: in _test_classification_model
    model = models.__dict__[name](num_classes=50)
../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/inception.py:60: in inception_v3
    return Inception3(**kwargs)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = Inception3(
  (Conv2d_1a_3x3): BasicConv2d(
    (conv): Conv2d(3, 32, kernel_size=(3, 3), stride=(2, 2), bias=False)
 ...um=0.1, affine=True, track_running_stats=True)
    )
  )
  (fc): Linear(in_features=2048, out_features=50, bias=True)
)
num_classes = 50, aux_logits = True, transform_input = False
inception_blocks = [<class 'torchvision.models.inception.BasicConv2d'>, <class 'torchvision.models.inception.InceptionA'>, <class 'torchv...nceptionC'>, <class 'torchvision.models.inception.InceptionD'>, <class 'torchvision.models.inception.InceptionE'>, ...]
init_weights = True

    def __init__(self, num_classes=1000, aux_logits=True, transform_input=False,
                 inception_blocks=None, init_weights=True):
        super(Inception3, self).__init__()
        if inception_blocks is None:
            inception_blocks = [
                BasicConv2d, InceptionA, InceptionB, InceptionC,
                InceptionD, InceptionE, InceptionAux
            ]
        assert len(inception_blocks) == 7
        conv_block = inception_blocks[0]
        inception_a = inception_blocks[1]
        inception_b = inception_blocks[2]
        inception_c = inception_blocks[3]
        inception_d = inception_blocks[4]
        inception_e = inception_blocks[5]
        inception_aux = inception_blocks[6]
    
        self.aux_logits = aux_logits
        self.transform_input = transform_input
        self.Conv2d_1a_3x3 = conv_block(3, 32, kernel_size=3, stride=2)
        self.Conv2d_2a_3x3 = conv_block(32, 32, kernel_size=3)
        self.Conv2d_2b_3x3 = conv_block(32, 64, kernel_size=3, padding=1)
        self.Conv2d_3b_1x1 = conv_block(64, 80, kernel_size=1)
        self.Conv2d_4a_3x3 = conv_block(80, 192, kernel_size=3)
        self.Mixed_5b = inception_a(192, pool_features=32)
        self.Mixed_5c = inception_a(256, pool_features=64)
        self.Mixed_5d = inception_a(288, pool_features=64)
        self.Mixed_6a = inception_b(288)
        self.Mixed_6b = inception_c(768, channels_7x7=128)
        self.Mixed_6c = inception_c(768, channels_7x7=160)
        self.Mixed_6d = inception_c(768, channels_7x7=160)
        self.Mixed_6e = inception_c(768, channels_7x7=192)
        if aux_logits:
            self.AuxLogits = inception_aux(768, num_classes)
        self.Mixed_7a = inception_d(768)
        self.Mixed_7b = inception_e(1280)
        self.Mixed_7c = inception_e(2048)
        self.fc = nn.Linear(2048, num_classes)
        if init_weights:
            for m in self.modules():
                if isinstance(m, nn.Conv2d) or isinstance(m, nn.Linear):
>                   import scipy.stats as stats
E                   ModuleNotFoundError: No module named 'scipy'

../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/inception.py:106: ModuleNotFoundError
____________ ModelTester.test_keypointrcnn_resnet50_fpn_validation _____________

self = <test_models.ModelTester testMethod=test_keypointrcnn_resnet50_fpn_validation>
model_name = 'keypointrcnn_resnet50_fpn'

    def do_validation_test(self, model_name=model_name):
>       self._test_detection_model_validation(model_name)

test/test_models.py:345: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
test/test_models.py:170: in _test_detection_model_validation
    self.assertRaises(ValueError, model, x, targets=targets)
../anaconda3/envs/vision/lib/python3.6/site-packages/torch/nn/modules/module.py:550: in __call__
    result = self.forward(*input, **kwargs)
../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/detection/generalized_rcnn.py:66: in forward
    images, targets = self.transform(images, targets)
../anaconda3/envs/vision/lib/python3.6/site-packages/torch/nn/modules/module.py:550: in __call__
    result = self.forward(*input, **kwargs)
../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/detection/transform.py:45: in forward
    image, target_index = self.resize(image, target_index)
../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/detection/transform.py:98: in resize
    bbox = resize_boxes(bbox, (h, w), image.shape[-2:])
../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/detection/transform.py:217: in resize_boxes
    for s, s_orig in zip(new_size, original_size)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

        torch.tensor(s, dtype=torch.float32, device=boxes.device) /
        torch.tensor(s_orig, dtype=torch.float32, device=boxes.device)
>       for s, s_orig in zip(new_size, original_size)
    ]
E   AttributeError: 'float' object has no attribute 'device'

../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/detection/transform.py:217: AttributeError
______________ ModelTester.test_maskrcnn_resnet50_fpn_validation _______________

self = <test_models.ModelTester testMethod=test_maskrcnn_resnet50_fpn_validation>
model_name = 'maskrcnn_resnet50_fpn'

    def do_validation_test(self, model_name=model_name):
>       self._test_detection_model_validation(model_name)

test/test_models.py:345: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
test/test_models.py:170: in _test_detection_model_validation
    self.assertRaises(ValueError, model, x, targets=targets)
../anaconda3/envs/vision/lib/python3.6/site-packages/torch/nn/modules/module.py:550: in __call__
    result = self.forward(*input, **kwargs)
../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/detection/generalized_rcnn.py:66: in forward
    images, targets = self.transform(images, targets)
../anaconda3/envs/vision/lib/python3.6/site-packages/torch/nn/modules/module.py:550: in __call__
    result = self.forward(*input, **kwargs)
../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/detection/transform.py:45: in forward
    image, target_index = self.resize(image, target_index)
../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/detection/transform.py:98: in resize
    bbox = resize_boxes(bbox, (h, w), image.shape[-2:])
../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/detection/transform.py:217: in resize_boxes
    for s, s_orig in zip(new_size, original_size)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

        torch.tensor(s, dtype=torch.float32, device=boxes.device) /
        torch.tensor(s_orig, dtype=torch.float32, device=boxes.device)
>       for s, s_orig in zip(new_size, original_size)
    ]
E   AttributeError: 'float' object has no attribute 'device'

../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/detection/transform.py:217: AttributeError
__________________ ModelTester.test_memory_efficient_densenet __________________

self = <test_models.ModelTester testMethod=test_memory_efficient_densenet>

    def test_memory_efficient_densenet(self):
        input_shape = (1, 3, 300, 300)
        x = torch.rand(input_shape)
    
        for name in ['densenet121', 'densenet169', 'densenet201', 'densenet161']:
            model1 = models.__dict__[name](num_classes=50, memory_efficient=True)
            params = model1.state_dict()
            num_params = sum([x.numel() for x in model1.parameters()])
            model1.eval()
            out1 = model1(x)
            out1.sum().backward()
            num_grad = sum([x.grad.numel() for x in model1.parameters() if x.grad is not None])
    
            model2 = models.__dict__[name](num_classes=50, memory_efficient=False)
            model2.load_state_dict(params)
            model2.eval()
            out2 = model2(x)
    
            max_diff = (out1 - out2).abs().max()
    
>           self.assertTrue(num_params == num_grad)
E           AssertionError: False is not true

test/test_models.py:223: AssertionError
___________________ ModelTester.test_mobilenetv2_norm_layer ____________________

self = <test_models.ModelTester testMethod=test_mobilenetv2_norm_layer>

    def test_mobilenetv2_norm_layer(self):
        model = models.__dict__["mobilenet_v2"]()
        self.assertTrue(any(isinstance(x, nn.BatchNorm2d) for x in model.modules()))
    
        def get_gn(num_channels):
            return nn.GroupNorm(32, num_channels)
    
>       model = models.__dict__["mobilenet_v2"](norm_layer=get_gn)

test/test_models.py:251: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

pretrained = False, progress = True
kwargs = {'norm_layer': <function ModelTester.test_mobilenetv2_norm_layer.<locals>.get_gn at 0x7fd97e3fac80>}

    def mobilenet_v2(pretrained=False, progress=True, **kwargs):
        """
        Constructs a MobileNetV2 architecture from
        `"MobileNetV2: Inverted Residuals and Linear Bottlenecks" <https://arxiv.org/abs/1801.04381>`_.
    
        Args:
            pretrained (bool): If True, returns a model pre-trained on ImageNet
            progress (bool): If True, displays a progress bar of the download to stderr
        """
>       model = MobileNetV2(**kwargs)
E       TypeError: __init__() got an unexpected keyword argument 'norm_layer'

../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/mobilenet.py:172: TypeError
______________ Tester.test_fasterrcnn_resnet50_fpn_frozen_layers _______________

self = <test_models_detection_utils.Tester testMethod=test_fasterrcnn_resnet50_fpn_frozen_layers>

    def test_fasterrcnn_resnet50_fpn_frozen_layers(self):
        # we know how many initial layers and parameters of the network should
        # be frozen for each trainable_backbone_layers paramter value
        # i.e all 53 params are frozen if trainable_backbone_layers=0
        # ad first 24 params are frozen if trainable_backbone_layers=2
        expected_frozen_params = {0: 53, 1: 43, 2: 24, 3: 11, 4: 1, 5: 0}
        for train_layers, exp_froz_params in expected_frozen_params.items():
            model = fasterrcnn_resnet50_fpn(pretrained=True, progress=False,
                                            num_classes=91, pretrained_backbone=False,
>                                           trainable_backbone_layers=train_layers)

test/test_models_detection_utils.py:32: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

pretrained = True, progress = False, num_classes = 91
pretrained_backbone = False, kwargs = {'trainable_backbone_layers': 0}
backbone = BackboneWithFPN(
  (body): IntermediateLayerGetter(
    (conv1): Conv2d(3, 64, kernel_size=(7, 7), stride=(2, 2), padd... Conv2d(256, 256, kernel_size=(3, 3), stride=(1, 1), padding=(1, 1))
    )
    (extra_blocks): LastLevelMaxPool()
  )
)

    def fasterrcnn_resnet50_fpn(pretrained=False, progress=True,
                                num_classes=91, pretrained_backbone=True, **kwargs):
        """
        Constructs a Faster R-CNN model with a ResNet-50-FPN backbone.
    
        The input to the model is expected to be a list of tensors, each of shape ``[C, H, W]``, one for each
        image, and should be in ``0-1`` range. Different images can have different sizes.
    
        The behavior of the model changes depending if it is in training or evaluation mode.
    
        During training, the model expects both the input tensors, as well as a targets (list of dictionary),
        containing:
            - boxes (``FloatTensor[N, 4]``): the ground-truth boxes in ``[x1, y1, x2, y2]`` format, with values of ``x``
              between ``0`` and ``W`` and values of ``y`` between ``0`` and ``H``
            - labels (``Int64Tensor[N]``): the class label for each ground-truth box
    
        The model returns a ``Dict[Tensor]`` during training, containing the classification and regression
        losses for both the RPN and the R-CNN.
    
        During inference, the model requires only the input tensors, and returns the post-processed
        predictions as a ``List[Dict[Tensor]]``, one for each input image. The fields of the ``Dict`` are as
        follows:
            - boxes (``FloatTensor[N, 4]``): the predicted boxes in ``[x1, y1, x2, y2]`` format, with values of ``x``
              between ``0`` and ``W`` and values of ``y`` between ``0`` and ``H``
            - labels (``Int64Tensor[N]``): the predicted labels for each image
            - scores (``Tensor[N]``): the scores or each prediction
    
        Faster R-CNN is exportable to ONNX for a fixed batch size with inputs images of fixed size.
    
        Example::
    
            >>> model = torchvision.models.detection.fasterrcnn_resnet50_fpn(pretrained=True)
            >>> # For training
            >>> images, boxes = torch.rand(4, 3, 600, 1200), torch.rand(4, 11, 4)
            >>> labels = torch.randint(1, 91, (4, 11))
            >>> images = list(image for image in images)
            >>> targets = []
            >>> for i in range(len(images)):
            >>>     d = {}
            >>>     d['boxes'] = boxes[i]
            >>>     d['labels'] = labels[i]
            >>>     targets.append(d)
            >>> output = model(images, targets)
            >>> # For inference
            >>> model.eval()
            >>> x = [torch.rand(3, 300, 400), torch.rand(3, 500, 400)]
            >>> predictions = model(x)
            >>>
            >>> # optionally, if you want to export the model to ONNX:
            >>> torch.onnx.export(model, x, "faster_rcnn.onnx", opset_version = 11)
    
        Arguments:
            pretrained (bool): If True, returns a model pre-trained on COCO train2017
            progress (bool): If True, displays a progress bar of the download to stderr
        """
        if pretrained:
            # no need to download the backbone if pretrained is set
            pretrained_backbone = False
        backbone = resnet_fpn_backbone('resnet50', pretrained_backbone)
>       model = FasterRCNN(backbone, num_classes, **kwargs)
E       TypeError: __init__() got an unexpected keyword argument 'trainable_backbone_layers'

../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/detection/faster_rcnn.py:350: TypeError
_____________ Tester.test_keypointrcnn_resnet50_fpn_frozen_layers ______________

self = <test_models_detection_utils.Tester testMethod=test_keypointrcnn_resnet50_fpn_frozen_layers>

    def test_keypointrcnn_resnet50_fpn_frozen_layers(self):
        # we know how many initial layers and parameters of the keypointrcnn should
        # be frozen for each trainable_backbone_layers paramter value
        # i.e all 53 params are frozen if trainable_backbone_layers=0
        # ad first 24 params are frozen if trainable_backbone_layers=2
        expected_frozen_params = {0: 53, 1: 43, 2: 24, 3: 11, 4: 1, 5: 0}
        for train_layers, exp_froz_params in expected_frozen_params.items():
            model = keypointrcnn_resnet50_fpn(pretrained=True, progress=False,
                                              num_classes=2, pretrained_backbone=False,
>                                             trainable_backbone_layers=train_layers)

test/test_models_detection_utils.py:62: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

pretrained = True, progress = False, num_classes = 2, num_keypoints = 17
pretrained_backbone = False, kwargs = {'trainable_backbone_layers': 0}
backbone = BackboneWithFPN(
  (body): IntermediateLayerGetter(
    (conv1): Conv2d(3, 64, kernel_size=(7, 7), stride=(2, 2), padd... Conv2d(256, 256, kernel_size=(3, 3), stride=(1, 1), padding=(1, 1))
    )
    (extra_blocks): LastLevelMaxPool()
  )
)

    def keypointrcnn_resnet50_fpn(pretrained=False, progress=True,
                                  num_classes=2, num_keypoints=17,
                                  pretrained_backbone=True, **kwargs):
        """
        Constructs a Keypoint R-CNN model with a ResNet-50-FPN backbone.
    
        The input to the model is expected to be a list of tensors, each of shape ``[C, H, W]``, one for each
        image, and should be in ``0-1`` range. Different images can have different sizes.
    
        The behavior of the model changes depending if it is in training or evaluation mode.
    
        During training, the model expects both the input tensors, as well as a targets (list of dictionary),
        containing:
            - boxes (``FloatTensor[N, 4]``): the ground-truth boxes in ``[x1, y1, x2, y2]`` format, with values of ``x``
              between ``0`` and ``W`` and values of ``y`` between ``0`` and ``H``
            - labels (``Int64Tensor[N]``): the class label for each ground-truth box
            - keypoints (``FloatTensor[N, K, 3]``): the ``K`` keypoints location for each of the ``N`` instances, in the
              format ``[x, y, visibility]``, where ``visibility=0`` means that the keypoint is not visible.
    
        The model returns a ``Dict[Tensor]`` during training, containing the classification and regression
        losses for both the RPN and the R-CNN, and the keypoint loss.
    
        During inference, the model requires only the input tensors, and returns the post-processed
        predictions as a ``List[Dict[Tensor]]``, one for each input image. The fields of the ``Dict`` are as
        follows:
            - boxes (``FloatTensor[N, 4]``): the predicted boxes in ``[x1, y1, x2, y2]`` format,  with values of ``x``
              between ``0`` and ``W`` and values of ``y`` between ``0`` and ``H``
            - labels (``Int64Tensor[N]``): the predicted labels for each image
            - scores (``Tensor[N]``): the scores or each prediction
            - keypoints (``FloatTensor[N, K, 3]``): the locations of the predicted keypoints, in ``[x, y, v]`` format.
    
        Keypoint R-CNN is exportable to ONNX for a fixed batch size with inputs images of fixed size.
    
        Example::
    
            >>> model = torchvision.models.detection.keypointrcnn_resnet50_fpn(pretrained=True)
            >>> model.eval()
            >>> x = [torch.rand(3, 300, 400), torch.rand(3, 500, 400)]
            >>> predictions = model(x)
            >>>
            >>> # optionally, if you want to export the model to ONNX:
            >>> torch.onnx.export(model, x, "keypoint_rcnn.onnx", opset_version = 11)
    
        Arguments:
            pretrained (bool): If True, returns a model pre-trained on COCO train2017
            progress (bool): If True, displays a progress bar of the download to stderr
        """
        if pretrained:
            # no need to download the backbone if pretrained is set
            pretrained_backbone = False
        backbone = resnet_fpn_backbone('resnet50', pretrained_backbone)
>       model = KeypointRCNN(backbone, num_classes, num_keypoints=num_keypoints, **kwargs)
E       TypeError: __init__() got an unexpected keyword argument 'trainable_backbone_layers'

../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/detection/keypoint_rcnn.py:322: TypeError
_______________ Tester.test_maskrcnn_resnet50_fpn_frozen_layers ________________

self = <test_models_detection_utils.Tester testMethod=test_maskrcnn_resnet50_fpn_frozen_layers>

    def test_maskrcnn_resnet50_fpn_frozen_layers(self):
        # we know how many initial layers and parameters of the maskrcnn should
        # be frozen for each trainable_backbone_layers paramter value
        # i.e all 53 params are frozen if trainable_backbone_layers=0
        # ad first 24 params are frozen if trainable_backbone_layers=2
        expected_frozen_params = {0: 53, 1: 43, 2: 24, 3: 11, 4: 1, 5: 0}
        for train_layers, exp_froz_params in expected_frozen_params.items():
            model = maskrcnn_resnet50_fpn(pretrained=True, progress=False,
                                          num_classes=91, pretrained_backbone=False,
>                                         trainable_backbone_layers=train_layers)

test/test_models_detection_utils.py:47: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

pretrained = True, progress = False, num_classes = 91
pretrained_backbone = False, kwargs = {'trainable_backbone_layers': 0}
backbone = BackboneWithFPN(
  (body): IntermediateLayerGetter(
    (conv1): Conv2d(3, 64, kernel_size=(7, 7), stride=(2, 2), padd... Conv2d(256, 256, kernel_size=(3, 3), stride=(1, 1), padding=(1, 1))
    )
    (extra_blocks): LastLevelMaxPool()
  )
)

    def maskrcnn_resnet50_fpn(pretrained=False, progress=True,
                              num_classes=91, pretrained_backbone=True, **kwargs):
        """
        Constructs a Mask R-CNN model with a ResNet-50-FPN backbone.
    
        The input to the model is expected to be a list of tensors, each of shape ``[C, H, W]``, one for each
        image, and should be in ``0-1`` range. Different images can have different sizes.
    
        The behavior of the model changes depending if it is in training or evaluation mode.
    
        During training, the model expects both the input tensors, as well as a targets (list of dictionary),
        containing:
            - boxes (``FloatTensor[N, 4]``): the ground-truth boxes in ``[x1, y1, x2, y2]`` format,  with values of ``x``
              between ``0`` and ``W`` and values of ``y`` between ``0`` and ``H``
            - labels (``Int64Tensor[N]``): the class label for each ground-truth box
            - masks (``UInt8Tensor[N, H, W]``): the segmentation binary masks for each instance
    
        The model returns a ``Dict[Tensor]`` during training, containing the classification and regression
        losses for both the RPN and the R-CNN, and the mask loss.
    
        During inference, the model requires only the input tensors, and returns the post-processed
        predictions as a ``List[Dict[Tensor]]``, one for each input image. The fields of the ``Dict`` are as
        follows:
            - boxes (``FloatTensor[N, 4]``): the predicted boxes in ``[x1, y1, x2, y2]`` format,  with values of ``x``
              between ``0`` and ``W`` and values of ``y`` between ``0`` and ``H``
            - labels (``Int64Tensor[N]``): the predicted labels for each image
            - scores (``Tensor[N]``): the scores or each prediction
            - masks (``UInt8Tensor[N, 1, H, W]``): the predicted masks for each instance, in ``0-1`` range. In order to
              obtain the final segmentation masks, the soft masks can be thresholded, generally
              with a value of 0.5 (``mask >= 0.5``)
    
        Mask R-CNN is exportable to ONNX for a fixed batch size with inputs images of fixed size.
    
        Example::
    
            >>> model = torchvision.models.detection.maskrcnn_resnet50_fpn(pretrained=True)
            >>> model.eval()
            >>> x = [torch.rand(3, 300, 400), torch.rand(3, 500, 400)]
            >>> predictions = model(x)
            >>>
            >>> # optionally, if you want to export the model to ONNX:
            >>> torch.onnx.export(model, x, "mask_rcnn.onnx", opset_version = 11)
    
        Arguments:
            pretrained (bool): If True, returns a model pre-trained on COCO train2017
            progress (bool): If True, displays a progress bar of the download to stderr
        """
        if pretrained:
            # no need to download the backbone if pretrained is set
            pretrained_backbone = False
        backbone = resnet_fpn_backbone('resnet50', pretrained_backbone)
>       model = MaskRCNN(backbone, num_classes, **kwargs)
E       TypeError: __init__() got an unexpected keyword argument 'trainable_backbone_layers'

../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/detection/mask_rcnn.py:318: TypeError
______________________ Tester.test_transform_copy_targets ______________________

self = <test_models_detection_utils.Tester testMethod=test_transform_copy_targets>

    def test_transform_copy_targets(self):
        transform = GeneralizedRCNNTransform(300, 500, torch.zeros(3), torch.ones(3))
        image = [torch.rand(3, 200, 300), torch.rand(3, 200, 200)]
        targets = [{'boxes': torch.rand(3, 4)}, {'boxes': torch.rand(2, 4)}]
        targets_copy = copy.deepcopy(targets)
        out = transform(image, targets)  # noqa: F841
>       self.assertTrue(torch.equal(targets[0]['boxes'], targets_copy[0]['boxes']))
E       AssertionError: False is not true

test/test_models_detection_utils.py:74: AssertionError
______________________________ NMSTester.test_nms ______________________________

self = <test_ops.NMSTester testMethod=test_nms>

    def test_nms(self):
        err_msg = 'NMS incompatible between CPU and reference implementation for IoU={}'
        for iou in [0.2, 0.5, 0.8]:
            boxes, scores = self._create_tensors_with_iou(1000, iou)
            keep_ref = self.reference_nms(boxes, scores, iou)
            keep = ops.nms(boxes, scores, iou)
            self.assertTrue(torch.allclose(keep, keep_ref), err_msg.format(iou))
>       self.assertRaises(RuntimeError, ops.nms, torch.rand(4), torch.rand(3), 0.5)

test/test_ops.py:396: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

    def nms(boxes, scores, iou_threshold):
        # type: (Tensor, Tensor, float)
        """
        Performs non-maximum suppression (NMS) on the boxes according
        to their intersection-over-union (IoU).
    
        NMS iteratively removes lower scoring boxes which have an
        IoU greater than iou_threshold with another (higher scoring)
        box.
    
        Parameters
        ----------
        boxes : Tensor[N, 4])
            boxes to perform NMS on. They
            are expected to be in (x1, y1, x2, y2) format
        scores : Tensor[N]
            scores for each one of the boxes
        iou_threshold : float
            discards all overlapping
            boxes with IoU > iou_threshold
    
        Returns
        -------
        keep : Tensor
            int64 tensor with the indices
            of the elements that have been kept
            by NMS, sorted in decreasing order of scores
        """
>       return torch.ops.torchvision.nms(boxes, scores, iou_threshold)
E       IndexError: Dimension out of range (expected to be in range of [-1, 0], but got 1)

../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/ops/boxes.py:35: IndexError
__________________ FrozenBNTester.test_frozenbatchnorm2d_eps ___________________

self = <test_ops.FrozenBNTester testMethod=test_frozenbatchnorm2d_eps>

    def test_frozenbatchnorm2d_eps(self):
        sample_size = (4, 32, 28, 28)
        x = torch.rand(sample_size)
        state_dict = dict(weight=torch.rand(sample_size[1]),
                          bias=torch.rand(sample_size[1]),
                          running_mean=torch.rand(sample_size[1]),
                          running_var=torch.rand(sample_size[1]),
                          num_batches_tracked=torch.tensor(100))
    
        # Check that default eps is zero for backward-compatibility
        fbn = ops.misc.FrozenBatchNorm2d(sample_size[1])
        fbn.load_state_dict(state_dict, strict=False)
        bn = torch.nn.BatchNorm2d(sample_size[1], eps=0).eval()
        bn.load_state_dict(state_dict)
        # Difference is expected to fall in an acceptable range
        self.assertTrue(torch.allclose(fbn(x), bn(x), atol=1e-6))
    
        # Check computation for eps > 0
>       fbn = ops.misc.FrozenBatchNorm2d(sample_size[1], eps=1e-5)
E       TypeError: __init__() got an unexpected keyword argument 'eps'

test/test_ops.py:572: TypeError
_________________ FrozenBNTester.test_frozenbatchnorm2d_n_arg __________________

self = <test_ops.FrozenBNTester testMethod=test_frozenbatchnorm2d_n_arg>

    def test_frozenbatchnorm2d_n_arg(self):
        """Ensure a warning is thrown when passing `n` kwarg
        (remove this when support of `n` is dropped)"""
>       self.assertWarns(DeprecationWarning, ops.misc.FrozenBatchNorm2d, 32, eps=1e-5, n=32)
E       TypeError: __init__() got an unexpected keyword argument 'eps'

test/test_ops.py:581: TypeError
__________________ FrozenBNTester.test_frozenbatchnorm2d_repr __________________

self = <test_ops.FrozenBNTester testMethod=test_frozenbatchnorm2d_repr>

    def test_frozenbatchnorm2d_repr(self):
        num_features = 32
        t = ops.misc.FrozenBatchNorm2d(num_features)
    
        # Check integrity of object __repr__ attribute
        expected_string = f"FrozenBatchNorm2d({num_features})"
>       self.assertEqual(t.__repr__(), expected_string)
E       AssertionError: 'FrozenBatchNorm2d()' != 'FrozenBatchNorm2d(32)'
E       - FrozenBatchNorm2d()
E       + FrozenBatchNorm2d(32)
E       ?                   ++

test/test_ops.py:552: AssertionError
________________ BoxConversionTester.test_check_roi_boxes_shape ________________

self = <test_ops.BoxConversionTester testMethod=test_check_roi_boxes_shape>

    def test_check_roi_boxes_shape(self):
        # Ensure common sequences of tensors are supported
        for box_sequence in self._get_box_sequences():
>           self.assertIsNone(ops._utils.check_roi_boxes_shape(box_sequence))

test/test_ops.py:597: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

boxes = (tensor([[  0.,   0., 100., 100.]]), tensor([[  0.,   0., 100., 100.]]))

    def check_roi_boxes_shape(boxes):
        if isinstance(boxes, list):
            for _tensor in boxes:
                assert _tensor.size(1) == 4, \
                    'The shape of the tensor in the boxes list is not correct as List[Tensor[L, 4]]'
        elif isinstance(boxes, torch.Tensor):
            assert boxes.size(1) == 5, 'The boxes tensor shape is not correct as Tensor[K, 5]'
        else:
>           assert False, 'boxes is expected to be a Tensor[L, 5] or a List[Tensor[K, 4]]'
E           AssertionError: boxes is expected to be a Tensor[L, 5] or a List[Tensor[K, 4]]

../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/ops/_utils.py:37: AssertionError
__________________________ ModelTester.test_googlenet __________________________

self = <test_quantized_models.ModelTester testMethod=test_googlenet>
model_name = 'googlenet'

    def do_test(self, model_name=model_name):
        input_shape = (1, 3, 224, 224)
        if model_name in ['inception_v3']:
            input_shape = (1, 3, 299, 299)
>       self._test_classification_model(model_name, input_shape)

test/test_quantized_models.py:84: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
test/test_quantized_models.py:53: in _test_classification_model
    model = torchvision.models.quantization.__dict__[name](pretrained=False, quantize=True)
../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/quantization/googlenet.py:50: in googlenet
    model = QuantizableGoogLeNet(**kwargs)
../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/quantization/googlenet.py:138: in __init__
    **kwargs
../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/googlenet.py:110: in __init__
    self._initialize_weights()
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = QuantizableGoogLeNet(
  (conv1): QuantizableBasicConv2d(
    (conv): Conv2d(3, 64, kernel_size=(7, 7), stride=(2, 2), ...ize=(1, 1))
  (dropout): Dropout(p=0.2, inplace=False)
  (fc): Linear(in_features=1024, out_features=1000, bias=True)
)

    def _initialize_weights(self):
        for m in self.modules():
            if isinstance(m, nn.Conv2d) or isinstance(m, nn.Linear):
>               import scipy.stats as stats
E               ModuleNotFoundError: No module named 'scipy'

../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/googlenet.py:115: ModuleNotFoundError
________________ Tester.test_convert_image_dtype_float_to_float ________________

self = <test_transforms.Tester testMethod=test_convert_image_dtype_float_to_float>

    def test_convert_image_dtype_float_to_float(self):
        for input_dtype, output_dtypes in cycle_over(float_dtypes()):
            input_image = torch.tensor((0.0, 1.0), dtype=input_dtype)
            for output_dtype in output_dtypes:
                with self.subTest(input_dtype=input_dtype, output_dtype=output_dtype):
>                   transform = transforms.ConvertImageDtype(output_dtype)
E                   AttributeError: module 'torchvision.transforms' has no attribute 'ConvertImageDtype'

test/test_transforms.py:534: AttributeError
_________________ Tester.test_convert_image_dtype_float_to_int _________________

self = <test_transforms.Tester testMethod=test_convert_image_dtype_float_to_int>

    def test_convert_image_dtype_float_to_int(self):
        for input_dtype in float_dtypes():
            input_image = torch.tensor((0.0, 1.0), dtype=input_dtype)
            for output_dtype in int_dtypes():
                with self.subTest(input_dtype=input_dtype, output_dtype=output_dtype):
>                   transform = transforms.ConvertImageDtype(output_dtype)
E                   AttributeError: module 'torchvision.transforms' has no attribute 'ConvertImageDtype'

test/test_transforms.py:548: AttributeError
_________________ Tester.test_convert_image_dtype_int_to_float _________________

self = <test_transforms.Tester testMethod=test_convert_image_dtype_int_to_float>

    def test_convert_image_dtype_int_to_float(self):
        for input_dtype in int_dtypes():
            input_image = torch.tensor((0, torch.iinfo(input_dtype).max), dtype=input_dtype)
            for output_dtype in float_dtypes():
                with self.subTest(input_dtype=input_dtype, output_dtype=output_dtype):
>                   transform = transforms.ConvertImageDtype(output_dtype)
E                   AttributeError: module 'torchvision.transforms' has no attribute 'ConvertImageDtype'

test/test_transforms.py:569: AttributeError
__________________ Tester.test_convert_image_dtype_int_to_int __________________

self = <test_transforms.Tester testMethod=test_convert_image_dtype_int_to_int>

    def test_convert_image_dtype_int_to_int(self):
        for input_dtype, output_dtypes in cycle_over(int_dtypes()):
            input_max = torch.iinfo(input_dtype).max
            input_image = torch.tensor((0, input_max), dtype=input_dtype)
            for output_dtype in output_dtypes:
                output_max = torch.iinfo(output_dtype).max
    
                with self.subTest(input_dtype=input_dtype, output_dtype=output_dtype):
>                   transform = transforms.ConvertImageDtype(output_dtype)
E                   AttributeError: module 'torchvision.transforms' has no attribute 'ConvertImageDtype'

test/test_transforms.py:588: AttributeError
____________ Tester.test_convert_image_dtype_int_to_int_consistency ____________

self = <test_transforms.Tester testMethod=test_convert_image_dtype_int_to_int_consistency>

    def test_convert_image_dtype_int_to_int_consistency(self):
        for input_dtype, output_dtypes in cycle_over(int_dtypes()):
            input_max = torch.iinfo(input_dtype).max
            input_image = torch.tensor((0, input_max), dtype=input_dtype)
            for output_dtype in output_dtypes:
                output_max = torch.iinfo(output_dtype).max
                if output_max <= input_max:
                    continue
    
                with self.subTest(input_dtype=input_dtype, output_dtype=output_dtype):
>                   transform = transforms.ConvertImageDtype(output_dtype)
E                   AttributeError: module 'torchvision.transforms' has no attribute 'ConvertImageDtype'

test/test_transforms.py:613: AttributeError
_______________________________ Tester.test_pad ________________________________

self = <test_transforms.Tester testMethod=test_pad>

    def test_pad(self):
        height = random.randint(10, 32) * 2
        width = random.randint(10, 32) * 2
        img = torch.ones(3, height, width)
        padding = random.randint(1, 20)
        fill = random.randint(1, 50)
        result = transforms.Compose([
            transforms.ToPILImage(),
            transforms.Pad(padding, fill=fill),
            transforms.ToTensor(),
        ])(img)
        self.assertEqual(result.size(1), height + 2 * padding)
        self.assertEqual(result.size(2), width + 2 * padding)
        # check that all elements in the padded region correspond
        # to the pad value
        fill_v = fill / 255
        eps = 1e-5
>       self.assertTrue((result[:, :padding, :] - fill_v).abs().max() < eps)
E       AssertionError: tensor(False) is not true

test/test_transforms.py:330: AssertionError
__________________________ Tester.test_pil_to_tensor ___________________________

self = <test_transforms.Tester testMethod=test_pil_to_tensor>

    def test_pil_to_tensor(self):
        test_channels = [1, 3, 4]
        height, width = 4, 4
>       trans = transforms.PILToTensor()
E       AttributeError: module 'torchvision.transforms' has no attribute 'PILToTensor'

test/test_transforms.py:636: AttributeError
__________________________ Tester.test_random_erasing __________________________

self = <test_transforms.Tester testMethod=test_random_erasing>

    def test_random_erasing(self):
        """Unit tests for random erasing transform"""
        for is_scripted in [False, True]:
            torch.manual_seed(12)
            img = torch.rand(3, 60, 60)
    
            # Test Set 0: invalid value
            random_erasing = transforms.RandomErasing(value=(0.1, 0.2, 0.3, 0.4), p=1.0)
            with self.assertRaises(ValueError, msg="If value is a sequence, it should have either a single value or 3"):
>               img_re = random_erasing(img)

test/test_transforms.py:1628: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/transforms/transforms.py:1296: in __call__
    return F.erase(img, x, y, h, w, v, self.inplace)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

    def erase(img, i, j, h, w, v, inplace=False):
        """ Erase the input Tensor Image with given value.
    
        Args:
            img (Tensor Image): Tensor image of size (C, H, W) to be erased
            i (int): i in (i,j) i.e coordinates of the upper left corner.
            j (int): j in (i,j) i.e coordinates of the upper left corner.
            h (int): Height of the erased region.
            w (int): Width of the erased region.
            v: Erasing value.
            inplace(bool, optional): For in-place operations. By default is set False.
    
        Returns:
            Tensor Image: Erased image.
        """
        if not isinstance(img, torch.Tensor):
            raise TypeError('img should be Tensor Image. Got {}'.format(type(img)))
    
        if not inplace:
            img = img.clone()
    
>       img[:, i:i + h, j:j + w] = v
E       RuntimeError: The expanded size of the tensor (3) must match the existing size (4) at non-singleton dimension 0.  Target sizes: [3, 10, 17].  Tensor sizes: [4, 10, 17]

../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/transforms/functional.py:905: RuntimeError
___________________________ Tester.test_adjustments ____________________________

self = <test_transforms_tensor.Tester testMethod=test_adjustments>

    def test_adjustments(self):
        fns = ['adjust_brightness', 'adjust_contrast', 'adjust_saturation']
        for _ in range(20):
            factor = 3 * torch.rand(1).item()
            tensor, _ = self._create_data()
            pil_img = T.ToPILImage()(tensor)
    
            for func in fns:
>               adjusted_tensor = getattr(F, func)(tensor, factor)

test/test_transforms_tensor.py:67: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

img = tensor([[[ 13,  23, 243],
         [ 28, 151, 254],
         [ 17,  65,   8]],

        [[171, 221, 193],
         [23...  [207, 130, 190]],

        [[251, 132, 160],
         [182,  87, 245],
         [220,  33,  30]]], dtype=torch.uint8)
brightness_factor = 0.16737663745880127

    def adjust_brightness(img, brightness_factor):
        """Adjust brightness of an Image.
    
        Args:
            img (PIL Image): PIL Image to be adjusted.
            brightness_factor (float):  How much to adjust the brightness. Can be
                any non negative number. 0 gives a black image, 1 gives the
                original image while 2 increases the brightness by a factor of 2.
    
        Returns:
            PIL Image: Brightness adjusted image.
        """
        if not _is_pil_image(img):
>           raise TypeError('img should be PIL Image. Got {}'.format(type(img)))
E           TypeError: img should be PIL Image. Got <class 'torch.Tensor'>

../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/transforms/functional.py:606: TypeError
___________________________ Tester.test_center_crop ____________________________

self = <test_transforms_tensor.Tester testMethod=test_center_crop>

    def test_center_crop(self):
        fn_kwargs = {"output_size": (4, 5)}
        meth_kwargs = {"size": (4, 5), }
        self._test_geom_op(
>           "center_crop", "CenterCrop", fn_kwargs=fn_kwargs, meth_kwargs=meth_kwargs
        )

test/test_transforms_tensor.py:134: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
test/test_transforms_tensor.py:50: in _test_geom_op
    self._test_functional_geom_op(func, fn_kwargs)
test/test_transforms_tensor.py:25: in _test_functional_geom_op
    transformed_tensor = getattr(F, func)(tensor, **fn_kwargs)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

img = tensor([[[ 89, 143,  93,  91, 206,  12, 157,  47, 203, 215],
         [ 25, 245, 200, 120, 149,  46, 155, 133,  19,  9...167, 177, 149,   2, 148, 196],
         [116, 235,  35, 229, 164, 146, 172,  68,  25, 210]]],
       dtype=torch.uint8)
output_size = (4, 5)

    def center_crop(img, output_size):
        """Crop the given PIL Image and resize it to desired size.
    
        Args:
            img (PIL Image): Image to be cropped. (0,0) denotes the top left corner of the image.
            output_size (sequence or int): (height, width) of the crop box. If int,
                it is used for both directions
        Returns:
            PIL Image: Cropped image.
        """
        if isinstance(output_size, numbers.Number):
            output_size = (int(output_size), int(output_size))
>       image_width, image_height = img.size
E       TypeError: 'builtin_function_or_method' object is not iterable

../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/transforms/functional.py:374: TypeError
_______________________________ Tester.test_crop _______________________________

self = <test_transforms_tensor.Tester testMethod=test_crop>

    def test_crop(self):
        fn_kwargs = {"top": 2, "left": 3, "height": 4, "width": 5}
        # Test transforms.RandomCrop with size and padding as tuple
        meth_kwargs = {"size": (4, 5), "padding": (4, 4), "pad_if_needed": True, }
        self._test_geom_op(
>           'crop', 'RandomCrop', fn_kwargs=fn_kwargs, meth_kwargs=meth_kwargs
        )

test/test_transforms_tensor.py:112: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
test/test_transforms_tensor.py:50: in _test_geom_op
    self._test_functional_geom_op(func, fn_kwargs)
test/test_transforms_tensor.py:25: in _test_functional_geom_op
    transformed_tensor = getattr(F, func)(tensor, **fn_kwargs)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

img = tensor([[[135, 131, 163,  58,  51,  11, 221, 134,  63,  51],
         [186,  59,  33, 192, 192,  94, 245,  67, 238,  4... 88,  57, 185, 215, 108,   0],
         [ 80, 245, 165,  28,  55,  24,  36,  73,  66,  89]]],
       dtype=torch.uint8)
top = 2, left = 3, height = 4, width = 5

    def crop(img, top, left, height, width):
        """Crop the given PIL Image.
    
        Args:
            img (PIL Image): Image to be cropped. (0,0) denotes the top left corner of the image.
            top (int): Vertical component of the top left corner of the crop box.
            left (int): Horizontal component of the top left corner of the crop box.
            height (int): Height of the crop box.
            width (int): Width of the crop box.
    
        Returns:
            PIL Image: Cropped image.
        """
        if not _is_pil_image(img):
>           raise TypeError('img should be PIL Image. Got {}'.format(type(img)))
E           TypeError: img should be PIL Image. Got <class 'torch.Tensor'>

../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/transforms/functional.py:357: TypeError
____________________________ Tester.test_five_crop _____________________________

self = <test_transforms_tensor.Tester testMethod=test_five_crop>

    def test_five_crop(self):
        fn_kwargs = meth_kwargs = {"size": (5,)}
        self._test_geom_op_list_output(
>           "five_crop", "FiveCrop", out_length=5, fn_kwargs=fn_kwargs, meth_kwargs=meth_kwargs
        )

test/test_transforms_tensor.py:187: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
test/test_transforms_tensor.py:163: in _test_geom_op_list_output
    transformed_t_list = getattr(F, func)(tensor, **fn_kwargs)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

img = tensor([[[219,  60, 123,  ..., 227,   6,  59],
         [105, 193, 129,  ...,  14,  83, 175],
         [ 41, 111, 186,...74],
         [ 39, 194, 254,  ..., 134, 177, 220],
         [244, 167, 206,  ..., 228,  99, 151]]], dtype=torch.uint8)
size = (5,)

    def five_crop(img, size):
        """Crop the given PIL Image into four corners and the central crop.
    
        .. Note::
            This transform returns a tuple of images and there may be a
            mismatch in the number of inputs and targets your ``Dataset`` returns.
    
        Args:
           size (sequence or int): Desired output size of the crop. If size is an
               int instead of sequence like (h, w), a square crop (size, size) is
               made.
    
        Returns:
           tuple: tuple (tl, tr, bl, br, center)
                    Corresponding top left, top right, bottom left, bottom right and center crop.
        """
        if isinstance(size, numbers.Number):
            size = (int(size), int(size))
        else:
>           assert len(size) == 2, "Please provide only two dimensions (h, w) for size."
E           AssertionError: Please provide only two dimensions (h, w) for size.

../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/transforms/functional.py:540: AssertionError
_______________________________ Tester.test_pad ________________________________

self = <test_transforms_tensor.Tester testMethod=test_pad>

    def test_pad(self):
    
        # Test functional.pad (PIL and Tensor) with padding as single int
        self._test_functional_geom_op(
>           "pad", fn_kwargs={"padding": 2, "fill": 0, "padding_mode": "constant"}
        )

test/test_transforms_tensor.py:89: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
test/test_transforms_tensor.py:25: in _test_functional_geom_op
    transformed_tensor = getattr(F, func)(tensor, **fn_kwargs)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

img = tensor([[[ 97, 162, 139, 204, 195,  16, 100,  72,  40, 252],
         [ 53, 115, 105, 242, 122, 191,  24, 175, 176,  8...106, 112,  96,  55,  76,   5],
         [ 13,  88, 158, 226, 235,  27,  93, 173, 157,  78]]],
       dtype=torch.uint8)
padding = 2, fill = 0, padding_mode = 'constant'

    def pad(img, padding, fill=0, padding_mode='constant'):
        r"""Pad the given PIL Image on all sides with specified padding mode and fill value.
    
        Args:
            img (PIL Image): Image to be padded.
            padding (int or tuple): Padding on each border. If a single int is provided this
                is used to pad all borders. If tuple of length 2 is provided this is the padding
                on left/right and top/bottom respectively. If a tuple of length 4 is provided
                this is the padding for the left, top, right and bottom borders
                respectively.
            fill: Pixel fill value for constant fill. Default is 0. If a tuple of
                length 3, it is used to fill R, G, B channels respectively.
                This value is only used when the padding_mode is constant
            padding_mode: Type of padding. Should be: constant, edge, reflect or symmetric. Default is constant.
    
                - constant: pads with a constant value, this value is specified with fill
    
                - edge: pads with the last value on the edge of the image
    
                - reflect: pads with reflection of image (without repeating the last value on the edge)
    
                           padding [1, 2, 3, 4] with 2 elements on both sides in reflect mode
                           will result in [3, 2, 1, 2, 3, 4, 3, 2]
    
                - symmetric: pads with reflection of image (repeating the last value on the edge)
    
                             padding [1, 2, 3, 4] with 2 elements on both sides in symmetric mode
                             will result in [2, 1, 1, 2, 3, 4, 4, 3]
    
        Returns:
            PIL Image: Padded image.
        """
        if not _is_pil_image(img):
>           raise TypeError('img should be PIL Image. Got {}'.format(type(img)))
E           TypeError: img should be PIL Image. Got <class 'torch.Tensor'>

../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/transforms/functional.py:288: TypeError
______________________ Tester.test_random_horizontal_flip ______________________

self = <test_transforms_tensor.Tester testMethod=test_random_horizontal_flip>

    def test_random_horizontal_flip(self):
>       self._test_geom_op('hflip', 'RandomHorizontalFlip')

test/test_transforms_tensor.py:54: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
test/test_transforms_tensor.py:50: in _test_geom_op
    self._test_functional_geom_op(func, fn_kwargs)
test/test_transforms_tensor.py:25: in _test_functional_geom_op
    transformed_tensor = getattr(F, func)(tensor, **fn_kwargs)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

img = tensor([[[229,  99, 248,  42,  45,  34, 232, 134,  89, 175],
         [  7, 253, 224,  99, 130,  39, 158,  51, 145, 22... 13, 245, 171, 218, 244,  45],
         [111, 161, 149, 126,  80,  66,  65, 133, 144, 132]]],
       dtype=torch.uint8)

    def hflip(img):
        """Horizontally flip the given PIL Image.
    
        Args:
            img (PIL Image): Image to be flipped.
    
        Returns:
            PIL Image:  Horizontall flipped image.
        """
        if not _is_pil_image(img):
>           raise TypeError('img should be PIL Image. Got {}'.format(type(img)))
E           TypeError: img should be PIL Image. Got <class 'torch.Tensor'>

../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/transforms/functional.py:414: TypeError
_______________________ Tester.test_random_vertical_flip _______________________

self = <test_transforms_tensor.Tester testMethod=test_random_vertical_flip>

    def test_random_vertical_flip(self):
>       self._test_geom_op('vflip', 'RandomVerticalFlip')

test/test_transforms_tensor.py:57: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
test/test_transforms_tensor.py:50: in _test_geom_op
    self._test_functional_geom_op(func, fn_kwargs)
test/test_transforms_tensor.py:25: in _test_functional_geom_op
    transformed_tensor = getattr(F, func)(tensor, **fn_kwargs)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

img = tensor([[[ 27,  51, 149, 227, 198, 123, 137, 103, 116,  92],
         [ 50, 207,  25, 161, 207, 187, 159, 100, 237,  9... 46,  66, 243, 251,  20,  56],
         [147, 254, 107, 159,  28, 167,  34, 175, 151, 151]]],
       dtype=torch.uint8)

    def vflip(img):
        """Vertically flip the given PIL Image.
    
        Args:
            img (PIL Image): Image to be flipped.
    
        Returns:
            PIL Image:  Vertically flipped image.
        """
        if not _is_pil_image(img):
>           raise TypeError('img should be PIL Image. Got {}'.format(type(img)))
E           TypeError: img should be PIL Image. Got <class 'torch.Tensor'>

../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/transforms/functional.py:516: TypeError
_____________________________ Tester.test_ten_crop _____________________________

self = <test_transforms_tensor.Tester testMethod=test_ten_crop>

    def test_ten_crop(self):
        fn_kwargs = meth_kwargs = {"size": (5,)}
        self._test_geom_op_list_output(
>           "ten_crop", "TenCrop", out_length=10, fn_kwargs=fn_kwargs, meth_kwargs=meth_kwargs
        )

test/test_transforms_tensor.py:205: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
test/test_transforms_tensor.py:163: in _test_geom_op_list_output
    transformed_t_list = getattr(F, func)(tensor, **fn_kwargs)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

img = tensor([[[ 46,   2, 204,  ...,  30, 248, 240],
         [ 93, 122, 181,  ...,  91,   7,  31],
         [156, 126, 237,...59],
         [106,  98, 183,  ...,  97, 254, 240],
         [147, 171, 142,  ..., 254, 176,  50]]], dtype=torch.uint8)
size = (5,), vertical_flip = False

    def ten_crop(img, size, vertical_flip=False):
        """Generate ten cropped images from the given PIL Image.
        Crop the given PIL Image into four corners and the central crop plus the
        flipped version of these (horizontal flipping is used by default).
    
        .. Note::
            This transform returns a tuple of images and there may be a
            mismatch in the number of inputs and targets your ``Dataset`` returns.
    
        Args:
            size (sequence or int): Desired output size of the crop. If size is an
                int instead of sequence like (h, w), a square crop (size, size) is
                made.
            vertical_flip (bool): Use vertical flipping instead of horizontal
    
        Returns:
            tuple: tuple (tl, tr, bl, br, center, tl_flip, tr_flip, bl_flip, br_flip, center_flip)
                Corresponding top left, top right, bottom left, bottom right and
                center crop and same for the flipped image.
        """
        if isinstance(size, numbers.Number):
            size = (int(size), int(size))
        else:
>           assert len(size) == 2, "Please provide only two dimensions (h, w) for size."
E           AssertionError: Please provide only two dimensions (h, w) for size.

../anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/transforms/functional.py:580: AssertionError
=============================== warnings summary ===============================
/home/aryaman4/anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/__init__.py:64
  /home/aryaman4/anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/__init__.py:64: UserWarning: video_reader video backend is not available
    warnings.warn("video_reader video backend is not available")

test/test_datasets.py::Tester::test_fashionmnist
  /pytorch/torch/csrc/utils/tensor_numpy.cpp:141: UserWarning: The given NumPy array is not writeable, and PyTorch does not support non-writeable tensors. This means you can write to the underlying (supposedly non-writeable) NumPy array using the tensor. You may want to copy the array to protect its data or make it writeable before converting it to a tensor. This type of warning will be suppressed for the rest of this program.

test/test_models.py: 10 tests with warnings
test/test_models_detection_utils.py: 1 test with warning
  /home/aryaman4/anaconda3/envs/vision/lib/python3.6/site-packages/torch/nn/functional.py:2854: UserWarning: The default behavior for interpolate/upsample with float scale_factor will change in 1.6.0 to align with other frameworks/libraries, and use scale_factor directly, instead of relying on the computed output size. If you wish to keep the old behavior, please set recompute_scale_factor=True. See the documentation of nn.Upsample for details. 
    warnings.warn("The default behavior for interpolate/upsample with float scale_factor will change "

test/test_models.py::ModelTester::test_fasterrcnn_double
  /pytorch/torch/csrc/utils/python_arg_parser.cpp:756: UserWarning: This overload of nonzero is deprecated:
  	nonzero(Tensor input, *, Tensor out)
  Consider using one of the following signatures instead:
  	nonzero(Tensor input, *, bool as_tuple)

test/test_models.py::ModelTester::test_fasterrcnn_resnet50_fpn
test/test_models.py::ModelTester::test_keypointrcnn_resnet50_fpn
test/test_models.py::ModelTester::test_maskrcnn_resnet50_fpn
  /home/aryaman4/anaconda3/envs/vision/lib/python3.6/site-packages/torchvision/models/detection/generalized_rcnn.py:80: UserWarning: RCNN always returns a (Losses, Detections) tuple in scripting
    warnings.warn("RCNN always returns a (Losses, Detections) tuple in scripting")

test/test_models.py::ModelTester::test_memory_efficient_densenet
  /home/aryaman4/anaconda3/envs/vision/lib/python3.6/site-packages/torch/utils/checkpoint.py:25: UserWarning: None of the inputs have requires_grad=True. Gradients will be None
    warnings.warn("None of the inputs have requires_grad=True. Gradients will be None")

test/test_quantized_models.py::ModelTester::test_mobilenet_v2
test/test_quantized_models.py::ModelTester::test_resnet18
test/test_quantized_models.py::ModelTester::test_resnet50
test/test_quantized_models.py::ModelTester::test_resnext101_32x8d
test/test_quantized_models.py::ModelTester::test_shufflenet_v2_x0_5
test/test_quantized_models.py::ModelTester::test_shufflenet_v2_x1_0
test/test_quantized_models.py::ModelTester::test_shufflenet_v2_x1_5
test/test_quantized_models.py::ModelTester::test_shufflenet_v2_x2_0
  /home/aryaman4/anaconda3/envs/vision/lib/python3.6/site-packages/torch/quantization/observer.py:208: UserWarning: Must run observer before calling calculate_qparams.                           Returning default scale and zero point.
    Returning default scale and zero point.")

test/test_transforms_video.py::TestVideoTransforms::test_random_resized_crop_video
  /home/aryaman4/anaconda3/envs/vision/lib/python3.6/site-packages/torch/nn/functional.py:2973: UserWarning: Default upsampling behavior when mode=bilinear is changed to align_corners=False since 0.4.0. Please specify align_corners=True if the old behavior is desired. See the documentation of nn.Upsample for details.
    "See the documentation of nn.Upsample for details.".format(mode))

-- Docs: https://docs.pytest.org/en/latest/warnings.html
============================ slowest test durations ============================
24.07s call     test/test_ops.py::DeformConvTester::test_backward_cpu_non_contiguous
19.12s call     test/test_ops.py::DeformConvTester::test_backward_cpu_contiguous
9.32s call     test/test_quantized_models.py::ModelTester::test_resnext101_32x8d
8.97s call     test/test_models.py::ModelTester::test_fasterrcnn_double
7.30s call     test/test_transforms.py::Tester::test_affine
6.65s call     test/test_models.py::ModelTester::test_keypointrcnn_resnet50_fpn
4.32s call     test/test_models.py::ModelTester::test_resnet_dilation
3.74s call     test/test_models.py::ModelTester::test_maskrcnn_resnet50_fpn
3.72s call     test/test_models.py::ModelTester::test_fasterrcnn_resnet50_fpn
2.86s call     test/test_quantized_models.py::ModelTester::test_resnet50
2.04s call     test/test_datasets.py::Tester::test_cityscapes
2.04s call     test/test_models.py::ModelTester::test_vgg19_bn
2.03s call     test/test_models.py::ModelTester::test_vgg19
1.96s call     test/test_models.py::ModelTester::test_vgg16_bn
1.95s call     test/test_models.py::ModelTester::test_vgg16
1.89s call     test/test_models.py::ModelTester::test_vgg13_bn
1.87s call     test/test_models.py::ModelTester::test_vgg13
1.87s call     test/test_models.py::ModelTester::test_vgg11_bn
1.86s call     test/test_models.py::ModelTester::test_vgg11
1.77s call     test/test_models.py::ModelTester::test_wide_resnet101_2
1.73s call     test/test_models.py::ModelTester::test_googlenet_eval
1.57s call     test/test_ops.py::DeformConvTester::test_forward_cpu_non_contiguous
1.57s call     test/test_ops.py::DeformConvTester::test_forward_cpu_contiguous
1.52s call     test/test_models.py::ModelTester::test_deeplabv3_resnet101
1.28s call     test/test_models.py::ModelTester::test_resnext101_32x8d
1.25s call     test/test_quantized_models.py::ModelTester::test_resnet18
1.19s call     test/test_quantized_models.py::ModelTester::test_shufflenet_v2_x2_0
1.11s call     test/test_models.py::ModelTester::test_fcn_resnet101
0.98s call     test/test_quantized_models.py::ModelTester::test_shufflenet_v2_x1_5
0.96s call     test/test_quantized_models.py::ModelTester::test_mobilenet_v2
0.95s call     test/test_models.py::ModelTester::test_wide_resnet50_2
0.93s call     test/test_models.py::ModelTester::test_resnet152
0.93s call     test/test_models_detection_negative_samples.py::Tester::test_forward_negative_sample_krcnn
0.89s call     test/test_quantized_models.py::ModelTester::test_shufflenet_v2_x1_0
0.85s call     test/test_ops.py::RoIAlignTester::test_forward_cpu_non_contiguous
0.84s call     test/test_ops.py::RoIAlignTester::test_forward_cpu_contiguous
0.83s call     test/test_quantized_models.py::ModelTester::test_shufflenet_v2_x0_5
0.74s call     test/test_models.py::ModelTester::test_deeplabv3_resnet50
0.73s call     test/test_models_detection_negative_samples.py::Tester::test_forward_negative_sample_mrcnn
0.71s call     test/test_models_detection_negative_samples.py::Tester::test_forward_negative_sample_frcnn
0.68s call     test/test_models.py::ModelTester::test_resnet101
0.67s call     test/test_models.py::ModelTester::test_memory_efficient_densenet
0.67s call     test/test_models.py::ModelTester::test_keypointrcnn_resnet50_fpn_validation
0.64s call     test/test_models.py::ModelTester::test_r2plus1d_18
0.63s call     test/test_models.py::ModelTester::test_r3d_18
0.60s call     test/test_models.py::ModelTester::test_fcn_resnet50
0.56s call     test/test_models.py::ModelTester::test_densenet161
0.47s call     test/test_models.py::ModelTester::test_maskrcnn_resnet50_fpn_validation
0.45s call     test/test_backbone_utils.py::ResnetFPNBackboneTester::test_resnet50_fpn_backbone
0.43s call     test/test_models.py::ModelTester::test_fasterrcnn_resnet50_fpn_validation
0.41s call     test/test_models.py::ModelTester::test_densenet201
0.38s call     test/test_models.py::ModelTester::test_alexnet
0.38s call     test/test_models.py::ModelTester::test_resnet50
0.37s call     test/test_datasets_utils.py::Tester::test_download_url
0.37s call     test/test_models.py::ModelTester::test_resnext50_32x4d
0.34s call     test/test_models_detection_utils.py::Tester::test_keypointrcnn_resnet50_fpn_frozen_layers
0.34s call     test/test_ops.py::NMSTester::test_nms
0.34s call     test/test_models_detection_utils.py::Tester::test_maskrcnn_resnet50_fpn_frozen_layers
0.34s call     test/test_models_detection_utils.py::Tester::test_fasterrcnn_resnet50_fpn_frozen_layers
0.33s call     test/test_datasets_utils.py::Tester::test_download_url_retry_http
0.33s call     test/test_models.py::ModelTester::test_resnet34
0.32s call     test/test_models.py::ModelTester::test_mc3_18
0.29s call     test/test_models.py::ModelTester::test_densenet169
0.26s call     test/test_transforms.py::Tester::test_linear_transformation
0.24s call     test/test_backbone_utils.py::ResnetFPNBackboneTester::test_resnet18_fpn_backbone
0.21s call     test/test_datasets_utils.py::Tester::test_download_url_dont_exist
0.20s call     test/test_models.py::ModelTester::test_densenet121
0.18s call     test/test_models.py::ModelTester::test_resnet18
0.14s call     test/test_models.py::ModelTester::test_inception_v3
0.12s call     test/test_models.py::ModelTester::test_mnasnet1_3
0.11s call     test/test_ops.py::RoIPoolTester::test_backward_cpu_non_contiguous
0.11s call     test/test_ops.py::RoIAlignTester::test_backward_cpu_non_contiguous
0.10s call     test/test_ops.py::RoIPoolTester::test_backward_cpu_contiguous
0.10s call     test/test_ops.py::RoIAlignTester::test_backward_cpu_contiguous
0.10s call     test/test_ops.py::PSRoIAlignTester::test_backward_cpu_non_contiguous
0.09s call     test/test_ops.py::PSRoIPoolTester::test_backward_cpu_non_contiguous
0.09s call     test/test_ops.py::PSRoIAlignTester::test_backward_cpu_contiguous
0.09s call     test/test_ops.py::PSRoIPoolTester::test_backward_cpu_contiguous
0.08s call     test/test_models.py::ModelTester::test_mnasnet1_0
0.08s call     test/test_quantized_models.py::ModelTester::test_googlenet
0.07s call     test/test_models.py::ModelTester::test_mnasnet0_75
0.07s call     test/test_models.py::ModelTester::test_mobilenet_v2
0.07s call     test/test_models.py::ModelTester::test_shufflenet_v2_x2_0
0.06s call     test/test_models.py::ModelTester::test_googlenet
0.06s call     test/test_models.py::ModelTester::test_mobilenetv2_norm_layer
0.06s call     test/test_models.py::ModelTester::test_mnasnet0_5
0.05s call     test/test_models.py::ModelTester::test_shufflenet_v2_x1_5
0.04s call     test/test_models.py::ModelTester::test_squeezenet1_0
0.04s call     test/test_models.py::ModelTester::test_shufflenet_v2_x1_0
0.04s call     test/test_models.py::ModelTester::test_mobilenetv2_residual_setting
0.04s call     test/test_ops.py::PSRoIAlignTester::test_forward_cpu_non_contiguous
0.04s call     test/test_ops.py::PSRoIAlignTester::test_forward_cpu_contiguous
0.03s call     test/test_models.py::ModelTester::test_shufflenet_v2_x0_5
0.03s call     test/test_models.py::ModelTester::test_squeezenet1_1
0.01s call     test/test_transforms.py::Tester::test_randomperspective
0.01s call     test/test_ops.py::PSRoIPoolTester::test_forward_cpu_contiguous
0.01s call     test/test_ops.py::PSRoIPoolTester::test_forward_cpu_non_contiguous
0.01s call     test/test_models_detection_negative_samples.py::Tester::test_assign_targets_to_proposals
0.01s call     test/test_models_detection_utils.py::Tester::test_transform_copy_targets
0.01s call     test/test_ops.py::RoIPoolTester::test_forward_cpu_non_contiguous
0.01s call     test/test_ops.py::RoIPoolTester::test_forward_cpu_contiguous

(0.00 durations hidden.  Use -vv to show these durations.)
=========================== short test summary info ============================
FAILED test/test_datasets.py::Tester::test_imagefolder_empty - TypeError: can...
FAILED test/test_models.py::ModelTester::test_fasterrcnn_resnet50_fpn_validation
FAILED test/test_models.py::ModelTester::test_googlenet - ModuleNotFoundError...
FAILED test/test_models.py::ModelTester::test_inception_v3 - ModuleNotFoundEr...
FAILED test/test_models.py::ModelTester::test_keypointrcnn_resnet50_fpn_validation
FAILED test/test_models.py::ModelTester::test_maskrcnn_resnet50_fpn_validation
FAILED test/test_models.py::ModelTester::test_memory_efficient_densenet - Ass...
FAILED test/test_models.py::ModelTester::test_mobilenetv2_norm_layer - TypeEr...
FAILED test/test_models_detection_utils.py::Tester::test_fasterrcnn_resnet50_fpn_frozen_layers
FAILED test/test_models_detection_utils.py::Tester::test_keypointrcnn_resnet50_fpn_frozen_layers
FAILED test/test_models_detection_utils.py::Tester::test_maskrcnn_resnet50_fpn_frozen_layers
FAILED test/test_models_detection_utils.py::Tester::test_transform_copy_targets
FAILED test/test_ops.py::NMSTester::test_nms - IndexError: Dimension out of r...
FAILED test/test_ops.py::FrozenBNTester::test_frozenbatchnorm2d_eps - TypeErr...
FAILED test/test_ops.py::FrozenBNTester::test_frozenbatchnorm2d_n_arg - TypeE...
FAILED test/test_ops.py::FrozenBNTester::test_frozenbatchnorm2d_repr - Assert...
FAILED test/test_ops.py::BoxConversionTester::test_check_roi_boxes_shape - As...
FAILED test/test_quantized_models.py::ModelTester::test_googlenet - ModuleNot...
FAILED test/test_transforms.py::Tester::test_convert_image_dtype_float_to_float
FAILED test/test_transforms.py::Tester::test_convert_image_dtype_float_to_int
FAILED test/test_transforms.py::Tester::test_convert_image_dtype_int_to_float
FAILED test/test_transforms.py::Tester::test_convert_image_dtype_int_to_int
FAILED test/test_transforms.py::Tester::test_convert_image_dtype_int_to_int_consistency
FAILED test/test_transforms.py::Tester::test_pad - AssertionError: tensor(Fal...
FAILED test/test_transforms.py::Tester::test_pil_to_tensor - AttributeError: ...
FAILED test/test_transforms.py::Tester::test_random_erasing - RuntimeError: T...
FAILED test/test_transforms_tensor.py::Tester::test_adjustments - TypeError: ...
FAILED test/test_transforms_tensor.py::Tester::test_center_crop - TypeError: ...
FAILED test/test_transforms_tensor.py::Tester::test_crop - TypeError: img sho...
FAILED test/test_transforms_tensor.py::Tester::test_five_crop - AssertionErro...
FAILED test/test_transforms_tensor.py::Tester::test_pad - TypeError: img shou...
FAILED test/test_transforms_tensor.py::Tester::test_random_horizontal_flip - ...
FAILED test/test_transforms_tensor.py::Tester::test_random_vertical_flip - Ty...
FAILED test/test_transforms_tensor.py::Tester::test_ten_crop - AssertionError...
===== 34 failed, 162 passed, 126 skipped, 27 warnings in 146.53s (0:02:26) =====
