Viewer Opens Slow

Started by Mees Dekker, February 26, 2025, 04:16:49 PM

Previous topic - Next topic

Mees Dekker

One thing I noticed, is when I send a picture from the file window to the viewer, it takes much longer (>10 seconds) than before (IMatch 2023) to see it on the screen. Peek preview is almost instantly. In IMatch the viewer was as fast as the Peek preview (almost instantly).

Both database and the picture are on the same internal SSD drive, which has some 350 Gb of free space.

I have made the necessary changes to my virus checker, after installing IMatch 2025

Could this be related in any way?

Mario

I don't think so. Can you make a debug log from an IMatch session where you encounter this? So we get some timing info?
I have not experienced this and there are no similar reports.

How many files do you show in the Viewer? Multiple side-by-side  layout?
Which panels have you open in the Viewer? Categories Panel? Annotations Panel?

axel.hennig

Quote from: Mees Dekker on February 26, 2025, 04:16:49 PMOne thing I noticed, is when I send a picture from the file window to the viewer, it takes much longer (>10 seconds) than before (IMatch 2023) to see it on the screen. Peek preview is almost instantly. In IMatch the viewer was as fast as the Peek preview (almost instantly).

I'm observing the same. Opening the Viewer takes much longer than before (IMatch 2023).

Maybe we should split this post, because two different topics.

axel.hennig

Quote from: Mario on February 26, 2025, 04:32:25 PMHow many files do you show in the Viewer? Multiple side-by-side  layout?
Which panels have you open in the Viewer? Categories Panel? Annotations Panel?

How many files do you show in the Viewer? Less than 100, somtimes less than 10.

Multiple side-by-side layout? No

Which panels have you open in the Viewer? Categories Panel? Annotations Panel? Categories Panel and Film Strip.

Mario

Quote from: axel.hennig on February 26, 2025, 04:36:19 PMWhich panels have you open in the Viewer? Categories Panel? Annotations Panel? Categories Panel and Film Strip.
What happens if you close both panels, then the Viewer and open it again? Any change?
Also, the log file in debug logging mode (see log file) is needed for a minimum of information to work with.

For a 100K files database, and a File Window with 400 files, it takes about 3 seconds to open the Viewer. Film strip and collection overlay visible. How long does it take on your PC?

Mees Dekker

Usually I have the flimstrip, annotation panel and statusbar open.

When I close all panels in the viewer, I notice only a minor improvement. Opening the viewer took 12 seconds, after closing all panels (including filmstrip) and the viewer, I reopened the viewer and then it took some 10 seconds to open just 1 jpg file.

I have 117 files in the file window and only 1 is send to/shown in the viewer. My database contains almost 160.000 files. 

A logfile in debug mode is attached.

axel.hennig

#6
Not sure if I've spotted correctly, but your first "open Viewer" took 9203ms and your second "open Viewer" (with all panels closed) took 8140ms.

02.27 08:33:22+    0 [1D20] 10  M>  <  0 [9203ms #sl] CViewWndDatabase::CreateViewerWnd
02.27 08:34:43+    0 [1D20] 10  M>  <  0 [8140ms #sl] CViewWndDatabase::CreateViewerWnd

I've also tested this and my times are 4328ms and 750ms. But this on a very small test-DB (only 77 jpg-files). Will also test with a larger DB.

But in general: I also had the "feeling" that it takes longer to open images in the Viewer compared to IMatch 2023.

Edit: Your Computer - in general - seems to be faster than mine (Number of processors 24 vs 12 and same amount of memory: 32GB)

Tveloso

I'm not seeing the slow start to the Viewer here (although I do see an occasional subsequent performance drop while using the viewer, as discussed in another thread - but it's intermittent).

My perception is that it might be just slightly slower to open the Viewer in IMatch 2025, than it was in IMatch 2023, but its still pretty quick for me.  I tested sending both one file, and 300 files, to the Viewer, and there was no appreciable difference between the two.  Sending 300 files took 2.09 seconds:

[2094ms] CViewWndDatabase::CreateViewerWnd
...and one file took just under that, but about the same (1.969 seconds):

[1969ms] CViewWndDatabase::CreateViewerWnd
My PC has a second discrete GPU, and in my ignorance, it was not being used for IMatch.  So I added that preference in Windows:

    Screenshot 2025-02-27 093738.png

and then repeated this test. 

To my surprise, it was actually slightly slower to open the Viewer with the "high performance" GPU configured (but not really measurably so).  And it was slower to open one file, than to open the 300.

Sending 300 Files took 3.39 seconds:

[3390ms] CViewWndDatabase::CreateViewerWnd
...and one file was 3.469 seconds:

[3469ms] CViewWndDatabase::CreateViewerWnd
(I'm pretty sure I don't have those reversed)...
--Tony

Tveloso

I just wanted to report (for anyone reading this topic later) that the GPU configuration change I mentioned here, is not an appropriate thing to do, as Mario explained:
Quote from: Mario on February 27, 2025, 04:33:47 PMIMatch ist not a game and will not benefit much (or at all) from running on the NVIDIA instead of the Intel GPU.
IMatch uses DirectX to render images in the Viewer, Quick View Panel and Slide Show. But displaying an image on screen is peanuts for modern GPUs.

You can force Windows to use the NVIDIA card for rendering, but that will not make things faster, just use more power.

Thank you for setting me straight on that Mario.
--Tony

Mario

#9
I've looked at the log Mees has attached and I see this:

Quote02.27 08:33:15+    0 [1D20] 05  M>  <  0 [234ms] CIMDXCacheManager::Start
02.27 08:33:22+ 6860 [1D20] 10  M> >  0 CIMViewerWnd::SetLayout  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(3539)'
02.27 08:33:22+  15 [1D20] 10  M>  <  0 [15ms] CIMViewerWnd::SetLayout

When the Viewer opens, it initializes a "cache manager" that is responsible for loading and pre-loading images in the background, using WIC and DirectX to directly load images into the GPU memory.

Once this is done, the Viewer updates internal properties, which includes calling SetLayout.
The only thing between cache manager Start and SetLayout is determining the current monitor via a Windows function call.

Nothing of this should take much time. And this code is unchanged between 2023 and 2025.

On Mees' machine, there is a almost 7 second pause between the cache manager start completed and the call to SetLayout.
On my computers there is a 15 millisecond (!) pause. I've checked on my workstation and on my laptop.

Mees: Do you use multiple monitors perhaps?  Any special monitor layout? Maybe a second monitor unplugged but not disabled in Windows itself?

Which panels are open in the Viewer (Categories, Histogram, Favorites, ...)?


Mees Dekker

Yes I do use 2 monitors, each 1920 x 1200 px. DellU2412 and EIZO CG247X. No special lay-outs. No open panels in the viewer. 

But Imatch is only using the Dell monitor (2nd monitor is used for PS). 

What puzzles me is that Peek Preview is almost instantly responding but the viewer, that uses the same technique/components (dixit Mario), has a 7 seconds pause. Why this difference?

And I did not have this "problem" in the previous versions (2023). On my travelling laptop, there is no pause. 


sinus

Without to measure, I see no difference between 2023 and 2025. 
The viewer is very quickly. 

Hm, hopefully, that the mystery on Mees' computer will be solved. 
Best wishes from Switzerland! :-)
Markus

Mario


QuoteWhat puzzles me is that Peek Preview is almost instantly responding but the viewer, that uses the same technique/components (dixit Mario), has a 7 seconds pause. Why this difference?
They use the same caching, pre-loading and display technology.
The difference, as far as I can tell without logging each individual line of code, is the call the Viewer makes to determine the active monitor. This is what happens between the Start of the cache manager and the SetLayout code.

Maybe try this: Move IMatch to your main monitor, Viewer to. Power of or even unplug the other monitor. Maybe there is a change?

Problems like this which appear to happen on one or two PCs, are very hard to track down. Especially when all we see is "And here IMatch does nothing for 7 seconds, and then it opens the Viewer". This is where guesswork begins...

I have two 4K monitors myself, and I work with both of them most of the time. I keep the Quick Preview Panel and Viewer on the left monitor and IMatch on the right monitor. But I don't get the same pause you experience when opening the Viewer on your system. I use a 4K monitor for my laptop, again usually keeping the Viewer on the 4K monitor.  Just tried, but I don't get this obscure pause. Typical type for CViewWndDatabase::CreateViewerWnd is about 800ms.

axel.hennig

Quote from: Mario on February 27, 2025, 05:08:27 PMOn Mees' machine, there is a almost 7 second pause between the cache manager start completed and the call to SetLayout.
On my computers there is a 15 millisecond (!) pause. I've checked on my workstation and on my laptop.

On my Laptop this pause is almost 3 seconds (also far away from 15 milliseconds) and all additional panels are disabled. There are no further Monitors plugged-in and the Windows-settings also does not show further Monitors.

Mario

Hm., so maybe not the monitor. I was wondering, because nothing has changed in this code between IMatch 2023 and 2025.
Is there a difference depending on whether or not the film strip is visible in the Viewer on your system?

I've added more logging and I've analyzed the code with a performance profile on my PC and my laptop. What I see is this:

03.04 08:33:13+    0 [4F38] 05  M>  <  0 [47ms] CIMDXCacheManager::Start
03.04 08:33:13+    0 [4F38] 05  M> >  0 CIMDXWnd::InitD2D  'V:\develop\IMatch5\src\IMatchNG\IMDXWnd.cpp(360)'
03.04 08:33:13+    0 [4F38] 05  M> >  0 CIMDXWnd::InitFactories  'V:\develop\IMatch5\src\IMatchNG\IMDXWnd.cpp(331)'
03.04 08:33:13+  15 [4F38] 05  M>  <  0 [15ms] CIMDXWnd::InitFactories
03.04 08:33:13+    0 [4F38] 50  M> >  0 CIMDXWnd::DiscardDeviceResources  'V:\develop\IMatch5\src\IMatchNG\IMDXWnd.cpp(533)'
03.04 08:33:13+    0 [4F38] 50  M>  <  0 CIMDXWnd::DiscardDeviceResources
03.04 08:33:13+    0 [4F38] 05  M>  <  0 [15ms] CIMDXWnd::InitD2D
03.04 08:33:13+    0 [4F38] 50  M> >  0 CIMDXWnd::CreateDeviceResources  'V:\develop\IMatch5\src\IMatchNG\IMDXWnd.cpp(437)'
03.04 08:33:13+    0 [4F38] 50  M> >  0 CIMDXWnd::DiscardDeviceResources  'V:\develop\IMatch5\src\IMatchNG\IMDXWnd.cpp(533)'
03.04 08:33:13+    0 [4F38] 50  M>  <  0 CIMDXWnd::DiscardDeviceResources
03.04 08:33:13+    0 [4F38] 50  M>  <  0 CIMDXWnd::CreateDeviceResources
03.04 08:33:13+  16 [4F38] 05  M>  <  0 [78ms] CIMViewerImageWnd::OnCreate

Everything is done in less than one second. This is from my 5 year old PC. InitFactories and CreateDevice* are functions of Windows DirectX which allows IMatch to render images super-fast with the GPU.

This code is unchanged between 2023 and 2025. I have no idea how to find out why there is such a long pause on Mees' and a shorter one on yours.

I'll leave the logging in place for the next release (debug logging must be enabled) and maybe we see something in your logs then.


Mees Dekker

I don't notice any difference between filmstrip being enabled or not.

It remains a mystery for now.

axel.hennig

Wanted to follow-up on this, since Mario mentioned that he added additional logging.

Please find attached a debug-log still showing that the Viewer opens slowly (not as slow as for Mees, but still slower than in IMatch 2023).

I think the relevant part of the log is:

03.19 08:54:33+    0 [35B0] 05  M>  <  0 [109ms] CIMDXCacheManager::RecreateDeviceResources
03.19 08:54:33+    0 [35B0] 05  M>  <  0 [109ms] CIMDXCacheManager::InitD2D
03.19 08:54:33+    0 [35B0] 05  M>  <  0 [125ms] CIMDXCacheManager::Start
03.19 08:54:33+    0 [35B0] 10  M> >  0 CIMViewerWnd::GetCurrentMonitor  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(3208)'
03.19 08:54:33+    0 [35B0] 10  M>  <  0 CIMViewerWnd::GetCurrentMonitor
03.19 08:54:33+    0 [35B0] 10  M> >  0 CIMViewerWnd::SetProperties  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(900)'
03.19 08:54:33+   16 [35B0] 10  M> >  0 CIMViewerWnd::UpdateSmartMenu  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(4191)'
03.19 08:54:33+    0 [35B0] 10  M>  <  0 CIMViewerWnd::UpdateSmartMenu
03.19 08:54:36+ 3203 [35B0] 10  M> >  0 CIMViewerWnd::SetLayout  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(3549)'
03.19 08:54:36+   15 [35B0] 10  M>  <  0 [15ms] CIMViewerWnd::SetLayout
03.19 08:54:36+    0 [35B0] 10  M>  <  0 [3234ms] CIMViewerWnd::SetProperties

So, I think it is not the "figure out the current Monitor" topic mentioned in another post above, but I don't know what's causing this.

Mario

Very strange.

After CIMViewerWnd::UpdateSmartMenu() has finished,
there is a 3 second pause (?) and then CIMViewerWnd::SetLayout() is called.

During this time, the Viewer sets up the status bar, film strip, annotations/category/favs and other panels, depending on the user configuration. I checked the code and it is identical to IMatch 2023. So is the code of the panels. Which gives no clue for where the time is spend. I can only add more logging code for the next release...

Which panels do you have open?
Does the performance (the delay between UpdateSmartMenu and SetLayout) change when you close all panels and film strip?

axel.hennig

Quote from: Mario on March 19, 2025, 11:55:04 AMWhich panels do you have open?
Status Bar, Filmstrip & Categories Panel.


Quote from: Mario on March 19, 2025, 11:55:04 AMDoes the performance (the delay between UpdateSmartMenu and SetLayout) change when you close all panels and film strip?

All panels closed (i.e. Status Bar, Filmstrip & Categories Panel), then I get the following (still approx. 3sec):

03.19 13:26:22+    0 [4608] 05  M>  <  0 [110ms] CIMDXCacheManager::RecreateDeviceResources
03.19 13:26:22+    0 [4608] 05  M>  <  0 [110ms] CIMDXCacheManager::InitD2D
03.19 13:26:22+    0 [4608] 05  M>  <  0 [110ms] CIMDXCacheManager::Start
03.19 13:26:22+    0 [4608] 10  M> >  0 CIMViewerWnd::GetCurrentMonitor  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(3208)'
03.19 13:26:22+    0 [4608] 10  M>  <  0 CIMViewerWnd::GetCurrentMonitor
03.19 13:26:22+    0 [4608] 10  M> >  0 CIMViewerWnd::SetProperties  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(900)'
03.19 13:26:22+    0 [4608] 10  M> >  0 CIMViewerWnd::UpdateSmartMenu  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(4191)'
03.19 13:26:22+    0 [4608] 10  M>  <  0 CIMViewerWnd::UpdateSmartMenu
03.19 13:26:25+ 2812 [4608] 10  M> >  0 CIMViewerWnd::SetLayout  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(3549)'
03.19 13:26:25+    0 [4608] 10  M>  <  0 CIMViewerWnd::SetLayout
03.19 13:26:25+    0 [4608] 10  M>  <  0 [2812ms] CIMViewerWnd::SetProperties
03.19 13:26:25+   31 [4608] 10  M> >  0 CIMViewerWnd::SetLayout  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(3549)'
03.19 13:26:25+    0 [4608] 10  M>  <  0 CIMViewerWnd::SetLayout

