OneKey 是一个面向 Hackathon / 创客活动场景的智能视频分析系统,支持单摄像头、OBS 虚拟摄像头、多摄像头采集,集成人物追踪、人脸识别、实时 ASR、关键时刻管理、AI 分析与网页可视化。
chmod +x install_ubuntu.sh
./install_ubuntu.sh
logout
重新登录后:
python3 integrated_system.py --camera auto --camera-usb 05a3:9230
./start.sh # 标准启动(交互选择模式)
./start_live.sh # 直播模式(后台+直播页)
./start_multicam.sh # 多摄像头模式(默认 0,2,4,6)
./start_auto_recording.sh # 自动启动 ASR
./start_with_full_recording.sh # 启动并控制 OBS 全程录制
Onekey/
├── integrated_system.py
├── start_multicam_system.py
├── multi_camera_capture.py
├── multi_camera_recording.py
├── key_moments_manager.py
├── key_moments_viewer.py
├── realtime_asr.py
├── audio_manager.py
├── microphone_recorder.py
├── ai_live_commentary.py
├── camera_utils.py
├── esp32_server.py
├── archive_data.py
├── LAUNCH_GUI.py
├── web_viewer.py
├── obs_auto_record.py
├── start.sh / start_live.sh / start_multicam.sh
├── start_auto_recording.sh / start_with_full_recording.sh / stop_with_full_recording.sh
├── install_ubuntu.sh
├── .env.local.example
├── requirements.txt
├── FireRedASR/
├── MagicLLM/
├── web/
│ ├── integrated.html
│ ├── integrated_v2.html
│ └── 启动中心.html
├── integrated final.html
├── integrated_final_live.html
└── integrated_data/ (运行后自动生成)
0,2,4,6)python3 integrated_system.py --obs
python3 integrated_system.py --camera auto --camera-usb 05a3:9230
python3 integrated_system.py --video file.mp4
python3 start_multicam_system.py --cameras 0,2,4,6 --fps 30 --resolution 1280x720
--ai # 启用 AI 分析
--no-face # 关闭人脸识别
复制模板并填写:
cp .env.local.example .env.local
关键变量:
LLM_PROVIDER=qwen|claudeDASHSCOPE_API_KEYANTHROPIC_API_KEY / CLAUDE_API_KEYLLM_MODEL(如 qwen-max)VISION_MODEL(如 qwen-vl-max-latest)VISION_MODEL_FAST(如 qwen-vl-plus)ASR_PROVIDER=qwen|fireredasrCAMERA_USB_VIDPID=05a3:9230AUDIO_BACKEND=pulse|alsaAUDIO_INPUT=defaultWEB_STREAM_FPS=1~30ARC 摄像头通常每个物理设备会产生两个节点:偶数索引用于视频采集,奇数索引多为元数据节点。
建议使用:0,2,4,6。
为保证色彩与帧率,使用 MJPEG 并优先设置 FOURCC:
cap.set(cv2.CAP_PROP_FOURCC, cv2.VideoWriter_fourcc('M','J','P','G'))
cap.set(cv2.CAP_PROP_FRAME_WIDTH, 1280)
cap.set(cv2.CAP_PROP_FRAME_HEIGHT, 720)
cap.set(cv2.CAP_PROP_FPS, 30)
sudo modprobe v4l2loopback devices=1 video_nr=8 card_label="OBS Virtual Camera" exclusive_caps=1
4455obs_auto_record.py / obs_recording_control.sh 控制录制状态推荐配置:
0,2,4,61280x72030MJPEG启动:
./start_multicam.sh
python3 esp32_server.py
5000./rgb.sh
关键时刻来源:
每个关键时刻可包含:
.mp4).jpg).json,含描述/转写/分析)查看器:
http://localhost:8082http://localhost:8086运行后常见目录:
integrated_data/key_moments/integrated_data/audio/integrated_data/transcripts/integrated_data/face_database/integrated_data/snapshots/integrated_data/logs/archives/归档:
python3 archive_data.py
python3 archive_data.py --dry-run
ls -la /dev/video*
v4l2-ctl --list-devices
确认用户已加入 video 组并重新登录。
lsmod | grep v4l2loopback
确认内核模块已加载并在 OBS 内启动虚拟摄像头。
检查 8082 / 8086 / 5000 / 4455 是否被占用,调整启动参数或结束冲突进程。
1280x720 @ 30fpsWEB_STREAM_FPS--no-face)./auto_restart.sh 2
20 commits
7 commits
HTML
48.4%
Python
45.0%
Shell
4.6%
OneKey 是一个面向 Hackathon / 创客活动场景的智能视频分析系统,支持单摄像头、OBS 虚拟摄像头、多摄像头采集,集成人物追踪、人脸识别、实时 ASR、关键时刻管理、AI 分析与网页可视化。
chmod +x install_ubuntu.sh
./install_ubuntu.sh
logout
重新登录后:
python3 integrated_system.py --camera auto --camera-usb 05a3:9230
./start.sh # 标准启动(交互选择模式)
./start_live.sh # 直播模式(后台+直播页)
./start_multicam.sh # 多摄像头模式(默认 0,2,4,6)
./start_auto_recording.sh # 自动启动 ASR
./start_with_full_recording.sh # 启动并控制 OBS 全程录制
Onekey/
├── integrated_system.py
├── start_multicam_system.py
├── multi_camera_capture.py
├── multi_camera_recording.py
├── key_moments_manager.py
├── key_moments_viewer.py
├── realtime_asr.py
├── audio_manager.py
├── microphone_recorder.py
├── ai_live_commentary.py
├── camera_utils.py
├── esp32_server.py
├── archive_data.py
├── LAUNCH_GUI.py
├── web_viewer.py
├── obs_auto_record.py
├── start.sh / start_live.sh / start_multicam.sh
├── start_auto_recording.sh / start_with_full_recording.sh / stop_with_full_recording.sh
├── install_ubuntu.sh
├── .env.local.example
├── requirements.txt
├── FireRedASR/
├── MagicLLM/
├── web/
│ ├── integrated.html
│ ├── integrated_v2.html
│ └── 启动中心.html
├── integrated final.html
├── integrated_final_live.html
└── integrated_data/ (运行后自动生成)
0,2,4,6)python3 integrated_system.py --obs
python3 integrated_system.py --camera auto --camera-usb 05a3:9230
python3 integrated_system.py --video file.mp4
python3 start_multicam_system.py --cameras 0,2,4,6 --fps 30 --resolution 1280x720
--ai # 启用 AI 分析
--no-face # 关闭人脸识别
复制模板并填写:
cp .env.local.example .env.local
关键变量:
LLM_PROVIDER=qwen|claudeDASHSCOPE_API_KEYANTHROPIC_API_KEY / CLAUDE_API_KEYLLM_MODEL(如 qwen-max)VISION_MODEL(如 qwen-vl-max-latest)VISION_MODEL_FAST(如 qwen-vl-plus)ASR_PROVIDER=qwen|fireredasrCAMERA_USB_VIDPID=05a3:9230AUDIO_BACKEND=pulse|alsaAUDIO_INPUT=defaultWEB_STREAM_FPS=1~30ARC 摄像头通常每个物理设备会产生两个节点:偶数索引用于视频采集,奇数索引多为元数据节点。
建议使用:0,2,4,6。
为保证色彩与帧率,使用 MJPEG 并优先设置 FOURCC:
cap.set(cv2.CAP_PROP_FOURCC, cv2.VideoWriter_fourcc('M','J','P','G'))
cap.set(cv2.CAP_PROP_FRAME_WIDTH, 1280)
cap.set(cv2.CAP_PROP_FRAME_HEIGHT, 720)
cap.set(cv2.CAP_PROP_FPS, 30)
sudo modprobe v4l2loopback devices=1 video_nr=8 card_label="OBS Virtual Camera" exclusive_caps=1
4455obs_auto_record.py / obs_recording_control.sh 控制录制状态推荐配置:
0,2,4,61280x72030MJPEG启动:
./start_multicam.sh
python3 esp32_server.py
5000./rgb.sh
关键时刻来源:
每个关键时刻可包含:
.mp4).jpg).json,含描述/转写/分析)查看器:
http://localhost:8082http://localhost:8086运行后常见目录:
integrated_data/key_moments/integrated_data/audio/integrated_data/transcripts/integrated_data/face_database/integrated_data/snapshots/integrated_data/logs/archives/归档:
python3 archive_data.py
python3 archive_data.py --dry-run
ls -la /dev/video*
v4l2-ctl --list-devices
确认用户已加入 video 组并重新登录。
lsmod | grep v4l2loopback
确认内核模块已加载并在 OBS 内启动虚拟摄像头。
检查 8082 / 8086 / 5000 / 4455 是否被占用,调整启动参数或结束冲突进程。
1280x720 @ 30fpsWEB_STREAM_FPS--no-face)./auto_restart.sh 2
20 commits
7 commits
HTML
48.4%
Python
45.0%
Shell
4.6%