Skip to content

Persistence diagram and wasserstein distance using ripser vs torch_topological #41

Open
@AmeerHamza96

Description

@AmeerHamza96

Hello,

  1. I have used ripser and torch_topological libraries to compute cubical persistence of the same image but the two two diagrams are different.
  2. About the wasserstein distance, I have tried to input same persistence diagram to persim.wasserstein and torch_topological.nn.wasserstein distance with same setting but the answers are different.

Can you please guide me what is the reason behind this? Am I doing something wrong? Is there a way to resolve this issue?

Ripser/Persim
"diagram1 = np.array([[0., 1.]])
diagram2 = np.array([[0., 1.],
[0., 1.]])
distance = persim.wasserstein(diagram2, diagram1)
output: Wasserstein distance: 0.7071067811865476"

with torch_topological
I got "tensor(0.5000)"

Thanks in advance.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions