Skip to content

several fixes for SimNIBS 4.6.0 easyconfig - #26579

Open
boegel wants to merge 4 commits into
easybuilders:developfrom
boegel:20260803090040_new_pr_SimNIBS460
Open

several fixes for SimNIBS 4.6.0 easyconfig#26579
boegel wants to merge 4 commits into
easybuilders:developfrom
boegel:20260803090040_new_pr_SimNIBS460

Conversation

@boegel

@boegel boegel commented Aug 3, 2026

Copy link
Copy Markdown
Member

(created using eb --new-pr)

Part 1: Make sure that vendored Eigen is used when building ml-dtypes extension in SimNIBS 4.6.0 easyconfig

fix for problem that manifests like:

  g++ -O1 -march=native -fno-math-errno -fPIC -I/apps/gent/RHEL9/zen5-ib/software/FFTW.MPI/3.3.10-gompi-2023b/include -I/apps/gent/RHEL9/zen5-ib/software/FFTW/3.3.10-GCC-13.2.0/include -I/apps/gent/RHEL9/zen5-ib/software/FlexiBLAS/3.3.1-GCC-13.2.0/include/flexiblas -I/apps/gent/RHEL9/zen5-ib/software/FlexiBLAS/3.3.1-GCC-13.2.0/include -I/apps/gent/RHEL9/zen5-ib/software/OpenMPI/4.1.6-GCC-13.2.0/include -I/apps/gent/RHEL9/zen5-ib/software/LittleCMS/2.15-GCCcore-13.2.0/include -I/apps/gent/RHEL9/zen5-ib/software/OpenJPEG/2.5.0-GCCcore-13.2.0/include -I/apps/gent/RHEL9/zen5-ib/software/freetype/2.13.2-GCCcore-13.2.0/include/freetype2 -I/apps/gent/RHEL9/zen5-ib/software/LibTIFF/4.6.0-GCCcore-13.2.0/include -I/apps/gent/RHEL9/zen5-ib/software/libpng/1.6.40-GCCcore-13.2.0/include -I/apps/gent/RHEL9/zen5-ib/software/libjpeg-turbo/3.0.1-GCCcore-13.2.0/include -I/apps/gent/RHEL9/zen5-ib/software/HDF5/1.14.3-gompi-2023b/include -I/apps/gent/RHEL9/zen5-ib/software/Boost/1.83.0-GCC-13.2.0/include -I/apps/gent/RHEL9/zen5-ib/software/imkl/2023.2.0-gompi-2023b/mkl/2023.2.0/include/fftw -I/apps/gent/RHEL9/zen5-ib/software/imkl/2023.2.0-gompi-2023b/mkl/2023.2.0/include -I/apps/gent/RHEL9/zen5-ib/software/zlib/1.2.13-GCCcore-13.2.0/include -I/apps/gent/RHEL9/zen5-ib/software/MUMPS/5.7.3-foss-2023b-metis-seq/include -I/apps/gent/RHEL9/zen5-ib/software/libwebp/1.3.2-GCCcore-13.2.0/include -I/apps/gent/RHEL9/zen5-ib/software/freeglut/3.4.0-GCCcore-13.2.0/include -I/apps/gent/RHEL9/zen5-ib/software/tbb/2021.13.0-GCCcore-13.2.0/include -I/apps/gent/RHEL9/zen5-ib/software/Python/3.11.5-GCCcore-13.2.0/include -I/apps/gent/RHEL9/zen5-ib/software/Catch2/2.13.9-GCCcore-13.2.0/include -I/apps/gent/RHEL9/zen5-ib/software/Eigen/3.4.0-GCCcore-13.2.0/include -I/apps/gent/RHEL9/zen5-ib/software/pkgconf/2.0.3-GCCcore-13.2.0/include -I/apps/gent/RHEL9/zen5-ib/software/GCCcore/13.2.0/include -fPIC -Ithird_party/eigen -Iml_dtypes -I/apps/gent/RHEL9/zen5-ib/software/SimNIBS/4.6.0-foss-2023b/lib/python3.11/site-packages/numpy/_core/include -I/apps/gent/RHEL9/zen5-ib/software/Python/3.11.5-GCCcore-13.2.0/include/python3.11 -c ml_dtypes/_src/dtypes.cc -o build/temp.linux-x86_64-cpython-311/ml_dtypes/_src/dtypes.o -std=c++17 -DEIGEN_MPL2_ONLY -fvisibility=hidden -ftrapping-math
  In file included from ml_dtypes/_src/dtypes.cc:35:
  ml_dtypes/include/float8.h:871:29: error: ‘get_integer_by_size’ in namespace ‘Eigen::numext’ does not name a template type
    871 |     typename Eigen::numext::get_integer_by_size<kNumBytes>::unsigned_type;
        |                             ^~~~~~~~~~~~~~~~~~~

