     }
 }
 
-void read_float_blob(const char* fn, thrust::host_vector<cuFloatComplex>& b)
+void read_complex_float_blob(const char* fn, thrust::host_vector<cuFloatComplex>& b)
 {
     std::fstream f(fn, std::ios_base::in | std::ios_base::binary);
     if(!f.read(reinterpret_cast<char*>(b.data()), b.size() * sizeof(float) * 2))

            }
        } destroy_plan(plan);

        if(cufftExecR2C(plan, thrust::raw_pointer_cast(im_d_in.data()), thrust::raw_pointer_cast(im_d_out.data())) != CUFFT_SUCCESS)
        {
            throw std::string("cuff2ExecR2C(..) failed.");
        }

        thrust::host_vector<cuFloatComplex> im_h_out(im_d_out);

    try
    {
        std::size_t im_size(2560 * 2160);
        thrust::host_vector<cuFloatComplex> im_h_in(im_size);
        read_complex_float_blob("/home/ehvatum/zplrepo/wautofocuser/build/in.complexfloatblob", im_h_in);
        thrust::device_vector<cuFloatComplex> im_d_in(im_h_in);

        cufftHandle plan;
        if(cufftPlan2d(&plan, 2160, 2560, CUFFT_C2C) != CUFFT_SUCCESS)
        {
            throw std::string("cufftPlan2d(..) failed.");
        }
