diff options
author | vrouvrea <vrouvrea@636b058d-ea47-450e-bf9e-a15bfbe3eedb> | 2016-11-25 16:00:19 +0000 |
---|---|---|
committer | vrouvrea <vrouvrea@636b058d-ea47-450e-bf9e-a15bfbe3eedb> | 2016-11-25 16:00:19 +0000 |
commit | af146a2e48c16855355ac599cbc617250727d244 (patch) | |
tree | bab3117c6886f41ec9d2a1869bc70105ecdd63b3 /src/cython/example/alpha_complex_diagram_persistence_from_off_file_example.py | |
parent | f843ef3f8e4ab4ce94a28ded6d8cafd37f2b2311 (diff) |
Add of tangential complex doc
Separate simplex tree from alpha complex
git-svn-id: svn+ssh://scm.gforge.inria.fr/svnroot/gudhi/branches/ST_cythonize@1788 636b058d-ea47-450e-bf9e-a15bfbe3eedb
Former-commit-id: 1cf4a35e0a099501eb1cb6b9809041dd1a1e2617
Diffstat (limited to 'src/cython/example/alpha_complex_diagram_persistence_from_off_file_example.py')
-rwxr-xr-x | src/cython/example/alpha_complex_diagram_persistence_from_off_file_example.py | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/cython/example/alpha_complex_diagram_persistence_from_off_file_example.py b/src/cython/example/alpha_complex_diagram_persistence_from_off_file_example.py index d74eba57..40d06f93 100755 --- a/src/cython/example/alpha_complex_diagram_persistence_from_off_file_example.py +++ b/src/cython/example/alpha_complex_diagram_persistence_from_off_file_example.py @@ -52,15 +52,17 @@ with open(args.file, 'r') as f: message = "AlphaComplex with max_edge_length=" + repr(args.max_alpha_square) print(message) - alpha_complex = gudhi.AlphaComplex(off_file=args.file, max_alpha_square=args.max_alpha_square) + alpha_complex = gudhi.AlphaComplex(off_file=args.file) + simplex_tree = gudhi.SimplexTree() + alpha_complex.create_simplex_tree(simplex_tree, max_alpha_square=args.max_alpha_square) - message = "Number of simplices=" + repr(alpha_complex.num_simplices()) + message = "Number of simplices=" + repr(simplex_tree.num_simplices()) print(message) - diag = alpha_complex.persistence() + diag = simplex_tree.persistence() print("betti_numbers()=") - print(alpha_complex.betti_numbers()) + print(simplex_tree.betti_numbers()) if args.no_diagram == False: gudhi.diagram_persistence(diag) |