UCL / STIR

Software for Tomographic Image Reconstruction
http://stir.sourceforge.net/
Other
104 stars 89 forks source link

openmp changes to allow projection matrix parallelisation #458

Open KrisThielemans opened 4 years ago

KrisThielemans commented 4 years ago

At present, for SPECTUB there is a problem that when doing forward projection, gradient calculations etc, the code wants to use multi-threading, but the SPECTUB matrix cannot (unless all views are cached, but it is then still very ineffective).

On the other hand, the matrix calculation itself could be parallelisable.

One way to achieve this would be to

Another advantage of this would be that it would enable MPI/GPU and OPENMP to be used together.

CMake variables would need to be set in src/CMakeLists.txt and cmake/STIRConfig.h.in

danieldeidda commented 4 years ago

should the BinNormalisation also use STIR_OPENMP_PROJECTIONS?

KrisThielemans commented 4 years ago

not sure if there's any openmp in there (maybe in the ...FromAttenuationImage one?) But as these are not using distributable_computation, we wouldn't have a conflict anyway. so, the answer is no.

maybe we should rename this to STIR_OPENMP_DISTRIBUTABLE, but that won't be terribly clear for users. suggestions welcome.