Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support a mask2k file to prioritize sections VERSION 2 #10

Merged
merged 9 commits into from Apr 3, 2022

Conversation

Alch-Emi
Copy link
Contributor

@Alch-Emi Alch-Emi commented Apr 3, 2022

This is a minor rewrite of @octylFractal's #3.

The most significant change is to the algorithm which decides which pixel to draw from a list of buckets. Where octyl's method groups pixels into buckets, selects a bucket using a weighted random, and then selects a pixel from that bucket at a uniform random, the revised algorithm creates a virtual pool of 150 pixels pulled from the highest priority buckets, and then selects evenly from that pool.

This strategy further reduces the chance of a collision and also provides a single number that can be used to balance strength of prioritization against collision resistance.

This also patches most of the nits that were brought up in the original pull request.

I've done my best to review the code on my own, and am running + observing it in testing, but code review is still strongly requested, if possible.

Thanks for any feedback <3

@bb010g
Copy link
Contributor

bb010g commented Apr 3, 2022

Please rebase this on top of d/main.

@bb010g bb010g merged commit 56b20a7 into r-ainbowroad:d/main Apr 3, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants