Skip to content

Commit

Permalink
Merge pull request #16 from humphrem/ruff-linting
Browse files Browse the repository at this point in the history
Use ruff for linting Python, fix errors
  • Loading branch information
humphrem authored Oct 14, 2023
2 parents 4d0fbeb + cea903c commit 7330f4a
Show file tree
Hide file tree
Showing 5 changed files with 681 additions and 579 deletions.
2 changes: 1 addition & 1 deletion action.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
)
from yolo_fish_detector import YoloFishDetector
from megadetector_detector import MegadetectorDetector
from utils import *
from utils import format_time, format_percent, get_video_paths

import cv2

Expand Down
4 changes: 3 additions & 1 deletion base_detector.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ def __init__(
buffer,
confidence,
class_name,
providers=["CPUExecutionProvider"],
providers=None,
):
"""
Initialize the detector with model parameters and provider.
Expand All @@ -47,6 +47,8 @@ def __init__(
class_name: Name of the class to be detected.
providers: List of providers for ONNX runtime. Default is CPUExecutionProvider.
"""
if providers is None:
providers = ["CPUExecutionProvider"]
self.logger = logger
self.model_path = model_path
self.input_image_height = input_image_height
Expand Down
Loading

0 comments on commit 7330f4a

Please sign in to comment.