Giter Site home page Giter Site logo

Failing test about gudhi-devel HOT 8 CLOSED

mboisson avatar mboisson commented on June 13, 2024
Failing test

from gudhi-devel.

Comments (8)

mglisse avatar mglisse commented on June 13, 2024

Hello,
I don't remember ever seeing this error. Does it reproduce every time? Could you tell us more about how you built gudhi (options to cmake, output of cmake)? Is there anything unusual in your platform (virtual machine, compilation and execution on different machines, etc)?
Line 80 is assert gudhi.pick_n_random_points(points=[], nb_points=0) == [], does running gudhi.pick_n_random_points(points=[], nb_points=0) after just importing gudhi also crash?

from gudhi-devel.

mboisson avatar mboisson commented on June 13, 2024

Yes, it happens every time (until I disable the tests).

This is an install for cluster computing environments. The build is in a virtual machine. The tests are run on the same VM.

The whole build is using EasyBuild, with modules (external libraries), and is therefore rather complicated, but the gist of the commands being run is the following:

grep "running cmd" /home/mboisson/.local/easybuild/software/2020/avx2/Compiler/gcc9/gudhi/3.7.1/easybuild/easybuild-GUDHI-3.7.1-20230216.163908.log
== 2023-02-16 16:24:22,821 run.py:236 INFO running cmd: tar xzf /home/mboisson/.local/easybuild/sources/g/GUDHI/gudhi.3.7.1.tar.gz
== 2023-02-16 16:24:39,346 run.py:236 INFO running cmd:  cmake  -DCMAKE_INSTALL_PREFIX=/home/mboisson/.local/easybuild/software/2020/avx2/Compiler/gcc9/gudhi/3.7.1 -DCMAKE_BUILD_TYPE=Release -DCMAKE_VERBOSE_MAKEFILE=ON -DCMAKE_FIND_USE_PACKAGE_REGISTRY=OFF -DBoost_NO_BOOST_CMAKE=ON -DBOOST_ROOT=/cvmfs/soft.computecanada.ca/easybuild/software/2020/avx2/Compiler/gcc9/boost/1.72.0 -DBoost_NO_SYSTEM_PATHS=ON  -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON  -DENABLE_XHOST=OFF  -DCMAKE_SKIP_INSTALL_RPATH=ON -DPYTHON_EXECUTABLE=$EBROOTPYTHON/bin/python3 .
== 2023-02-16 16:24:42,853 run.py:236 INFO running cmd:  make  -j 8
== 2023-02-16 16:24:54,769 run.py:236 INFO running cmd:  make install  && mkdir -p /home/mboisson/.local/easybuild/software/2020/avx2/Compiler/gcc9/gudhi/3.7.1/lib/python3.10/site-packages && cd python && pip install --no-deps --no-build-isolation --prefix=/home/mboisson/.local/easybuild/software/2020/avx2/Compiler/gcc9/gudhi/3.7.1 .
== 2023-02-16 16:25:09,677 run.py:236 INFO running cmd: tar xzf /home/mboisson/.local/easybuild/sources/g/GUDHI/gudhi.3.7.1.tar.gz
== 2023-02-16 16:25:23,726 run.py:236 INFO running cmd:  cmake   -DCMAKE_INSTALL_PREFIX=/home/mboisson/.local/easybuild/software/2020/avx2/Compiler/gcc9/gudhi/3.7.1 -DCMAKE_BUILD_TYPE=Release -DCMAKE_VERBOSE_MAKEFILE=ON -DCMAKE_FIND_USE_PACKAGE_REGISTRY=OFF -DBoost_NO_BOOST_CMAKE=ON -DBOOST_ROOT=/cvmfs/soft.computecanada.ca/easybuild/software/2020/avx2/Compiler/gcc9/boost/1.72.0 -DBoost_NO_SYSTEM_PATHS=ON  -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON  -DENABLE_XHOST=OFF  -DCMAKE_SKIP_INSTALL_RPATH=ON -DPYTHON_EXECUTABLE=$EBROOTPYTHON/bin/python3 .
== 2023-02-16 16:25:28,600 run.py:236 INFO running cmd:  make  -j 8
== 2023-02-16 16:31:00,989 run.py:236 INFO running cmd:  make install  && mkdir -p /home/mboisson/.local/easybuild/software/2020/avx2/Compiler/gcc9/gudhi/3.7.1/lib/python3.9/site-packages && cd python && pip install --no-deps --no-build-isolation --prefix=/home/mboisson/.local/easybuild/software/2020/avx2/Compiler/gcc9/gudhi/3.7.1 .
== 2023-02-16 16:31:35,739 run.py:236 INFO running cmd: tar xzf /home/mboisson/.local/easybuild/sources/g/GUDHI/gudhi.3.7.1.tar.gz
== 2023-02-16 16:31:49,786 run.py:236 INFO running cmd:  cmake    -DCMAKE_INSTALL_PREFIX=/home/mboisson/.local/easybuild/software/2020/avx2/Compiler/gcc9/gudhi/3.7.1 -DCMAKE_BUILD_TYPE=Release -DCMAKE_VERBOSE_MAKEFILE=ON -DCMAKE_FIND_USE_PACKAGE_REGISTRY=OFF -DBoost_NO_BOOST_CMAKE=ON -DBOOST_ROOT=/cvmfs/soft.computecanada.ca/easybuild/software/2020/avx2/Compiler/gcc9/boost/1.72.0 -DBoost_NO_SYSTEM_PATHS=ON  -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON  -DENABLE_XHOST=OFF  -DCMAKE_SKIP_INSTALL_RPATH=ON -DPYTHON_EXECUTABLE=$EBROOTPYTHON/bin/python3 .
== 2023-02-16 16:31:54,793 run.py:236 INFO running cmd:  make  -j 8
== 2023-02-16 16:37:28,439 run.py:236 INFO running cmd:  make install  && mkdir -p /home/mboisson/.local/easybuild/software/2020/avx2/Compiler/gcc9/gudhi/3.7.1/lib/python3.8/site-packages && cd python && pip install --no-deps --no-build-isolation --prefix=/home/mboisson/.local/easybuild/software/2020/avx2/Compiler/gcc9/gudhi/3.7.1 .
== 2023-02-16 16:38:20,622 run.py:236 INFO running cmd: python -c 'import gudhi'
== 2023-02-16 16:38:34,991 run.py:236 INFO running cmd: python -c 'import gudhi'
== 2023-02-16 16:38:49,693 run.py:236 INFO running cmd: python -c 'import gudhi'
== 2023-02-16 16:39:08,687 run.py:236 INFO running cmd: gcc -v
== 2023-02-16 16:39:08,696 run.py:236 INFO running cmd: ldd --version

