GBIM(Gesture-Based Interaction map)

Overview

GBIM

Python 3.6 PaddleX License

手势交互地图 GBIM(Gesture-Based Interaction map),基于视觉深度神经网络的交互地图,通过电脑摄像头观察使用者的手势变化,进而控制地图进行简单的交互。网络使用PaddleX提供的轻量级模型PPYOLO Tiny以及MobileNet V3 small,使得整个模型大小约10MB左右,即使在CPU下也能快速定位和识别手势。

手势

手势 交互 手势 交互 手势 交互
向上滑动 向左滑动 地图放大
手势 交互 手势 交互 手势 交互
向下滑动 向右滑动 地图缩小

进度安排

基础

  • 确认用于交互的手势。
  • 使用det_acq.py采集一些电脑摄像头拍摄的人手姿势数据。
  • 数据标注,训练手的目标检测模型
  • 捕获目标手,使用clas_acq.py获取手部图像进行标注,并用于训练手势分类模型。
  • 交互手势的检测与识别组合验证。
  • 打开百度地图网页版,进行模拟按键交互。
  • 组合功能,验证基本功能。

进阶

  • 将图像分类改为序列图像分类,提高手势识别的流畅度和准确度。
  • 重新采集和标注数据,调参训练模型。
  • 搭建可用于参数调节的地图。
  • 界面整合,整理及美化。

数据集 & 模型

手势检测

  • 数据集使用来自联想小新笔记本摄像头采集的数据,使用labelImg标注为VOC格式,共1011张。该数据集场景、环境和人物单一,仅作为测试使用,不提供数据集下载。数据组织参考PaddelX下的PascalVOC数据组织方式。
  • 模型使用超轻量级PPYOLO Tiny,模型大小小于4MB,随便训练了100轮后保留best_model作为测试模型,由于数据集和未调参训练的原因,当前默认识别效果较差

手势分类

  • 数据集使用来自联想小新笔记本摄像头采集的数据,通过手势检测模型提出出手图像,人工分为7类,分别为6种交互手势以及“其他”,共1102张。该数据集数量较少,手型及手势单一,仅作为测试使用,不提供数据集下载。数据组织形式如下:
dataset
	├-- Images
	|     ├-- up
	┆     ┆    └-- xxx.jpg
	|     └-- other
	┆          └-- xxx.jpg
	├-- labels.txt
	├-- train_list.txt
	└-- val_list.txt
  • 模型使用超轻量级MobileNet V3 small,模型大小小于7MB,由于数据量很小,随便训练了20轮后保留best_model作为测试模型,当前识别分类效果较差

模型文件上传使用LFS,下拉时注意需要安装LFS,参考LFS文档。后续将重新采集和标注更加多样的大量数据集,并采用更好的调参方法获得更加准确的识别模型

演示

手势识别

地图交互

*未显示Capture界面

使用

  1. 克隆当前项目到本地,按照requirements.txt安装所依赖的包opencv、paddlex以及pynput。PaddleX对应请安装最新版的PaddlePaddle,由于模型轻量,CPU版本足矣,参考下面代码,细节参考官方网站
python -m pip install paddlepaddle -i https://mirror.baidu.com/pypi/simple
  1. 进入demo.py,将浏览器路径修改为自己使用的浏览器路径:
web_path = '"D:/Twinkstar/Twinkstar Browser/twinkstar.exe"'  # 自己的浏览器路径
  1. 运行demo.py启动程序:
cd GBIM
python demo.py

常见问题及解决

  1. Q: 拉项目时卡住不动

    A:首先确认按照文档安装LFS。如果已经安装那极大可能是网络问题,可以等待一段时间,或先跳过LFS文件,再单独拉取,参考下面git代码:

    // 开启跳过无法clone的LFS文件
    git lfs install --skip-smudge 
    // clone当前项目
    git clone "current project" 
    // 进入当前项目,单独拉取LFS文件
    cd "current project" 
    git lfs pull 
    // 恢复LFS设置
    git lfs install --force
  2. Q:按q或者手势交互无效

    A:请注意当前鼠标点击的焦点,焦点在Capture,则接受q退出;焦点在浏览器,则交互结果将驱动浏览器中的地图进行变换。

  3. Q:安装PaddleX时报错,关于MV C++

    A:若在Windows下安装coco tool时报错,则可能缺少Microsoft Visual C++,可在微软官方下载网页进行下载安装后重启,即可解决。

  4. Q:运行未报错,但没有保存数据到本地

    A:请检查路径是否有中文,cv2.imwrite保存图像时不能有中文路径。

参考

  1. 玩腻了小游戏?Paddle手势识别玩转游戏玩出新花样!
  2. https://github.com/PaddlePaddle/PaddleX

交流与反馈

Email:[email protected]

Symbolic Music Generation with Diffusion Models

Symbolic Music Generation with Diffusion Models Supplementary code release for our work Symbolic Music Generation with Diffusion Models. Installation

Magenta 119 Jan 07, 2023
SporeAgent: Reinforced Scene-level Plausibility for Object Pose Refinement

SporeAgent: Reinforced Scene-level Plausibility for Object Pose Refinement This repository implements the approach described in SporeAgent: Reinforced

