stat/card: new package for cardinality estimation
MODIFY
.travis/script.d/check-generate.sh
.travis/script.d/check-generate.sh
@@ -5,6 +5,7 @@ go generate gonum.org/v1/gonum/blas/gonum
go generate gonum.org/v1/gonum/unit
go generate gonum.org/v1/gonum/unit/constant
go generate gonum.org/v1/gonum/graph/formats/dot
+go generate gonum.org/v1/gonum/stat/card
if [ -n "$(git diff)" ]; then
git diff

ADD
stat/card/generate_64bit.sh
+#!/bin/bash
+
+echo -e '// Code generated by "go generate gonum.org/v1/gonum/stat/card"; DO NOT EDIT.\n' > hll64.go
+< hll32.go cat \
+| gofmt -r 'HyperLogLog32 -> HyperLogLog64' \
+| gofmt -r 'Hash32 -> Hash64' \
+| gofmt -r 'Sum32 -> Sum64' \
+| gofmt -r 'rho32 -> rho64' \
+| gofmt -r 'uint32 -> uint64' \
+| gofmt -r 'bits.LeadingZeros32 -> bits.LeadingZeros64' \
+\
+| sed \
+ -e 's/\[4, 32\]/[4, 64]/' \
+ -e 's/rho32/rho64/' \
+ -e 's/HyperLogLog32/HyperLogLog64/g' \
+ -e 's/Hash32/Hash64/' \
+ -e 's/w32/w64/g' \
+>> hll64.go
\ No newline at end of file

stat/card: new package for cardinality estimation