hitontology / gui

Erneuerung der Benutzungsoberflächen von HITO
https://hitontology.github.io/gui/
MIT License
0 stars 0 forks source link

generate all paths between source and targets #15

Closed KonradHoeffner closed 6 months ago

KonradHoeffner commented 7 months ago

Not possible with default Cytoscape investigate https://github.com/daniel-dx/cytoscape-all-paths. Probably less relevant: https://stackoverflow.com/questions/56365530/how-would-i-find-all-paths-between-two-nodes-using-cytoscape-js.

KonradHoeffner commented 6 months ago

Testing https://github.com/daniel-dx/cytoscape-all-paths but it seems to be buggy. It only finds 27 paths in the whole graph. There is an extension that adds "directed" and "target" parameters but the target parameter seems to be ignored, see https://github.com/daniel-dx/cytoscape-all-paths/pull/2.

KonradHoeffner commented 6 months ago

It seems like cytoscape-all-paths is not what we need because it only works for directed graphs (which we have in theory but we traverse edges backwards in the SPARQL query so we treat it as a non-directed one) and the pull request seems to keep the basic premise of operating on root notes which I think doesn't make sense for our case.

KonradHoeffner commented 6 months ago

Next approach: implement the path search for ourselves, for example using a modified breadth first search. This should be relatively simple.

KonradHoeffner commented 6 months ago

Implemented in 46c708420ccd9dddf9cfbc8a28946a4559a3ddd6.