Cancel is Cancel. If you want to save your options, start the report.
This is True for all reports. not only the narrative web.
Serge
That is my entire point. If in order to save the configuration I hit start then I have to an 8 hour coffee break while I wait for it to finish or crash GRAMPS. If I get interrupted or want to wait for a while and rethink what I am doing I should be able to save the configuration settings without running the report.
I have no problem if the thought is outrageous. I can keep on putting in a non valid path for the report output.
Phil
You have progress information while Narrative Web is generated. The notification says something like āGenerating peopleā, āGenerating familiesā, ā¦ See which message is displayed when the process seems to slack a bit.
My bet is in the media pages generation because it involves a lot of copies and image conversion: you have a full directory for native resolution images, one for reduced resolution and a third one for thumbnails. As I already mentioned, each directory tries to spread your images in 2-level tree using some kind of hash (excerpts from the āhandleā record id). For each image you have two transformations and 3 copies.
I donāt use much media files in my genealogy; I canāt experiment.
If you donāt want to regenerate your web tree because it takes too much time, try not to include media to see if it makes a difference.
I wonder if the Media generation might not be the ideal place to experiment with controlling threaded processes? Each conversion and thrumbnail is pretty independent.
Whilst I have never been allowed to spend a full day sat in front of the screen timing each stage I can confirm ācreating media pagesā is the part that takes in excess of 50% of the time.
Now I confess I have not experimented with the various media options to study the effect but might do so.
Phil
More than 90% of the time is spent in āCreating media pagesā. It takes no more than 45 minutes to reach that stage, and only a few minutes to complete the report after that stage completes.
I saw some comments in the code that made me think it was creating reduced resolution images, but Iāve never found where they are being stored. But maybe that is the problem. The options Iāve been using for the Dynamic Web Report generates image and thumb directories that are practically identical to the images and thumb directories generated by the Narrated Web Report. (The only differences are the nine icon and background files Narrated Web Report includes in the images directory.)
Yet the Dynamic Web Report takes less than 10% of the time it takes to generate the Narrated Web Report. That was the reason I originally suspected it was the generation of the References section because that was the only extra information included in the Narrated Web Report.
So it is beginning to sound like the Narrated Web Report may be wasting a lot of time generating reduced resolution images that are never used.
I did some tests on an M3 Mac with Gramps 5.1.6 .
People: 17500
Families: 6000
Media: 5700 (total 7GB space)
Using the Narrated Web Report in CLI (with many options specified for clarity)
Gramps -O āMain Treeā -a report -p name=navwebpage,ancestortree=True,coordinates=True,create_thumbs_only=False,familymappages=True,gallery=True,graphgens=4,inc_addressbook=False,inc_events=True,inc_families=True,inc_gendex=True,inc_id=0,inc_places=True,inc_repository=False,inc_sources=True,inc_stats=True,incdownload=False,incl_private=True,living_people=99,placemappages=True,prevnext=False,relation=False,showbirth=True,showdeath=True,showhalfsiblings=True,showparents=True,showpartner=True,unused=False
takes about 1 hour. If I change to gallery=False, it takes 1 minute. Alternately, if I change create_thumbs_only=True, it also reduces duration to 1 minute. In each of these cases, it does not create the Media section. The other options donāt significantly change the duration.
This is because The image resizing is done by Gtk. in 5.1.5 I have added the possibility to reduce the time with a module named āmagicā which is not installed by default.
import magic
# For performance reasons, we'll try to get image size from magic.
# This avoid to load the image in memory. This is a real improvement
# when we have many big images.
# Used in odfdoc, rtfdoc and webreport and tested with png, gif, jpeg,
# bmp, tiff
#
# file size with magic without (Gdk) ratio
# example 1 : 256k 0.00080 0.00575 7
# example 2 : 21M 0.00171 0.55860 326
In 5.2, this module is changed to imagesize (see PR Use imagesize rather than magic by Nick-Hall Ā· Pull Request #1597 Ā· gramps-project/gramps Ā· GitHub)
Where is information on how to install and use magic? It would be helpful.
I think it is a bug. I never changed the narrative-print.css despite all the changes in the narrative web report.
You can try the following:
replace
/* Navigation
----------------------------------------------------- */
#alphabet, #navigation, #subnavigation { display:none; }
by
/* Navigation
----------------------------------------------------- */
#alphabet, #navigation, #nav, #gototop, #subnavigation, #treeContainer, .triangle, .polygon { display:none; }
Moderator: added 26 Mar 2024 as Pull Request #1692
Found a line with that navigation path in data/css/Web_Print-Default.css GitHub repository. But cannot find that file in my Fedora installation.
Where is the target file located?
The data/ directory is one of the development auxiliary directories. I think its contents gets copied to various locations during installation/configuration. Since Narrative Web pages end up encoded in a āuniversalā way, the āskinā you chose for your server is implemented by CSS stylesheets referenced by conventional names narrative-print.css and narrative-screen.css. During Narrative Web generation the original CSS files, e.g. Web_Basic-Ash.css, are copied over these conventional names.
The data/ directory is not transferred into site-packages/gramps/ during installation. I have not found it in my āproductionā library in /usr/lib/ (in fact, didnāt look long). It is present in every ādevelopmentā directory at same level as gramps/.
The destination file is the <target directory>/css/narrative-print.css
OK. So weāre talking about there being a file named that way in the folder generated by the Reports ā Web Pages ā Narrated Web Siteā¦ report? Not in the Gramps source?
I was hoping to find it in the Source on the local machine. (so the CSS would only have to be tweaked once.)
I give this file to test if that works. I think a bug report should be created. [0013160: [Narrated Web Site report] request option for a Print-friendy CSS - Gramps - Bugtracker ā Free Genealogy Software}
effectively the real file is data/css/Web_Print-Default.css which is copied at the end of the narrative web report.
Serge
I tried that mod on the Narrative print css in the NarWeb folder it made
no difference
Phil
You need to be sure the page is reloaded and the css file reactualized.
Hi Serge sorry for delayed response, I went back to basics altering too many things at once removed all V Smeets mods to be sure. Reran the Narrative Web Report and got the same result looked at narrative-print.css and found an issue with the file created so modified to include your suggestion you can see this in attached files
(As was as I found it) (As is what I modified it to) and a sample of print very nearly what I want.
Sample Print File.pdf (34.8 KB)
Serge just posted a single line-of-code patch in a Pull Requst to address this: