Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def test_bottleneck_matching(self):
dgm1 = np.array([
[0.1, 0.2],
[0.2, 0.4]
])
dgm2 = np.array([
[0.1, 0.2],
[0.3, 0.45]
])
d, (matching, D) = persim.bottleneck(dgm1, dgm2, matching=True)
persim.bottleneck_matching(dgm1, dgm2, matching, D)
def test_plot_labels(self):
dgm1 = np.array([
[0.1, 0.2],
[0.2, 0.4]
])
dgm2 = np.array([
[0.1, 0.2],
[0.3, 0.45]
])
d, (matching, D) = persim.bottleneck(dgm1, dgm2, matching=True)
persim.bottleneck_matching(
dgm1, dgm2, matching, D, labels=["X", "Y"])