Mees Dekker

Same here: Status bar, filmstrip and "show collections" and "annotations". Still as slow as before.

When all panels closed: no noticable change in performance.

Logfile (in debug mode) attached.

Mario

2.8 seconds for thrinn, 5.5s for Mees. Why so much of a difference?

On my five year old system I get (with the new log entries for each individual step)

03.19 14:28:11+    0 [6594] 10  M>  <  0 CIMViewerWnd::GetCurrentMonitor
03.19 14:28:11+    0 [6594] 10  M> >  0 CIMViewerWnd::SetProperties  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(900)'
03.19 14:28:11+    0 [6594] 10  M> >  0 CIMViewerWnd::UpdateSmartMenu  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(4229)'
03.19 14:28:11+    0 [6594] 10  M>  <  0 CIMViewerWnd::UpdateSmartMenu
03.19 14:28:11+    0 [6594] 02  I> CIMViewerWnd::RecalcLayout: status bar: 0ms
03.19 14:28:11+   15 [6594] 02  I> CIMViewerWnd::RecalcLayout: film strip: 0ms
03.19 14:28:11+    0 [6594] 02  I> CIMViewerWnd::RecalcLayout: category panel: 0ms
03.19 14:28:11+    0 [6594] 02  I> CIMViewerWnd::RecalcLayout: favs panel: 0ms
03.19 14:28:11+    0 [6594] 02  I> CIMViewerWnd::RecalcLayout: anno panel: 0ms
03.19 14:28:11+    0 [6594] 10  M> >  0 CIMViewerWnd::SetLayout  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(3549)'
03.19 14:28:11+    0 [6594] 10  M>  <  0 CIMViewerWnd::SetLayout
03.19 14:28:11+    0 [6594] 10  M>  <  0 [15ms] CIMViewerWnd::SetProperties

15ms for SetProperties, not several seconds. I use film strip, status bar, annotations panel and collections.
When I enable the "very expensive" panels Categories and Favorites, I get:

.19 14:31:24+    0 [6594] 10  M>  <  0 CIMViewerWnd::UpdateSmartMenu
03.19 14:31:24+  15 [6594] 02  I> CIMViewerWnd::RecalcLayout: status bar: 15ms
03.19 14:31:24+    0 [6594] 02  I> CIMViewerWnd::RecalcLayout: film strip: 0ms
03.19 14:31:26+ 1156 [72C0] 02  I> FolderSweeper: processed 508 folders in 0ms. Deepcheck: 0
03.19 14:31:27+ 1250 [6594] 02  I> CIMViewerWnd::RecalcLayout: category panel: 2406ms
03.19 14:31:27+  329 [6594] 10  M> >  0 CIMFavContainerWnd::LoadFavs  'V:\develop\IMatch5\src\IMatchNG\IMFavContainerWnd.cpp(687)'
03.19 14:31:27+  93 [6594] 10  M>  <  0 [93ms] CIMFavContainerWnd::LoadFavs
03.19 14:31:27+    0 [6594] 02  I> CIMViewerWnd::RecalcLayout: favs panel: 422ms
03.19 14:31:27+    0 [6594] 02  I> CIMViewerWnd::RecalcLayout: anno panel: 0ms
03.19 14:31:27+    0 [6594] 10  M> >  0 CIMViewerWnd::SetLayout  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(3549)'
03.19 14:31:27+    0 [6594] 10  M>  <  0 CIMViewerWnd::SetLayout
03.19 14:31:27+    0 [6594] 10  M>  <  0 [2843ms] CIMViewerWnd::SetProperties


So almost 3 seconds now, with 2.5 seconds for the Categories Panel and 0.5s for the Favorites panel.
The Categories panel is expensive, because it has to load so much data, maybe wait for categories to finish updating etc.

