Skip to content

Commit

Permalink
ultralytics upgraded
Browse files Browse the repository at this point in the history
  • Loading branch information
mgonzs13 committed Jun 28, 2024
1 parent 7763938 commit e6ae844
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
opencv-python==4.8.1.78
typing-extensions>=4.4.0
ultralytics==8.2.38
ultralytics==8.2.45
lap==0.4.0
4 changes: 2 additions & 2 deletions yolov8_ros/yolov8_ros/yolov8_node.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@

from cv_bridge import CvBridge

from torch import cuda
import torch
from ultralytics import YOLO
from ultralytics.engine.results import Results
from ultralytics.engine.results import Boxes
Expand Down Expand Up @@ -125,7 +125,7 @@ def on_deactivate(self, state: LifecycleState) -> TransitionCallbackReturn:
del self.yolo
if "cuda" in self.device:
self.get_logger().info("Clearing CUDA cache")
cuda.empty_cache()
torch.cuda.empty_cache()

self.destroy_subscription(self._sub)
self._sub = None
Expand Down

0 comments on commit e6ae844

Please sign in to comment.