Conda binaries cannot use HDF5

Issue #142 invalid
Romain Beucher created an issue

Hi,

I have added HDF5 to the petsc conda build on conda-forge.
They seem to work just fine.
My issue is when I install petsc4py using conda I can’t use the HDF5 functionalities:

An example such as:

from petsc4py import PETSc

DIM = 2
CELLS = [[0, 1], [1, 2]]
COORDS = [[0.], [0.5], [1.]]

dm = PETSc.DMPlex().createFromCellList(DIM, CELLS, COORDS)

ViewHDF5 = PETSc.Viewer()
ViewHDF5.createHDF5('test.h5', mode='w')
ViewHDF5.view(obj=dm)
ViewHDF5 = None

returns:

Traceback (most recent call last):
  File "test.py", line 11, in <module>
    ViewHDF5.view(obj=dm)
  File "PETSc/Viewer.pyx", line 103, in petsc4py.PETSc.Viewer.view
petsc4py.PETSc.Error: error code 56
[0] PetscObjectView() line 90 in /home/conda/feedstock_root/build_artifacts/petsc_1591169429678/work/src/sys/objects/destroy.c
[0] DMView() line 922 in /home/conda/feedstock_root/build_artifacts/petsc_1591169429678/work/src/dm/interface/dm.c
[0] DMView_Plex() line 1263 in /home/conda/feedstock_root/build_artifacts/petsc_1591169429678/work/src/dm/impls/plex/plex.c
[0] DMPlexView_HDF5_Internal() line 781 in /home/conda/feedstock_root/build_artifacts/petsc_1591169429678/work/src/dm/impls/plex/plexhdf5.c
[0] DMPlexWriteCoordinates_HDF5_Static() line 551 in /home/conda/feedstock_root/build_artifacts/petsc_1591169429678/work/src/dm/impls/plex/plexhdf5.c
[0] PetscViewerHDF5PushGroup() line 12 in src/include/compat/hdf5.h
[0] No support for this operation for this object type
[0] PetscViewerHDF5PushGroup() requires HDF5

Would a new petsc4py build on conda-forge fix this?

Thanks

R

Comments (4)

  1. Lisandro Dalcin

    Well, petsc4py should be rebuilt with the new PETSc. I guess it is just a matter of submiting a PR bumping the build number in the petsc4py feedstock?

  2. Romain Beucher reporter

    Yes, if it is indeed a where the issue comes from, this should be on the petsc4pt-feedstock.

    I will submit a PR there.

    Romain

  3. Log in to comment