GithubHelp home page GithubHelp logo

romeo's Issues

ReadOnlyMemoryError()

Thanks for sharing the Unwrapping software @korbinian90,

I would love to try it on my NeuroDebian installation on my 0.2mm FLASH data.
Unfortunately, I get the error below:
I used it like this: romeo -m manitude.nii -o outputname.nii phasedata.nii
can you point me to any documentation of romeo's usage?
Do you have example data that I could use to see if the installation worked correctly?

Thanks a lot.
Renzo

ERROR: ReadOnlyMemoryError() Stacktrace: [1] setindex! at ./array.jl:825 [inlined] [2] setindex! at ./subarray.jl:289 [inlined] [3] _setindex! at ./abstractarray.jl:1096 [inlined] [4] setindex! at ./abstractarray.jl:1073 [inlined] [5] macro expansion at ./broadcast.jl:910 [inlined] [6] macro expansion at ./simdloop.jl:77 [inlined] [7] copyto! at ./broadcast.jl:909 [inlined] [8] copyto! at ./broadcast.jl:864 [inlined] [9] materialize!(::SubArray{Int16,3,Array{Int16,4},Tuple{Base.Slice{Base.OneTo{Int64}},Base.Slice{Base.OneTo{Int64}},Base.Slice{Base.OneTo{Int64}},Int64},true}, ::Base.Broadcast.Broadcasted{Base.Broadcast.DefaultArrayStyle{3},Nothing,typeof(*),Tuple{SubArray{Int16,3,Array{Int16,4},Tuple{Base.Slice{Base.OneTo{Int64}},Base.Slice{Base.OneTo{Int64}},Base.Slice{Base.OneTo{Int64}},Int64},true},BitArray{3}}}) at ./broadcast.jl:823 [10] parsekwargs(::Base.Iterators.Pairs{Symbol,AbstractArray{T,3} where T,Tuple{Symbol,Symbol},NamedTuple{(:mag, :mask),Tuple{SubArray{Int16,3,Array{Int16,4},Tuple{Base.Slice{Base.OneTo{Int64}},Base.Slice{Base.OneTo{Int64}},Base.Slice{Base.OneTo{Int64}},Int64},true},BitArray{3}}}}, ::Array{Float32,3}) at /home/korbinian90/.julia/dev/ROMEO/src/weights.jl:104 [11] calculateweights_romeo(::Array{Float32,3}, ::Int64, ::BitArray{1}, ::Type{UInt8}; kwargs::Base.Iterators.Pairs{Symbol,AbstractArray{T,3} where T,Tuple{Symbol,Symbol},NamedTuple{(:mag, :mask),Tuple{SubArray{Int16,3,Array{Int16,4},Tuple{Base.Slice{Base.OneTo{Int64}},Base.Slice{Base.OneTo{Int64}},Base.Slice{Base.OneTo{Int64}},Int64},true},BitArray{3}}}}) at /home/korbinian90/.julia/dev/ROMEO/src/weights.jl:45 [12] calculateweights_romeo(::Array{Float32,3}, ::Symbol, ::Int64; kwargs::Base.Iterators.Pairs{Symbol,AbstractArray{T,3} where T,Tuple{Symbol,Symbol},NamedTuple{(:mag, :mask),Tuple{SubArray{Int16,3,Array{Int16,4},Tuple{Base.Slice{Base.OneTo{Int64}},Base.Slice{Base.OneTo{Int64}},Base.Slice{Base.OneTo{Int64}},Int64},true},BitArray{3}}}}) at /home/korbinian90/.julia/dev/ROMEO/src/weights.jl:41 [13] calculateweights(::Array{Float32,3}, ::Symbol, ::Int64; kwargs::Base.Iterators.Pairs{Symbol,AbstractArray{T,3} where T,Tuple{Symbol,Symbol},NamedTuple{(:mag, :mask),Tuple{SubArray{Int16,3,Array{Int16,4},Tuple{Base.Slice{Base.OneTo{Int64}},Base.Slice{Base.OneTo{Int64}},Base.Slice{Base.OneTo{Int64}},Int64},true},BitArray{3}}}}) at /home/korbinian90/.julia/dev/ROMEO/src/weights.jl:21 [14] unwrap!(::Array{Float32,3}; weights::Symbol, keyargs::Base.Iterators.Pairs{Symbol,AbstractArray{T,3} where T,Tuple{Symbol,Symbol},NamedTuple{(:mag, :mask),Tuple{SubArray{Int16,3,Array{Int16,4},Tuple{Base.Slice{Base.OneTo{Int64}},Base.Slice{Base.OneTo{Int64}},Base.Slice{Base.OneTo{Int64}},Int64},true},BitArray{3}}}}) at /home/korbinian90/.julia/dev/ROMEO/src/unwrapping.jl:4 [15] unwrapping_main(::Array{String,1}) at /home/korbinian90/.julia/dev/RomeoApp/src/caller.jl:72 [16] julia_main() at /home/korbinian90/.julia/dev/RomeoApp/src/RomeoApp.jl:14 [17] julia_main() at ./none:29

