Skip to content

Commit

Permalink
remove QSM dependency;
Browse files Browse the repository at this point in the history
clearswiApp uses QSM.jl RTS, since it is a lighter dependency
  • Loading branch information
korbinian90 committed Dec 5, 2023
1 parent 8015c55 commit 77ae479
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 10 deletions.
4 changes: 1 addition & 3 deletions Project.toml
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
name = "CLEARSWI"
uuid = "06ae4d9b-ce5e-4813-a1b3-426e46312ec2"
authors = ["Korbinian Eckstein"]
version = "1.2.0"
version = "1.3.0"

[deps]
ArgParse = "c7e460c6-2fb9-53a9-8c5b-16f535851c63"
MriResearchTools = "557dad86-b9bd-4533-8525-1a39684d020f"
QuantitativeSusceptibilityMappingTGV = "bd393529-335a-4aed-902f-5de61cc7ff49"
Statistics = "10745b16-79ce-11e8-11f9-7d13ad32a3b2"

[weakdeps]
Expand All @@ -18,5 +17,4 @@ ClearswiApp = "ArgParse"
[compat]
ArgParse = "1"
MriResearchTools = "3.1"
QuantitativeSusceptibilityMappingTGV = "0.2"
julia = "1.7"
7 changes: 5 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ phase_hp_sigma=[4,4,0]
phase_scaling_type=:tanh
phase_scaling_strength=4
writesteps=nothing
qsm=false
```

* `mag_combine` selects the echo combination for the magnitude. Options are
Expand All @@ -118,6 +119,8 @@ writesteps=nothing

* Set `writesteps` to the path, where intermediate steps should be saved, e.g. `writesteps="/tmp/clearswi_steps"`. If set to `nothing`, intermediate steps won't be saved.

* [Experimental] Set `qsm` to true to use QSM processing for the phase contrast. This requires the additional use of a QSM package. Supported are either [`QSM`](https://github.com/kamesy/QSM.jl) or [`QuantitativeSusceptibilityMappingTGV`](https://github.com/korbinian90/QuantitativeSusceptibilityMappingTGV.jl). Before setting this option, you need load one of these packages with `using`.

### Calculating T2* and B0 maps on multi-echo datasets

T2* and B0 maps can be calculated using the package [MriResearchTools](https://github.com/korbinian90/MriResearchTools.jl):
Expand Down Expand Up @@ -161,7 +164,7 @@ usage: <PROGRAM> [-m MAGNITUDE] [-p PHASE] [-o OUTPUT]
[-e ECHOES [ECHOES...]] [-N] [--no-phase-rescale]
[--writesteps WRITESTEPS] [-v] [--version] [-h]
3.6.4
4.0.4
optional arguments:
-m, --magnitude MAGNITUDE
Expand All @@ -173,7 +176,7 @@ optional arguments:
The echo times are required for multi-echo
datasets specified in array or range syntax
(eg. "[1.5,3.0]" or "3.5:3.5:14").
--qsm When activated uses TGV-QSM for phase weighting
--qsm When activated uses RTS QSM for phase weighting
--mag-combine MAG-COMBINE [MAG-COMBINE...]
SNR | average | echo <n> | SE <te>. Magnitude
combination algorithm. echo <n> selects a
Expand Down
6 changes: 3 additions & 3 deletions clearswi.jl
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import Pkg
Pkg.activate(@__DIR__)
try
using CLEARSWI, ArgParse
using CLEARSWI, QSM, ArgParse
catch
Pkg.add(["CLEARSWI", "ArgParse"])
using CLEARSWI, ArgParse
Pkg.add(["CLEARSWI", "QSM", "ArgParse"])
using CLEARSWI, QSM, ArgParse
end

@time msg = clearswi_main(ARGS)
Expand Down
2 changes: 1 addition & 1 deletion ext/ClearswiApp/argparse.jl
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ function getargs(args::AbstractVector, version)
"3.5:3.5:14")."""
nargs = '+'
"--qsm"
help = """When activated uses TGV-QSM for phase weighting
help = """When activated uses RTS QSM for phase weighting.
"""
action = :store_true
"--mag-combine"
Expand Down
1 change: 0 additions & 1 deletion src/CLEARSWI.jl
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
module CLEARSWI

using MriResearchTools
using QuantitativeSusceptibilityMappingTGV
using Statistics

include("tissue.jl")
Expand Down

0 comments on commit 77ae479

Please sign in to comment.