Telemetry介紹
上一篇文章我們介紹了Intel Developer Cloud Telemetry的概念和功能,通過該功能的數據分析,可以更好地優化產品方案。有關Telemetry 的工作原理和集成方法,我將在這篇文章里細細解釋。耐心看下去,相信您肯定可以在自己應用中開啟這個功能。Telemetry收集流程

Telemetry集成
這次依然選擇object-detection-python實例來介紹集成方法,應用程序的 python 代碼中調用了applicationMetricWriter模塊向Telemetry傳遞數據指標如,幀率、推理時間、模型名稱、推理硬件信息,下面通過具體代碼來展示詳細信息。-
Step1. 登錄JupyterLab
-
Step2. 程序源碼分析

#!/usr/bin/env python
import applicationMetricWriter
...
def main():
...
try:
infer_time_start = time.time()
with open(processed_vid, "rb") as data:
while frame_count < video_len:
byte = data.read(CHUNKSIZE)
if not byte == b"":
deserialized_bytes = np.frombuffer(byte, dtype=np.uint8)
in_frame = np.reshape(deserialized_bytes, newshape=(n, c, h, w))
inf_time = time.time()
exec_net.start_async(request_id=current_inference,inputs={input_blob: in_frame})
# Retrieve the output of an earlier inference request
if previous_inference >= 0:
status = infer_requests[previous_inference].wait()
if status is not 0:
raise Exception("Infer request not completed successfully")
det_time = time.time() - inf_time
applicationMetricWriter.send_inference_time(det_time*1000)
res = output_postprocessor(exec_net.requests[previous_inference].output_blobs)
processBoxes(frame_count, res, labels_map, args.prob_threshold, width, height, result_file)
frame_count += 1
…
applicationMetricWriter.send_application_metrics(model_xml, args.device)
-
Step3.Telemetry數據訪問

https://devcloud.intel.com/edge/metrics/d/+ID
比如:https://devcloud.intel.com/edge/metrics/d/573403訪問該路徑即可獲取Telemetry 的數據了。
總 結
看到這相信您一定理解了Intel Developer Cloud Telemetry 的集成方法了,它并沒有我們想象的那么復雜。我這里總結出來,只是為了方便剛開始接觸這塊的您更快上手,不用花費太多精力就可以更快的把事情搞定。如果您在使用過程中有碰到問題,期待一起交流。這篇就到這吧。審核編輯 :李倩
-
AI
+關注
關注
87文章
32494瀏覽量
271706 -
應用程序
+關注
關注
38文章
3305瀏覽量
58213 -
數據分析
+關注
關注
2文章
1464瀏覽量
34357
原文標題:Intel Developer Cloud Telemetry數據分析(二)
文章出處:【微信號:SDNLAB,微信公眾號:SDNLAB】歡迎添加關注!文章轉載請注明出處。
發布評論請先 登錄
相關推薦
Intel PXA27x Processor Family Developer's Manual
數據分析需要的技能
怎么有效學習Python數據分析?
BI分享秀——高度開放的數據分析經驗共享
BI數據分析軟件使用指南
電商數據分析攻略,讓你輕松搞定數據分析!
IBM Cloud Pak for Data平臺讓數據分析變得更簡單
Intel? Developer Cloud Telemetry數據分析
Intel Developer Cloud Telemetry數據分析(一)

Intel Developer Cloud之Telemetry數據分析

評論