This didn't happen before because $CPLUS_INCLUDE_PATH was being updated by the Eigen easyblock to include the location to the Eigen header files, but this was changed in:

Note: another fix for this SimNIBS easyconfig will be required, because later on the test step for the sympy extension is failing with:

== 2026-08-02 12:26:26,761 run.py:532 INFO Running shell command in /kyukon/home/gent/400/vsc40023:                                                                                                 export PYTHONPATH=/tmp/eb-7olcfm9h/tmpg0tvv5kf/lib/python3.11/site-packages:$PYTHONPATH && export PATH=/tmp/eb-7olcfm9h/tmpg0tvv5kf/bin:$PATH && export EBPYTHONPREFIXES=/tmp/eb-7olcfm9h/tmpg0tvv5kf:$EBPYTHONPREFIXES &&   ulimit -s 8192 &&   python -s -m pytest -ra --tb=short sympy                                                                                                                                                            
== 2026-08-02 12:26:27,166 run.py:653 WARNING Shell command FAILED (exit code 4)                                                                                                            
Output (stdout + stderr):                                                                                                                                                                   
ERROR: file or directory not found: sympy

That happens because sympy is being installed from a whl file, so there's no unpacked source tarball for sympy, as expected by the test_step method of the sympy easyblock...

This issue went under the radar before because of a bug in the sympy easyblock, which got fixed in:

Part 2: Fix failing test for sympy due to incompatibility with llvmlite 0.45+

========================================================================================== ERRORS ==========================================================================================
sympy/printing/llvmjitcode.py:19: in <module>
    llvm.initialize()
