# PyCharm IDE and Paraview

**URL:** https://discourse.paraview.org/t/pycharm-ide-and-paraview/9559
**Category:** ParaView Support
**Tags:** python
**Created:** [May 3, 2022, 10:57pm UTC](https://discourse.paraview.org/t/pycharm-ide-and-paraview/9559 "2022-05-03T22:57:04Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![Thipessoa](https://discourse.paraview.org/user_avatar/discourse.paraview.org/thipessoa/32/9140_2.png) [@Thipessoa](https://discourse.paraview.org/u/Thipessoa)
#### Post date: [May 3, 2022, 10:57pm UTC](https://discourse.paraview.org/t/pycharm-ide-and-paraview/9559/1 "2022-05-03T22:57:04Z")

</div>

Hello everyone!

I am using Paraview to automate the post-processing of my model. I am currently writing a script in PyCharm and through Paraview in “Run script”, I can make it run, everything works fine.

But I would like to make an interactive and executable program that the user could choose what kind of filters he would like to analyse, making PyCharm to open Paraview and run the script automatically. I managed to open Paraview by a code, but I don’t know what to do when talking about Paraview running a script without clicking in “Run script”.

Another issue that I am struggling with, I am creating different .py files (around five), and I would like to only one of them (the main one) would run the rest, but Paraview seems to not recognize opening other .py files from the main one.

Anyone could help? Thank you!  
Thiago.

---

<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: [May 4, 2022, 7:46am UTC](https://discourse.paraview.org/t/pycharm-ide-and-paraview/9559/2 "2022-05-04T07:46:45Z")

</div>

Hi @Thipessoa ,

> [@Thipessoa](#):
>
> but I don’t know what to do when talking about Paraview running a script without clicking in “Run script”.

You are either looking for

```auto
pvpython /path/to/script

```

or

```auto
paraview --script /path/to/script

```

Best,

---

<div class="post-metadata">

### Author: ![Thipessoa](https://discourse.paraview.org/user_avatar/discourse.paraview.org/thipessoa/32/9140_2.png) [@Thipessoa](https://discourse.paraview.org/u/Thipessoa)
#### Post date: [May 4, 2022, 5:49pm UTC](https://discourse.paraview.org/t/pycharm-ide-and-paraview/9559/3 "2022-05-04T17:49:31Z")

</div>

Hello @mwestphal, thanks for the reply.

This should be added into the .py file script, right?

I will be testing here and giving a reply later. Thanks!!

---

<div class="post-metadata">

### Author: ![Thipessoa](https://discourse.paraview.org/user_avatar/discourse.paraview.org/thipessoa/32/9140_2.png) [@Thipessoa](https://discourse.paraview.org/u/Thipessoa)
#### Post date: [May 4, 2022, 11:39pm UTC](https://discourse.paraview.org/t/pycharm-ide-and-paraview/9559/4 "2022-05-04T23:39:18Z")

</div>

Hey @mwestphal, correct me if I am wrong, but both “pvpython /path/to/script” and “paraview --script /path/to/script” are shell commands, right? I should find a way to read these lines in the .py file then.

I already managed to make the .py file open Paraview through **os** library “os.system(path/paraview.exe)”.

Now just need to make the same .py file insert everything that comes out from the **trace tool** into the **Python shell** or make it read another .py file for example.

---

<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: [May 5, 2022, 7:09am UTC](https://discourse.paraview.org/t/pycharm-ide-and-paraview/9559/5 "2022-05-05T07:09:47Z")

</div>

Hi @Thipessoa ,

> [@Thipessoa](#):
>
> Hey @mwestphal, correct me if I am wrong, but both “pvpython /path/to/script” and “paraview --script /path/to/script” are shell commands, right?

Yes

> I should find a way to read these lines in the .py file then.

Not at all, you can just use pvpython directly. Why do you want to run paraview ?

---

<div class="post-metadata">

### Author: ![Thipessoa](https://discourse.paraview.org/user_avatar/discourse.paraview.org/thipessoa/32/9140_2.png) [@Thipessoa](https://discourse.paraview.org/u/Thipessoa)
#### Post date: [May 6, 2022, 2:47am UTC](https://discourse.paraview.org/t/pycharm-ide-and-paraview/9559/6 "2022-05-06T02:47:18Z")

</div>

@mwestphal I see what you mean, I don’t have to open Paraview to make it run then…

Thank you for all the help, I will try make these work!
