Closed ews-ffarella closed 8 months ago
OK, this solved it (assuming your are using the docker image)
This is taken from https://gitlab.onelab.info/gmsh/gmsh/-/blob/master/utils/docker/Dockerfile.ubuntu20.04
cd $HOME/packages
find $HOME/packages -maxdepth 1 -type d -iname "gmsh*" | xargs rm -rf
GMSH_VERSION="4.11.1"
GMSH_NAME=$(echo $GMSH_VERSION | sed 's/\./_/g')
wget "https://gitlab.onelab.info/gmsh/gmsh/-/archive/gmsh_$GMSH_NAME/gmsh-gmsh_$GMSH_NAME.tar.gz" && tar -xf "gmsh-gmsh_$GMSH_NAME.tar.gz" && rm -f "gmsh-gmsh_$GMSH_NAME.tar.gz" && mv "gmsh-gmsh_$GMSH_NAME" "gmsh-$GMSH_VERSION"
# Or if we don't want the names being fixed
GMSH_VERSION="master"
git clone https://gitlab.onelab.info/gmsh/gmsh.git "gmsh-$GMSH_VERSION" && cd "gmsh-$GMSH_VERSION"
git checkout 3a8640cbda19bbde95a80bdeef0525485d0f145e
cd "$HOME/packages/gmsh-$GMSH_VERSION"
mkdir build && cd build
CGNS_ROOT="$HOME/packages/CGNS-4.4.0/opt-gcc" cmake \
-DCMAKE_INSTALL_PREFIX="$HOME/packages/gmsh-$GMSH_VERSION/opt-gcc" \
-DCMAKE_BUILD_TYPE=Release \
-DENABLE_BUILD_SHARED=1 \
-DENABLE_PRIVATE_API=1 \
-DENABLE_CGNS=ON \
-DENABLE_CGNS_CPEX0045=OFF \
-DENABLE_PETSC=ON \
-DENABLE_MPI=ON \
-DENABLE_OPENMP=ON \
-DENABLE_PETSC4PY=ON \
-DOPENGL_GL_PREFERENCE=LEGACY \
..
make -j8 shared && make -j8 install && cd .. && rm -rf build
cd $HOME
Now i can at least run cgnscheck
on my output
Note that I reverted to version 4.11.1 because of this https://gitlab.onelab.info/gmsh/gmsh/-/issues/2652
Solved it! If anyone face problems with gmsh output, you can reach out to me. The trick is to use cgns_utilities, modify the BCSTANDARD dict and set the key of wall to 0 before using readGrid. Then, one can loop over the blocks and reset the cgns_type to the desired value
Edit: I will try to compile GMSH from source on the mdolab image and let you know
I am trying to read multi-block grid generatey by GMSH version 4.12.2 but somehow it fails.
The code to generate the surface is:
So I export the data using the PLOT3D Driver, and
pyhyp
can load it. Somehow, the normals are inverted, but I can live with it. Now, Paraview 5.11.2 can read the CGNS output generated by GMSH (Mesh.Format = 32). So I would like to do a bit of processing, show below, modify the output of GMSH, and save it to VTM and then CGNS from paraview.but somehow, the file is still corrupted. Any idea where this comes from?
This is what my CGNS looks like in Paraview
I must point out that I am running it in a container and that the files are written on a CIFS volume. I will try to write them under '/tmp', maybe this could be help.
Thanks