Logarithmic Calibration, Mixed Axes and Y Direction

This guide (V08) documents three aspects of Curve Digitalizer: X-log/Y-linear axes, X-log/Y-log axes and the vertical direction of the full-image calibration.

1. Three Canonical Images and Three Configurations

Three reproducible synthetic images were created and imported through the GX-TXT Acquisition Handler as true Image Datasets with the image.raster contract. They are neither experimental photographs nor screenshots of the interface.

Test configurationSource and purpose
V08 Mixed LogX LinearYGraph with logarithmic X, linear Y
V08 Both Axes LogGraph with both X/Y logarithmic
V08 Pixel Y DirectionPixel rows to compare Upward and Downward

2. The First Graph: Logarithmic X and Linear Y

The first example shows Frequency, from 1 to 1000 Hz on a logarithmic scale, and Linear response, from 0 to 100 mV on a linear scale. The quadrilateral with four targets is deliberately in slight perspective.

After creating the Digitizer Configuration, the source was confirmed with Preview source image → Use this image. The yellow verification point nominally corresponds to about 31.622777 Hz and 45 mV.

Preview source image dialog for the synthetic graph with logarithmic X and linear Y axes.
Figure 1. The mixed raster is checked before linking it to the new Digitizer Configuration.

3. Constraint: The Limits of a Log Axis Cannot Be Zero or Negative

Selecting X Scale = log and Minimum = 0, the Apply axis settings command rejected the input with:

Invalid axis configuration: Logarithmic axes require positive limits.

Error message stating that logarithmic axes require positive limits, with X Minimum set to 0.
Figure 3. The logarithmic configuration does not accept zero limits.

The same check was exercised with Minimum = −1, again rejected.

Error message rejecting X Minimum −1 on a logarithmic axis.
Figure 4. A negative minimum cannot be stored as a valid logarithmic axis.

The axes of the previous Workspace remained unchanged. Both limits of every logarithmic axis must be strictly positive and different. In the mixed example, on the other hand, the limit Y=0 mV is valid, because Y remains linear.

4. Setting and Applying the Mixed Calibration

In the X axis panel, enter Label = Frequency, Unit = Hz, Minimum = 1, Maximum = 1000, Scale = log. In the Y axis panel, use Label = Linear response, Unit = mV, Minimum = 0, Maximum = 100, Scale = linear.

Axis settings with Frequency in Hz from 1 to 1000 on a log scale and Linear response in mV from 0 to 100.
Figure 5. A mixed calibration accepts zero on the linear Y axis but not on the logarithmic X axis.

Press Apply axis settings. The framework confirms that X and Y have distinct scientific scales. These fields do not yet establish where the physical corners of the graph are in the raster.

5. Four Corners of the Mixed Source

Press the Set BL, Set BR, Set TL, Set TR buttons in order, clicking the original targets of the graph area.

First calibration marker placed at the bottom-left corner of the mixed graph.
Figure 6. The Set BL button creates a real geometric reference and increments the corner count.
Four calibration markers placed on the corners of the mixed graph.
Figure 7. The non-affine quadrilateral is calibrated with four clicks without publishing numerical curves.

After the fourth click, the GUI showed Calibration ready, with four cyan markers. The model determined a non-affine projective homography, valid with mixed numerical axes as well.

Calibration ready status with homography condition and corner RMS for the mixed graph.
Figure 8. The interface shows the homography condition, the geometric RMS and four markers on the source points.

The value corner RMS ≈ 2.3×10⁻¹⁶ describes the residual of the four points used to determine the matrix; it does not measure the real uncertainty of the experiment.

6. Formula for Logarithmic X, Linear Y

After the pixels are projected into normalized coordinates (u,v), GX-TXT applies a transformation for each axis.

For logarithmic X: X = 10^(log10(Xmin) + u × [log10(Xmax) − log10(Xmin)]).

With Xmin=1 and Xmax=1000: X = 10^(3u) Hz.

For linear Y: Y = Ymin + v × (Ymax − Ymin) = 100v mV.

The synthetic control point was drawn at (u,v)=(0.5; 0.45), so its nominal coordinates are √1000 ≈ 31.622777 Hz and 45 mV. The logarithmic transformation is not a canvas zoom: it changes the scientific mapping of the coordinates.

7. Independent Verification of the Mixed Graph

With Verify calibration… open, the yellow marker was clicked in the GUI and Expected X = 31.622776601683793, Expected Y = 45 were entered. The actual Tk event (366,394) corresponded to about (674.0719; 473.0216) source pixels.

