Re: Bottleneck distance is not symmetric

nukpezah@...
 
Edited

Dear Dmitriy,
I am also running into the same issue and am not sure why. I computed pairwise bottleneck distances for 21 different NMR structures of a protein and realized that the distances are not symmetric also which should not be. I am running the code in a Jupyter notebook in Ubuntu. So I decided to test the code on Dmitriy's website for diagram distances and still running into same issues. This is the code below;
import numpy as np
import dionysus as d
f1 = d.fill_rips(np.random.random((20, 2)), 2, 1)
m1 = d.homology_persistence(f1)
dgms1 = d.init_diagrams(m1, f1)
f2 = d.fill_rips(np.random.random((20, 2)), 2, 1)
m2 = d.homology_persistence(f2)
dgms2 = d.init_diagrams(m2, f2)
bdist1 = d.bottleneck_distance(dgms1[1], dgms2[1])
print("Bottleneck distance between 1-dimensional persistence diagrams:", bdist1)
bdist2 = d.bottleneck_distance(dgms2[1], dgms1[1])
print("Bottleneck distance between 1-dimensional persistence diagrams:", bdist2)

Bottleneck distance between 1-dimensional persistence diagrams: 0.050108347088098526
Bottleneck distance between 1-dimensional persistence diagrams: 0.04992149770259857

Thanks for any help!
I am running dionysus ver 2.06 in Ubuntu 18.04.1 LTS
Sincerely
Jonathan

Join dionysus@groups.io to automatically receive all group messages.