I pushed the changes.
I ended up making a class instance instead of using two global functions, in order to reduce pollution of the namespace when importing. I am also depending on the GIL to ensure that the assignment of the device to the class variable is atomic.
|