ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: "Thomas A. Schmitz" <thomas.schmitz@uni-bonn.de>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: [NTG-context] save runtime information
Date: Tue, 19 Nov 2024 23:38:58 +0100	[thread overview]
Message-ID: <76a670b3-72f8-4fb7-87a0-db3b52fa9160@uni-bonn.de> (raw)

Hi,

a couple of years ago, I asked whether it was possible to typeset the 
information about runtime that I get at the end of the context run. Hans 
provided an answer 
(https://www.mail-archive.com/ntg-context@ntg.nl/msg90554.html):

> it's in the log file:
> 
> local data    = io.loaddata("oeps.log") or ""
> 
> local pattern = "> runtime: ([%d%.]+) seconds, ([%d]+) processed pages, ([%d]+) shipped pages, ([%d%.]+) pages/second"
> 
> 
> local r, n, s, p = string.match(data,pattern)
> 
> print(r,n,s,p)

The information I get this way is inaccurate. The runtime (in seconds) I 
see at the end of the run on the terminal:

5.635

vs. the value I get with the code:

0.660260200500488

I'm not sure whether something has changed with lmtx or if this was the 
case before (the log file is being written to during the run, so this 
may explain the difference?). So my question from then still stands: is 
it possible to extract the real runtime somehow? I would like to write 
it to a different file at the end of the run. What would be the best way 
to do this?

All best

Thomas


___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki     : https://wiki.contextgarden.net
___________________________________________________________________________________

             reply	other threads:[~2024-11-19 22:43 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-11-19 22:38 Thomas A. Schmitz [this message]
2024-11-20  8:10 ` [NTG-context] " Hans Hagen
2024-11-20 21:10   ` Thomas A. Schmitz

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=76a670b3-72f8-4fb7-87a0-db3b52fa9160@uni-bonn.de \
    --to=thomas.schmitz@uni-bonn.de \
    --cc=ntg-context@ntg.nl \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).