Skip to content

Improve duplicate handling in sterics.occupied #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

Open
tooooby opened this issue Mar 3, 2022 · 0 comments
Open

Improve duplicate handling in sterics.occupied #17

tooooby opened this issue Mar 3, 2022 · 0 comments
Assignees
Labels
optimization Issues relating to optimizing existing functions of DBSTEP

Comments

@tooooby
Copy link
Collaborator

tooooby commented Mar 3, 2022

Currently, we convert the list of indices to a set and then back to a list to remove duplicates. This does not scale very well compared to a simple alternative: make a bit mask (each bit marking whether a point is occupied or not) and, as you are scanning out the sphere's, set the needed indices to true. This means there will be no duplicates as each value is restricted to true or false. The overall grid can then be indexed using this mask to make the occupied grid.

@tooooby tooooby self-assigned this Mar 3, 2022
@tooooby tooooby added the optimization Issues relating to optimizing existing functions of DBSTEP label Apr 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
optimization Issues relating to optimizing existing functions of DBSTEP
Projects
None yet
Development

No branches or pull requests

1 participant