Git Product home page Git Product logo

openpmd-converter's People

Contributors

ax3l avatar denisbertini avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Forkers

denisbertini

openpmd-converter's Issues

HDF5: XMDF Creator

Merge our old tools for splash2xdmf and pic2xdmf (usage see PIConGPU wiki) to a unified tool for openPMD files.

A specific tool for the ED-PIC extension might not be necessary since all definitions of the base standard stay valid (e.g., positions, etc.).

Merge: fileBased -> groupBased

I recently needed a small script that converted our usual "fileBased" iterationEncoding to a single "groupBased" file (in HDF5).

Next time I need it I will rewrite it in pure python so it's more portable. (Actually, I tried pure bash but needed a small in-file manipulation which I found no CLI tool for).

Nevertheless, here it is already:

#!/usr/bin/env bash
#
# Copyright 2017 Axel Huebl
#
# Use under the ISC software license.
#

# needs input argument parsing & help

dumps=($(ls h5/*_*.h5))
first=0

for d in ${dumps[@]};
do
    if [ $first -eq 0 ]
    then
        # includes copy of / attributes from first file
        cp $d simData.h5
        first=1
    else
        step=$(echo $d | sed 's/.\+_\([0-9]\+\)\.h5/\1/')
        h5copy -i $d -s "/data/$step" \
               -o simData.h5 -d "/data/$step"
    fi
done

# that might not be necessary if your files already had compression enabled
h5repack -i simData.h5 -o simData.h5.gz -f GZIP=1 && \
    mv simData.h5.gz simData.h5

# change attributes:
#   "/iterationEncoding" -> "groupBased"
#   "/iterationFormat" -> "/data/%T/"
python -c 'import h5py; import numpy as np; f=h5py.File("simData.h5", "a"); f.attrs["iterationEncoding"] = np.string_("groupBased"); f.attrs["iterationFormat"] = np.string_("/data/%T/"); f.close()'

Comparion to CFconventions

How do we compare to http://cfconventions.org/ ?

We are file format agnostic.
The openPMD base standard is (scientific) domain and application agnostic.
We do not yet support unstructured meshes, besides expressing them as particles (dataframes).

Title of the README

I think the title of the README should be changed to "openPMD tools" instead of "openPMD Validator scripts"

OpenVDB

https://en.wikipedia.org/wiki/OpenVDB:

OpenVDB is an open source software library for working with sparse volumetric data. It provides a hierarchical data structure and related functions to help with calculating volumetric effects in CGI applications. Volumetric effects apply to volumes, as opposed to just on surfaces. An example is fog.

Specifically catering for feature film production, the library was originally developed by DreamWorks Animation and is currently maintained by the Academy Software Foundation (ASWF). The primary authors are Ken Museth, Peter Cucka, Mihai Aldén, and David Hill. OpenVDB is written in C++ and has Python bindings.

OpenVDB is supported in a wide range of CGI software, such as Blender (since April 2016), Cinema 4D, Houdini, and RenderMan. It was used in the films Puss in Boots (2011) and Rise of the Guardians (2012). 

https://www.openvdb.org
https://academysoftwarefoundation.github.io/openvdb/
https://github.com/AcademySoftwareFoundation/openvdb

converter for hdf5 to adios and vice versa

A tool that converts openPMD files from hdf5 to adios and vice versa would be useful since:

  • specific pre- and post-processing tool might only work with one or the other
  • some PIC codes (and others) might only have implemented one output format thus this would ease interchange of openPMD files between codes (that only support one version)

As an example:
I have implemented an electron bunch initialization that only works with hdf5 and writes out a openPMD checkpoint that PIConGPU can use to continue simulating the bunch evolution. However since the simulation is quite large and memory consuming, adios would be a better choice for file IO and using hdf5 comes with a performance detriment. Thus, I have right now three options: (1) update my code to the latest dev where PIConGPU supports mixed output formats, (2) include adios as output to my pre-processing tool, or (3) convert the generated hdf5 to adios before using PIConGPU with adios only.

However, since such a conversion tool might be useful for more users, my question is whether you @RemiLehe and @ax3l think it is useful too and if you think a conversion between openPMD hdf5 and openPMD adios is possible in general.

SDF to openPMD

@ax3l i sent a PR to this repo. about the SDF to openPMD project. If there is some problem to merge, please tell me.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.