From c945a5d8629bcbd865fe2c1f4d302997647af777 Mon Sep 17 00:00:00 2001 From: Laura Beghini <54085129+Laura2305@users.noreply.github.com> Date: Wed, 20 Sep 2023 12:19:18 +0200 Subject: [PATCH 1/2] Update Project.toml --- Project.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Project.toml b/Project.toml index e77c7da..ea10188 100644 --- a/Project.toml +++ b/Project.toml @@ -33,7 +33,7 @@ DataFrames = "1.6" DataInterpolations = "4" Documenter = "0.27, 1" FileIO = "1" -Images = "0.25" +Images = "0.25, 0.26" MAT = "0.10" MRICoilSensitivities = "0.1" MRIFiles = "0.1" From af8f8a9cfe10364e4f397d2e0efa1be43b42c215 Mon Sep 17 00:00:00 2001 From: Laura Beghini Date: Wed, 4 Oct 2023 13:59:06 +0200 Subject: [PATCH 2/2] update use of connected components functions for compatibility with v0.26 of Images --- src/CoilSensMap.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/CoilSensMap.jl b/src/CoilSensMap.jl index 9d7cee4..dce0495 100644 --- a/src/CoilSensMap.jl +++ b/src/CoilSensMap.jl @@ -78,7 +78,7 @@ function findConnectedComponent!(mask_slice::Array{T,2}) where {T} # Find and keep only the largest connected component in the image components = label_components(mask_slice) measured_area = component_lengths(components) - measured_area = measured_area[2:end] #remove background component + measured_area = measured_area[findfirst(isequal(first(measured_area)), measured_area)+1 : end] #remove background component blob = findmax(measured_area)[2] cartes_index_blob = findall(x -> x!=blob, components) mask_slice[cartes_index_blob] .= 0