Open jarmitage opened 1 year ago
Someone met the same problem before and it seems old CMake's FindPython.cmake
doesn't look for Python in conda environments. Please upgrade your CMake to 3.17 or higher.
That's interesting, I am using CMake 3.26.1, but it sounds like it could be a similar issue.
I couldn't find any info about how to possibly intervene with FindPython that might help here though https://cmake.org/cmake/help/latest/module/FindPython3.html
Maybe the 'someone' you mentioned might know? Or do you remember anything else about their issue/solution?
Ok, changing this to 3.26 fixed it! Is that what you meant?
Ok, so to run the CI script on macOS using conda and Vulkan only, I had to:
test_config.json
change cmake_args to "cmake_args" : ["-DTI_WITH_CUDA=OFF", "-DTI_WITH_CPU=OFF", "-DMY-PYTHON-VERSION=[insert_conda_python_version]"]
set(CMAKE_PREFIX_PATH "/Users/xxx/.miniconda3/envs/my-env/")
find_package (Python ${MY_PYTHON_VERSION} EXACT REQUIRED)
set(CMAKE_PREFIX_PATH "/Users/xxx/.miniconda3/envs/my-env/")
to the root CMakeFile as well.
When I add this to the CMake file:
I get the correct Python path for my current conda environment.
But, I am getting
ModuleNotFoundError: No module named 'taichi'
errors when runningpython ./ci/run_tests.py -l $TAICHI_C_API_INSTALL_DIR
.