CERN / TIGRE

TIGRE: Tomographic Iterative GPU-based Reconstruction Toolbox
BSD 3-Clause "New" or "Revised" License
560 stars 183 forks source link

updated logic for cuda version selection #340

Closed gfardell closed 2 years ago

gfardell commented 2 years ago

The CUDA_VERSION queried though conda returned a string '9.2.' for me which was unable to convert to a float and failed the logic check. I've converted the check to make it more robust. Although this may be a conda distributed cuda toolkit quirk only.

I've also added:

"-gencode=arch=compute_70,code=compute_70",

to allow runtime forward compilation if the target gpu isn't explicitly built for (this is mostly so we can distribute one version built with cuda 9.2 and be sure it is forward compatible to any gpu.

If you'd prefer not to incorporate these changes I can keep a local fork to build from.

AnderBiguri commented 2 years ago

They are good, as long as they don't break anything else, happy to add whatever helps support the stuff. I'd like to make pip and conda packages too, just not enough time, ugh. So this is very welcomed, thanks! I just have that 1 comment

gfardell commented 2 years ago

Thanks :) and if you have any requests for the conda hosting, for different cuda-toolkit versions or anything let me know. They are in the ccpi channel https://anaconda.org/ccpi/tigre if you want to add it to your distribution notes.