日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

DataSketches HLL Sketch module

發(fā)布時間:2023/12/14 编程问答 36 豆豆
生活随笔 收集整理的這篇文章主要介紹了 DataSketches HLL Sketch module 小編覺得挺不錯的,現(xiàn)在分享給大家,幫大家做個參考.

上圖是官網(wǎng)的介紹,翻譯后的意思是此模塊提供Apache Druid聚合器為不同的計數(shù)基于HLL sketch來自datasketches數(shù)據(jù)庫。攝入的時候這個聚合器創(chuàng)建HLL sketch對象存儲在Druid的segments中。在查詢的時候sketches被讀取并且被合并到一起。最后默認情況下,你可以收到提交給sketch的不同值的估計值。此外,還可以使用post聚合器在同一行中生成sketch列的聯(lián)合。可以對任何標識符的列使用HLL sketch聚合器。它將返回列的估計基數(shù)。

要是想要使用此聚合器,在配置文件中必須要包含:

druid.extensions.loadList=["druid-datasketches"]

聚合器示例:

{"type" : "HLLSketchBuild","name" : <output name>,"fieldName" : <metric name>,"lgK" : <size and accuracy parameter>,"tgtHllType" : <target HLL type>,"round": <false | true>} {"type" : "HLLSketchMerge","name" : <output name>,"fieldName" : <metric name>,"lgK" : <size and accuracy parameter>,"tgtHllType" : <target HLL type>,"round": <false | true>}

參數(shù)的類型及對應(yīng)的含義:

post的聚合器:

估計:返回不重復(fù)計數(shù)估計值的兩倍

{"type" : "HLLSketchEstimate","name": <output name>,"field" : <post aggregator that returns an HLL Sketch>,"round" : <if true, round the estimate. Default is false> }

有界的估計:返回HLL sketch中不同的估算數(shù)和誤差范圍結(jié)果將是一個包含三個雙精度值的數(shù)組:估計值、下界和上界。邊界以給定的標準差數(shù)提供(可選默認是1)。該值必須是1、2或3的整數(shù)值,對應(yīng)約68.3%、95.4%和99.7%的置信區(qū)間。

{"type" : "HLLSketchEstimateWithBounds","name": <output name>,"field" : <post aggregator that returns an HLL Sketch>,"numStdDev" : <number of standard deviations: 1 (default), 2 or 3> }

聯(lián)合:

{"type" : "HLLSketchUnion","name": <output name>,"fields" : <array of post aggregators that return HLL sketches>,"lgK": <log2 of K for the target sketch>,"tgtHllType" : <target HLL type> }

sketch to string:

{"type" : "HLLSketchToString","name": <output name>,"field" : <post aggregator that returns an HLL Sketch> }

總結(jié)

以上是生活随笔為你收集整理的DataSketches HLL Sketch module的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網(wǎng)站內(nèi)容還不錯,歡迎將生活随笔推薦給好友。