QuantityExpectedCalculatedΔ physical
Frequency X31.622777 Hz31.31893 Hz−0.3038503 Hz
Linear response Y45 mV45.18386 mV+0.1838589 mV
Calibration verification of the mixed graph with Expected, Calculated and residual values.
Figure 9. The inline panel distinguishes a logarithmic residual in decades for X and a percentage residual for Y.

A second numerical solution of the matrix, run on the four saved corners, returned 31.3189263 Hz and 45.1838589 mV, consistent with the figures shown in the interface.

8. Decades and Percentages Are Different Comparisons

In the Relative / log column, the Viewer showed for logarithmic X:

−0.004193135 decades (×0.9903914)

For linear Y:

+0.4085754 %

Relative / log column showing decades for X and a percentage for Y.
Figure 10. The residuals of the same verification use different units according to the scale of each axis.

The logarithmic comparison uses log10(Calculated / Expected), while a linear relative comparison uses (Calculated − Expected) / Expected × 100%, when the reference allows it.

These numbers are residuals of a verified point, not statistical uncertainties or estimates of general accuracy.

9. Opening a Log-Log Dataset Without Relinking the First Configuration

The second example uses a new Digitizer Configuration and another source: v08.loglog_positive. The first configuration stays linked to its own Image Dataset.

Second configuration linked to the log-log synthetic graph v08.loglog_positive.
Figure 11. A second Digitizer Configuration keeps a canonical source distinct from the first one.

The log-log figure declares Frequency X = 1–1000 Hz and Intensity Y = 1–1000 a.u., both logarithmic. The central yellow point nominally represents √1000 on each axis.

10. Rejection of Zero and Negative Values on a Logarithmic Y

With Y Scale = log, a Y Minimum equal to 0 was tried.

Error message rejecting Y Minimum 0 on a logarithmic Y axis.
Figure 12. The positivity constraint is checked independently on the Y axis too.

A Y Minimum equal to −1 was then tried.

Error message rejecting Y Minimum −1 on a logarithmic Y axis.
Figure 13. No logarithmic axis with non-positive values is saved in the Session.

Both attempts were rejected with Logarithmic axes require positive limits.

11. Applying Two Logarithmic Axes

Fill in X Frequency / Hz, Minimum 1, Maximum 1000, Scale log, and Y Intensity / a.u., Minimum 1, Maximum 1000, Scale log. Apply through Apply axis settings.

Then acquire the four corners with Set BL / BR / TL / TR. The result is a valid quadrilateral with a single four-corner homography: the two scientific axes transform the normalized coordinates independently.

Log-log graph calibrated with four markers and Calibration ready.
Figure 15. The same geometric homography supports the logarithmic conversion of both coordinates.

12. Mathematics and Verification of the Log-Log Graph

With both axes between 1 and 1000 on a logarithmic scale:

X = 10^(3u) Hz and Y = 10^(3v) a.u..

At the normalized point (0.5; 0.5), both are equal to √1000 ≈ 31.6227766. The actual click on the yellow control happened on the canvas at (367,379), equivalent to about (675.9137; 445.3957) source pixels.

The GUI showed:

AxisExpectedCalculatedLogarithmic residual
X · Frequency31.622777 Hz31.44566 Hz−0.002439231 decades
Y · Intensity31.622777 a.u.31.85506 a.u.+0.003178412 decades
Calibration verification of the log-log graph with residuals in decades.
Figure 16. Both deviations are given in decades and multiplicative ratios.
Detail of the log-log verification panel with X and Y results.
Figure 17. The logarithmic transformation must not be interpreted as a change of zoom.

13. The Logarithmic Expected Reference Must Also Be Positive

Expected Y = 0 was deliberately entered during the log-log verification. The already calculated Y result stayed visible, but the comparison showed:

Y1: A logarithmic axis requires a strictly positive physical reference.

The comparison column indicated Invalid reference.

Calibration verification showing Invalid reference for Expected Y equal to 0 on a log axis.
Figure 18. The calculated physical coordinate stays visible, while the comparison with a zero or negative log Expected value is invalid.

Restoring a positive Expected value makes the comparison available again. Neither the original Dataset nor the calibration corners are removed.

14. A Third Source to Separate the Y Direction from Log Axes

The Calibration tab includes a Y direction control with two entries:

  • Upward (Cartesian)
  • Downward (image pixels)

This selector is used in the A · Full image → Auto-calibrate full image procedure. On its own it does not change a previous manual log-log calibration.

