measure op• Data kinds: signal → table
• Call: import fullseye as fs; fs.ledger.profile_params(p, dx=1.0, n_sampling=5) (to call the implementation directly, import roughness; roughness.profile_params(p, dx=1.0, n_sampling=5); from the registry, opsroughness.get("profile_params"))
Profile roughness parameters Ra/Rq/Rz/Rt/Rp/Rv/Rsk/Rku (ISO 4287).
Arguments
p Band-processed profile (1-D).
dx Sample spacing. Has no effect on the parameters themselves, but is needed to report sampling_length
(without units the conditions of Rz cannot be stated).
n_sampling Number of sampling lengths. ISO 4287 default is 5.
★ Returns both Rz and Rt —— the definitional difference is removed here ISO 4287 Rz is "the evaluation length divided into n_sampling equal parts, with max peak height + max valley depth of each part averaged". Rt, on the other hand, is the maximum height difference over the whole evaluation length. The values differ on the same profile, and depending on literature or instrument which one "Rz" refers to varies. Return both and they cannot be mixed up.
Measured (512 points, profile cut at λc=80 µm; a row containing 1 deep scratch was chosen):
Rz (mean of 5 parts) 1.5076
Rz_max (max over parts) 5.4706
Rt (whole eval. length) 5.4706
Rt / Rz 3.63
Since the scratch lies in only 1 part, averaging over 5 parts dilutes its contribution to 1/5. On the same profile, numbers differing by 3.6x are both called "Rz". Removing just the scratch from the same row lowers Rt/Rz to 1.21 —— the gap opens only when there is an isolated feature, so "they agree on our instrument, so they are the same" only means no counterexample has been hit.
★ Pitfall —— the Rz of a single profile does not represent the areal Sz On a surface whose machining marks run along the rows (512x512, 4 deep scratches, λc=80 µm), measured with 171 profiles taken per direction:
• Rq along the columns, perpendicular to the marks, is 2.67x that along the parallel rows (0.1853 vs 0.0694). Same surface, same instrument, only the direction differs.
• Rt along the rows ranges from min 0.2765 to max 5.4706, a spread of 19.8x.
• Profiles reaching 80 % of the areal Sz (5.9694): 6 of 171 (3.5 %).
A few profiles suffice for Rq but not for Rz —— even for the same 1-D profile, the number of profiles needed differs per parameter. When reporting Rz, always state the number and direction of profiles.
Definition details (deviations from the standard are stated explicitly here)
• The reference line is the mean line over the whole evaluation length (not a least-squares line). Remove tilt beforehand with surface_form_remove or surface_filter.
• Rp / Rv / Rsk / Rku are computed over the whole evaluation length (not averaged per part).
• If the evaluation length is not divisible by n_sampling, the remainder is discarded. The number of discarded points is returned in dropped_samples.
fail-closed
• Not 1-D / fewer than 8 points / contains NaN or Inf.
• n_sampling is less than 1, or a part would have fewer than 4 points.
• The profile is perfectly flat (Rq=0).
• surface_roughness family guide
• Sample-data catalog (download URLs / licences) — 2-D uses skimage.data (BSD/public domain) plus synthetic images; 3-D lists download URLs for real data sources (Stanford, PDS, …).
• Operator provenance and references — the sources of the research/methods this op family came from.
• The canonical algorithm (author, year) and its uses are named in the family usage guide above.
• poc_food_cutting_measure — py -3.11 examples/poc_food_cutting_measure.py
• poc_surface_roughness — py -3.11 examples/poc_surface_roughness.py
table as input)—
measure)*Provenance: roughness.py — ROUGHNESS operator registry. This per-op note is generated by tools/opdocs.py md (do not hand-edit).*
© 2026 Kazufumi Furuse — Fullseye operator documentation. Licensed under Apache-2.0.