Cannot import labels from an image

I wanted to import labels from a TIF image, but unfortunately MIB does not let me select the image despite trying to change the options. See screenshots.
You can observe that I cannot select any image.
How can I fix it?
I use version 2.65 / 23 3 2020.
Thanks in advance

Hi,
was there any error?
You should try to load those files as images and check that they are grayscale images (not RGB) with materials having indices 1,2,3, etc
Best regards,
Ilya

There is no error, I cannot even select them.
And all the images are fine, see screenshots.Capture d’écran 2020-07-02 à 12.15.55 Capture d’écran 2020-07-02 à 12.19.27 Capture d’écran 2020-07-02 à 12.19.33

ok, the compiled version for MacOS does not have command window where error messages are displayed. Possibly starting MIB from console may show those.
To load tif as model you need to have the following:

  1. load a dataset in mib for which you have this model
  2. press the Load button in the Segmentation panel
  3. select TIF as file extension and choose the files (you may need to rename your files from tiff to tif)
  4. the model will be loaded correctly if size of your loaded dataset (in pixels) matches size of the loaded model.
    Ilya

Hi,
this is what I tried to do (without starting MIB from a terminal), but even though I select TIF in the options, the app does not let me select a TIFF image. I’ve checked the images dimensions and format.
How can I start MIB from a terminal?

if you start macos terminal and start MIB from there, does it show any errors?
If you can send me few of those files I can take a look.
I am on holidays until next week, so I will only be able to check those next Mon.
Ilya

Thank you for your help.
How do I start MIB from a terminal?

‘How do I start MIB from a terminal?’
you start command prompt (terminal window, there should be an icon somewhere on toolbar on MacOS)

after that follow this section:
Run MATLAB Generated Standalone Application

https://nl.mathworks.com/help/compiler/compile-a-standalone-application-from-the-command-line.html#mw_f80a2136-e018-41bf-b00f-ebc63ea19a84

you need to change “magicsquare” with name of MIB package (in this case mib, I think). and use v97 instead v92 in the MCR path.
Best regards,
Ilya

Thank you for your answer, and sorry for my very late reply, as I was dragged away by some other stuff.
I tried to do what you said and it didn’t work.
See the error:
$./MIB.app/Contents/MacOS/MIB
dyld: Library not loaded: @rpath/libmwlaunchermain.dylib
Referenced from: /Applications/MIB/application/./MIB.app/Contents/MacOS/MIB
Reason: image not found
[1] 6437 abort ./MIB.app/Contents/MacOS/MIB

I think it’s because in the export DYLD_LIBRARY_PATH=..., the variable MATLAB_RUNTIME_INSTALL_DIR is not defined in my environment.
What should it be? Knowing that I don’t have Matlab on my laptop.

Hi Guillaume,
Could you send me few images that you can’t open, I can check them.
Ilya

Done on your email address, along with screenshots showing the problem.

@FiReTiTi,
the problems seems to be related to incompatibility between Matlab uigetfile function and MacOS Catalina. There are few ways to fix that, but so far I can suggest 2 options.
A
Use Batch Processing (Menu->File->Batch processing)
in this tool you can make the following action to load the model:

B

  1. Load the images into the 1st container of MIB:
    image
  2. Switch to container 2 and load there the model (tif) files
    image
  3. Switch back to container 1
  4. Use Menu->Images->Tools for images->Image arithmetics and run the following command, which assigns image in the container 2 to a model in the container 1.
    image
  5. The limitation, that the names of materials are not transferred and you need to press the + button in the segmentation panel to add names for materials
    image

Ilya

Hi @FiReTiTi,
I’ve made a release that does not have this problem:

Please note that it is based on a beta version.

Ilya