noir/recon.c: rename img to x
since img in that case was actually the image and the coils together.
It now reflects standard usage: x is the variable optimized by the
IRGNM.
@@ -68,15 +68,16 @@ void noir_recon(const struct noir_conf_s* conf, const long dims[DIMS], complex f
long data_size = md_calc_size(DIMS, data_dims);
long d1[1] = { size };
- complex float* img = md_alloc_sameplace(1, d1, CFL_SIZE, kspace);
+ // variable which is optimized by the IRGNM
+ complex float* x = md_alloc_sameplace(1, d1, CFL_SIZE, kspace);
- md_clear(DIMS, imgs_dims, img, CFL_SIZE);
+ md_clear(DIMS, imgs_dims, x, CFL_SIZE);
md_zfill(DIMS, img1_dims, outbuf, 1.); // initial only first image
- md_copy(DIMS, img1_dims, img, outbuf, CFL_SIZE);
+ md_copy(DIMS, img1_dims, x, outbuf, CFL_SIZE);
- md_clear(DIMS, coil_dims, img + skip, CFL_SIZE);
+ md_clear(DIMS, coil_dims, x + skip, CFL_SIZE);
struct noir_model_conf_s mconf = noir_model_conf_defaults;
mconf.rvc = conf->rvc;
@@ -96,21 +97,21 @@ void noir_recon(const struct noir_conf_s* conf, const long dims[DIMS], complex f
iter4_irgnm(CAST_UP(&irgnm_conf),
nlop,
- size * 2, (float*)img, NULL,
+ size * 2, (float*) x, NULL,
data_size * 2, (const float*)kspace);
- md_copy(DIMS, imgs_dims, outbuf, img, CFL_SIZE);
+ md_copy(DIMS, imgs_dims, outbuf, x, CFL_SIZE);
if (NULL != sensout) {
assert(!conf->usegpu);
- noir_forw_coils(noir_get_data(nlop), sensout, img + skip);
+ noir_forw_coils(noir_get_data(nlop), sensout, x + skip);
fftmod(DIMS, coil_dims, fft_flags, sensout, sensout);
}
nlop_free(nlop);
- md_free(img);
+ md_free(x);
}
