20 #define TENSOR_LOAD_IMPL
21 #include <tensor/tensor.h>
25 const CTensor to_complex(
const RTensor &r)
27 CTensor output(r.dimensions());
28 RTensor::const_iterator ir = r.begin();
29 for (CTensor::iterator io = output.begin(); io != output.end(); ++io, ++ir) {
30 *io = to_complex(*ir);
35 const CTensor to_complex(
const RTensor &r,
const RTensor &i)
37 CTensor output(r.dimensions());
38 RTensor::const_iterator ir = r.begin();
39 RTensor::const_iterator ii = i.begin();
40 for (CTensor::iterator io = output.begin(); io != output.end(); ++io, ++ir, +ii) {
41 *io = to_complex(*ir,*ii);