How to revise to plot in ParaView installed in Windows system?

Hi, for some reason, I have to use VirtualBox to run Pylith in my computer. However, there is not too much storage for my VirtualBox, so I installed Paraview in my Windows system. But as a new programmer, I don’t know how to revise the file to let my Paraview read all of the files that it needs to compile the program into a virtual plot. Below is the error info when I run python shell in Paraview.

Traceback (most recent call last):
File “”, line 152, in
File “”, line 56, in visualize
OSError: File ‘output\step01_axialdisp-domain.xmf’ does not exist.

By the way, I have tried to copy output folder and to Windows system and revise the path lines in the to plot but I failed.

I guess I need to revise somewhere of file to make it plot but I don’t know how. Thanks for help!

For Windows, we recommend using the Windows Subsystem for Linux rather than a virtual box. This makes it easier to access files generated within Linux from Windows and vice versa.

Regardless of your operating system, if you launch ParaView from a directory other than where you ran PyLith (for example, examples/box-2d), then you need to set OUTPUT_DIR in the ParaView Python shell to the absolute path to where the .h5 and .xmf files are located before running the Python script. For example, if the output files are in (using Linux directory structure) $HOME/src/cig/pylith/examples/box-2d/output, then in the ParaView Python Shell:

import os
OUTPUT_DIR = os.path.join(os.environ["HOME"], "src", "cig", "pylith", "examples", "box-2d", "output")

This is documented at the top of the Python script, but I will add it to the manual.

Thanks for your answer. That’s the exactly the part where i think I should change the code. But could you please show me how to use Windows directory structure to change the command lines of absolute path. My output folder is saved in this path:

import os
OUTPUT_DIR = os.path.abspath(os.path.join("Users","HeLingChao","Downloads", "output"))

Using os.path.abspath() should add the drive letter on Windows.

Thanks for help. I tried this code but ParaView still shows:
Traceback (most recent call last):
File “”, line 151, in
File “”, line 55, in visualize
OSError: File ‘output\step01_axialdisp-domain.xmf’ does not exist.

There is no need to edit the script. In this case, you edited the comment, so it has no effect. You need to set OUTPUT_DIR in the ParaView Python Shell (see screenshot below) before clicking on the Run Script button.

It is fixed! Thanks for your patience!