Low-Level Reconstruction

MDFFile
	Study: "FocusField", Dates.DateTime("2014-11-13T16:20:01.217")
	Experiment: "Ph5DotsDF10Overlap0LL (E99)", Dates.DateTime("2014-11-27T14:40:01.280")

In low-level reconstruction we manually supply both the system matrix $\mathbf{S}$ and the preprocessed measurement vector $\mathbf{u}$. As an example we will reproduce a high-level reconstruction with the low-level interface:

params = Dict{Symbol, Any}()
params[:SNRThresh] = 5
params[:sf] = bSF
params[:frames] = 1:acqNumFrames(b)
params[:minFreq] = 80e3
params[:recChannels] = 1:rxNumChannels(b)
params[:iterations] = 1
params[:spectralLeakageCorrection] = true;
params[:reg] = [L2Regularization(0.0f0)]


cHigh = reconstruct("SinglePatch", b; params...);
[ Info: Loading SM
[ Info: Preparing SF
[ Info: Adapting SF

While it is possible to manually invoke the processing steps involved in an algorithms reconstruction, we will instead call the respective procsesing functions of MPIFiles to prepare $\mathbf{u}$:

freqs = filterFrequencies(bSF, SNRThresh = 5, minFreq = 80e3, recChannels = 1:rxNumChannels(b))
u = getMeasurementsFD(b, frames = 1:acqNumFrames(b), frequencies = freqs, spectralLeakageCorrection=true)
316×1×1 Array{ComplexF32, 3}:
[:, :, 1] =
 -30.544167f0 + 237.64691f0im
  49.839363f0 + 6.077115f0im
  103.42677f0 - 200.07315f0im
 -361.64047f0 + 263.4484f0im
  4014.6577f0 - 537.76056f0im
  1381.6943f0 - 503.87634f0im
  4160.1587f0 + 774.6267f0im
  1467.8561f0 + 31.470478f0im
  982.94666f0 + 564.83417f0im
  175.98564f0 + 254.31558f0im
              ⋮
   18.14365f0 - 19.928759f0im
 -3.8579865f0 + 11.583164f0im
  15.987284f0 - 16.056135f0im
   6.190239f0 - 10.057348f0im
   -2.49429f0 + 15.494686f0im
 -13.097083f0 + 27.7542f0im
 0.17072822f0 + 9.907414f0im
 0.41215464f0 + 0.21798661f0im
 -1.2570407f0 + 0.77176857f0im

And afterwards use MPIRecos utility functions to prepare $\mathbf{S}$:

sparseTrafo = nothing
S, grid = getSF(bSF, freqs, sparseTrafo, Kaczmarz)
typeof.([S, grid])
2-element Vector{DataType}:
 LinearAlgebra.Transpose{ComplexF32, Matrix{ComplexF32}}
 RegularGridPositions{Float64}

Now we can configur a low-level reconstruction:

cLow = reconstruct("LowLevel", u; S = S, iterations = params[:iterations], reg = params[:reg])
1024×1 Matrix{Float64}:
 0.0
 0.00020932727784384042
 0.0
 2.7252777726971544e-5
 0.00021386408479884267
 0.0
 0.0
 0.0
 0.0
 0.0005012618494220078
 ⋮
 0.0
 0.0
 0.0
 0.0
 0.0
 0.0
 0.0
 0.0
 0.0

Note that the low-level reconstruction returns a matrix without any metadata unlike the other reconstructions. The second dimension of the result matrix are the frames. To compare and plot our data we have to reshape it:

sliceLow = sliceLow = reshape(cLow[:, 1], Tuple(grid.shape))
fig = Figure();
hidedecorations!(heatmap(fig[1, 1], cHigh[1, :, :, 1, 1].data.data, axis = (title = "High",)).axis)
hidedecorations!(heatmap(fig[1, 2], sliceLow[:, :, 1], axis = (title = "Low",)).axis)
fig
Example block output

This page was generated using Literate.jl.