Skip to content
This repository has been archived by the owner on Apr 22, 2020. It is now read-only.

direction in louvain community detection #935

Open
xiexiexxs opened this issue Mar 13, 2020 · 2 comments
Open

direction in louvain community detection #935

xiexiexxs opened this issue Mar 13, 2020 · 2 comments

Comments

@xiexiexxs
Copy link

when i tried louvain in neo4j-graph-algorithms-3.5.14.0-standalone. i met the error.

"Neo.ClientError.Procedure.ProcedureCallFailed: Failed to invoke procedure `algo.beta.louvain.stream`: Caused by: java.lang.IllegalArgumentException: Incompatible directions between loaded graph and requested compute direction. Load direction: 'OUTGOING' Compute direction: 'BOTH' "

codes are here

MERGE (nAlice:User {id:'Alice'}) SET nAlice.community = 0
MERGE (nBridget:User {id:'Bridget'}) SET nBridget.community = 0
MERGE (nCharles:User {id:'Charles'}) SET nCharles.community = 1
MERGE (nDoug:User {id:'Doug'}) SET nDoug.community = 1
MERGE (nMark:User {id:'Mark'}) SET nMark.community = 1
MERGE (nMichael:User {id:'Michael'}) SET nMichael.community = 0
MERGE (nKarin:User {id:'Karin'}) SET nKarin.community = 1
MERGE (nAmy:User {id:'Amy'})
MERGE (nAlice)-[:FRIEND]->(nBridget)
MERGE (nAlice)-[:FRIEND]->(nCharles)
MERGE (nMark)-[:FRIEND]->(nDoug)
MERGE (nBridget)-[:FRIEND]->(nMichael)
MERGE (nCharles)-[:FRIEND]->(nMark)
MERGE (nAlice)-[:FRIEND]->(nMichael)
MERGE (nCharles)-[:FRIEND]->(nDoug)
MERGE (nMark)-[:FRIEND]->(nKarin)
MERGE (nKarin)-[:FRIEND]->(nAmy)
MERGE (nAmy)-[:FRIEND]->(nDoug)

CALL algo.louvain(
'MATCH (p:User) RETURN id(p) as id',
'MATCH (p1:User)-[f:FRIEND]-(p2:User)
RETURN id(p1) as source, id(p2) as target, f.weight as weight',
{graph:'cypher',write:true})
@mading0817
Copy link

I have that problem too

@tomasonjo
Copy link
Collaborator

Graph algorithms will not be maintained anymore AFAIK, so can you please try the new Graph data science plugin at:

https://github.com/neo4j/graph-data-science

You shouldn't have these problems with it.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants