Updated modules in find_package command for Python3 - #933
Conversation
|
https://cmake.org/cmake/help/latest/module/FindPythonInterp.html deprecated since 3.12, while we require 3.16.2. Current change is minimal. We probably should pass |
|
Need to update how we look for cython I guess This error is different from why I saw in #932 but it's possible that @NicoleJurjew only saw the Tomophantom error when using this branch I guess. |
|
With the suggested changes, the PYTHONPATH isn't exported correctly. I think some changes need to be done here, as well: |
|
that's a bit strange. What is the content of env_sirf.sh etc then? Can you just do a message(STATUS "PYTHON_EXECUTABLE=${PYTHON_EXECUTABLE}")before those statement to check what it is? |
3f09077 to
f5d9c0c
Compare
|
Looks like a gadgetron build error related to https://groups.google.com/g/linux.debian.bugs.dist/c/JpHAw3GY0Bk |
|
This was all discussed in #937. I've contributed a PR to Gadgetron. However, moving on with Gadgetron created a lot of other problems. So @paskino and I decided to wait with that, and just fix Ubuntu 22.04. This is done in #943. So suggestion therefore is to finish #943, merge it, and merge that back on here. |
KrisThielemans
left a comment
There was a problem hiding this comment.
Did you check if the dependencies indeed accept Python3_EXECUTABLE. In any case, I'm fairly sure this needs to be Python_EXECUTABLE. Easiest might be to pass both of course, although that's a bit ugly.
Also, in SIRF and STIR, we have a "backwards compatible" line to set Python_EXECUTABLE if PYTHON_EXECUTABLE is set. Maybe no longer need it?
|
@casperdcl I've merged #943. Note that we'll also need to update CHANGES.md here. |
f5d9c0c to
15b6504
Compare
| -DPython_EXECUTABLE=${NiftyPET_PYTHON_EXECUTABLE} | ||
| -DPython3_Executable=${NiftyPET_PYTHON_EXECUTABLE} |
There was a problem hiding this comment.
note that we are stuck to NiftyPET 2. Are you sure this is ok?
There was a problem hiding this comment.
Any reason why? Current NiftyPET is Python3 only.
There was a problem hiding this comment.
We currently only use NiftyPET via STIR, but that all happens on the C++ front. NiftyPET3 no longer has the appropriate libraries, and I have no energy for it.
See UCL/STIR#1294 to jog your memory :-)
There was a problem hiding this comment.
It could be worthwile wrapping NiftyPET in CIL instead, but it's nowhere on my (our?) list of priorities.
|
There seem to be 2 different Python versions used in the CIL install, resulting in the For the SB, CMake finds a surprising version (which is then passed on) The CMake strategy for selecting a python version is still far too complicated/error-prone. I suggest therefore to explicitly set In addition, it looks like the CIL version that is being built (I only checked with I think therefore we need to add |
9e2e844 to
c4bacd6
Compare
when building TomoPhantom. Not sure why this happens now? Wrong python used? TBH, We shouldn't really build TomoPhantom as part of our CI I think. @paskino ? I guess we have a problem with the naming somewhere. |
2e56611 to
9fa54cf
Compare
|
Current test failures due to lack of CIL deps... CIL:scripts/requirements-test.yml are not included in CIL:pyproject.toml and I think they should be. I've opened TomographicImaging/CIL#2116 |
ed81a12 to
74fd9cb
Compare
This is still the case, hence the failures. |
3569455 to
72b5111
Compare
|
Ah I finally understood; you don't want to use the system Python. TL;DR we need to unset the cmake helpers defined by |
cd45e61 to
1cbc258
Compare
pretty confusing... I don't care which python is being used here, but obviously we should always use the same. As we seem to be using Sadly, some zenodo download issues ATM. |
KrisThielemans
left a comment
There was a problem hiding this comment.
oh. still need to update CHANGES.md!
|
Success! Thanks @casperdcl . however, can you now have a different PR to update CHANGES.md, saying that we've switched to FindPython (maybe a link), and that they should use |
|
Already updated the changelog; feel free to update further |
|
Sorry. Confused. Which changelog? |

No description provided.