If I install pytorch with conda the relevant cmake files fro find_package are not stored in the default folder that cmake checks. The only way for me to make it work is to specificaly set the CMAKE_PREFIX_PATH.
This is unfortunate as it is python version dependent and any update would require to also change the Cmake file. Is there any way around that? Could the conda package just add the files to the default CMAKE_PREFIX_PATH?
well installing with conda pytorch_cpu the needed cmake files are in anaconda/envs/<env_name>/lib/python3.8/site-packages/torch/share/cmake/
That is not a path that cmake chacks by default as far as I can tell