Jingo

Mine is quite fast to open as well.. I only have the filmstrip, status bar and camera info open:

03.19 09:34:00+  125 [33EC] 50  M>  <  0 [500ms] CIMDXCacheManagerLoaderDelegate::InnerLoad
03.19 09:34:00+    0 [0DAC] 50  M>  <  0 [125ms] CIMDXCacheManager::ClearCache
03.19 09:34:00+    0 [0DAC] 10  M> >  0 CViewWndDatabase::SetViewerMode  'V:\develop\IMatch5\src\IMatchNG\ViewWndDatabase.cpp(3474)'
03.19 09:34:00+   31 [0DAC] 10  M> >  0 CViewWndDatabase::CreateViewerWnd  'V:\develop\IMatch5\src\IMatchNG\ViewWndDatabase.cpp(3398)'
03.19 09:34:00+   16 [0DAC] 10  M> >  0 CIMViewerWnd::UpdateSmartMenu  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(4191)'
03.19 09:34:00+    0 [0DAC] 10  M>  <  0 CIMViewerWnd::UpdateSmartMenu
03.19 09:34:00+  672 [0DAC] 10  M> >  0 CIMViewerWnd::UpdateSmartMenu  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(4191)'
03.19 09:34:00+    0 [0DAC] 10  M>  <  0 CIMViewerWnd::UpdateSmartMenu
03.19 09:34:00+    0 [0DAC] 10  M> >  0 CIMViewerWnd::SetLayout  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(3549)'
03.19 09:34:00+    0 [0DAC] 10  M>  <  0 CIMViewerWnd::SetLayout
03.19 09:34:00+    0 [0DAC] 10  M> >  0 CIMViewerWnd::UpdateSmartMenu  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(4191)'
03.19 09:34:00+    0 [0DAC] 10  M>  <  0 CIMViewerWnd::UpdateSmartMenu

Mario

Quote from: Jingo on March 19, 2025, 02:37:04 PMMine is quite fast to open as well.. I only have the filmstrip, status bar and camera info open:
The SetProperties method is the relevant bit, not included in your post.

Jingo

Quote from: Mario on March 19, 2025, 02:41:53 PM
Quote from: Jingo on March 19, 2025, 02:37:04 PMMine is quite fast to open as well.. I only have the filmstrip, status bar and camera info open:
The SetProperties method is the relevant bit, not included in your post.
Ooops - here you go:

03.19 09:34:00+    0 [0DAC] 10  M> >  0 CIMViewerWnd::SetProperties  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(900)'
03.19 09:34:00+    0 [0DAC] 10  M> >  0 CIMViewerWnd::UpdateSmartMenu  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(4191)'
03.19 09:34:00+    0 [0DAC] 10  M>  <  0 CIMViewerWnd::UpdateSmartMenu
03.19 09:34:00+    0 [0DAC] 10  M> >  0 CIMViewerWnd::SetLayout  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(3549)'
03.19 09:34:00+    0 [0DAC] 10  M>  <  0 CIMViewerWnd::SetLayout
03.19 09:34:00+    0 [0DAC] 10  M>  <  0 CIMViewerWnd::SetProperties



Mario

Less than a few milliseconds. Not 2 or even 5 seconds as for thrinn or Mees. Very strange.

Mario

@Mees and @thrinn

Can you still reproduce this? If so, switch to debug logging, open the Viewer. If it's still slow, use Help > Support > Copy Logfile, ZIP and attach. 

I've added more logging in the 2025.2.2 release.

thrinn

I did not experience any issues. Do you mean Axel?
Thorsten
Win 10 / 64, IMatch 2018, IMA

axel.hennig

Quote from: Mario on April 03, 2025, 10:14:20 AMI've added more logging in the 2025.2.2 release.
I think you've mentioned that additional logging was added in 2025.2.4, which was released 19.03.2025.

