neuropoly / axonseg

Segment axon and myelin from microscopy data. Written in Matlab.
MIT License
18 stars 12 forks source link

Error using message/getString ... Unable to load a message catalog 'mg:textedit'. #27

Closed ngoertz closed 7 years ago

ngoertz commented 8 years ago

Your APP is exactly what I need to analyze SEM images of plant fibres. However I get the following error when I try to run the AxonSegmentationApp.m. Can you help me please?

Error using message/getString
    Unable to load a message catalog 'mg:textedit'. Please check the file location and format.
Error in uigetimagefile (line 47)
    dialogTitle = getString(message('mg:textedit:ImageInsertTtile'));
Error in SegmentationGUI (line 40)
    FileName= uigetimagefile;
Error in AxonSegmentationApp/startApp (line 61)
    obj.AppHandle = eval('SegmentationGUI');
Error in AxonSegmentationApp (line 38)
    startApp(obj)
Error in appinstall.internal.runapp>execute (line 78)
    out = evalin('caller', [script ';']);
Error in appinstall.internal.runapp>runapp13a (line 57)
    outobj = execute(fullfile(appinstalldir, [wrapperfile 'App.m']));
Error in appinstall.internal.runapp>runcorrectversion (line 36)
    appobj = runapp13a(appinstalldir);
Error in appinstall.internal.runapp (line 18)
    out = runcorrectversion(appmetadata, appentrypoint, addonmetadatadir);
alzaia commented 8 years ago

Hi, glad you are trying to use our toolbox!

