-
Notifications
You must be signed in to change notification settings - Fork 17
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
Allow references with up to 2**31 contigs #455
base: main
Are you sure you want to change the base?
Conversation
This changes the RefRandstrobe struct in the following way. Previous layout: - 40 bits base hash - 24 bits auxiliary hash - 32 bits position - 23 bits reference/contig index - 8 bits strobe2 offset - 1 bit first_strobe_is_main flag We take 8 bits away from the auxiliary hash and use those bits for the reference index. New layout: - 40 bits base hash - 16 bits auxiliary hash - 8 bits strobe2 offset - 32 bits position - 31 bits reference/contig index - 1 bit first_strobe_is_main flag Closes #421
great! Let's have a meeting at some point. I want to understand and learn from you some of the design choices in this commit. Like changing hash to a method. @luispedro had a local version where he moved the offset bits into positions integer. Just tagging him here so that he can see we are now actively working on it with a different layout related to multi-context seeds. An idea we had for a while that we make public soon. |
Happy to talk about this further. To elaborate already now: Making all attributes private improves encapsulation. By forcing any access to the hash value to go through the Also, as a consequence of making all attributes private and not exposing any methods that allow changing them, |
Layout now: - 38 bits base hash - 17 bits auxiliary hash - 1 bit first_strobe_is_main flag - 8 bits strobe2 offset - 32 bits position - 32 bits reference/contig index
Note, this is not quite the layout suggested in #421 (comment). I implemented it this way before that comment, but will adjust it.
This changes the RefRandstrobe struct in the following way.
Previous layout:
We take 8 bits away from the auxiliary hash and use those bits for the reference
index. New layout:
Closes #421