diff --git a/CLAUDE.md b/CLAUDE.md index e49542b1..c2b697e4 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -6,8 +6,8 @@ Guidance for Claude Code (and humans) working in this repository. Nyxus is a scalable C++/Python library that computes engineered features (intensity, texture, morphology, moments, digital-filter) from segmented and -whole-slide/whole-volume images. It computes 758 features in all, 539 for 2D -images, 213 for 3D volumes and 6 image quality features, at the ROI or +whole-slide/whole-volume images. It computes 760 features in all, 540 for 2D +images, 214 for 3D volumes and 6 image quality features, at the ROI or whole-image level (`docs/tools/gen_feature_reference.py --check` keeps these counts equal to the code), and is designed to operate at any scale by assembling ROIs that span multiple image diff --git a/README.md b/README.md index 188d3fc7..18c29738 100644 --- a/README.md +++ b/README.md @@ -7,7 +7,7 @@ [![Conda Downloads](https://img.shields.io/conda/dn/conda-forge/nyxus?label=Conda%20downloads)](https://anaconda.org/conda-forge/nyxus) Nyxus computes intensity, texture, morphology and image quality features for every region of -interest (ROI) in 2D images and 3D volumes: 758 features in all, 539 for 2D images, 213 for 3D +interest (ROI) in 2D images and 3D volumes: 760 features in all, 540 for 2D images, 214 for 3D volumes and 6 image quality features. It runs from Python or the command line, reads TIFF, OME-TIFF, OME-Zarr, NIfTI and DICOM files (OME-TIFF and OME-Zarr with up to five dimensions), and assembles ROIs that span several image tiles. Each feature's validation against reference tools diff --git a/docs/examples/glcm_3d_worked_example.py b/docs/examples/glcm_3d_worked_example.py index 80ba6925..442ee4f2 100644 --- a/docs/examples/glcm_3d_worked_example.py +++ b/docs/examples/glcm_3d_worked_example.py @@ -59,7 +59,7 @@ def check(table, column, expected, what): # Default settings (64-level binning, ordered pairs) default = run(img, seg, "default", False) for column, expected in {"3GLCM_CONTRAST": 478.61, "3GLCM_CONTRAST_AVE": 620.39, - "3GLCM_JVAR": 257.66, "3GLCM_VARIANCE": 334.03}.items(): + "3GLCM_JVAR": 334.03, "3GLCM_VARIANCE": 334.03}.items(): check(default, column, expected, "default") # 3glcm/greydepth and coarse_gray_depth both set the number of levels diff --git a/docs/examples/glcm_worked_example.py b/docs/examples/glcm_worked_example.py index 75fd2b97..1ba5d1cd 100644 --- a/docs/examples/glcm_worked_example.py +++ b/docs/examples/glcm_worked_example.py @@ -30,13 +30,16 @@ # Values the page quotes for the default settings (64-level binning, ordered pairs) default = Nyxus(["*ALL_GLCM*"]).featurize(img, mask) -quoted = {"CONTRAST": 473.45, "VARIANCE": 332.44, "JVAR": 345.41, "CLUSHADE": -585.66, - "SUMVARIANCE": 882.25, "CLUTEND": 882.25} +quoted = {"CONTRAST": 473.45, "VARIANCE": 332.44, "JVAR": 332.44, "CLUSHADE": 9490.19, + "SUMVARIANCE": 867.43, "CLUTEND": 867.43} for name, expected in quoted.items(): got = default[f"GLCM_{name}_0"][0] assert math.isclose(got, expected, rel_tol=5e-4), f"default GLCM_{name}_0 = {got}, page says {expected}" +mirrored = Nyxus(["*ALL_GLCM*"]).featurize(np.ascontiguousarray(img[:, ::-1]), mask) +assert math.isclose(mirrored["GLCM_CLUSHADE_0"][0], 9490.19, rel_tol=5e-4), "mirrored cluster shade" +assert math.isclose(default["GLCM_HOM2_AVE"][0], default["GLCM_IDM_AVE"][0], rel_tol=1e-12), "HOM2_AVE vs IDM_AVE" -# The default-settings values the IBSI definitions give on the same 64-level matrix of ordered pairs +# The default-settings values are the IBSI definitions on the same 64-level matrix of ordered pairs binned = np.minimum(np.floor(64 * img.astype(int) / 5 + 1), 64).astype(int) P = np.zeros((64, 64)) for r in range(5): diff --git a/docs/feature_descriptions.toml b/docs/feature_descriptions.toml index 3f5cce07..8c06e999 100644 --- a/docs/feature_descriptions.toml +++ b/docs/feature_descriptions.toml @@ -257,9 +257,9 @@ ANG_BW_NEIGHBORS_MODE = "Most frequent direction, rounded to whole degrees, from [glcm] GLCM_ASM = "Angular second moment: the sum of the squared co-occurrence probabilities, which is high when a few grey-level pairs dominate (a uniform texture)." GLCM_ACOR = "Autocorrelation: the co-occurrence-weighted mean of the product of the two grey levels of a pixel pair, which grows with both coarseness and brightness." -GLCM_CLUPROM = "Cluster prominence: the fourth moment of the sum of the two grey levels of a pair about twice the neighbour pixel's mean grey level, which is large when that distribution is asymmetric or heavy-tailed." -GLCM_CLUSHADE = "Cluster shade: the third moment of the sum of the two grey levels of a pair about twice the neighbour pixel's mean grey level, which measures the skewness of the co-occurrence matrix." -GLCM_CLUTEND = "Cluster tendency: the second moment of the sum of the two grey levels of a pair about twice the neighbour pixel's mean grey level, which measures how strongly pairs group into similar grey levels." +GLCM_CLUPROM = "Cluster prominence: the fourth moment of the sum of the two grey levels of a pair about its mean, the sum of the two pixels' mean grey levels, which is large when that distribution is asymmetric or heavy-tailed." +GLCM_CLUSHADE = "Cluster shade: the third moment of the sum of the two grey levels of a pair about its mean, the sum of the two pixels' mean grey levels, which measures the skewness of the co-occurrence matrix." +GLCM_CLUTEND = "Cluster tendency: the second moment of the sum of the two grey levels of a pair about its mean, the sum of the two pixels' mean grey levels, which measures how strongly pairs group into similar grey levels; it returns the same value as GLCM_SUMVARIANCE." GLCM_CONTRAST = "Contrast: the co-occurrence-weighted mean squared grey-level difference between the two pixels of a pair, which grows with local intensity variation." GLCM_CORRELATION = "Correlation: the linear correlation, from -1 to 1, between the grey levels of the two pixels of a pair." GLCM_DIFAVE = "Difference average: the mean absolute grey-level difference between the two pixels of a pair, taken from the distribution of those differences." @@ -269,21 +269,21 @@ GLCM_DIS = "Dissimilarity: the co-occurrence-weighted mean absolute difference b GLCM_ENERGY = "Energy: the sum of the squared co-occurrence probabilities; it returns the same value as GLCM_ASM." GLCM_ENTROPY = "Entropy: the base-2 entropy of the co-occurrence probabilities, which is high when many grey-level pairs are about equally likely; it returns the same value as GLCM_JE." GLCM_HOM1 = "Homogeneity 1: the co-occurrence probabilities weighted by one over one plus the grey-level difference of the pair; it returns the same value as GLCM_ID." -GLCM_HOM2 = "Homogeneity 2: the co-occurrence probabilities weighted by one over one plus the squared grey-level difference of the pair; it returns the same value as GLCM_IDM and has no _AVE code." +GLCM_HOM2 = "Homogeneity 2: the co-occurrence probabilities weighted by one over one plus the squared grey-level difference of the pair; it returns the same value as GLCM_IDM." GLCM_ID = "Inverse difference: the co-occurrence probabilities weighted by one over one plus the grey-level difference of the pair, which is high when paired pixels have similar grey levels." GLCM_IDN = "Inverse difference normalized: inverse difference with the grey-level difference divided by the number of grey levels, which makes it less dependent on the number of grey levels." GLCM_IDM = "Inverse difference moment: the co-occurrence probabilities weighted by one over one plus the squared grey-level difference of the pair, a measure of local homogeneity." GLCM_IDMN = "Inverse difference moment normalized: inverse difference moment with the squared grey-level difference divided by the squared number of grey levels." -GLCM_INFOMEAS1 = "Informational measure of correlation 1: the joint entropy minus the entropy expected if the two grey levels were independent, divided by the entropy of one marginal distribution; it measures how much the two grey levels depend on each other." +GLCM_INFOMEAS1 = "Informational measure of correlation 1: the joint entropy minus the entropy expected if the two grey levels were independent, divided by the larger of the two marginal entropies; it measures how much the two grey levels depend on each other." GLCM_INFOMEAS2 = "Informational measure of correlation 2: a 0-to-1 measure of the dependence between the two grey levels of a pair, computed from the gap between the joint entropy and the entropy of the product of the marginals." GLCM_IV = "Inverse variance: the distribution of grey-level differences between paired pixels weighted by one over the squared difference, leaving out pairs with equal grey levels." GLCM_JAVE = "Joint average: the co-occurrence-weighted mean grey level of the reference pixel of a pair." GLCM_JE = "Joint entropy: the base-2 entropy of the co-occurrence probabilities, which is high when many grey-level pairs are about equally likely." GLCM_JMAX = "Joint maximum: the largest co-occurrence probability, that is the share of pairs taken by the most common grey-level pair." -GLCM_JVAR = "Joint variance: the co-occurrence-weighted spread of the neighbour pixel's grey level around the joint average (the reference pixel's mean); it equals GLCM_VARIANCE only when the matrix is symmetric." +GLCM_JVAR = "Joint variance: the co-occurrence-weighted variance of the reference pixel's grey level about the joint average; it returns the same value as GLCM_VARIANCE." GLCM_SUMAVERAGE = "Sum average: the mean of the sum of the two grey levels of a pixel pair." GLCM_SUMENTROPY = "Sum entropy: the base-2 entropy of the distribution of the sum of the two grey levels of a pixel pair." -GLCM_SUMVARIANCE = "Sum variance: the spread of the sum of the two grey levels of a pair about twice the neighbour pixel's mean grey level; this code returns the cluster tendency value, the same as GLCM_CLUTEND." +GLCM_SUMVARIANCE = "Sum variance: the variance of the sum of the two grey levels of a pair; it returns the same value as GLCM_CLUTEND." GLCM_VARIANCE = "Variance: the co-occurrence-weighted variance of the reference pixel's grey level about its mean (PyRadiomics sum of squares)." GLCM_ASM_AVE = "Angular second moment, averaged over the angles." GLCM_ACOR_AVE = "Autocorrelation, averaged over the angles." @@ -299,6 +299,7 @@ GLCM_DIS_AVE = "Dissimilarity, averaged over the angles." GLCM_ENERGY_AVE = "Energy, averaged over the angles." GLCM_ENTROPY_AVE = "Entropy, averaged over the angles." GLCM_HOM1_AVE = "Homogeneity 1, averaged over the angles." +GLCM_HOM2_AVE = "Homogeneity 2, averaged over the angles." GLCM_ID_AVE = "Inverse difference, averaged over the angles." GLCM_IDN_AVE = "Inverse difference normalized, averaged over the angles." GLCM_IDM_AVE = "Inverse difference moment, averaged over the angles." @@ -683,9 +684,9 @@ RADIAL_CV = "Multi-column feature RADIAL_CV_0 to RADIAL_CV_7: for each of the 8 [glcm_3d] 3GLCM_ACOR = "Autocorrelation: the co-occurrence-weighted mean of the product of the two grey levels of a voxel pair, which grows with both coarseness and brightness." 3GLCM_ASM = "Angular second moment: the sum of the squared co-occurrence probabilities, which is high when a few grey-level pairs dominate (a uniform texture)." -3GLCM_CLUPROM = "Cluster prominence: the fourth moment of the sum of the two grey levels of a pair about twice the mean grey level, which is large when that distribution is asymmetric or heavy-tailed." -3GLCM_CLUSHADE = "Cluster shade: the third moment of the sum of the two grey levels of a pair about twice the mean grey level, which measures the skewness of the co-occurrence matrix." -3GLCM_CLUTEND = "Cluster tendency: the second moment of the sum of the two grey levels of a pair about twice the mean grey level, which measures how strongly pairs group into similar grey levels." +3GLCM_CLUPROM = "Cluster prominence: the fourth moment of the sum of the two grey levels of a pair about its mean, the sum of the two voxels' mean grey levels, which is large when that distribution is asymmetric or heavy-tailed." +3GLCM_CLUSHADE = "Cluster shade: the third moment of the sum of the two grey levels of a pair about its mean, the sum of the two voxels' mean grey levels, which measures the skewness of the co-occurrence matrix." +3GLCM_CLUTEND = "Cluster tendency: the second moment of the sum of the two grey levels of a pair about its mean, the sum of the two voxels' mean grey levels, which measures how strongly pairs group into similar grey levels; it returns the same value as 3GLCM_SUMVARIANCE." 3GLCM_CONTRAST = "Contrast: the co-occurrence-weighted mean squared grey-level difference between the two voxels of a pair, which grows with local intensity variation." 3GLCM_CORRELATION = "Correlation: the linear correlation, from -1 to 1, between the grey levels of the two voxels of a pair." 3GLCM_DIFAVE = "Difference average: the mean absolute grey-level difference between the two voxels of a pair, taken from the distribution of those differences." @@ -695,21 +696,21 @@ RADIAL_CV = "Multi-column feature RADIAL_CV_0 to RADIAL_CV_7: for each of the 8 3GLCM_ENERGY = "Energy: the sum of the squared co-occurrence probabilities; it returns the same value as 3GLCM_ASM." 3GLCM_ENTROPY = "Entropy: the base-2 entropy of the co-occurrence probabilities, which is high when many grey-level pairs are about equally likely; it returns the same value as 3GLCM_JE." 3GLCM_HOM1 = "Homogeneity 1: the co-occurrence probabilities weighted by one over one plus the grey-level difference of the pair; it returns the same value as 3GLCM_ID." -3GLCM_HOM2 = "Homogeneity 2: the co-occurrence probabilities weighted by one over one plus the squared grey-level difference of the pair; it returns the same value as 3GLCM_IDM and has no _AVE code." +3GLCM_HOM2 = "Homogeneity 2: the co-occurrence probabilities weighted by one over one plus the squared grey-level difference of the pair; it returns the same value as 3GLCM_IDM." 3GLCM_ID = "Inverse difference: the co-occurrence probabilities weighted by one over one plus the grey-level difference of the pair, which is high when paired voxels have similar grey levels." 3GLCM_IDN = "Inverse difference normalized: inverse difference with the grey-level difference divided by the number of grey levels, which makes it less dependent on the number of grey levels." 3GLCM_IDM = "Inverse difference moment: the co-occurrence probabilities weighted by one over one plus the squared grey-level difference of the pair, a measure of local homogeneity." 3GLCM_IDMN = "Inverse difference moment normalized: inverse difference moment with the squared grey-level difference divided by the squared number of grey levels." -3GLCM_INFOMEAS1 = "Informational measure of correlation 1: the joint entropy minus the entropy expected if the two grey levels were independent, divided by the entropy of one marginal distribution; it measures how much the two grey levels depend on each other." +3GLCM_INFOMEAS1 = "Informational measure of correlation 1: the joint entropy minus the entropy expected if the two grey levels were independent, divided by the larger of the two marginal entropies; it measures how much the two grey levels depend on each other." 3GLCM_INFOMEAS2 = "Informational measure of correlation 2: a 0-to-1 measure of the dependence between the two grey levels of a pair, computed from the gap between the joint entropy and the entropy of the product of the marginals." 3GLCM_IV = "Inverse variance: the distribution of grey-level differences between paired voxels weighted by one over the squared difference, leaving out pairs with equal grey levels." 3GLCM_JAVE = "Joint average: the co-occurrence-weighted mean grey level of the reference voxel of a pair." 3GLCM_JE = "Joint entropy: the base-2 entropy of the co-occurrence probabilities, which is high when many grey-level pairs are about equally likely." 3GLCM_JMAX = "Joint maximum: the largest co-occurrence probability, that is the share of pairs taken by the most common grey-level pair." -3GLCM_JVAR = "Joint variance: the co-occurrence-weighted spread of the neighbour voxel's grey level around the joint average (the reference voxel's mean)." +3GLCM_JVAR = "Joint variance: the co-occurrence-weighted variance of the reference voxel's grey level about the joint average; it returns the same value as 3GLCM_VARIANCE." 3GLCM_SUMAVERAGE = "Sum average: the mean of the sum of the two grey levels of a voxel pair." 3GLCM_SUMENTROPY = "Sum entropy: the base-2 entropy of the distribution of the sum of the two grey levels of a voxel pair." -3GLCM_SUMVARIANCE = "Sum variance: the spread of the sum of the two grey levels of a pair about twice the mean grey level; this code returns the cluster tendency value, the same as 3GLCM_CLUTEND." +3GLCM_SUMVARIANCE = "Sum variance: the variance of the sum of the two grey levels of a pair; it returns the same value as 3GLCM_CLUTEND." 3GLCM_VARIANCE = "Variance: the co-occurrence-weighted variance of the reference voxel's grey level about its mean (PyRadiomics sum of squares)." 3GLCM_ASM_AVE = "Angular second moment, averaged over the directions." 3GLCM_ACOR_AVE = "Autocorrelation, averaged over the directions." @@ -725,6 +726,7 @@ RADIAL_CV = "Multi-column feature RADIAL_CV_0 to RADIAL_CV_7: for each of the 8 3GLCM_ENERGY_AVE = "Energy, averaged over the directions." 3GLCM_ENTROPY_AVE = "Entropy, averaged over the directions." 3GLCM_HOM1_AVE = "Homogeneity 1, averaged over the directions." +3GLCM_HOM2_AVE = "Homogeneity 2, averaged over the directions." 3GLCM_ID_AVE = "Inverse difference, averaged over the directions." 3GLCM_IDN_AVE = "Inverse difference normalized, averaged over the directions." 3GLCM_IDM_AVE = "Inverse difference moment, averaged over the directions." diff --git a/docs/source/Math/f_glcm.rst b/docs/source/Math/f_glcm.rst index e433b56f..0dbf03b6 100644 --- a/docs/source/Math/f_glcm.rst +++ b/docs/source/Math/f_glcm.rst @@ -9,8 +9,8 @@ regularity that first-order intensity statistics cannot see. :widths: 26 74 * - **Feature codes** - - ``GLCM_*``: 30 features, each with a column per direction, and 29 ``GLCM_*_AVE`` direction - averages (``GLCM_HOM2`` has none) + - ``GLCM_*``: 30 features, each with a column per direction, and 30 ``GLCM_*_AVE`` direction + averages * - **Group** - ``*ALL_GLCM*``; also part of ``*ALL*`` and ``*WHOLESLIDE*`` * - **Dimensions** @@ -22,9 +22,8 @@ regularity that first-order intensity statistics cannot see. 1024 × 1024 pixels. On a larger striped file out-of-core processing of this family raises an error or returns wrong values, depending on the ROI (see :ref:`large-images-tiles`). * - **IBSI** - - 25 of the 30 features have an IBSI identifier. Four of the other 5 return the same value as - one that does; ``GLCM_VARIANCE`` equals IBSI joint variance, which ``GLCM_JVAR`` matches only - on a symmetric matrix. + - 25 of the 30 features have an IBSI identifier. The other 5 return the same value as one that + does; ``GLCM_VARIANCE`` is IBSI joint variance, ``GLCM_JVAR``. .. tip:: @@ -204,8 +203,7 @@ Each feature produces one column per enabled direction and one average: for each direction. - ``GLCM_CONTRAST_AVE``: the mean of the per-direction values. -Each direction has its own matrix; the matrices are not merged. ``GLCM_HOM2`` has no ``_AVE`` -column; ``GLCM_IDM_AVE`` has the same value. +Each direction has its own matrix; the matrices are not merged. .. _glcm-index: @@ -271,11 +269,12 @@ the sums are spread far from their mean. .. math:: - \mathrm{CLUPROM} = \sum_{i=1}^{N_g}\sum_{j=1}^{N_g} \big(i + j - 2\mu_y\big)^4\, p_{ij} + \mathrm{CLUPROM} = \sum_{i=1}^{N_g}\sum_{j=1}^{N_g} \big(i + j - \mu_x - \mu_y\big)^4\, p_{ij} -**Possible issues.** IBSI and PyRadiomics centre on :math:`\mu_x + \mu_y`; Nyxus centres on -:math:`2\mu_y`, twice the neighbour mean. The two are equal on a symmetric matrix. With the default -counting they differ, and the value changes when the image is mirrored. +.. versionchanged:: 0.12.1+ + + Centred on :math:`\mu_x + \mu_y`, as in IBSI and PyRadiomics. Version 0.12.1 and earlier centred + on :math:`2\mu_y`, twice the neighbour mean, which differs with the default one-order counting. .. _feature-glcm-clushade: @@ -291,11 +290,14 @@ the mean the sums are spread. .. math:: - \mathrm{CLUSHADE} = \sum_{i=1}^{N_g}\sum_{j=1}^{N_g} \big(i + j - 2\mu_y\big)^3\, p_{ij} + \mathrm{CLUSHADE} = \sum_{i=1}^{N_g}\sum_{j=1}^{N_g} \big(i + j - \mu_x - \mu_y\big)^3\, p_{ij} + +With the default settings the worked example gives 9490.19, and so does its left-right mirror. -**Possible issues.** Centred on :math:`2\mu_y` like cluster prominence. The power is odd, so the -difference from IBSI can change the sign: with the default settings the worked example gives -−585.66, while the IBSI definition on the same matrix gives 9490.19. +.. versionchanged:: 0.12.1+ + + Centred on :math:`\mu_x + \mu_y`. Version 0.12.1 and earlier centred on :math:`2\mu_y`, which with + the default counting gave a different value on the worked example and on its mirror. .. _feature-glcm-clutend: @@ -310,11 +312,14 @@ Measures how grey levels group into clusters of similar values. .. math:: - \mathrm{CLUTEND} = \sum_{i=1}^{N_g}\sum_{j=1}^{N_g} \big(i + j - 2\mu_y\big)^2\, p_{ij} + \mathrm{CLUTEND} = \sum_{i=1}^{N_g}\sum_{j=1}^{N_g} \big(i + j - \mu_x - \mu_y\big)^2\, p_{ij} + +**Relations.** Equal to ``GLCM_SUMVARIANCE`` on every matrix: :math:`\mu_x + \mu_y` is the sum +average. -**Relations.** ``GLCM_SUMVARIANCE`` returns the same value. +.. versionchanged:: 0.12.1+ -**Possible issues.** Centred on :math:`2\mu_y` like cluster prominence. + Centred on :math:`\mu_x + \mu_y`. Version 0.12.1 and earlier centred on :math:`2\mu_y`. .. _feature-glcm-contrast: @@ -480,7 +485,7 @@ the grey-level difference. Homogeneity 2 ^^^^^^^^^^^^^ -:Code: ``GLCM_HOM2`` (no ``_AVE`` column) +:Code: ``GLCM_HOM2`` :Range: :math:`(0, 1]`, dimensionless Measures how close the pairs are to the matrix diagonal, with a weight that falls off with the @@ -490,7 +495,11 @@ square of the grey-level difference. \mathrm{HOM2} = \sum_{i=1}^{N_g}\sum_{j=1}^{N_g} \frac{p_{ij}}{1+(i-j)^2} -**Relations.** Equal to ``GLCM_IDM``; for the direction average use ``GLCM_IDM_AVE``. +**Relations.** Equal to ``GLCM_IDM``, and ``GLCM_HOM2_AVE`` to ``GLCM_IDM_AVE``. + +.. versionadded:: 0.12.1+ + + ``GLCM_HOM2_AVE``. .. versionchanged:: 0.11.0+ @@ -578,12 +587,15 @@ Values closer to −1 mean stronger dependence. .. math:: - \mathrm{IMC1} = \frac{HXY - HXY1}{HY} + \mathrm{IMC1} = \frac{HXY - HXY1}{\max(HX, HY)} + +When :math:`HX = HY = 0` the result is the ``--noval`` substitute. + +.. versionchanged:: 0.12.1+ -**Possible issues.** IBSI and PyRadiomics divide by :math:`\max(HX, HY)`; Nyxus divides by -:math:`HY`, the entropy of the neighbour marginal. On a symmetric matrix :math:`HX = HY`, so the -difference shows only with the default counting, where the value can change when the image is -mirrored. When :math:`HY = 0` the result is the ``--noval`` substitute. + Divided by :math:`\max(HX, HY)`, as in IBSI and PyRadiomics. Version 0.12.1 and earlier divided + by :math:`HY`, the entropy of the neighbour marginal, so with the default counting the value + could change when the image was mirrored. .. _feature-glcm-infomeas2: @@ -682,12 +694,14 @@ Measures the spread of grey levels in the counted pairs around the joint average .. math:: - \mathrm{JVAR} = \sum_{i=1}^{N_g}\sum_{j=1}^{N_g} (j-\mu_x)^2\, p_{ij} + \mathrm{JVAR} = \sum_{i=1}^{N_g}\sum_{j=1}^{N_g} (i-\mu_x)^2\, p_{ij} -**Possible issues.** IBSI defines joint variance as :math:`\sum_{i,j}(i-\mu_x)^2\,p_{ij}`; Nyxus -takes the neighbour's level :math:`j` around the reference mean :math:`\mu_x`. The two agree on a -symmetric matrix. With the default counting they differ: 345.41 instead of 332.44 on the worked -example with 64-level binning. ``GLCM_VARIANCE`` gives the IBSI value in both cases. +**Relations.** Equal to ``GLCM_VARIANCE``. + +.. versionchanged:: 0.12.1+ + + The reference pixel's level :math:`i` around its mean, as IBSI defines joint variance. Version + 0.12.1 and earlier took the neighbour's level :math:`j`, which differs with the default counting. .. _feature-glcm-sumaverage: @@ -734,13 +748,18 @@ Measures the spread of the sums of the two grey levels in a pair. .. math:: - \mathrm{SUMVARIANCE} = \sum_{i=1}^{N_g}\sum_{j=1}^{N_g} \big(i + j - 2\mu_y\big)^2\, p_{ij} + \mathrm{SUMVARIANCE} = \sum_{k=2}^{2N_g} \big(k - \mu_x - \mu_y\big)^2\, p_{x+y}(k) + +where :math:`\mu_x + \mu_y = \sum_k k\,p_{x+y}(k)` is the IBSI sum average. + +**Relations.** Equal to ``GLCM_CLUTEND`` on every matrix. On the worked example with the default +settings it is 867.43. With PyRadiomics-style binning and missing grey levels ``GLCM_SUMAVERAGE`` +is not :math:`\mu_x + \mu_y` (see :ref:`glcm-possible-issues`). -**Relations.** Nyxus returns the ``GLCM_CLUTEND`` value. IBSI defines sum variance as -:math:`\sum_k (k - \mathrm{SUMAVERAGE})^2\, p_{x+y}(k)`, the same quantity on a symmetric matrix. +.. versionchanged:: 0.12.1+ -**Possible issues.** With the default counting the two differ: 882.25 instead of 867.43 on the -worked example with 64-level binning. + Version 0.12.1 and earlier returned cluster tendency centred on :math:`2\mu_y`, which differs + with the default counting. .. _feature-glcm-variance: @@ -758,8 +777,8 @@ of squares*. \mathrm{Variance} = \sum_{i=1}^{N_g}\sum_{j=1}^{N_g} (i-\mu_x)^2\, p_{ij} -**Relations.** Matches the IBSI definition of joint variance on every matrix; ``GLCM_JVAR`` matches -it only on a symmetric one. +**Relations.** Matches the IBSI definition of joint variance on every matrix, and returns the same +value as ``GLCM_JVAR``. .. _glcm-possible-issues: @@ -769,35 +788,21 @@ Possible issues Asymmetric matrix by default With the default (positive) ``--coarseGrayDepth`` each ordered pair is counted once, while - PyRadiomics, MIRP and IBSI count both orders. Features that use only one side of the pair then - take it from a fixed side, and some mix the two sides: - - .. list-table:: - :widths: 40 60 - :header-rows: 1 - - * - Feature - - Difference from IBSI with the default settings - * - ``CLUPROM``, ``CLUSHADE``, ``CLUTEND``, ``SUMVARIANCE`` - - Centred on :math:`2\mu_y` instead of :math:`\mu_x + \mu_y` - * - ``JVAR`` - - Neighbour level around the reference mean - * - ``INFOMEAS1`` - - Divides by :math:`HY` instead of :math:`\max(HX, HY)` - - These values can change when the image is mirrored. Run in IBSI mode to match IBSI, - PyRadiomics or MIRP. + PyRadiomics, MIRP and IBSI count both orders. Every feature still follows its IBSI definition, + but on a matrix that is not symmetric: the features that read one side of the pair, such as + ``JAVE``, ``VARIANCE`` and ``JVAR``, read the reference pixel's, and their values can change when + the image is mirrored. Run in IBSI mode to match IBSI, PyRadiomics or MIRP; PyRadiomics with + ``symmetricalGLCM=False`` counts one order, as Nyxus does by default. Constant ROI Before building any matrix, Nyxus bins the ROI's minimum and maximum intensities to ``--coarseGrayDepth`` levels counted from 0 (``glcm/greydepth`` from Python), in IBSI mode too. - When the two fall into the same level, every GLCM feature returns 0, whatever ``--noval`` is, - a known defect (`#511 `__): the substitute is written and then overwritten by the empty - per-angle results, which the output pads with 0. + When the two fall into the same level, every GLCM feature, the ``_AVE`` columns included, + returns the ``--noval`` substitute (0 by default, and always 0 from Python). This covers a constant ROI and, with a positive grey depth :math:`N` (64 by default), any ROI whose minimum is at least :math:`(N-1)/N` of its maximum: in IBSI mode with the default - :math:`N`, a ROI of intensities 1000 and 1001 returns 0 in every column, while one of 10 and - 11 does not. With a zero or negative ``--coarseGrayDepth`` only a constant ROI does. + :math:`N`, a ROI of intensities 1000 and 1001 returns the substitute in every column, while one + of 10 and 11 does not. With a zero or negative ``--coarseGrayDepth`` only a constant ROI does. ROI with too many grey levels In IBSI mode the matrix has one row and one column per integer level up to the ROI's maximum. @@ -812,12 +817,11 @@ Grey-level values and indices binned values present in the ROI. Most features use those values, but ``DIS``, ``HOM1``, ``HOM2``, ``DIFENTRO``, ``SUMENTROPY`` and the inverse-difference features use positions 1 to :math:`N_g` in that list, and ``IDN`` and ``IDMN`` divide by :math:`N_g`, the number of levels - present. ``DIFAVE``, ``SUMAVERAGE``, ``IV``, ``JVAR`` and ``DIFVAR`` are a known defect + present. ``DIFAVE``, ``SUMAVERAGE``, ``IV`` and ``DIFVAR`` are a known defect (`#510 `__) and, when the levels present are not consecutive, match neither convention. ``DIFAVE``, ``SUMAVERAGE`` and ``IV`` group pairs by the difference or sum of their positions, but weight each group by the value difference or sum of - one pair in it. ``JVAR`` takes positions minus ``JAVE``, a mean of values, and ``DIFVAR`` takes - position differences minus ``DIFAVE``. Values and positions coincide with the default binning + one pair in it, and ``DIFVAR`` takes position differences minus ``DIFAVE``. Values and positions coincide with the default binning and in IBSI mode. @@ -827,8 +831,10 @@ Validation The test suite checks every 2D GLCM feature against an independent implementation, named in the :ref:`index `. PyRadiomics and MIRP are compared on matched settings (symmetric matrix, identical grey levels), and IBSI mode reproduces the IBSI consensus values on the IBSI digital -phantom. Because the reference tools count pairs symmetrically, the default asymmetric counting is -covered by regression tests only. +phantom. With the default asymmetric counting, cluster prominence, shade and tendency, sum +variance, joint variance and the first information measure of correlation are checked against their +IBSI definitions on an independently counted matrix, on an image and on its mirror; the other +features are covered there by regression tests only. References diff --git a/docs/source/Math/f_glcm_3d.rst b/docs/source/Math/f_glcm_3d.rst index c0b01699..a28c6511 100644 --- a/docs/source/Math/f_glcm_3d.rst +++ b/docs/source/Math/f_glcm_3d.rst @@ -10,7 +10,7 @@ along each of the 13 directions of the 26-voxel neighbourhood. Every formula is :widths: 26 74 * - **Feature codes** - - ``3GLCM_*``: 30 features, each a single column, and 29 ``3GLCM_*_AVE`` direction averages + - ``3GLCM_*``: 30 features, each a single column, and 30 ``3GLCM_*_AVE`` direction averages * - **Group** - ``*3D_GLCM*``; also part of ``*3D_ALL_TEXTURE*`` and ``*3D_ALL*`` * - **Dimensions** @@ -22,9 +22,9 @@ along each of the 13 directions of the 26-voxel neighbourhood. Every formula is When one read of the file returns the whole volume (NIfTI, or OME-Zarr chunked over all of Z), an oversized ROI stops the run with an error (see :doc:`/large_images`). * - **IBSI** - - 25 of the 30 features have an IBSI identifier. Four of the other 5 return the same value as - one that does; ``3GLCM_VARIANCE`` equals IBSI joint variance, which ``3GLCM_JVAR`` matches - only on a symmetric matrix. The ``_AVE`` codes follow the IBSI *3D:avg* aggregation (ITBB). + - 25 of the 30 features have an IBSI identifier. The other 5 return the same value as one that + does; ``3GLCM_VARIANCE`` is IBSI joint variance, ``3GLCM_JVAR``. The ``_AVE`` codes follow + the IBSI *3D:avg* aggregation (ITBB). .. tip:: @@ -280,8 +280,7 @@ Cluster prominence :Code: ``3GLCM_CLUPROM`` :Range: :math:`[0, \infty)`, grey levels to the fourth power -Defined as :ref:`GLCM_CLUPROM `, centred on :math:`2\mu_y`. This equals the -IBSI centre :math:`\mu_x + \mu_y` only on a symmetric matrix. +Defined as :ref:`GLCM_CLUPROM `, centred on :math:`\mu_x + \mu_y`. .. _feature-3glcm-clushade: @@ -292,7 +291,7 @@ Cluster shade :Code: ``3GLCM_CLUSHADE`` :Range: :math:`(-\infty, \infty)`, grey levels cubed -Defined as :ref:`GLCM_CLUSHADE `, centred on :math:`2\mu_y`. +Defined as :ref:`GLCM_CLUSHADE `, centred on :math:`\mu_x + \mu_y`. .. _feature-3glcm-clutend: @@ -303,7 +302,7 @@ Cluster tendency :Code: ``3GLCM_CLUTEND`` :Range: :math:`[0, \infty)`, squared grey levels -Defined as :ref:`GLCM_CLUTEND `, centred on :math:`2\mu_y`. +Defined as :ref:`GLCM_CLUTEND `, centred on :math:`\mu_x + \mu_y`. ``3GLCM_SUMVARIANCE`` returns the same value. @@ -415,11 +414,11 @@ Defined as :ref:`GLCM_HOM1 `. Equal to ``3GLCM_ID``. Homogeneity 2 ^^^^^^^^^^^^^ -:Code: ``3GLCM_HOM2`` (no ``_AVE`` column) +:Code: ``3GLCM_HOM2`` :Range: :math:`(0, 1]`, dimensionless -Defined as :ref:`GLCM_HOM2 `. Equal to ``3GLCM_IDM``; for the direction average -use ``3GLCM_IDM_AVE``. +Defined as :ref:`GLCM_HOM2 `. Equal to ``3GLCM_IDM``, and ``3GLCM_HOM2_AVE`` to +``3GLCM_IDM_AVE``. .. _feature-3glcm-id: @@ -474,9 +473,10 @@ Information measure of correlation 1 :Code: ``3GLCM_INFOMEAS1`` :Range: :math:`[-1, 0]`, dimensionless -Defined as :ref:`GLCM_INFOMEAS1 `: it divides by :math:`HY`, the entropy of -the neighbour marginal. When :math:`HY = 0`, as on a constant ROI, the result is the ``--noval`` -substitute, 0 by default (``-0.0`` in Arrow and Parquet files; see :ref:`conventions-missing`). +Defined as :ref:`GLCM_INFOMEAS1 `: it divides by :math:`\max(HX, HY)`. +When :math:`HX = HY = 0`, as on a constant ROI, the result is the ``--noval`` substitute, 0 by +default (``-0.0`` in Arrow and Parquet files; see :ref:`conventions-missing`). A direction where +this happens enters ``3GLCM_INFOMEAS1_AVE`` with the substitute, like a direction without pairs. .. _feature-3glcm-infomeas2: @@ -542,9 +542,9 @@ Joint variance :Code: ``3GLCM_JVAR`` :Range: :math:`[0, \infty)`, squared grey levels -Defined as :ref:`GLCM_JVAR `: the neighbour's level :math:`j` around the -reference mean :math:`\mu_x`. It equals ``3GLCM_VARIANCE`` on a symmetric matrix; with the default -counting the worked example gives 257.66 against 334.03. +Defined as :ref:`GLCM_JVAR `: the reference voxel's level :math:`i` around its +mean :math:`\mu_x`. It returns the same value as ``3GLCM_VARIANCE``, 334.03 on the worked example +with the default settings. .. _feature-3glcm-sumaverage: @@ -577,8 +577,7 @@ Sum variance :Code: ``3GLCM_SUMVARIANCE`` :Range: :math:`[0, \infty)`, squared grey levels -Returns the ``3GLCM_CLUTEND`` value, as :ref:`GLCM_SUMVARIANCE ` does in -2D. +Defined as :ref:`GLCM_SUMVARIANCE `. Equal to ``3GLCM_CLUTEND``. .. _feature-3glcm-variance: @@ -590,7 +589,7 @@ Variance :Range: :math:`[0, \infty)`, squared grey levels Defined as :ref:`GLCM_VARIANCE `; it matches the IBSI joint variance on -every matrix. +every matrix and returns the same value as ``3GLCM_JVAR``. .. _glcm-3d-possible-issues: @@ -612,18 +611,16 @@ Directions without pairs enter the average ``3GLCM_CONTRAST_AVE`` is 0.673, while the mean of the 4 in-plane directions is 2.1875. Asymmetric matrix by default - As in 2D, the default counting takes each ordered pair once, so features centred on - :math:`2\mu_y` (``CLUPROM``, ``CLUSHADE``, ``CLUTEND``, ``SUMVARIANCE``), ``JVAR`` and - ``INFOMEAS1`` differ from IBSI and can change when the volume is mirrored. See - :ref:`glcm-possible-issues` on the 2D page. + As in 2D, the default counting takes each ordered pair once, so the matrix is not symmetric and + the features that read one side of the pair, such as ``JAVE``, ``VARIANCE`` and ``JVAR``, can + change when the volume is mirrored. See :ref:`glcm-possible-issues` on the 2D page. Constant ROI When all voxels share one grey level the matrix is a single diagonal entry and the features take their limiting values (``3GLCM_ASM`` 1, ``3GLCM_CONTRAST`` 0, ``3GLCM_JAVE`` the level). ``3GLCM_CORRELATION`` and ``3GLCM_INFOMEAS1`` divide by zero; the result is the ``--noval`` substitute in CSV files and pandas, and ``-0.0`` in Arrow and Parquet files. This differs from - the 2D family, which returns 0 for every feature in every format, whatever ``--noval`` is, a - known defect (`#511 `__; see :ref:`glcm-possible-issues`). + the 2D family, which returns the substitute for every feature (see :ref:`glcm-possible-issues`). ``get_metaparam("3glcm/...")`` returns the 2D settings ``get_metaparam("3glcm/greydepth")`` and ``get_metaparam("3glcm/offset")`` return the 2D GLCM @@ -634,7 +631,7 @@ Constant ROI Grey-level values and indices As in 2D, with PyRadiomics-style binning some features use positions 1 to :math:`N_g` in the list of grey levels present, and others the levels themselves. ``DIFAVE``, ``SUMAVERAGE``, - ``IV``, ``JVAR`` and ``DIFVAR`` mix the two as on the 2D page, a known defect + ``IV`` and ``DIFVAR`` mix the two as on the 2D page, a known defect (`#510 `__). @@ -645,8 +642,11 @@ The test suite checks every 3D GLCM feature against PyRadiomics 3.0.1 with PyRad binning (20 bins), where both matrices are symmetric. Each plain feature is compared direction by direction, all 13 values against PyRadiomics' own per-direction values, and each ``_AVE`` code against PyRadiomics' direction-averaged value. Entropy features are compared at a looser tolerance -because of the approximate logarithm. Values with the default binning are covered by regression -tests only, and IBSI mode only by the worked-example script on this page. +because of the approximate logarithm. With the default binning, cluster prominence, shade and +tendency, sum variance, joint variance and the first information measure of correlation are checked +in all 13 directions against their IBSI definitions on an independently counted matrix, on a volume +and on its mirror; the other features are covered there by regression tests only. IBSI mode is +covered only by the worked-example script on this page. References diff --git a/docs/source/Math/glcm_3d_index.inc b/docs/source/Math/glcm_3d_index.inc index 9d5b3a21..924505aa 100644 --- a/docs/source/Math/glcm_3d_index.inc +++ b/docs/source/Math/glcm_3d_index.inc @@ -23,17 +23,17 @@ * - :ref:`3GLCM_CLUPROM ` - Cluster prominence - AE86 - - PyRadiomics (rel. 1e-9) + - analytic (rel. 1e-9), PyRadiomics (rel. 1e-9) - 15.47 * - :ref:`3GLCM_CLUSHADE ` - Cluster shade - 7NFM - - PyRadiomics (rel. 1e-9) + - analytic (rel. 1e-9), PyRadiomics (rel. 1e-9) - −0.08299 * - :ref:`3GLCM_CLUTEND ` - Cluster tendency - DG8W - - PyRadiomics (rel. 1e-9) + - analytic (rel. 1e-9), PyRadiomics (rel. 1e-9) - 2.83 * - :ref:`3GLCM_CONTRAST ` - Contrast @@ -108,7 +108,7 @@ * - :ref:`3GLCM_INFOMEAS1 ` - Information measure of correlation 1 - R8DG - - PyRadiomics (rel. 4e-2) + - analytic (rel. 2e-2), PyRadiomics (rel. 4e-2) - −0.0914 * - :ref:`3GLCM_INFOMEAS2 ` - Information measure of correlation 2 @@ -138,7 +138,7 @@ * - :ref:`3GLCM_JVAR ` - Joint variance - UR99 - - PyRadiomics (rel. 1e-9) + - analytic (rel. 1e-9), PyRadiomics (rel. 1e-9) - 1.194 * - :ref:`3GLCM_SUMAVERAGE ` - Sum average @@ -153,10 +153,10 @@ * - :ref:`3GLCM_SUMVARIANCE ` - Sum variance - OEEB - - PyRadiomics (rel. 1e-9) + - analytic (rel. 1e-9), PyRadiomics (rel. 1e-9) - 2.83 * - :ref:`3GLCM_VARIANCE ` - Variance - — - - PyRadiomics (rel. 1e-9) + - analytic (rel. 1e-9), PyRadiomics (rel. 1e-9) - 1.194 diff --git a/docs/source/Math/glcm_index.inc b/docs/source/Math/glcm_index.inc index 5a520fe9..b3133fd9 100644 --- a/docs/source/Math/glcm_index.inc +++ b/docs/source/Math/glcm_index.inc @@ -23,17 +23,17 @@ * - :ref:`GLCM_CLUPROM ` - Cluster prominence - AE86 - - PyRadiomics (rel. 1e-9) + - analytic (rel. 1e-9), PyRadiomics (rel. 1e-9) - 58.1 * - :ref:`GLCM_CLUSHADE ` - Cluster shade - 7NFM - - MIRP (rel. 1e-9) + - analytic (rel. 1e-9), MIRP (rel. 1e-9) - 4.8 * - :ref:`GLCM_CLUTEND ` - Cluster tendency - DG8W - - PyRadiomics (rel. 1e-9) + - analytic (rel. 1e-9), PyRadiomics (rel. 1e-9) - 5.3 * - :ref:`GLCM_CONTRAST ` - Contrast @@ -108,7 +108,7 @@ * - :ref:`GLCM_INFOMEAS1 ` - Information measure of correlation 1 - R8DG - - MIRP (rel. 5e-3) + - analytic (rel. 1.5e-2), MIRP (rel. 5e-3) - −0.2276 * - :ref:`GLCM_INFOMEAS2 ` - Information measure of correlation 2 @@ -138,7 +138,7 @@ * - :ref:`GLCM_JVAR ` - Joint variance - UR99 - - MIRP (rel. 1e-9) + - analytic (rel. 1e-9), MIRP (rel. 1e-9) - 2.05 * - :ref:`GLCM_SUMAVERAGE ` - Sum average @@ -153,10 +153,10 @@ * - :ref:`GLCM_SUMVARIANCE ` - Sum variance - OEEB - - PyRadiomics (rel. 1e-9) + - analytic (rel. 1e-9), PyRadiomics (rel. 1e-9) - 5.3 * - :ref:`GLCM_VARIANCE ` - Variance - — - - IBSI (rel. 1e-9) + - analytic (rel. 1e-9), IBSI (rel. 1e-9) - 2.05 diff --git a/docs/source/conventions.rst b/docs/source/conventions.rst index 0bec0e65..b35db329 100644 --- a/docs/source/conventions.rst +++ b/docs/source/conventions.rst @@ -257,7 +257,7 @@ they differ in these ways: - Every family takes the mask from the ROI's voxels and leaves the voxels outside it out, in every mode. See `Background`_. * - Constant ROI - - Every GLCM feature returns 0, whatever ``--noval`` is, a known defect (`#511 `__). + - Every GLCM feature returns the substitute. - Most 3D GLCM features return their limiting values when the ROI fills its bounding box. See `Constant ROIs and missing values`_. * - Neighbourhood size @@ -489,7 +489,7 @@ A ROI whose pixels all have one intensity is the most common case: - Every ``IH_*`` feature returns the substitute - No 3D family * - GLCM (:doc:`2D `, :doc:`3D `) - - Every feature returns 0, whatever ``--noval`` is, a known defect (`#511 `__) + - Every feature returns the substitute, the ``_AVE`` columns included - Limiting values (``3GLCM_ASM`` 1, ``3GLCM_CONTRAST`` 0); ``3GLCM_CORRELATION`` and ``3GLCM_INFOMEAS1`` return the substitute (``-0.0`` in Arrow and Parquet) * - GLRLM, GLSZM, GLDM, GLDZM diff --git a/docs/source/devguide.rst b/docs/source/devguide.rst index 6e42e8ae..cadac00e 100644 --- a/docs/source/devguide.rst +++ b/docs/source/devguide.rst @@ -1260,7 +1260,7 @@ without ``--check`` to rewrite its pages; with ``--check`` it fails if a page is ``gen_feature_reference.py`` fails, and writes nothing, when a code has no description, a description names no code, a code belongs to no family, a family page lacks a code's entry, ``feature_extras.toml`` lists a code that is not a base code of that family, or a file in -``COUNT_PAGES`` does not state the current feature counts ("758 features in all, 539 for 2D +``COUNT_PAGES`` does not state the current feature counts ("760 features in all, 540 for 2D images, ..."). Documenting a new feature diff --git a/docs/source/featuregroups.rst b/docs/source/featuregroups.rst index e7a510b2..13e9ed21 100644 --- a/docs/source/featuregroups.rst +++ b/docs/source/featuregroups.rst @@ -33,10 +33,10 @@ even ``*ALL_INTENSITY*``. - Features - Families * - ``*ALL*`` - - 539 + - 540 - :ref:`Intensity `, :ref:`Basic morphology `, :ref:`Ellipse fitting `, :ref:`Contour `, :ref:`Convex hull `, :ref:`Erosion `, :ref:`Fractal dimension `, :ref:`Feret diameters `, :ref:`Martin diameters `, :ref:`Nassenstein diameters `, :ref:`Chords `, :ref:`Euler number `, :ref:`Extrema `, :ref:`Inscribing and circumscribing circles `, :ref:`Geodetic length and thickness `, :ref:`ROI radius `, :ref:`Neighbors `, :ref:`Grey-level co-occurrence matrix (GLCM) `, :ref:`Grey-level run-length matrix (GLRLM) `, :ref:`Grey-level distance-zone matrix (GLDZM) `, :ref:`Grey-level size-zone matrix (GLSZM) `, :ref:`Grey-level dependence matrix (GLDM) `, :ref:`Neighbouring grey-level dependence matrix (NGLDM) `, :ref:`Neighbourhood grey-tone difference matrix (NGTDM) `, :ref:`Radial distribution `, :ref:`Gabor `, :ref:`Zernike `, :ref:`Shape moments `, :ref:`Intensity moments `, :ref:`IBSI intensity histogram ` * - ``*WHOLESLIDE*`` - - 283 + - 284 - :ref:`Intensity `, :ref:`Contour `, :ref:`Grey-level co-occurrence matrix (GLCM) `, :ref:`Grey-level run-length matrix (GLRLM) `, :ref:`Grey-level size-zone matrix (GLSZM) `, :ref:`Grey-level dependence matrix (GLDM) `, :ref:`Neighbouring grey-level dependence matrix (NGLDM) `, :ref:`Neighbourhood grey-tone difference matrix (NGTDM) `, :ref:`Radial distribution `, :ref:`Gabor `, :ref:`Zernike `, :ref:`Intensity moments ` * - ``*ALL_INTENSITY*`` - 36 @@ -48,7 +48,7 @@ even ``*ALL_INTENSITY*``. - 15 - :ref:`Basic morphology ` * - ``*ALL_GLCM*`` - - 59 + - 60 - :ref:`Grey-level co-occurrence matrix (GLCM) ` * - ``*ALL_GLRLM*`` - 32 @@ -95,7 +95,7 @@ even ``*ALL_INTENSITY*``. - Features - Families * - ``*3D_ALL*`` - - 213 + - 214 - :ref:`Intensity (3D) `, :ref:`Shape (3D) `, :ref:`GLCM (3D) `, :ref:`GLDM (3D) `, :ref:`GLDZM (3D) `, :ref:`NGLDM (3D) `, :ref:`NGTDM (3D) `, :ref:`GLSZM (3D) `, :ref:`GLRLM (3D) ` * - ``*3D_ALL_INTENSITY*`` - 36 @@ -104,10 +104,10 @@ even ``*ALL_INTENSITY*``. - 14 - :ref:`Shape (3D) ` * - ``*3D_ALL_TEXTURE*`` - - 163 + - 164 - :ref:`GLCM (3D) `, :ref:`GLDM (3D) `, :ref:`GLDZM (3D) `, :ref:`NGLDM (3D) `, :ref:`NGTDM (3D) `, :ref:`GLSZM (3D) `, :ref:`GLRLM (3D) ` * - ``*3D_GLCM*`` - - 59 + - 60 - :ref:`GLCM (3D) ` * - ``*3D_GLDM*`` - 14 diff --git a/docs/source/featurelist.rst b/docs/source/featurelist.rst index b6ee652d..dcfa5e39 100644 --- a/docs/source/featurelist.rst +++ b/docs/source/featurelist.rst @@ -4,7 +4,7 @@ Feature list ============ -Nyxus computes 539 features for 2D images, 213 for 3D volumes and 6 image quality features. Request a feature by its code, or a family of features by its group (see :doc:`featuregroups`). +Nyxus computes 540 features for 2D images, 214 for 3D volumes and 6 image quality features. Request a feature by its code, or a family of features by its group (see :doc:`featuregroups`). The *Validation* column says how each feature is tested: @@ -892,14 +892,14 @@ Definitions, formulas and settings: :doc:`/Math/f_glcm`. - Autocorrelation: the co-occurrence-weighted mean of the product of the two grey levels of a pixel pair, which grows with both coarseness and brightness. - vetted: MIRP * - ``GLCM_CLUPROM`` - - Cluster prominence: the fourth moment of the sum of the two grey levels of a pair about twice the neighbour pixel's mean grey level, which is large when that distribution is asymmetric or heavy-tailed. - - vetted: PyRadiomics + - Cluster prominence: the fourth moment of the sum of the two grey levels of a pair about its mean, the sum of the two pixels' mean grey levels, which is large when that distribution is asymmetric or heavy-tailed. + - vetted: analytic, PyRadiomics * - ``GLCM_CLUSHADE`` - - Cluster shade: the third moment of the sum of the two grey levels of a pair about twice the neighbour pixel's mean grey level, which measures the skewness of the co-occurrence matrix. - - vetted: MIRP + - Cluster shade: the third moment of the sum of the two grey levels of a pair about its mean, the sum of the two pixels' mean grey levels, which measures the skewness of the co-occurrence matrix. + - vetted: analytic, MIRP * - ``GLCM_CLUTEND`` - - Cluster tendency: the second moment of the sum of the two grey levels of a pair about twice the neighbour pixel's mean grey level, which measures how strongly pairs group into similar grey levels. - - vetted: PyRadiomics + - Cluster tendency: the second moment of the sum of the two grey levels of a pair about its mean, the sum of the two pixels' mean grey levels, which measures how strongly pairs group into similar grey levels; it returns the same value as GLCM_SUMVARIANCE. + - vetted: analytic, PyRadiomics * - ``GLCM_CONTRAST`` - Contrast: the co-occurrence-weighted mean squared grey-level difference between the two pixels of a pair, which grows with local intensity variation. - vetted: PyRadiomics @@ -928,7 +928,7 @@ Definitions, formulas and settings: :doc:`/Math/f_glcm`. - Homogeneity 1: the co-occurrence probabilities weighted by one over one plus the grey-level difference of the pair; it returns the same value as GLCM_ID. - vetted: PyRadiomics * - ``GLCM_HOM2`` - - Homogeneity 2: the co-occurrence probabilities weighted by one over one plus the squared grey-level difference of the pair; it returns the same value as GLCM_IDM and has no _AVE code. + - Homogeneity 2: the co-occurrence probabilities weighted by one over one plus the squared grey-level difference of the pair; it returns the same value as GLCM_IDM. - vetted: MIRP * - ``GLCM_ID`` - Inverse difference: the co-occurrence probabilities weighted by one over one plus the grey-level difference of the pair, which is high when paired pixels have similar grey levels. @@ -943,8 +943,8 @@ Definitions, formulas and settings: :doc:`/Math/f_glcm`. - Inverse difference moment normalized: inverse difference moment with the squared grey-level difference divided by the squared number of grey levels. - vetted: PyRadiomics * - ``GLCM_INFOMEAS1`` - - Informational measure of correlation 1: the joint entropy minus the entropy expected if the two grey levels were independent, divided by the entropy of one marginal distribution; it measures how much the two grey levels depend on each other. - - vetted: MIRP + - Informational measure of correlation 1: the joint entropy minus the entropy expected if the two grey levels were independent, divided by the larger of the two marginal entropies; it measures how much the two grey levels depend on each other. + - vetted: analytic, MIRP * - ``GLCM_INFOMEAS2`` - Informational measure of correlation 2: a 0-to-1 measure of the dependence between the two grey levels of a pair, computed from the gap between the joint entropy and the entropy of the product of the marginals. - vetted: PyRadiomics @@ -961,8 +961,8 @@ Definitions, formulas and settings: :doc:`/Math/f_glcm`. - Joint maximum: the largest co-occurrence probability, that is the share of pairs taken by the most common grey-level pair. - vetted: PyRadiomics * - ``GLCM_JVAR`` - - Joint variance: the co-occurrence-weighted spread of the neighbour pixel's grey level around the joint average (the reference pixel's mean); it equals GLCM_VARIANCE only when the matrix is symmetric. - - vetted: MIRP + - Joint variance: the co-occurrence-weighted variance of the reference pixel's grey level about the joint average; it returns the same value as GLCM_VARIANCE. + - vetted: analytic, MIRP * - ``GLCM_SUMAVERAGE`` - Sum average: the mean of the sum of the two grey levels of a pixel pair. - vetted: MIRP @@ -970,11 +970,11 @@ Definitions, formulas and settings: :doc:`/Math/f_glcm`. - Sum entropy: the base-2 entropy of the distribution of the sum of the two grey levels of a pixel pair. - vetted: PyRadiomics * - ``GLCM_SUMVARIANCE`` - - Sum variance: the spread of the sum of the two grey levels of a pair about twice the neighbour pixel's mean grey level; this code returns the cluster tendency value, the same as GLCM_CLUTEND. - - vetted: PyRadiomics + - Sum variance: the variance of the sum of the two grey levels of a pair; it returns the same value as GLCM_CLUTEND. + - vetted: analytic, PyRadiomics * - ``GLCM_VARIANCE`` - Variance: the co-occurrence-weighted variance of the reference pixel's grey level about its mean (PyRadiomics sum of squares). - - vetted: IBSI + - vetted: analytic, IBSI * - ``GLCM_ASM_AVE`` - Angular second moment, averaged over the angles. - vetted: PyRadiomics @@ -1017,6 +1017,9 @@ Definitions, formulas and settings: :doc:`/Math/f_glcm`. * - ``GLCM_HOM1_AVE`` - Homogeneity 1, averaged over the angles. - vetted: PyRadiomics + * - ``GLCM_HOM2_AVE`` + - Homogeneity 2, averaged over the angles. + - vetted: IBSI * - ``GLCM_ID_AVE`` - Inverse difference, averaged over the angles. - vetted: IBSI @@ -2321,14 +2324,14 @@ Definitions, formulas and settings: :doc:`/Math/f_glcm_3d`. - Angular second moment: the sum of the squared co-occurrence probabilities, which is high when a few grey-level pairs dominate (a uniform texture). - vetted: PyRadiomics * - ``3GLCM_CLUPROM`` - - Cluster prominence: the fourth moment of the sum of the two grey levels of a pair about twice the mean grey level, which is large when that distribution is asymmetric or heavy-tailed. - - vetted: PyRadiomics + - Cluster prominence: the fourth moment of the sum of the two grey levels of a pair about its mean, the sum of the two voxels' mean grey levels, which is large when that distribution is asymmetric or heavy-tailed. + - vetted: analytic, PyRadiomics * - ``3GLCM_CLUSHADE`` - - Cluster shade: the third moment of the sum of the two grey levels of a pair about twice the mean grey level, which measures the skewness of the co-occurrence matrix. - - vetted: PyRadiomics + - Cluster shade: the third moment of the sum of the two grey levels of a pair about its mean, the sum of the two voxels' mean grey levels, which measures the skewness of the co-occurrence matrix. + - vetted: analytic, PyRadiomics * - ``3GLCM_CLUTEND`` - - Cluster tendency: the second moment of the sum of the two grey levels of a pair about twice the mean grey level, which measures how strongly pairs group into similar grey levels. - - vetted: PyRadiomics + - Cluster tendency: the second moment of the sum of the two grey levels of a pair about its mean, the sum of the two voxels' mean grey levels, which measures how strongly pairs group into similar grey levels; it returns the same value as 3GLCM_SUMVARIANCE. + - vetted: analytic, PyRadiomics * - ``3GLCM_CONTRAST`` - Contrast: the co-occurrence-weighted mean squared grey-level difference between the two voxels of a pair, which grows with local intensity variation. - vetted: PyRadiomics @@ -2357,7 +2360,7 @@ Definitions, formulas and settings: :doc:`/Math/f_glcm_3d`. - Homogeneity 1: the co-occurrence probabilities weighted by one over one plus the grey-level difference of the pair; it returns the same value as 3GLCM_ID. - vetted: PyRadiomics * - ``3GLCM_HOM2`` - - Homogeneity 2: the co-occurrence probabilities weighted by one over one plus the squared grey-level difference of the pair; it returns the same value as 3GLCM_IDM and has no _AVE code. + - Homogeneity 2: the co-occurrence probabilities weighted by one over one plus the squared grey-level difference of the pair; it returns the same value as 3GLCM_IDM. - vetted: PyRadiomics * - ``3GLCM_ID`` - Inverse difference: the co-occurrence probabilities weighted by one over one plus the grey-level difference of the pair, which is high when paired voxels have similar grey levels. @@ -2372,8 +2375,8 @@ Definitions, formulas and settings: :doc:`/Math/f_glcm_3d`. - Inverse difference moment normalized: inverse difference moment with the squared grey-level difference divided by the squared number of grey levels. - vetted: PyRadiomics * - ``3GLCM_INFOMEAS1`` - - Informational measure of correlation 1: the joint entropy minus the entropy expected if the two grey levels were independent, divided by the entropy of one marginal distribution; it measures how much the two grey levels depend on each other. - - vetted: PyRadiomics + - Informational measure of correlation 1: the joint entropy minus the entropy expected if the two grey levels were independent, divided by the larger of the two marginal entropies; it measures how much the two grey levels depend on each other. + - vetted: analytic, PyRadiomics * - ``3GLCM_INFOMEAS2`` - Informational measure of correlation 2: a 0-to-1 measure of the dependence between the two grey levels of a pair, computed from the gap between the joint entropy and the entropy of the product of the marginals. - vetted: PyRadiomics @@ -2390,8 +2393,8 @@ Definitions, formulas and settings: :doc:`/Math/f_glcm_3d`. - Joint maximum: the largest co-occurrence probability, that is the share of pairs taken by the most common grey-level pair. - vetted: PyRadiomics * - ``3GLCM_JVAR`` - - Joint variance: the co-occurrence-weighted spread of the neighbour voxel's grey level around the joint average (the reference voxel's mean). - - vetted: PyRadiomics + - Joint variance: the co-occurrence-weighted variance of the reference voxel's grey level about the joint average; it returns the same value as 3GLCM_VARIANCE. + - vetted: analytic, PyRadiomics * - ``3GLCM_SUMAVERAGE`` - Sum average: the mean of the sum of the two grey levels of a voxel pair. - vetted: PyRadiomics @@ -2399,11 +2402,11 @@ Definitions, formulas and settings: :doc:`/Math/f_glcm_3d`. - Sum entropy: the base-2 entropy of the distribution of the sum of the two grey levels of a voxel pair. - vetted: PyRadiomics * - ``3GLCM_SUMVARIANCE`` - - Sum variance: the spread of the sum of the two grey levels of a pair about twice the mean grey level; this code returns the cluster tendency value, the same as 3GLCM_CLUTEND. - - vetted: PyRadiomics + - Sum variance: the variance of the sum of the two grey levels of a pair; it returns the same value as 3GLCM_CLUTEND. + - vetted: analytic, PyRadiomics * - ``3GLCM_VARIANCE`` - Variance: the co-occurrence-weighted variance of the reference voxel's grey level about its mean (PyRadiomics sum of squares). - - vetted: PyRadiomics + - vetted: analytic, PyRadiomics * - ``3GLCM_ASM_AVE`` - Angular second moment, averaged over the directions. - vetted: analytic, PyRadiomics @@ -2446,6 +2449,9 @@ Definitions, formulas and settings: :doc:`/Math/f_glcm_3d`. * - ``3GLCM_HOM1_AVE`` - Homogeneity 1, averaged over the directions. - vetted: PyRadiomics + * - ``3GLCM_HOM2_AVE`` + - Homogeneity 2, averaged over the directions. + - vetted: PyRadiomics * - ``3GLCM_ID_AVE`` - Inverse difference, averaged over the directions. - vetted: PyRadiomics diff --git a/docs/source/ibsi_mode.rst b/docs/source/ibsi_mode.rst index eb73ddaa..d15456e6 100644 --- a/docs/source/ibsi_mode.rst +++ b/docs/source/ibsi_mode.rst @@ -62,9 +62,9 @@ are. The 2D families affected are: - No conversion. One binning step remains in IBSI mode: before building the 2D GLCM, Nyxus bins the ROI's minimum -and maximum to ``--coarseGrayDepth`` levels and when they fall into one level every GLCM feature returns 0, whatever -``--noval`` is (a known defect, `#511 `__), so a ROI whose minimum is at least 63/64 of its maximum gets 0 -in every GLCM column (see :ref:`glcm-possible-issues`). +and maximum to ``--coarseGrayDepth`` levels and when they fall into one level every GLCM feature +returns the ``--noval`` substitute, so a ROI whose minimum is at least 63/64 of its maximum gets the +substitute in every GLCM column (see :ref:`glcm-possible-issues`). The 3D twins of these families skip binning in the same way; by default they bin into 64 levels like the 2D families (see :ref:`conventions-grey-levels`). diff --git a/docs/source/index.rst b/docs/source/index.rst index 94e8d52f..42db92eb 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -2,7 +2,7 @@ Nyxus ===== Nyxus computes intensity, texture, morphology and image quality features for every region of -interest (ROI) in 2D images and 3D volumes: 758 features in all, 539 for 2D images, 213 for 3D +interest (ROI) in 2D images and 3D volumes: 760 features in all, 540 for 2D images, 214 for 3D volumes and 6 image quality features. It runs from the command line or from Python, reads TIFF, OME-TIFF, OME-Zarr, NIfTI and DICOM files (OME-TIFF and OME-Zarr with up to five dimensions), and assembles ROIs that span several image tiles. diff --git a/docs/source/large_images.rst b/docs/source/large_images.rst index 55e1d7e0..39fc520f 100644 --- a/docs/source/large_images.rst +++ b/docs/source/large_images.rst @@ -177,7 +177,7 @@ Which features differ out of core In 3D, every family gives the same values out of core as in memory, the 3D axis features up to the last digits (see :doc:`Math/f_morphology_3d`). A test volume with two ROIs, computed with -``ram_limit=0``, matched the in-memory run in the 213 ``*3D_ALL*`` features, and so did a whole +``ram_limit=0``, matched the in-memory run in every ``*3D_ALL*`` feature, and so did a whole volume. This holds for inputs Nyxus can stream; see the end of :ref:`large-images-tiles` for those it refuses. diff --git a/src/nyx/features/3d_glcm.cpp b/src/nyx/features/3d_glcm.cpp index 25a6bfd7..e68063d9 100644 --- a/src/nyx/features/3d_glcm.cpp +++ b/src/nyx/features/3d_glcm.cpp @@ -153,6 +153,7 @@ void D3_GLCM_feature::save_value(std::vector>& fvals) fvals[(int)Feature3D::GLCM_ENERGY_AVE][0] = calc_ave(fvals_energy); fvals[(int)Feature3D::GLCM_ENTROPY_AVE][0] = calc_ave(fvals_entropy); fvals[(int)Feature3D::GLCM_HOM1_AVE][0] = calc_ave(fvals_homo); + fvals[(int)Feature3D::GLCM_HOM2_AVE][0] = calc_ave(fvals_hom2); fvals[(int)Feature3D::GLCM_ID_AVE][0] = calc_ave(fvals_id); fvals[(int)Feature3D::GLCM_IDN_AVE][0] = calc_ave(fvals_idn); fvals[(int)Feature3D::GLCM_IDM_AVE][0] = calc_ave(fvals_IDM); @@ -185,45 +186,15 @@ void D3_GLCM_feature::finalize_angle (double soft_nan) // Blank cooc-matrix? -- no point to use it, assign each feature value '0' and return. if (sum_p == 0) { - auto _ = soft_nan; - fvals_ASM.push_back(_); - fvals_acor.push_back(_); - fvals_cluprom.push_back(_); - fvals_clushade.push_back(_); - fvals_clutend.push_back(_); - fvals_contrast.push_back(_); - fvals_correlation.push_back(_); - fvals_diff_avg.push_back(_); - fvals_diff_var.push_back(_); - fvals_diff_entropy.push_back(_); - fvals_dis.push_back(_); - fvals_energy.push_back(_); - fvals_entropy.push_back(_); - fvals_homo.push_back(_); - fvals_hom2.push_back(_); - fvals_id.push_back(_); - fvals_idn.push_back(_); - fvals_IDM.push_back(_); - fvals_idmn.push_back(_); - fvals_meas_corr1.push_back(_); - fvals_meas_corr2.push_back(_); - fvals_iv.push_back(_); - fvals_jave.push_back(_); - fvals_je.push_back(_); - fvals_jmax.push_back(_); - fvals_jvar.push_back(_); - fvals_sum_avg.push_back(_); - fvals_sum_var.push_back(_); - fvals_sum_entropy.push_back(_); - fvals_variance.push_back(_); + push_noval (soft_nan); return; } // Output - 'Pxpy' (meaning: 'x plus y') and 'Pxmy' (meaning: 'x minus y') calculatePxpmy(); - // Calculate by-row mean - calculate_by_row_mean(); + // Output - 'mean_x' and 'mean_y' + calculate_marginal_means(); // Compute Haralick statistics fvals_ASM.push_back(f_asm(P_matrix)); @@ -231,7 +202,10 @@ void D3_GLCM_feature::finalize_angle (double soft_nan) fvals_correlation.push_back(f_corr()); fvals_energy.push_back(f_energy(P_matrix)); fvals_homo.push_back(f_homogeneity()); - fvals_variance.push_back(f_var(P_matrix)); + // 3GLCM_VARIANCE and 3GLCM_JVAR are both IBSI joint variance, sum_ij (i - mu_x)^2 p(i,j), so it is + // calculated once + double jvar = f_var(P_matrix); + fvals_variance.push_back(jvar); fvals_IDM.push_back(f_idm()); fvals_sum_avg.push_back(f_savg()); fvals_sum_entropy.push_back(f_sentropy()); @@ -239,12 +213,15 @@ void D3_GLCM_feature::finalize_angle (double soft_nan) fvals_diff_var.push_back(f_dvar(P_matrix)); fvals_diff_entropy.push_back(f_dentropy(P_matrix)); fvals_diff_avg.push_back(f_difference_avg()); - fvals_meas_corr1.push_back(f_info_meas_corr1(P_matrix)); + fvals_meas_corr1.push_back(f_info_meas_corr1(P_matrix, soft_nan)); fvals_meas_corr2.push_back(f_info_meas_corr2(P_matrix)); fvals_acor.push_back(f_GLCM_ACOR(P_matrix)); fvals_cluprom.push_back(f_GLCM_CLUPROM()); fvals_clushade.push_back(f_GLCM_CLUSHADE()); - double clutend = f_GLCM_CLUTEND(); // 'cluster tendency' is equivalent to 'sum variance', so calculate it once + // Cluster tendency, sum_ij (i + j - mu_x - mu_y)^2 p(i,j), and IBSI sum variance, + // sum_k (k - SA)^2 p_{x+y}(k), are the same sum on every matrix because the IBSI sum average + // SA = sum_k k p_{x+y}(k) is mu_x + mu_y, so it is calculated once + double clutend = f_GLCM_CLUTEND(); fvals_clutend.push_back(clutend); fvals_sum_var.push_back(clutend); fvals_dis.push_back(f_GLCM_DIS(P_matrix)); @@ -257,7 +234,41 @@ void D3_GLCM_feature::finalize_angle (double soft_nan) fvals_jave.push_back(jave); fvals_je.push_back(f_GLCM_JE(P_matrix)); fvals_jmax.push_back(f_GLCM_JMAX(P_matrix)); - fvals_jvar.push_back(f_GLCM_JVAR(P_matrix, jave)); + fvals_jvar.push_back(jvar); +} + +void D3_GLCM_feature::push_noval (double softnan) +{ + fvals_ASM.push_back (softnan); + fvals_acor.push_back (softnan); + fvals_cluprom.push_back (softnan); + fvals_clushade.push_back (softnan); + fvals_clutend.push_back (softnan); + fvals_contrast.push_back (softnan); + fvals_correlation.push_back (softnan); + fvals_diff_avg.push_back (softnan); + fvals_diff_var.push_back (softnan); + fvals_diff_entropy.push_back (softnan); + fvals_dis.push_back (softnan); + fvals_energy.push_back (softnan); + fvals_entropy.push_back (softnan); + fvals_homo.push_back (softnan); + fvals_hom2.push_back (softnan); + fvals_id.push_back (softnan); + fvals_idn.push_back (softnan); + fvals_IDM.push_back (softnan); + fvals_idmn.push_back (softnan); + fvals_meas_corr1.push_back (softnan); + fvals_meas_corr2.push_back (softnan); + fvals_iv.push_back (softnan); + fvals_jave.push_back (softnan); + fvals_je.push_back (softnan); + fvals_jmax.push_back (softnan); + fvals_jvar.push_back (softnan); + fvals_sum_avg.push_back (softnan); + fvals_sum_var.push_back (softnan); + fvals_sum_entropy.push_back (softnan); + fvals_variance.push_back (softnan); } // prerequisite: needs previously grey-binned ROI. No grey binning is done in this method @@ -402,27 +413,21 @@ void D3_GLCM_feature::calculatePxpmy() } } -void D3_GLCM_feature::calculate_by_row_mean() +void D3_GLCM_feature::calculate_marginal_means() { int n_levels = I.size(); - // px[i] is the (i-1)th entry in the marginal probability matrix obtained - // by summing the rows of p[i][j] - std::vector px(n_levels); - for (int j = 0; j < n_levels; j++) - for (int i = 0; i < n_levels; i++) - px[i] += P_matrix.xy(i, j) / sum_p; - - // Now calculate the means and standard deviations of px and py */ - // - fix supplied by J. Michael Christensen, 21 Jun 1991 */ - // - further modified by James Darrell McCauley, 16 Aug 1991 - // after realizing that meanx=meany and stddevx=stddevy - by_row_mean = 0; - for (int i = 0; i < n_levels; ++i) - { - double ival = I[i]; - by_row_mean += px[i] * ival; - } + // P_matrix.yx(r, c) counts the pairs whose reference voxel has level I[r] and whose neighbour + // has level I[c], so the reference marginal sums a row and the neighbour marginal a column. + // The two means differ unless the matrix is symmetric. + mean_x = mean_y = 0; + for (int r = 0; r < n_levels; r++) + for (int c = 0; c < n_levels; c++) + { + double p = P_matrix.yx(r, c) / sum_p; + mean_x += p * I[r]; + mean_y += p * I[c]; + } } /* Angular Second Moment @@ -725,12 +730,13 @@ void D3_GLCM_feature::calcH(const SimpleMatrix& P, std::vector& } } -double D3_GLCM_feature::f_info_meas_corr1(const SimpleMatrix& P) +double D3_GLCM_feature::f_info_meas_corr1(const SimpleMatrix& P, double softnan) { + // IMC1 = (HXY - HXY1) / max(HX, HY), HX and HY the entropies of the two marginals auto Ng = P.width(); - double HX = 0, HXY = 0, HXY1 = 0; + double HX = 0, HY = 0, HXY = 0, HXY1 = 0; std::vector px, py; px.resize(Ng); @@ -754,10 +760,15 @@ double D3_GLCM_feature::f_info_meas_corr1(const SimpleMatrix& P) for (int i = 0; i < Ng; ++i) { HX += px[i] * fast_log10(px[i] + EPSILON) / LOG10_2; - + HY += py[i] * fast_log10(py[i] + EPSILON) / LOG10_2; } - return (HXY - HXY1) / HX; + // The sums above are the negated entropies, so the larger entropy is the smaller sum. + // Undefined when both marginals are a single level (0/0 -> NaN), as on a constant ROI. + double r = (HXY - HXY1) / std::min (HX, HY); + if (!std::isfinite(r)) + return softnan; + return r; } double D3_GLCM_feature::f_info_meas_corr2(const SimpleMatrix& P) @@ -842,9 +853,7 @@ double D3_GLCM_feature::f_GLCM_ACOR(const SimpleMatrix& P) return f; } -// -// Argument 'mean_x' is calculated by f_corr() -// +// The cluster features centre i + j on mu_x + mu_y (calculate_marginal_means()) double D3_GLCM_feature::f_GLCM_CLUPROM() { int n_levels = I.size(); @@ -859,7 +868,7 @@ double D3_GLCM_feature::f_GLCM_CLUPROM() for (int c = 0; c < n_levels; c++) { double cval = I[c]; - double m = rval + cval - by_row_mean - by_row_mean; + double m = rval + cval - mean_x - mean_y; f += m * m * m * m * P_matrix.yx(r, c) / sum_p; } } @@ -881,7 +890,7 @@ double D3_GLCM_feature::f_GLCM_CLUSHADE() for (int c = 0; c < n_levels; c++) { double cval = I[c]; - double m = rval + cval - by_row_mean - by_row_mean; + double m = rval + cval - mean_x - mean_y; f += m * m * m * P_matrix.yx(r, c) / sum_p; } } @@ -902,7 +911,7 @@ double D3_GLCM_feature::f_GLCM_CLUTEND() for (int y = 0; y < n_levels; y++) { double yval = I[y]; - double m = xval + yval - by_row_mean - by_row_mean; + double m = xval + yval - mean_x - mean_y; f += m * m * P_matrix.xy(x,y) / sum_p; } } @@ -1053,26 +1062,6 @@ double D3_GLCM_feature::f_GLCM_JMAX(const SimpleMatrix& P_matrix) return max_p; } -double D3_GLCM_feature::f_GLCM_JVAR(const SimpleMatrix& P_matrix, double joint_ave) -{ - int n_levels = I.size(); - - // joint variance = \sum^{N_g}_{i=1} \sum^{N_g}_{j=1} (i-\mu_x) ^2 p(i,j) - // where \mu_x is the value of joint average feature (IBSI: "Fcm.joint.avg"), - // \mu_x = \sum^{N_g}_{i=1} \sum^{N_g}_{j=1} i p(i,j) - - double f = 0; - for (int x = 0; x < n_levels; x++) - { - double d = double(x+1) - joint_ave, - d2 = d * d; - - for (int y = 0; y < n_levels; y++) - f += d2 * P_matrix.xy(x, y) / sum_p; - } - return f; -} - void D3_GLCM_feature::reduce (size_t start, size_t end, std::vector* ptrLabels, std::unordered_map * ptrLabelData, const Fsettings & s, const Dataset & _) { for (auto i = start; i < end; i++) diff --git a/src/nyx/features/3d_glcm.h b/src/nyx/features/3d_glcm.h index 22243b06..a21b9af5 100644 --- a/src/nyx/features/3d_glcm.h +++ b/src/nyx/features/3d_glcm.h @@ -60,6 +60,7 @@ class D3_GLCM_feature : public FeatureMethod, public TextureFeature Nyxus::Feature3D::GLCM_ENERGY_AVE, Nyxus::Feature3D::GLCM_ENTROPY_AVE, Nyxus::Feature3D::GLCM_HOM1_AVE, + Nyxus::Feature3D::GLCM_HOM2_AVE, Nyxus::Feature3D::GLCM_ID_AVE, Nyxus::Feature3D::GLCM_IDN_AVE, Nyxus::Feature3D::GLCM_IDM_AVE, @@ -94,6 +95,7 @@ class D3_GLCM_feature : public FeatureMethod, public TextureFeature Nyxus::Feature3D::GLCM_ENERGY_AVE, Nyxus::Feature3D::GLCM_ENTROPY_AVE, Nyxus::Feature3D::GLCM_HOM1_AVE, + Nyxus::Feature3D::GLCM_HOM2_AVE, Nyxus::Feature3D::GLCM_ID_AVE, Nyxus::Feature3D::GLCM_IDN_AVE, Nyxus::Feature3D::GLCM_IDM_AVE, @@ -162,7 +164,8 @@ class D3_GLCM_feature : public FeatureMethod, public TextureFeature bool ibsi); void calculatePxpmy(); - void calculate_by_row_mean(); + void calculate_marginal_means(); + void push_noval (double softnan); static inline int cast_to_range(PixIntens orig_I, PixIntens min_orig_I, PixIntens max_orig_I, int min_target_I, int max_target_I) { @@ -194,7 +197,6 @@ class D3_GLCM_feature : public FeatureMethod, public TextureFeature double f_GLCM_JAVE(); double f_GLCM_JE(const SimpleMatrix& P_matrix); double f_GLCM_JMAX(const SimpleMatrix& P_matrix); - double f_GLCM_JVAR(const SimpleMatrix& P_matrix, double mean_x); using AngledFeatures = std::vector; void copyfvals(AngledFeatures& dst, const AngledFeatures& src); @@ -235,7 +237,7 @@ class D3_GLCM_feature : public FeatureMethod, public TextureFeature double hx = -1, hy = -1, hxy = -1, hxy1 = -1, hxy2 = -1; // Entropies for f12/f13_icorr calculation void calcH(const SimpleMatrix& P_matrix, std::vector& px, std::vector& py); - double f_info_meas_corr1(const SimpleMatrix& P_matrix); + double f_info_meas_corr1(const SimpleMatrix& P_matrix, double softnan); double f_info_meas_corr2(const SimpleMatrix& P_matrix); double f_energy(const SimpleMatrix& P_matrix); @@ -250,7 +252,8 @@ class D3_GLCM_feature : public FeatureMethod, public TextureFeature Pxmy, kValuesSum, // intensities x+y kValuesDiff; // intensities x-y - double by_row_mean; + double mean_x = 0, // mean grey level of the reference voxel, mu_x + mean_y = 0; // mean grey level of its neighbour, mu_y const double EPSILON = 0.000000001; }; diff --git a/src/nyx/features/glcm.cpp b/src/nyx/features/glcm.cpp index c9623e52..8d2c07f9 100644 --- a/src/nyx/features/glcm.cpp +++ b/src/nyx/features/glcm.cpp @@ -32,69 +32,10 @@ void GLCMFeature::calculate (LR& r, const Fsettings& s) auto binnedMax = bin_pixel(r.aux_max, r.aux_min, r.aux_max, nGreys); if (binnedMin == binnedMax) { - auto w = softNAN; // safe NAN - - // assign it to each angled feature value - auto n = angles.size(); - r.fvals[(int)Feature2D::GLCM_ASM].assign(n, w); - r.fvals[(int)Feature2D::GLCM_ACOR].assign(n, w); - r.fvals[(int)Feature2D::GLCM_CLUPROM].assign(n, w); - r.fvals[(int)Feature2D::GLCM_CLUSHADE].assign(n, w); - r.fvals[(int)Feature2D::GLCM_CLUTEND].assign(n, w); - r.fvals[(int)Feature2D::GLCM_CONTRAST].assign(n, w); - r.fvals[(int)Feature2D::GLCM_CORRELATION].assign(n, w); - r.fvals[(int)Feature2D::GLCM_DIFAVE].assign(n, w); - r.fvals[(int)Feature2D::GLCM_DIFENTRO].assign(n, w); - r.fvals[(int)Feature2D::GLCM_DIFVAR].assign(n, w); - r.fvals[(int)Feature2D::GLCM_DIS].assign(n, w); - r.fvals[(int)Feature2D::GLCM_ENERGY].assign(n, w); - r.fvals[(int)Feature2D::GLCM_ENTROPY].assign(n, w); - r.fvals[(int)Feature2D::GLCM_HOM1].assign(n, w); - r.fvals[(int)Feature2D::GLCM_HOM2].assign(n, w); - r.fvals[(int)Feature2D::GLCM_IDMN].assign(n, w); - r.fvals[(int)Feature2D::GLCM_ID].assign(n, w); - r.fvals[(int)Feature2D::GLCM_IDN].assign(n, w); - r.fvals[(int)Feature2D::GLCM_INFOMEAS1].assign(n, w); - r.fvals[(int)Feature2D::GLCM_INFOMEAS2].assign(n, w); - r.fvals[(int)Feature2D::GLCM_IDM].assign(n, w); - r.fvals[(int)Feature2D::GLCM_IV].assign(n, w); - r.fvals[(int)Feature2D::GLCM_JAVE].assign(n, w); - r.fvals[(int)Feature2D::GLCM_JE].assign(n, w); - r.fvals[(int)Feature2D::GLCM_JMAX].assign(n, w); - r.fvals[(int)Feature2D::GLCM_JVAR].assign(n, w); - r.fvals[(int)Feature2D::GLCM_SUMAVERAGE].assign(n, w); - r.fvals[(int)Feature2D::GLCM_SUMENTROPY].assign(n, w); - r.fvals[(int)Feature2D::GLCM_SUMVARIANCE].assign(n, w); - r.fvals[(int)Feature2D::GLCM_VARIANCE].assign(n, w); - r.fvals[(int)Feature2D::GLCM_ASM_AVE][0] = - r.fvals[(int)Feature2D::GLCM_ACOR_AVE][0] = - r.fvals[(int)Feature2D::GLCM_CLUPROM_AVE][0] = - r.fvals[(int)Feature2D::GLCM_CLUSHADE_AVE][0] = - r.fvals[(int)Feature2D::GLCM_CLUTEND_AVE][0] = - r.fvals[(int)Feature2D::GLCM_CONTRAST_AVE][0] = - r.fvals[(int)Feature2D::GLCM_CORRELATION_AVE][0] = - r.fvals[(int)Feature2D::GLCM_DIFAVE_AVE][0] = - r.fvals[(int)Feature2D::GLCM_DIFENTRO_AVE][0] = - r.fvals[(int)Feature2D::GLCM_DIFVAR_AVE][0] = - r.fvals[(int)Feature2D::GLCM_DIS_AVE][0] = - r.fvals[(int)Feature2D::GLCM_ENERGY_AVE][0] = - r.fvals[(int)Feature2D::GLCM_ENTROPY_AVE][0] = - r.fvals[(int)Feature2D::GLCM_HOM1_AVE][0] = - r.fvals[(int)Feature2D::GLCM_ID_AVE][0] = - r.fvals[(int)Feature2D::GLCM_IDN_AVE][0] = - r.fvals[(int)Feature2D::GLCM_IDM_AVE][0] = - r.fvals[(int)Feature2D::GLCM_IDMN_AVE][0] = - r.fvals[(int)Feature2D::GLCM_IV_AVE][0] = - r.fvals[(int)Feature2D::GLCM_JAVE_AVE][0] = - r.fvals[(int)Feature2D::GLCM_JE_AVE][0] = - r.fvals[(int)Feature2D::GLCM_INFOMEAS1_AVE][0] = - r.fvals[(int)Feature2D::GLCM_INFOMEAS2_AVE][0] = - r.fvals[(int)Feature2D::GLCM_JMAX_AVE][0] = - r.fvals[(int)Feature2D::GLCM_JVAR_AVE][0] = - r.fvals[(int)Feature2D::GLCM_SUMAVERAGE_AVE][0] = - r.fvals[(int)Feature2D::GLCM_SUMENTROPY_AVE][0] = - r.fvals[(int)Feature2D::GLCM_SUMVARIANCE_AVE][0] = - r.fvals[(int)Feature2D::GLCM_VARIANCE_AVE][0] = w; + // One grey level: every angle reports the substitute, which save_value() writes to the + // angled columns and averages into the _AVE ones + for (size_t a = 0; a < angles.size(); a++) + push_noval (softNAN); return; } @@ -121,45 +62,11 @@ void GLCMFeature::refuse_roi (int label, double w, const char* reason) clear_result_buffers(); for (size_t i = 0; i < angles.size(); i++) - push_angle_value (w); + push_noval (w); std::cerr << "Error: ROI " + std::to_string(label) + ": GLCM features not calculated, set to the no-value substitute: " + reason + "\n"; } -void GLCMFeature::push_angle_value (double w) -{ - fvals_ASM.push_back(w); - fvals_acor.push_back(w); - fvals_cluprom.push_back(w); - fvals_clushade.push_back(w); - fvals_clutend.push_back(w); - fvals_contrast.push_back(w); - fvals_correlation.push_back(w); - fvals_diff_avg.push_back(w); - fvals_diff_var.push_back(w); - fvals_diff_entropy.push_back(w); - fvals_dis.push_back(w); - fvals_energy.push_back(w); - fvals_entropy.push_back(w); - fvals_homo.push_back(w); - fvals_hom2.push_back(w); - fvals_id.push_back(w); - fvals_idn.push_back(w); - fvals_IDM.push_back(w); - fvals_idmn.push_back(w); - fvals_meas_corr1.push_back(w); - fvals_meas_corr2.push_back(w); - fvals_iv.push_back(w); - fvals_jave.push_back(w); - fvals_je.push_back(w); - fvals_jmax.push_back(w); - fvals_jvar.push_back(w); - fvals_sum_avg.push_back(w); - fvals_sum_var.push_back(w); - fvals_sum_entropy.push_back(w); - fvals_variance.push_back(w); -} - void GLCMFeature::clear_result_buffers() { fvals_ASM.clear(); @@ -204,10 +111,7 @@ void GLCMFeature::copyfvals(AngledFeatures& dst, const AngledFeatures& src) void GLCMFeature::save_value(std::vector>& fvals) { copyfvals(fvals[(int)Feature2D::GLCM_ASM], fvals_ASM); - copyfvals(fvals[(int)Feature2D::GLCM_ACOR], fvals_acor); - copyfvals(fvals[(int)Feature2D::GLCM_ACOR], fvals_acor); - copyfvals(fvals[(int)Feature2D::GLCM_CLUPROM], fvals_cluprom); copyfvals(fvals[(int)Feature2D::GLCM_CLUSHADE], fvals_clushade); copyfvals(fvals[(int)Feature2D::GLCM_CLUTEND], fvals_clutend); @@ -250,6 +154,7 @@ void GLCMFeature::save_value(std::vector>& fvals) fvals[(int)Feature2D::GLCM_ENERGY_AVE][0] = calc_ave(fvals_energy); fvals[(int)Feature2D::GLCM_ENTROPY_AVE][0] = calc_ave(fvals_entropy); fvals[(int)Feature2D::GLCM_HOM1_AVE][0] = calc_ave(fvals_homo); + fvals[(int)Feature2D::GLCM_HOM2_AVE][0] = calc_ave(fvals_hom2); fvals[(int)Feature2D::GLCM_ID_AVE][0] = calc_ave(fvals_id); fvals[(int)Feature2D::GLCM_IDN_AVE][0] = calc_ave(fvals_idn); fvals[(int)Feature2D::GLCM_IDM_AVE][0] = calc_ave(fvals_IDM); @@ -265,7 +170,6 @@ void GLCMFeature::save_value(std::vector>& fvals) fvals[(int)Feature2D::GLCM_SUMAVERAGE_AVE][0] = calc_ave(fvals_sum_avg); fvals[(int)Feature2D::GLCM_SUMVARIANCE_AVE][0] = calc_ave(fvals_sum_var); fvals[(int)Feature2D::GLCM_SUMENTROPY_AVE][0] = calc_ave(fvals_sum_entropy); - fvals[(int)Feature2D::GLCM_VARIANCE_AVE][0] = calc_ave(fvals_variance); } void GLCMFeature::extract (LR& r, const Fsettings& s) @@ -317,19 +221,18 @@ void GLCMFeature::Extract_Texture_Features2 (const Fsettings& s, int angle, cons calculateCoocMatAtAngle (P_matrix, s, dx, dy, grays, min_val, max_val); - // Blank cooc-matrix? -- no point to use it, assign each feature value '0' and return. + // Blank cooc-matrix? -- no point to use it, assign each feature value the substitute and return. if (sum_p == 0) { - push_angle_value (s[(int)NyxSetting::SOFTNAN].rval); - + push_noval (s[(int)NyxSetting::SOFTNAN].rval); return; } // Output - 'Pxpy' (meaning: 'x plus y') and 'Pxmy' (meaning: 'x minus y') calculatePxpmy(); - // Calculate by-row mean. (Output - 'by_row_mean') - calculate_by_row_mean(); + // Output - 'mean_x' and 'mean_y' + calculate_marginal_means(); // Compute Haralick statistics fvals_ASM.push_back (f_asm(P_matrix)); @@ -337,7 +240,10 @@ void GLCMFeature::Extract_Texture_Features2 (const Fsettings& s, int angle, cons fvals_correlation.push_back (f_corr(s[(int)NyxSetting::SOFTNAN].rval)); fvals_energy.push_back (f_energy(P_matrix)); fvals_homo.push_back (f_homogeneity()); - fvals_variance.push_back (f_var(P_matrix)); + // GLCM_VARIANCE and GLCM_JVAR are both IBSI joint variance, sum_ij (i - mu_x)^2 p(i,j), so it is + // calculated once + double jvar = f_var(P_matrix); + fvals_variance.push_back (jvar); fvals_IDM.push_back (f_idm()); fvals_sum_avg.push_back (f_savg()); fvals_sum_entropy.push_back (f_sentropy()); @@ -351,7 +257,9 @@ void GLCMFeature::Extract_Texture_Features2 (const Fsettings& s, int angle, cons fvals_cluprom.push_back (f_GLCM_CLUPROM()); fvals_clushade.push_back (f_GLCM_CLUSHADE()); - // 'cluster tendency' is equivalent to 'sum variance', so calculate it once + // Cluster tendency, sum_ij (i + j - mu_x - mu_y)^2 p(i,j), and IBSI sum variance, + // sum_k (k - SA)^2 p_{x+y}(k), are the same sum on every matrix because the IBSI sum average + // SA = sum_k k p_{x+y}(k) is mu_x + mu_y, so it is calculated once double clutend = f_GLCM_CLUTEND(); fvals_clutend.push_back (clutend); fvals_sum_var.push_back (clutend); @@ -368,7 +276,7 @@ void GLCMFeature::Extract_Texture_Features2 (const Fsettings& s, int angle, cons fvals_je.push_back (f_GLCM_JE(P_matrix)); fvals_jmax.push_back (f_GLCM_JMAX(P_matrix)); - fvals_jvar.push_back (f_GLCM_JVAR(P_matrix, jave)); + fvals_jvar.push_back (jvar); } void GLCMFeature::allocate_cooc (SimpleMatrix& GLCM, size_t n_levels) @@ -546,27 +454,55 @@ void GLCMFeature::calculatePxpmy() } } -void GLCMFeature::calculate_by_row_mean() +void GLCMFeature::calculate_marginal_means() { int n_levels = I.size(); - // px[i] is the (i-1)th entry in the marginal probability matrix obtained - // by summing the rows of p[i][j] - std::vector px(n_levels); - for (int j = 0; j < n_levels; j++) - for (int i = 0; i < n_levels; i++) - px[i] += P_matrix.xy(i, j) / sum_p; - - // Now calculate the means and standard deviations of px and py */ - // - fix supplied by J. Michael Christensen, 21 Jun 1991 */ - // - further modified by James Darrell McCauley, 16 Aug 1991 - // after realizing that meanx=meany and stddevx=stddevy - by_row_mean = 0; - for (int i = 0; i < n_levels; ++i) - { - double ival = I[i]; - by_row_mean += px[i] * ival; - } + // P_matrix.yx(r, c) counts the pairs whose reference pixel has level I[r] and whose neighbour + // has level I[c], so the reference marginal sums a row and the neighbour marginal a column. + // The two means differ unless the matrix is symmetric. + mean_x = mean_y = 0; + for (int r = 0; r < n_levels; r++) + for (int c = 0; c < n_levels; c++) + { + double p = P_matrix.yx(r, c) / sum_p; + mean_x += p * I[r]; + mean_y += p * I[c]; + } +} + +void GLCMFeature::push_noval (double softnan) +{ + fvals_ASM.push_back (softnan); + fvals_acor.push_back (softnan); + fvals_cluprom.push_back (softnan); + fvals_clushade.push_back (softnan); + fvals_clutend.push_back (softnan); + fvals_contrast.push_back (softnan); + fvals_correlation.push_back (softnan); + fvals_diff_avg.push_back (softnan); + fvals_diff_var.push_back (softnan); + fvals_diff_entropy.push_back (softnan); + fvals_dis.push_back (softnan); + fvals_energy.push_back (softnan); + fvals_entropy.push_back (softnan); + fvals_homo.push_back (softnan); + fvals_hom2.push_back (softnan); + fvals_id.push_back (softnan); + fvals_idn.push_back (softnan); + fvals_IDM.push_back (softnan); + fvals_idmn.push_back (softnan); + fvals_meas_corr1.push_back (softnan); + fvals_meas_corr2.push_back (softnan); + fvals_iv.push_back (softnan); + fvals_jave.push_back (softnan); + fvals_je.push_back (softnan); + fvals_jmax.push_back (softnan); + fvals_jvar.push_back (softnan); + fvals_sum_avg.push_back (softnan); + fvals_sum_var.push_back (softnan); + fvals_sum_entropy.push_back (softnan); + fvals_variance.push_back (softnan); } /* Angular Second Moment @@ -878,10 +814,11 @@ void GLCMFeature::calcH(const SimpleMatrix& P, std::vector& px, double GLCMFeature::f_info_meas_corr1 (const SimpleMatrix& P, double softnan) { + // IMC1 = (HXY - HXY1) / max(HX, HY), HX and HY the entropies of the two marginals auto Ng = P.width(); - double HX = 0, HXY = 0, HXY1 = 0; + double HX = 0, HY = 0, HXY = 0, HXY1 = 0; std::vector px, py; px.resize (Ng); @@ -905,12 +842,12 @@ double GLCMFeature::f_info_meas_corr1 (const SimpleMatrix& P, double sof for (int i = 0; i < Ng; ++i) { HX += px[i] * fast_log10(px[i] + EPSILON) / LOG10_2; - + HY += py[i] * fast_log10(py[i] + EPSILON) / LOG10_2; } - // Undefined when a grey-tone marginal is a single level (HX -> 0 -> 0/0 -> NaN), which can - // happen on a tiny/uniform ROI once out-of-ROI background is correctly excluded. - double r = (HXY - HXY1) / HX; + // The sums above are the negated entropies, so the larger entropy is the smaller sum. + // Undefined when both marginals are a single level (0/0 -> NaN), as on a tiny or uniform ROI. + double r = (HXY - HXY1) / std::min (HX, HY); if (!std::isfinite(r)) return softnan; return r; @@ -998,9 +935,7 @@ double GLCMFeature::f_GLCM_ACOR(const SimpleMatrix& P) return f; } -// -// Argument 'mean_x' is calculated by f_corr() -// +// The cluster features centre i + j on mu_x + mu_y (calculate_marginal_means()) double GLCMFeature::f_GLCM_CLUPROM() { int n_levels = I.size(); @@ -1015,7 +950,7 @@ double GLCMFeature::f_GLCM_CLUPROM() for (int c = 0; c < n_levels; c++) { double cval = I[c]; - double m = rval + cval - by_row_mean - by_row_mean; + double m = rval + cval - mean_x - mean_y; f += m * m * m * m * P_matrix.yx(r,c) / sum_p; } } @@ -1037,7 +972,7 @@ double GLCMFeature::f_GLCM_CLUSHADE() for (int c = 0; c < n_levels; c++) { double cval = I[c]; - double m = rval + cval - by_row_mean - by_row_mean; + double m = rval + cval - mean_x - mean_y; f += m * m * m * P_matrix.yx(r, c) / sum_p; } } @@ -1064,7 +999,7 @@ double GLCMFeature::f_GLCM_CLUTEND() for (int y = 0; y < n_levels; y++) { double yval = I[y]; - double m = xval + yval - by_row_mean * 2.0; + double m = xval + yval - mean_x - mean_y; f += m * m * P_matrix.xy(x, y) / sum_p ; } } @@ -1215,25 +1150,6 @@ double GLCMFeature::f_GLCM_JMAX(const SimpleMatrix& P_matrix) return max_p; } -double GLCMFeature::f_GLCM_JVAR(const SimpleMatrix& P_matrix, double joint_ave) -{ - int n_levels = I.size(); - - // joint variance = \sum^{N_g}_{i=1} \sum^{N_g}_{j=1} (i-\mu_x) ^2 p(i,j) - // where \mu_x is the value of joint average feature (IBSI: "Fcm.joint.avg"), - // \mu_x = \sum^{N_g}_{i=1} \sum^{N_g}_{j=1} i p(i,j) - - double f = 0; - for (int x = 0; x < n_levels; x++) - { - double d = double(x + 1) - joint_ave, - d2 = d * d; - for (int y = 0; y < n_levels; y++) - f += d2 * P_matrix.xy(x, y) / sum_p; - } - return f; -} - // 'afv' is angled feature values double GLCMFeature::calc_ave(const std::vector& afv) { diff --git a/src/nyx/features/glcm.h b/src/nyx/features/glcm.h index 7e4a7988..13015d2d 100644 --- a/src/nyx/features/glcm.h +++ b/src/nyx/features/glcm.h @@ -72,6 +72,7 @@ class GLCMFeature : public FeatureMethod, public TextureFeature Nyxus::Feature2D::GLCM_ENERGY_AVE, Nyxus::Feature2D::GLCM_ENTROPY_AVE, Nyxus::Feature2D::GLCM_HOM1_AVE, + Nyxus::Feature2D::GLCM_HOM2_AVE, Nyxus::Feature2D::GLCM_ID_AVE, Nyxus::Feature2D::GLCM_IDN_AVE, Nyxus::Feature2D::GLCM_IDM_AVE, @@ -106,6 +107,7 @@ class GLCMFeature : public FeatureMethod, public TextureFeature Nyxus::Feature2D::GLCM_ENERGY_AVE, Nyxus::Feature2D::GLCM_ENTROPY_AVE, Nyxus::Feature2D::GLCM_HOM1_AVE, + Nyxus::Feature2D::GLCM_HOM2_AVE, Nyxus::Feature2D::GLCM_ID_AVE, Nyxus::Feature2D::GLCM_IDN_AVE, Nyxus::Feature2D::GLCM_IDM_AVE, @@ -155,7 +157,9 @@ class GLCMFeature : public FeatureMethod, public TextureFeature PixIntens max_val); void calculatePxpmy(); - void calculate_by_row_mean(); + void calculate_marginal_means(); + // Appends 'softnan' to the per-angle buffer of every GLCM feature + void push_noval (double softnan); static inline int cast_to_range(PixIntens orig_I, PixIntens min_orig_I, PixIntens max_orig_I, int min_target_I, int max_target_I) { @@ -187,7 +191,6 @@ class GLCMFeature : public FeatureMethod, public TextureFeature double f_GLCM_JAVE(); double f_GLCM_JE(const SimpleMatrix& P_matrix); double f_GLCM_JMAX(const SimpleMatrix& P_matrix); - double f_GLCM_JVAR(const SimpleMatrix& P_matrix, double mean_x); double calc_ave(const std::vector& angled_feature_vals); @@ -228,9 +231,6 @@ class GLCMFeature : public FeatureMethod, public TextureFeature void clear_result_buffers(); - // Appends 'w' to the per-angle buffer of every GLCM feature - void push_angle_value (double w); - // Replaces the ROI's results with 'w' for every angle and reports the ROI on stderr void refuse_roi (int label, double w, const char* reason); @@ -254,6 +254,7 @@ class GLCMFeature : public FeatureMethod, public TextureFeature Pxmy, kValuesSum, // intensities x+y kValuesDiff; // intensities x-y - double by_row_mean; + double mean_x = 0, // mean grey level of the reference pixel, mu_x + mean_y = 0; // mean grey level of its neighbour, mu_y const double EPSILON = 0.000000001; }; diff --git a/src/nyx/featureset.cpp b/src/nyx/featureset.cpp index 18191df9..0055ad57 100644 --- a/src/nyx/featureset.cpp +++ b/src/nyx/featureset.cpp @@ -283,6 +283,7 @@ namespace Nyxus { "GLCM_ENERGY_AVE", Feature2D::GLCM_ENERGY_AVE }, { "GLCM_ENTROPY_AVE", Feature2D::GLCM_ENTROPY_AVE }, { "GLCM_HOM1_AVE", Feature2D::GLCM_HOM1_AVE }, + { "GLCM_HOM2_AVE", Feature2D::GLCM_HOM2_AVE }, { "GLCM_ID_AVE", Feature2D::GLCM_ID_AVE }, { "GLCM_IDN_AVE", Feature2D::GLCM_IDN_AVE }, { "GLCM_IDM_AVE", Feature2D::GLCM_IDM_AVE }, @@ -808,6 +809,7 @@ namespace Nyxus { "3GLCM_ENERGY_AVE", Feature3D::GLCM_ENERGY_AVE }, { "3GLCM_ENTROPY_AVE", Feature3D::GLCM_ENTROPY_AVE }, { "3GLCM_HOM1_AVE", Feature3D::GLCM_HOM1_AVE }, + { "3GLCM_HOM2_AVE", Feature3D::GLCM_HOM2_AVE }, { "3GLCM_ID_AVE", Feature3D::GLCM_ID_AVE }, { "3GLCM_IDN_AVE", Feature3D::GLCM_IDN_AVE }, { "3GLCM_IDM_AVE", Feature3D::GLCM_IDM_AVE }, diff --git a/src/nyx/featureset.h b/src/nyx/featureset.h index 65922267..ee0fe9d1 100644 --- a/src/nyx/featureset.h +++ b/src/nyx/featureset.h @@ -216,6 +216,7 @@ namespace Nyxus GLCM_ENERGY_AVE, GLCM_ENTROPY_AVE, GLCM_HOM1_AVE, + GLCM_HOM2_AVE, GLCM_ID_AVE, GLCM_IDN_AVE, GLCM_IDM_AVE, @@ -780,6 +781,7 @@ namespace Nyxus GLCM_ENERGY_AVE, GLCM_ENTROPY_AVE, GLCM_HOM1_AVE, + GLCM_HOM2_AVE, GLCM_ID_AVE, GLCM_IDN_AVE, GLCM_IDM_AVE, diff --git a/tests/test_2d_glcm_analytic.h b/tests/test_2d_glcm_analytic.h new file mode 100644 index 00000000..909f27a9 --- /dev/null +++ b/tests/test_2d_glcm_analytic.h @@ -0,0 +1,242 @@ +#pragma once + +#include + +#include +#include +#include + +#include "test_2d_glcm_common.h" // GLCMFeature, Fsettings, LR, NyxusPixel, load_masked_test_roi_data + +// 2D GLCM on an asymmetric co-occurrence matrix against the IBSI definitions evaluated in the test. +// +// MATLAB-style binning, Nyxus' default (a positive grey depth, 64 levels here), counts each ordered +// pair of pixels once, so the matrix P(i, j) -- i the grey level of the pixel, j that of its neighbour +// at the angle's offset -- is not symmetric. The features below read the two marginals p_x (the +// pixel's) and p_y (the neighbour's) separately, and on such a matrix they tell apart a definition that +// mixes the marginals from IBSI's: +// +// cluster tendency, shade, prominence (DG8W, 7NFM, AE86) sum_ij (i + j - mu_x - mu_y)^{2,3,4} p_ij +// sum variance (OEEB) sum_k (k - SA)^2 p_{x+y}(k), SA = sum_k k p_{x+y}(k) +// joint variance (UR99) sum_ij (i - mu_x)^2 p_ij +// information correlation 1 (R8DG) (HXY - HXY1) / max(HX, HY) +// +// PyRadiomics run with symmetricalGLCM=False uses the same definitions (ClusterTendency, ClusterShade, +// ClusterProminence, SumSquares, Imc1); on the binned levels of the fixture below it agrees with this +// reference to 2e-15 for both orientations. +// +// The fixture is the 5 x 5 GLCM example image of the PyRadiomics documentation, and its left-right +// mirror. Mirroring turns the 0-degree matrix into its transpose, so a feature that depends on the +// matrix only through the IBSI expressions above, all symmetric in the two marginals except joint +// variance, has the same 0-degree value on both; and it turns the 45-degree matrix into the mirror's +// 135-degree one. +// +// Kind: *analytic* per tests/vetting/SPEC.md 4: the reference is the definition evaluated here, on a +// co-occurrence matrix counted from the fixture without Nyxus. + +static const unsigned int glcm_2d_asym_side = 5; +static const unsigned int glcm_2d_asym_image[glcm_2d_asym_side][glcm_2d_asym_side] = +{ + {1, 2, 5, 2, 3}, + {3, 2, 1, 3, 1}, + {1, 3, 5, 5, 2}, + {1, 1, 1, 1, 2}, + {1, 2, 4, 3, 5} +}; +static const int glcm_2d_asym_levels = 64; // the default coarse grey depth + +// The fixture's intensity at (x, y), mirrored left-right when 'mirror' is set. +static unsigned int glcm_2d_asym_intensity (unsigned int x, unsigned int y, bool mirror) +{ + return glcm_2d_asym_image[y][mirror ? glcm_2d_asym_side - 1 - x : x]; +} + +// The fixture inside a one-pixel background frame, so the ROI fills the 5 x 5 square. +static void make_2d_glcm_asym_roi (LR& roidata, bool mirror) +{ + const unsigned int side = glcm_2d_asym_side + 2; + std::vector intensity, mask; + for (unsigned int y = 0; y < side; y++) + for (unsigned int x = 0; x < side; x++) + { + const bool in_roi = x >= 1 && x <= glcm_2d_asym_side && y >= 1 && y <= glcm_2d_asym_side; + intensity.push_back (NyxusPixel {x, y, in_roi ? glcm_2d_asym_intensity (x - 1, y - 1, mirror) : 0u}); + mask.push_back (NyxusPixel {x, y, in_roi ? 1u : 0u}); + } + Nyxus::load_masked_test_roi_data (roidata, intensity.data(), mask.data(), intensity.size()); +} + +// Default binning: MATLAB-style at 64 levels, asymmetric matrix, offset 1, the four 2D angles. +static Fsettings make_2d_glcm_asym_settings() +{ + Fsettings s = make_2d_glcm_dense_settings(); + s[(int)NyxSetting::IBSI].bval = false; + s[(int)NyxSetting::GREYDEPTH].ival = glcm_2d_asym_levels; + s[(int)NyxSetting::GLCM_GREYDEPTH].ival = glcm_2d_asym_levels; + return s; +} + +static std::vector> run_2d_glcm_asym (bool mirror) +{ + LR roidata; + make_2d_glcm_asym_roi (roidata, mirror); + GLCMFeature::symmetric_glcm = false; + GLCMFeature::angles = {0, 45, 90, 135}; + GLCMFeature f; + f.calculate (roidata, make_2d_glcm_asym_settings()); + roidata.initialize_fvals(); + f.save_value (roidata.fvals); + return roidata.fvals; +} + +struct Glcm2dIbsiValues +{ + double clutend, clushade, cluprom, sumvariance, jvar, infomeas1; +}; + +// The IBSI values of the fixture at offset (dx, dy), each angle's offset in glcm.cpp. Levels are +// MATLAB-style, floor(n x / max + 1) clipped to 1..n over the ROI's maximum, which is how a positive +// grey depth bins; the whole 5 x 5 square is the ROI. +static Glcm2dIbsiValues glcm_2d_ibsi_values (bool mirror, int dx, int dy) +{ + const int n = glcm_2d_asym_levels, side = (int) glcm_2d_asym_side; + unsigned int mx = 0; + for (int y = 0; y < side; y++) + for (int x = 0; x < side; x++) + mx = std::max (mx, glcm_2d_asym_intensity (x, y, mirror)); + auto level = [&](int x, int y) + { + const int l = (int) std::floor (double(n) * glcm_2d_asym_intensity (x, y, mirror) / double(mx) + 1.); + return std::min (std::max (l, 1), n); + }; + + // P(i, j), i the level of pixel (x, y) and j that of its neighbour (x + dx, y + dy), normalised + std::vector> p (n + 1, std::vector (n + 1, 0.)); + double total = 0; + for (int y = 0; y < side; y++) + for (int x = 0; x < side; x++) + { + const int xn = x + dx, yn = y + dy; + if (xn < 0 || xn >= side || yn < 0 || yn >= side) + continue; + p[level (x, y)][level (xn, yn)] += 1; + total += 1; + } + + std::vector px (n + 1, 0.), py (n + 1, 0.), pxpy (2 * n + 1, 0.); + double mux = 0, muy = 0; + for (int i = 1; i <= n; i++) + for (int j = 1; j <= n; j++) + { + p[i][j] /= total; + px[i] += p[i][j]; + py[j] += p[i][j]; + pxpy[i + j] += p[i][j]; + mux += i * p[i][j]; + muy += j * p[i][j]; + } + + Glcm2dIbsiValues v {}; + double hxy = 0, hxy1 = 0, hx = 0, hy = 0; + for (int i = 1; i <= n; i++) + for (int j = 1; j <= n; j++) + { + const double m = i + j - mux - muy; + v.clutend += m * m * p[i][j]; + v.clushade += m * m * m * p[i][j]; + v.cluprom += m * m * m * m * p[i][j]; + v.jvar += (i - mux) * (i - mux) * p[i][j]; + if (p[i][j] > 0) + { + hxy -= p[i][j] * std::log2 (p[i][j]); + hxy1 -= p[i][j] * std::log2 (px[i] * py[j]); + } + } + for (int i = 1; i <= n; i++) + { + if (px[i] > 0) + hx -= px[i] * std::log2 (px[i]); + if (py[i] > 0) + hy -= py[i] * std::log2 (py[i]); + } + v.infomeas1 = (hxy - hxy1) / std::max (hx, hy); + + double sa = 0; + for (int k = 2; k <= 2 * n; k++) + sa += k * pxpy[k]; + for (int k = 2; k <= 2 * n; k++) + v.sumvariance += (k - sa) * (k - sa) * pxpy[k]; + + return v; +} + +// (dx, dy) of GLCMFeature::angles {0, 45, 90, 135}, as Extract_Texture_Features2 shifts them +static const int glcm_2d_asym_offsets[4][2] = { {1, 0}, {1, 1}, {0, 1}, {-1, 1} }; + +static void assert_2d_glcm_near (double actual, double expected, double rel, const std::string& what) +{ + EXPECT_NEAR (actual, expected, std::abs (expected) * rel) << what; +} + +// Cluster tendency, shade and prominence centre i + j on mu_x + mu_y, and sum variance is the variance +// of p_{x+y}; each angle of the fixture and of its mirror matches the IBSI expression. Without a log in +// any of them, the band is rounding only. +void test_2d_glcm_cluster_and_sum_variance_asymmetric_analytic() +{ + for (bool mirror : {false, true}) + { + const auto fv = run_2d_glcm_asym (mirror); + for (int a = 0; a < 4; a++) + { + const auto ref = glcm_2d_ibsi_values (mirror, glcm_2d_asym_offsets[a][0], glcm_2d_asym_offsets[a][1]); + const std::string at = std::string (mirror ? "mirror" : "fixture") + " angle " + std::to_string (GLCMFeature::angles[a]); + assert_2d_glcm_near (fv[(int)Nyxus::Feature2D::GLCM_CLUTEND][a], ref.clutend, 1e-9, "CLUTEND " + at); + assert_2d_glcm_near (fv[(int)Nyxus::Feature2D::GLCM_CLUSHADE][a], ref.clushade, 1e-9, "CLUSHADE " + at); + assert_2d_glcm_near (fv[(int)Nyxus::Feature2D::GLCM_CLUPROM][a], ref.cluprom, 1e-9, "CLUPROM " + at); + assert_2d_glcm_near (fv[(int)Nyxus::Feature2D::GLCM_SUMVARIANCE][a], ref.sumvariance, 1e-9, "SUMVARIANCE " + at); + } + } +} + +// Joint variance is the variance of the pixel's own level, sum (i - mu_x)^2 p_ij: the IBSI value at +// every angle, and the same number GLCM_VARIANCE reports. +void test_2d_glcm_jvar_asymmetric_analytic() +{ + for (bool mirror : {false, true}) + { + const auto fv = run_2d_glcm_asym (mirror); + for (int a = 0; a < 4; a++) + { + const auto ref = glcm_2d_ibsi_values (mirror, glcm_2d_asym_offsets[a][0], glcm_2d_asym_offsets[a][1]); + const std::string at = std::string (mirror ? "mirror" : "fixture") + " angle " + std::to_string (GLCMFeature::angles[a]); + assert_2d_glcm_near (fv[(int)Nyxus::Feature2D::GLCM_JVAR][a], ref.jvar, 1e-9, "JVAR " + at); + assert_2d_glcm_near (fv[(int)Nyxus::Feature2D::GLCM_JVAR][a], fv[(int)Nyxus::Feature2D::GLCM_VARIANCE][a], 1e-12, "JVAR vs VARIANCE " + at); + } + } +} + +// Information correlation 1 divides by the larger marginal entropy. Nyxus' entropies read the +// fast_log10 approximation (helpers.h), a convention that puts up to 7.0e-3 relative on this quotient +// of a difference of entropies; the band is 1.5e-2, below the 4.3 % a divisor taken from one fixed +// marginal is off on the mirror's 0-degree matrix. The orientation check needs no band beyond +// rounding: the mirror's 0-degree matrix is the transpose of the fixture's, and HXY, HXY1 and +// max(HX, HY) do not change under a transpose. +void test_2d_glcm_infomeas1_asymmetric_analytic() +{ + const auto fixture = run_2d_glcm_asym (false), + mirror = run_2d_glcm_asym (true); + for (bool m : {false, true}) + { + const auto& fv = m ? mirror : fixture; + for (int a = 0; a < 4; a++) + { + const auto ref = glcm_2d_ibsi_values (m, glcm_2d_asym_offsets[a][0], glcm_2d_asym_offsets[a][1]); + assert_2d_glcm_near (fv[(int)Nyxus::Feature2D::GLCM_INFOMEAS1][a], ref.infomeas1, 1.5e-2, + std::string ("INFOMEAS1 ") + (m ? "mirror" : "fixture") + " angle " + std::to_string (GLCMFeature::angles[a])); + } + } + + const int code = (int)Nyxus::Feature2D::GLCM_INFOMEAS1; + assert_2d_glcm_near (mirror[code][0], fixture[code][0], 1e-12, "INFOMEAS1 at 0 degrees, mirror vs fixture"); + assert_2d_glcm_near (mirror[code][3], fixture[code][1], 1e-12, "INFOMEAS1 at 135 degrees on the mirror vs 45 on the fixture"); +} diff --git a/tests/test_2d_glcm_ibsi.h b/tests/test_2d_glcm_ibsi.h index bd61f8ef..02dd54cf 100644 --- a/tests/test_2d_glcm_ibsi.h +++ b/tests/test_2d_glcm_ibsi.h @@ -397,6 +397,11 @@ void test_2d_glcm_idm_ave_ibsi() assert_glcm_feature_ibsi(Nyxus::Feature2D::GLCM_IDM_AVE, "GLCM_IDM_AVE"); } +void test_2d_glcm_hom2_ave_ibsi() +{ + assert_glcm_feature_ibsi(Nyxus::Feature2D::GLCM_HOM2_AVE, "GLCM_HOM2_AVE"); +} + void test_2d_glcm_infomeas1_ave_ibsi() { assert_glcm_feature_ibsi(Nyxus::Feature2D::GLCM_INFOMEAS1_AVE, "GLCM_INFOMEAS1_AVE"); diff --git a/tests/test_2d_glcm_mechanics.h b/tests/test_2d_glcm_mechanics.h index c025997e..4eb9b90c 100644 --- a/tests/test_2d_glcm_mechanics.h +++ b/tests/test_2d_glcm_mechanics.h @@ -1,6 +1,7 @@ #pragma once #include +#include #include #include "../src/nyx/environment.h" @@ -71,6 +72,129 @@ inline void test_2d_glcm_own_greydepth_bins_the_matrix_mechanics() ASSERT_TRUE (any_differs); } +// Runs 2D GLCM through extract(), the entry point the trivial-ROI pass calls, which is calculate() +// followed by save_value(), on a w x h ROI that fills its frame, at the default grey depth and the +// given soft-NaN substitute. +template +static std::vector> run_2d_glcm_extract (unsigned int w, unsigned int h, Inten inten, double softnan) +{ + std::vector intensity, mask; + for (unsigned int y = 0; y < h; y++) + for (unsigned int x = 0; x < w; x++) + { + intensity.push_back (NyxusPixel {x, y, (unsigned int) inten (x, y)}); + mask.push_back (NyxusPixel {x, y, 1u}); + } + + Fsettings s = make_2d_glcm_dense_settings(); + s[(int)NyxSetting::IBSI].bval = false; + s[(int)NyxSetting::GREYDEPTH].ival = 64; + s[(int)NyxSetting::GLCM_GREYDEPTH].ival = 64; + s[(int)NyxSetting::SOFTNAN].rval = softnan; + + LR roidata; + GLCMFeature::symmetric_glcm = false; + GLCMFeature::angles = {0, 45, 90, 135}; + Nyxus::load_masked_test_roi_data (roidata, intensity.data(), mask.data(), intensity.size()); + roidata.initialize_fvals(); + GLCMFeature::extract (roidata, s); + return roidata.fvals; +} + +// A ROI of one grey level has no co-occurrence statistics, and every GLCM feature reports the soft-NaN +// substitute (--noval) there: one value per angle for an angled feature, one for an _AVE feature. The +// substitute is -999 so that it cannot be mistaken for a computed 0. +inline void test_2d_glcm_constant_roi_reports_noval_mechanics() +{ + const double noval = -999.; + const auto fv = run_2d_glcm_extract (4, 4, [](unsigned int, unsigned int) { return 7; }, noval); + + const std::vector non_angled (GLCMFeature::nonAngledFeatures); + for (auto fc : GLCMFeature::featureset) + { + SCOPED_TRACE ("2D feature code " + std::to_string ((int)fc)); + const bool ave = std::find (non_angled.begin(), non_angled.end(), fc) != non_angled.end(); + const auto& v = fv[(int)fc]; + if (ave) + ASSERT_FALSE (v.empty()); + else + ASSERT_EQ (v.size(), GLCMFeature::angles.size()); + for (double x : v) + ASSERT_EQ (x, noval); + if (ave) + ASSERT_EQ (v[0], noval); + } +} + +// The same pass on a ROI of two grey levels computes the features: no angle of any GLCM feature +// reports the substitute, so it is the constant ROI, not the substitute setting, that selects it. +inline void test_2d_glcm_two_level_roi_computes_mechanics() +{ + const double noval = -999.; + const auto fv = run_2d_glcm_extract (4, 4, [](unsigned int x, unsigned int y) { return (x + y) % 2 ? 7 : 3; }, noval); + + for (auto fc : GLCMFeature::featureset) + { + SCOPED_TRACE ("2D feature code " + std::to_string ((int)fc)); + ASSERT_FALSE (fv[(int)fc].empty()); + for (double x : fv[(int)fc]) + ASSERT_NE (x, noval); + } +} + +// GLCM_HOM2_AVE is the mean of the per-angle GLCM_HOM2 values, like every _AVE feature; homogeneity 2 +// and the inverse difference moment are the same sum, so it equals GLCM_IDM_AVE as well. +inline void test_2d_glcm_hom2_ave_mechanics() +{ + // looked up by its user-facing name, which is what --features and the output columns go by + auto it = Nyxus::UserFacingFeatureNames.find ("GLCM_HOM2_AVE"); + ASSERT_TRUE (it != Nyxus::UserFacingFeatureNames.end()); + const int hom2_ave = (int) it->second; + ASSERT_TRUE (std::find (GLCMFeature::featureset.begin(), GLCMFeature::featureset.end(), it->second) != GLCMFeature::featureset.end()); + + const auto fv = run_2d_glcm_dense (64, 64); + const auto& hom2 = fv[(int)Nyxus::Feature2D::GLCM_HOM2]; + ASSERT_EQ (hom2.size(), 4u); + const double mean = (hom2[0] + hom2[1] + hom2[2] + hom2[3]) / 4.; + ASSERT_GT (mean, 0.); + ASSERT_NEAR (fv[hom2_ave][0], mean, mean * 1e-12); + ASSERT_NEAR (fv[hom2_ave][0], fv[(int)Nyxus::Feature2D::GLCM_IDM_AVE][0], mean * 1e-12); +} + +// Information correlation 1 is undefined where both marginals hold one grey level (HX = HY = 0). On +// this ROI the horizontal pairs all join level 7 to level 7, while the ROI itself has two levels: the +// third row is a single pixel of level 3 with no horizontal neighbour. The 0-degree value is the +// soft-NaN substitute rather than NaN. +inline void test_2d_glcm_infomeas1_single_level_reports_noval_mechanics() +{ + const double noval = -999.; + std::vector intensity, mask; + for (unsigned int y = 0; y < 3; y++) + for (unsigned int x = 0; x < 3; x++) + { + const bool in_roi = y == 0 || (y == 2 && x == 0); + intensity.push_back (NyxusPixel {x, y, in_roi ? (y == 0 ? 7u : 3u) : 0u}); + mask.push_back (NyxusPixel {x, y, in_roi ? 1u : 0u}); + } + + Fsettings s = make_2d_glcm_dense_settings(); + s[(int)NyxSetting::IBSI].bval = false; + s[(int)NyxSetting::GREYDEPTH].ival = 64; + s[(int)NyxSetting::GLCM_GREYDEPTH].ival = 64; + s[(int)NyxSetting::SOFTNAN].rval = noval; + + LR roidata; + GLCMFeature::symmetric_glcm = false; + GLCMFeature::angles = {0, 45, 90, 135}; + Nyxus::load_masked_test_roi_data (roidata, intensity.data(), mask.data(), intensity.size()); + roidata.initialize_fvals(); + GLCMFeature::extract (roidata, s); + + // the 0-degree matrix has pairs, so the value comes from the quotient's own guard + ASSERT_GT (roidata.fvals[(int)Nyxus::Feature2D::GLCM_ASM][0], 0.); + ASSERT_EQ (roidata.fvals[(int)Nyxus::Feature2D::GLCM_INFOMEAS1][0], noval); +} + static std::vector> extract_2d_glcm_ibsi (unsigned int top_level, double noval) { std::vector intensity, mask; @@ -120,4 +244,4 @@ inline void test_2d_glcm_ibsi_small_roi_not_refused_mechanics() for (double x : v) ASSERT_NE (x, noval); } -} \ No newline at end of file +} diff --git a/tests/test_2d_glcm_mirp.h b/tests/test_2d_glcm_mirp.h index 757aa4ed..f3f4ad51 100644 --- a/tests/test_2d_glcm_mirp.h +++ b/tests/test_2d_glcm_mirp.h @@ -55,6 +55,7 @@ static const ref_vals_map glcm_2d_mirp_ref_vals {"GLCM_IDM", 0.27853769782341209}, // cm_inv_diff_mom {"GLCM_IDM_AVE", 0.27853769782341209}, // cm_inv_diff_mom {"GLCM_HOM2", 0.27853769782341209}, // cm_inv_diff_mom + {"GLCM_HOM2_AVE", 0.27853769782341209}, // cm_inv_diff_mom {"GLCM_IDMN", 0.88734163285067313}, // cm_inv_diff_mom_norm {"GLCM_IDMN_AVE", 0.88734163285067313}, // cm_inv_diff_mom_norm {"GLCM_IDN", 0.77947925090782233}, // cm_inv_diff_norm diff --git a/tests/test_2d_glcm_pyradiomics.h b/tests/test_2d_glcm_pyradiomics.h index 61a6470c..d1a03316 100644 --- a/tests/test_2d_glcm_pyradiomics.h +++ b/tests/test_2d_glcm_pyradiomics.h @@ -56,6 +56,7 @@ static const ref_vals_map glcm_2d_pyradiomics_ref_vals {"GLCM_IDM", 0.27853769782341203}, // Idm {"GLCM_IDM_AVE", 0.27853769782341203}, // Idm {"GLCM_HOM2", 0.27853769782341203}, // Idm + {"GLCM_HOM2_AVE", 0.27853769782341203}, // Idm {"GLCM_IDMN", 0.88734163285067313}, // Idmn {"GLCM_IDMN_AVE", 0.88734163285067313}, // Idmn {"GLCM_IDN", 0.77947925090782222}, // Idn diff --git a/tests/test_2d_glcm_regression.h b/tests/test_2d_glcm_regression.h index 6f79b07d..cbc3541f 100644 --- a/tests/test_2d_glcm_regression.h +++ b/tests/test_2d_glcm_regression.h @@ -30,9 +30,9 @@ static const ref_vals_map glcm_2d_regression_ref_vals { {"GLCM_ACOR", 1437.33}, // absolute-level-dependent: matlab binning re-maps levels, so ibsi=False diverges from a symmetric oracle by ~43%. Vetted on the IBSI path instead -- see below. {"GLCM_ASM", 0.381801}, - {"GLCM_CLUPROM", 6.1972e+06}, - {"GLCM_CLUSHADE", 21905.3}, - {"GLCM_CLUTEND", 1.5639042057291665e+03}, + {"GLCM_CLUPROM", 6.0407190524108699e+06}, + {"GLCM_CLUSHADE", 3.1988865940239932e+04}, + {"GLCM_CLUTEND", 1.5133468428950318e+03}, // == GLCM_SUMVARIANCE: the sum average is mu_x + mu_y {"GLCM_CONTRAST", 1.4448130208333334e+03}, // sym-invariant {"GLCM_CORRELATION", 0.000690135}, {"GLCM_DIFAVE", 23.6493}, // sym-invariant @@ -47,16 +47,16 @@ static const ref_vals_map glcm_2d_regression_ref_vals {"GLCM_IDM", 0.572168}, // sym-invariant {"GLCM_IDMN", 9.0029152005531590e-01}, // Ng-dependent, same story as ACOR {"GLCM_IDN", 8.4432100308124380e-01}, // Ng-dependent, same story as ACOR - {"GLCM_INFOMEAS1", -0.184406}, + {"GLCM_INFOMEAS1", -1.7279222821916787e-01}, {"GLCM_INFOMEAS2", 0.495817}, {"GLCM_IV", 0.000206466}, // sym-invariant {"GLCM_JAVE", 35.5215}, {"GLCM_JE", 1.87602}, {"GLCM_JMAX", 0.527914}, - {"GLCM_JVAR", 828.383}, + {"GLCM_JVAR", 6.7487128442258143e+02}, // == GLCM_VARIANCE: both are IBSI joint variance {"GLCM_SUMAVERAGE", 72.0369}, // absolute-level-dependent, same story as ACOR {"GLCM_SUMENTROPY", 1.61957}, // sym-invariant - {"GLCM_SUMVARIANCE", 1.5639042057291665e+03}, + {"GLCM_SUMVARIANCE", 1.5133468428950318e+03}, {"GLCM_VARIANCE", 674.871} }; // ACOR/IDN/IDMN/SUMAVERAGE are genuinely third-party-vetted on the IBSI path (symmetric matrix, @@ -399,6 +399,11 @@ void test_2d_glcm_idm_ave_regression() assert_glcm_feature_regression(Nyxus::Feature2D::GLCM_IDM_AVE, "GLCM_IDM_AVE"); } +void test_2d_glcm_hom2_ave_regression() +{ + assert_glcm_feature_regression(Nyxus::Feature2D::GLCM_HOM2_AVE, "GLCM_HOM2_AVE"); +} + void test_2d_glcm_idmn_ave_regression() { assert_glcm_feature_regression(Nyxus::Feature2D::GLCM_IDMN_AVE, "GLCM_IDMN_AVE"); diff --git a/tests/test_3d_coverage_common.h b/tests/test_3d_coverage_common.h index aa9cab25..763edeea 100644 --- a/tests/test_3d_coverage_common.h +++ b/tests/test_3d_coverage_common.h @@ -137,12 +137,12 @@ static const std::set& individually_pinned_3d_feature_names() TEST(TEST_NYXUS, TEST_3D_FEATURE_COVERAGE_COUNTS) { - EXPECT_EQ(213u, Nyxus::UserFacing_3D_featureNames.size()); - // 148 of the 213 have an external reference behind them; the 16 NGLDM features and the 16 GLDZM + EXPECT_EQ(214u, Nyxus::UserFacing_3D_featureNames.size()); + // 148 of the 214 have an external reference behind them; the 16 NGLDM features and the 16 GLDZM // features MIRP can discriminate, and the mesh area with its five ratios, are part of that count. - // The remaining 65 carry a named regression pin instead, which is what the loop below enforces. + // The remaining 66 carry a named regression pin instead, which is what the loop below enforces. EXPECT_EQ(148u, feature_3d_cases(true).size()); - EXPECT_EQ(65u, feature_3d_cases(false).size()); + EXPECT_EQ(66u, feature_3d_cases(false).size()); EXPECT_EQ(Nyxus::UserFacing_3D_featureNames.size(), feature_3d_cases(true).size() + feature_3d_cases(false).size()); // SPEC 1: every public feature with no oracle behind it still has to have a named regression pin. diff --git a/tests/test_3d_glcm_analytic.h b/tests/test_3d_glcm_analytic.h new file mode 100644 index 00000000..51380dc2 --- /dev/null +++ b/tests/test_3d_glcm_analytic.h @@ -0,0 +1,254 @@ +#pragma once + +#include + +#include +#include +#include +#include + +#include "../src/nyx/feature_settings.h" // Fsettings, NyxSetting +#include "../src/nyx/featureset.h" // Feature3D +#include "../src/nyx/features/3d_glcm.h" // D3_GLCM_feature +#include "../src/nyx/roi_cache.h" // LR + +// 3D GLCM on an asymmetric co-occurrence matrix against the IBSI definitions evaluated in the test, +// the 3D counterpart of test_2d_glcm_analytic.h, which states the definitions and why MATLAB-style +// binning makes the matrix asymmetric. +// +// The fixture is a 5 x 5 x 3 box, every voxel the ROI's: slice 0 is the 5 x 5 GLCM example image of +// the PyRadiomics documentation, slice 1 its left-right mirror and slice 2 its transpose. Its +// left-right mirror is the second volume. Mirroring turns the matrix of a direction (1, dy, dz) into +// the transpose of the original's matrix of direction (1, -dy, -dz), so the features that do not +// change under a transpose take that direction's value. +// +// Kind: *analytic* per tests/vetting/SPEC.md 4: the reference is the definition evaluated here, on a +// co-occurrence matrix counted from the fixture without Nyxus. + +static const int glcm_3d_asym_side = 5, glcm_3d_asym_depth = 3; +static const unsigned int glcm_3d_asym_slice[glcm_3d_asym_side][glcm_3d_asym_side] = +{ + {1, 2, 5, 2, 3}, + {3, 2, 1, 3, 1}, + {1, 3, 5, 5, 2}, + {1, 1, 1, 1, 2}, + {1, 2, 4, 3, 5} +}; +static const int glcm_3d_asym_levels = 64; // the default coarse grey depth + +// The 13 directions, (dx, dy, dz), in the order 3d_glcm.cpp walks them and stores their values +static const int glcm_3d_asym_shifts[13][3] = +{ + {1, 1, 1}, {1, 1, 0}, {1, 1, -1}, {1, 0, 1}, {1, 0, 0}, {1, 0, -1}, {1, -1, 1}, {1, -1, 0}, {1, -1, -1}, + {0, 1, 1}, {0, 1, 0}, {0, 1, -1}, {0, 0, 1} +}; + +static unsigned int glcm_3d_asym_intensity (int x, int y, int z, bool mirror) +{ + if (mirror) + x = glcm_3d_asym_side - 1 - x; + switch (z) + { + case 0: return glcm_3d_asym_slice[y][x]; + case 1: return glcm_3d_asym_slice[y][glcm_3d_asym_side - 1 - x]; + default: return glcm_3d_asym_slice[x][y]; + } +} + +static std::vector> run_3d_glcm_asym (bool mirror, double softnan) +{ + LR r (1); + r.slide_idx = -1; + r.aabb.init_x (0); r.aabb.update_x (glcm_3d_asym_side - 1); + r.aabb.init_y (0); r.aabb.update_y (glcm_3d_asym_side - 1); + r.aabb.init_z (0); r.aabb.update_z (glcm_3d_asym_depth - 1); + r.aux_min = ~(PixIntens) 0; + r.aux_max = 0; + for (int z = 0; z < glcm_3d_asym_depth; z++) + for (int y = 0; y < glcm_3d_asym_side; y++) + for (int x = 0; x < glcm_3d_asym_side; x++) + { + const PixIntens v = glcm_3d_asym_intensity (x, y, z, mirror); + r.raw_pixels_3D.push_back (Pixel3 (x, y, z, v)); + r.aux_min = (std::min) (r.aux_min, v); + r.aux_max = (std::max) (r.aux_max, v); + } + r.aux_area = (decltype(r.aux_area)) r.raw_pixels_3D.size(); + + Fsettings s; + s.resize ((int)NyxSetting::__COUNT__); + s[(int)NyxSetting::SOFTNAN].rval = softnan; + s[(int)NyxSetting::IBSI].bval = false; + s[(int)NyxSetting::GREYDEPTH].ival = glcm_3d_asym_levels; + s[(int)NyxSetting::GLCM_GREYDEPTH].ival = glcm_3d_asym_levels; + s[(int)NyxSetting::GLCM_OFFSET].ival = 1; + + D3_GLCM_feature::symmetric_glcm = false; + D3_GLCM_feature f; + f.calculate (r, s); + r.initialize_fvals(); + f.save_value (r.fvals); + return r.fvals; +} + +struct Glcm3dIbsiValues +{ + double clutend, clushade, cluprom, sumvariance, jvar, infomeas1; +}; + +// The IBSI values of the fixture in direction (dx, dy, dz): P(i, j), i the MATLAB-style level of the +// voxel and j that of its neighbour, floor(n x / max + 1) clipped to 1..n over the ROI's maximum. +static Glcm3dIbsiValues glcm_3d_ibsi_values (bool mirror, int dx, int dy, int dz) +{ + const int n = glcm_3d_asym_levels, side = glcm_3d_asym_side, depth = glcm_3d_asym_depth; + unsigned int mx = 0; + for (int z = 0; z < depth; z++) + for (int y = 0; y < side; y++) + for (int x = 0; x < side; x++) + mx = std::max (mx, glcm_3d_asym_intensity (x, y, z, mirror)); + auto level = [&](int x, int y, int z) + { + const int l = (int) std::floor (double(n) * glcm_3d_asym_intensity (x, y, z, mirror) / double(mx) + 1.); + return std::min (std::max (l, 1), n); + }; + + std::vector> p (n + 1, std::vector (n + 1, 0.)); + double total = 0; + for (int z = 0; z < depth; z++) + for (int y = 0; y < side; y++) + for (int x = 0; x < side; x++) + { + const int xn = x + dx, yn = y + dy, zn = z + dz; + if (xn < 0 || xn >= side || yn < 0 || yn >= side || zn < 0 || zn >= depth) + continue; + p[level (x, y, z)][level (xn, yn, zn)] += 1; + total += 1; + } + + std::vector px (n + 1, 0.), py (n + 1, 0.), pxpy (2 * n + 1, 0.); + double mux = 0, muy = 0; + for (int i = 1; i <= n; i++) + for (int j = 1; j <= n; j++) + { + p[i][j] /= total; + px[i] += p[i][j]; + py[j] += p[i][j]; + pxpy[i + j] += p[i][j]; + mux += i * p[i][j]; + muy += j * p[i][j]; + } + + Glcm3dIbsiValues v {}; + double hxy = 0, hxy1 = 0, hx = 0, hy = 0; + for (int i = 1; i <= n; i++) + for (int j = 1; j <= n; j++) + { + const double m = i + j - mux - muy; + v.clutend += m * m * p[i][j]; + v.clushade += m * m * m * p[i][j]; + v.cluprom += m * m * m * m * p[i][j]; + v.jvar += (i - mux) * (i - mux) * p[i][j]; + if (p[i][j] > 0) + { + hxy -= p[i][j] * std::log2 (p[i][j]); + hxy1 -= p[i][j] * std::log2 (px[i] * py[j]); + } + } + for (int i = 1; i <= n; i++) + { + if (px[i] > 0) + hx -= px[i] * std::log2 (px[i]); + if (py[i] > 0) + hy -= py[i] * std::log2 (py[i]); + } + v.infomeas1 = (hxy - hxy1) / std::max (hx, hy); + + double sa = 0; + for (int k = 2; k <= 2 * n; k++) + sa += k * pxpy[k]; + for (int k = 2; k <= 2 * n; k++) + v.sumvariance += (k - sa) * (k - sa) * pxpy[k]; + + return v; +} + +static void assert_3d_glcm_near (double actual, double expected, double rel, const std::string& what) +{ + EXPECT_NEAR (actual, expected, std::abs (expected) * rel) << what; +} + +static std::string glcm_3d_asym_where (bool mirror, int k) +{ + return std::string (mirror ? "mirror" : "fixture") + " direction (" + std::to_string (glcm_3d_asym_shifts[k][0]) + "," + + std::to_string (glcm_3d_asym_shifts[k][1]) + "," + std::to_string (glcm_3d_asym_shifts[k][2]) + ")"; +} + +// Cluster tendency, shade and prominence centre i + j on mu_x + mu_y, and sum variance is the variance +// of p_{x+y}, in all 13 directions of the fixture and of its mirror. +void test_3d_glcm_cluster_and_sum_variance_asymmetric_analytic() +{ + using F = Nyxus::Feature3D; + for (bool mirror : {false, true}) + { + const auto fv = run_3d_glcm_asym (mirror, 0.); + ASSERT_EQ (fv[(int)F::GLCM_CLUSHADE].size(), 13u); + for (int k = 0; k < 13; k++) + { + const auto ref = glcm_3d_ibsi_values (mirror, glcm_3d_asym_shifts[k][0], glcm_3d_asym_shifts[k][1], glcm_3d_asym_shifts[k][2]); + const std::string at = glcm_3d_asym_where (mirror, k); + assert_3d_glcm_near (fv[(int)F::GLCM_CLUTEND][k], ref.clutend, 1e-9, "3GLCM_CLUTEND " + at); + assert_3d_glcm_near (fv[(int)F::GLCM_CLUSHADE][k], ref.clushade, 1e-9, "3GLCM_CLUSHADE " + at); + assert_3d_glcm_near (fv[(int)F::GLCM_CLUPROM][k], ref.cluprom, 1e-9, "3GLCM_CLUPROM " + at); + assert_3d_glcm_near (fv[(int)F::GLCM_SUMVARIANCE][k], ref.sumvariance, 1e-9, "3GLCM_SUMVARIANCE " + at); + } + } +} + +// Joint variance is sum (i - mu_x)^2 p_ij in every direction, the value 3GLCM_VARIANCE reports. +void test_3d_glcm_jvar_asymmetric_analytic() +{ + using F = Nyxus::Feature3D; + for (bool mirror : {false, true}) + { + const auto fv = run_3d_glcm_asym (mirror, 0.); + ASSERT_EQ (fv[(int)F::GLCM_JVAR].size(), 13u); + for (int k = 0; k < 13; k++) + { + const auto ref = glcm_3d_ibsi_values (mirror, glcm_3d_asym_shifts[k][0], glcm_3d_asym_shifts[k][1], glcm_3d_asym_shifts[k][2]); + const std::string at = glcm_3d_asym_where (mirror, k); + assert_3d_glcm_near (fv[(int)F::GLCM_VARIANCE][k], ref.jvar, 1e-9, "3GLCM_VARIANCE " + at); + assert_3d_glcm_near (fv[(int)F::GLCM_JVAR][k], ref.jvar, 1e-9, "3GLCM_JVAR " + at); + } + } +} + +// Information correlation 1 divides by max(HX, HY). The fast_log10 entropies (helpers.h) put up to +// 1.4e-2 relative on this quotient in one of the 26 directions here, and the band is 2e-2, below the +// 4.2 % a divisor taken from one fixed marginal is off in the mirror's direction (1, 0, 1). The +// orientation check pairs each direction (1, dy, dz) of the mirror with (1, -dy, -dz) of the fixture +// and needs only rounding. +void test_3d_glcm_infomeas1_asymmetric_analytic() +{ + const int code = (int)Nyxus::Feature3D::GLCM_INFOMEAS1; + const auto fixture = run_3d_glcm_asym (false, 0.), + mirror = run_3d_glcm_asym (true, 0.); + ASSERT_EQ (fixture[code].size(), 13u); + for (bool m : {false, true}) + for (int k = 0; k < 13; k++) + { + const auto ref = glcm_3d_ibsi_values (m, glcm_3d_asym_shifts[k][0], glcm_3d_asym_shifts[k][1], glcm_3d_asym_shifts[k][2]); + assert_3d_glcm_near ((m ? mirror : fixture)[code][k], ref.infomeas1, 2e-2, "3GLCM_INFOMEAS1 " + glcm_3d_asym_where (m, k)); + } + + for (int k = 0; k < 13; k++) + { + if (glcm_3d_asym_shifts[k][0] != 1) + continue; + int t = -1; + for (int q = 0; q < 13; q++) + if (glcm_3d_asym_shifts[q][0] == 1 && glcm_3d_asym_shifts[q][1] == -glcm_3d_asym_shifts[k][1] && glcm_3d_asym_shifts[q][2] == -glcm_3d_asym_shifts[k][2]) + t = q; + ASSERT_GE (t, 0); + assert_3d_glcm_near (mirror[code][k], fixture[code][t], 1e-12, "3GLCM_INFOMEAS1 mirror " + glcm_3d_asym_where (true, k) + " vs fixture " + glcm_3d_asym_where (false, t)); + } +} diff --git a/tests/test_3d_glcm_mechanics.h b/tests/test_3d_glcm_mechanics.h new file mode 100644 index 00000000..b5f39282 --- /dev/null +++ b/tests/test_3d_glcm_mechanics.h @@ -0,0 +1,48 @@ +#pragma once + +#include + +#include "../src/nyx/feature_settings.h" // Fsettings, NyxSetting +#include "../src/nyx/featureset.h" // Feature3D +#include "../src/nyx/features/3d_glcm.h" // D3_GLCM_feature +#include "../src/nyx/roi_cache.h" // LR + +// Information correlation 1 is undefined where both marginals of a direction hold one grey level +// (HX = HY = 0), and reports the soft-NaN substitute there rather than NaN. The ROI is two voxels of +// level 7 side by side in x and one voxel of level 3 two slices away, so the direction (1, 0, 0), +// the fifth of the 13, pairs only 7 with 7 while the ROI itself has two levels. The substitute is -999 +// so that it cannot be mistaken for a computed value. +void test_3d_glcm_infomeas1_single_level_reports_noval_mechanics() +{ + LR r (1); + r.slide_idx = -1; + r.aabb.init_x (0); r.aabb.update_x (1); + r.aabb.init_y (0); r.aabb.update_y (0); + r.aabb.init_z (0); r.aabb.update_z (2); + r.raw_pixels_3D.push_back (Pixel3 (0, 0, 0, 7)); + r.raw_pixels_3D.push_back (Pixel3 (1, 0, 0, 7)); + r.raw_pixels_3D.push_back (Pixel3 (0, 0, 2, 3)); + r.aux_min = 3; + r.aux_max = 7; + r.aux_area = 3; + + const double noval = -999.; + Fsettings s; + s.resize ((int)NyxSetting::__COUNT__); + s[(int)NyxSetting::SOFTNAN].rval = noval; + s[(int)NyxSetting::IBSI].bval = false; + s[(int)NyxSetting::GREYDEPTH].ival = 64; + s[(int)NyxSetting::GLCM_GREYDEPTH].ival = 64; + s[(int)NyxSetting::GLCM_OFFSET].ival = 1; + + D3_GLCM_feature::symmetric_glcm = false; + D3_GLCM_feature f; + f.calculate (r, s); + r.initialize_fvals(); + f.save_value (r.fvals); + + // the direction has pairs, so the value comes from the quotient's own guard + const int x_dir = 4; + ASSERT_GT (r.fvals[(int)Nyxus::Feature3D::GLCM_ASM][x_dir], 0.); + ASSERT_EQ (r.fvals[(int)Nyxus::Feature3D::GLCM_INFOMEAS1][x_dir], noval); +} diff --git a/tests/test_3d_glcm_pyradiomics.h b/tests/test_3d_glcm_pyradiomics.h index bf1ccf6c..de28d446 100644 --- a/tests/test_3d_glcm_pyradiomics.h +++ b/tests/test_3d_glcm_pyradiomics.h @@ -913,6 +913,12 @@ void test_3d_glcm_idm_ave_pyradiomics() assert_3d_glcm_ave_feature_pyradiomics (Nyxus::Feature3D::GLCM_IDM_AVE, "3GLCM_IDM"); } +// Homogeneity 2 is PyRadiomics' Idm, so its direction average has Idm's golden +void test_3d_glcm_hom2_ave_pyradiomics() +{ + assert_3d_glcm_ave_feature_pyradiomics (Nyxus::Feature3D::GLCM_HOM2_AVE, "3GLCM_IDM"); +} + void test_3d_glcm_idmn_ave_pyradiomics() { assert_3d_glcm_ave_feature_pyradiomics (Nyxus::Feature3D::GLCM_IDMN_AVE, "3GLCM_IDMN"); @@ -969,7 +975,7 @@ void test_3d_glcm_sumentropy_ave_pyradiomics() } -// The six *_AVE features PyRadiomics does not report under their own name. Each is numerically +// The seven *_AVE features PyRadiomics does not report under their own name. Each is numerically // identical to a twin that does, and the identity is not an assumption: it is asserted at 1e-6 on // the per-angle values by test_3d_glcm_equivalence_dump_pyradiomics(). This pins the same identity // on the stored *_AVE features, so the twin's PyRadiomics golden carries both. @@ -1019,6 +1025,7 @@ void test_3d_glcm_ave_equivalence_pyradiomics() { F::GLCM_ENERGY_AVE, F::GLCM_ASM_AVE, "3GLCM_ENERGY_AVE", "3GLCM_ASM_AVE", "3GLCM_ASM" }, { F::GLCM_ENTROPY_AVE, F::GLCM_JE_AVE, "3GLCM_ENTROPY_AVE", "3GLCM_JE_AVE", "3GLCM_JE" }, { F::GLCM_HOM1_AVE, F::GLCM_ID_AVE, "3GLCM_HOM1_AVE", "3GLCM_ID_AVE", "3GLCM_ID" }, + { F::GLCM_HOM2_AVE, F::GLCM_IDM_AVE, "3GLCM_HOM2_AVE", "3GLCM_IDM_AVE", "3GLCM_IDM" }, { F::GLCM_SUMVARIANCE_AVE, F::GLCM_CLUTEND_AVE, "3GLCM_SUMVARIANCE_AVE", "3GLCM_CLUTEND_AVE", "3GLCM_CLUTEND" }, { F::GLCM_VARIANCE_AVE, F::GLCM_JVAR_AVE, "3GLCM_VARIANCE_AVE", "3GLCM_JVAR_AVE", "3GLCM_JVAR" } }; diff --git a/tests/test_3d_glcm_regression.h b/tests/test_3d_glcm_regression.h index 2a5e3999..2db85989 100644 --- a/tests/test_3d_glcm_regression.h +++ b/tests/test_3d_glcm_regression.h @@ -356,6 +356,7 @@ static const ref_vals_map> glcm_3d_regression_grey64_ref_val { "3GLCM_ENTROPY_AVE", { 9.0190088166756421 } }, { "3GLCM_HOM1", { 0.36892514882970728, 0.45044986312487578, 0.36892514882970728, 0.41424874300616815, 0.49224180198970136, 0.41424874300616815, 0.36892514882970728, 0.45044986312487578, 0.36892514882970728, 0.39005648807915821, 0.45950108578725052, 0.39005648807915821, 0.58069852668437139 } }, { "3GLCM_HOM1_AVE", { 0.42443478447696592 } }, + { "3GLCM_HOM2_AVE", { 0.35139004587558276 } }, { "3GLCM_HOM2", { 0.28872829324757127, 0.38383297610972528, 0.28872829324757127, 0.33348704011686431, 0.42513980234144694, 0.33348704011686431, 0.28872829324757127, 0.38383297610972528, 0.28872829324757127, 0.30925413808751828, 0.39117578581244239, 0.30925413808751828, 0.54369352661018644 } }, { "3GLCM_ID_AVE", { 0.42443478447696553 } }, { "3GLCM_IDM_AVE", { 0.35139004587558276 } }, @@ -436,6 +437,7 @@ void test_3d_glcm_entropy_ave_grey64_regression() { assert_3d_glcm_feature_grey6 void test_3d_glcm_hom1_grey64_regression() { assert_3d_glcm_feature_grey64_regression(Nyxus::Feature3D::GLCM_HOM1, "3GLCM_HOM1"); } void test_3d_glcm_hom1_ave_grey64_regression() { assert_3d_glcm_feature_grey64_regression(Nyxus::Feature3D::GLCM_HOM1_AVE, "3GLCM_HOM1_AVE"); } void test_3d_glcm_hom2_grey64_regression() { assert_3d_glcm_feature_grey64_regression(Nyxus::Feature3D::GLCM_HOM2, "3GLCM_HOM2"); } +void test_3d_glcm_hom2_ave_grey64_regression() { assert_3d_glcm_feature_grey64_regression(Nyxus::Feature3D::GLCM_HOM2_AVE, "3GLCM_HOM2_AVE"); } void test_3d_glcm_idmn_ave_grey64_regression() { assert_3d_glcm_feature_grey64_regression(Nyxus::Feature3D::GLCM_IDMN_AVE, "3GLCM_IDMN_AVE"); } void test_3d_glcm_idm_ave_grey64_regression() { assert_3d_glcm_feature_grey64_regression(Nyxus::Feature3D::GLCM_IDM_AVE, "3GLCM_IDM_AVE"); } void test_3d_glcm_idn_ave_grey64_regression() { assert_3d_glcm_feature_grey64_regression(Nyxus::Feature3D::GLCM_IDN_AVE, "3GLCM_IDN_AVE"); } diff --git a/tests/test_all.cc b/tests/test_all.cc index 4f9f4b37..516dfba9 100644 --- a/tests/test_all.cc +++ b/tests/test_all.cc @@ -154,6 +154,9 @@ #include "test_3d_glszm_analytic.h" #include "test_3d_coverage_common.h" #include "test_2d_glcm_mechanics.h" +#include "test_2d_glcm_analytic.h" +#include "test_3d_glcm_analytic.h" +#include "test_3d_glcm_mechanics.h" #ifdef USE_ARROW #include "test_arrow_mechanics.h" #include "test_arrow_file_name_mechanics.h" @@ -3024,6 +3027,11 @@ TEST(TEST_NYXUS, TEST_2D_GLCM_IDM_AVE_IBSI) ASSERT_NO_THROW(test_2d_glcm_idm_ave_ibsi()); } +TEST(TEST_NYXUS, TEST_2D_GLCM_HOM2_AVE_IBSI) +{ + ASSERT_NO_THROW(test_2d_glcm_hom2_ave_ibsi()); +} + TEST(TEST_NYXUS, TEST_2D_GLCM_INFOMEAS1_AVE_IBSI) { ASSERT_NO_THROW(test_2d_glcm_infomeas1_ave_ibsi()); @@ -3328,6 +3336,11 @@ TEST(TEST_NYXUS, TEST_2D_GLCM_IDM_AVE_REGRESSION) ASSERT_NO_THROW(test_2d_glcm_idm_ave_regression()); } +TEST(TEST_NYXUS, TEST_2D_GLCM_HOM2_AVE_REGRESSION) +{ + ASSERT_NO_THROW(test_2d_glcm_hom2_ave_regression()); +} + TEST(TEST_NYXUS, TEST_2D_GLCM_IDMN_AVE_REGRESSION) { ASSERT_NO_THROW(test_2d_glcm_idmn_ave_regression()); @@ -3410,6 +3423,63 @@ TEST(TEST_NYXUS, TEST_2D_GLCM_OWN_GREYDEPTH_BINS_THE_MATRIX_MECHANICS) ASSERT_NO_THROW(test_2d_glcm_own_greydepth_bins_the_matrix_mechanics()); } +TEST(TEST_NYXUS, TEST_2D_GLCM_CONSTANT_ROI_REPORTS_NOVAL_MECHANICS) +{ + ASSERT_NO_THROW(test_2d_glcm_constant_roi_reports_noval_mechanics()); +} + +TEST(TEST_NYXUS, TEST_2D_GLCM_TWO_LEVEL_ROI_COMPUTES_MECHANICS) +{ + ASSERT_NO_THROW(test_2d_glcm_two_level_roi_computes_mechanics()); +} + +TEST(TEST_NYXUS, TEST_2D_GLCM_HOM2_AVE_MECHANICS) +{ + ASSERT_NO_THROW(test_2d_glcm_hom2_ave_mechanics()); +} + +TEST(TEST_NYXUS, TEST_2D_GLCM_INFOMEAS1_SINGLE_LEVEL_REPORTS_NOVAL_MECHANICS) +{ + ASSERT_NO_THROW(test_2d_glcm_infomeas1_single_level_reports_noval_mechanics()); +} + +//***** 2D and 3D GLCM on an asymmetric co-occurrence matrix vs the IBSI definitions ***** + +TEST(TEST_NYXUS, TEST_2D_GLCM_CLUSTER_AND_SUM_VARIANCE_ASYMMETRIC_ANALYTIC) +{ + ASSERT_NO_THROW(test_2d_glcm_cluster_and_sum_variance_asymmetric_analytic()); +} + +TEST(TEST_NYXUS, TEST_2D_GLCM_JVAR_ASYMMETRIC_ANALYTIC) +{ + ASSERT_NO_THROW(test_2d_glcm_jvar_asymmetric_analytic()); +} + +TEST(TEST_NYXUS, TEST_2D_GLCM_INFOMEAS1_ASYMMETRIC_ANALYTIC) +{ + ASSERT_NO_THROW(test_2d_glcm_infomeas1_asymmetric_analytic()); +} + +TEST(TEST_NYXUS, TEST_3D_GLCM_CLUSTER_AND_SUM_VARIANCE_ASYMMETRIC_ANALYTIC) +{ + ASSERT_NO_THROW(test_3d_glcm_cluster_and_sum_variance_asymmetric_analytic()); +} + +TEST(TEST_NYXUS, TEST_3D_GLCM_JVAR_ASYMMETRIC_ANALYTIC) +{ + ASSERT_NO_THROW(test_3d_glcm_jvar_asymmetric_analytic()); +} + +TEST(TEST_NYXUS, TEST_3D_GLCM_INFOMEAS1_ASYMMETRIC_ANALYTIC) +{ + ASSERT_NO_THROW(test_3d_glcm_infomeas1_asymmetric_analytic()); +} + +TEST(TEST_NYXUS, TEST_3D_GLCM_INFOMEAS1_SINGLE_LEVEL_REPORTS_NOVAL_MECHANICS) +{ + ASSERT_NO_THROW(test_3d_glcm_infomeas1_single_level_reports_noval_mechanics()); +} + //***** PyRadiomics tests of 2D GLDM ***** TEST(TEST_NYXUS, TEST_2D_GLDM_SDE_PYRADIOMICS) @@ -6686,6 +6756,7 @@ TEST(TEST_NYXUS, TEST_3D_GLCM_ENTROPY_AVE_GREY64_REGRESSION) { ASSERT_NO_THROW(t TEST(TEST_NYXUS, TEST_3D_GLCM_HOM1_GREY64_REGRESSION) { ASSERT_NO_THROW(test_3d_glcm_hom1_grey64_regression()); } TEST(TEST_NYXUS, TEST_3D_GLCM_HOM1_AVE_GREY64_REGRESSION) { ASSERT_NO_THROW(test_3d_glcm_hom1_ave_grey64_regression()); } TEST(TEST_NYXUS, TEST_3D_GLCM_HOM2_GREY64_REGRESSION) { ASSERT_NO_THROW(test_3d_glcm_hom2_grey64_regression()); } +TEST(TEST_NYXUS, TEST_3D_GLCM_HOM2_AVE_GREY64_REGRESSION) { ASSERT_NO_THROW(test_3d_glcm_hom2_ave_grey64_regression()); } TEST(TEST_NYXUS, TEST_3D_GLCM_IDMN_AVE_GREY64_REGRESSION) { ASSERT_NO_THROW(test_3d_glcm_idmn_ave_grey64_regression()); } TEST(TEST_NYXUS, TEST_3D_GLCM_IDM_AVE_GREY64_REGRESSION) { ASSERT_NO_THROW(test_3d_glcm_idm_ave_grey64_regression()); } TEST(TEST_NYXUS, TEST_3D_GLCM_IDN_AVE_GREY64_REGRESSION) { ASSERT_NO_THROW(test_3d_glcm_idn_ave_grey64_regression()); } @@ -6717,6 +6788,7 @@ TEST(TEST_NYXUS, TEST_3D_GLCM_DIFENTRO_AVE_PYRADIOMICS) { ASSERT_NO_THROW(test_3 TEST(TEST_NYXUS, TEST_3D_GLCM_DIFVAR_AVE_PYRADIOMICS) { ASSERT_NO_THROW(test_3d_glcm_difvar_ave_pyradiomics()); } TEST(TEST_NYXUS, TEST_3D_GLCM_ID_AVE_PYRADIOMICS) { ASSERT_NO_THROW(test_3d_glcm_id_ave_pyradiomics()); } TEST(TEST_NYXUS, TEST_3D_GLCM_IDM_AVE_PYRADIOMICS) { ASSERT_NO_THROW(test_3d_glcm_idm_ave_pyradiomics()); } +TEST(TEST_NYXUS, TEST_3D_GLCM_HOM2_AVE_PYRADIOMICS) { ASSERT_NO_THROW(test_3d_glcm_hom2_ave_pyradiomics()); } TEST(TEST_NYXUS, TEST_3D_GLCM_IDMN_AVE_PYRADIOMICS) { ASSERT_NO_THROW(test_3d_glcm_idmn_ave_pyradiomics()); } TEST(TEST_NYXUS, TEST_3D_GLCM_IDN_AVE_PYRADIOMICS) { ASSERT_NO_THROW(test_3d_glcm_idn_ave_pyradiomics()); } TEST(TEST_NYXUS, TEST_3D_GLCM_INFOMEAS1_AVE_PYRADIOMICS) { ASSERT_NO_THROW(test_3d_glcm_infomeas1_ave_pyradiomics()); } diff --git a/tests/vetting/audit/glcm_2d_golden_regen.md b/tests/vetting/audit/glcm_2d_golden_regen.md index aab7ac3a..00f7b2df 100644 --- a/tests/vetting/audit/glcm_2d_golden_regen.md +++ b/tests/vetting/audit/glcm_2d_golden_regen.md @@ -71,7 +71,7 @@ One tool quantity can cover several Nyxus names. The mapping lives in the genera |---|---|---|---| | `GLCM_ASM`, `GLCM_ENERGY` | `JointEnergy` | `cm_energy` | the two Nyxus names are one quantity | | `GLCM_ID`, `GLCM_HOM1` | `Id` | `cm_inv_diff` | | -| `GLCM_IDM`, `GLCM_HOM2` | `Idm` | `cm_inv_diff_mom` | `GLCM_HOM2` has no `_AVE` twin | +| `GLCM_IDM`, `GLCM_HOM2` | `Idm` | `cm_inv_diff_mom` | | | `GLCM_JE`, `GLCM_ENTROPY` | `JointEntropy` | `cm_joint_entr` | | | `GLCM_JVAR`, `GLCM_VARIANCE` | `SumSquares` | `cm_joint_var` | IBSI joint variance UR99 | | `GLCM_CLUTEND`, `GLCM_SUMVARIANCE` | `ClusterTendency` | `cm_clust_tend`, `cm_sum_var` | PyRadiomics dropped SumVariance as a duplicate; MIRP reports both | @@ -86,8 +86,8 @@ One tool quantity can cover several Nyxus names. The mapping lives in the genera - **Log-based features** - `DIFENTRO`, `JE`/`ENTROPY`, `SUMENTROPY`, `INFOMEAS1`, `INFOMEAS2` land 1e-3..3e-3 off both tools because Nyxus sums through `fast_log10` with an `EPSILON` guard. Assert those at `rel=5e-3`; everything else holds at `rel=1e-9`. -- **`GLCM_VARIANCE` vs `GLCM_JVAR`** - different routines in Nyxus (marginal mean vs level index) - reaching the same quantity. If a future change makes them differ, the fixture will show it: both +- **`GLCM_VARIANCE` vs `GLCM_JVAR`** - different routines in Nyxus (`GLCM_VARIANCE` takes its own + mean of the reference level, `GLCM_JVAR` reuses `GLCM_JAVE`) reaching the same quantity. If a future change makes them differ, the fixture will show it: both are pinned to the same tool value. - **Grey-level gaps** - at identity binning both tools build the matrix over the image's own levels, so a fixture with absent levels is fine; verified on the IBSI phantom (levels {1,3,4,6}), where diff --git a/tests/vetting/audit/glcm_2d_pyradiomics_vetting_report.md b/tests/vetting/audit/glcm_2d_pyradiomics_vetting_report.md index 595622da..efb41d46 100644 --- a/tests/vetting/audit/glcm_2d_pyradiomics_vetting_report.md +++ b/tests/vetting/audit/glcm_2d_pyradiomics_vetting_report.md @@ -135,14 +135,18 @@ oracle tests use. Under the asymmetric config the keys split in two: - **Symmetrisation-invariant** - they depend only on the grey-level difference `p_{x-y}` / `|i-j|` (`CONTRAST`, `DIFAVE`, `DIS`, `DIFENTRO`, `DIFVAR`, `ID`, `HOM1`, `IDM`, `IV`) or on the sum - distribution `p_{x+y}` (`SUMENTROPY`). These land within 1% of PyRadiomics run on the same - per-slice MATLAB-binned images, because this phantom's binning relabels levels without rescaling - them. They are *not* invariant to level scaling - that only holds here. -- **Transpose-sensitive** - they read individual matrix entries or the grey-tone marginal means - `mu_x`/`mu_y`, and diverge from any symmetric-matrix tool as configured. Measured: - `ASM`/`ENERGY` 3.7%, `CLUSHADE` 46%, `CLUTEND`/`SUMVARIANCE` 3.2%, `JE` 9.3%, - `JVAR`/`VARIANCE` ~10%. `CLUTEND`/`SUMVARIANCE` are in this group because Nyxus computes them - from the single row-marginal mean `by_row_mean`. + distribution `p_{x+y}` (`SUMENTROPY`, and `CLUPROM`, `CLUSHADE`, `CLUTEND`/`SUMVARIANCE`, which + centre `i + j` on `mu_x + mu_y`, the mean of `p_{x+y}`). The difference features and `SUMENTROPY` + land within 1% of PyRadiomics run on the same per-slice MATLAB-binned images, because this + phantom's binning relabels levels without rescaling them. They are *not* invariant to level + scaling - that only holds here. +- **Transpose-sensitive** - they read individual matrix entries or one marginal, and diverge from + any symmetric-matrix tool as configured. Measured: `ASM`/`ENERGY` 3.7%, `JE` 9.3%, + `JVAR`/`VARIANCE` ~10%. `INFOMEAS1` divides by the larger marginal entropy and is in this group + too. +- The asymmetric configuration has its own vetting for `CLUPROM`, `CLUSHADE`, `CLUTEND`, + `SUMVARIANCE`, `JVAR`, `VARIANCE` and `INFOMEAS1`: `test_2d_glcm_analytic.h` evaluates their IBSI + definitions on the asymmetric matrix itself (recipe `glcm.analytic_default_asymmetric`). So the snapshot is a drift guard and nothing more; comparing it to a tool would require rerunning it with `symmetric_glcm=true`, at which point it is the oracle tests' recipe. diff --git a/tests/vetting/audit/scan_glcm3d_coverage.py b/tests/vetting/audit/scan_glcm3d_coverage.py index a7b289a4..0139f570 100644 --- a/tests/vetting/audit/scan_glcm3d_coverage.py +++ b/tests/vetting/audit/scan_glcm3d_coverage.py @@ -19,6 +19,8 @@ SOURCES = [ "test_3d_glcm_pyradiomics.h", "test_3d_glcm_regression.h", + "test_3d_glcm_analytic.h", + "test_3d_glcm_mechanics.h", os.path.join("python", "test_nyxus.py"), VOLMIN_TEST, ANALYTIC_TEST, diff --git a/tests/vetting/audit/scan_glcm_coverage.py b/tests/vetting/audit/scan_glcm_coverage.py index 1883160e..10d4f120 100644 --- a/tests/vetting/audit/scan_glcm_coverage.py +++ b/tests/vetting/audit/scan_glcm_coverage.py @@ -18,6 +18,7 @@ "test_2d_glcm_pyradiomics.h", "test_2d_glcm_regression.h", "test_2d_glcm_mechanics.h", + "test_2d_glcm_analytic.h", os.path.join("python", "test_2d_glcm_pyradiomics.py"), ] @@ -28,8 +29,7 @@ "GLCM_ENERGY": "same quantity as GLCM_ASM (PyRadiomics JointEnergy / MIRP cm_energy)", "GLCM_ENTROPY": "same quantity as GLCM_JE (joint entropy)", "GLCM_HOM1": "same quantity as GLCM_ID (PyRadiomics Id / MIRP cm_inv_diff)", - "GLCM_HOM2": "same quantity as GLCM_IDM (PyRadiomics Idm / MIRP cm_inv_diff_mom); no _AVE twin " - "exists", + "GLCM_HOM2": "same quantity as GLCM_IDM (PyRadiomics Idm / MIRP cm_inv_diff_mom)", "GLCM_SUMVARIANCE": "equals GLCM_CLUTEND; PyRadiomics dropped SumVariance as that duplicate, " "MIRP reports it natively", "GLCM_VARIANCE": "same quantity as GLCM_JVAR (PyRadiomics SumSquares = joint variance)", @@ -55,7 +55,8 @@ def note(feature, cov): FAMILY = scanlib.Family( dim="2D", family="glcm", sources=SOURCES, - oracle_suffix={"ibsi": "ibsi", "mirp": "mirp", "pyradiomics": "pyradiomics"}, + oracle_suffix={"ibsi": "ibsi", "mirp": "mirp", "pyradiomics": "pyradiomics", + "analytic": "analytic"}, notes=note, # test_2d_glcm_acor_family_pyradiomics loops a dict of goldens rather than naming each feature py_loop_tables=True, diff --git a/tests/vetting/benchmarks.md b/tests/vetting/benchmarks.md index 7f1ab03f..f7756746 100644 --- a/tests/vetting/benchmarks.md +++ b/tests/vetting/benchmarks.md @@ -723,3 +723,28 @@ Tests reaching it today: `test_2d_contour_invariant.h` **It is a literal table rather than a closed form** because nothing about it is regular: it is the mask the defect was first measured on, kept as found. + +--- + +## `bench_square5_glcm_example` — the 5 x 5 GLCM example image of the PyRadiomics documentation + +| | | +|---|---| +| Fixture | `glcm_2d_asym_image` in `tests/test_2d_glcm_analytic.h`, inside a one-pixel background frame, and its left-right mirror | +| ROI | the whole 5 x 5 square, intensities 1..5 | +| Why it exists | at the default MATLAB-style binning every angle's co-occurrence matrix is asymmetric, so the features that read the two marginals separately are told apart from a definition that mixes them; the mirror turns the 0-degree matrix into its transpose | + +Recipes: `glcm.analytic_default_asymmetric`. Tests: `test_2d_glcm_analytic.h`. The same image is the +worked example of the 2D GLCM documentation page. + +--- + +## `bench_box5x5x3_glcm_asymmetric` — three transformed copies of `bench_square5_glcm_example` + +| | | +|---|---| +| Fixture | built in `tests/test_3d_glcm_analytic.h`: slice 0 the 5 x 5 example image, slice 1 its left-right mirror, slice 2 its transpose; and the x-mirror of the whole box | +| ROI | every voxel of the 5 x 5 x 3 box | +| Why it exists | asymmetric matrices in all 13 directions at the default binning; the x-mirror pairs direction (1, dy, dz) with the transpose of (1, -dy, -dz) | + +Recipes: `glcm3d.analytic_default_asymmetric`. Tests: `test_3d_glcm_analytic.h`. diff --git a/tests/vetting/config_recipes.md b/tests/vetting/config_recipes.md index 8c582b8b..92256905 100644 --- a/tests/vetting/config_recipes.md +++ b/tests/vetting/config_recipes.md @@ -15,6 +15,20 @@ chosen reference tool (SPEC 5). Oracle tests reference a recipe by id; this file phantom (`test_2d_glcm_ibsi.h`, in-mask levels {1,3,4,6}) and a dense 8x8 phantom where every level 1..8 and every level pair occurs (`test_2d_glcm_common.h`). +## glcm.analytic_default_asymmetric +- `bench_square5_glcm_example` and its left-right mirror, built in `test_2d_glcm_analytic.h`, at the + default settings: `ibsi=False`, `GLCM_GREYDEPTH=64` (MATLAB-style binning, `floor(64 x / max + 1)` + clipped to `1..64` over the ROI's maximum), `symmetric_glcm=false`, offset 1, angles + `{0, 45, 90, 135}`. Each ordered pair is counted once, so the matrix is asymmetric. +- Oracle: `analytic`, the IBSI definitions evaluated in the test, per angle, on the co-occurrence + matrix it counts from the fixture itself. PyRadiomics with `symmetricalGLCM=False`, `binWidth=1` on + the binned levels (a constant shift, which none of these features sees) agrees with that reference + to 2e-15 on both orientations. +- Used by `test_2d_glcm_cluster_and_sum_variance_asymmetric_analytic`, + `test_2d_glcm_jvar_asymmetric_analytic` and `test_2d_glcm_infomeas1_asymmetric_analytic`: + cluster tendency, shade and prominence, sum variance, joint variance and variance at `rel=1e-9`; + information correlation 1 at `rel=1.5e-2`, the fast_log10 entropies putting up to 7.0e-3 on it. + ## glcm.pyradiomics_symmetric - `ibsi=False`, fixed bin count, symmetric GLCM averaged over directions, distance 1. - Oracle: `pyradiomics` (symmetricalGLCM=True, binCount matched). Used by: `test_2d_glcm_pyradiomics.h`. @@ -698,6 +712,17 @@ oracle for the Nyxus-original features); it is not built in this tree, and the g `ENTROPY≡JE`, `HOM1≡ID`, `SUMVARIANCE≡CLUTEND`, `VARIANCE≡JVAR`. The identities are asserted at 1e-6, and the twin carries the oracle claim. +## glcm3d.analytic_default_asymmetric +- `bench_box5x5x3_glcm_asymmetric` and its x-mirror, built in `test_3d_glcm_analytic.h`, at the + default binning of `glcm.analytic_default_asymmetric` (`GLCM_GREYDEPTH=64`, MATLAB-style), offset 1, + all 13 directions, each checked on its own. +- Oracle: `analytic`, the IBSI definitions evaluated in the test on the matrix it counts from the + fixture. PyRadiomics with `symmetricalGLCM=False` over its 13 directions agrees with the reference's + 13-direction mean to 3e-15 for cluster tendency, shade, prominence and `Imc1`. Used by + `test_3d_glcm_cluster_and_sum_variance_asymmetric_analytic`, + `test_3d_glcm_jvar_asymmetric_analytic` and `test_3d_glcm_infomeas1_asymmetric_analytic` at + `rel=1e-9`, and information correlation 1 at `rel=2e-2` (fast_log10 puts up to 1.4e-2 on it). + ## glcm3d.regression_ut_phantom - The segmented phantom (`phantoms/ut_inten.nii` + `phantoms/ut_mask57.nii`, label 57) at `GREYDEPTH=100`, `IBSI=false`, `GLCM_GREYDEPTH=-100` (binCount 100), `GLCM_OFFSET=1`, diff --git a/tests/vetting/coverage_report.md b/tests/vetting/coverage_report.md index f41c88a7..4790fb1e 100644 --- a/tests/vetting/coverage_report.md +++ b/tests/vetting/coverage_report.md @@ -2,14 +2,14 @@ _Generated by check_coverage.py from oracle_coverage.csv. Do not edit by hand._ -Features vetted by >=1 oracle: 646/758 (85%) +Features vetted by >=1 oracle: 648/760 (85%) regression: 112 invariant: 0 untested: 0 | family | total | vetted | regression | invariant | untested | |---|---|---|---|---|---| | firstorder | 72 | 67 | 5 | 0 | 0 | | gabor | 1 | 1 | 0 | 0 | 0 | -| glcm | 118 | 118 | 0 | 0 | 0 | +| glcm | 120 | 120 | 0 | 0 | 0 | | gldm | 28 | 28 | 0 | 0 | 0 | | gldzm | 36 | 32 | 4 | 0 | 0 | | glrlm | 64 | 64 | 0 | 0 | 0 | diff --git a/tests/vetting/matrix/glcm.md b/tests/vetting/matrix/glcm.md index b56b6582..12fb3e10 100644 --- a/tests/vetting/matrix/glcm.md +++ b/tests/vetting/matrix/glcm.md @@ -6,6 +6,7 @@ Axes = the settings GLCM reads; verdicts (VALID/INVALID) are measured empiricall |---|---|---|---|---| | True | True | identity (levels=distinct) | VALID | glcm.ibsi_identity — ibsi/mirp | | False | True | fixed bin count | VALID | glcm.pyradiomics_symmetric — pyradiomics | +| False | False | MATLAB-style, 64 levels (default) | VALID for CLUPROM, CLUSHADE, CLUTEND, SUMVARIANCE, JVAR, VARIANCE, INFOMEAS1; the rest prod-only | glcm.analytic_default_asymmetric — analytic (IBSI definitions on the asymmetric matrix) | | any | any | offset/distance = 0 | INVALID | degenerate self-cooccurrence — mechanics guard, not an oracle | -3D: same axes; the recipe MUST force symmetric + 13-direction (Nyxus 3D GT default is asymmetric/1-offset). +3D: same axes; a tool recipe MUST force symmetric + 13-direction (Nyxus 3D GT default is asymmetric/1-offset). The default asymmetric cell is vetted for the same seven features by glcm3d.analytic_default_asymmetric. diff --git a/tests/vetting/not_covered.md b/tests/vetting/not_covered.md index bb7a27a7..ff1e4110 100644 --- a/tests/vetting/not_covered.md +++ b/tests/vetting/not_covered.md @@ -17,7 +17,7 @@ Regenerate by re-deriving both sets; keep this file in step with each reorg wave --- -## A. Test files no registry row references — 34 files, 124 test functions +## A. Test files no registry row references — 34 files, 128 test functions Both totals are the sum of the two tables below, counting each distinct file once and skipping any row struck through as closed, so they can be recomputed from the tables. @@ -32,7 +32,7 @@ These assert no feature value, so they have no `(feature × config × oracle)` r | `test_3d_nifti_mechanics.h` | 2 | NIfTI loader geometry / data access | | `test_arrow_mechanics.h` | 4 | Arrow + Parquet writer plumbing, including an output path that cannot be opened | | `test_arrow_file_name_mechanics.h` | 1 | output-file naming rules | -| `test_2d_glcm_mechanics.h` | 4 | guards the `GLCM_OFFSET` default and own grey depth (settings, not values) and the substitute for a ROI whose matrix cannot be held | +| `test_2d_glcm_mechanics.h` | 8 | guards the `GLCM_OFFSET` default and own grey depth (settings, not values), the substitute for a ROI whose matrix cannot be held, for a ROI of one grey level and for an undefined `INFOMEAS1`, and that `GLCM_HOM2_AVE` averages the per-angle values | | `test_2d_glcm_mechanics.py` | 3 | a ROI whose IBSI matrix cannot be held is refused on its own, in RAM and out of core | | `test_2d_radial_mechanics.h` | 6 | contour frame, centre pixel and normalising radius — the wiring the radial goldens depend on — and the one-pixel, two-pixel and two-fragment ROIs. **Uncredited by decision, not by construction:** see the note below the table | | `test_initialization_mechanics.h` | 1 | environment init | diff --git a/tests/vetting/oracle_coverage.csv b/tests/vetting/oracle_coverage.csv index b40ea72f..fb78ffd5 100644 --- a/tests/vetting/oracle_coverage.csv +++ b/tests/vetting/oracle_coverage.csv @@ -222,11 +222,14 @@ dim,feature,family,status,oracle,agreement,config_recipe,tolerance,current_test, 2D,ANG_BW_NEIGHBORS_MEAN,neighbor,vetted,analytic,agreed,neighbor.scene2d_radius1,abs=1e-9,test_2d_neighbor_analytic.h,test_2d_neighbor_analytic.h,,,audit,"vetted vs an independent numpy recomputation of the documented closed form on the neighborhood2d_scene_labels fixture at PIXELDISTANCE=1, recipe neighbor.scene2d_radius1; agreement 1.2e-16 worst case across the family (29 of 30 values bit-identical), asserted per ROI at abs=1e-9, SPEC 7's exact tier in test_2d_neighbor_analytic.h. The neighbour graph the closed form is evaluated on is itself vetted against CellProfiler, so this is not circular. CP cannot vet these: its AngleBetweenNeighbors is the SUBTENDED angle and its SecondClosestDistance ranges over ANY object, both different quantities. Re-measured 2026-08-20: the previous assertion was ASSERT_NEAR at 1e-4 absolute with no tolerance recorded here; an intermediate rel=1e-9 was corrected to the absolute band SPEC 7 defines. gen_neighbor_analytic.py re-verifies every pin in the header it feeds; tests/vetting/audit/neighbor_2d_analytic_vetting_report.md",TEST_NYXUS.TEST_2D_NEIGHBOR_SECOND_DISTANCE_AND_ANGLES_ANALYTIC,bench_scene7_5roi_enclosed 2D,ANG_BW_NEIGHBORS_STDDEV,neighbor,vetted,analytic,agreed,neighbor.scene2d_radius1,abs=1e-9,test_2d_neighbor_analytic.h,test_2d_neighbor_analytic.h,,,audit,"vetted vs an independent numpy recomputation of the documented closed form on the neighborhood2d_scene_labels fixture at PIXELDISTANCE=1, recipe neighbor.scene2d_radius1; agreement 1.2e-16 worst case across the family (29 of 30 values bit-identical), asserted per ROI at abs=1e-9, SPEC 7's exact tier in test_2d_neighbor_analytic.h. The neighbour graph the closed form is evaluated on is itself vetted against CellProfiler, so this is not circular. CP cannot vet these: its AngleBetweenNeighbors is the SUBTENDED angle and its SecondClosestDistance ranges over ANY object, both different quantities. Re-measured 2026-08-20: the previous assertion was ASSERT_NEAR at 1e-4 absolute with no tolerance recorded here; an intermediate rel=1e-9 was corrected to the absolute band SPEC 7 defines. gen_neighbor_analytic.py re-verifies every pin in the header it feeds; tests/vetting/audit/neighbor_2d_analytic_vetting_report.md",TEST_NYXUS.TEST_2D_NEIGHBOR_SECOND_DISTANCE_AND_ANGLES_ANALYTIC,bench_scene7_5roi_enclosed 2D,ANG_BW_NEIGHBORS_MODE,neighbor,vetted,analytic,agreed,neighbor.scene2d_radius1,abs=1e-9,test_2d_neighbor_analytic.h,test_2d_neighbor_analytic.h,,,audit,"vetted vs an independent numpy recomputation of the documented closed form on the neighborhood2d_scene_labels fixture at PIXELDISTANCE=1, recipe neighbor.scene2d_radius1; agreement 1.2e-16 worst case across the family (29 of 30 values bit-identical), asserted per ROI at abs=1e-9, SPEC 7's exact tier in test_2d_neighbor_analytic.h. The neighbour graph the closed form is evaluated on is itself vetted against CellProfiler, so this is not circular. CP cannot vet these: its AngleBetweenNeighbors is the SUBTENDED angle and its SecondClosestDistance ranges over ANY object, both different quantities. Re-measured 2026-08-20: the previous assertion was ASSERT_NEAR at 1e-4 absolute with no tolerance recorded here; an intermediate rel=1e-9 was corrected to the absolute band SPEC 7 defines. gen_neighbor_analytic.py re-verifies every pin in the header it feeds; tests/vetting/audit/neighbor_2d_analytic_vetting_report.md",TEST_NYXUS.TEST_2D_NEIGHBOR_SECOND_DISTANCE_AND_ANGLES_ANALYTIC,bench_scene7_5roi_enclosed -2D,GLCM_ASM,glcm,vetted,pyradiomics,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h,,,,in-tree,"RE-VETTED regression->vetted against pyradiomics v3.0.1 and mirp on the dense phantom of test_2d_glcm_common.h (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h). The demotion stood because test_2d_glcm_matlab.h asserted this against Nyxus' own snapshot table, so the matlab claim rested on no MATLAB values; re-vetting was blocked on graycoprops, which Octave does not ship. Two IBSI-conformant tools reproducing the value at rel<=rel=1e-9 closes that without MATLAB. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A | DEMOTED vetted->regression: test_2d_glcm_matlab.h asserted this through assert_glcm_feature_regression against the Nyxus snapshot table in test_2d_glcm_regression.h, so the matlab claim rested on no MATLAB values -- the table was refreshed in 2026-06 to follow a Nyxus fix. Assertions moved into test_2d_glcm_regression.h; graycoprops goldens (SPEC 6.4) would be needed to re-vet.",, +2D,GLCM_ASM,glcm,vetted,pyradiomics,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h;test_2d_glcm_mechanics.h,,,,in-tree,"RE-VETTED regression->vetted against pyradiomics v3.0.1 and mirp on the dense phantom of test_2d_glcm_common.h (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h). The demotion stood because test_2d_glcm_matlab.h asserted this against Nyxus' own snapshot table, so the matlab claim rested on no MATLAB values; re-vetting was blocked on graycoprops, which Octave does not ship. Two IBSI-conformant tools reproducing the value at rel<=rel=1e-9 closes that without MATLAB. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A | DEMOTED vetted->regression: test_2d_glcm_matlab.h asserted this through assert_glcm_feature_regression against the Nyxus snapshot table in test_2d_glcm_regression.h, so the matlab claim rested on no MATLAB values -- the table was refreshed in 2026-06 to follow a Nyxus fix. Assertions moved into test_2d_glcm_regression.h; graycoprops goldens (SPEC 6.4) would be needed to re-vet.",, 2D,GLCM_ACOR,glcm,vetted,mirp,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h,,MIRP/IBSI check,,in-tree,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | vetted vs MIRP (IBSI digital phantom, glcm_oracle/); MIRP reproduces IBSI consensus exactly and Nyxus IBSI gtest passes (ACOR 5.09, CLUSHADE 7, INFOMEAS1 -0.155, JAVE 2.14, JVAR 2.69, SUMAVERAGE 4.28); _AVE = angle-average of the vetted base",, -2D,GLCM_CLUPROM,glcm,vetted,pyradiomics,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h,,,,in-tree,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A",, -2D,GLCM_CLUSHADE,glcm,vetted,mirp,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h,,MIRP/IBSI check,,in-tree,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | vetted vs MIRP (IBSI digital phantom, glcm_oracle/); MIRP reproduces IBSI consensus exactly and Nyxus IBSI gtest passes (ACOR 5.09, CLUSHADE 7, INFOMEAS1 -0.155, JAVE 2.14, JVAR 2.69, SUMAVERAGE 4.28); _AVE = angle-average of the vetted base",, -2D,GLCM_CLUTEND,glcm,vetted,pyradiomics,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h,,,,in-tree,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A",, +2D,GLCM_CLUPROM,glcm,vetted,pyradiomics,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h;test_2d_glcm_analytic.h,,,,in-tree,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A",, +2D,GLCM_CLUPROM,glcm,vetted,analytic,agreed,glcm.analytic_default_asymmetric,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h;test_2d_glcm_analytic.h,test_2d_glcm_analytic.h,,,in-tree,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (AE86) evaluated in the test on the matrix it counts from the fixture itself, in each of the 4 angles of bench_square5_glcm_example and of its left-right mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions.",TEST_NYXUS.TEST_2D_GLCM_CLUSTER_AND_SUM_VARIANCE_ASYMMETRIC_ANALYTIC,bench_square5_glcm_example +2D,GLCM_CLUSHADE,glcm,vetted,mirp,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h;test_2d_glcm_analytic.h,,MIRP/IBSI check,,in-tree,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | vetted vs MIRP (IBSI digital phantom, glcm_oracle/); MIRP reproduces IBSI consensus exactly and Nyxus IBSI gtest passes (ACOR 5.09, CLUSHADE 7, INFOMEAS1 -0.155, JAVE 2.14, JVAR 2.69, SUMAVERAGE 4.28); _AVE = angle-average of the vetted base",, +2D,GLCM_CLUSHADE,glcm,vetted,analytic,agreed,glcm.analytic_default_asymmetric,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h;test_2d_glcm_analytic.h,test_2d_glcm_analytic.h,,,in-tree,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (7NFM) evaluated in the test on the matrix it counts from the fixture itself, in each of the 4 angles of bench_square5_glcm_example and of its left-right mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions.",TEST_NYXUS.TEST_2D_GLCM_CLUSTER_AND_SUM_VARIANCE_ASYMMETRIC_ANALYTIC,bench_square5_glcm_example +2D,GLCM_CLUTEND,glcm,vetted,pyradiomics,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h;test_2d_glcm_analytic.h,,,,in-tree,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A",, +2D,GLCM_CLUTEND,glcm,vetted,analytic,agreed,glcm.analytic_default_asymmetric,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h;test_2d_glcm_analytic.h,test_2d_glcm_analytic.h,,,in-tree,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (DG8W) evaluated in the test on the matrix it counts from the fixture itself, in each of the 4 angles of bench_square5_glcm_example and of its left-right mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions.",TEST_NYXUS.TEST_2D_GLCM_CLUSTER_AND_SUM_VARIANCE_ASYMMETRIC_ANALYTIC,bench_square5_glcm_example 2D,GLCM_CONTRAST,glcm,vetted,pyradiomics,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h,,,,in-tree,"RE-VETTED regression->vetted against pyradiomics v3.0.1 and mirp on the dense phantom of test_2d_glcm_common.h (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h). The demotion stood because test_2d_glcm_matlab.h asserted this against Nyxus' own snapshot table, so the matlab claim rested on no MATLAB values; re-vetting was blocked on graycoprops, which Octave does not ship. Two IBSI-conformant tools reproducing the value at rel<=rel=1e-9 closes that without MATLAB. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A | DEMOTED vetted->regression: test_2d_glcm_matlab.h asserted this through assert_glcm_feature_regression against the Nyxus snapshot table in test_2d_glcm_regression.h, so the matlab claim rested on no MATLAB values -- the table was refreshed in 2026-06 to follow a Nyxus fix. Assertions moved into test_2d_glcm_regression.h; graycoprops goldens (SPEC 6.4) would be needed to re-vet.",, 2D,GLCM_CORRELATION,glcm,vetted,pyradiomics,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h,,,,in-tree,"RE-VETTED regression->vetted against pyradiomics v3.0.1 and mirp on the dense phantom of test_2d_glcm_common.h (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h). The demotion stood because test_2d_glcm_matlab.h asserted this against Nyxus' own snapshot table, so the matlab claim rested on no MATLAB values; re-vetting was blocked on graycoprops, which Octave does not ship. Two IBSI-conformant tools reproducing the value at rel<=rel=1e-9 closes that without MATLAB. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A | DEMOTED vetted->regression: test_2d_glcm_matlab.h asserted this through assert_glcm_feature_regression against the Nyxus snapshot table in test_2d_glcm_regression.h, so the matlab claim rested on no MATLAB values -- the table was refreshed in 2026-06 to follow a Nyxus fix. Assertions moved into test_2d_glcm_regression.h; graycoprops goldens (SPEC 6.4) would be needed to re-vet.",, 2D,GLCM_DIFAVE,glcm,vetted,pyradiomics,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h,,,,in-tree,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A",, @@ -241,17 +244,21 @@ dim,feature,family,status,oracle,agreement,config_recipe,tolerance,current_test, 2D,GLCM_IDN,glcm,vetted,pyradiomics,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h,,,,in-tree,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A",, 2D,GLCM_IDM,glcm,vetted,pyradiomics,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h,,,,in-tree,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A",, 2D,GLCM_IDMN,glcm,vetted,pyradiomics,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h,,,,in-tree,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A",, -2D,GLCM_INFOMEAS1,glcm,vetted,mirp,agreed,glcm.ibsi_identity,rel=5e-3,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h,,MIRP/IBSI check,,in-tree,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=5e-3 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | vetted vs MIRP (IBSI digital phantom, glcm_oracle/); MIRP reproduces IBSI consensus exactly and Nyxus IBSI gtest passes (ACOR 5.09, CLUSHADE 7, INFOMEAS1 -0.155, JAVE 2.14, JVAR 2.69, SUMAVERAGE 4.28); _AVE = angle-average of the vetted base",, +2D,GLCM_INFOMEAS1,glcm,vetted,mirp,agreed,glcm.ibsi_identity,rel=5e-3,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h;test_2d_glcm_analytic.h;test_2d_glcm_mechanics.h,,MIRP/IBSI check,,in-tree,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=5e-3 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | vetted vs MIRP (IBSI digital phantom, glcm_oracle/); MIRP reproduces IBSI consensus exactly and Nyxus IBSI gtest passes (ACOR 5.09, CLUSHADE 7, INFOMEAS1 -0.155, JAVE 2.14, JVAR 2.69, SUMAVERAGE 4.28); _AVE = angle-average of the vetted base",, +2D,GLCM_INFOMEAS1,glcm,vetted,analytic,agreed,glcm.analytic_default_asymmetric,rel=1.5e-2,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h;test_2d_glcm_analytic.h;test_2d_glcm_mechanics.h,test_2d_glcm_analytic.h,,,in-tree,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (R8DG) evaluated in the test on the matrix it counts from the fixture itself, in each of the 4 angles of bench_square5_glcm_example and of its left-right mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions. Nyxus' entropies take the fast_log10 approximation, so the band is the measured worst residual with margin (7.0e-3 in 2D, 1.4e-2 in 3D).",TEST_NYXUS.TEST_2D_GLCM_INFOMEAS1_ASYMMETRIC_ANALYTIC,bench_square5_glcm_example 2D,GLCM_INFOMEAS2,glcm,vetted,pyradiomics,agreed,glcm.ibsi_identity,rel=5e-3,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h,,,,in-tree,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=5e-3 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A",, 2D,GLCM_IV,glcm,vetted,pyradiomics,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h,,,,in-tree,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A",, 2D,GLCM_JAVE,glcm,vetted,mirp,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h,,MIRP/IBSI check,,in-tree,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | vetted vs MIRP (IBSI digital phantom, glcm_oracle/); MIRP reproduces IBSI consensus exactly and Nyxus IBSI gtest passes (ACOR 5.09, CLUSHADE 7, INFOMEAS1 -0.155, JAVE 2.14, JVAR 2.69, SUMAVERAGE 4.28); _AVE = angle-average of the vetted base",, 2D,GLCM_JE,glcm,vetted,pyradiomics,agreed,glcm.ibsi_identity,rel=5e-3,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h,,,,in-tree,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=5e-3 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A",, 2D,GLCM_JMAX,glcm,vetted,pyradiomics,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h,,,,in-tree,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A",, -2D,GLCM_JVAR,glcm,vetted,mirp,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h,,MIRP/IBSI check,,in-tree,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | vetted vs MIRP (IBSI digital phantom, glcm_oracle/); MIRP reproduces IBSI consensus exactly and Nyxus IBSI gtest passes (ACOR 5.09, CLUSHADE 7, INFOMEAS1 -0.155, JAVE 2.14, JVAR 2.69, SUMAVERAGE 4.28); _AVE = angle-average of the vetted base",, +2D,GLCM_JVAR,glcm,vetted,mirp,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h;test_2d_glcm_analytic.h,,MIRP/IBSI check,,in-tree,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | vetted vs MIRP (IBSI digital phantom, glcm_oracle/); MIRP reproduces IBSI consensus exactly and Nyxus IBSI gtest passes (ACOR 5.09, CLUSHADE 7, INFOMEAS1 -0.155, JAVE 2.14, JVAR 2.69, SUMAVERAGE 4.28); _AVE = angle-average of the vetted base",, +2D,GLCM_JVAR,glcm,vetted,analytic,agreed,glcm.analytic_default_asymmetric,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h;test_2d_glcm_analytic.h,test_2d_glcm_analytic.h,,,in-tree,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (UR99) evaluated in the test on the matrix it counts from the fixture itself, in each of the 4 angles of bench_square5_glcm_example and of its left-right mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions.",TEST_NYXUS.TEST_2D_GLCM_JVAR_ASYMMETRIC_ANALYTIC,bench_square5_glcm_example 2D,GLCM_SUMAVERAGE,glcm,vetted,mirp,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h,,MIRP/IBSI check,,in-tree,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | vetted vs MIRP (IBSI digital phantom, glcm_oracle/); MIRP reproduces IBSI consensus exactly and Nyxus IBSI gtest passes (ACOR 5.09, CLUSHADE 7, INFOMEAS1 -0.155, JAVE 2.14, JVAR 2.69, SUMAVERAGE 4.28); _AVE = angle-average of the vetted base",, 2D,GLCM_SUMENTROPY,glcm,vetted,pyradiomics,agreed,glcm.ibsi_identity,rel=5e-3,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h,,,,in-tree,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=5e-3 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A",, -2D,GLCM_SUMVARIANCE,glcm,vetted,pyradiomics,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h,,,,in-tree,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A",, -2D,GLCM_VARIANCE,glcm,vetted,ibsi,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_ibsi.h;test_2d_glcm_regression.h,,,,in-tree,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | IBSI has no separate variance quantity: Nyxus computes GLCM_VARIANCE as the joint variance about the grey-level marginal mean - a routine distinct from the one behind GLCM_JVAR that reaches the same quantity (measured 2.687695905 for both) - so it is asserted in test_2d_glcm_ibsi.h against the IBSI joint variance consensus UR99 = 2.69. Was vetted from an offline run only (source=tracker), with target_test naming a PyRadiomics test that does not exist; PyRadiomics has no GLCM variance feature of its own, its Sum of Squares being this same joint variance.",, +2D,GLCM_SUMVARIANCE,glcm,vetted,pyradiomics,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h;test_2d_glcm_analytic.h,,,,in-tree,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A",, +2D,GLCM_SUMVARIANCE,glcm,vetted,analytic,agreed,glcm.analytic_default_asymmetric,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_ibsi.h;test_2d_glcm_analytic.h,test_2d_glcm_analytic.h,,,in-tree,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (OEEB) evaluated in the test on the matrix it counts from the fixture itself, in each of the 4 angles of bench_square5_glcm_example and of its left-right mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions.",TEST_NYXUS.TEST_2D_GLCM_CLUSTER_AND_SUM_VARIANCE_ASYMMETRIC_ANALYTIC,bench_square5_glcm_example +2D,GLCM_VARIANCE,glcm,vetted,ibsi,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_ibsi.h;test_2d_glcm_regression.h;test_2d_glcm_analytic.h,,,,in-tree,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | IBSI has no separate variance quantity: Nyxus computes GLCM_VARIANCE as the joint variance about the grey-level marginal mean - a routine distinct from the one behind GLCM_JVAR that reaches the same quantity (measured 2.687695905 for both) - so it is asserted in test_2d_glcm_ibsi.h against the IBSI joint variance consensus UR99 = 2.69. Was vetted from an offline run only (source=tracker), with target_test naming a PyRadiomics test that does not exist; PyRadiomics has no GLCM variance feature of its own, its Sum of Squares being this same joint variance.",, +2D,GLCM_VARIANCE,glcm,vetted,analytic,agreed,glcm.analytic_default_asymmetric,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_ibsi.h;test_2d_glcm_regression.h;test_2d_glcm_analytic.h,test_2d_glcm_analytic.h,,,in-tree,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted equal at rel=1e-12 to GLCM_JVAR, which test_2d_glcm_jvar_asymmetric_analytic checks against the IBSI joint variance (UR99) evaluated in the test on the matrix it counts from the fixture itself, in each of the 4 angles of bench_square5_glcm_example and of its left-right mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions.",TEST_NYXUS.TEST_2D_GLCM_JVAR_ASYMMETRIC_ANALYTIC,bench_square5_glcm_example 2D,GLCM_ASM_AVE,glcm,vetted,pyradiomics,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_ibsi.h;test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h,,,,in-tree,"RE-VETTED regression->vetted against pyradiomics v3.0.1 and mirp on the dense phantom of test_2d_glcm_common.h (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h). The demotion stood because test_2d_glcm_matlab.h asserted this against Nyxus' own snapshot table, so the matlab claim rested on no MATLAB values; re-vetting was blocked on graycoprops, which Octave does not ship. Two IBSI-conformant tools reproducing the value at rel<=rel=1e-9 closes that without MATLAB. | DEMOTED vetted->regression: test_2d_glcm_matlab.h asserted this through assert_glcm_feature_regression against the Nyxus snapshot table in test_2d_glcm_regression.h, so the matlab claim rested on no MATLAB values -- the table was refreshed in 2026-06 to follow a Nyxus fix. Assertions moved into test_2d_glcm_regression.h; graycoprops goldens (SPEC 6.4) would be needed to re-vet.",, 2D,GLCM_ACOR_AVE,glcm,vetted,mirp,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_ibsi.h;test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_pyradiomics.py,,MIRP/IBSI check,,in-tree,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | vetted vs MIRP (IBSI digital phantom, glcm_oracle/); MIRP reproduces IBSI consensus exactly and Nyxus IBSI gtest passes (ACOR 5.09, CLUSHADE 7, INFOMEAS1 -0.155, JAVE 2.14, JVAR 2.69, SUMAVERAGE 4.28); _AVE = angle-average of the vetted base",, 2D,GLCM_CLUPROM_AVE,glcm,vetted,ibsi,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_ibsi.h;test_2d_glcm_regression.h,,,,in-tree,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | Asserted in test_2d_glcm_ibsi.h against the IBSI consensus for CLUPROM (AE86) (= 79.1): that consensus is quoted for the 2D-averaged aggregation, so it is the golden of the angle average itself, and the _AVE feature reproduces its base feature's 4-angle mean exactly (both 79.11263068). Was vetted from an offline run only (source=tracker), with nothing in the tree asserting the angle-averaging step.",, @@ -268,7 +275,8 @@ dim,feature,family,status,oracle,agreement,config_recipe,tolerance,current_test, 2D,GLCM_HOM1_AVE,glcm,vetted,pyradiomics,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h,,,,in-tree,"RE-VETTED regression->vetted against pyradiomics v3.0.1 and mirp on the dense phantom of test_2d_glcm_common.h (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h). The demotion stood because test_2d_glcm_matlab.h asserted this against Nyxus' own snapshot table, so the matlab claim rested on no MATLAB values; re-vetting was blocked on graycoprops, which Octave does not ship. Two IBSI-conformant tools reproducing the value at rel<=rel=1e-9 closes that without MATLAB. | DEMOTED vetted->regression: test_2d_glcm_matlab.h asserted this through assert_glcm_feature_regression against the Nyxus snapshot table in test_2d_glcm_regression.h, so the matlab claim rested on no MATLAB values -- the table was refreshed in 2026-06 to follow a Nyxus fix. Assertions moved into test_2d_glcm_regression.h; graycoprops goldens (SPEC 6.4) would be needed to re-vet.",, 2D,GLCM_ID_AVE,glcm,vetted,ibsi,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_ibsi.h;test_2d_glcm_regression.h,,,,in-tree,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | Asserted in test_2d_glcm_ibsi.h against the IBSI consensus for ID (IB1Z) (= 0.678): that consensus is quoted for the 2D-averaged aggregation, so it is the golden of the angle average itself, and the _AVE feature reproduces its base feature's 4-angle mean exactly (both 0.6779485416). Was vetted from an offline run only (source=tracker), with nothing in the tree asserting the angle-averaging step.",, 2D,GLCM_IDN_AVE,glcm,vetted,pyradiomics,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_ibsi.h;test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_pyradiomics.py,,,,in-tree,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against.",, -2D,GLCM_IDM_AVE,glcm,vetted,ibsi,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_ibsi.h;test_2d_glcm_regression.h,,,,in-tree,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | Asserted in test_2d_glcm_ibsi.h against the IBSI consensus for IDM (WF0Z) (= 0.619): that consensus is quoted for the 2D-averaged aggregation, so it is the golden of the angle average itself, and the _AVE feature reproduces its base feature's 4-angle mean exactly (both 0.6187370709). Was vetted from an offline run only (source=tracker), with nothing in the tree asserting the angle-averaging step.",, +2D,GLCM_IDM_AVE,glcm,vetted,ibsi,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_ibsi.h;test_2d_glcm_regression.h;test_2d_glcm_mechanics.h,,,,in-tree,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | Asserted in test_2d_glcm_ibsi.h against the IBSI consensus for IDM (WF0Z) (= 0.619): that consensus is quoted for the 2D-averaged aggregation, so it is the golden of the angle average itself, and the _AVE feature reproduces its base feature's 4-angle mean exactly (both 0.6187370709). Was vetted from an offline run only (source=tracker), with nothing in the tree asserting the angle-averaging step.",, +2D,GLCM_HOM2_AVE,glcm,vetted,ibsi,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_ibsi.h;test_2d_glcm_regression.h,,,,in-tree,"Also asserted against pyradiomics v3.0.1 and MIRP on the dense phantom of test_2d_glcm_common.h at rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h). | Homogeneity 2 is the inverse difference moment, so its angle average is asserted in test_2d_glcm_ibsi.h against the IBSI consensus for IDM (WF0Z, 0.619) and against Idm / cm_inv_diff_mom in the two tool tables; test_2d_glcm_hom2_ave_mechanics holds it equal to the mean of the four GLCM_HOM2 angles and to GLCM_IDM_AVE.",, 2D,GLCM_IDMN_AVE,glcm,vetted,pyradiomics,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_ibsi.h;test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_regression.h;test_2d_glcm_pyradiomics.py,,,,in-tree,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against.",, 2D,GLCM_IV_AVE,glcm,vetted,ibsi,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_ibsi.h;test_2d_glcm_regression.h,,,,in-tree,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | Asserted in test_2d_glcm_ibsi.h against the IBSI consensus for IV (E8JP) (= 0.0567): that consensus is quoted for the 2D-averaged aggregation, so it is the golden of the angle average itself, and the _AVE feature reproduces its base feature's 4-angle mean exactly (both 0.05669828975). Was vetted from an offline run only (source=tracker), with nothing in the tree asserting the angle-averaging step.",, 2D,GLCM_JAVE_AVE,glcm,vetted,ibsi,agreed,glcm.ibsi_identity,rel=1e-9,test_2d_glcm_mirp.h;test_2d_glcm_pyradiomics.h;test_2d_glcm_ibsi.h;test_2d_glcm_regression.h,,,,in-tree,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | Asserted in test_2d_glcm_ibsi.h against the IBSI consensus for JAVE (60VM) (= 2.14): that consensus is quoted for the 2D-averaged aggregation, so it is the golden of the angle average itself, and the _AVE feature reproduces its base feature's 4-angle mean exactly (both 2.142418606). Was vetted from an offline run only (source=tracker), with nothing in the tree asserting the angle-averaging step. | vetted vs MIRP (IBSI digital phantom, glcm_oracle/); MIRP reproduces IBSI consensus exactly and Nyxus IBSI gtest passes (ACOR 5.09, CLUSHADE 7, INFOMEAS1 -0.155, JAVE 2.14, JVAR 2.69, SUMAVERAGE 4.28); _AVE = angle-average of the vetted base",, @@ -751,10 +759,13 @@ dim,feature,family,status,oracle,agreement,config_recipe,tolerance,current_test, 3D,3MESH_VOLUME,morphology,vetted,analytic,agreed,morphology3d.analytic_lattice_solids,rel=1e-12,test_3d_morphology_analytic.h,,,,in-tree,"vetted vs closed-form geometry, recipe morphology3d.analytic_lattice_solids, asserted in test_3d_morphology_analytic.h. A single voxel's 0.5-isolevel surface is the octahedron with vertices half a lattice step out (volume 1/6) and a solid w x h x d box is a bevelled box whose volume is an exact function of w, h and d, in both the general and the whole-volume (SINGLEROI) branch; a box with zero intensities gives the same. Every golden holds at rel=1e-12. No external tool is involved, so this row is independent of the MIRP row on the same feature. The shapes separate the conventions outright: counting voxels returns 1 for the single voxel against 1/6. Scope: ROIs whose surface has no ambiguous face (two diagonal corners inside); the phantom has none, so no value assertion reaches the 120 case-table entries that depart from the classic triangulation.",, 3D,3VOLUME_CONVEXHULL,morphology,vetted,analytic,agreed,morphology3d.analytic_lattice_solids,rel=1e-12,test_3d_morphology_analytic.h,,,,in-tree,"vetted vs closed-form geometry, recipe morphology3d.analytic_lattice_solids, asserted in test_3d_morphology_analytic.h through D3_SurfaceFeature. 3VOLUME_CONVEXHULL is the volume of the convex hull of the mesh vertices, each an in-ROI voxel moved half a step towards an out-of-ROI neighbour, so on a lattice solid whose extreme voxels are known it is exact: the single voxel (1/6) and the w x h x d box (the bevelled box, in both SINGLEROI settings) are their own hulls, the octahedron |x|+|y|+|z| <= R gives 4/3 (R+1/2)^3 (R = 3, 8, 15), and the rhombic prism |x|+|y| <= R, |z| <= H gives a prism of radius R+1/2 and height 2H with two frusta of height 1/2 (R = 4, 12; H = R/2+1). A one-slice ROI gives its bevelled slab, and a box with zero intensities the uniform box's value. The solids sit hundreds of voxels from the origin and every volume holds at rel=1e-12; qhull over the same vertices reproduces each to 5e-16. No external tool is involved, so this row is independent of the MIRP and MATLAB rows on the same feature. The quick_hull kernel under the feature is checked predicate by predicate in test_3d_morphology_mechanics.h, which is mechanics and claims no vetting. Scope: ROIs whose surface has no ambiguous face (two diagonal corners inside); the phantom has none, so no value assertion reaches the 120 case-table entries that depart from the classic triangulation.",, 3D,3GLCM_ACOR,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, -3D,3GLCM_ASM,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, -3D,3GLCM_CLUPROM,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, -3D,3GLCM_CLUSHADE,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, -3D,3GLCM_CLUTEND,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, +3D,3GLCM_ASM,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h;test_3d_glcm_mechanics.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, +3D,3GLCM_CLUPROM,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h;test_3d_glcm_analytic.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, +3D,3GLCM_CLUPROM,glcm,vetted,analytic,agreed,glcm3d.analytic_default_asymmetric,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h;test_3d_glcm_analytic.h,test_3d_glcm_analytic.h,,,in-tree,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (AE86) evaluated in the test on the matrix it counts from the fixture itself, in each of the 13 directions of bench_box5x5x3_glcm_asymmetric and of its x-mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions.",TEST_NYXUS.TEST_3D_GLCM_CLUSTER_AND_SUM_VARIANCE_ASYMMETRIC_ANALYTIC,bench_box5x5x3_glcm_asymmetric +3D,3GLCM_CLUSHADE,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h;test_3d_glcm_analytic.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, +3D,3GLCM_CLUSHADE,glcm,vetted,analytic,agreed,glcm3d.analytic_default_asymmetric,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h;test_3d_glcm_analytic.h,test_3d_glcm_analytic.h,,,in-tree,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (7NFM) evaluated in the test on the matrix it counts from the fixture itself, in each of the 13 directions of bench_box5x5x3_glcm_asymmetric and of its x-mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions.",TEST_NYXUS.TEST_3D_GLCM_CLUSTER_AND_SUM_VARIANCE_ASYMMETRIC_ANALYTIC,bench_box5x5x3_glcm_asymmetric +3D,3GLCM_CLUTEND,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h;test_3d_glcm_analytic.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, +3D,3GLCM_CLUTEND,glcm,vetted,analytic,agreed,glcm3d.analytic_default_asymmetric,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h;test_3d_glcm_analytic.h,test_3d_glcm_analytic.h,,,in-tree,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (DG8W) evaluated in the test on the matrix it counts from the fixture itself, in each of the 13 directions of bench_box5x5x3_glcm_asymmetric and of its x-mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions.",TEST_NYXUS.TEST_3D_GLCM_CLUSTER_AND_SUM_VARIANCE_ASYMMETRIC_ANALYTIC,bench_box5x5x3_glcm_asymmetric 3D,3GLCM_CONTRAST,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, 3D,3GLCM_CORRELATION,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, 3D,3GLCM_DIFAVE,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, @@ -769,17 +780,21 @@ dim,feature,family,status,oracle,agreement,config_recipe,tolerance,current_test, 3D,3GLCM_IDN,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, 3D,3GLCM_IDM,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, 3D,3GLCM_IDMN,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, -3D,3GLCM_INFOMEAS1,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=4e-2,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is 1.7e-2. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only). That band is Nyxus' fast_log10 (helpers.h), a float-precision log2 approximation used by every entropy-family GLCM feature, not a convention difference.",, +3D,3GLCM_INFOMEAS1,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=4e-2,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h;test_3d_glcm_analytic.h;test_3d_glcm_mechanics.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is 1.7e-2. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only). That band is Nyxus' fast_log10 (helpers.h), a float-precision log2 approximation used by every entropy-family GLCM feature, not a convention difference.",, +3D,3GLCM_INFOMEAS1,glcm,vetted,analytic,agreed,glcm3d.analytic_default_asymmetric,rel=2e-2,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h;test_3d_glcm_analytic.h;test_3d_glcm_mechanics.h,test_3d_glcm_analytic.h,,,in-tree,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (R8DG) evaluated in the test on the matrix it counts from the fixture itself, in each of the 13 directions of bench_box5x5x3_glcm_asymmetric and of its x-mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions. Nyxus' entropies take the fast_log10 approximation, so the band is the measured worst residual with margin (7.0e-3 in 2D, 1.4e-2 in 3D).",TEST_NYXUS.TEST_3D_GLCM_INFOMEAS1_ASYMMETRIC_ANALYTIC,bench_box5x5x3_glcm_asymmetric 3D,3GLCM_INFOMEAS2,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=2e-2,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is 7.7e-3. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only). That band is Nyxus' fast_log10 (helpers.h), a float-precision log2 approximation used by every entropy-family GLCM feature, not a convention difference.",, 3D,3GLCM_IV,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, 3D,3GLCM_JAVE,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, 3D,3GLCM_JE,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-3,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is 4.1e-4. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only). That band is Nyxus' fast_log10 (helpers.h), a float-precision log2 approximation used by every entropy-family GLCM feature, not a convention difference.",, 3D,3GLCM_JMAX,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, -3D,3GLCM_JVAR,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, +3D,3GLCM_JVAR,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h;test_3d_glcm_analytic.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, +3D,3GLCM_JVAR,glcm,vetted,analytic,agreed,glcm3d.analytic_default_asymmetric,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h;test_3d_glcm_analytic.h,test_3d_glcm_analytic.h,,,in-tree,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (UR99) evaluated in the test on the matrix it counts from the fixture itself, in each of the 13 directions of bench_box5x5x3_glcm_asymmetric and of its x-mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions.",TEST_NYXUS.TEST_3D_GLCM_JVAR_ASYMMETRIC_ANALYTIC,bench_box5x5x3_glcm_asymmetric 3D,3GLCM_SUMAVERAGE,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, 3D,3GLCM_SUMENTROPY,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=2e-3,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is 7.6e-4. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only). That band is Nyxus' fast_log10 (helpers.h), a float-precision log2 approximation used by every entropy-family GLCM feature, not a convention difference.",, -3D,3GLCM_SUMVARIANCE,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h,,"pyradiomics/mirp (DIS=DifferenceAverage, HOM1=Id, HOM2=Idm, SUMVAR=ClusterTendency, ENERGY=JointEnergy=ASM, VAR=mirp cm_var); CONFIG-SENSITIVE: symmetric+13dir vs Nyxus asym/1-offset/100lvl",,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, -3D,3GLCM_VARIANCE,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h,,"pyradiomics/mirp (DIS=DifferenceAverage, HOM1=Id, HOM2=Idm, SUMVAR=ClusterTendency, ENERGY=JointEnergy=ASM, VAR=mirp cm_var); CONFIG-SENSITIVE: symmetric+13dir vs Nyxus asym/1-offset/100lvl",,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, +3D,3GLCM_SUMVARIANCE,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h;test_3d_glcm_analytic.h,,"pyradiomics/mirp (DIS=DifferenceAverage, HOM1=Id, HOM2=Idm, SUMVAR=ClusterTendency, ENERGY=JointEnergy=ASM, VAR=mirp cm_var); CONFIG-SENSITIVE: symmetric+13dir vs Nyxus asym/1-offset/100lvl",,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, +3D,3GLCM_SUMVARIANCE,glcm,vetted,analytic,agreed,glcm3d.analytic_default_asymmetric,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h;test_3d_glcm_analytic.h,test_3d_glcm_analytic.h,,,in-tree,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (OEEB) evaluated in the test on the matrix it counts from the fixture itself, in each of the 13 directions of bench_box5x5x3_glcm_asymmetric and of its x-mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions.",TEST_NYXUS.TEST_3D_GLCM_CLUSTER_AND_SUM_VARIANCE_ASYMMETRIC_ANALYTIC,bench_box5x5x3_glcm_asymmetric +3D,3GLCM_VARIANCE,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h;test_3d_glcm_analytic.h,,"pyradiomics/mirp (DIS=DifferenceAverage, HOM1=Id, HOM2=Idm, SUMVAR=ClusterTendency, ENERGY=JointEnergy=ASM, VAR=mirp cm_var); CONFIG-SENSITIVE: symmetric+13dir vs Nyxus asym/1-offset/100lvl",,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only).",, +3D,3GLCM_VARIANCE,glcm,vetted,analytic,agreed,glcm3d.analytic_default_asymmetric,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h;test_3d_glcm_analytic.h,test_3d_glcm_analytic.h,,,in-tree,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (UR99) evaluated in the test on the matrix it counts from the fixture itself, in each of the 13 directions of bench_box5x5x3_glcm_asymmetric and of its x-mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions.",TEST_NYXUS.TEST_3D_GLCM_JVAR_ASYMMETRIC_ANALYTIC,bench_box5x5x3_glcm_asymmetric 3D,3GLCM_ASM_AVE,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_nyxus.py;test_3d_glcm_regression.h;test_3d_glcm_pyradiomics.py;test_3d_glcm_analytic.py,,mirp,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20. PyRadiomics reports one value per feature over its whole direction set, which is this *_AVE aggregation over the 13 3D angles; the assertion reads the stored *_AVE feature rather than recomputing it, so a defect in how save_value populates *_AVE fails here. The 13 directional values of the base feature are asserted separately and per direction. Measured residual <= 1.2e-15.",, 3D,3GLCM_ASM_AVE,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_volmin_bincount8,rel=1e-9,test_3d_glcm_pyradiomics.h;test_nyxus.py;test_3d_glcm_regression.h;test_3d_glcm_pyradiomics.py;test_3d_glcm_analytic.py,,,,in-tree,"vetted vs PyRadiomics 3.0.1 on bench_volmin_3d, recipe glcm3d.pyradiomics_volmin_bincount8: Nyxus coarse_gray_depth=-8, PyRadiomics-style binning (IBSI's fixed bin number over the ROI's own [min, max]), against PyRadiomics binCount=8, label 1, no resampling, weightingNorm=None, force2D=False -- each tool discretising for itself. The ROI holds the volume's lowest intensity, which Nyxus stores as 0, the value the background cells of its bounding box hold; under this binning those voxels are the ROI's bin 1. The same table holds on the control bench_volmin_ctrl_3d, whose ROI is stored without a 0, and both run in RAM and out of core (an OME-TIFF Z-stack streamed at ram_limit=0). A family that bins a stored 0 to level 0 reads those voxels as background, or shifts every level by one, and parts from the table on bench_volmin_3d while it still holds on the control. PyRadiomics reports one value over its 13 directions, which is this *_AVE aggregation. Asserted at rel=1e-9 by test_3d_glcm_volmin_pyradiomics in tests/python/test_3d_glcm_pyradiomics.py, a pytest case, so test_name is empty; the logarithmic 3GLCM_DIFENTRO_AVE, 3GLCM_INFOMEAS1_AVE, 3GLCM_INFOMEAS2_AVE, 3GLCM_JE_AVE and 3GLCM_SUMENTROPY_AVE carry Nyxus' fast_log10 approximation and so stay out of the table. tests/vetting/oracles/gen_glcm3d_pyradiomics.py re-verifies every pin at rel 1e-12 and that PyRadiomics gives the control the same values.",,bench_volmin_3d 3D,3GLCM_ASM_AVE,glcm,vetted,analytic,agreed,glcm3d.analytic_matlab_background,rel=1e-9,test_3d_glcm_pyradiomics.h;test_nyxus.py;test_3d_glcm_regression.h;test_3d_glcm_pyradiomics.py;test_3d_glcm_analytic.py,,,,in-tree,"vetted vs the definition at recipe glcm3d.analytic_matlab_background: MATLAB-style binning at the default coarse grey depth 64 on bench_ellipsoid6x40x40_boxbg_3d, an ellipsoid ROI whose bounding box has background in it, in RAM and out of core. The reference, evaluated in numpy inside the test, counts for each of the 13 offsets at distance 1 the ordered pairs of ROI voxels by their MATLAB levels, floor(64 x / max + 1) clipped to 1..64, and takes ASM (sum p^2) of each normalised matrix, averaged over the 13. A family that reads the bounding box's background as level 1 counts every ROI-background pair and parts from it on the ellipsoid; test_3d_glcm_matlab_box_analytic, a ROI that fills its bounding box, is the negative case that holds either way. Asserted at rel=1e-9 by test_3d_glcm_matlab_background_analytic in tests/python/test_3d_glcm_analytic.py, a pytest case, so test_name is empty.",,bench_ellipsoid6x40x40_boxbg_3d @@ -811,6 +826,7 @@ dim,feature,family,status,oracle,agreement,config_recipe,tolerance,current_test, 3D,3GLCM_IDN_AVE,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_volmin_bincount8,rel=1e-9,test_3d_glcm_pyradiomics.h;test_nyxus.py;test_3d_glcm_regression.h;test_3d_glcm_pyradiomics.py,,,,in-tree,"vetted vs PyRadiomics 3.0.1 on bench_volmin_3d, recipe glcm3d.pyradiomics_volmin_bincount8: Nyxus coarse_gray_depth=-8, PyRadiomics-style binning (IBSI's fixed bin number over the ROI's own [min, max]), against PyRadiomics binCount=8, label 1, no resampling, weightingNorm=None, force2D=False -- each tool discretising for itself. The ROI holds the volume's lowest intensity, which Nyxus stores as 0, the value the background cells of its bounding box hold; under this binning those voxels are the ROI's bin 1. The same table holds on the control bench_volmin_ctrl_3d, whose ROI is stored without a 0, and both run in RAM and out of core (an OME-TIFF Z-stack streamed at ram_limit=0). A family that bins a stored 0 to level 0 reads those voxels as background, or shifts every level by one, and parts from the table on bench_volmin_3d while it still holds on the control. PyRadiomics reports one value over its 13 directions, which is this *_AVE aggregation. Asserted at rel=1e-9 by test_3d_glcm_volmin_pyradiomics in tests/python/test_3d_glcm_pyradiomics.py, a pytest case, so test_name is empty; the logarithmic 3GLCM_DIFENTRO_AVE, 3GLCM_INFOMEAS1_AVE, 3GLCM_INFOMEAS2_AVE, 3GLCM_JE_AVE and 3GLCM_SUMENTROPY_AVE carry Nyxus' fast_log10 approximation and so stay out of the table. tests/vetting/oracles/gen_glcm3d_pyradiomics.py re-verifies every pin at rel 1e-12 and that PyRadiomics gives the control the same values.",,bench_volmin_3d 3D,3GLCM_IDM_AVE,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_nyxus.py;test_3d_glcm_regression.h;test_3d_glcm_pyradiomics.py,,mirp,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20. PyRadiomics reports one value per feature over its whole direction set, which is this *_AVE aggregation over the 13 3D angles; the assertion reads the stored *_AVE feature rather than recomputing it, so a defect in how save_value populates *_AVE fails here. The 13 directional values of the base feature are asserted separately and per direction. Measured residual <= 1.2e-15.",, 3D,3GLCM_IDM_AVE,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_volmin_bincount8,rel=1e-9,test_3d_glcm_pyradiomics.h;test_nyxus.py;test_3d_glcm_regression.h;test_3d_glcm_pyradiomics.py,,,,in-tree,"vetted vs PyRadiomics 3.0.1 on bench_volmin_3d, recipe glcm3d.pyradiomics_volmin_bincount8: Nyxus coarse_gray_depth=-8, PyRadiomics-style binning (IBSI's fixed bin number over the ROI's own [min, max]), against PyRadiomics binCount=8, label 1, no resampling, weightingNorm=None, force2D=False -- each tool discretising for itself. The ROI holds the volume's lowest intensity, which Nyxus stores as 0, the value the background cells of its bounding box hold; under this binning those voxels are the ROI's bin 1. The same table holds on the control bench_volmin_ctrl_3d, whose ROI is stored without a 0, and both run in RAM and out of core (an OME-TIFF Z-stack streamed at ram_limit=0). A family that bins a stored 0 to level 0 reads those voxels as background, or shifts every level by one, and parts from the table on bench_volmin_3d while it still holds on the control. PyRadiomics reports one value over its 13 directions, which is this *_AVE aggregation. Asserted at rel=1e-9 by test_3d_glcm_volmin_pyradiomics in tests/python/test_3d_glcm_pyradiomics.py, a pytest case, so test_name is empty; the logarithmic 3GLCM_DIFENTRO_AVE, 3GLCM_INFOMEAS1_AVE, 3GLCM_INFOMEAS2_AVE, 3GLCM_JE_AVE and 3GLCM_SUMENTROPY_AVE carry Nyxus' fast_log10 approximation and so stay out of the table. tests/vetting/oracles/gen_glcm3d_pyradiomics.py re-verifies every pin at rel 1e-12 and that PyRadiomics gives the control the same values.",,bench_volmin_3d +3D,3GLCM_HOM2_AVE,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_3d_glcm_regression.h,,mirp,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20. Homogeneity 2 is PyRadiomics' Idm, so test_3d_glcm_hom2_ave_pyradiomics reads the stored *_AVE feature against Idm's direction-set value, and test_3d_glcm_ave_equivalence_pyradiomics holds it equal to 3GLCM_IDM_AVE. test_3d_glcm_regression.h pins Nyxus' own value at the grey64 profile (drift guard only).",, 3D,3GLCM_IDMN_AVE,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_nyxus.py;test_3d_glcm_regression.h;test_3d_glcm_pyradiomics.py,,,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20. PyRadiomics reports one value per feature over its whole direction set, which is this *_AVE aggregation over the 13 3D angles; the assertion reads the stored *_AVE feature rather than recomputing it, so a defect in how save_value populates *_AVE fails here. The 13 directional values of the base feature are asserted separately and per direction. Measured residual <= 1.2e-15.",, 3D,3GLCM_IDMN_AVE,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_volmin_bincount8,rel=1e-9,test_3d_glcm_pyradiomics.h;test_nyxus.py;test_3d_glcm_regression.h;test_3d_glcm_pyradiomics.py,,,,in-tree,"vetted vs PyRadiomics 3.0.1 on bench_volmin_3d, recipe glcm3d.pyradiomics_volmin_bincount8: Nyxus coarse_gray_depth=-8, PyRadiomics-style binning (IBSI's fixed bin number over the ROI's own [min, max]), against PyRadiomics binCount=8, label 1, no resampling, weightingNorm=None, force2D=False -- each tool discretising for itself. The ROI holds the volume's lowest intensity, which Nyxus stores as 0, the value the background cells of its bounding box hold; under this binning those voxels are the ROI's bin 1. The same table holds on the control bench_volmin_ctrl_3d, whose ROI is stored without a 0, and both run in RAM and out of core (an OME-TIFF Z-stack streamed at ram_limit=0). A family that bins a stored 0 to level 0 reads those voxels as background, or shifts every level by one, and parts from the table on bench_volmin_3d while it still holds on the control. PyRadiomics reports one value over its 13 directions, which is this *_AVE aggregation. Asserted at rel=1e-9 by test_3d_glcm_volmin_pyradiomics in tests/python/test_3d_glcm_pyradiomics.py, a pytest case, so test_name is empty; the logarithmic 3GLCM_DIFENTRO_AVE, 3GLCM_INFOMEAS1_AVE, 3GLCM_INFOMEAS2_AVE, 3GLCM_JE_AVE and 3GLCM_SUMENTROPY_AVE carry Nyxus' fast_log10 approximation and so stay out of the table. tests/vetting/oracles/gen_glcm3d_pyradiomics.py re-verifies every pin at rel 1e-12 and that PyRadiomics gives the control the same values.",,bench_volmin_3d 3D,3GLCM_IV_AVE,glcm,vetted,pyradiomics,agreed,glcm3d.pyradiomics_bincount20,rel=1e-9,test_3d_glcm_pyradiomics.h;test_nyxus.py;test_3d_glcm_regression.h;test_3d_glcm_pyradiomics.py,,mirp,,audit,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20. PyRadiomics reports one value per feature over its whole direction set, which is this *_AVE aggregation over the 13 3D angles; the assertion reads the stored *_AVE feature rather than recomputing it, so a defect in how save_value populates *_AVE fails here. The 13 directional values of the base feature are asserted separately and per direction. Measured residual <= 1.2e-15.",, diff --git a/tests/vetting/oracles/gen_glcm_mirp.py b/tests/vetting/oracles/gen_glcm_mirp.py index adbb6173..ab1d248f 100644 --- a/tests/vetting/oracles/gen_glcm_mirp.py +++ b/tests/vetting/oracles/gen_glcm_mirp.py @@ -131,7 +131,7 @@ def main(): print("// MISSING from this mirp build: %s" % key) continue for feature in MIRP_TO_NYXUS[column]: - names = [feature] if feature == "GLCM_HOM2" else [feature, feature + "_AVE"] + names = [feature, feature + "_AVE"] for n in names: emitted[n] = values[key] print(' {"%s", %.17g}, // %s' % (n, values[key], column)) diff --git a/tests/vetting/oracles/gen_glcm_pyradiomics.py b/tests/vetting/oracles/gen_glcm_pyradiomics.py index 5f57e91c..8ccb26ac 100644 --- a/tests/vetting/oracles/gen_glcm_pyradiomics.py +++ b/tests/vetting/oracles/gen_glcm_pyradiomics.py @@ -95,7 +95,7 @@ def emit(values, name_map, tool_note): once for its _AVE twin - because the oracle reports the angle-averaged value, which is what _AVE holds and what averaging the 4 angled values of the base feature produces. Both names have to appear literally: the coverage report credits a feature only where a test or its table names - it. GLCM_HOM2 is the one quantity with no _AVE twin in the feature set.""" + it.""" print(tool_note) emitted = {} for oracle_name in sorted(name_map): @@ -103,7 +103,7 @@ def emit(values, name_map, tool_note): print("// MISSING from this build of the tool: %s" % oracle_name) continue for feature in name_map[oracle_name]: - names = [feature] if feature == "GLCM_HOM2" else [feature, feature + "_AVE"] + names = [feature, feature + "_AVE"] for n in names: emitted[n] = values[oracle_name] print(' {"%s", %.17g}, // %s' % (n, values[oracle_name], oracle_name)) diff --git a/tests/vetting/report_output.csv b/tests/vetting/report_output.csv index 213b9c4d..e39484e4 100644 --- a/tests/vetting/report_output.csv +++ b/tests/vetting/report_output.csv @@ -222,11 +222,14 @@ dim,family,feature,claim_status,claim_oracle,claim_recipe,claim_tolerance,claim_ 2D,neighbor,ANG_BW_NEIGHBORS_MEAN,vetted,analytic,neighbor.scene2d_radius1,abs=1e-9,agreed,bench_scene7_5roi_enclosed,TEST_NYXUS.TEST_2D_NEIGHBOR_SECOND_DISTANCE_AND_ANGLES_ANALYTIC,,,audit,analytic,test_2d_neighbor_second_distance_and_angles_analytic,,,1,0,,test_2d_neighbor_second_distance_and_angles_analytic,agree,row,audit/neighbor_2d_analytic_vetting_report.md,audit/neighbor_2d_golden_regen.md,matrix/neighbor.md,"vetted vs an independent numpy recomputation of the documented closed form on the neighborhood2d_scene_labels fixture at PIXELDISTANCE=1, recipe neighbor.scene2d_radius1; agreement 1.2e-16 worst case across the family (29 of 30 values bit-identical), asserted per ROI at abs=1e-9, SPEC 7's exact tier in test_2d_neighbor_analytic.h. The neighbour graph the closed form is evaluated on is itself vetted against CellProfiler, so this is not circular. CP cannot vet these: its AngleBetweenNeighbors is the SUBTENDED angle and its SecondClosestDistance ranges over ANY object, both different quantities. Re-measured 2026-08-20: the previous assertion was ASSERT_NEAR at 1e-4 absolute with no tolerance recorded here; an intermediate rel=1e-9 was corrected to the absolute band SPEC 7 defines. gen_neighbor_analytic.py re-verifies every pin in the header it feeds; tests/vetting/audit/neighbor_2d_analytic_vetting_report.md" 2D,neighbor,ANG_BW_NEIGHBORS_STDDEV,vetted,analytic,neighbor.scene2d_radius1,abs=1e-9,agreed,bench_scene7_5roi_enclosed,TEST_NYXUS.TEST_2D_NEIGHBOR_SECOND_DISTANCE_AND_ANGLES_ANALYTIC,,,audit,analytic,test_2d_neighbor_second_distance_and_angles_analytic,,,1,0,,test_2d_neighbor_second_distance_and_angles_analytic,agree,row,audit/neighbor_2d_analytic_vetting_report.md,audit/neighbor_2d_golden_regen.md,matrix/neighbor.md,"vetted vs an independent numpy recomputation of the documented closed form on the neighborhood2d_scene_labels fixture at PIXELDISTANCE=1, recipe neighbor.scene2d_radius1; agreement 1.2e-16 worst case across the family (29 of 30 values bit-identical), asserted per ROI at abs=1e-9, SPEC 7's exact tier in test_2d_neighbor_analytic.h. The neighbour graph the closed form is evaluated on is itself vetted against CellProfiler, so this is not circular. CP cannot vet these: its AngleBetweenNeighbors is the SUBTENDED angle and its SecondClosestDistance ranges over ANY object, both different quantities. Re-measured 2026-08-20: the previous assertion was ASSERT_NEAR at 1e-4 absolute with no tolerance recorded here; an intermediate rel=1e-9 was corrected to the absolute band SPEC 7 defines. gen_neighbor_analytic.py re-verifies every pin in the header it feeds; tests/vetting/audit/neighbor_2d_analytic_vetting_report.md" 2D,neighbor,ANG_BW_NEIGHBORS_MODE,vetted,analytic,neighbor.scene2d_radius1,abs=1e-9,agreed,bench_scene7_5roi_enclosed,TEST_NYXUS.TEST_2D_NEIGHBOR_SECOND_DISTANCE_AND_ANGLES_ANALYTIC,,,audit,analytic,test_2d_neighbor_second_distance_and_angles_analytic,,,1,0,,test_2d_neighbor_second_distance_and_angles_analytic,agree,row,audit/neighbor_2d_analytic_vetting_report.md,audit/neighbor_2d_golden_regen.md,matrix/neighbor.md,"vetted vs an independent numpy recomputation of the documented closed form on the neighborhood2d_scene_labels fixture at PIXELDISTANCE=1, recipe neighbor.scene2d_radius1; agreement 1.2e-16 worst case across the family (29 of 30 values bit-identical), asserted per ROI at abs=1e-9, SPEC 7's exact tier in test_2d_neighbor_analytic.h. The neighbour graph the closed form is evaluated on is itself vetted against CellProfiler, so this is not circular. CP cannot vet these: its AngleBetweenNeighbors is the SUBTENDED angle and its SecondClosestDistance ranges over ANY object, both different quantities. Re-measured 2026-08-20: the previous assertion was ASSERT_NEAR at 1e-4 absolute with no tolerance recorded here; an intermediate rel=1e-9 was corrected to the absolute band SPEC 7 defines. gen_neighbor_analytic.py re-verifies every pin in the header it feeds; tests/vetting/audit/neighbor_2d_analytic_vetting_report.md" -2D,glcm,GLCM_ASM,vetted,pyradiomics,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_asm_ibsi;test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics,test_2d_glcm_asm_regression,,3,1,same quantity as GLCM_ENERGY,,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"RE-VETTED regression->vetted against pyradiomics v3.0.1 and mirp on the dense phantom of test_2d_glcm_common.h (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h). The demotion stood because test_2d_glcm_matlab.h asserted this against Nyxus' own snapshot table, so the matlab claim rested on no MATLAB values; re-vetting was blocked on graycoprops, which Octave does not ship. Two IBSI-conformant tools reproducing the value at rel<=rel=1e-9 closes that without MATLAB. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A | DEMOTED vetted->regression: test_2d_glcm_matlab.h asserted this through assert_glcm_feature_regression against the Nyxus snapshot table in test_2d_glcm_regression.h, so the matlab claim rested on no MATLAB values -- the table was refreshed in 2026-06 to follow a Nyxus fix. Assertions moved into test_2d_glcm_regression.h; graycoprops goldens (SPEC 6.4) would be needed to re-vet." +2D,glcm,GLCM_ASM,vetted,pyradiomics,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_asm_ibsi;test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics,test_2d_glcm_asm_regression,test_2d_glcm_infomeas1_single_level_reports_noval_mechanics,3,1,same quantity as GLCM_ENERGY,,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"RE-VETTED regression->vetted against pyradiomics v3.0.1 and mirp on the dense phantom of test_2d_glcm_common.h (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h). The demotion stood because test_2d_glcm_matlab.h asserted this against Nyxus' own snapshot table, so the matlab claim rested on no MATLAB values; re-vetting was blocked on graycoprops, which Octave does not ship. Two IBSI-conformant tools reproducing the value at rel<=rel=1e-9 closes that without MATLAB. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A | DEMOTED vetted->regression: test_2d_glcm_matlab.h asserted this through assert_glcm_feature_regression against the Nyxus snapshot table in test_2d_glcm_regression.h, so the matlab claim rested on no MATLAB values -- the table was refreshed in 2026-06 to follow a Nyxus fix. Assertions moved into test_2d_glcm_regression.h; graycoprops goldens (SPEC 6.4) would be needed to re-vet." 2D,glcm,GLCM_ACOR,vetted,mirp,glcm.ibsi_identity,rel=1e-9,agreed,,,,MIRP/IBSI check,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_acor_ibsi;test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics,test_2d_glcm_acor_regression,,3,1,,,agree,feature,audit/glcm_2d_mirp_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | vetted vs MIRP (IBSI digital phantom, glcm_oracle/); MIRP reproduces IBSI consensus exactly and Nyxus IBSI gtest passes (ACOR 5.09, CLUSHADE 7, INFOMEAS1 -0.155, JAVE 2.14, JVAR 2.69, SUMAVERAGE 4.28); _AVE = angle-average of the vetted base" -2D,glcm,GLCM_CLUPROM,vetted,pyradiomics,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_cluprom_ibsi;test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics,test_2d_glcm_cluprom_regression,,3,1,,,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A" -2D,glcm,GLCM_CLUSHADE,vetted,mirp,glcm.ibsi_identity,rel=1e-9,agreed,,,,MIRP/IBSI check,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_clushade_ibsi;test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics,test_2d_glcm_clushade_regression,,3,1,,,agree,feature,audit/glcm_2d_mirp_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | vetted vs MIRP (IBSI digital phantom, glcm_oracle/); MIRP reproduces IBSI consensus exactly and Nyxus IBSI gtest passes (ACOR 5.09, CLUSHADE 7, INFOMEAS1 -0.155, JAVE 2.14, JVAR 2.69, SUMAVERAGE 4.28); _AVE = angle-average of the vetted base" -2D,glcm,GLCM_CLUTEND,vetted,pyradiomics,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_clutend_ibsi;test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics,test_2d_glcm_clutend_regression,,3,1,,,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A" +2D,glcm,GLCM_CLUPROM,vetted,pyradiomics,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,analytic;ibsi;mirp;pyradiomics,test_2d_glcm_cluprom_ibsi;test_2d_glcm_cluster_and_sum_variance_asymmetric_analytic;test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics,test_2d_glcm_cluprom_regression,,4,1,,,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A" +2D,glcm,GLCM_CLUPROM,vetted,analytic,glcm.analytic_default_asymmetric,rel=1e-9,agreed,bench_square5_glcm_example,TEST_NYXUS.TEST_2D_GLCM_CLUSTER_AND_SUM_VARIANCE_ASYMMETRIC_ANALYTIC,,,in-tree,analytic;ibsi;mirp;pyradiomics,test_2d_glcm_cluprom_ibsi;test_2d_glcm_cluster_and_sum_variance_asymmetric_analytic;test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics,test_2d_glcm_cluprom_regression,,4,1,,test_2d_glcm_cluster_and_sum_variance_asymmetric_analytic,agree,row,audit/glcm_2d_ibsi_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (AE86) evaluated in the test on the matrix it counts from the fixture itself, in each of the 4 angles of bench_square5_glcm_example and of its left-right mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions." +2D,glcm,GLCM_CLUSHADE,vetted,mirp,glcm.ibsi_identity,rel=1e-9,agreed,,,,MIRP/IBSI check,in-tree,analytic;ibsi;mirp;pyradiomics,test_2d_glcm_clushade_ibsi;test_2d_glcm_cluster_and_sum_variance_asymmetric_analytic;test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics,test_2d_glcm_clushade_regression,,4,1,,,agree,feature,audit/glcm_2d_mirp_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | vetted vs MIRP (IBSI digital phantom, glcm_oracle/); MIRP reproduces IBSI consensus exactly and Nyxus IBSI gtest passes (ACOR 5.09, CLUSHADE 7, INFOMEAS1 -0.155, JAVE 2.14, JVAR 2.69, SUMAVERAGE 4.28); _AVE = angle-average of the vetted base" +2D,glcm,GLCM_CLUSHADE,vetted,analytic,glcm.analytic_default_asymmetric,rel=1e-9,agreed,bench_square5_glcm_example,TEST_NYXUS.TEST_2D_GLCM_CLUSTER_AND_SUM_VARIANCE_ASYMMETRIC_ANALYTIC,,,in-tree,analytic;ibsi;mirp;pyradiomics,test_2d_glcm_clushade_ibsi;test_2d_glcm_cluster_and_sum_variance_asymmetric_analytic;test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics,test_2d_glcm_clushade_regression,,4,1,,test_2d_glcm_cluster_and_sum_variance_asymmetric_analytic,agree,row,audit/glcm_2d_ibsi_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (7NFM) evaluated in the test on the matrix it counts from the fixture itself, in each of the 4 angles of bench_square5_glcm_example and of its left-right mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions." +2D,glcm,GLCM_CLUTEND,vetted,pyradiomics,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,analytic;ibsi;mirp;pyradiomics,test_2d_glcm_cluster_and_sum_variance_asymmetric_analytic;test_2d_glcm_clutend_ibsi;test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics,test_2d_glcm_clutend_regression,,4,1,,,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A" +2D,glcm,GLCM_CLUTEND,vetted,analytic,glcm.analytic_default_asymmetric,rel=1e-9,agreed,bench_square5_glcm_example,TEST_NYXUS.TEST_2D_GLCM_CLUSTER_AND_SUM_VARIANCE_ASYMMETRIC_ANALYTIC,,,in-tree,analytic;ibsi;mirp;pyradiomics,test_2d_glcm_cluster_and_sum_variance_asymmetric_analytic;test_2d_glcm_clutend_ibsi;test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics,test_2d_glcm_clutend_regression,,4,1,,test_2d_glcm_cluster_and_sum_variance_asymmetric_analytic,agree,row,audit/glcm_2d_ibsi_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (DG8W) evaluated in the test on the matrix it counts from the fixture itself, in each of the 4 angles of bench_square5_glcm_example and of its left-right mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions." 2D,glcm,GLCM_CONTRAST,vetted,pyradiomics,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_contrast_ibsi;test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics,test_2d_glcm_contrast_regression,,3,1,,,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"RE-VETTED regression->vetted against pyradiomics v3.0.1 and mirp on the dense phantom of test_2d_glcm_common.h (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h). The demotion stood because test_2d_glcm_matlab.h asserted this against Nyxus' own snapshot table, so the matlab claim rested on no MATLAB values; re-vetting was blocked on graycoprops, which Octave does not ship. Two IBSI-conformant tools reproducing the value at rel<=rel=1e-9 closes that without MATLAB. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A | DEMOTED vetted->regression: test_2d_glcm_matlab.h asserted this through assert_glcm_feature_regression against the Nyxus snapshot table in test_2d_glcm_regression.h, so the matlab claim rested on no MATLAB values -- the table was refreshed in 2026-06 to follow a Nyxus fix. Assertions moved into test_2d_glcm_regression.h; graycoprops goldens (SPEC 6.4) would be needed to re-vet." 2D,glcm,GLCM_CORRELATION,vetted,pyradiomics,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_correlation_ibsi;test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics,test_2d_glcm_correlation_regression,,3,1,,,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"RE-VETTED regression->vetted against pyradiomics v3.0.1 and mirp on the dense phantom of test_2d_glcm_common.h (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h). The demotion stood because test_2d_glcm_matlab.h asserted this against Nyxus' own snapshot table, so the matlab claim rested on no MATLAB values; re-vetting was blocked on graycoprops, which Octave does not ship. Two IBSI-conformant tools reproducing the value at rel<=rel=1e-9 closes that without MATLAB. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A | DEMOTED vetted->regression: test_2d_glcm_matlab.h asserted this through assert_glcm_feature_regression against the Nyxus snapshot table in test_2d_glcm_regression.h, so the matlab claim rested on no MATLAB values -- the table was refreshed in 2026-06 to follow a Nyxus fix. Assertions moved into test_2d_glcm_regression.h; graycoprops goldens (SPEC 6.4) would be needed to re-vet." 2D,glcm,GLCM_DIFAVE,vetted,pyradiomics,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_difference_average_ibsi;test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics,test_2d_glcm_difference_average_regression,,3,1,,,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A" @@ -236,22 +239,26 @@ dim,family,feature,claim_status,claim_oracle,claim_recipe,claim_tolerance,claim_ 2D,glcm,GLCM_ENERGY,vetted,pyradiomics,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics,test_2d_glcm_energy_regression,,2,1,same quantity as GLCM_ASM (PyRadiomics JointEnergy / MIRP cm_energy),,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"RE-VETTED regression->vetted against pyradiomics v3.0.1 and mirp on the dense phantom of test_2d_glcm_common.h (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h). The demotion stood because test_2d_glcm_matlab.h asserted this against Nyxus' own snapshot table, so the matlab claim rested on no MATLAB values; re-vetting was blocked on graycoprops, which Octave does not ship. Two IBSI-conformant tools reproducing the value at rel<=rel=1e-9 closes that without MATLAB. | DEMOTED vetted->regression: test_2d_glcm_matlab.h asserted this through assert_glcm_feature_regression against the Nyxus snapshot table in test_2d_glcm_regression.h, so the matlab claim rested on no MATLAB values -- the table was refreshed in 2026-06 to follow a Nyxus fix. Assertions moved into test_2d_glcm_regression.h; graycoprops goldens (SPEC 6.4) would be needed to re-vet." 2D,glcm,GLCM_ENTROPY,vetted,mirp,glcm.ibsi_identity,rel=5e-3,agreed,,,,MIRP/IBSI check,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_entropy_ibsi;test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics,test_2d_glcm_entropy_regression,,3,1,"same quantity as GLCM_JE (joint entropy) | log-based: Nyxus sums through fast_log10 with an EPSILON guard, so it lands 1e-3..3e-3 from both tools instead of on them; asserted at rel=5e-3",,agree,feature,audit/glcm_2d_mirp_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=5e-3 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | FIXED (missing /sum_p normalization added to f_GLCM_HOM2/f_entropy) + vetted vs MIRP/IBSI: HOM2==IDM 0.619, ENTROPY==JE 2.05. New IBSI gtests TEST_2D_GLCM_HOM2_IBSI/ENTROPY pin it; regression goldens updated" 2D,glcm,GLCM_HOM1,vetted,pyradiomics,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics,test_2d_glcm_hom1_regression,,2,1,same quantity as GLCM_ID (PyRadiomics Id / MIRP cm_inv_diff),,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"RE-VETTED regression->vetted against pyradiomics v3.0.1 and mirp on the dense phantom of test_2d_glcm_common.h (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h). The demotion stood because test_2d_glcm_matlab.h asserted this against Nyxus' own snapshot table, so the matlab claim rested on no MATLAB values; re-vetting was blocked on graycoprops, which Octave does not ship. Two IBSI-conformant tools reproducing the value at rel<=rel=1e-9 closes that without MATLAB. | DEMOTED vetted->regression: test_2d_glcm_matlab.h asserted this through assert_glcm_feature_regression against the Nyxus snapshot table in test_2d_glcm_regression.h, so the matlab claim rested on no MATLAB values -- the table was refreshed in 2026-06 to follow a Nyxus fix. Assertions moved into test_2d_glcm_regression.h; graycoprops goldens (SPEC 6.4) would be needed to re-vet." -2D,glcm,GLCM_HOM2,vetted,mirp,glcm.ibsi_identity,rel=1e-9,agreed,,,,MIRP/IBSI check,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_hom2_ibsi,test_2d_glcm_hom2_regression,,3,1,same quantity as GLCM_IDM (PyRadiomics Idm / MIRP cm_inv_diff_mom); no _AVE twin exists,,agree,feature,audit/glcm_2d_mirp_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | FIXED (missing /sum_p normalization added to f_GLCM_HOM2/f_entropy) + vetted vs MIRP/IBSI: HOM2==IDM 0.619, ENTROPY==JE 2.05. New IBSI gtests TEST_2D_GLCM_HOM2_IBSI/ENTROPY pin it; regression goldens updated" +2D,glcm,GLCM_HOM2,vetted,mirp,glcm.ibsi_identity,rel=1e-9,agreed,,,,MIRP/IBSI check,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_hom2_ibsi,test_2d_glcm_hom2_regression,,3,1,same quantity as GLCM_IDM (PyRadiomics Idm / MIRP cm_inv_diff_mom),,agree,feature,audit/glcm_2d_mirp_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | FIXED (missing /sum_p normalization added to f_GLCM_HOM2/f_entropy) + vetted vs MIRP/IBSI: HOM2==IDM 0.619, ENTROPY==JE 2.05. New IBSI gtests TEST_2D_GLCM_HOM2_IBSI/ENTROPY pin it; regression goldens updated" 2D,glcm,GLCM_ID,vetted,pyradiomics,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_id_ibsi,test_2d_glcm_id_regression,,3,1,,,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A" 2D,glcm,GLCM_IDN,vetted,pyradiomics,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_idn_ibsi,test_2d_glcm_idn_regression,,3,1,,,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A" 2D,glcm,GLCM_IDM,vetted,pyradiomics,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_idm_ibsi,test_2d_glcm_idm_regression,,3,1,,,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A" 2D,glcm,GLCM_IDMN,vetted,pyradiomics,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_idmn_ibsi,test_2d_glcm_idmn_regression,,3,1,,,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A" -2D,glcm,GLCM_INFOMEAS1,vetted,mirp,glcm.ibsi_identity,rel=5e-3,agreed,,,,MIRP/IBSI check,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_infomeas1_ibsi,test_2d_glcm_infomeas1_regression,,3,1,"log-based: Nyxus sums through fast_log10 with an EPSILON guard, so it lands 1e-3..3e-3 from both tools instead of on them; asserted at rel=5e-3",,agree,feature,audit/glcm_2d_mirp_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=5e-3 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | vetted vs MIRP (IBSI digital phantom, glcm_oracle/); MIRP reproduces IBSI consensus exactly and Nyxus IBSI gtest passes (ACOR 5.09, CLUSHADE 7, INFOMEAS1 -0.155, JAVE 2.14, JVAR 2.69, SUMAVERAGE 4.28); _AVE = angle-average of the vetted base" +2D,glcm,GLCM_INFOMEAS1,vetted,mirp,glcm.ibsi_identity,rel=5e-3,agreed,,,,MIRP/IBSI check,in-tree,analytic;ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_infomeas1_asymmetric_analytic;test_2d_glcm_infomeas1_ibsi,test_2d_glcm_infomeas1_regression,test_2d_glcm_infomeas1_single_level_reports_noval_mechanics,4,1,"log-based: Nyxus sums through fast_log10 with an EPSILON guard, so it lands 1e-3..3e-3 from both tools instead of on them; asserted at rel=5e-3",,agree,feature,audit/glcm_2d_mirp_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=5e-3 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | vetted vs MIRP (IBSI digital phantom, glcm_oracle/); MIRP reproduces IBSI consensus exactly and Nyxus IBSI gtest passes (ACOR 5.09, CLUSHADE 7, INFOMEAS1 -0.155, JAVE 2.14, JVAR 2.69, SUMAVERAGE 4.28); _AVE = angle-average of the vetted base" +2D,glcm,GLCM_INFOMEAS1,vetted,analytic,glcm.analytic_default_asymmetric,rel=1.5e-2,agreed,bench_square5_glcm_example,TEST_NYXUS.TEST_2D_GLCM_INFOMEAS1_ASYMMETRIC_ANALYTIC,,,in-tree,analytic;ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_infomeas1_asymmetric_analytic;test_2d_glcm_infomeas1_ibsi,test_2d_glcm_infomeas1_regression,test_2d_glcm_infomeas1_single_level_reports_noval_mechanics,4,1,"log-based: Nyxus sums through fast_log10 with an EPSILON guard, so it lands 1e-3..3e-3 from both tools instead of on them; asserted at rel=5e-3",test_2d_glcm_infomeas1_asymmetric_analytic,agree,row,audit/glcm_2d_ibsi_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (R8DG) evaluated in the test on the matrix it counts from the fixture itself, in each of the 4 angles of bench_square5_glcm_example and of its left-right mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions. Nyxus' entropies take the fast_log10 approximation, so the band is the measured worst residual with margin (7.0e-3 in 2D, 1.4e-2 in 3D)." 2D,glcm,GLCM_INFOMEAS2,vetted,pyradiomics,glcm.ibsi_identity,rel=5e-3,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_infomeas2_ibsi,test_2d_glcm_infomeas2_regression,,3,1,"log-based: Nyxus sums through fast_log10 with an EPSILON guard, so it lands 1e-3..3e-3 from both tools instead of on them; asserted at rel=5e-3",,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=5e-3 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A" 2D,glcm,GLCM_IV,vetted,pyradiomics,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_iv_ibsi,test_2d_glcm_iv_regression,,3,1,,,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A" 2D,glcm,GLCM_JAVE,vetted,mirp,glcm.ibsi_identity,rel=1e-9,agreed,,,,MIRP/IBSI check,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_jave_ibsi,test_2d_glcm_jave_regression,,3,1,,,agree,feature,audit/glcm_2d_mirp_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | vetted vs MIRP (IBSI digital phantom, glcm_oracle/); MIRP reproduces IBSI consensus exactly and Nyxus IBSI gtest passes (ACOR 5.09, CLUSHADE 7, INFOMEAS1 -0.155, JAVE 2.14, JVAR 2.69, SUMAVERAGE 4.28); _AVE = angle-average of the vetted base" 2D,glcm,GLCM_JE,vetted,pyradiomics,glcm.ibsi_identity,rel=5e-3,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_je_ibsi,test_2d_glcm_je_regression,,3,1,"log-based: Nyxus sums through fast_log10 with an EPSILON guard, so it lands 1e-3..3e-3 from both tools instead of on them; asserted at rel=5e-3",,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=5e-3 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A" 2D,glcm,GLCM_JMAX,vetted,pyradiomics,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_jmax_ibsi,test_2d_glcm_jmax_regression,,3,1,,,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A" -2D,glcm,GLCM_JVAR,vetted,mirp,glcm.ibsi_identity,rel=1e-9,agreed,,,,MIRP/IBSI check,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_jvar_ibsi,test_2d_glcm_jvar_regression,,3,1,,,agree,feature,audit/glcm_2d_mirp_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | vetted vs MIRP (IBSI digital phantom, glcm_oracle/); MIRP reproduces IBSI consensus exactly and Nyxus IBSI gtest passes (ACOR 5.09, CLUSHADE 7, INFOMEAS1 -0.155, JAVE 2.14, JVAR 2.69, SUMAVERAGE 4.28); _AVE = angle-average of the vetted base" +2D,glcm,GLCM_JVAR,vetted,mirp,glcm.ibsi_identity,rel=1e-9,agreed,,,,MIRP/IBSI check,in-tree,analytic;ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_jvar_asymmetric_analytic;test_2d_glcm_jvar_ibsi,test_2d_glcm_jvar_regression,,4,1,,,agree,feature,audit/glcm_2d_mirp_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | vetted vs MIRP (IBSI digital phantom, glcm_oracle/); MIRP reproduces IBSI consensus exactly and Nyxus IBSI gtest passes (ACOR 5.09, CLUSHADE 7, INFOMEAS1 -0.155, JAVE 2.14, JVAR 2.69, SUMAVERAGE 4.28); _AVE = angle-average of the vetted base" +2D,glcm,GLCM_JVAR,vetted,analytic,glcm.analytic_default_asymmetric,rel=1e-9,agreed,bench_square5_glcm_example,TEST_NYXUS.TEST_2D_GLCM_JVAR_ASYMMETRIC_ANALYTIC,,,in-tree,analytic;ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_jvar_asymmetric_analytic;test_2d_glcm_jvar_ibsi,test_2d_glcm_jvar_regression,,4,1,,test_2d_glcm_jvar_asymmetric_analytic,agree,row,audit/glcm_2d_ibsi_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (UR99) evaluated in the test on the matrix it counts from the fixture itself, in each of the 4 angles of bench_square5_glcm_example and of its left-right mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions." 2D,glcm,GLCM_SUMAVERAGE,vetted,mirp,glcm.ibsi_identity,rel=1e-9,agreed,,,,MIRP/IBSI check,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_sum_average_ibsi,test_2d_glcm_sum_average_regression,,3,1,,,agree,feature,audit/glcm_2d_mirp_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | vetted vs MIRP (IBSI digital phantom, glcm_oracle/); MIRP reproduces IBSI consensus exactly and Nyxus IBSI gtest passes (ACOR 5.09, CLUSHADE 7, INFOMEAS1 -0.155, JAVE 2.14, JVAR 2.69, SUMAVERAGE 4.28); _AVE = angle-average of the vetted base" 2D,glcm,GLCM_SUMENTROPY,vetted,pyradiomics,glcm.ibsi_identity,rel=5e-3,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_sum_entropy_ibsi,test_2d_glcm_sum_entropy_regression,,3,1,"log-based: Nyxus sums through fast_log10 with an EPSILON guard, so it lands 1e-3..3e-3 from both tools instead of on them; asserted at rel=5e-3",,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=5e-3 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A" -2D,glcm,GLCM_SUMVARIANCE,vetted,pyradiomics,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_sum_variance_ibsi,test_2d_glcm_sum_variance_regression,,3,1,"equals GLCM_CLUTEND; PyRadiomics dropped SumVariance as that duplicate, MIRP reports it natively",,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A" -2D,glcm,GLCM_VARIANCE,vetted,ibsi,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_variance_ibsi,test_2d_glcm_variance_regression,,3,1,same quantity as GLCM_JVAR (PyRadiomics SumSquares = joint variance),,agree,feature,audit/glcm_2d_ibsi_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | IBSI has no separate variance quantity: Nyxus computes GLCM_VARIANCE as the joint variance about the grey-level marginal mean - a routine distinct from the one behind GLCM_JVAR that reaches the same quantity (measured 2.687695905 for both) - so it is asserted in test_2d_glcm_ibsi.h against the IBSI joint variance consensus UR99 = 2.69. Was vetted from an offline run only (source=tracker), with target_test naming a PyRadiomics test that does not exist; PyRadiomics has no GLCM variance feature of its own, its Sum of Squares being this same joint variance." +2D,glcm,GLCM_SUMVARIANCE,vetted,pyradiomics,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,analytic;ibsi;mirp;pyradiomics,test_2d_glcm_cluster_and_sum_variance_asymmetric_analytic;test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_sum_variance_ibsi,test_2d_glcm_sum_variance_regression,,4,1,"equals GLCM_CLUTEND; PyRadiomics dropped SumVariance as that duplicate, MIRP reports it natively",,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | test_3d_glcm_regression.h ORPHANED (not #included in test_all.cc; 26 test_3glcm_* fns never run) - left as-is per decision A" +2D,glcm,GLCM_SUMVARIANCE,vetted,analytic,glcm.analytic_default_asymmetric,rel=1e-9,agreed,bench_square5_glcm_example,TEST_NYXUS.TEST_2D_GLCM_CLUSTER_AND_SUM_VARIANCE_ASYMMETRIC_ANALYTIC,,,in-tree,analytic;ibsi;mirp;pyradiomics,test_2d_glcm_cluster_and_sum_variance_asymmetric_analytic;test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_sum_variance_ibsi,test_2d_glcm_sum_variance_regression,,4,1,"equals GLCM_CLUTEND; PyRadiomics dropped SumVariance as that duplicate, MIRP reports it natively",test_2d_glcm_cluster_and_sum_variance_asymmetric_analytic,agree,row,audit/glcm_2d_ibsi_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (OEEB) evaluated in the test on the matrix it counts from the fixture itself, in each of the 4 angles of bench_square5_glcm_example and of its left-right mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions." +2D,glcm,GLCM_VARIANCE,vetted,ibsi,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,analytic;ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_jvar_asymmetric_analytic;test_2d_glcm_variance_ibsi,test_2d_glcm_variance_regression,,4,1,same quantity as GLCM_JVAR (PyRadiomics SumSquares = joint variance),,agree,feature,audit/glcm_2d_ibsi_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | IBSI has no separate variance quantity: Nyxus computes GLCM_VARIANCE as the joint variance about the grey-level marginal mean - a routine distinct from the one behind GLCM_JVAR that reaches the same quantity (measured 2.687695905 for both) - so it is asserted in test_2d_glcm_ibsi.h against the IBSI joint variance consensus UR99 = 2.69. Was vetted from an offline run only (source=tracker), with target_test naming a PyRadiomics test that does not exist; PyRadiomics has no GLCM variance feature of its own, its Sum of Squares being this same joint variance." +2D,glcm,GLCM_VARIANCE,vetted,analytic,glcm.analytic_default_asymmetric,rel=1e-9,agreed,bench_square5_glcm_example,TEST_NYXUS.TEST_2D_GLCM_JVAR_ASYMMETRIC_ANALYTIC,,,in-tree,analytic;ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_jvar_asymmetric_analytic;test_2d_glcm_variance_ibsi,test_2d_glcm_variance_regression,,4,1,same quantity as GLCM_JVAR (PyRadiomics SumSquares = joint variance),test_2d_glcm_jvar_asymmetric_analytic,agree,row,audit/glcm_2d_ibsi_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted equal at rel=1e-12 to GLCM_JVAR, which test_2d_glcm_jvar_asymmetric_analytic checks against the IBSI joint variance (UR99) evaluated in the test on the matrix it counts from the fixture itself, in each of the 4 angles of bench_square5_glcm_example and of its left-right mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions." 2D,glcm,GLCM_ASM_AVE,vetted,pyradiomics,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_asm_ave_ibsi;test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics,test_2d_glcm_asm_ave_regression,,3,1,"angle average; the tools report one value over the angle set, so it shares its base feature's golden",,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"RE-VETTED regression->vetted against pyradiomics v3.0.1 and mirp on the dense phantom of test_2d_glcm_common.h (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h). The demotion stood because test_2d_glcm_matlab.h asserted this against Nyxus' own snapshot table, so the matlab claim rested on no MATLAB values; re-vetting was blocked on graycoprops, which Octave does not ship. Two IBSI-conformant tools reproducing the value at rel<=rel=1e-9 closes that without MATLAB. | DEMOTED vetted->regression: test_2d_glcm_matlab.h asserted this through assert_glcm_feature_regression against the Nyxus snapshot table in test_2d_glcm_regression.h, so the matlab claim rested on no MATLAB values -- the table was refreshed in 2026-06 to follow a Nyxus fix. Assertions moved into test_2d_glcm_regression.h; graycoprops goldens (SPEC 6.4) would be needed to re-vet." 2D,glcm,GLCM_ACOR_AVE,vetted,mirp,glcm.ibsi_identity,rel=1e-9,agreed,,,,MIRP/IBSI check,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_acor_ave_ibsi;test_2d_glcm_acor_family_pyradiomics;test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics,test_2d_glcm_acor_ave_regression,,4,1,"angle average; the tools report one value over the angle set, so it shares its base feature's golden",,agree,feature,audit/glcm_2d_mirp_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | vetted vs MIRP (IBSI digital phantom, glcm_oracle/); MIRP reproduces IBSI consensus exactly and Nyxus IBSI gtest passes (ACOR 5.09, CLUSHADE 7, INFOMEAS1 -0.155, JAVE 2.14, JVAR 2.69, SUMAVERAGE 4.28); _AVE = angle-average of the vetted base" 2D,glcm,GLCM_CLUPROM_AVE,vetted,ibsi,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_cluprom_ave_ibsi;test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics,test_2d_glcm_cluprom_ave_regression,,3,1,"angle average; the tools report one value over the angle set, so it shares its base feature's golden",,agree,feature,audit/glcm_2d_ibsi_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | Asserted in test_2d_glcm_ibsi.h against the IBSI consensus for CLUPROM (AE86) (= 79.1): that consensus is quoted for the 2D-averaged aggregation, so it is the golden of the angle average itself, and the _AVE feature reproduces its base feature's 4-angle mean exactly (both 79.11263068). Was vetted from an offline run only (source=tracker), with nothing in the tree asserting the angle-averaging step." @@ -268,7 +275,8 @@ dim,family,feature,claim_status,claim_oracle,claim_recipe,claim_tolerance,claim_ 2D,glcm,GLCM_HOM1_AVE,vetted,pyradiomics,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics,test_2d_glcm_hom1_ave_regression,,2,1,"angle average; the tools report one value over the angle set, so it shares its base feature's golden",,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"RE-VETTED regression->vetted against pyradiomics v3.0.1 and mirp on the dense phantom of test_2d_glcm_common.h (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h). The demotion stood because test_2d_glcm_matlab.h asserted this against Nyxus' own snapshot table, so the matlab claim rested on no MATLAB values; re-vetting was blocked on graycoprops, which Octave does not ship. Two IBSI-conformant tools reproducing the value at rel<=rel=1e-9 closes that without MATLAB. | DEMOTED vetted->regression: test_2d_glcm_matlab.h asserted this through assert_glcm_feature_regression against the Nyxus snapshot table in test_2d_glcm_regression.h, so the matlab claim rested on no MATLAB values -- the table was refreshed in 2026-06 to follow a Nyxus fix. Assertions moved into test_2d_glcm_regression.h; graycoprops goldens (SPEC 6.4) would be needed to re-vet." 2D,glcm,GLCM_ID_AVE,vetted,ibsi,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_id_ave_ibsi,test_2d_glcm_id_ave_regression,,3,1,"angle average; the tools report one value over the angle set, so it shares its base feature's golden",,agree,feature,audit/glcm_2d_ibsi_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | Asserted in test_2d_glcm_ibsi.h against the IBSI consensus for ID (IB1Z) (= 0.678): that consensus is quoted for the 2D-averaged aggregation, so it is the golden of the angle average itself, and the _AVE feature reproduces its base feature's 4-angle mean exactly (both 0.6779485416). Was vetted from an offline run only (source=tracker), with nothing in the tree asserting the angle-averaging step." 2D,glcm,GLCM_IDN_AVE,vetted,pyradiomics,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_acor_family_pyradiomics;test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_idn_ave_ibsi,test_2d_glcm_idn_ave_regression,,4,1,"angle average; the tools report one value over the angle set, so it shares its base feature's golden",,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against." -2D,glcm,GLCM_IDM_AVE,vetted,ibsi,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_idm_ave_ibsi,test_2d_glcm_idm_ave_regression,,3,1,"angle average; the tools report one value over the angle set, so it shares its base feature's golden",,agree,feature,audit/glcm_2d_ibsi_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | Asserted in test_2d_glcm_ibsi.h against the IBSI consensus for IDM (WF0Z) (= 0.619): that consensus is quoted for the 2D-averaged aggregation, so it is the golden of the angle average itself, and the _AVE feature reproduces its base feature's 4-angle mean exactly (both 0.6187370709). Was vetted from an offline run only (source=tracker), with nothing in the tree asserting the angle-averaging step." +2D,glcm,GLCM_IDM_AVE,vetted,ibsi,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_idm_ave_ibsi,test_2d_glcm_idm_ave_regression,test_2d_glcm_hom2_ave_mechanics,3,1,"angle average; the tools report one value over the angle set, so it shares its base feature's golden",,agree,feature,audit/glcm_2d_ibsi_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | Asserted in test_2d_glcm_ibsi.h against the IBSI consensus for IDM (WF0Z) (= 0.619): that consensus is quoted for the 2D-averaged aggregation, so it is the golden of the angle average itself, and the _AVE feature reproduces its base feature's 4-angle mean exactly (both 0.6187370709). Was vetted from an offline run only (source=tracker), with nothing in the tree asserting the angle-averaging step." +2D,glcm,GLCM_HOM2_AVE,vetted,ibsi,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_hom2_ave_ibsi,test_2d_glcm_hom2_ave_regression,,3,1,"angle average; the tools report one value over the angle set, so it shares its base feature's golden",,agree,feature,audit/glcm_2d_ibsi_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against pyradiomics v3.0.1 and MIRP on the dense phantom of test_2d_glcm_common.h at rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h). | Homogeneity 2 is the inverse difference moment, so its angle average is asserted in test_2d_glcm_ibsi.h against the IBSI consensus for IDM (WF0Z, 0.619) and against Idm / cm_inv_diff_mom in the two tool tables; test_2d_glcm_hom2_ave_mechanics holds it equal to the mean of the four GLCM_HOM2 angles and to GLCM_IDM_AVE." 2D,glcm,GLCM_IDMN_AVE,vetted,pyradiomics,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_acor_family_pyradiomics;test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_idmn_ave_ibsi,test_2d_glcm_idmn_ave_regression,,4,1,"angle average; the tools report one value over the angle set, so it shares its base feature's golden",,agree,feature,audit/glcm_2d_pyradiomics_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against mirp on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against." 2D,glcm,GLCM_IV_AVE,vetted,ibsi,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_iv_ave_ibsi,test_2d_glcm_iv_ave_regression,,3,1,"angle average; the tools report one value over the angle set, so it shares its base feature's golden",,agree,feature,audit/glcm_2d_ibsi_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | Asserted in test_2d_glcm_ibsi.h against the IBSI consensus for IV (E8JP) (= 0.0567): that consensus is quoted for the 2D-averaged aggregation, so it is the golden of the angle average itself, and the _AVE feature reproduces its base feature's 4-angle mean exactly (both 0.05669828975). Was vetted from an offline run only (source=tracker), with nothing in the tree asserting the angle-averaging step." 2D,glcm,GLCM_JAVE_AVE,vetted,ibsi,glcm.ibsi_identity,rel=1e-9,agreed,,,,,in-tree,ibsi;mirp;pyradiomics,test_2d_glcm_family_mirp;test_2d_glcm_family_pyradiomics;test_2d_glcm_jave_ave_ibsi,test_2d_glcm_jave_ave_regression,,3,1,"angle average; the tools report one value over the angle set, so it shares its base feature's golden",,agree,feature,audit/glcm_2d_ibsi_vetting_report.md,audit/glcm_2d_golden_regen.md,matrix/glcm.md,"Also asserted against pyradiomics v3.0.1 on the dense phantom of test_2d_glcm_common.h at rel<=rel=1e-9 (test_2d_glcm_pyradiomics.h, test_2d_glcm_mirp.h), so the oracle this row names is one the tree actually compares against. | Asserted in test_2d_glcm_ibsi.h against the IBSI consensus for JAVE (60VM) (= 2.14): that consensus is quoted for the 2D-averaged aggregation, so it is the golden of the angle average itself, and the _AVE feature reproduces its base feature's 4-angle mean exactly (both 2.142418606). Was vetted from an offline run only (source=tracker), with nothing in the tree asserting the angle-averaging step. | vetted vs MIRP (IBSI digital phantom, glcm_oracle/); MIRP reproduces IBSI consensus exactly and Nyxus IBSI gtest passes (ACOR 5.09, CLUSHADE 7, INFOMEAS1 -0.155, JAVE 2.14, JVAR 2.69, SUMAVERAGE 4.28); _AVE = angle-average of the vetted base" @@ -751,10 +759,13 @@ dim,family,feature,claim_status,claim_oracle,claim_recipe,claim_tolerance,claim_ 3D,morphology,3MESH_VOLUME,vetted,analytic,morphology3d.analytic_lattice_solids,rel=1e-12,agreed,,,,,in-tree,analytic;mirp;pyradiomics,test_3d_morphology_aniso_mesh_volume_pyradiomics;test_3d_morphology_mesh_volume_mirp;test_3d_morphology_single_voxel_mesh_analytic;test_3d_morphology_zero_intensity_hull_analytic,,,4,0,"IBSI volume (mesh) = MIRP morph_volume 274338.3438, pinned at rel=1e-6; also pinned against closed-form solids in the analytic file. MATLAB regionprops3 carries no mesh volume, so it holds no row for this feature",,agree,feature,audit/morphology_3d_mirp_vetting_report.md,audit/morphology_3d_golden_regen.md,,"vetted vs closed-form geometry, recipe morphology3d.analytic_lattice_solids, asserted in test_3d_morphology_analytic.h. A single voxel's 0.5-isolevel surface is the octahedron with vertices half a lattice step out (volume 1/6) and a solid w x h x d box is a bevelled box whose volume is an exact function of w, h and d, in both the general and the whole-volume (SINGLEROI) branch; a box with zero intensities gives the same. Every golden holds at rel=1e-12. No external tool is involved, so this row is independent of the MIRP row on the same feature. The shapes separate the conventions outright: counting voxels returns 1 for the single voxel against 1/6. Scope: ROIs whose surface has no ambiguous face (two diagonal corners inside); the phantom has none, so no value assertion reaches the 120 case-table entries that depart from the classic triangulation." 3D,morphology,3VOLUME_CONVEXHULL,vetted,analytic,morphology3d.analytic_lattice_solids,rel=1e-12,agreed,,,,,in-tree,analytic;matlab;mirp,test_3d_morphology_lattice_hull_volume_analytic;test_3d_morphology_planar_hull_volume_analytic;test_3d_morphology_single_voxel_mesh_analytic;test_3d_morphology_volume_convex_hull_matlab;test_3d_morphology_volume_convex_hull_mirp;test_3d_morphology_zero_intensity_hull_analytic,test_3d_morphology_volume_convex_hull_regression,,6,1,"hull of the mesh vertices = MIRP's hull 496958.3201, pinned at rel=1e-6; MATLAB regionprops3 ConvexVolume 497824 counts the rasterised hull, asserted at 0.174% in a 0.5% band; also pinned at rel=1e-12 against boxes, octahedra and rhombic prisms in the analytic file",,agree,feature,audit/morphology_3d_mirp_vetting_report.md,audit/morphology_3d_golden_regen.md,,"vetted vs closed-form geometry, recipe morphology3d.analytic_lattice_solids, asserted in test_3d_morphology_analytic.h through D3_SurfaceFeature. 3VOLUME_CONVEXHULL is the volume of the convex hull of the mesh vertices, each an in-ROI voxel moved half a step towards an out-of-ROI neighbour, so on a lattice solid whose extreme voxels are known it is exact: the single voxel (1/6) and the w x h x d box (the bevelled box, in both SINGLEROI settings) are their own hulls, the octahedron |x|+|y|+|z| <= R gives 4/3 (R+1/2)^3 (R = 3, 8, 15), and the rhombic prism |x|+|y| <= R, |z| <= H gives a prism of radius R+1/2 and height 2H with two frusta of height 1/2 (R = 4, 12; H = R/2+1). A one-slice ROI gives its bevelled slab, and a box with zero intensities the uniform box's value. The solids sit hundreds of voxels from the origin and every volume holds at rel=1e-12; qhull over the same vertices reproduces each to 5e-16. No external tool is involved, so this row is independent of the MIRP and MATLAB rows on the same feature. The quick_hull kernel under the feature is checked predicate by predicate in test_3d_morphology_mechanics.h, which is mechanics and claims no vetting. Scope: ROIs whose surface has no ambiguous face (two diagonal corners inside); the phantom has none, so no value assertion reaches the 120 case-table entries that depart from the classic triangulation." 3D,glcm,3GLCM_ACOR,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,pyradiomics,test_3d_glcm_acor_ave_pyradiomics;test_3d_glcm_acor_pyradiomics,test_3d_glcm_acor_regression,,2,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." -3D,glcm,3GLCM_ASM,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,pyradiomics,test_3d_glcm_asm_ave_pyradiomics;test_3d_glcm_asm_pyradiomics;test_3d_glcm_ave_equivalence_pyradiomics;test_3d_glcm_equivalence_dump_pyradiomics,test_3d_glcm_asm_regression,,4,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." -3D,glcm,3GLCM_CLUPROM,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,pyradiomics,test_3d_glcm_cluprom_ave_pyradiomics;test_3d_glcm_cluprom_pyradiomics,test_3d_glcm_cluprom_regression,,2,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." -3D,glcm,3GLCM_CLUSHADE,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,pyradiomics,test_3d_glcm_clushade_ave_pyradiomics;test_3d_glcm_clushade_pyradiomics,test_3d_glcm_clushade_regression,,2,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." -3D,glcm,3GLCM_CLUTEND,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,pyradiomics,test_3d_glcm_ave_equivalence_pyradiomics;test_3d_glcm_clutend_ave_pyradiomics;test_3d_glcm_clutend_pyradiomics;test_3d_glcm_equivalence_dump_pyradiomics,test_3d_glcm_clutend_regression,,4,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." +3D,glcm,3GLCM_ASM,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,pyradiomics,test_3d_glcm_asm_ave_pyradiomics;test_3d_glcm_asm_pyradiomics;test_3d_glcm_ave_equivalence_pyradiomics;test_3d_glcm_equivalence_dump_pyradiomics,test_3d_glcm_asm_regression,test_3d_glcm_infomeas1_single_level_reports_noval_mechanics,4,1,also asserted by test_3d_glcm_infomeas1_single_level_reports_noval_mechanics (kind is neither oracle nor regression),,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." +3D,glcm,3GLCM_CLUPROM,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,analytic;pyradiomics,test_3d_glcm_cluprom_ave_pyradiomics;test_3d_glcm_cluprom_pyradiomics;test_3d_glcm_cluster_and_sum_variance_asymmetric_analytic,test_3d_glcm_cluprom_regression,,3,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." +3D,glcm,3GLCM_CLUPROM,vetted,analytic,glcm3d.analytic_default_asymmetric,rel=1e-9,agreed,bench_box5x5x3_glcm_asymmetric,TEST_NYXUS.TEST_3D_GLCM_CLUSTER_AND_SUM_VARIANCE_ASYMMETRIC_ANALYTIC,,,in-tree,analytic;pyradiomics,test_3d_glcm_cluprom_ave_pyradiomics;test_3d_glcm_cluprom_pyradiomics;test_3d_glcm_cluster_and_sum_variance_asymmetric_analytic,test_3d_glcm_cluprom_regression,,3,1,,test_3d_glcm_cluster_and_sum_variance_asymmetric_analytic,agree,row,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (AE86) evaluated in the test on the matrix it counts from the fixture itself, in each of the 13 directions of bench_box5x5x3_glcm_asymmetric and of its x-mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions." +3D,glcm,3GLCM_CLUSHADE,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,analytic;pyradiomics,test_3d_glcm_clushade_ave_pyradiomics;test_3d_glcm_clushade_pyradiomics;test_3d_glcm_cluster_and_sum_variance_asymmetric_analytic,test_3d_glcm_clushade_regression,,3,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." +3D,glcm,3GLCM_CLUSHADE,vetted,analytic,glcm3d.analytic_default_asymmetric,rel=1e-9,agreed,bench_box5x5x3_glcm_asymmetric,TEST_NYXUS.TEST_3D_GLCM_CLUSTER_AND_SUM_VARIANCE_ASYMMETRIC_ANALYTIC,,,in-tree,analytic;pyradiomics,test_3d_glcm_clushade_ave_pyradiomics;test_3d_glcm_clushade_pyradiomics;test_3d_glcm_cluster_and_sum_variance_asymmetric_analytic,test_3d_glcm_clushade_regression,,3,1,,test_3d_glcm_cluster_and_sum_variance_asymmetric_analytic,agree,row,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (7NFM) evaluated in the test on the matrix it counts from the fixture itself, in each of the 13 directions of bench_box5x5x3_glcm_asymmetric and of its x-mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions." +3D,glcm,3GLCM_CLUTEND,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,analytic;pyradiomics,test_3d_glcm_ave_equivalence_pyradiomics;test_3d_glcm_cluster_and_sum_variance_asymmetric_analytic;test_3d_glcm_clutend_ave_pyradiomics;test_3d_glcm_clutend_pyradiomics;test_3d_glcm_equivalence_dump_pyradiomics,test_3d_glcm_clutend_regression,,5,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." +3D,glcm,3GLCM_CLUTEND,vetted,analytic,glcm3d.analytic_default_asymmetric,rel=1e-9,agreed,bench_box5x5x3_glcm_asymmetric,TEST_NYXUS.TEST_3D_GLCM_CLUSTER_AND_SUM_VARIANCE_ASYMMETRIC_ANALYTIC,,,in-tree,analytic;pyradiomics,test_3d_glcm_ave_equivalence_pyradiomics;test_3d_glcm_cluster_and_sum_variance_asymmetric_analytic;test_3d_glcm_clutend_ave_pyradiomics;test_3d_glcm_clutend_pyradiomics;test_3d_glcm_equivalence_dump_pyradiomics,test_3d_glcm_clutend_regression,,5,1,,test_3d_glcm_cluster_and_sum_variance_asymmetric_analytic,agree,row,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (DG8W) evaluated in the test on the matrix it counts from the fixture itself, in each of the 13 directions of bench_box5x5x3_glcm_asymmetric and of its x-mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions." 3D,glcm,3GLCM_CONTRAST,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,pyradiomics,test_3d_glcm_contrast_ave_pyradiomics;test_3d_glcm_contrast_pyradiomics,test_3d_glcm_contrast_regression,,2,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." 3D,glcm,3GLCM_CORRELATION,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,pyradiomics,test_3d_glcm_correlation_ave_pyradiomics;test_3d_glcm_correlation_pyradiomics,test_3d_glcm_correlation_regression,,2,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." 3D,glcm,3GLCM_DIFAVE,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,pyradiomics,test_3d_glcm_ave_equivalence_pyradiomics;test_3d_glcm_difave_ave_pyradiomics;test_3d_glcm_difference_average_pyradiomics;test_3d_glcm_equivalence_dump_pyradiomics,test_3d_glcm_difference_average_regression,,4,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." @@ -767,19 +778,23 @@ dim,family,feature,claim_status,claim_oracle,claim_recipe,claim_tolerance,claim_ 3D,glcm,3GLCM_HOM2,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,"pyradiomics/mirp (DIS=DifferenceAverage, HOM1=Id, HOM2=Idm, SUMVAR=ClusterTendency, ENERGY=JointEnergy=ASM, VAR=mirp cm_var); CONFIG-SENSITIVE: symmetric+13dir vs Nyxus asym/1-offset/100lvl",audit,pyradiomics,test_3d_glcm_equivalence_dump_pyradiomics,test_3d_glcm_hom2_grey64_regression,,1,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." 3D,glcm,3GLCM_ID,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,pyradiomics,test_3d_glcm_ave_equivalence_pyradiomics;test_3d_glcm_equivalence_dump_pyradiomics;test_3d_glcm_id_ave_pyradiomics;test_3d_glcm_id_pyradiomics,test_3d_glcm_id_regression,,4,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." 3D,glcm,3GLCM_IDN,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,pyradiomics,test_3d_glcm_idn_ave_pyradiomics;test_3d_glcm_idn_pyradiomics,test_3d_glcm_idn_regression,,2,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." -3D,glcm,3GLCM_IDM,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,pyradiomics,test_3d_glcm_equivalence_dump_pyradiomics;test_3d_glcm_idm_ave_pyradiomics;test_3d_glcm_idm_pyradiomics,test_3d_glcm_idm_regression,,3,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." +3D,glcm,3GLCM_IDM,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,pyradiomics,test_3d_glcm_ave_equivalence_pyradiomics;test_3d_glcm_equivalence_dump_pyradiomics;test_3d_glcm_hom2_ave_pyradiomics;test_3d_glcm_idm_ave_pyradiomics;test_3d_glcm_idm_pyradiomics,test_3d_glcm_idm_regression,,5,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." 3D,glcm,3GLCM_IDMN,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,pyradiomics,test_3d_glcm_idmn_ave_pyradiomics;test_3d_glcm_idmn_pyradiomics,test_3d_glcm_idmn_regression,,2,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." -3D,glcm,3GLCM_INFOMEAS1,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=4e-2,agreed,,,,,audit,pyradiomics,test_3d_glcm_infomeas1_ave_pyradiomics;test_3d_glcm_infomeas1_pyradiomics,test_3d_glcm_infomeas1_regression,,2,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is 1.7e-2. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only). That band is Nyxus' fast_log10 (helpers.h), a float-precision log2 approximation used by every entropy-family GLCM feature, not a convention difference." +3D,glcm,3GLCM_INFOMEAS1,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=4e-2,agreed,,,,,audit,analytic;pyradiomics,test_3d_glcm_infomeas1_asymmetric_analytic;test_3d_glcm_infomeas1_ave_pyradiomics;test_3d_glcm_infomeas1_pyradiomics,test_3d_glcm_infomeas1_regression,test_3d_glcm_infomeas1_single_level_reports_noval_mechanics,3,1,also asserted by test_3d_glcm_infomeas1_single_level_reports_noval_mechanics (kind is neither oracle nor regression),,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is 1.7e-2. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only). That band is Nyxus' fast_log10 (helpers.h), a float-precision log2 approximation used by every entropy-family GLCM feature, not a convention difference." +3D,glcm,3GLCM_INFOMEAS1,vetted,analytic,glcm3d.analytic_default_asymmetric,rel=2e-2,agreed,bench_box5x5x3_glcm_asymmetric,TEST_NYXUS.TEST_3D_GLCM_INFOMEAS1_ASYMMETRIC_ANALYTIC,,,in-tree,analytic;pyradiomics,test_3d_glcm_infomeas1_asymmetric_analytic;test_3d_glcm_infomeas1_ave_pyradiomics;test_3d_glcm_infomeas1_pyradiomics,test_3d_glcm_infomeas1_regression,test_3d_glcm_infomeas1_single_level_reports_noval_mechanics,3,1,also asserted by test_3d_glcm_infomeas1_single_level_reports_noval_mechanics (kind is neither oracle nor regression),test_3d_glcm_infomeas1_asymmetric_analytic,agree,row,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (R8DG) evaluated in the test on the matrix it counts from the fixture itself, in each of the 13 directions of bench_box5x5x3_glcm_asymmetric and of its x-mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions. Nyxus' entropies take the fast_log10 approximation, so the band is the measured worst residual with margin (7.0e-3 in 2D, 1.4e-2 in 3D)." 3D,glcm,3GLCM_INFOMEAS2,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=2e-2,agreed,,,,,audit,pyradiomics,test_3d_glcm_infomeas2_ave_pyradiomics;test_3d_glcm_infomeas2_pyradiomics,test_3d_glcm_infomeas2_regression,,2,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is 7.7e-3. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only). That band is Nyxus' fast_log10 (helpers.h), a float-precision log2 approximation used by every entropy-family GLCM feature, not a convention difference." 3D,glcm,3GLCM_IV,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,pyradiomics,test_3d_glcm_iv_ave_pyradiomics;test_3d_glcm_iv_pyradiomics,test_3d_glcm_iv_regression,,2,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." 3D,glcm,3GLCM_JAVE,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,pyradiomics,test_3d_glcm_jave_ave_pyradiomics;test_3d_glcm_jave_pyradiomics,test_3d_glcm_jave_regression,,2,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." 3D,glcm,3GLCM_JE,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-3,agreed,,,,,audit,pyradiomics,test_3d_glcm_ave_equivalence_pyradiomics;test_3d_glcm_equivalence_dump_pyradiomics;test_3d_glcm_je_ave_pyradiomics;test_3d_glcm_je_pyradiomics,test_3d_glcm_je_regression,,4,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is 4.1e-4. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only). That band is Nyxus' fast_log10 (helpers.h), a float-precision log2 approximation used by every entropy-family GLCM feature, not a convention difference." 3D,glcm,3GLCM_JMAX,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,pyradiomics,test_3d_glcm_jmax_ave_pyradiomics;test_3d_glcm_jmax_pyradiomics,test_3d_glcm_jmax_regression,,2,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." -3D,glcm,3GLCM_JVAR,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,pyradiomics,test_3d_glcm_ave_equivalence_pyradiomics;test_3d_glcm_equivalence_dump_pyradiomics;test_3d_glcm_jvar_ave_pyradiomics;test_3d_glcm_jvar_pyradiomics,test_3d_glcm_jvar_regression,,4,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." +3D,glcm,3GLCM_JVAR,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,analytic;pyradiomics,test_3d_glcm_ave_equivalence_pyradiomics;test_3d_glcm_equivalence_dump_pyradiomics;test_3d_glcm_jvar_asymmetric_analytic;test_3d_glcm_jvar_ave_pyradiomics;test_3d_glcm_jvar_pyradiomics,test_3d_glcm_jvar_regression,,5,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." +3D,glcm,3GLCM_JVAR,vetted,analytic,glcm3d.analytic_default_asymmetric,rel=1e-9,agreed,bench_box5x5x3_glcm_asymmetric,TEST_NYXUS.TEST_3D_GLCM_JVAR_ASYMMETRIC_ANALYTIC,,,in-tree,analytic;pyradiomics,test_3d_glcm_ave_equivalence_pyradiomics;test_3d_glcm_equivalence_dump_pyradiomics;test_3d_glcm_jvar_asymmetric_analytic;test_3d_glcm_jvar_ave_pyradiomics;test_3d_glcm_jvar_pyradiomics,test_3d_glcm_jvar_regression,,5,1,,test_3d_glcm_jvar_asymmetric_analytic,agree,row,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (UR99) evaluated in the test on the matrix it counts from the fixture itself, in each of the 13 directions of bench_box5x5x3_glcm_asymmetric and of its x-mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions." 3D,glcm,3GLCM_SUMAVERAGE,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,pyradiomics,test_3d_glcm_sum_average_pyradiomics;test_3d_glcm_sumaverage_ave_pyradiomics,test_3d_glcm_sum_average_regression,,2,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." 3D,glcm,3GLCM_SUMENTROPY,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=2e-3,agreed,,,,,audit,pyradiomics,test_3d_glcm_sum_entropy_pyradiomics;test_3d_glcm_sumentropy_ave_pyradiomics,test_3d_glcm_sum_entropy_regression,,2,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is 7.6e-4. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only). That band is Nyxus' fast_log10 (helpers.h), a float-precision log2 approximation used by every entropy-family GLCM feature, not a convention difference." -3D,glcm,3GLCM_SUMVARIANCE,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,"pyradiomics/mirp (DIS=DifferenceAverage, HOM1=Id, HOM2=Idm, SUMVAR=ClusterTendency, ENERGY=JointEnergy=ASM, VAR=mirp cm_var); CONFIG-SENSITIVE: symmetric+13dir vs Nyxus asym/1-offset/100lvl",audit,pyradiomics,test_3d_glcm_equivalence_dump_pyradiomics,test_3d_glcm_sum_variance_regression;test_3d_glcm_sumvariance_grey64_regression,,1,2,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." -3D,glcm,3GLCM_VARIANCE,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,"pyradiomics/mirp (DIS=DifferenceAverage, HOM1=Id, HOM2=Idm, SUMVAR=ClusterTendency, ENERGY=JointEnergy=ASM, VAR=mirp cm_var); CONFIG-SENSITIVE: symmetric+13dir vs Nyxus asym/1-offset/100lvl",audit,pyradiomics,test_3d_glcm_equivalence_dump_pyradiomics,test_3d_glcm_variance_grey64_regression,,1,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." +3D,glcm,3GLCM_SUMVARIANCE,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,"pyradiomics/mirp (DIS=DifferenceAverage, HOM1=Id, HOM2=Idm, SUMVAR=ClusterTendency, ENERGY=JointEnergy=ASM, VAR=mirp cm_var); CONFIG-SENSITIVE: symmetric+13dir vs Nyxus asym/1-offset/100lvl",audit,analytic;pyradiomics,test_3d_glcm_cluster_and_sum_variance_asymmetric_analytic;test_3d_glcm_equivalence_dump_pyradiomics,test_3d_glcm_sum_variance_regression;test_3d_glcm_sumvariance_grey64_regression,,2,2,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." +3D,glcm,3GLCM_SUMVARIANCE,vetted,analytic,glcm3d.analytic_default_asymmetric,rel=1e-9,agreed,bench_box5x5x3_glcm_asymmetric,TEST_NYXUS.TEST_3D_GLCM_CLUSTER_AND_SUM_VARIANCE_ASYMMETRIC_ANALYTIC,,,in-tree,analytic;pyradiomics,test_3d_glcm_cluster_and_sum_variance_asymmetric_analytic;test_3d_glcm_equivalence_dump_pyradiomics,test_3d_glcm_sum_variance_regression;test_3d_glcm_sumvariance_grey64_regression,,2,2,,test_3d_glcm_cluster_and_sum_variance_asymmetric_analytic,agree,row,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (OEEB) evaluated in the test on the matrix it counts from the fixture itself, in each of the 13 directions of bench_box5x5x3_glcm_asymmetric and of its x-mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions." +3D,glcm,3GLCM_VARIANCE,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,"pyradiomics/mirp (DIS=DifferenceAverage, HOM1=Id, HOM2=Idm, SUMVAR=ClusterTendency, ENERGY=JointEnergy=ASM, VAR=mirp cm_var); CONFIG-SENSITIVE: symmetric+13dir vs Nyxus asym/1-offset/100lvl",audit,analytic;pyradiomics,test_3d_glcm_equivalence_dump_pyradiomics;test_3d_glcm_jvar_asymmetric_analytic,test_3d_glcm_variance_grey64_regression,,2,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20, PER DIRECTION: the assertion in test_3d_glcm_pyradiomics.h compares all 13 directional values of this feature against PyRadiomics' own per-angle values (glcm_3d_pyradiomics_ref_vals_by_angle), not the average of them - an average agrees whenever per-direction errors cancel. Both sides are symmetric here (Nyxus symmetrises under radiomics grey binning, 3d_glcm.cpp), so the measured residual is <= 1.2e-15. Goldens and the angle mapping from gen_glcm3d_pyradiomics.py. test_3d_glcm_regression.h pins Nyxus' own values on a different phantom and bin count and claims no oracle (drift guard only)." +3D,glcm,3GLCM_VARIANCE,vetted,analytic,glcm3d.analytic_default_asymmetric,rel=1e-9,agreed,bench_box5x5x3_glcm_asymmetric,TEST_NYXUS.TEST_3D_GLCM_JVAR_ASYMMETRIC_ANALYTIC,,,in-tree,analytic;pyradiomics,test_3d_glcm_equivalence_dump_pyradiomics;test_3d_glcm_jvar_asymmetric_analytic,test_3d_glcm_variance_grey64_regression,,2,1,,test_3d_glcm_jvar_asymmetric_analytic,agree,row,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"Default MATLAB-style binning at 64 levels, an asymmetric co-occurrence matrix: asserted against the IBSI definition (UR99) evaluated in the test on the matrix it counts from the fixture itself, in each of the 13 directions of bench_box5x5x3_glcm_asymmetric and of its x-mirror. PyRadiomics with symmetricalGLCM=False agrees with that reference to 3e-15 on the 2D and 3D fixtures, for the features it reports under these definitions." 3D,glcm,3GLCM_ASM_AVE,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,mirp,audit,analytic;pyradiomics,test_3d_glcm_asm_ave_pyradiomics;test_3d_glcm_ave_equivalence_pyradiomics;test_3d_glcm_matlab_background_analytic;test_3d_glcm_matlab_box_analytic;test_3d_glcm_volmin_pyradiomics,test_3d_glcm_asm_ave_grey64_regression,test_3d_glcm_compatibility,5,1,also asserted by test_3d_glcm_compatibility (kind is neither oracle nor regression),,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20. PyRadiomics reports one value per feature over its whole direction set, which is this *_AVE aggregation over the 13 3D angles; the assertion reads the stored *_AVE feature rather than recomputing it, so a defect in how save_value populates *_AVE fails here. The 13 directional values of the base feature are asserted separately and per direction. Measured residual <= 1.2e-15." 3D,glcm,3GLCM_ASM_AVE,vetted,pyradiomics,glcm3d.pyradiomics_volmin_bincount8,rel=1e-9,agreed,bench_volmin_3d,,,,in-tree,analytic;pyradiomics,test_3d_glcm_asm_ave_pyradiomics;test_3d_glcm_ave_equivalence_pyradiomics;test_3d_glcm_matlab_background_analytic;test_3d_glcm_matlab_box_analytic;test_3d_glcm_volmin_pyradiomics,test_3d_glcm_asm_ave_grey64_regression,test_3d_glcm_compatibility,5,1,also asserted by test_3d_glcm_compatibility (kind is neither oracle nor regression),,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on bench_volmin_3d, recipe glcm3d.pyradiomics_volmin_bincount8: Nyxus coarse_gray_depth=-8, PyRadiomics-style binning (IBSI's fixed bin number over the ROI's own [min, max]), against PyRadiomics binCount=8, label 1, no resampling, weightingNorm=None, force2D=False -- each tool discretising for itself. The ROI holds the volume's lowest intensity, which Nyxus stores as 0, the value the background cells of its bounding box hold; under this binning those voxels are the ROI's bin 1. The same table holds on the control bench_volmin_ctrl_3d, whose ROI is stored without a 0, and both run in RAM and out of core (an OME-TIFF Z-stack streamed at ram_limit=0). A family that bins a stored 0 to level 0 reads those voxels as background, or shifts every level by one, and parts from the table on bench_volmin_3d while it still holds on the control. PyRadiomics reports one value over its 13 directions, which is this *_AVE aggregation. Asserted at rel=1e-9 by test_3d_glcm_volmin_pyradiomics in tests/python/test_3d_glcm_pyradiomics.py, a pytest case, so test_name is empty; the logarithmic 3GLCM_DIFENTRO_AVE, 3GLCM_INFOMEAS1_AVE, 3GLCM_INFOMEAS2_AVE, 3GLCM_JE_AVE and 3GLCM_SUMENTROPY_AVE carry Nyxus' fast_log10 approximation and so stay out of the table. tests/vetting/oracles/gen_glcm3d_pyradiomics.py re-verifies every pin at rel 1e-12 and that PyRadiomics gives the control the same values." 3D,glcm,3GLCM_ASM_AVE,vetted,analytic,glcm3d.analytic_matlab_background,rel=1e-9,agreed,bench_ellipsoid6x40x40_boxbg_3d,,,,in-tree,analytic;pyradiomics,test_3d_glcm_asm_ave_pyradiomics;test_3d_glcm_ave_equivalence_pyradiomics;test_3d_glcm_matlab_background_analytic;test_3d_glcm_matlab_box_analytic;test_3d_glcm_volmin_pyradiomics,test_3d_glcm_asm_ave_grey64_regression,test_3d_glcm_compatibility,5,1,also asserted by test_3d_glcm_compatibility (kind is neither oracle nor regression),,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs the definition at recipe glcm3d.analytic_matlab_background: MATLAB-style binning at the default coarse grey depth 64 on bench_ellipsoid6x40x40_boxbg_3d, an ellipsoid ROI whose bounding box has background in it, in RAM and out of core. The reference, evaluated in numpy inside the test, counts for each of the 13 offsets at distance 1 the ordered pairs of ROI voxels by their MATLAB levels, floor(64 x / max + 1) clipped to 1..64, and takes ASM (sum p^2) of each normalised matrix, averaged over the 13. A family that reads the bounding box's background as level 1 counts every ROI-background pair and parts from it on the ellipsoid; test_3d_glcm_matlab_box_analytic, a ROI that fills its bounding box, is the negative case that holds either way. Asserted at rel=1e-9 by test_3d_glcm_matlab_background_analytic in tests/python/test_3d_glcm_analytic.py, a pytest case, so test_name is empty." @@ -809,8 +824,9 @@ dim,family,feature,claim_status,claim_oracle,claim_recipe,claim_tolerance,claim_ 3D,glcm,3GLCM_ID_AVE,vetted,pyradiomics,glcm3d.pyradiomics_volmin_bincount8,rel=1e-9,agreed,bench_volmin_3d,,,,in-tree,pyradiomics,test_3d_glcm_ave_equivalence_pyradiomics;test_3d_glcm_id_ave_pyradiomics;test_3d_glcm_volmin_pyradiomics,test_3d_glcm_id_ave_grey64_regression,test_3d_glcm_compatibility,3,1,also asserted by test_3d_glcm_compatibility (kind is neither oracle nor regression),,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on bench_volmin_3d, recipe glcm3d.pyradiomics_volmin_bincount8: Nyxus coarse_gray_depth=-8, PyRadiomics-style binning (IBSI's fixed bin number over the ROI's own [min, max]), against PyRadiomics binCount=8, label 1, no resampling, weightingNorm=None, force2D=False -- each tool discretising for itself. The ROI holds the volume's lowest intensity, which Nyxus stores as 0, the value the background cells of its bounding box hold; under this binning those voxels are the ROI's bin 1. The same table holds on the control bench_volmin_ctrl_3d, whose ROI is stored without a 0, and both run in RAM and out of core (an OME-TIFF Z-stack streamed at ram_limit=0). A family that bins a stored 0 to level 0 reads those voxels as background, or shifts every level by one, and parts from the table on bench_volmin_3d while it still holds on the control. PyRadiomics reports one value over its 13 directions, which is this *_AVE aggregation. Asserted at rel=1e-9 by test_3d_glcm_volmin_pyradiomics in tests/python/test_3d_glcm_pyradiomics.py, a pytest case, so test_name is empty; the logarithmic 3GLCM_DIFENTRO_AVE, 3GLCM_INFOMEAS1_AVE, 3GLCM_INFOMEAS2_AVE, 3GLCM_JE_AVE and 3GLCM_SUMENTROPY_AVE carry Nyxus' fast_log10 approximation and so stay out of the table. tests/vetting/oracles/gen_glcm3d_pyradiomics.py re-verifies every pin at rel 1e-12 and that PyRadiomics gives the control the same values." 3D,glcm,3GLCM_IDN_AVE,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,pyradiomics,test_3d_glcm_idn_ave_pyradiomics;test_3d_glcm_volmin_pyradiomics,test_3d_glcm_idn_ave_grey64_regression,test_3d_glcm_compatibility,2,1,also asserted by test_3d_glcm_compatibility (kind is neither oracle nor regression),,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20. PyRadiomics reports one value per feature over its whole direction set, which is this *_AVE aggregation over the 13 3D angles; the assertion reads the stored *_AVE feature rather than recomputing it, so a defect in how save_value populates *_AVE fails here. The 13 directional values of the base feature are asserted separately and per direction. Measured residual <= 1.2e-15." 3D,glcm,3GLCM_IDN_AVE,vetted,pyradiomics,glcm3d.pyradiomics_volmin_bincount8,rel=1e-9,agreed,bench_volmin_3d,,,,in-tree,pyradiomics,test_3d_glcm_idn_ave_pyradiomics;test_3d_glcm_volmin_pyradiomics,test_3d_glcm_idn_ave_grey64_regression,test_3d_glcm_compatibility,2,1,also asserted by test_3d_glcm_compatibility (kind is neither oracle nor regression),,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on bench_volmin_3d, recipe glcm3d.pyradiomics_volmin_bincount8: Nyxus coarse_gray_depth=-8, PyRadiomics-style binning (IBSI's fixed bin number over the ROI's own [min, max]), against PyRadiomics binCount=8, label 1, no resampling, weightingNorm=None, force2D=False -- each tool discretising for itself. The ROI holds the volume's lowest intensity, which Nyxus stores as 0, the value the background cells of its bounding box hold; under this binning those voxels are the ROI's bin 1. The same table holds on the control bench_volmin_ctrl_3d, whose ROI is stored without a 0, and both run in RAM and out of core (an OME-TIFF Z-stack streamed at ram_limit=0). A family that bins a stored 0 to level 0 reads those voxels as background, or shifts every level by one, and parts from the table on bench_volmin_3d while it still holds on the control. PyRadiomics reports one value over its 13 directions, which is this *_AVE aggregation. Asserted at rel=1e-9 by test_3d_glcm_volmin_pyradiomics in tests/python/test_3d_glcm_pyradiomics.py, a pytest case, so test_name is empty; the logarithmic 3GLCM_DIFENTRO_AVE, 3GLCM_INFOMEAS1_AVE, 3GLCM_INFOMEAS2_AVE, 3GLCM_JE_AVE and 3GLCM_SUMENTROPY_AVE carry Nyxus' fast_log10 approximation and so stay out of the table. tests/vetting/oracles/gen_glcm3d_pyradiomics.py re-verifies every pin at rel 1e-12 and that PyRadiomics gives the control the same values." -3D,glcm,3GLCM_IDM_AVE,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,mirp,audit,pyradiomics,test_3d_glcm_idm_ave_pyradiomics;test_3d_glcm_volmin_pyradiomics,test_3d_glcm_idm_ave_grey64_regression,test_3d_glcm_compatibility,2,1,also asserted by test_3d_glcm_compatibility (kind is neither oracle nor regression),,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20. PyRadiomics reports one value per feature over its whole direction set, which is this *_AVE aggregation over the 13 3D angles; the assertion reads the stored *_AVE feature rather than recomputing it, so a defect in how save_value populates *_AVE fails here. The 13 directional values of the base feature are asserted separately and per direction. Measured residual <= 1.2e-15." -3D,glcm,3GLCM_IDM_AVE,vetted,pyradiomics,glcm3d.pyradiomics_volmin_bincount8,rel=1e-9,agreed,bench_volmin_3d,,,,in-tree,pyradiomics,test_3d_glcm_idm_ave_pyradiomics;test_3d_glcm_volmin_pyradiomics,test_3d_glcm_idm_ave_grey64_regression,test_3d_glcm_compatibility,2,1,also asserted by test_3d_glcm_compatibility (kind is neither oracle nor regression),,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on bench_volmin_3d, recipe glcm3d.pyradiomics_volmin_bincount8: Nyxus coarse_gray_depth=-8, PyRadiomics-style binning (IBSI's fixed bin number over the ROI's own [min, max]), against PyRadiomics binCount=8, label 1, no resampling, weightingNorm=None, force2D=False -- each tool discretising for itself. The ROI holds the volume's lowest intensity, which Nyxus stores as 0, the value the background cells of its bounding box hold; under this binning those voxels are the ROI's bin 1. The same table holds on the control bench_volmin_ctrl_3d, whose ROI is stored without a 0, and both run in RAM and out of core (an OME-TIFF Z-stack streamed at ram_limit=0). A family that bins a stored 0 to level 0 reads those voxels as background, or shifts every level by one, and parts from the table on bench_volmin_3d while it still holds on the control. PyRadiomics reports one value over its 13 directions, which is this *_AVE aggregation. Asserted at rel=1e-9 by test_3d_glcm_volmin_pyradiomics in tests/python/test_3d_glcm_pyradiomics.py, a pytest case, so test_name is empty; the logarithmic 3GLCM_DIFENTRO_AVE, 3GLCM_INFOMEAS1_AVE, 3GLCM_INFOMEAS2_AVE, 3GLCM_JE_AVE and 3GLCM_SUMENTROPY_AVE carry Nyxus' fast_log10 approximation and so stay out of the table. tests/vetting/oracles/gen_glcm3d_pyradiomics.py re-verifies every pin at rel 1e-12 and that PyRadiomics gives the control the same values." +3D,glcm,3GLCM_IDM_AVE,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,mirp,audit,pyradiomics,test_3d_glcm_ave_equivalence_pyradiomics;test_3d_glcm_idm_ave_pyradiomics;test_3d_glcm_volmin_pyradiomics,test_3d_glcm_idm_ave_grey64_regression,test_3d_glcm_compatibility,3,1,also asserted by test_3d_glcm_compatibility (kind is neither oracle nor regression),,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20. PyRadiomics reports one value per feature over its whole direction set, which is this *_AVE aggregation over the 13 3D angles; the assertion reads the stored *_AVE feature rather than recomputing it, so a defect in how save_value populates *_AVE fails here. The 13 directional values of the base feature are asserted separately and per direction. Measured residual <= 1.2e-15." +3D,glcm,3GLCM_IDM_AVE,vetted,pyradiomics,glcm3d.pyradiomics_volmin_bincount8,rel=1e-9,agreed,bench_volmin_3d,,,,in-tree,pyradiomics,test_3d_glcm_ave_equivalence_pyradiomics;test_3d_glcm_idm_ave_pyradiomics;test_3d_glcm_volmin_pyradiomics,test_3d_glcm_idm_ave_grey64_regression,test_3d_glcm_compatibility,3,1,also asserted by test_3d_glcm_compatibility (kind is neither oracle nor regression),,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on bench_volmin_3d, recipe glcm3d.pyradiomics_volmin_bincount8: Nyxus coarse_gray_depth=-8, PyRadiomics-style binning (IBSI's fixed bin number over the ROI's own [min, max]), against PyRadiomics binCount=8, label 1, no resampling, weightingNorm=None, force2D=False -- each tool discretising for itself. The ROI holds the volume's lowest intensity, which Nyxus stores as 0, the value the background cells of its bounding box hold; under this binning those voxels are the ROI's bin 1. The same table holds on the control bench_volmin_ctrl_3d, whose ROI is stored without a 0, and both run in RAM and out of core (an OME-TIFF Z-stack streamed at ram_limit=0). A family that bins a stored 0 to level 0 reads those voxels as background, or shifts every level by one, and parts from the table on bench_volmin_3d while it still holds on the control. PyRadiomics reports one value over its 13 directions, which is this *_AVE aggregation. Asserted at rel=1e-9 by test_3d_glcm_volmin_pyradiomics in tests/python/test_3d_glcm_pyradiomics.py, a pytest case, so test_name is empty; the logarithmic 3GLCM_DIFENTRO_AVE, 3GLCM_INFOMEAS1_AVE, 3GLCM_INFOMEAS2_AVE, 3GLCM_JE_AVE and 3GLCM_SUMENTROPY_AVE carry Nyxus' fast_log10 approximation and so stay out of the table. tests/vetting/oracles/gen_glcm3d_pyradiomics.py re-verifies every pin at rel 1e-12 and that PyRadiomics gives the control the same values." +3D,glcm,3GLCM_HOM2_AVE,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,mirp,audit,pyradiomics,test_3d_glcm_ave_equivalence_pyradiomics;test_3d_glcm_hom2_ave_pyradiomics,test_3d_glcm_hom2_ave_grey64_regression,,2,1,,,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20. Homogeneity 2 is PyRadiomics' Idm, so test_3d_glcm_hom2_ave_pyradiomics reads the stored *_AVE feature against Idm's direction-set value, and test_3d_glcm_ave_equivalence_pyradiomics holds it equal to 3GLCM_IDM_AVE. test_3d_glcm_regression.h pins Nyxus' own value at the grey64 profile (drift guard only)." 3D,glcm,3GLCM_IDMN_AVE,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,,audit,pyradiomics,test_3d_glcm_idmn_ave_pyradiomics;test_3d_glcm_volmin_pyradiomics,test_3d_glcm_idmn_ave_grey64_regression,test_3d_glcm_compatibility,2,1,also asserted by test_3d_glcm_compatibility (kind is neither oracle nor regression),,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20. PyRadiomics reports one value per feature over its whole direction set, which is this *_AVE aggregation over the 13 3D angles; the assertion reads the stored *_AVE feature rather than recomputing it, so a defect in how save_value populates *_AVE fails here. The 13 directional values of the base feature are asserted separately and per direction. Measured residual <= 1.2e-15." 3D,glcm,3GLCM_IDMN_AVE,vetted,pyradiomics,glcm3d.pyradiomics_volmin_bincount8,rel=1e-9,agreed,bench_volmin_3d,,,,in-tree,pyradiomics,test_3d_glcm_idmn_ave_pyradiomics;test_3d_glcm_volmin_pyradiomics,test_3d_glcm_idmn_ave_grey64_regression,test_3d_glcm_compatibility,2,1,also asserted by test_3d_glcm_compatibility (kind is neither oracle nor regression),,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on bench_volmin_3d, recipe glcm3d.pyradiomics_volmin_bincount8: Nyxus coarse_gray_depth=-8, PyRadiomics-style binning (IBSI's fixed bin number over the ROI's own [min, max]), against PyRadiomics binCount=8, label 1, no resampling, weightingNorm=None, force2D=False -- each tool discretising for itself. The ROI holds the volume's lowest intensity, which Nyxus stores as 0, the value the background cells of its bounding box hold; under this binning those voxels are the ROI's bin 1. The same table holds on the control bench_volmin_ctrl_3d, whose ROI is stored without a 0, and both run in RAM and out of core (an OME-TIFF Z-stack streamed at ram_limit=0). A family that bins a stored 0 to level 0 reads those voxels as background, or shifts every level by one, and parts from the table on bench_volmin_3d while it still holds on the control. PyRadiomics reports one value over its 13 directions, which is this *_AVE aggregation. Asserted at rel=1e-9 by test_3d_glcm_volmin_pyradiomics in tests/python/test_3d_glcm_pyradiomics.py, a pytest case, so test_name is empty; the logarithmic 3GLCM_DIFENTRO_AVE, 3GLCM_INFOMEAS1_AVE, 3GLCM_INFOMEAS2_AVE, 3GLCM_JE_AVE and 3GLCM_SUMENTROPY_AVE carry Nyxus' fast_log10 approximation and so stay out of the table. tests/vetting/oracles/gen_glcm3d_pyradiomics.py re-verifies every pin at rel 1e-12 and that PyRadiomics gives the control the same values." 3D,glcm,3GLCM_IV_AVE,vetted,pyradiomics,glcm3d.pyradiomics_bincount20,rel=1e-9,agreed,,,,mirp,audit,pyradiomics,test_3d_glcm_iv_ave_pyradiomics;test_3d_glcm_volmin_pyradiomics,test_3d_glcm_iv_ave_grey64_regression,test_3d_glcm_compatibility,2,1,also asserted by test_3d_glcm_compatibility (kind is neither oracle nor regression),,agree,feature,audit/glcm_3d_pyradiomics_vetting_report.md,audit/glcm_3d_golden_regen.md,,"vetted vs PyRadiomics 3.0.1 on the compat phantom, recipe glcm3d.pyradiomics_bincount20. PyRadiomics reports one value per feature over its whole direction set, which is this *_AVE aggregation over the 13 3D angles; the assertion reads the stored *_AVE feature rather than recomputing it, so a defect in how save_value populates *_AVE fails here. The 13 directional values of the base feature are asserted separately and per direction. Measured residual <= 1.2e-15." diff --git a/tests/vetting/report_output.md b/tests/vetting/report_output.md index 128b5ed6..3f221f5d 100644 --- a/tests/vetting/report_output.md +++ b/tests/vetting/report_output.md @@ -8,14 +8,14 @@ what [`oracle_coverage.csv`](oracle_coverage.csv) CLAIMS to what the test tree A ## Coverage -Features vetted by >=1 oracle: 646/758 (85%) +Features vetted by >=1 oracle: 648/760 (85%) regression: 112 invariant: 0 untested: 0 | family | total | vetted | regression | invariant | untested | |---|---|---|---|---|---| | firstorder | 72 | 67 | 5 | 0 | 0 | | gabor | 1 | 1 | 0 | 0 | 0 | -| glcm | 118 | 118 | 0 | 0 | 0 | +| glcm | 120 | 120 | 0 | 0 | 0 | | gldm | 28 | 28 | 0 | 0 | 0 | | gldzm | 36 | 32 | 4 | 0 | 0 | | glrlm | 64 | 64 | 0 | 0 | 0 | @@ -32,11 +32,11 @@ regression: 112 invariant: 0 untested: 0 ## Verdicts -1263 of 1263 assertion rows agree with the tree. +1279 of 1279 assertion rows agree with the tree. | verdict | rows | meaning | |---|---:|---| -| `agree` | 1263 | the claim and the tree say the same thing | +| `agree` | 1279 | the claim and the tree say the same thing | ### How far each verdict reaches @@ -45,8 +45,8 @@ regression: 112 invariant: 0 untested: 0 | scope | rows | what was compared | |---|---:|---| -| `feature` | 640 | `test_name` is empty, so the tree was read for the feature and not for this row's own assertion | -| `row` | 388 | the case named in `test_name` asserts this feature, at this row's kind; its configuration is unchecked, the family declaring no recipe reader | +| `feature` | 642 | `test_name` is empty, so the tree was read for the feature and not for this row's own assertion | +| `row` | 402 | the case named in `test_name` asserts this feature, at this row's kind; its configuration is unchecked, the family declaring no recipe reader | | `row+config` | 235 | the case named in `test_name` asserts this feature at this `config_recipe` | ## Every oracle a feature was matched against @@ -59,7 +59,7 @@ that alone understates every family that corroborates. |---|---|---|---|---|---|---|---|---|---|---|---|---| | 2D | firstorder | 9 | . | . | 13 | . | 31 | . | . | 18 | . | 2 | | 2D | gabor | . | . | . | . | . | . | . | . | . | 1 | . | -| 2D | glcm | . | . | . | 55 | . | . | 59 | . | 59 | . | . | +| 2D | glcm | 7 | . | . | 56 | . | . | 60 | . | 60 | . | . | | 2D | gldm | . | . | . | 14 | . | . | . | . | 14 | . | . | | 2D | gldzm | . | . | . | 14 | . | . | 16 | . | . | . | 2 | | 2D | glrlm | 14 | . | . | 32 | . | . | 32 | . | 32 | . | . | @@ -73,7 +73,7 @@ that alone understates every family that corroborates. | 2D | radial | . | . | . | . | . | . | . | . | . | . | 3 | | 2D | zernike | 1 | . | . | . | . | . | . | . | . | . | . | | 3D | firstorder | 9 | . | . | . | . | 29 | . | . | 17 | . | 3 | -| 3D | glcm | 2 | . | . | . | . | . | . | . | 59 | . | . | +| 3D | glcm | 9 | . | . | . | . | . | . | . | 60 | . | . | | 3D | gldm | . | . | . | . | . | . | . | . | 14 | . | . | | 3D | gldzm | . | . | . | . | . | . | 16 | . | . | . | 2 | | 3D | glrlm | 14 | . | . | . | . | . | . | . | 32 | . | . | @@ -82,14 +82,14 @@ that alone understates every family that corroborates. | 3D | ngldm | . | . | . | . | . | . | 16 | . | . | . | 3 | | 3D | ngtdm | . | . | . | . | . | . | 5 | . | 5 | . | . | | IMQ | imq | 1 | 2 | . | . | . | . | . | 2 | . | . | 2 | -| | **all** | **103** | **10** | **2** | **182** | **20** | **95** | **219** | **3** | **275** | **127** | **112** | +| | **all** | **117** | **10** | **2** | **183** | **20** | **95** | **220** | **3** | **277** | **127** | **112** | ## By dimensionality | dim | features | vetted | scanned | no oracle assertion | unscanned | |---|---:|---:|---:|---:|---:| -| 2D | 539 | 437 | 539 | 102 | 0 | -| 3D | 213 | 205 | 213 | 8 | 0 | +| 2D | 540 | 438 | 540 | 102 | 0 | +| 3D | 214 | 206 | 214 | 8 | 0 | | IMQ | 6 | 4 | 6 | 2 | 0 | ## Reading a row