smoothing a changed to device function, renamed stokes output