My two posts above (post 1, post 2, 19.03.2025, IMatch 2025.2.4) should have the additional logging and you've already replied to both.

Also Mees has replied with the additional logging (his post with additional logging) and you have also already replied to his post.

Do you need anything else? I'm still experiencing the slow opening.

Mario

Sorry, I forgot. Just wanted to clean up some loose ends.
I will add more logging to the next release.

axel.hennig

Since today IMatch 2025.3.2 is available and I wanted to follow-up on this topic since more logging was added.

I've done three tests which are as followed:

  • TEST-1 (logging below): My productive IMatch-DB; opened a JPG-file; Filmstrip, Categories-Panel and Status Bar visible
  • TEST-2 (logging below): My productive IMatch-DB; opened a JPG-file; all Panels de-activated (not visible)
  • TEST-3 (logging below): Created new IMatch-Test-DB; imported one JPG-file; deleted all Categories which IMatch has initially created, so that the Category-tree just has @All, @Keywords and @Builder; opened the only JPG-file; all Panels de-activated (not visible)

From my point of view TEST-3 should open the JPG-file as fast as possible.

The slow part is always the "RecalcLayout: category panel". But this, I do not understand. Especially not for TEST-2 and even more not for TEST-3.

The debug-log for the three tests is:

TEST-1
04.29 15:59:40+    0 [09B0] 10  M> >  0 CIMViewerWnd::SetProperties  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(900)'
04.29 15:59:40+    0 [09B0] 10  M> >  0 CIMViewerWnd::ScreenCacheBegin  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(3091)'
04.29 15:59:40+    0 [09B0] 10  M>  <  0 CIMViewerWnd::ScreenCacheBegin
04.29 15:59:40+    0 [09B0] 10  M> >  0 CIMViewerWnd::UpdateSmartMenu  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(4232)'
04.29 15:59:40+    0 [09B0] 10  M>  <  0 CIMViewerWnd::UpdateSmartMenu
04.29 15:59:40+    0 [09B0] 02  I> CIMViewerWnd::RecalcLayout: status bar: 0ms
04.29 15:59:40+    0 [09B0] 02  I> CIMViewerWnd::RecalcLayout: film strip: 0ms
04.29 15:59:43+ 2813 [09B0] 02  I> CIMViewerWnd::RecalcLayout: category panel: 2813ms
04.29 15:59:43+    0 [09B0] 02  I> CIMViewerWnd::RecalcLayout: favs panel: 0ms
04.29 15:59:43+    0 [09B0] 02  I> CIMViewerWnd::RecalcLayout: anno panel: 0ms
04.29 15:59:43+   16 [09B0] 10  M> >  0 CIMViewerWnd::SetLayout  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(3550)'
04.29 15:59:43+    0 [09B0] 10  M>  <  0 CIMViewerWnd::SetLayout
04.29 15:59:43+    0 [09B0] 10  M>  <  0 [2829ms] CIMViewerWnd::SetProperties


TEST-2
04.29 16:20:36+    0 [302C] 10  M> >  0 CIMViewerWnd::SetProperties  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(900)'
04.29 16:20:36+   16 [302C] 10  M> >  0 CIMViewerWnd::ScreenCacheBegin  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(3091)'
04.29 16:20:36+    0 [302C] 10  M>  <  0 CIMViewerWnd::ScreenCacheBegin
04.29 16:20:36+    0 [302C] 10  M> >  0 CIMViewerWnd::UpdateSmartMenu  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(4232)'
04.29 16:20:36+    0 [302C] 10  M>  <  0 CIMViewerWnd::UpdateSmartMenu
04.29 16:20:36+    0 [302C] 02  I> CIMViewerWnd::RecalcLayout: status bar: 0ms
04.29 16:20:36+    0 [302C] 02  I> CIMViewerWnd::RecalcLayout: film strip: 0ms
04.29 16:20:39+ 2828 [302C] 02  I> CIMViewerWnd::RecalcLayout: category panel: 2828ms
04.29 16:20:39+    0 [302C] 02  I> CIMViewerWnd::RecalcLayout: favs panel: 0ms
04.29 16:20:39+   16 [302C] 02  I> CIMViewerWnd::RecalcLayout: anno panel: 0ms
04.29 16:20:39+    0 [302C] 10  M> >  0 CIMViewerWnd::SetLayout  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(3550)'
04.29 16:20:39+    0 [302C] 10  M>  <  0 CIMViewerWnd::SetLayout
04.29 16:20:39+    0 [302C] 10  M>  <  0 [2860ms] CIMViewerWnd::SetProperties


