opencv 运动追踪_足球运动员追踪-使用OpenCV根据运动员的球衣颜色识别运动员的球队

该博客介绍如何利用OpenCV的运动追踪功能,通过球员球衣颜色来识别他们在比赛中的队伍。
摘要由CSDN通过智能技术生成

opencv 运动追踪

介绍 (Introduction)

In my previous work, I used pre-trained Yolov3 model to detect and used SORT (simple online and realtime tracking) to track football players from video. Then I used OpenCV’s getPerspectiveTransform function to convert the video to bird’s-eye view.

在我以前的工作中,我使用了预先训练的Yolov3模型来检测并使用SORT(简单的在线和实时跟踪)从视频中跟踪足球运动员。 然后,我使用OpenCVgetPerspectiveTransform函数将视频转换为鸟瞰图。

One of the problems of this work is that the model cannot tell the difference between teams. It will be good if the program is able to identify players’ team instead of just detecting ‘person’. To further improve this, I wish to include a function which tells the difference based on the colors of players’ jersey.

这项工作的问题之一是模型无法区分团队之间的差异。 如果程序能够识别玩家的团队而不仅仅是检测“人”,那将是很好的。 为了进一步改善这一点,我希望包含一个功能,该功能根据球员球衣的颜色来区分差异。

Two approaches I can think of now to this problem.

我现在可以想到两种解决这个问题的方法。

  1. Train an object detection model using custom dataset containing 3 classes — the players of two teams and referees. This approach might not be practical for real application because one has to train a specific model before every match.

    使用包含3个类的自定义数据集训练对象检测模型-两个团队的球员和裁判。 这种方法对于实际应用可能不切实际,因为必须在每次比赛之前训练一种特定的模型。
  2. Use to current object detection model and extract the color information from the detections. Based on that I can identify the color of players’ jersey.

    用于当前物体检测模型并从检测中提取颜色信息。 基于此,我可以识别球员球衣的颜色。

I decided to try approach 2 using OpenCV.

我决定尝试使用OpenCV方法2。

足球视频 (Football video)

The stationary football video is downloaded from

  • 2
    点赞
  • 15
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值