vistalab / vistasoft

VISTASOFT is the main software repository of the VISTA lab at Stanford University.
http://vistalab.stanford.edu
148 stars 142 forks source link

Problems Integrating with Remote Data Toolbox #264

Open ejduwell opened 7 years ago

ejduwell commented 7 years ago

Hello, I just recently started using mrVista, and have been having problems running the tutorials. I think they all come down to problems integrating with Remote Data toolbox. When I try to run any of the tutorial scripts such as t_initAnatomyFromFreesurfer, I get the following error message:

Could not find artifactId <ernie> of type <zip> at remotePath <vistadata/anatomy/freesurfer>
Suggestion: specify the full remotePath, not just a parent path:
  rdtReadArtifact( ... 'remotePath', '/foo/bar/baz')
  rather than
  rdtReadArtifact( ... 'remotePath', '/foo')
Suggestion: specify the artifact file type:
  rdtReadArtifact( ... 'type', 'jpg')
  rdtReadArtifact( ... 'type', 'tiff')
  rdtReadArtifact( ... 'type', 'gz')
  etc...
Error using gradleFetchArtifact (line 154)
fetchPom Could not resolve all dependencies for configuration ':fetchPom'.
fetchWithClassifier Could not resolve all dependencies for configuration ':fetchWithClassifier'.
fetchWithoutClassifier Could not resolve all dependencies for configuration ':fetchWithoutClassifier'.

