3D Layouts?

Hi All!

I am looking at graph libs for python, and came across graph_tool. I am
trying to see if it is possible to create 3D layouts instead of 2D ones
(which it does really well). Has anybody done that, or does anybody have
some ideas on how we could do that?

Any hints welcome!

   Dirk

attachment.html (403 Bytes)

Hi, Dirk

Visualisation graph in 3D is a quite specific task. May be, this link will help you

https://www.westgrid.ca/files/3Dgraphs-WestGridWebinar-May24.2016.pdf

attachment.html (1.53 KB)

3D layouts are not implemented in graph-tool at all.

Best,
Tiago

Hi Зверев

Hi, Dirk
Visualisation graph in 3D is a quite specific task. May be, this link will
help you

https://www.westgrid.ca/files/3Dgraphs-WestGridWebinar-May24.2016.pdf

Thanks for the link! I used NX for a project a while ago, and we did some
experiments with 3D layouts, that why I was hoping GT would be able to do
something similar. The 3D graphics part is the easy one for us, that' what
we do every day, so I wouldn't use VTK for this (not really what it's
designed for anyway).

Yours

  Dirk

attachment.html (1.29 KB)

Hi Tiago,

3D layouts are not implemented in graph-tool at all.

That's more or less what I expected, thanks for the confirmation.

Is there a fundamental problem with it, or is it just something that has
not been a priority? In general force-directed layouts are pretty agnostic
concerning dimensionality, do you think it would be difficult to add? If I
understand the code correctly (big if :wink: positions are just vector<double>
properties, and the 2D part is more a convention than anything else. This
is obviously only partially true for the QuadTree part in SFDP, which would
have to be an octree for 3D, but it might still work at reduced efficiency.
Are there other limitations that you can think of from the top of your head
that would make 3D layouts infeasible?

If I can find some time over the summer I might play with it...

Thanks!

  Dirk

attachment.html (1.35 KB)

Modifying sfdp_layout() to n-dimensions is indeed straightforward.

The issue is modifying the actual drawing (i.e. graph_draw()) to 3D. We use
cairo in the backend, which is strictly 2D. Implementing 3D would require
the use of something else entirely, like OpenGL.

I have no desire of ever implementing 3D drawing, because I think it is not
really helpful in the majority of cases.

Best,
Tiago

I would say that it can be helpful when you can interactively 'fly through' your data. It is possible to use a 'flying' interface with a game engine type backend to allow interactive exploration of massive datasets. I agree that it is mostly pointless for static rendering.

Peter

attachment.html (2.61 KB)