diff options
author | vrouvrea <vrouvrea@636b058d-ea47-450e-bf9e-a15bfbe3eedb> | 2016-07-01 16:03:35 +0000 |
---|---|---|
committer | vrouvrea <vrouvrea@636b058d-ea47-450e-bf9e-a15bfbe3eedb> | 2016-07-01 16:03:35 +0000 |
commit | 5ac39620529111d16e81ca8fec645228359d10e2 (patch) | |
tree | 25efc373a0567298b24fa5d7dc86c7caf04729ac /src/cython | |
parent | 569b7265b27ee5a2a9b1f9f41bd1dc3c74221a27 (diff) |
Last sphinx modifications
git-svn-id: svn+ssh://scm.gforge.inria.fr/svnroot/gudhi/branches/ST_cythonize@1380 636b058d-ea47-450e-bf9e-a15bfbe3eedb
Former-commit-id: 7c7315dcf3fb211451948b67ceba499b6b7e98ca
Diffstat (limited to 'src/cython')
-rw-r--r-- | src/cython/doc/source/alpha_complex_ref.rst | 9 | ||||
-rw-r--r-- | src/cython/doc/source/alpha_complex_user.rst | 8 | ||||
-rw-r--r-- | src/cython/doc/source/cubical_complex_ref.rst | 9 | ||||
-rw-r--r-- | src/cython/doc/source/cubical_complex_user.rst | 8 | ||||
-rw-r--r-- | src/cython/doc/source/index.rst | 81 | ||||
-rw-r--r-- | src/cython/src/cpp/Alpha_complex_interface.h | 4 | ||||
-rw-r--r-- | src/cython/src/cpp/Cubical_complex_interface.h | 4 | ||||
-rw-r--r-- | src/cython/src/cython/alpha_complex.pyx | 15 | ||||
-rw-r--r-- | src/cython/src/cython/cubical_complex.pyx | 22 |
9 files changed, 125 insertions, 35 deletions
diff --git a/src/cython/doc/source/alpha_complex_ref.rst b/src/cython/doc/source/alpha_complex_ref.rst new file mode 100644 index 00000000..ab81eee0 --- /dev/null +++ b/src/cython/doc/source/alpha_complex_ref.rst @@ -0,0 +1,9 @@ +Alpha complex reference manual +############################## + +.. autoclass:: gudhi.AlphaComplex + :members: + :undoc-members: + :show-inheritance: + + .. automethod:: gudhi.AlphaComplex.__init__ diff --git a/src/cython/doc/source/alpha_complex_user.rst b/src/cython/doc/source/alpha_complex_user.rst new file mode 100644 index 00000000..3b445d13 --- /dev/null +++ b/src/cython/doc/source/alpha_complex_user.rst @@ -0,0 +1,8 @@ +Alpha complex user manual +######################### + +blablabla + +.. image:: img/alpha_complex_representation.png + :align: center + diff --git a/src/cython/doc/source/cubical_complex_ref.rst b/src/cython/doc/source/cubical_complex_ref.rst new file mode 100644 index 00000000..84aa4223 --- /dev/null +++ b/src/cython/doc/source/cubical_complex_ref.rst @@ -0,0 +1,9 @@ +Cubical complex reference manual +################################ + +.. autoclass:: gudhi.CubicalComplex + :members: + :undoc-members: + :show-inheritance: + + .. automethod:: gudhi.CubicalComplex.__init__ diff --git a/src/cython/doc/source/cubical_complex_user.rst b/src/cython/doc/source/cubical_complex_user.rst new file mode 100644 index 00000000..7ade4b86 --- /dev/null +++ b/src/cython/doc/source/cubical_complex_user.rst @@ -0,0 +1,8 @@ +Cubical complex user manual +########################### + +blablabla + +.. image:: img/Cubical_complex_representation.png + :align: center + diff --git a/src/cython/doc/source/index.rst b/src/cython/doc/source/index.rst index 7dfea239..d08b465c 100644 --- a/src/cython/doc/source/index.rst +++ b/src/cython/doc/source/index.rst @@ -38,27 +38,68 @@ Data structures Alpha complex ============= -.. image:: img/alpha_complex_representation.png - :align: center - -Alpha_complex is a simplicial complex constructed from the finite cells of a -Delaunay Triangulation. - -The filtration value of each simplex is computed as the square of the -circumradius of the simplex if the circumsphere is empty (the simplex is then -said to be Gabriel), and as the minimum of the filtration values of the -codimension 1 cofaces that make it not Gabriel otherwise. All simplices that -have a filtration value strictly greater than a given alpha squared value are -not inserted into the complex. - -This package requires having CGAL version 4.7 or higher (4.8.1 is advised for -better perfomances). +===================================== ===================================== ===================================== +:Author: Vincent Rouvreau :Introduced in: GUDHI PYTHON 1.4.0 :Copyright: GPL v3 +===================================== ===================================== ===================================== + ++-------------------------------------------+----------------------------------------------------------------------+ +| .. image:: | Alpha_complex is a simplicial complex constructed from the finite | +| img/alpha_complex_representation.png | cells of a Delaunay Triangulation. | +| | | +| | The filtration value of each simplex is computed as the square of the| +| | circumradius of the simplex if the circumsphere is empty (the simplex| +| | is then said to be Gabriel), and as the minimum of the filtration | +| | values of the codimension 1 cofaces that make it not Gabriel | +| | otherwise. All simplices that have a filtration value strictly | +| | greater than a given alpha squared value are not inserted into the | +| | complex. | +| | | +| | This package requires having CGAL version 4.7 or higher (4.8.1 is | +| | advised for better perfomances). | ++-------------------------------------------+----------------------------------------------------------------------+ +| :doc:`alpha_complex_user` | :doc:`alpha_complex_ref` | ++-------------------------------------------+----------------------------------------------------------------------+ + +Cubical complex +=============== + +===================================== ===================================== ===================================== +:Author: Pawel Dlotko :Introduced in: GUDHI PYTHON 1.4.0 :Copyright: GPL v3 +===================================== ===================================== ===================================== + ++---------------------------------------------+----------------------------------------------------------------------+ +| .. image:: | The cubical complex is an example of a structured complex useful in | +| img/Cubical_complex_representation.png | computational mathematics (specially rigorous numerics) and image | +| | analysis. | ++---------------------------------------------+----------------------------------------------------------------------+ +| :doc:`cubical_complex_user` | :doc:`cubical_complex_ref` | ++---------------------------------------------+----------------------------------------------------------------------+ + +Simplex tree +============ + +===================================== ===================================== ===================================== +:Author: Clément Maria :Introduced in: GUDHI PYTHON 1.4.0 :Copyright: GPL v3 +===================================== ===================================== ===================================== + +Witness complex +=============== + +===================================== ===================================== ===================================== +:Author: Siargey Kachanovich :Introduced in: GUDHI PYTHON 1.4.0 :Copyright: GPL v3 +===================================== ===================================== ===================================== + + +Toolbox +******* + +Persistence cohomology +====================== + +===================================== ===================================== ===================================== +:Author: Clément Maria :Introduced in: GUDHI PYTHON 1.4.0 :Copyright: GPL v3 +===================================== ===================================== ===================================== -* :ref:`alphacomplex` -.. automodule:: gudhi - :members: - :undoc-members: - :show-inheritance: diff --git a/src/cython/src/cpp/Alpha_complex_interface.h b/src/cython/src/cpp/Alpha_complex_interface.h index c745543a..ee5ab823 100644 --- a/src/cython/src/cpp/Alpha_complex_interface.h +++ b/src/cython/src/cpp/Alpha_complex_interface.h @@ -32,7 +32,7 @@ namespace Gudhi { -namespace alphacomplex { +namespace alpha_complex { class Alpha_complex_interface : public Alpha_complex< CGAL::Epick_d< CGAL::Dynamic_dimension_tag > > { using Alpha_complex = Alpha_complex< CGAL::Epick_d< CGAL::Dynamic_dimension_tag > > ; @@ -129,7 +129,7 @@ class Alpha_complex_interface : public Alpha_complex< CGAL::Epick_d< CGAL::Dynam }; -} // namespace alphacomplex +} // namespace alpha_complex } // namespace Gudhi diff --git a/src/cython/src/cpp/Cubical_complex_interface.h b/src/cython/src/cpp/Cubical_complex_interface.h index f054fbbd..5d17ff6b 100644 --- a/src/cython/src/cpp/Cubical_complex_interface.h +++ b/src/cython/src/cpp/Cubical_complex_interface.h @@ -33,7 +33,7 @@ namespace Gudhi { -namespace Cubical_complex { +namespace cubical_complex { template<typename CubicalComplexOptions = Bitmap_cubical_complex_base<double>> class Cubical_complex_interface : public Bitmap_cubical_complex<CubicalComplexOptions> { @@ -50,7 +50,7 @@ class Cubical_complex_interface : public Bitmap_cubical_complex<CubicalComplexOp }; -} // namespace Cubical_complex +} // namespace cubical_complex } // namespace Gudhi diff --git a/src/cython/src/cython/alpha_complex.pyx b/src/cython/src/cython/alpha_complex.pyx index f36de661..33fc06ef 100644 --- a/src/cython/src/cython/alpha_complex.pyx +++ b/src/cython/src/cython/alpha_complex.pyx @@ -81,13 +81,18 @@ cdef class AlphaComplex: cdef Alpha_complex_persistence_interface * pcohptr - def __cinit__(self, points=[], max_alpha_square=float('inf')): + # Fake constructor that does nothing but documenting the constructor + def __init__(self, points=[], max_alpha_square=float('inf')): """AlphaComplex constructor. - Args: - points (list): A list of points in d-Dimension. - max_alpha_square (float): Maximum Alpha square value. + :param points: A list of points in d-Dimension. + :type points: list of list of double + :param max_alpha_square: Maximum Alpha square value. + :type max_alpha_square: double """ + + # The real cython constructor + def __cinit__(self, points=[], max_alpha_square=float('inf')): self.thisptr = new Alpha_complex_interface(points, max_alpha_square) @@ -119,7 +124,7 @@ cdef class AlphaComplex: given N-simplex. :param simplex: The N-simplex, represented by a list of vertex. - :type simplex: list of int. + :type simplex: list of int :returns: float -- the simplicial complex filtration value. """ return self.thisptr.simplex_filtration(simplex) diff --git a/src/cython/src/cython/cubical_complex.pyx b/src/cython/src/cython/cubical_complex.pyx index 52137520..fe286dc6 100644 --- a/src/cython/src/cython/cubical_complex.pyx +++ b/src/cython/src/cython/cubical_complex.pyx @@ -53,16 +53,26 @@ cdef class CubicalComplex: cdef Cubical_complex_persistence_interface * pcohptr - def __cinit__(self, dimensions=None, top_dimensional_cells=None, + # Fake constructor that does nothing but documenting the constructor + def __init__(self, dimensions=None, top_dimensional_cells=None, perseus_file=''): """CubicalComplex constructor from dimensions and top_dimensional_cells or from a perseus file style name. - Args: - dimensions (list): A list of number of top dimensional cells. - top_dimensional_cells (list): A list of top dimensional cells. - perseus_file (string): A perseus file style name. - """ + :param dimensions: A list of number of top dimensional cells. + :type dimensions: list of int + :param top_dimensional_cells: A list of top dimensional cells. + :type top_dimensional_cells: list of double + + Or + + :param perseus_file: A perseus file style name. + :type perseus_file: string + """ + + # The real cython constructor + def __cinit__(self, dimensions=None, top_dimensional_cells=None, + perseus_file=''): if ((dimensions is not None) or (top_dimensional_cells is not None) and (perseus_file is not '')): print("CubicalComplex can be constructed from dimensions and " |