Converting embedded pictures

Please post all questions and comments regarding Help & Manual 7 here.

Moderators: Alexander Halser, Tim Green

Post Reply
Ted Carlson
Posts: 20
Joined: Fri Jul 30, 2010 1:03 am
Location: Washington, DC area
Contact:

Converting embedded pictures

Unread post by Ted Carlson »

Hi everyone,
I recently updated H&M to 7.3.6 build 4521. Since then, I've had an issue with converting embedded pics. Before the update, the conversion would normally take 2-3 seconds before a File Save dialog appeared. Now, it takes approximately 135-150 seconds for the dialog to appear. There are no error message and in all other respects the program works flawlessly. Any suggestions would be appreciated.

Ted
User avatar
Tim Green
Site Admin
Posts: 23156
Joined: Mon Jun 24, 2002 9:11 am
Location: Bruehl, Germany
Contact:

Re: Converting embedded pictures

Unread post by Tim Green »

Hi Ted,

This is unusual and not a known issue. The questions that occur to me are:
  • How many embedded images do you have to convert? Embedded images use a huge (really, HUGE) amount of memory and resources and having many of them can slow down your computer.
  • Where is the project stored? It it's on a network drive that may have something to do with it.
  • Are there any orphaned network references in Help+Manual or your projectd? (see below)
Slow loading and saving performance is often caused by orphaned network references in your project to locations on the network that no longer exist, and it may be made worse by embedded images in your project, which can also slow down editing. This can apply in particular to image file references if the Project Search Path contains orphaned network references.

Windows networks take a very long time to resolve invalid network references. In your project go to the following locations and delete any references to network locations that are no longer valid:

* Project Explorer > Configuration > Common Properties > Project Search Path
* Project Explorer > Configuration > Common Properties > Help Windows: HTML Help Options
* File > Recent projects (delete any projects shown in red that no longer exist)
* Home > Recent projects (ditto)
Regards,
Tim (EC Software Documentation & User Support)

Private support:
Please do not email or PM me with private support requests -- post to the forum directly.
Ted Carlson
Posts: 20
Joined: Fri Jul 30, 2010 1:03 am
Location: Washington, DC area
Contact:

Re: Converting embedded pictures

Unread post by Ted Carlson »

Hi Tim,
I have no images to convert. Typically I create a page, add text and links, and then paste an image from a PDF. H&M asks me to convert and I do so.

The project is stored on an Unraid server. I also thought this might affect speed so I moved it to a local hard drive. There was no change. Finally, I moved the project to my C drive which is an SSD. The time improved somewhat to 90-110 seconds.

There are no orphaned references.

Finally, I have noticed CPU usage in the Process tab of Task Manager never goes above 5% during the conversion. I don't know how H&M does the conversion but I would think the CPU usage would be higher.

Ted
Ted Carlson
Posts: 20
Joined: Fri Jul 30, 2010 1:03 am
Location: Washington, DC area
Contact:

Re: Converting embedded pictures

Unread post by Ted Carlson »

Tim,
I think I have figured it out. I opened another very small project and tried pasting a pic. The dialog came up immediately. Next, I removed all but a handful of the images for the project I'm having trouble with. When I hit the convert button, the Save As dialog came up almost immediately.

As my project progressed, I simply accepted the default name your program provides (clip####.png) and press on. My project is at clip2535.png now. I suspect that when I hit the convert button, H&M starts with clip0001.png and continues add 1 until it comes to an available filename. Now I can see why it would take so long for the dialog to appear, especially if the project was on a server.

Ted
User avatar
Tim Green
Site Admin
Posts: 23156
Joined: Mon Jun 24, 2002 9:11 am
Location: Bruehl, Germany
Contact:

Re: Converting embedded pictures

Unread post by Tim Green »

Hi Ted,

Wow... thanks for providing this information... :shock:

Generally it's best to use your own descriptive image file names as it helps you to identify images without always having to preview them. This reason is a new one to me....
Regards,
Tim (EC Software Documentation & User Support)

Private support:
Please do not email or PM me with private support requests -- post to the forum directly.
User avatar
Alexander Halser
EC-Software Support
Posts: 4098
Joined: Mon Jun 24, 2002 7:24 pm
Location: Salzburg, Austria
Contact:

Re: Converting embedded pictures

Unread post by Alexander Halser »

Hi Ted,

Thanks for this helpful information! Yes, I can imagine that it takes a while to open the picture-save dialog, if so many images with "clipXXX" are in the search folder. We've never had this problem before, but we'll see if we can come up with a faster solution for the file name suggestion.

To share some background information: when you convert an embedded image, or take a screenshot, or paste an image from the clipboard, Help+Manual will open a save dialog to save this image to disk. And it opens the dialog with a file name suggestion, that starts with a generic "clipXXX" name, where the number should be a new number, that does not conflict with any other picture file in the search path. So, this is a nice and helpful feature, but with hundreds or thousands of "clip1234" pictures in the search folder, it turns into the opposite...

Here is what happens: H&M tries "clip0001.png" for a new file name, then tests if this file name does already exist in any of the folders that are in the project search list. If the file exists, it tests for "clip0002.png" and so on. I think it stops testing after 100 tries, but one hundred tries are already too much, if the image folders are on a network path.

What we can do is to shorten this function and/or implement a faster bulk test. We have to think about it a bit...

What you can do right now is to clean up the list of image search folders. Remove those folders from the search list that are not used in this project. If you still have plenty of generic "clipxxxx" images in your search folder, try to remove unused images: the full project report also reports unused images and lets you remove these images with one click. The images are not deleted, but just moved to a new folder (not in the search path), so if you find out that you have removed too many images, you can easily recover them.
Alexander Halser
Senior Software Architect, EC Software GmbH
Ted Carlson
Posts: 20
Joined: Fri Jul 30, 2010 1:03 am
Location: Washington, DC area
Contact:

Re: Converting embedded pictures

Unread post by Ted Carlson »

Alexander Halser wrote: What you can do right now is to clean up the list of image search folders. Remove those folders from the search list that are not used in this project. If you still have plenty of generic "clipxxxx" images in your search folder, try to remove unused images: the full project report also reports unused images and lets you remove these images with one click. The images are not deleted, but just moved to a new folder (not in the search path), so if you find out that you have removed too many images, you can easily recover them.
Hi Alexander,
Actually, I did do a cleanup similar to what you suggest. In the end I left all the images in the folder. I found the page that uses clip0001.png, and renamed that .png file. Now, when I paste an image and click the convert button I get the dialog right away, but I must rename the image to something else. For me this isn't difficult, but I did like the default name. It made it easy for me :D

If you can come up with a solution that would be excellent, but if it proves to be problematic then I can live without it. Thank you for looking into this.

Ted
Simon_Dismore
Posts: 205
Joined: Thu Jul 13, 2017 2:57 pm

Re: Converting embedded pictures

Unread post by Simon_Dismore »

Alexander Halser wrote:we'll see if we can come up with a faster solution for the file name suggestion
How about using the date & time in ISO 8601 form without separators, e.g. 20181002T105000Z.png or 20181002T105000.123Z.png? It's sequential like the current numbering scheme and is unlikely to have duplicates.
Post Reply