Confusion with tool selection: VTK vs ParaView for Web-based volume rendering of large data sets

Hello,

I want to develop a Web-based application which performs interactive/real-time volume rendering on a remote server and displays the result on a Web browser. After some reading it appears that VTK, Paraview, and related technologies are the way to go. However I am really overwhelmed with all the information and the reading I need to do in order to even begin to understand how all these technologies work. Furthermore, I am having a hard time finding documentation for the components my application needs. I have already started creating some prototypes using different technologies, but I have problems with all of them. So, I was wondering if someone can provide advice as to which are the most appropriate technologies for my use-case. After knowing which are the right tools to use, then I will only focus on them for the implementation.

Here is a description of what I need to do: I want to perform interactive volume rendering of a series of 3D data sets (data cubes). The size of these data cubes is between 5MB and 4GB, with the majority of them being around 100MB. The number of the data cubes is about 10,000. The data cubes are already located on the server. I want the user to be able to select the name of a data cube and almost immediately see a volumetric visualisation which can move around, manipulate, and even change transfer functions etc. Furthermore, I want multiple users to be able to render a different cube at the same time. In other words, this is a multi-user application.

Given the size and number of data cubes, I can’t just fetch the cubes on the client and render them using vtk.js. I guess for the small cubes I could use some kind of LOD scheme, but for the big ones, a LOD approach won’t be good enough (especially for slow connections). Because of this, I think that server-side rendering is the way to go, and maybe in the future, for the small cubes, also implement client-side rendering using some kind of LOD scheme.

The problem now is that I do not know which technology I should use to do this. I guess the two options are the ParaView and VTK clients/servers. I have found some examples on the internet demonstrating remote rendering, but the more I explore them, the more questions they raise. For example this: https://kitware.github.io/paraviewweb/examples/RemoteRenderer.html. This example provides two different servers, a ParaView-based and a VTKWeb-based. This example also uses the ParaViewWeb JavaScript client.

Question 1: What is the advantage of using the ParaView instead of VTK as a server?

Question 2: My first thought was to use VTK as a server because I am more familiar with it. Given the requirements of my application, which is the best technology and why?

Question 3: Are there any implications when using ParaViewWeb as a client and VTK as a server?

There are also other examples of remote rendering which use VTK.js on the client side:

Question 4: What is the advantage of using the ParaViewWeb instead of vtk.js as a client?

Question 5: Can a vtk.js client work with a ParaView server? If yes, are there some implications for not using the ParaViewWeb client?

There is also a multi-user setup I will need to do in order to have multiple users running visualisations of different data cubes. Fortunately, there is a guide for this here: https://kitware.github.io/paraviewweb/docs/multi_user_setup.html

Question 6: Will the above setup work for VTK.js + VTKWeb server as well?

Just to summarise, here are the requirements of the application I want to build:

  • Perform “real-time” interactive volume rendering of three-dimensional images (cubes) on the Web browser.
  • The data set size can be between 5MB to 4GB, with median being 100MB. The number of data sets will be around 10,000.
  • Multiple users (i.e., clients (i.e., web browsers)) should be able to use this application at the same time to visualise different data sets.
  • Usually, each user will want to visualise one cube at a time, but the visualisation of multiple cubes-per-user is also welcome.
  • After the user selects a data set, the visualisation should appear as soon as possible.
  • The application will have a series of widgets to control the rendering.

Any suggestions on the right choice of technologies (ParaView(Web) vs VTK(Web)), given the above requirements, is more than welcome. In case you are curious, I am planning to use this tool to visualise astronomical observations of large-scale galaxy surveys.

Thank you very much for your time.

PS: For the admins: Unfortunately the VTK and ParaView forums are separate. Do you think I should post a copy of this post on the ParaView forum as well?

3 Likes

Hi Bekos,
actually these were great questions.
We are struggling with the same ones.
Did you find a solution?

Thanks and regards,
Ennio

Sorry that I missed your post @bekos. I was most likely in vacation at that time and did not noticed when I got back. It is probably too late but since your questions are relevant, I’m going to reply below.

Question 1: What is the advantage of using the ParaView instead of VTK as a server?

ParaView is based on VTK so truly both rely on the same underlying capabilities. But ParaView can support larger data by working across several machines at the same time (think cluster, High Performance Computing).
And because of that possible multi-machine setup in ParaView, we have an abstraction layer on how things get organized (proxy). This abstraction layer tend to confuse developers but in the same time it provide an higher level API which is more compact than the equivalent VTK code base.
This is especially important since VTK/ParaView Web rely on the Python wrapping to expose those services to the Web. In other words if ParaView already has the capability built-in (filters, rendering settings, …), the amount of code required on the server side with ParaView will be much smaller than its equivalent VTK code. You can already see the difference with that example.

Question 2: My first thought was to use VTK as a server because I am more familiar with it. Given the requirements of my application, which is the best technology and why?

If you know VTK and are familiar with it. Go for it. There will be no difference than with ParaView on a single machine. Having said that, it is possible that you may run into small issue as the ParaView Web path tend to be more exercised. But such bugs will be located on the Python layer and can easily be fixed by your own implementation.

Question 3: Are there any implications when using ParaViewWeb as a client and VTK as a server?

Not really. This is more historic than anything else. We started to enable web with ParaView, hence the name. But both now rely on the same core of communication.

Question 4: What is the advantage of using the ParaViewWeb instead of vtk.js as a client?

Actually, I would recommend using vtk.js on the client side as it is a more modern code and you could allow either remote or local rendering. I know that in your use case, local rendering is out of the question but sometime for mesh rendering when they are small enough (no need to wait minutes to get it on the client side) it could be a convenient option. Also, vtk.js is the library that we will support going forward.

Question 5: Can a vtk.js client work with a ParaView server? If yes, are there some implications for not using the ParaViewWeb client?

Yes. vtk.js in some way aims to replace the ParaViewWeb client library. The ParaViewWeb client library offer more via some React based widget but in term of connectivity to a vtk/pv Web backend, paraviewweb is lagging behind vtk.js. Basically vtk.js offer a nicer implementation, but both will still work as nothing really change over the wire.

Question 6: Will the above setup work for VTK.js + VTKWeb server as well?

Yes. In fact a new protocol was designed for sending images to the client which exist on both VTK and ParaView. An example can be seen here

Hope that helps and sorry again for not having responded earlier.

Seb