ROMEO run in matlab

Hi,
I am trying to run romeo for phase unwrapping via Matlab. I downloaded mritools V3.6.6. But when I run example_ROMEO_call.m file according my data, it gives an error:

Error using ROMEO
ROMEO unwrapping failed! Check input files for corruption in /N/project/dMRI1/CARE_CSI/ANALYSIS/QSM/temp/Tina/mritools_ubuntu/bin/romeo_tmp.

image

Could you please help me to fix it.

Thank you.

Matlab run ROMEO error

Hello:
I plan to carry out phase unwrapping through ROMEO, but the following errors are reported during operation (my matlab version is R2020a, mritools windows is v4.0.2) :

_ROMEO command: "C:\Users\wang\Desktop\my_QSM_calc\mritools_windows-2019_4.0.2\matlab..\bin\romeo.exe" "-p" "C:\Users\wang\Desktop\my_QSM_calc\Head_QSM_193459\QSM_results\phase_unwapping\Phase.nii" "-o" "C:\Users\wang\Desktop\my_QSM_calc\Head_QSM_193459\QSM_results\phase_unwapping\Unwrapped.nii" "-B" "-m" "C:\Users\wang\Desktop\my_QSM_calc\Head_QSM_193459\QSM_results\phase_unwapping\Mag.nii" "-t" "[6.8 14 21.2 28.4 35.6]" "-k" "C:\Users\wang\Desktop\my_QSM_calc\Head_QSM_193459\QSM_results\phase_unwapping\Mask.nii" --verbose -q
fatal: error thrown and no exception handler available.
InitError(mod=:GPUCompiler, error=ErrorException("type Nothing has no field major"))
ijl_errorf at C:/workdir/src\rtutils.c:77
ijl_has_no_field_error at C:/workdir/src\rtutils.c:137
getproperty at .\Base.jl:37
init at C:\Users\runneradmin.julia\packages\GPUCompiler\2mJjc\src\GPUCompiler.jl:64
jfptr___init___99249.clone_1 at C:\Users\wang\Desktop\my_QSM_calc\mritools_windows-2019_4.0.2\lib\julia\sys.dll (unknown line)
jl_apply at C:/workdir/src\julia.h:1880 [inlined]
jl_module_run_initializer at C:/workdir/src\toplevel.c:75
_finish_julia_init at C:/workdir/src\init.c:855
ijl_init_with_image at C:/workdir/src\jlapi.c:66 [inlined]
ijl_init_with_image at C:/workdir/src\jlapi.c:55 [inlined]
ijl_init at C:/workdir/src\jlapi.c:82
.text at C:\Users\wang\Desktop\my_QSM_calc\mritools_windows-2019_4.0.2\bin\romeo.exe (unknown line)
__tmainCRTStartup at C:\Users\wang\Desktop\my_QSM_calc\mritools_windows-2019_4.0.2\bin\romeo.exe (unknown line)
.l_start at C:\Users\wang\Desktop\my_QSM_calc\mritools_windows-2019_4.0.2\bin\romeo.exe (unknown line)
BaseThreadInitThunk at C:\Windows\System32\KERNEL32.DLL (unknown line)
RtlUserThreadStart at C:\Windows\SYSTEM32\ntdll.dll (unknown line)
错误使用 ROMEO (line 89)
Something went wrong!
Please also try if ROMEO works via the command line.
Otherwise, please report the issue on https://github.com/korbinian90/ROMEO/issues

出错 Format_conversion (line 123)
[unwrapped, B0] = ROMEO(Phase_nii.img, parameters);_

I run romeo.exe on the command line to get the same error, what should I do next, thank you.

Push to Docker Hub

This stems from #3 (comment). It would be helpful (especially for OSX usage) to add a Dockerfile and push automatically to Docker Hub (https://hub.docker.com). Singularity users can also build from Docker Hub images, so that would help them as well.

Matlab example data files not included?

Just getting started with ROMEO and running it under Matlab. Appreciate that there is a way to do this!

Example_ROMEO_call.m calls for Phase.nii, Magnitude.nii, and Mask.nii? These are not included anywhere? Maybe they are not supposed to be included?

In any event, I will figure out how to take my data and turn it into these files.

