补全yolov5的代码
This commit is contained in:
@ -18,9 +18,9 @@ from PIL import Image, ImageDraw
|
||||
from scipy.ndimage.filters import gaussian_filter1d
|
||||
from ultralytics.utils.plotting import Annotator
|
||||
|
||||
from utils import TryExcept, threaded
|
||||
from utils.general import LOGGER, clip_boxes, increment_path, xywh2xyxy, xyxy2xywh
|
||||
from utils.metrics import fitness
|
||||
from yolov5.utils import TryExcept, threaded
|
||||
from yolov5.utils.general import LOGGER, clip_boxes, increment_path, xywh2xyxy, xyxy2xywh
|
||||
from yolov5.utils.metrics import fitness
|
||||
|
||||
# Settings
|
||||
RANK = int(os.getenv("RANK", -1))
|
||||
@ -372,7 +372,7 @@ def plot_labels(labels, names=(), save_dir=Path("")):
|
||||
|
||||
def imshow_cls(im, labels=None, pred=None, names=None, nmax=25, verbose=False, f=Path("images.jpg")):
|
||||
"""Displays a grid of images with optional labels and predictions, saving to a file."""
|
||||
from utils.augmentations import denormalize
|
||||
from yolov5.utils.augmentations import denormalize
|
||||
|
||||
names = names or [f"class{i}" for i in range(1000)]
|
||||
blocks = torch.chunk(
|
||||
|
Reference in New Issue
Block a user