Hi,
I am trying to use graph tool to extract communities, and I used the minimize_blockmodel_dl function. However, after it has been executed successfully, I wish to know each vertex and information of which community it belongs to, and I can not figure out how. For example, state = graph_tool.community.minimize_blockmodel_dl(g, parallel=True) ##print state.b print state.get_blocks().get_array()
it give me an array of all the vertex in zero. Could any one point me to the right directions. Thank you very much.
Best Regards Junjun
-- View this message in context: http://main-discussion-list-for-the-graph-tool-project.982480.n3.nabble.com/... Sent from the Main discussion list for the graph-tool project mailing list archive at Nabble.com.
On 19.03.2015 20:56, yinjunjun wrote:
Hi,
I am trying to use graph tool to extract communities, and I used the minimize_blockmodel_dl function. However, after it has been executed successfully, I wish to know each vertex and information of which community it belongs to, and I can not figure out how. For example, state = graph_tool.community.minimize_blockmodel_dl(g, parallel=True) ##print state.b print state.get_blocks().get_array()
it give me an array of all the vertex in zero. Could any one point me to the right directions. Thank you very much.
What you tried to do is correct. If the values of state.b are all zero, it means that the best fit is a block model with only one group, i.e. your graph looks like a random graph.
If you want to force a minimum number of groups (and risk overfitting), you can specify the "min_B" option.
Best, Tiago
Dear Tiago,
Many thanks for the information. Yes, you are right, after intentionally add extra vertices, which should belong to other "communities", the function works and provide difference community numbers in the output.
I have another question: Does graph tool provide support for community detection on directed weighted graphs? I can see "eweight" can be provided for minimize_blockmodel_dl, but it is only for "multigraph". Would you please help confirm on this. Thanks again.
Best Regards Junjun
-- View this message in context: http://main-discussion-list-for-the-graph-tool-project.982480.n3.nabble.com/... Sent from the Main discussion list for the graph-tool project mailing list archive at Nabble.com.
On 20.03.2015 21:35, yinjunjun wrote:
Dear Tiago,
Many thanks for the information. Yes, you are right, after intentionally add extra vertices, which should belong to other "communities", the function works and provide difference community numbers in the output.
I have another question: Does graph tool provide support for community detection on directed weighted graphs? I can see "eweight" can be provided for minimize_blockmodel_dl, but it is only for "multigraph". Would you please help confirm on this. Thanks again.
Real-valued weights are not supported, but it is currently being implemented and will be available soon.
Best, Tiago
Hi
I'm looking for a way to find communities in directed and (real-valued) weighted graphs and I just found this message in the mailing list. Is there any update on this?
Regards,
I have another question: Does graph tool provide support for community detection on directed weighted graphs? I can see "eweight" can be provided for minimize_blockmodel_dl, but it is only for "multigraph". Would you please help confirm on this. Thanks again.
Real-valued weights are not supported, but it is currently being implemented and will be available soon.
Best, Tiago
On 04.07.2016 17:33, Sancho wrote:
I'm looking for a way to find communities in directed and (real-valued) weighted graphs and I just found this message in the mailing list. Is there any update on this?
Support for real-valued weights is not yet done, but will be included very soon.
Best, Tiago