Thanks for putting this together and making it available.

Problem with coil combination using the romeo binary

Thanks for this nice unwrapping tool.

I have a problem when I run the romeo binary with 5D magnitude and phase data (2-echo scans). The coil combination seems to be not working correctly as the combined magnitude images lose all contrast and are very noisy.

If I do a 2 step unwrapping, running the mcpc3ds binary first, the coil combined images look fine.
These are my command line inputs:
1 step:
bin/romeo -p phs.nii.gz -m mag.nii.gz --no-rescale -B -t [2.42,4.84] -o .
2 step:
bin/mcpc3ds -m mag.nii.gz -p phs.nii.gz -t [2.42,4.84] --no-phase-rescale -o .
bin/romeo -p combined_phase.nii -m combined_mag.nii --no-rescale -B -t [2.42,4.84] -o .

mag.nii.gz and phs.nii.gz are both 5D images [x,y,z,echo,coil].

I am using the standalone executables.

Version report

Just a little thing: the last few versions have all claimed to be v3.1.0
$ v3.1.4/bin/romeo --version
v3.1.0

AssertionError()

Hello @korbinian90,
First of all, I would like to acknowledge the amazing unwrapping tool you guys developed!

I was trying to use it in some single-echo fMRI data that I need to analyze. However, I appear to get an error when using it with a binary mask file. It works fine without a mask or with the "robustmask" option. Do you have any idea why does the error arise?

Thank you very much! Cheers.
Iñigo

Here is the code I used: romeo -m magnitude.nii -o unwrapped.nii -k mask_file.nii phase.nii
And here is the error I get:
ERROR: AssertionError: Unwrap-weights are all zero! Stacktrace: [1] unwrap!(::SubArray{Float32,3,Array{Float32,4},Tuple{Base.Slice{Base.OneTo{Int64}},Base.Slice{Base.OneTo{Int64}},Base.Slice{Base.OneTo{Int64}},Int64},true}; weights::Symbol, keyargs::Base.Iterators.Pairs{Symbol,AbstractArray,NTuple{4,Symbol},NamedTuple{(:TEs, :phase2, :mag, :mask),Tuple{Array{Int64,1},Array{Float32,3},Array{Int16,3},BitArray{3}}}}) at /home/korbinian90/.julia/dev/ROMEO/src/unwrapping.jl:5 [2] unwrap!(::Array{Float32,4}; TEs::UnitRange{Int64}, template::Int64, p2ref::Int64, keyargs::Base.Iterators.Pairs{Symbol,Any,Tuple{Symbol,Symbol,Symbol},NamedTuple{(:weights, :mag, :mask),Tuple{Symbol,SubArray{Int16,4,Array{Int16,4},Tuple{Base.Slice{Base.OneTo{Int64}},Base.Slice{Base.OneTo{Int64}},Base.Slice{Base.OneTo{Int64}},UnitRange{Int64}},true},BitArray{3}}}}) at /home/korbinian90/.julia/dev/ROMEO/src/unwrapping.jl:55 [3] unwrapping_main(::Array{String,1}) at /home/korbinian90/.julia/dev/RomeoApp/src/caller.jl:76 [4] julia_main() at /home/korbinian90/.julia/dev/RomeoApp/src/RomeoApp.jl:14 [5] julia_main() at ./none:29

Phase Contrast Imaging

Hi Korbinian,
Moving the dialog here....the clear SWI portion of things is all resolved. I've moved the newer ROMEO & Laplacian unwrapping stuff here, so you can close the SWI part at your leisure. Right now your answer to the question below is still in the SWI part.

Encountering an error with a multi-echo data set

Dear Korbinian,

I am encountering an issue with running ROMEO on a multi-echo data set, as it throws the error:
"ERROR: AssertionError: Unwrap-weights are all zero!"

If I run ROMEO on individual echoes from this data set, it works fine, so this issue is limited to the multi-echo combination procedure.
I tested ROMEO on this data set using both the MRITools and Neurodesk implementations, obtaining the same error.
As a further test, I successfully ran ROMEO on a different multi-echo data set (in Neurodesk). Thus, this is not an installation issue but something specific to this one data set.

I would appreciate your input on this!

Thanks,
Emma

Romeo binary associated with virus

In case anybody experiences the same issue, when I unpacked the Windows binaries, the romeo.exe file was always missing. Reason was that my antivirus (Clam Sentinel) was mistaking it for a virus. White-list a folder and the file can be extracted there. Not much you can do about it, but at least the problem is known.

question about units

