Declaring Half precision floating point memory in SYCL

For half-precision, you can just use sycl::half as the template parameter for either of these.

accHalf[i] = static_cast<sycl::half>(accFloat[i]);

For copying, you'll need to convert the data from fp32 to fp16, which you could probably do using a kernel to perform the conversion. This seems to be a well documented problem with solutions, see this thread.