# timeLag **Repository Path**: smart-ex/timeLag ## Basic Information - **Project Name**: timeLag - **Description**: No description available - **Primary Language**: Go - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 1 - **Forks**: 0 - **Created**: 2022-02-18 - **Last Updated**: 2022-02-24 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # 说明 ### 功能说明 用于检索特殊时间的视频切帧目录,对帧图中的时间进行OCR识别,并将其与文件的生成时间进行比较,输出所有帧时间延时(ms),并计算平均延时与标准差。 注:仅适用于linux,windows系统文件日期不支持fulltime输出。 ### 使用方法 ```bash > ./timeLag -p -s -g -f -t ``` 推荐使用nohup进行后台执行 ```bash # 在指定 pathNumber 下均衡扫描 个帧图并默认输出 -report.json 测试报告 # nohup ./timeLag -p -s > console.out & # 举例:扫描 "./resource/1645608532435" 均衡扫描10张帧图并输出到 ./resource/1645608532435-report.json > nohup ./timeLag -p ./resource/1645608532435 -s 10 > console.out & > tail -f console.out # 扫描 -p 目录下从范围内的所有帧图目录并按均衡扫描输出,默认输出 -report.json 测试报告 # nohup ./timeLag -p -s -g -f -t > console.out & # 举例:扫描 "./resource/1645608532435"~"./resource/1645608532484" 每个目录均衡扫描10张帧图并输出到 ./resource/test50-report.json > nohup ./timeLag -p ./resource -s 10 -g test50 -f 1645608532435 -t 1645608532484 > console.out & ``` - 输入: -s 有效采样数,如果为-1则全局采样;否则就平均采样指定数 - 输出: 在本地输出 xxxx-report.json: ### 关于视频信号源 - 方案1:摄像头直接拍摄流媒体主机console ```bash > watch -n 0.1 date +'%F.%X.%N' ``` ![img.png](img.png) - 方案2:使用wecam虚拟摄像头抓拍国家授时中心标准北京时间(http://www.daojishiqi.com/bjtime.asp) ![img_1.png](img_1.png) 注:以上方案都需同时拍摄到日期和时间信息,否则OCR无法正确解析时间格式。