VTUFileHandler
VTUFileHandler: A VTU library in the Julia language that implements an algebra for basic mathematical operations on VTU data - Published in JOSS (2022)
Science Score: 49.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
○CITATION.cff file
-
✓codemeta.json file
Found codemeta.json file -
✓.zenodo.json file
Found .zenodo.json file -
✓DOI references
Found 3 DOI reference(s) in README -
✓Academic publication links
Links to: joss.theoj.org -
○Committers with academic emails
-
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (15.5%) to scientific vocabulary
Scientific Fields
Repository
A VTU library in the Julia language that implements an algebra for basic mathematical operations on VTU data.
Basic Info
- Host: GitHub
- Owner: baxmittens
- License: mit
- Language: Julia
- Default Branch: main
- Size: 2.49 MB
Statistics
- Stars: 4
- Watchers: 2
- Forks: 3
- Open Issues: 1
- Releases: 5
Metadata Files
README.md
VTUFileHandler.jl
A VTU library in the Julia language that implements an algebra for basic mathematical operations on VTU data.
See the documentation
Introduction
With increasing computing resources, investigating uncertainties in simulation results is becoming an increasingly important factor. A discrete numerical simulation is computed several times with different deviations of the input parameters to produce different outputs of the same model to analyze those effects. The relevant stochastic or parametric output variables, such as mean, expected value, and variance, are often calculated and visualized only at selected individual points of the whole domain. This project aims to provide a simple way to perform stochastic/parametric post-processing of numerical simulations on entire domains using the VTK unstructured grid (VTU) file system and the Julia language as an example.
Install
julia
import Pkg
Pkg.add("VTUFileHandler")
Preliminaries
The VTUFileHandler will eventually be used to perform stochastic post-processing on large VTU result files. Therefore, the following assumptions have to be fulfilled for the software to work correctly:
- The VTU file must be in binary format and, in addition, can be Zlib compressed.
- Operators can only be applied to VTU files sharing the same topology. The user must ensure that this condition is met.
- The data type of numerical fields of the VTU file, for which operators should be applied, have to be
Float64.
Usage
The VTUFileHandler implements a basic VTU reader and writer through the functions:
julia
function VTUFile(file::String) ... end
function Base.write(vtu::VTUFile, add_timestamp=true) ... end
By default, a timestamp is added if VTU files are written to disk not to overwrite existing files. Only data fields that are registered by the function
julia
function set_uncompress_keywords(uk::Vector{String}) ... end
before reading the VTU file are uncompressed and can be altered. For applying math operators onto a data field, the associated field has to be registered by the function
julia
function set_interpolation_keywords(ik::Vector{String}) ... end
The following math operators are implemented:
julia
+(::VTUFile, ::VTUFile),+(::VTUFile, ::Number),
-(::VTUFile, ::VTUFile),-(::VTUFile, ::Number),
*(::VTUFile, ::VTUFile),*(::VTUFile, ::Number),
/(::VTUFile, ::VTUFile),/(::VTUFile, ::Number),
^(::VTUFile, ::Number)
In-place variations of the operators above are implemented as well.
Example
A three-dimensional cube with dimension (x,y,z) with 0<=x,y,z<=2 discretized by quadrilian elements with 27 points and 8 cells named vox8.vtu with a linear ramp in x-direction (f(x=0,y,z)=0, f(x=2,y,z)=0.8) as a result field termed xramp will be used as an example. The following set of instructions transform the result field from a linear ramp to a quadratic function in x-direction (displayed as a piecewise linear field due to the discretization):
julia
using VTUFileHandler
set_uncompress_keywords(["xRamp"]) # uncompress data field xramp
set_interpolation_keywords(["xRamp"]) # apply math operators to xramp
vtu = VTUFile("vox8.vtu"); # read the vtu
vtu += vtu/4; # [0.0,...,0.8] -> [0.0,...,1.0]
vtu *= 4.0; # [0,...,1.0] -> [0.0,...,4.0]
vtu -= 2.0; # [0,...,4.0] -> [-2.0,...,2.0]
vtu ^= 2.0; # [-2.0,...,2.0] -> [4.0,...,0.0,...,4.0]
rename!(vtu, ”vox8_1.vtu”)
write(vtu)
.
Contributions, report bugs and support
Contributions to or questions about this project are welcome. Feel free to create a issue or a pull request on GitHub.
Owner
- Name: Max Bittens
- Login: baxmittens
- Kind: user
- Repositories: 7
- Profile: https://github.com/baxmittens
Scientific coworker @ BGR
GitHub Events
Total
- Release event: 1
- Watch event: 1
- Issue comment event: 3
- Push event: 2
- Create event: 1
Last Year
- Release event: 1
- Watch event: 1
- Issue comment event: 3
- Push event: 2
- Create event: 1
Committers
Last synced: 5 months ago
Top Committers
| Name | Commits | |
|---|---|---|
| Bittens | B****M@b****l | 137 |
| Max Bittens | 1****s | 109 |
| Mark Kittisopikul | m****i | 3 |
| unknown | t****l@u****e | 1 |
| Nathan Zimmerberg | 3****2 | 1 |
| Mehmet Hakan Satman | m****n@g****m | 1 |
| Max Bittens | b****s@o****l | 1 |
| Admin.Bittens | A****s@P****l | 1 |
Committer Domains (Top 20 + Academic)
Issues and Pull Requests
Last synced: 4 months ago
All Time
- Total issues: 4
- Total pull requests: 8
- Average time to close issues: 7 months
- Average time to close pull requests: 2 days
- Total issue authors: 2
- Total pull request authors: 5
- Average comments per issue: 7.0
- Average comments per pull request: 0.5
- Merged pull requests: 8
- Bot issues: 0
- Bot pull requests: 0
Past Year
- Issues: 0
- Pull requests: 1
- Average time to close issues: N/A
- Average time to close pull requests: about 12 hours
- Issue authors: 0
- Pull request authors: 1
- Average comments per issue: 0
- Average comments per pull request: 0.0
- Merged pull requests: 1
- Bot issues: 0
- Bot pull requests: 0
Top Authors
Issue Authors
- baxmittens (3)
- JuliaTagBot (1)
Pull Request Authors
- mkitti (3)
- nhz2 (2)
- baxmittens (2)
- jbytecode (1)
- nagelt (1)
Top Labels
Issue Labels
Pull Request Labels
Packages
- Total packages: 1
-
Total downloads:
- julia 1 total
- Total dependent packages: 0
- Total dependent repositories: 0
- Total versions: 4
juliahub.com: VTUFileHandler
A VTU library in the Julia language that implements an algebra for basic mathematical operations on VTU data.
- Documentation: https://docs.juliahub.com/General/VTUFileHandler/stable/
- License: MIT
-
Latest release: 1.0.2
published 11 months ago