Commit graph

6 commits

Author SHA1 Message Date
fad35bbd3b Specify go.mod version 2020-09-11 18:30:18 +03:00
Alex Vanin
aa230933d1
Move normalization routine out of hrw library (#6)
HRW library supports weighted sorting. Weights must be normalized
before applying. Since there could be different types of normalization
for multiple criteria, there is no point to perform simple
normalization in this library. Pass a slice of normalized weights
to the `SortByWeight` functions.

This commit proposes to:
- remove normalization routine from `SortByWeight` function;
- add `ValidateWeights` function to check if weights are normalized;
- rename `weight` -> `distance` to avoid naming confusion between
  hash distance and actual weights;
- use testify lib in the tests;
2019-07-05 09:49:24 +03:00
Evgeniy Kulikov
7462e26df6
Update to release version after [this issue](https://github.com/spaolacci/murmur3/issues/24) (#3) 2019-03-18 14:49:34 +03:00
Evgeniy Kulikov
29dac15c96
Move repo to NSPCC (#1) 2019-02-01 14:30:34 +03:00
Evgeniy Kulikov
e5d4b47881
Work around Hashing and tests (#2)
* Work around Hashing and tests

* fixes

* add TravisCI

* fix lint

* so slow

* add badges

* work on README

* Improved tests and get rid of fnv (#3)
2019-01-31 12:54:02 +03:00
Evgeniy Kulikov
01e85efd7e
Base HRW implementation in golang 2019-01-30 01:58:30 +03:00