To avoid confusion between the direction of Y and its logarithmic scale, a third, neutral Dataset was created, with horizontal lines labeled in source pixels.

Neutral synthetic raster with horizontal lines labeled in source pixels.
Figure 19. The vertical direction test uses a raster separate from the two scientific graphs.

15. Downward (image pixels): Y Increases Downward

In the third configuration, Downward (image pixels) was selected and Auto-calibrate full image was pressed.

For the 1280×900 PNG, the CORE saved the axes X 0–1279 px, Y Minimum 899 px / Maximum 0 px and four corners matching the original raster boundaries.

Full-image calibration in Downward (image pixels) mode with Y from 899 to 0 px.
Figure 20. In Downward mode, the calibrated Y increases going down the image.

The scale stays linear and the unit px. With this choice the Y of an original pixel is directly its row: for example, pixel 180 has calibrated Y 180 and pixel 700 has calibrated Y 700.

16. Switching to Upward (Cartesian) Requires Confirmation

Selecting Upward (Cartesian) does not automatically replace the calibration that is already valid. Pressing Auto-calibrate full image again, the Viewer showed:

Replace the existing calibration and axis limits with full-image pixel coordinates? Existing digitized points will be recalculated, not deleted.

Confirmation dialog asking to replace the existing calibration with full-image pixel coordinates.
Figure 21. The Y direction menu on its own does not silently replace a previous calibration.

17. Upward (Cartesian): Same Geometry, Inverted Y Numbers

After the new calibration, the Y axis became Minimum 0 px / Maximum 899 px, keeping the same four pixel corners and the same SHA-256 of the source.

Full-image calibration in Upward (Cartesian) mode with Y from 0 to 899 px.
Figure 22. The model keeps the same four source corners but interprets Y in the Cartesian sense.

The mathematical comparison on the same raster is:

Original pixel YDownwardUpward
180180 px719 px
700700 px199 px

For Upward the transformation is Y = (H − 1) − pixel_y, with H=900. The difference concerns the interpretation of the coordinates, not a flip of the PNG pixels.

18. Actual Verification of a Pixel in Cartesian Mode

The Verify calibration… panel was also used for the third configuration. The original click near (500,180) became, after rounding on the canvas, (499.1079; 180.1871) source pixels.

With Expected X = 500 and Expected Y = 719, the Viewer calculated:

Calculated X = 499.1079 px
Calculated Y = 718.8129 px

Calibration verification in Cartesian mode with Expected X 500 and Expected Y 719.
Figure 23. The values calculated by the interface agree with the transformation Y = 899 minus pixel_y.

The small deviation is compatible with the discretization of the click. The independent reconstruction confirmed the value. The Y direction of the full-image calibration remains distinct from the Scale = log setting of scientific graphs.

19. Do Not Confuse Direction, Scale and Geometry

The log scale changes the relationship between normalized coordinates and scientific values. Y direction, instead, determines the orientation of the pixel axes when Auto-calibrate full image is used.

A new full-image calibration resets the axes to px, linear: it must not be applied to an already calibrated logarithmic graph in the belief that it only changes the direction of Y. For a manual graph, you need to read the actual physical limits, choose the appropriate mapping and verify known points.

The model can produce corner RMS values close to zero even on a scientifically misinterpreted graph. Always check the semantics of the labels in the image, not just the geometric matrix.

20. Saving and Reopening the Three Configurations

The configurations were saved and reopened through the normal Viewer commands, in the same Session. The CORE returned three separate Workspaces, each linked to its original Image Dataset.

Reopened third configuration with the pixel-line raster and its Y direction.
Figure 24. The source and the Y direction stay linked to the same canonical Workspace.
Reopened first configuration with the mixed logarithmic-linear graph.
Figure 25. Closing the interface did not swap the first image with the other two Datasets.
Reopened log-log configuration with four calibration markers.
Figure 26. The four corners and the positive double-log axes have persisted in the Session.

21. Essential Operating Procedure

For an X-log/Y-linear graph, set Scale = log only on X, using positive limits for X; Y stays linear even if it includes zero. For a log-log graph, both limits of both axes must be strictly positive.

After Apply axis settings, click Set BL / Set BR / Set TL / Set TR, check Calibration ready and verify at least one known point with Verify calibration…, distinguishing physical deviations, percentages and decades.

For the vertical direction of the whole raster, select Y direction → Upward/Downward and actually apply Auto-calibrate full image, checking the axes and any replacement confirmation.