Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion torchvision/__init__.py
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
import warnings

from .extension import _HAS_OPS

from torchvision import models
from torchvision import datasets
from torchvision import ops
from torchvision import transforms
from torchvision import utils
from torchvision import io

from .extension import _HAS_OPS
import torch

try:
Expand Down
2 changes: 1 addition & 1 deletion torchvision/models/detection/transform.py
Original file line number Diff line number Diff line change
Expand Up @@ -223,4 +223,4 @@ def resize_boxes(boxes, original_size, new_size):
xmax = xmax * ratio_width
ymin = ymin * ratio_height
ymax = ymax * ratio_height
return torch.stack((xmin, ymin, xmax, ymax), dim=1)
return torch.stack((xmin, ymin, xmax, ymax), dim=1)
2 changes: 2 additions & 0 deletions torchvision/ops/boxes.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
import torchvision


@torch.jit.script
def nms(boxes, scores, iou_threshold):
# type: (Tensor, Tensor, float)
"""
Expand Down Expand Up @@ -35,6 +36,7 @@ def nms(boxes, scores, iou_threshold):
return torch.ops.torchvision.nms(boxes, scores, iou_threshold)


@torch.jit.script
def batched_nms(boxes, scores, idxs, iou_threshold):
# type: (Tensor, Tensor, Tensor, float)
"""
Expand Down