What units are the unwrapped phase in? I sent in phase images with values ranging from 0 to 4095.
Output values ranged from -169.820160 to 195.847427.
I'm guessing that the range is some multiple of pi radians, but I would appreciate some specificity.
Apologies in advance if the answer is in the documentation and I was too lazy to find it.

Applicability to data with large gaps between echo times

I'm not sure if you'd prefer users to open usage-related issues here or post them somewhere like NeuroStars, but I figured I'd try here first. I was interested in applying ROMEO to multi-echo fMRI data, which has relatively large gaps in echo times. I have four echoes with TEs of 11.8, 28.04, 44.28, and 60.52 ms. I tested out ROMEO on my data after scaling my phase data to radians, but the results look odd to me. I wonder if perhaps the spacing between the echo times is just too large?

Here's how I called ROMEO:

romeo -m /tmp/temp/bold_v0010.nii -t [11.8,28.04,44.28,60.52] -Bvq -o /tmp/ /tmp/temp/pha_v0010.nii

The resulting unwrapped echoes mostly look like the below:

I'd appreciate any help you could provide. I should note that I'm not exactly an expert on phase data, unwrapping, or distortion correction, though.

Does not support phase difference input?

Thanks for this handy tool.

If I use -p phase_diff.nii (only 2D matrix inside), it would complain. Although at the beginning the doc says need 4D nifti, later the doc says we can input phase difference data. Am I missing something here?

This might be necessary for phase difference data,

error when trying to use phase difference data.

ERROR: BoundsError: attempt to access Tuple{Int64, Int64} at index [3]
Stacktrace:
[1] getindex
@ .\tuple.jl:29 [inlined]
[2] getindex(t::Tuple, r::UnitRange{Int64})
@ Base .\range.jl:313
[3] load_data_and_resolve_args!(settings::Dict{String, Any})
@ RomeoApp C:\Users\runneradmin.julia\packages\RomeoApp\xDyvE\src\caller.jl:78
[4] unwrapping_main(args::Vector{String}; version::String)
@ RomeoApp C:\Users\runneradmin.julia\packages\RomeoApp\xDyvE\src\caller.jl:3
[5] julia_main(version::String)
@ RomeoApp C:\Users\runneradmin.julia\packages\RomeoApp\xDyvE\src\RomeoApp.jl:12
[6] romeo()
@ App D:\a\CompileMRI.jl\CompileMRI.jl\App\src\App.jl:9
[7] top-level scope
@ none:1

Question about temporal coherence

I have a question regarding the temporal coherence that characterises ROMEO.
Does it make sense to use ROMEO with the temporal coherence ON for a set of images that consists of a FLASH image and a EPI image?

And in that case what are the echo times that should be passed? I would guess the following times

  • for the FLASH: the time from the RF pulse until half of the 1st readout
  • for the EPI: the time from the RF pulse until half of the whole sequence train (when half the k-space has been acquired)

Build crashes with "wrong argument formatting! too many arguments"

I've followed the build instructions in the related repo. After a fairly long build process, what I presume is a test is run:

./romeo/bin/romeo /some/path/to/romeo/julia-packages/dev/CompileMRI/test/data/small/Phase.nii -o /tmp/jl_OnIrwFyvaj -t 1:3 -k nomask

This results in

wrong argument formatting!
too many arguments

Causing the build (test?) process to abort.

The issue is that there is no -p flag placed before the filename

Name of the shared library

In the "Issues when calling from MATLAB" section, it says the library name should be "libstc++.so".
That library doesn't exist, but "libstdc++.so" exists and loading that library solved the problem.
Thank you for making the program available.

Unpublished version is the only one that works for my data

Hi,

Our group has been using ROMEO in an MS clinical study for QSM phase unwrapping and it usually works well. However, for a handful of subjects, all the currently downloadable versions leave some residual wraps in the total field map. Interestingly, I got another version ages ago from Barbara Dymerska (called ROMEO_20200130_compiled_win) which works perfectly even in these cases. We have contacted Barbara and she advised that "it looks like some voxel close to the sinuses acts as a tipping point: it may still have relatively high quality value in the quality map and in one case algorithm goes through this voxel slightly earlier than in the other case. The difference can be as small as just slightly different numerical approximation. But it’s worth checking if there is a slight difference in ROMEO weights between this version and the next one." She also suggested that we check the newest version with -k nomask as there was a bug in some of the earlier versions resulting in no mask being used even when -k robustmask was set. We have tried every masking option across a handful of versions without success. We could just continue using ROMEO_20200130_compiled_win, but some of the processing will have to be done on Linux (for other studies as well). Is there any way to figure out what that early version did differently and how we could set up the newest version in the same way?

Many thanks,
Anita

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.