Not sure what is the bug, but did you first install the App on MATLAB? Which release are you using? May I suggest you to try our last release (this one : https://github.com/neuropoly/axon_segmentation/releases/tag/v2.1)? You will get the source code, & once you add it to your MATLAB path, you can run the Segmentation GUI by calling it in the command window like this : >> SegmentationGUI.

Also, make sure you have a compatible MATLAB version (at least R2014a) & also the toolboxes that are needed to run the software (for example the Image Processing Toolbox).

I hope it helps.

ngoertz commented 8 years ago

Thank you ... if I can get this to work, it will be hugely helpful in our plant fibre research program (see FibreCITY if you're interested).

Yes, I installed the App on MATLAB

MATLAB Version: 8.6.0.267246 (R2015b)

It seems that the latest release causes the same error message.

thanks,

ngoertz commented 8 years ago

Thank you ... if I can get this to work, it will be hugely helpful in our plant fibre research program (see FibreCITY http://www.fibrecity.ca/ if you're interested).

Yes, I installed the App on MATLAB

MATLAB Version: 8.6.0.267246 (R2015b)

It seems that the latest release causes the same error message as well.

thanks,

Norm Goertzen (204) 237-8844

On Tue, Mar 1, 2016 at 1:32 PM, alzaia notifications@github.com wrote:

Hi, glad you are trying to use our toolbox!

Not sure what is the bug, but did you first install the App on MATLAB? Which release are you using? May I suggest you to try our last release (this one : https://github.com/neuropoly/axon_segmentation/releases/tag/v2.1)? You will get the source code, & once you add it to your MATLAB path, you can run the Segmentation GUI by calling it in the command window like this : >> SegmentationGUI.

Also, make sure you have a compatible MATLAB version (at least R2014a) & also the toolboxes that are needed to run the software (for example the Image Processing Toolbox).

I hope it helps.

— Reply to this email directly or view it on GitHub https://github.com/neuropoly/axon_segmentation/issues/27#issuecomment-190865915 .

alzaia commented 8 years ago

Did you try to run directly the SegmentationGUI code in the commend window?

ngoertz commented 8 years ago

Yup ... same error

alzaia commented 8 years ago

What type of image are you using as input?

ngoertz commented 8 years ago

I haven't got that far yet, but it will be a TIFF ... but it could also be any other format if that would help.

Should I be specifying an image on the command line, like this...

SegmentationGUI image4.tiff

Thanks

ngoertz commented 8 years ago

okay, that worked a bit better. Sorry.

So where is the documentation on the comman-line paramaters?

ngoertz commented 8 years ago

and the segmentation parameter file settings?

alzaia commented 8 years ago

You probably have an error because of the uigetimagefile line.

Yes, it should work if you call it this way : SegmentationGUI Image_name.tif.

You could also send us a sample image, so we can try & tell you if we have the same bug.

ngoertz commented 8 years ago

Thanks again. It mostly works until I get to 'Step 1' where when I press 'Go!' I always get the following messages -- and it doesn't seem to matter what values I select either, I never get to 'Step 2'.

So is there documentation I can read to inform myself on what all the settings actually do???

*** WARNING *** Reseting Step 1 will erase segmentation parameters previously defined.>> SegmentationGUI image4.tiff
    Not enough input arguments.
Error in step1 (line 3)
    im1 = axonInitialSegmentation(im_in, state.initSeg);
Error in SegmentationGUI>Go_1_to_2_Callback (line 275)
    handles.data.Step2_seg=step1(handles);
Error in gui_mainfcn (line 95)
    feval(varargin{:});
Error in SegmentationGUI (line 48)
    gui_mainfcn(gui_State, varargin{:});
Error in
    matlab.graphics.internal.figfile.FigFile/read>@(hObject,eventdata)SegmentationGUI('Go_1_to_2_Callback',hObject,eventdata,guidata(hObject))
Error while evaluating UIControl Callback
ngoertz commented 8 years ago

And here is the file I'm trying to segment.

Thanks again!

(PS. I'm really exciting ... even with partial results)

Norm Goertzen (204) 237-8844

On Tue, Mar 1, 2016 at 2:23 PM, alzaia notifications@github.com wrote:

You probably have an error because of the uigetimagefile line.

Yes, it should work if you call it this way : SegmentationGUI Image_name.tif.

You could also send us a sample image, so we can try & tell you if we have the same bug.

— Reply to this email directly or view it on GitHub https://github.com/neuropoly/axon_segmentation/issues/27#issuecomment-190886012 .

ngoertz commented 8 years ago

I sent the image via email, let me know know if nothing arrives.

alzaia commented 8 years ago

We have a quick video demo, it wasn't on the release page, but I just added it, so you can go & see it (its named Axon_Segmentation_GUI_overview.mp4).

alzaia commented 8 years ago

I think I didn't get your image in my mailbox.

ngoertz commented 8 years ago

can you send me your email address and I email it directly... if that's okay

Norm Goertzen (204) 237-8844

On Tue, Mar 1, 2016 at 4:12 PM, alzaia notifications@github.com wrote:

I think I didn't get your image in my mailbox.

— Reply to this email directly or view it on GitHub https://github.com/neuropoly/axon_segmentation/issues/27#issuecomment-190929921 .

ngoertz commented 8 years ago

did you post that mp4 file to GitHub?

Norm Goertzen (204) 237-8844

On Tue, Mar 1, 2016 at 4:13 PM, Norm Goertzen ngoertz@gmail.com wrote:

can you send me your email address and I email it directly... if that's okay

Norm Goertzen (204) 237-8844

On Tue, Mar 1, 2016 at 4:12 PM, alzaia notifications@github.com wrote:

I think I didn't get your image in my mailbox.

— Reply to this email directly or view it on GitHub https://github.com/neuropoly/axon_segmentation/issues/27#issuecomment-190929921 .

alzaia commented 8 years ago

yes it should be there : screen shot 2016-03-01 at 5 17 13 pm

ngoertz commented 8 years ago

darn it, the repo I'm looking at does not look like yours. what is the correct repo name?

Norm Goertzen (204) 237-8844

On Tue, Mar 1, 2016 at 4:17 PM, alzaia notifications@github.com wrote:

yes it should be there : [image: screen shot 2016-03-01 at 5 17 13 pm] https://cloud.githubusercontent.com/assets/14980394/13443938/7fafb424-dfd1-11e5-8658-ecb4ece29e0a.png

— Reply to this email directly or view it on GitHub https://github.com/neuropoly/axon_segmentation/issues/27#issuecomment-190932145 .

ngoertz commented 8 years ago

found, now downloading

Norm Goertzen (204) 237-8844

On Tue, Mar 1, 2016 at 4:18 PM, Norm Goertzen ngoertz@gmail.com wrote:

darn it, the repo I'm looking at does not look like yours. what is the correct repo name?

Norm Goertzen (204) 237-8844

On Tue, Mar 1, 2016 at 4:17 PM, alzaia notifications@github.com wrote:

yes it should be there : [image: screen shot 2016-03-01 at 5 17 13 pm] https://cloud.githubusercontent.com/assets/14980394/13443938/7fafb424-dfd1-11e5-8658-ecb4ece29e0a.png

— Reply to this email directly or view it on GitHub https://github.com/neuropoly/axon_segmentation/issues/27#issuecomment-190932145 .

ngoertz commented 8 years ago

and now I have it. it's the end of day here, so I will look at this tomorrow.

thanks very much! and hopefully I won't have to bother you further.

But when I complete my work, I can send you the details... if you wish.

Norm Goertzen (204) 237-8844

On Tue, Mar 1, 2016 at 4:20 PM, Norm Goertzen ngoertz@gmail.com wrote:

found, now downloading

Norm Goertzen (204) 237-8844

On Tue, Mar 1, 2016 at 4:18 PM, Norm Goertzen ngoertz@gmail.com wrote:

darn it, the repo I'm looking at does not look like yours. what is the correct repo name?

Norm Goertzen (204) 237-8844

On Tue, Mar 1, 2016 at 4:17 PM, alzaia notifications@github.com wrote:

yes it should be there : [image: screen shot 2016-03-01 at 5 17 13 pm] https://cloud.githubusercontent.com/assets/14980394/13443938/7fafb424-dfd1-11e5-8658-ecb4ece29e0a.png

— Reply to this email directly or view it on GitHub https://github.com/neuropoly/axon_segmentation/issues/27#issuecomment-190932145 .

alzaia commented 8 years ago

I did a test with your image. Its harder to work with it, but you should use the histogram equalization option in step 0 as your images have low contrast. Here are some screen captures : screen shot 2016-03-01 at 5 20 42 pm screen shot 2016-03-01 at 5 27 53 pm screen shot 2016-03-01 at 5 28 05 pm

ngoertz commented 8 years ago

interesting... I'll have to see what I can do to improve on the outline tracing accuracy of the fibres -- the holes are a secondary issue.

So I'm guessing that if I increase the contrast this would have produced better results?

Norm Goertzen (204) 237-8844

On Tue, Mar 1, 2016 at 4:30 PM, alzaia notifications@github.com wrote:

I did a test with your image. Its harder to work with it, but you should use the histogram equalization option in step 0 as your images have low contrast. Here are some screen captures : [image: screen shot 2016-03-01 at 5 20 42 pm] https://cloud.githubusercontent.com/assets/14980394/13444263/3ea4f5fa-dfd3-11e5-9273-3bdafed03713.png [image: screen shot 2016-03-01 at 5 27 53 pm] https://cloud.githubusercontent.com/assets/14980394/13444264/3ff31f72-dfd3-11e5-9a88-33e7f6184345.png [image: screen shot 2016-03-01 at 5 28 05 pm] https://cloud.githubusercontent.com/assets/14980394/13444269/41122a6a-dfd3-11e5-8ba8-89b28ab27288.png

— Reply to this email directly or view it on GitHub https://github.com/neuropoly/axon_segmentation/issues/27#issuecomment-190935896 .

alzaia commented 8 years ago

It may not be very precise in your case, but depends what you want to do with it. If you only want to get an approximate segmentation of the interior & exterior with stats (diameter, area,...) it could work.

If all your images are small like that, you dont even need to use full segmentation option or the discriminant analysis option. You can just do the segmentation directly on the GUI (result cropped) & you will have 2 result images (axon display & myelin display) + a .mat file with info + a .csv file with the stats (that you can open in Excel).

alzaia commented 8 years ago

If you only need the outside boundary, maybe our software is not the better for that. We start by finding & segmenting the axons, & then we do a screening in the axon neighbourhood to identify the myelin.

You should also notice that in your images, the fibers are very close to each other, so it will be very hard to get the good outside boundaries.

ngoertz commented 8 years ago

I see your point... and you might be correct.

Norm Goertzen (204) 237-8844

On Tue, Mar 1, 2016 at 4:38 PM, alzaia notifications@github.com wrote:

If you only need the outside boundary, maybe our software is not the better for that. We start by finding & segmenting the axons, & then we do a screening in the axon neighbourhood to identify the myelin.

You should also notice that in your images, the fibers are very close to each other, so it will be very hard to get the good outside boundaries.

— Reply to this email directly or view it on GitHub https://github.com/neuropoly/axon_segmentation/issues/27#issuecomment-190940774 .

tanguyduval commented 8 years ago

Hey Aldo,

Add an option to disable homogeneous sheath thickness in the GUI (use option khomo_off=1 in myelinInitialSegmention). for this particular issue you should also use the option radialProfileMaxLength = 2 (so that it can detect border that are quite far from the center of the fiber).

Try again on the image, show the results and close this old issue.

Best, Tanguy

tanguyduval commented 7 years ago

Homogeneous myelin thichness is a new functionnality in the upcoming version. Also the bug of uigetimagefile is solved