@@ -8,7 +8,7 @@ using CUDA, AMDGPU
88using Test
99using CompressedSensingIPM
1010
11- function mastodonte (z0, mask; gpu:: Bool = false , gpu_arch:: String = " cuda" , rdft:: Bool = false )
11+ function mastodonte (z0, mask; lambda :: Float64 = 1.0 , gpu:: Bool = false , gpu_arch:: String = " cuda" , rdft:: Bool = false )
1212 nnz_missing = length (mask) - nnz (vec (mask) |> sparse)
1313 # index_missing = Vector{CartesianIndex{3}}(undef, nnz_missing)
1414 index_missing = Vector {Int} (undef, nnz_missing)
@@ -47,7 +47,6 @@ function mastodonte(z0, mask; gpu::Bool=false, gpu_arch::String="cuda", rdft::Bo
4747 end
4848 index_missing = VI (index_missing)
4949
50- lambda = 1.0
5150 parameters = FFTParameters (DFTdim, DFTsize, z0 |> AT, lambda, index_missing)
5251 nlp = FFTNLPModel {VT} (parameters; rdft, preconditioner= true )
5352
@@ -80,7 +79,8 @@ z0 = read(z0_h5["data"])
8079path_mask_h5 = " mask_template_f_n_s_800_800_200.h5"
8180mask_h5 = h5open (path_mask_h5, " r" )
8281mask = read (mask_h5[" data" ])
83- nlp, solver, results, timer = mastodonte (z0, mask; gpu, gpu_arch, rdft)
82+ lambda = 1.0
83+ nlp, solver, results, timer = mastodonte (z0, mask; lambda, gpu, gpu_arch, rdft)
8484N = length (results. solution) ÷ 2
8585beta_MadNLP = results. solution[1 : N]
8686println (" Timer: $(timer) " )
0 commit comments