-
Notifications
You must be signed in to change notification settings - Fork 0
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
Add pinnedness planning #300
Conversation
a805792
to
2ec72f7
Compare
strider/query_planner.py
Outdated
def get_pinnedness(qgraph, qnode_id): | ||
"""Get pinnedness of each node.""" | ||
adjacency_mat = get_adjacency_matrix(qgraph) | ||
return -_get_pinnedness_recursively( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is there a minus sign here? I think it's easy to miss and should be more obvious.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I modified some naming/documentation to try and make this more readable.
strider/query_planner.py
Outdated
num_ids = ids | ||
A[qnode_id][qnode_id] = num_ids | ||
for qedge in qgraph["edges"].values(): | ||
A[qedge["subject"]][qedge["object"]] = True |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What about self-edges?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch... this will break somewhat if self edges are present, and also will not work as we perhaps hope if there are multi-edges. I think it can be made to work nicely, it will just take a little more thought.
Also clarify that we're computing log(n)
d087628
to
4590182
Compare
No description provided.