Skip to content

How can I force the model to show labels completely? #147

Closed Locked Answered by SkalskiP
amir-sbg asked this question in Q&A
Discussion options

You must be logged in to vote

Hi, @amir-sbg 👋🏻! Sorry I made you wait so long... I was working on other things on Monday. But at least I have a fix for you 🔥

Fixed code

import ultralytics
import cv2
import argparse
from ultralytics import YOLO
import supervision as sv
import numpy as np


def parse_arguments() -> argparse.Namespace:
    parser = argparse.ArgumentParser(description="YOLOv8 live")
    parser.add_argument(
        "--webcam-resolution",
        default=[640, 360],
        nargs=2,
        type=int
    )
    args = parser.parse_args()
    return args


def object_detection_setting():
    args = parse_arguments()
    frame_width, frame_height = args.webcam_resolution

    # cap_outside = cv2.VideoCapture(0)

Replies: 8 comments 6 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
4 replies
@SkalskiP
Comment options

@amir-sbg
Comment options

@SkalskiP
Comment options

@amir-sbg
Comment options

Comment options

You must be logged in to vote
1 reply
@hardikdava
Comment options

Answer selected by SkalskiP
Comment options

You must be logged in to vote
1 reply
@NaufalGhifari
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
5 participants