TEST-3
04.29 22:16:57+    0 [3848] 10  M> >  0 CIMViewerWnd::SetProperties  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(900)'
04.29 22:16:57+    0 [3848] 10  M> >  0 CIMViewerWnd::ScreenCacheBegin  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(3091)'
04.29 22:16:57+    0 [3848] 10  M>  <  0 CIMViewerWnd::ScreenCacheBegin
04.29 22:16:57+    0 [3848] 10  M> >  0 CIMViewerWnd::UpdateSmartMenu  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(4232)'
04.29 22:16:57+    0 [3848] 10  M>  <  0 CIMViewerWnd::UpdateSmartMenu
04.29 22:16:57+    0 [3848] 02  I> CIMViewerWnd::RecalcLayout: status bar: 0ms
04.29 22:16:57+    0 [3848] 02  I> CIMViewerWnd::RecalcLayout: film strip: 0ms
04.29 22:17:00+ 3031 [3848] 02  I> CIMViewerWnd::RecalcLayout: category panel: 3031ms
04.29 22:17:00+   16 [3848] 02  I> CIMViewerWnd::RecalcLayout: favs panel: 0ms
04.29 22:17:00+    0 [3848] 02  I> CIMViewerWnd::RecalcLayout: anno panel: 0ms
04.29 22:17:00+    0 [3848] 10  M> >  0 CIMViewerWnd::SetLayout  'V:\develop\IMatch5\src\IMatchNG\IMViewerWnd.cpp(3550)'
04.29 22:17:00+    0 [3848] 10  M>  <  0 CIMViewerWnd::SetLayout
04.29 22:17:00+    0 [3848] 10  M>  <  0 [3047ms] CIMViewerWnd::SetProperties

Mario

Good info, thanks.

After "film strip" is logged, IMatch checks if the category panel is enabled.
If it is, it checks if the category panel has already been created. It not, it is created.
In the next step, when the category panel is valid, IMatch checks if it should be off (the user may have toggled it) and then either recalculates the layout when the panel is enabled, or disables and hides the panel, when it is disabled.

Then "category panel" is logged.

When the categories panel is disabled when the Viewer is opened, it should never been created and the "category panel" step should take no time at all.

On my two computers, with the category panel disabled in the Viewer, the "category panel" step is always logged as 0 ms.
When I enable the panel (all standard categories and a small scope of only 30 images) the step takes about 2.5 seconds and the Viewer takes accordingly longer to open. Same as on your PC.

When I hide the panel again, the code hides and disables the panel but does not destroy it. This is intentional.
When I close and re-open the Viewer, the category panel creation is skipped completely and "category panel" logs again as 0ms.
This all seems to work correctly.

When I understand your post correctly,, the category panel was only enabled for your first test.
Still, it takes about 3s to perform this step, whether the category panel is enabled or not.


So, why does this always takes time on your computer, whether or not the category panel is open?

The only idea I have is that, for some reason, the category panel is always created, and when it it set to "off", it is hidden immediately after. But that would mean panel is created because it is not OFF, then it is hidden because it is OFF. Both sections of the code check the same category panel "docking site" setting.

When you press <Backspace> to hide everything except the images in the Viewer and then close and re-open it, do you notice any difference? Is "category panel" now logged as 0ms? In the "grid only" mode, no panels are created / shown.