# Simulation Application With ParaView

**URL:** https://discourse.paraview.org/t/simulation-application-with-paraview/11636
**Category:** ParaView Support
**Created:** [March 15, 2023, 7:41pm UTC](https://discourse.paraview.org/t/simulation-application-with-paraview/11636 "2023-03-15T19:41:01Z")
**Posts on this page:** 20
**Page:** 1

<div class="post-metadata">

### Author: ![Muhammad\_Saad\_Atique](https://discourse.paraview.org/user_avatar/discourse.paraview.org/muhammad_saad_atique/32/11159_2.png) [@Muhammad\_Saad\_Atique](https://discourse.paraview.org/u/Muhammad_Saad_Atique)
#### Post date: [March 15, 2023, 7:41pm UTC](https://discourse.paraview.org/t/simulation-application-with-paraview/11636/1 "2023-03-15T19:41:02Z")

</div>

Hi, I am creating a simulation (code written in C++). I want to create a simple frontend which will basically take some inputs and vtk file. I like to incorporate para view visualization and other filters in the frontend which will basically run my C++ code in backend. Any leads how I can incorporate paraView in my frontend form and how to take some inputs from paraview and pass it to my C++ source code?

---

<div class="post-metadata">

### Author: ![mwestphal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/mwestphal/32/17_2.png) [@mwestphal](https://discourse.paraview.org/u/mwestphal)
#### Post date: [March 16, 2023, 8:47am UTC](https://discourse.paraview.org/t/simulation-application-with-paraview/11636/2 "2023-03-16T08:47:07Z")

</div>

Are you looking to create a ParaView based application ?

[https://www.paraview.org/Wiki/Writing\_Custom\_Applications](https://www.paraview.org/Wiki/Writing_Custom_Applications)

---

<div class="post-metadata">

### Author: ![Muhammad\_Saad\_Atique](https://discourse.paraview.org/user_avatar/discourse.paraview.org/muhammad_saad_atique/32/11159_2.png) [@Muhammad\_Saad\_Atique](https://discourse.paraview.org/u/Muhammad_Saad_Atique)
#### Post date: [March 20, 2023, 2:04pm UTC](https://discourse.paraview.org/t/simulation-application-with-paraview/11636/3 "2023-03-20T14:04:35Z")

</div>

Yes. The idea is to use paraview for visualization, applying forces to regions and meshing. But I am doing this on Mac. Seems like there are a lot of issues on Mac with paraview

---

<div class="post-metadata">

### Author: ![mwestphal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/mwestphal/32/17_2.png) [@mwestphal](https://discourse.paraview.org/u/mwestphal)
#### Post date: [March 20, 2023, 2:06pm UTC](https://discourse.paraview.org/t/simulation-application-with-paraview/11636/4 "2023-03-20T14:06:38Z")

</div>

> [@Muhammad\_Saad\_Atique](#):
>
> Seems like there are a lot of issues on Mac with paraview

That is just not true. ParaView is compatible with ParaView and many users are using ParaView on MacOS perfectly.

If you’ve found any MacOS specific issue, please share it.

---

<div class="post-metadata">

### Author: ![Muhammad\_Saad\_Atique](https://discourse.paraview.org/user_avatar/discourse.paraview.org/muhammad_saad_atique/32/11159_2.png) [@Muhammad\_Saad\_Atique](https://discourse.paraview.org/u/Muhammad_Saad_Atique)
#### Post date: [March 20, 2023, 2:15pm UTC](https://discourse.paraview.org/t/simulation-application-with-paraview/11636/5 "2023-03-20T14:15:20Z")

</div>

Thanks for a quick response. The issue is not with Paraview GUI iteself. I am writing a python script with Pyside2 (which is built on QT) to create a new GUI. But my script would use paraview to display, visualize and apply forces.

Firstly, after installing Paraview GUI, I tried importing paraview, paraview.simple and paraview.qt but it seems to not find these packages in my script. If it run my script from pvpython it get’s rid of paraview and paraview.simple errors but paraview.qt error is still there.

---

<div class="post-metadata">

### Author: ![mwestphal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/mwestphal/32/17_2.png) [@mwestphal](https://discourse.paraview.org/u/mwestphal)
#### Post date: [March 20, 2023, 2:17pm UTC](https://discourse.paraview.org/t/simulation-application-with-paraview/11636/6 "2023-03-20T14:17:20Z")

</div>

> [@Muhammad\_Saad\_Atique](#):
>
> (code written in C++).

> I am writing a python script with Pyside2

Are you using Python or C++ ?

> paraview.qt but it seems to not find these packages in my script.

Pyside2 is not included in ParaView python modules.

---

<div class="post-metadata">

### Author: ![Muhammad\_Saad\_Atique](https://discourse.paraview.org/user_avatar/discourse.paraview.org/muhammad_saad_atique/32/11159_2.png) [@Muhammad\_Saad\_Atique](https://discourse.paraview.org/u/Muhammad_Saad_Atique)
#### Post date: [March 20, 2023, 2:23pm UTC](https://discourse.paraview.org/t/simulation-application-with-paraview/11636/7 "2023-03-20T14:23:09Z")

</div>

So I have a backend code written in C++ which is the main part of my application. But for the frontend/GUI I am using Python. As far as I know paraview.qt is not just for Pyside2. For example from paraview.qt import something would give me error that No Module name ‘paraview.qt’ and I could not resolve this issue. What are your suggestions?

---

<div class="post-metadata">

### Author: ![mwestphal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/mwestphal/32/17_2.png) [@mwestphal](https://discourse.paraview.org/u/mwestphal)
#### Post date: [March 20, 2023, 2:25pm UTC](https://discourse.paraview.org/t/simulation-application-with-paraview/11636/8 "2023-03-20T14:25:19Z")

</div>

`paraview.qt` is not a thing that exist.

> What are your suggestions?

There is a PythonQt plugin which is only available in ParaView master (it was broken for some releases but was recently fixed). That being said, I’d suggest to write your front end in C++, with proper Qt + ParaView C++ code.

---

<div class="post-metadata">

### Author: ![Muhammad\_Saad\_Atique](https://discourse.paraview.org/user_avatar/discourse.paraview.org/muhammad_saad_atique/32/11159_2.png) [@Muhammad\_Saad\_Atique](https://discourse.paraview.org/u/Muhammad_Saad_Atique)
#### Post date: [March 20, 2023, 2:28pm UTC](https://discourse.paraview.org/t/simulation-application-with-paraview/11636/9 "2023-03-20T14:28:41Z")

</div>

Thank you for the suggestions. One last question, so I am planning to make my application commercial and for Qt commercial versions I would have to pay. I am in my initial phases so I was wondering is there any alternate to Qt where I don’t have to pay for the commercial usage?

---

<div class="post-metadata">

### Author: ![mwestphal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/mwestphal/32/17_2.png) [@mwestphal](https://discourse.paraview.org/u/mwestphal)
#### Post date: [March 20, 2023, 2:29pm UTC](https://discourse.paraview.org/t/simulation-application-with-paraview/11636/10 "2023-03-20T14:29:49Z")

</div>

No suggestions here.

---

<div class="post-metadata">

### Author: ![Muhammad\_Saad\_Atique](https://discourse.paraview.org/user_avatar/discourse.paraview.org/muhammad_saad_atique/32/11159_2.png) [@Muhammad\_Saad\_Atique](https://discourse.paraview.org/u/Muhammad_Saad_Atique)
#### Post date: [March 20, 2023, 8:04pm UTC](https://discourse.paraview.org/t/simulation-application-with-paraview/11636/11 "2023-03-20T20:04:25Z")

</div>

Can we use python directly from our console or do we need to use pvpython?

---

<div class="post-metadata">

### Author: ![mwestphal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/mwestphal/32/17_2.png) [@mwestphal](https://discourse.paraview.org/u/mwestphal)
#### Post date: [March 21, 2023, 8:52am UTC](https://discourse.paraview.org/t/simulation-application-with-paraview/11636/12 "2023-03-21T08:52:16Z")

</div>

You can use python as you see fit.

If you mean that you want to access ParaView python modules from any python interpreter, yes you can.

Just add ParaView python modules to the PYTHONPATH.

---

<div class="post-metadata">

### Author: ![Muhammad\_Saad\_Atique](https://discourse.paraview.org/user_avatar/discourse.paraview.org/muhammad_saad_atique/32/11159_2.png) [@Muhammad\_Saad\_Atique](https://discourse.paraview.org/u/Muhammad_Saad_Atique)
#### Post date: [March 21, 2023, 6:12pm UTC](https://discourse.paraview.org/t/simulation-application-with-paraview/11636/13 "2023-03-21T18:12:42Z")

</div>

Thank you for your response. I have another question related to Qt. I know paraview is built using Qt. And now if I make custom application using paraview (indirectly I am using Qt) so will I need to pay for Qt license if I plan to make my application commercial?

---

<div class="post-metadata">

### Author: ![mwestphal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/mwestphal/32/17_2.png) [@mwestphal](https://discourse.paraview.org/u/mwestphal)
#### Post date: [March 22, 2023, 9:55am UTC](https://discourse.paraview.org/t/simulation-application-with-paraview/11636/14 "2023-03-22T09:55:54Z")

</div>

**This is not legal advice, consult a (open source specialized) lawyer for legal advice.**

If you want a commercial license of Qt, yes you need to pay for it.  
If you want a LGPL license license of Qt, there is nothing to pay but you need to respect the LGPL license terms.

Nothing in the LGPL license prevents you to “make you application commercial”.  
If you only link against Qt, the LGPL license terms let you license you application as you see fit.

**This is not legal advice, consult a (open source specialized) lawyer for legal advice.**

---

<div class="post-metadata">

### Author: ![Muhammad\_Saad\_Atique](https://discourse.paraview.org/user_avatar/discourse.paraview.org/muhammad_saad_atique/32/11159_2.png) [@Muhammad\_Saad\_Atique](https://discourse.paraview.org/u/Muhammad_Saad_Atique)
#### Post date: [March 22, 2023, 4:33pm UTC](https://discourse.paraview.org/t/simulation-application-with-paraview/11636/15 "2023-03-22T16:33:04Z")

</div>

Thank you so much!  
Sorry to bug you again. I tried to add Paraview Python to my PYTHONPATH but still could not import paraview.simple  
My paraview python is in: Applications/ParaView-5.11.0.app/Contents/Python/paraview  
And I am doing this on mac

---

<div class="post-metadata">

### Author: ![mwestphal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/mwestphal/32/17_2.png) [@mwestphal](https://discourse.paraview.org/u/mwestphal)
#### Post date: [March 22, 2023, 4:36pm UTC](https://discourse.paraview.org/t/simulation-application-with-paraview/11636/16 "2023-03-22T16:36:24Z")

</div>

You need to use the same python version as the ParaView binary release for this to work, and this may not be reliable.

At some point, you may want to build ParaView yourself and it will just work.

---

<div class="post-metadata">

### Author: ![Muhammad\_Saad\_Atique](https://discourse.paraview.org/user_avatar/discourse.paraview.org/muhammad_saad_atique/32/11159_2.png) [@Muhammad\_Saad\_Atique](https://discourse.paraview.org/u/Muhammad_Saad_Atique)
#### Post date: [March 22, 2023, 4:39pm UTC](https://discourse.paraview.org/t/simulation-application-with-paraview/11636/17 "2023-03-22T16:39:34Z")

</div>

My python version and the binary is the same i.e. 3.9.  
By building Paraview myself you mean paraview superbuild?[https://gitlab.kitware.com/paraview/paraview-superbuild](https://gitlab.kitware.com/paraview/paraview-superbuild)

---

<div class="post-metadata">

### Author: ![mwestphal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/mwestphal/32/17_2.png) [@mwestphal](https://discourse.paraview.org/u/mwestphal)
#### Post date: [March 22, 2023, 4:40pm UTC](https://discourse.paraview.org/t/simulation-application-with-paraview/11636/18 "2023-03-22T16:40:11Z")

</div>

No I mean ParaView: [https://gitlab.kitware.com/paraview/paraview/-/blob/master/Documentation/dev/build.md](https://gitlab.kitware.com/paraview/paraview/-/blob/master/Documentation/dev/build.md)

---

<div class="post-metadata">

### Author: ![Muhammad\_Saad\_Atique](https://discourse.paraview.org/user_avatar/discourse.paraview.org/muhammad_saad_atique/32/11159_2.png) [@Muhammad\_Saad\_Atique](https://discourse.paraview.org/u/Muhammad_Saad_Atique)
#### Post date: [March 22, 2023, 4:41pm UTC](https://discourse.paraview.org/t/simulation-application-with-paraview/11636/19 "2023-03-22T16:41:22Z")

</div>

> [@mwestphal](#):
>
> [https://gitlab.kitware.com/paraview/paraview/-/blob/master/Documentation/dev/build.md](https://gitlab.kitware.com/paraview/paraview/-/blob/master/Documentation/dev/build.md)

It does not seem to have the section for mac. Does it work for mac?

---

<div class="post-metadata">

### Author: ![mwestphal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/mwestphal/32/17_2.png) [@mwestphal](https://discourse.paraview.org/u/mwestphal)
#### Post date: [March 22, 2023, 4:43pm UTC](https://discourse.paraview.org/t/simulation-application-with-paraview/11636/20 "2023-03-22T16:43:01Z")

</div>

There is no getting started section for MacOS, but the generic section below is for all supported platforms, which include MacOS.

[Next page](https://discourse.paraview.org/t/simulation-application-with-paraview/11636.md?page=2)
