PetaVision / OpenPV

PetaVision is a C++ library for designing and deploying large-scale neurally-inspired computational models.
http://petavision.github.io
Eclipse Public License 1.0
40 stars 13 forks source link

MPI processes create CUDA devices serially #229

Closed peteschultz closed 7 years ago

peteschultz commented 7 years ago

This pull requests addresses an issue where several MPI processes creating CUDA devices simultaneously could cause CUDA functions to fail. When run under MPI, the CudaDevice constructor is called in a loop synchronized by MPI_Barrier, and each process creates the device only when the loop counter is equal to its global rank.