/tmp/vsc40023/software/SimNIBS/4.6.0-foss-2023b/lib/python3.11/site-packages/llvmlite/binding/initfini.py:17: in initialize
    raise RuntimeError(
E   RuntimeError: llvmlite.binding.initialize() is deprecated and will be removed. LLVM initialization is now handled automatically. Please remove calls to this function from your code and check for other behavioral changes that may have o
ccurred due to LLVM updates.
...skipping...

fixed via patch that was applied upstream:

Part 3: RPATH sanity check fails for lib/libgmsh.so.4.14 (WIP)

This occurs because gmsh extension in SimNIBS is installed through binary wheel:

== 2026-08-03 12:36:59,106 build_log.py:330 INFO FAILED: Installation ended unsuccessfully: Sanity check failed: No '(RPATH)' found in 'readelf -d' output for /tmp/vsc40023/software/SimNIBS/4.6.0-foss-2023b/lib/libgmsh.so.4.14 (took 37 mins 29 secs)

I'm not sure how this wasn't a problem before, since the easyconfigs was contributed pretty recently ( #26091)

There's a patchelf command listed in postinstallcmds that works around this, but it was accidentally "disables" by the changes in a follow-up PR (#26181), because of a missing , after the patchelf command...

@boegel

boegel commented Aug 3, 2026

Copy link
Copy Markdown
Member Author

@pavelToman Do you remember why you didn't use a source tarball instead of a pre-built wheel for sympy extension in SimNIBS 4.6.0 easyconfig?

@boegel
boegel marked this pull request as draft August 3, 2026 08:07
@pavelToman

pavelToman commented Aug 3, 2026

Copy link
Copy Markdown
Collaborator

@boegel No strict technical requirement. It was used because PyTorch pins sympy==1.13.1 and the matching pure-Python wheel is available from the PyTorch. It can be switched to the source tarball without changing functionality I hope

@boegel

boegel commented Aug 3, 2026

Copy link
Copy Markdown
Member Author

@boegel No strict technical requirement. It was used because PyTorch pins sympy==1.13.1 and the matching pure-Python wheel is available from the PyTorch. It can be switched to the source tarball without changing functionality I hope

I'm checking if that works right now (installing sympy from source tarball), because changing the sympy easyblock so running the tests when it's being installed from a wheel works isn't trivial...

@boegel

boegel commented Aug 3, 2026

Copy link
Copy Markdown
Member Author

@boegel No strict technical requirement. It was used because PyTorch pins sympy==1.13.1 and the matching pure-Python wheel is available from the PyTorch. It can be switched to the source tarball without changing functionality I hope

I'm checking if that works right now (installing sympy from source tarball), because changing the sympy easyblock so running the tests when it's being installed from a wheel works isn't trivial...

And of course there's one failing tests...

========================================================================================== ERRORS ==========================================================================================
sympy/printing/llvmjitcode.py:19: in <module>
    llvm.initialize()
/tmp/vsc40023/software/SimNIBS/4.6.0-foss-2023b/lib/python3.11/site-packages/llvmlite/binding/initfini.py:17: in initialize
    raise RuntimeError(
E   RuntimeError: llvmlite.binding.initialize() is deprecated and will be removed. LLVM initialization is now handled automatically. Please remove calls to this function from your code and check for other behavioral changes that may have o
ccurred due to LLVM updates.
...skipping...

At least that's a known issue, with a fix:

I'll try applying a patch to the sympy 1.13.1 extension for that...

@boegel boegel changed the title make sure that vendored Eigen is used when building ml-dtypes extension in SimNIBS 4.6.0 easyconfig several fixes for SimNIBS 4.6.0 easyconifg Aug 3, 2026
@boegel boegel changed the title several fixes for SimNIBS 4.6.0 easyconifg several fixes for SimNIBS 4.6.0 easyconfig Aug 3, 2026
@github-actions github-actions Bot added the change label Aug 3, 2026
@boegel
boegel force-pushed the 20260803090040_new_pr_SimNIBS460 branch from 1054ab8 to b92b2ec Compare August 3, 2026 11:42
@boegel boegel removed the change label Aug 3, 2026
@boegel
boegel marked this pull request as ready for review August 3, 2026 17:38
@boegel

boegel commented Aug 3, 2026

Copy link
Copy Markdown
Member Author

@boegelbot please test @ jsc-zen3

@boegel
boegel requested a review from laraPPr August 3, 2026 17:38
@boegelbot

Copy link
Copy Markdown
Collaborator

@boegel: Request for testing this PR well received on jsczen3l1.int.jsc-zen3.fz-juelich.de

PR test command 'if [[ develop != 'develop' ]]; then EB_BRANCH=develop ./easybuild_develop.sh 2> /dev/null 1>&2; EB_PREFIX=/home/boegelbot/easybuild/develop source init_env_easybuild_develop.sh; fi; EB_PR=26579 EB_ARGS= EB_CONTAINER= EB_REPO=easybuild-easyconfigs EB_BRANCH=develop /opt/software/slurm/bin/sbatch --job-name test_PR_26579 --ntasks=8 ~/boegelbot/eb_from_pr_upload_jsc-zen3.sh' executed!

  • exit code: 0
  • output:
Submitted batch job 11086

Test results coming soon (I hope)...

Details

- notification for comment with ID 5169752266 processed

Message to humans: this is just bookkeeping information for me,
it is of no use to you (unless you think I have a bug, which I don't).

@github-actions github-actions Bot added the change label Aug 3, 2026
@boegel

boegel commented Aug 3, 2026

Copy link
Copy Markdown
Member Author

Test report by @boegel
SUCCESS
Build succeeded for 1 out of 1 (total: 2 hours 10 mins 52 secs) (1 easyconfigs in total)
node4401.skiddo.os - Linux RHEL 9.6, x86_64, AMD EPYC 9755 128-Core Processor (zen5), Python 3.9.21
See https://gist.github.com/boegel/54b699616a601739a59a15c287fb97c2 for a full test report.

@boegelbot

Copy link
Copy Markdown
Collaborator

Test report by @boegelbot
SUCCESS
Build succeeded for 1 out of 1 (total: 2 hours 37 mins 29 secs) (1 easyconfigs in total)
jsczen3c1.int.jsc-zen3.fz-juelich.de - Linux Rocky Linux 9.8, x86_64, AMD EPYC-Milan Processor (zen3), Python 3.9.25
See https://gist.github.com/boegelbot/e6fc2e2b896d1fff394de2093c1ba7b2 for a full test report.

@boegel boegel removed the change label Aug 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants