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

perf(python): Adding multiple links should be handled by c++ #113

Closed
wants to merge 2 commits into from

Conversation

antoneri
Copy link
Member

@antoneri antoneri commented Mar 3, 2020

Fixes #108

@antoneri antoneri closed this Mar 3, 2020
@antoneri antoneri changed the title perf(python): Adding mulitple links should be handled by c++ perf(python): Adding multiple links should be handled by c++ Mar 3, 2020
@antoneri antoneri deleted the perf/python branch June 11, 2021 05:14
@flazerain
Copy link

Can I addLink in multiple threads ?

@antoneri
Copy link
Member Author

antoneri commented Dec 3, 2021

No, the Python interface is just a thin wrapper around the C++ core. If you would use something like multiprocessing module, the Infomap instance would be copied to each thread.

If you need maximum performance, try writing your edge list(s) to files and either using read_file (possibly with accumulate=True) or the C++ binary.

What is the problem that you are trying to solve?

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.

A faster way to add edges and build the network in Python API?
2 participants