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

Basic optimizations for UndirectedSparseGraph #130

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

melon3r
Copy link

@melon3r melon3r commented Apr 8, 2020

Description

Optimized item removal from UndirectedSparseGraph by only trying to remove the given item from its neighbors' adjacency lists, instead of all vertices'.

Optimized the Contains function of the DLinkedList structure by avoiding exceptions entirely, as they are costly and not really meaningful in this case (not finding an item in a list is normal, it's not an exception).

Checklist

  • An issue was first created before opening this pull request
  • The new code follows the contribution guidelines
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests to ensure that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes

@aalhour
Copy link
Owner

aalhour commented May 27, 2020

Hi @melon3r, pull requests should follow from existing issues, can you please create one first describing what kind of problem you're solving?

@melon3r
Copy link
Author

melon3r commented Jul 16, 2020

Hi @aalhour, I just created #146

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.

2 participants