Dominik Bauer 5 Jan 02, 2023
High-level library to help with training and evaluating neural networks in PyTorch flexibly and transparently.

TL;DR Ignite is a high-level library to help with training and evaluating neural networks in PyTorch flexibly and transparently. Click on the image to

4.2k Jan 01, 2023
SlotRefine: A Fast Non-Autoregressive Model forJoint Intent Detection and Slot Filling

SlotRefine: A Fast Non-Autoregressive Model for Joint Intent Detection and Slot Filling Reference Main paper to be cited (Di Wu et al., 2020) @article

Moore 34 Nov 03, 2022
The code for paper "Contrastive Spatio-Temporal Pretext Learning for Self-supervised Video Representation" which is accepted by AAAI 2022

Contrastive Spatio Temporal Pretext Learning for Self-supervised Video Representation (AAAI 2022) The code for paper "Contrastive Spatio-Temporal Pret

8 Jun 30, 2022
DCGAN-tensorflow - A tensorflow implementation of Deep Convolutional Generative Adversarial Networks

DCGAN in Tensorflow Tensorflow implementation of Deep Convolutional Generative Adversarial Networks which is a stabilize Generative Adversarial Networ

Taehoon Kim 7.1k Dec 29, 2022
CS_Final_Metal_surface_detection - This is a final project for CoderSchool Machine Learning bootcamp on 29/12/2021.

CS_Final_Metal_surface_detection This is a final project for CoderSchool Machine Learning bootcamp on 29/12/2021. The project is based on the dataset

Cuong Vo 1 Dec 29, 2021
🐾 Semantic segmentation of paws from cute pet images (PyTorch)

🐾 paw-segmentation 🐾 Semantic segmentation of paws from cute pet images 🐾 Semantic segmentation of paws from cute pet images (PyTorch) 🐾 Paw Segme

Zabir Al Nazi Nabil 3 Feb 01, 2022
The implementation of DeBERTa

DeBERTa: Decoding-enhanced BERT with Disentangled Attention This repository is the official implementation of DeBERTa: Decoding-enhanced BERT with Dis

Microsoft 1.2k Jan 06, 2023
PyTorch implementation of CDistNet: Perceiving Multi-Domain Character Distance for Robust Text Recognition

PyTorch implementation of CDistNet: Perceiving Multi-Domain Character Distance for Robust Text Recognition The unofficial code of CDistNet. Now, we ha

25 Jul 20, 2022
Source code and notebooks to reproduce experiments and benchmarks on Bias Faces in the Wild (BFW).

Face Recognition: Too Bias, or Not Too Bias? Robinson, Joseph P., Gennady Livitz, Yann Henon, Can Qin, Yun Fu, and Samson Timoner. "Face recognition:

Joseph P. Robinson 41 Dec 12, 2022
Open-source codebase for EfficientZero, from "Mastering Atari Games with Limited Data" at NeurIPS 2021.

EfficientZero (NeurIPS 2021) Open-source codebase for EfficientZero, from "Mastering Atari Games with Limited Data" at NeurIPS 2021. Thank you for you

Weirui Ye 671 Jan 03, 2023
A benchmark dataset for emulating atmospheric radiative transfer in weather and climate models with machine learning (NeurIPS 2021 Datasets and Benchmarks Track)

ClimART - A Benchmark Dataset for Emulating Atmospheric Radiative Transfer in Weather and Climate Models Official PyTorch Implementation Using deep le

21 Dec 31, 2022
wgan, wgan2(improved, gp), infogan, and dcgan implementation in lasagne, keras, pytorch

Generative Adversarial Notebooks Collection of my Generative Adversarial Network implementations Most codes are for python3, most notebooks works on C

tjwei 1.5k Dec 16, 2022
A commany has recently introduced a new type of bidding, the average bidding, as an alternative to the bid given to the current maximum bidding

Business Problem A commany has recently introduced a new type of bidding, the average bidding, as an alternative to the bid given to the current maxim

Kübra Bilinmiş 1 Jan 15, 2022
SmoothGrad implementation in PyTorch

SmoothGrad implementation in PyTorch PyTorch implementation of SmoothGrad: removing noise by adding noise. Vanilla Gradients SmoothGrad Guided backpro

SSKH 143 Jan 05, 2023
An open-source outlier detection package by Getcontact Data Team

pyfbad The pyfbad library supports anomaly detection projects. An end-to-end anomaly detection application can be written using the source codes of th

Teknasyon Tech 41 Dec 27, 2022
Share a benchmark that can easily apply reinforcement learning in Job-shop-scheduling

Gymjsp Gymjsp is an open source Python library, which uses the OpenAI Gym interface for easily instantiating and interacting with RL environments, and

134 Dec 08, 2022
The aim of the game, as in the original one, is to find a specific image from a group of different images of a person's face

GUESS WHO Main Links: [Github] [App] Related Links: [CLIP] [Celeba] The aim of the game, as in the original one, is to find a specific image from a gr

Arnau - DIMAI 3 Jan 04, 2022
LIMEcraft: Handcrafted superpixel selectionand inspection for Visual eXplanations

LIMEcraft LIMEcraft: Handcrafted superpixel selectionand inspection for Visual eXplanations The LIMEcraft algorithm is an explanatory method based on

MI^2 DataLab 4 Aug 01, 2022