Browse Source

Fix missing imports (#627)

* Fix missing imports

* Update detect.py

Co-authored-by: Glenn Jocher <glenn.jocher@ultralytics.com>
5.0
lorenzomammana GitHub 4 years ago
parent
commit
728efa6576
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 2 deletions
  1. +2
    -1
      detect.py
  2. +1
    -1
      train.py

+ 2
- 1
detect.py View File



from models.experimental import attempt_load from models.experimental import attempt_load
from utils.datasets import LoadStreams, LoadImages from utils.datasets import LoadStreams, LoadImages
from utils.general import check_img_size, non_max_suppression, apply_classifier, scale_coords, xyxy2xywh, plot_one_box
from utils.general import (
check_img_size, non_max_suppression, apply_classifier, scale_coords, xyxy2xywh, plot_one_box, strip_optimizer)
from utils.torch_utils import select_device, load_classifier, time_synchronized from utils.torch_utils import select_device, load_classifier, time_synchronized





+ 1
- 1
train.py View File

from utils.general import ( from utils.general import (
check_img_size, torch_distributed_zero_first, labels_to_class_weights, plot_labels, check_anchors, check_img_size, torch_distributed_zero_first, labels_to_class_weights, plot_labels, check_anchors,
labels_to_image_weights, compute_loss, plot_images, fitness, strip_optimizer, plot_results, labels_to_image_weights, compute_loss, plot_images, fitness, strip_optimizer, plot_results,
get_latest_run, check_git_status, check_file, increment_dir, print_mutation)
get_latest_run, check_git_status, check_file, increment_dir, print_mutation, plot_evolution)
from utils.google_utils import attempt_download from utils.google_utils import attempt_download
from utils.torch_utils import init_seeds, ModelEMA, select_device from utils.torch_utils import init_seeds, ModelEMA, select_device



Loading…
Cancel
Save