Added cuda implementations