clarified sino_sparsity

Sun, 21 Apr 2024 18:55:00 +0300

author
Neil Dizon <neil.dizon@helsinki.fi>
date
Sun, 21 Apr 2024 18:55:00 +0300
changeset 19
7c4dfeb48dd9
parent 18
e6a2ebaf467d
child 20
7d3a75b875fa

clarified sino_sparsity

src/PET/ImGenerate.jl file | annotate | diff | comparison | revisions
src/PET/PET.jl file | annotate | diff | comparison | revisions
--- a/src/PET/ImGenerate.jl	Sun Apr 21 18:45:09 2024 +0300
+++ b/src/PET/ImGenerate.jl	Sun Apr 21 18:55:00 2024 +0300
@@ -117,8 +117,8 @@
 function generate_radonmask(params)
     imdim = params.radondims
     sino_sparse = params.sino_sparsity
-    numone = Int64(round(sino_sparse*imdim[1]*imdim[2]))
-    numzero = imdim[1]*imdim[2]-numone
+    numzero = Int64(round(sino_sparse*imdim[1]*imdim[2]))
+    numone = imdim[1]*imdim[2]-numzero
     A = shuffle(rng,reshape([ones(numone); zeros(numzero)],(imdim[1],imdim[2])))
     return A
 end
--- a/src/PET/PET.jl	Sun Apr 21 18:45:09 2024 +0300
+++ b/src/PET/PET.jl	Sun Apr 21 18:55:00 2024 +0300
@@ -123,7 +123,7 @@
     sz = (256,256),
     scale = 1,
     c = 1.0,
-    sino_sparsity = 0.5,
+    sino_sparsity = 0.5,            # Percentage of zero parts in the mask
     L = 300.0,
     L_experiment = false,
     stable_interval = union(Set(1500:2000),Set(3500:4000)),

mercurial