Error in rdtReadArtifact (line 91)
    [localPath, pomPath, downloads] = gradleFetchArtifact(configuration.repositoryUrl, ...

Error in RdtClient/readArtifact (line 287)
                [data, artifact, downloads] = rdtReadArtifact(obj.configuration, ...

Error in mrtInstallSampleData (line 69)
rd.readArtifact(projectName, 'type',filetype, 'destinationFolder',dFolder);

Error in t_initAnatomyFromFreesurfer (line 36)
dataDir = mrtInstallSampleData('anatomy/freesurfer', 'ernie', ...

I saw in previous postings that this error occurs due to not setting the MATLAB_SHELL to bash. I made sure that matlab was using bash, and tried again, but got the same errors.

Next, I followed the instructions in #174 , and ran: mrvCleanWorkspace; test_mrInit to test my remote data toolbox integration. Again, I get a similar error message:

Could not find artifactId <mrBOLD_01> of type <zip> at remotePath <vistadata/functional>
Suggestion: specify the full remotePath, not just a parent path:
  rdtReadArtifact( ... 'remotePath', '/foo/bar/baz')
  rather than
  rdtReadArtifact( ... 'remotePath', '/foo')
Suggestion: specify the artifact file type:
  rdtReadArtifact( ... 'type', 'jpg')
  rdtReadArtifact( ... 'type', 'tiff')
  rdtReadArtifact( ... 'type', 'gz')
  etc...
Error using gradleFetchArtifact (line 154)
fetchPom Could not resolve all dependencies for configuration ':fetchPom'.
fetchWithClassifier Could not resolve all dependencies for configuration ':fetchWithClassifier'.
fetchWithoutClassifier Could not resolve all dependencies for configuration ':fetchWithoutClassifier'.

Error in rdtReadArtifact (line 91)
    [localPath, pomPath, downloads] = gradleFetchArtifact(configuration.repositoryUrl, ...

Error in RdtClient/readArtifact (line 287)
                [data, artifact, downloads] = rdtReadArtifact(obj.configuration, ...

Error in mrtInstallSampleData (line 69)
rd.readArtifact(projectName, 'type',filetype, 'destinationFolder',dFolder);

Error in test_mrInit (line 25)
nifti_path = mrtInstallSampleData('functional','mrBOLD_01');

I also ran the logfile = mrvTest([], 'bold'); edit(logfile) test, and I have attached the log file.

Does anybody know what might be wrong with my Remote Data Toolbox setup? If so, I'd really appreciate some advice.

Many Thanks, Ethan

mrvTestLog_2017_10_14_17-04-01.txt

wandell commented 7 years ago

Sorry. We are having trouble with the data server. We hope to resolve the matter this week.

ejduwell commented 7 years ago

Hello Dr. Wandell,

Thanks so much for your prompt reply and update! If you could let me know when the server is back up, I'd really appreciate it.

Thanks again, Ethan

wandell commented 7 years ago

The archiva server is now available through the web interface. We have not tested the command line interface, but we will get to it as soon as we can.

Feel free to go ahead and try the mrvTest ... and related functions when you are ready. If it starts to work, let us know! We think it should, we just have not yet tested.

ejduwell commented 7 years ago

Hello Dr. Wandell,

Thanks so much for the update! I just ran mrvTest, and it looks like the server fix solved most, but not all of my problems. Importantly, It looks like I'm successfully downloading data from the archiva server. However, I'm still failing on test_meshView and test_prf. This is critical as the pRF modeling program is the main piece of software I'm interested in. The error message I get on test_meshView is:

"Problem adding mesh actor to window."

The error message I get on test_prf is:

"No default options available for the function 'fmincon'."

This is the same error message I got trying to run an older pRF tutorial posted on your wiki: http://web.stanford.edu/group/vista/cgi-bin/wiki/index.php/PRF_Tutorial. I posted a previous issue regarding this: #263 . If you or anyone else have any insights into whats wrong with fmnicon when I run prf_test, I'd really appreciate them. I've attached the full mrvTestLog from my mrvTest below. mrvTestLog_2017_10_16_13-48-38.txt

Many Thanks, Ethan

DavidBrainard commented 7 years ago

I've had a few fmincon things break in 2017a that used to work for me. Could be a Matlab version issue that needs a little version specific coding. But, that's just a guess. Glad that the archiva server is up again (I was checking this to say that I think it is, but Brian got there first.)

ejduwell commented 7 years ago

I just solved the prf_test problem. fmincon was failing because it was depending on the Optimization Toolbox which I didn't have installed. I updated my toolboxes, and it works now. Test_meshView is still failing however.

wandell commented 7 years ago

If you would like help with Test_meshView, please include the error message.

JWinawer commented 7 years ago

Please also include your operating system and matlab version. If you run the following, you will get a complete log file, and you could copy the entire log file to the issues page:

logFile = mrvTest();

ejduwell commented 7 years ago

Hello Dr. Wandell and Dr. Winawer,

Thanks so much for your support. I really appreciate it. I just re-ran: logFile = mrvTest(); I've attached the log file to the bottom of this post. I also ran Test_meshView. It dies on line 35: vw = meshLoad(vw, mshFileName, displayFlag); The error message is listed below:

Can't establish connection to mrMeshSrv.
Can't establish connection to mrMeshSrv.
Ubuntu system detected: Loading mrMeshSrv for Ubuntu 12.04
Can't establish connection to mrMeshSrv.
Can't establish connection to mrMeshSrv.
Can't establish connection to mrMeshSrv.
Ubuntu system detected: Loading mrMeshSrv for Ubuntu 12.04
Can't establish connection to mrMeshSrv.
mrmInitMesh: Add mesh actor...
Can't establish connection to mrMeshSrv.
Error using mrmSet (line 90)
Problem adding mesh actor to window.

Error in mrmInitMesh (line 27)
msh = mrmSet(msh,'add actor');

Error in meshVisualize (line 43)
[msh, lights] = mrmInitMesh(msh,backColor);

Error in meshLoad (line 91)
    msh = meshVisualize(msh);

Error in test_meshView (line 35)
vw = meshLoad(vw, mshFileName, displayFlag);

Could this be an issue with my version of Ubuntu? I noticed it was trying to load mrMeshSrv for Ubuntu 12.04. I'm using Ubuntu 16.04 LTS.

Thanks again for all your help, Ethan mrvTestLog_2017_10_17_10-44-14.txt

JWinawer commented 7 years ago

Dear Ethan,

I believe someone previously reported difficulty running the mesh server with Ubuntu 2016. I do not know why. I do not have an Ubuntu machine to test it on (I use Macs). I would suggest trying to open the mesh server from the terminal window rather than Matlab. For example, in the terminal window (not Matlab), try executing this file:

vistasoft/mrMesh/meshserver/mrMeshSrv_Ubuntu1204.glxa64

If the server opens, then you should be ok. You can then test this in Matlab with the command

mrmCheckServer

But if you can't open the mesh server from the terminal, then Matlab won't be able to do it either, and I could only advise you to try compiling it yourself from the source code. But this can be hard.

Jon

ejduwell commented 7 years ago

Hello Jon,

I tried running mrMeshSrv_Ubuntu1204.glxa64 like you suggested. That was a good idea. It appears that this file relies on library package dependencies that are not supported by Ubuntu anymore. I get the following error message: ./mrMeshSrv_Ubuntu1204.glxa64: error while loading shared libraries: libvtkGraphics.so.5.8: cannot open shared object file: No such file or directory I looked up libvtkGraphics.so.5.8 and it looks like its an outdated package for complex accelerated 3d graphics processing. However, it relies on a whole host of other no-longer-supported other dependencies as well, so it wouldn't be as easy as simply installing it. A previous closed issue #215 (I believe this is the one you refer to above) says that the current default graphics package in Ubuntu lacks the 3D accelerated graphics necessary to run mrMesh which are apparently proprietary. He said he was able to get it running after switching out his graphics drivers. I think I'll try this route. I actually just ordered a new machine with better dedicated nvidia graphics. It might have the drivers necessary to solve the problem. I'll post if this solves the issue.

Many Thanks, Ethan

JWinawer commented 7 years ago

Many thanks. Please let us know if you succeed.

On Wed, Oct 25, 2017 at 11:44 AM Ethan Duwell notifications@github.com wrote:

Hello Jon,

I tried running mrMeshSrv_Ubuntu1204.glxa64 like you suggested. That was a good idea. It appears that this file relies on library package dependencies that are not supported by Ubuntu anymore. I get the following error message: ./mrMeshSrv_Ubuntu1204.glxa64: error while loading shared libraries: libvtkGraphics.so.5.8: cannot open shared object file: No such file or directory I looked up libvtkGraphics.so.5.8 and it looks like its an outdated package for complex accelerated 3d graphics processing. However, it relies on a whole host of other no-longer-supported other dependencies as well, so it wouldn't be as easy as simply installing it. A previous closed issue

215 https://github.com/vistalab/vistasoft/issues/215 (I believe this

is the one you refer to above) says that the current default graphics package in Ubuntu lacks the 3D accelerated graphics necessary to run mrMesh which are apparently proprietary. He said he was able to get it running after switching out his graphics drivers. I think I'll try this route. I actually just ordered a new machine with better dedicated nvidia graphics. It might have the drivers necessary to solve the problem. I'll post if this solves the issue.

Many Thanks, Ethan

— You are receiving this because you commented.

Reply to this email directly, view it on GitHub https://github.com/vistalab/vistasoft/issues/264#issuecomment-339374799, or mute the thread https://github.com/notifications/unsubscribe-auth/ACBX3svgAzeCN6R5XGn0G9e5xB0WioRcks5sv1dUgaJpZM4P5jZD .

-- Sent from Gmail Mobile

welbourne commented 6 years ago

@ejduwell I wondered whether you were able to get mrMesh running after getting a new computer with nvidia drivers?
I get the same error message you describe above (I'm using Ubuntu 16.04 LTS): ./mrMeshSrv_Ubuntu1204.glxa64: error while loading shared libraries: libvtkGraphics.so.5.8: cannot open shared object file: No such file or directory

In my system settings it shows that I am using the NVIDIA drivers (rather than the open source Nouveau one), so I don't think the driver is the issue in my case, unless the default is somehow switching to nouveau when I try to start the mrMesh server.

Has anybody got any suggestions of how I can fix this?

Everything else vista related works well on my Linux setup, except for mrMesh. I've tried setting it all up on a windows laptop, which connects to the mrMesh server fine, but then I have other issues trying to build meshes (likely mex file related). At this point I'm unsure whether my time should be spent fixing the issues in Linux or Windows!

Many thanks Lauren

wadelab commented 6 years ago

Lauren Just to say we (actually Andre) now have a new version of mrMesh based on python and the most recent VTK libs. We will release it soon but if you want it even sooner, drop him a line. It work well on Ubuntu. a

-- Alex R. Wade University of York

On 29 January 2018 at 14:53:51, welbourne (notifications@github.com) wrote:

@ejduwell https://github.com/ejduwell I wondered whether you were able to get mrMesh running after getting a new computer with nvidia drivers? I get the same error message you describe above (I'm using Ubuntu 16.04 LTS): ./mrMeshSrv_Ubuntu1204.glxa64: error while loading shared libraries: libvtkGraphics.so.5.8: cannot open shared object file: No such file or directory

In my system settings it shows that I am using the NVIDIA drivers (rather than the open source Nouveau one), so I don't think the driver is the issue in my case, unless the default is somehow switching to nouveau when I try to start the mrMesh server.

Has anybody got any suggestions of how I can fix this?

Everything else vista related works well on my Linux setup, except for mrMesh. I've tried setting it all up on a windows laptop, which connects to the mrMesh server fine, but then I have other issues trying to build meshes (likely mex file related). At this point I'm unsure whether my time should be spent fixing the issues in Linux or Windows!

Many thanks Lauren

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/vistalab/vistasoft/issues/264#issuecomment-361415209, or mute the thread https://github.com/notifications/unsubscribe-auth/ACYPKL-nG4QAYDq8Xw4zSaNeGjl76wq3ks5tPkv_gaJpZM4P5jZD .

welbourne commented 6 years ago

Awesome, thanks Alex. Cheers Lauren

ejduwell commented 6 years ago

Hello Lauren,

I still haven't retried this. There was an issue purchasing my new machine, and it still isn't here yet ..not happy ;( . Sorry, I wish I could be more help. I'll be sure to post when I am able to test this. However, If you have the NVIDIA drivers and are still getting the same error, I agree, that suggests there is something more to this. It could be that because 'mrMeshSrv_Ubuntu1204.glxa64' was made for Ubuntu 12.04, it depends on other expired/outdated libraries... That's my suspicion. I'd take Alex's offer above.

Best, Ethan

ejduwell commented 6 years ago

@welbourne

Hello Lauren, Sorry for the delay in testing my new machine. I finally got it, installed, mrVista, and tested the install. I have the same problem as before despite the updated graphics. I'm therefore guessing that this is an ubuntu version/library dependency issue.

Did you try loading the version of mrMesh suggested by @wadelab with the most recent VTK libs? Would either you either you or Alex be willing send me a copy? If so, I'd really appreciate it.

Ethan

welbourne commented 6 years ago

Hi Ethan

I have the demo version from @wadelab and it works great, I was finally able to view and overlay data on meshes! I think it's very much still in development but Alex may be able to sort you out with a copy in the meantime.

Lauren

On 5 March 2018 at 11:24, Ethan Duwell notifications@github.com wrote:

@welbourne https://github.com/welbourne

Hello Lauren, Sorry for the delay in testing my new machine. I finally got it, installed, mrVista, and tested the install. I have the same problem as before despite the updated graphics. I'm therefore guessing that this is an ubuntu version/library dependency issue.

Did you try loading the version of mrMesh suggested by @wadelab https://github.com/wadelab with the most recent VTK libs? Would either you either you or Alex be willing send me a copy? If so, I'd really appreciate it.

Ethan

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/vistalab/vistasoft/issues/264#issuecomment-370533558, or mute the thread https://github.com/notifications/unsubscribe-auth/Aak1NpQOu1hJ-jlFenCPnGNY_xTtFgtbks5tbZEHgaJpZM4P5jZD .

-- Lauren Welbourne laurenwelbourne@gmail.com

ejduwell commented 6 years ago

Thanks Lauren! That's good to know!

Ethan

wadelab commented 6 years ago

Just to say, before this runs away ... this is Andre Gouws' code - nothing to do with me at all. He's putting the finishing touches to it and there will be code available soon. a

On Mon, Mar 5, 2018 at 7:31 PM, Ethan Duwell notifications@github.com wrote:

Thanks Lauren! That's good to know!

Ethan

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/vistalab/vistasoft/issues/264#issuecomment-370535598, or mute the thread https://github.com/notifications/unsubscribe-auth/ACYPKJep8vE6oqOz0IhuknT7aae7pqqbks5tbZJ6gaJpZM4P5jZD .

-- Professor Alex Wade Department of Psychology University of York Heslington, UK YO10 5DD

http://www.wadelab.net Mob: +44 7427 432 364

wandell commented 6 years ago

@wadelab - I just installed Ubuntu 16.04 and would be glad for a version of mrMesh that works. Any chance that it is available now? Could Andrew push the code into the vistalab repository?

Thanks, Brian

allanhummer commented 6 years ago

Hey everyone, I also struggled with running the mesh server on Ubuntu 16.04. When trying to run it from the terminal it pointed to missing vtk libraries. As there is no libvtk5.8 package available from the 16.04 repositories, I decided to install a more recent version and create links for the libraries.

More precisely I did: sudo apt install libvtk5.10 cd /usr/lib sudo ln -s libvtkGraphics.so.5.10 libvtkGraphics.so.5.8 sudo ln -s libvtkFiltering.so.5.10 libvtkFiltering.so.5.8 sudo ln -s libvtkCommon.so.5.10 libvtkCommon.so.5.8

This workaround seems to work so far.

On another note - I found Andre Gouws' mrMesh version to be available on Github: https://github.com/andregouws/mrMeshPy

Allan

benharvey commented 2 years ago

I don't know if people are still interested in running mrMesh smoothly without having to use a really old and unsupported version of ubuntu as their main OS. After 12.04 reached end-of-life, I really wanted a new solution. I now have Ubuntu 12.04 running with working mrMesh in a virtualbox virtual machine that I would be happy to share (though it's 3.5 GB, so email Ben Harvey if you want a copy). This should allow you to run mrMesh on almost any modern OS, in virtual Ubuntu 12. It's a bit of a hack, but the result performs smoothly.

wadelab commented 6 months ago

Hi All! I suspect this thread will run until the heat death of the universe...

I also recently discovered that mrMeshSrv.exe will run on both Apple silicon Macs and Ubuntu 22 under Wine. Did we already know that? Anyway, if you have wine installed (apt get install wine on Deb/Ubuntu or brew install wine-stable on mac) then you can type "wine mrMeshSrv.exe" on the terminal and it Just Works. Very handy! a

On Wed, Jun 22, 2022 at 2:42 PM benharvey @.***> wrote:

I don't know if people are still interested in running mrMesh smoothly without having to use a really old and unsupported version of ubuntu as their main OS. After 12.04 reached end-of-life, I really wanted a new solution. I now have Ubuntu 12.04 running with working mrMesh in a virtualbox virtual machine that I would be happy to share (though it's 3.5 GB, so email Ben Harvey if you want a copy). This should allow you to run mrMesh on almost any modern OS, in virtual Ubuntu 12. It's a bit of a hack, but the result performs smoothly.

— Reply to this email directly, view it on GitHub https://github.com/vistalab/vistasoft/issues/264#issuecomment-1163115007, or unsubscribe https://github.com/notifications/unsubscribe-auth/AATA6KG4XHMIVV4RTWE4B4DVQMJ6BANCNFSM4D7GGZBQ . You are receiving this because you were mentioned.Message ID: @.***>

-- Professor Alex Wade Department of Psychology University of York Heslington, UK YO10 5DD

https://orcid.org/0000-0003-4871-2747 Mob: +44 7427 432 364

benharvey commented 6 months ago

Wow! Alex Wade is totally correct here. I certainly didn't know mrMeshSrv.exe runs under Wine. I have just got it working with little effort on Ubuntu 22.04. It seems pretty stable, and communicates fine with Matlab running in the Ubuntu system itself (Matlab doesn't need to be running in Wine). Mesh building, displaying, drawing ROIs etc all work just like you are running mrMeshSrv in Ubuntu itself. This seems to be the best solution we have yet to run mrMeshSrv in current operating systems. Nice one Alex!

lilac-mjung1 commented 6 months ago

Hi All! I suspect this thread will run until the heat death of the universe... I also recently discovered that mrMeshSrv.exe will run on both Apple silicon Macs and Ubuntu 22 under Wine. Did we already know that? Anyway, if you have wine installed (apt get install wine on Deb/Ubuntu or brew install wine-stable on mac) then you can type "wine mrMeshSrv.exe" on the terminal and it Just Works. Very handy! a On Wed, Jun 22, 2022 at 2:42 PM benharvey @.> wrote: I don't know if people are still interested in running mrMesh smoothly without having to use a really old and unsupported version of ubuntu as their main OS. After 12.04 reached end-of-life, I really wanted a new solution. I now have Ubuntu 12.04 running with working mrMesh in a virtualbox virtual machine that I would be happy to share (though it's 3.5 GB, so email Ben Harvey if you want a copy). This should allow you to run mrMesh on almost any modern OS, in virtual Ubuntu 12. It's a bit of a hack, but the result performs smoothly. — Reply to this email directly, view it on GitHub <#264 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AATA6KG4XHMIVV4RTWE4B4DVQMJ6BANCNFSM4D7GGZBQ . You are receiving this because you were mentioned.Message ID: @.> -- Professor Alex Wade Department of Psychology University of York Heslington, UK YO10 5DD https://orcid.org/0000-0003-4871-2747 Mob: +44 7427 432 364

Worked like a charm. Running mrMeshSrv.exe with wine on newer apple silicon ran smoother than on Windows. Thank you Alex!

wandell commented 2 months ago

Hi!

Do you know whether the whole system works? Gari Lerma showed me how to get mrMeshSrv.exe running under wine. Also, a client window opens. That part is very good. Thanks.

But the communications from Matlab to the server using the pnet.c technology breaks. Is that a solved problem too?

Thanks, Brian

elinekupers commented 2 months ago

Hi,

I tested it on a MacBook pro (Big Sur) with Matlab R2020b and ran into one minor bug thusfar.

The function "mrMesh/tcpToolbox/pnet_readMsg.m" kills the server if the wait time is too short. I got this MATLAB Error message in the command window:          

meshVisualize(vw.mesh{1})
mrmInitMesh: Add mesh actor...
Warning: could not read msg header.  Header length 0

> In pnet_readMsg (line 31)
In mrMesh (line 128)
In mrmSet (line 247)
In mrmInitMesh (line 29)
In meshVisualize (line 43) 
Warning: Error receiving server reply header. 
> In mrMesh (line 131)
In mrmSet (line 247)
In mrmInitMesh (line 29)
In meshVisualize (line 43) 
Warning: could not read msg header.  Header length 0

> In pnet_readMsg (line 31)
In mrMesh (line 70)
In mrmSet (line 389)
In mrmInitMesh (line 30)
In meshVisualize (line 43) 
Error using mrMesh (line 73)
Error receiving handshake reply.  Message length 0

Error in mrmSet (line 389)
         mrMesh(host, windowID, 'enable_origin_arrows', p);

Error in mrmInitMesh (line 30)
mrmSet(msh,'origin lines',0);

Error in meshVisualize (line 43)
[msh, lights] = mrmInitMesh(msh,backColor);

You can fix this by increasing the setreadtimeout for the "else" statement in vistasoft/mrMesh/tcpToolbox/pnet_readMsg.m (lines 24-26).

Changing it from 2 -> 4 did the trick for me (or you can remove the if statement to make it a single line command):

% Don't wait forever before aborting:
if ispc, pnet(con,'setreadtimeout',4);
else     pnet(con,'setreadtimeout',4);
end

I can create a pull request if this works for more people.