Home Image-Pro Automation (Macros, Apps, Reports)

My counts won't export into Excel after I updated to version 9.3. How can I fix this?

I have a professionally created macro to segment and count objects in three classes and then export the counts to Excel. (Count and export portion of macro above). The macro worked well in 9.1, and I tried loading it into 9.3. The macro seems to run, meaning no errors occur, but when it opens Excel, only the image name is there (see attached image). None of the counts are there. Neither are there counts in the measurement table. I didn't edit the macro at all - didn't add or delete any steps. I have tried it with Office 2010 and Office 2016 Excel.

Comments

  • Kristi,

    Do you have measurements in the Measurements data table? I see that your macro loads options file, be sure that this file exists in the expected place, image has expected calibration (and other points that ensure that the counted objects are segmented properly and within filter rages).

    If you can't find the problem, please post your macro (packaged IPX file) and a sample image, so we can test it.

    Regards,

    Yuri
  • They are attached.
  • Kristi,

    I checked your project. It has 4 macros, which macro should be used with that image? The macro uses calibration (KAO Visia) and options files "KAO NF ROI.iqo", "KAO NF count.iqo", classification "KAO NF Cyan Coral Mixed.lcl" and other, which are not included into the IPX.

    Can you please also provide these files? Also, please check that they exist in the Configurations Files folder of Premier 9.3. It's possible to add all these files into the IPX as Additional files to make project distribution easier, but you can just zip them for the forum.

    Thanks,

    Yuri
  • They are in the Configuration Files folder of 9.3. I can't share those files because of confidentiality. I shouldn't have shared what I have so far. I know it is difficult to help without these. Can you think of any reason that the counts wouldn't be populating the measurement table? I didn't edit the macros at all from the originals, which worked.


  • For that particular image, I would use the NF single macro.
  • Kristi,

    The main problem, I think, is that in the end of your macro there are no segmented objects, so nothing is shown in the measurements data table (and consequently nothing is exported to Excel.)

    There are several reasons why you may have no objects:

    1. Wrong thresholds.
    2. Wrong segmentation recipe.
    3. Wrong filter ranges in measurements, so segmented objects are outside of the measurement ranges and filtered out. It can also be caused by wrong calibration, as filter ranges are in calibrated units.

    The parameters for 1 are saved in "KAO NF ROI.iqo", the parameters for 2 and 3 are in "KAO NF count.iqo" and calibration "KAO Visia". If you can't send these files, you have to check the problem yourself (or ask the person who created you the macro).

    What you can do is to load an options file, click the Count button and check the measurements data table. If you don't have any objects there, check the measurement filters or segmentation parameters. You can also go through the macro step by step (in debug mode) to see what is segmented on each step.

    Regards,

    Yuri


  • Thanks, Yuri! I appreciate all the time and effort you put into this. I ended up getting another copy of the macro files from a colleague, and they worked. I don't know what went wrong with my orginal ones though.
Sign In or Register to comment.