https://github.com/trixi-framework/paraviewcatalyst.jl
ParaViewCatalyst.jl provides a Julia interface to Catalyst, used for in-situ visualization of simulation data.
https://github.com/trixi-framework/paraviewcatalyst.jl
Last synced: 4 months ago
JSON representation
ParaViewCatalyst.jl provides a Julia interface to Catalyst, used for in-situ visualization of simulation data.
- Host: GitHub
- URL: https://github.com/trixi-framework/paraviewcatalyst.jl
- Owner: trixi-framework
- License: mit
- Created: 2022-02-10T01:07:57.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2025-02-01T04:15:31.000Z (5 months ago)
- Last Synced: 2025-02-01T05:19:35.134Z (5 months ago)
- Language: Julia
- Homepage: https://trixi-framework.github.io/ParaViewCatalyst.jl
- Size: 310 KB
- Stars: 9
- Watchers: 15
- Forks: 2
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# ParaViewCatalyst.jl
[](https://trixi-framework.github.io/ParaViewCatalyst.jl/dev)
[](https://join.slack.com/t/trixi-framework/shared_invite/zt-sgkc6ppw-6OXJqZAD5SPjBYqLd8MU~g)
[](https://opensource.org/licenses/MIT)**ParaViewCatalyst.jl** provides a Julia interface to
[Catalyst](https://docs.paraview.org/en/latest/Catalyst/index.html),
used for in-situ visualization of simulation data.
The Catalyst library for Julia is provided automatically as a precompiled binary by Catalyst\_jll.jl
at
[JuliaBinaryWrappers](https://github.com/JuliaBinaryWrappers/Catalyst_jll.jl)
and [Yggdrasil](https://github.com/JuliaPackaging/Yggdrasil/tree/master/C/Catalyst).## Getting started
### Prerequisites
Although the [Catalyst API](https://catalyst-in-situ.readthedocs.io) is not restricted to
ParaView, this package is geared towards the
[ParaView implementation](https://docs.paraview.org/en/latest/Catalyst) of the Catalyst API.
As such ParaView needs to be present on the machine you run your simulation on. In
particular, a version is required that ships the Catalyst implementation as a library. On
Linux you should look for `libcatalyst-paraview.so`.
Its path has to be set as an environment variable, e.g. by
```bash
export CATALYST_IMPLEMENTATION_PATHS=
```
Alternatively, when using ParaViewCatalyst.jl from your own application, you can use the keyword argument `libpath` of the function `catalyst_initialize`.### Testing
#### Catalyst implementation
Go to the `examples` folder and start julia using
```shell
julia --project=.
```
In package mode do
```julia
(examples) pkg> dev ..
(examples) pkg> instantiate
```
then
```julia
julia> include("test_init.jl")
```
You should see some information about the Catalyst implementation. In particular, you
should see `implementation: "paraview"`.
More verbose output can be enabled by setting the
environment variable `CATALYST_DEBUG=1`.#### Paraview
Launch ParaView. From the main menu, select "Catalyst", then "Connect", and accept the
default port. Select "Catalyst" again and then "Pause Simulation". Now launch Julia as done
before, and execute
```julia
julia> include("test_execute.jl")
```
In ParaView click on the symbol in front of "Input", then click on the symbol in front of
"Extract: input". You should now see a square. In the properties tab under "Coloring",
select "testdata". Now select "Catalyst" from the main menu and "Continue". The square
should change its color every two seconds.### Using the interface
To use ParaViewCatalyst.jl from your code, you only need `catalyst_initialize()`,
`catalyst_execute(node)`, and `catalyst_finalize()`. All information is passed
through Conduit nodes, which are required to adhere to the
[Blueprint](https://docs.paraview.org/en/latest/Catalyst/blueprints.html).A user-defined ParaView pipeline script can be passed to `catalyst_initialize` using the
keyword argument `catalyst_pipeline`. By default src/catalyst_pipeline.py is used, which
activates live visualization. The data can also be viewed on a remote machine. In this case
`options.CatalystLiveURL` has to be adjusted to point to the remote machine.
Once a pipeline in ParaView has been set up, it can be exported as a script by selecting
"File" from the main menu and then "Save Catalyst State". It might be required to modify
this file afterwards.## Examples
ParaViewCatalyst.jl is used by [Trixi.jl](https://github.com/trixi-framework/Trixi.jl).## Authors
ParaViewCatalyst.jl was initiated by Jake Bolewski ([@jakebolewski](https://github.com/jakebolewski))
at https://github.com/CliMA and is now maintained by
[Benedict Geihe](https://www.mi.uni-koeln.de/NumSim/dr-benedict-geihe/) (University of Cologne,
Germany).## License and contributing
ParaViewCatalyst.jl is licensed under the MIT license (see [LICENSE.md](LICENSE.md)). Since
ParaViewCatalyst.jl is an open-source project, we are very happy to accept contributions from the
community. Note that we strive to be a friendly, inclusive open-source community and ask all members
of our community to treat each other decently. To get in touch with the developers,
[join us on Slack](https://join.slack.com/t/trixi-framework/shared_invite/zt-sgkc6ppw-6OXJqZAD5SPjBYqLd8MU~g)
or
[create an issue](https://github.com/trixi-framework/ParaViewCatalyst.jl/issues/new).