3 ms·
As an aside, I worked on path tracing[1] long ago, and there was various schemes to avoid the "clumpyness" you'd get by using purely random numbers. This inclu
by magicalhippo 3y ago
As an aside, I worked on path tracing[1] long ago, and there was various schemes to avoid the "clumpyness" you'd get by using purely random numbers.
This included regular stratified sampling[2] as well as using quasi-random low-discrepancy sequences[3] like the Sobol sequence[4], which would "space out" the random samples.
Probably not terribly relevant for load balancing, but I did find the quasi-random stuff fascinating. How to make something "random enough" without being "too random".
edit: Though now I got a shower thought moment, could stratified sampling be used as a variant of the "two choices", even if each load-balancer worked independently? That is, each load-balancer stratifies the resources, and keeps a separate index to the current bin. Then for each request pick a random/suitable resource from the current bin and increment the bin index, wrapping when needed. Hmm...
[1]: https://en.wikipedia.org/wiki/Path_tracing https://en.wikipedia.org/wiki/Path_tracing
[2]: https://en.wikipedia.org/wiki/Stratified_sampling https://en.wikipedia.org/wiki/Stratified_sampling
[3]: https://en.wikipedia.org/wiki/Low-discrepancy_sequence https://en.wikipedia.org/wiki/Low-discrepancy_sequence
[4]: https://en.wikipedia.org/wiki/Sobol_sequence https://en.wikipedia.org/wiki/Sobol_sequence
- vkoskiv 3y agoThe Halton sequence[1] is also a very nicely even distribution, and really quick to compute! [1]: https://en.wikipedia.org/wiki/Halton_sequence https://en.wikipedia.org/wiki/Halton_sequence
- magicalhippo 3y agoThanks, I knew there was one important I was missing I just couldn't recall.
- Karellen 3y ago> there was various schemes to avoid the "clumpyness" you'd get by using purely random numbers. ^^ This is worth highlighting. "Randomness is clumpy" -- Attributed to various authors https://en.wikipedia.org/wiki/Clustering_illusion https://en.wikipedia.org/wiki/Clustering_illusion