Correlation of Ranks (corr_ranks)

import math

from pyxla import load_data, corr_ranks
from pyxla.sampling import HilbertCurveSampler
sphere_sample = {
    "name": "Sphere",
    "X": HilbertCurveSampler(sample_size=100, dim=1, l_bound=-5, u_bound=5, seed=42),
    "F": lambda x: x**2,
    "V": [lambda x: x**2 - 2, lambda x: 8 * math.sin(20 * x)]
}

load_data(sphere_sample)
WARNING:root:The Hilbert curve with dimension 1 is just a number line. You are sampling around points on a number line.
corrs, plot = corr_ranks(sphere_sample)
/home/toni/Projects/pyxla-wg/src/pyxla/__init__.py:376: ConstantInputWarning: An input array is constant; the correlation coefficient is not defined.
  cor, _ = spearmanr(x, y)
../../_images/1ccecc4d07048002911a2a494e461975de6f39289e27e430e408671a40df0c8b.png
corrs
{'v0_f0 (feasible)': 'undefined',
 'v0_f0 (infeasible)': '1.00',
 'v1_f0 (feasible)': 'undefined',
 'v1_f0 (infeasible)': '-0.28',
 'paretoV_f0 (feasible)': 'undefined',
 'paretoV_f0 (infeasible)': '0.94',
 'Deb_f0 (feasible)': '1.00',
 'Deb_f0 (infeasible)': '0.94',
 'paretoFV_f0 (feasible)': '1.00',
 'paretoFV_f0 (infeasible)': '1.00',
 'v1_v0 (feasible)': 'undefined',
 'v1_v0 (infeasible)': '-0.28',
 'paretoV_v0 (feasible)': 'undefined',
 'paretoV_v0 (infeasible)': '0.94',
 'Deb_v0 (feasible)': 'undefined',
 'Deb_v0 (infeasible)': '0.95',
 'paretoFV_v0 (feasible)': 'undefined',
 'paretoFV_v0 (infeasible)': '1.00',
 'paretoV_v1 (feasible)': 'undefined',
 'paretoV_v1 (infeasible)': '-0.08',
 'Deb_v1 (feasible)': 'undefined',
 'Deb_v1 (infeasible)': '-0.11',
 'paretoFV_v1 (feasible)': 'undefined',
 'paretoFV_v1 (infeasible)': '-0.26',
 'Deb_paretoV (feasible)': 'undefined',
 'Deb_paretoV (infeasible)': '1.00',
 'paretoFV_paretoV (feasible)': 'undefined',
 'paretoFV_paretoV (infeasible)': '0.94',
 'paretoFV_Deb (feasible)': '1.00',
 'paretoFV_Deb (infeasible)': '0.95'}