Beispiel #1
0
        private int[] HashBottomSupernodes(IDataItem <T> dataItem, int B)
        {
            var indexArray = new int[B];
            var randomHash = new Random(dataItem.GetHashCode());

            for (int i = 0; i < B; i++)
            {
                // TODO: What about duplicate bottom supernodes?
                var hashIndex = randomHash.Next(0, netWidth);
                indexArray[i] = (netHeight - 1) * netWidth + hashIndex;
            }
            return(indexArray);
        }