This is now with the tests disabled.

from gudhi-devel.

mglisse avatar mglisse commented on June 13, 2024

Actually, testing with python3 -c 'import gudhi; gudhi.pick_n_random_points(points=[], nb_points=0)', I can reproduce the issue with several official packages (conda/pip), but not all. I'll see what I can figure out.

from gudhi-devel.

mglisse avatar mglisse commented on June 13, 2024

Ah, it was starting to ring a bell, and indeed: https://gcc.gnu.org/git/?p=gcc.git;a=commit;h=813ad9c4dd5a779f12ad2abf710c6e75a3117ef0

This was a bug in older versions of gcc. If at all possible, you should use a more recent compiler. If not, look at the file pick_n_random_points.h in gudhi, and change #if __cplusplus >= 201703L to #if 0 to avoid calling this broken code.
The problem only affects strange code (asking for 0 random points from an empty range), so it doesn't seem too bad.

from gudhi-devel.

mboisson avatar mboisson commented on June 13, 2024

Ah, thanks for the pointer. I'll see if we can backport the stdlib patch, or patch to skip this.

I note that the stdlib patch was only integrated in GCC version 11.3.0. Looking at the header files, all of our versions priori to GCC 11 have the same bug.

from gudhi-devel.

mglisse avatar mglisse commented on June 13, 2024

Note that it was backported to other branches, so for instance gcc-9.5 is fine, even 8.5 should work, but you are using an old version (9.3) of gcc-9...

from gudhi-devel.

mboisson avatar mboisson commented on June 13, 2024

Note that it was backported to other branches, so for instance gcc-9.5 is fine, even 8.5 should work, but you are using an old version (9.3) of gcc-9...

Quite possible indeed. Updating a compiler is not a trivial matter on a cluster, so we tend to pick one minor version per major version and stick with it forever.

from gudhi-devel.

mboisson avatar mboisson commented on June 13, 2024

I confirm that building with newer stdlib works. You can close this issue.

from gudhi-devel.

Related Issues (20)

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.