Working on cuda integration