Generate theta and phi (and beta and pi) on the device
Create random(gamma) on the device
Merge branch 'master' into theta-on-device