diff --git a/.buildinfo b/.buildinfo index a45b577..fe32c60 100644 --- a/.buildinfo +++ b/.buildinfo @@ -1,4 +1,4 @@ # Sphinx build info version 1 # This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done. -config: c21e735eab84c3aa0e238b171d1ab8ac +config: 32366a3347e65842caa56b850979ac4e tags: 645f666f9bcd5a90fca523b33c5a78b7 diff --git a/.doctrees/api.doctree b/.doctrees/api.doctree index 288d0b7..b5eef31 100644 Binary files a/.doctrees/api.doctree and b/.doctrees/api.doctree differ diff --git a/.doctrees/environment.pickle b/.doctrees/environment.pickle index 1517963..560063e 100644 Binary files a/.doctrees/environment.pickle and b/.doctrees/environment.pickle differ diff --git a/.doctrees/examples/sg_execution_times.doctree b/.doctrees/examples/sg_execution_times.doctree index 74ccf00..4973644 100644 Binary files a/.doctrees/examples/sg_execution_times.doctree and b/.doctrees/examples/sg_execution_times.doctree differ diff --git a/.doctrees/examples/spatial_indexing.doctree b/.doctrees/examples/spatial_indexing.doctree index 88a37ef..59d8969 100644 Binary files a/.doctrees/examples/spatial_indexing.doctree and b/.doctrees/examples/spatial_indexing.doctree differ diff --git a/.doctrees/sg_execution_times.doctree b/.doctrees/sg_execution_times.doctree index 0693a80..ad8df2d 100644 Binary files a/.doctrees/sg_execution_times.doctree and b/.doctrees/sg_execution_times.doctree differ diff --git a/_downloads/bc82bea3a5dd7bdba60b65220891d9e5/examples_python.zip b/_downloads/bc82bea3a5dd7bdba60b65220891d9e5/examples_python.zip index b4cb24b..1a36c34 100644 Binary files a/_downloads/bc82bea3a5dd7bdba60b65220891d9e5/examples_python.zip and b/_downloads/bc82bea3a5dd7bdba60b65220891d9e5/examples_python.zip differ diff --git a/_downloads/fb625db3c50d423b1b7881136ffdeec8/examples_jupyter.zip b/_downloads/fb625db3c50d423b1b7881136ffdeec8/examples_jupyter.zip index d3a5716..2779331 100644 Binary files a/_downloads/fb625db3c50d423b1b7881136ffdeec8/examples_jupyter.zip and b/_downloads/fb625db3c50d423b1b7881136ffdeec8/examples_jupyter.zip differ diff --git a/_modules/index.html b/_modules/index.html index ad7cf27..318db5d 100644 --- a/_modules/index.html +++ b/_modules/index.html @@ -7,7 +7,7 @@ - Overview: module code — Numba Celltree 0.1.6 documentation + Overview: module code — Numba Celltree 0.1.7 documentation @@ -39,7 +39,7 @@ - + diff --git a/_modules/numba_celltree/celltree.html b/_modules/numba_celltree/celltree.html index df7e600..b2603c7 100644 --- a/_modules/numba_celltree/celltree.html +++ b/_modules/numba_celltree/celltree.html @@ -7,7 +7,7 @@ - numba_celltree.celltree — Numba Celltree 0.1.6 documentation + numba_celltree.celltree — Numba Celltree 0.1.7 documentation @@ -39,7 +39,7 @@ - + @@ -392,7 +392,6 @@

Source code for numba_celltree.celltree

 )
 from numba_celltree.constants import (
     FILL_VALUE,
-    MAX_N_FACE,
     MAX_N_VERTEX,
     BoolArray,
     CellTreeData,
@@ -430,13 +429,7 @@ 

Source code for numba_celltree.celltree

         faces = np.ascontiguousarray(faces, dtype=IntDType)
     if faces.ndim != 2:
         raise ValueError("faces must have shape (n_face, n_max_vert)")
-    n_face, n_max_vert = faces.shape
-    if n_face > MAX_N_FACE:
-        raise ValueError(
-            f"faces contains {n_face} faces. "
-            f"numba_celltree supports a maximum of {MAX_N_FACE} faces. "
-            f"Increase MAX_N_FACE in the source code, or supply a smaller mesh."
-        )
+    _, n_max_vert = faces.shape
     if n_max_vert > MAX_N_VERTEX:
         raise ValueError(
             f"faces contains up to {n_max_vert} vertices for a single face. "
@@ -614,7 +607,9 @@ 

Source code for numba_celltree.celltree

         return i[actual], j[actual], area[actual]
- def _locate_faces( +
+[docs] + def locate_faces( self, vertices: FloatArray, faces: IntArray ) -> Tuple[IntArray, IntArray]: """ @@ -651,7 +646,8 @@

Source code for numba_celltree.celltree

             indices_a=shortlist_i,
             indices_b=shortlist_j,
         )
-        return shortlist_i[intersects], shortlist_j[intersects]
+        return shortlist_i[intersects], shortlist_j[intersects]
+
[docs] @@ -684,7 +680,7 @@

Source code for numba_celltree.celltree

         """
         vertices = cast_vertices(vertices)
         faces = cast_faces(faces, fill_value)
-        i, j = self._locate_faces(vertices, faces)
+        i, j = self.locate_faces(vertices, faces)
         area = area_of_intersection(
             vertices_a=vertices,
             vertices_b=self.vertices,
diff --git a/_sources/examples/sg_execution_times.rst.txt b/_sources/examples/sg_execution_times.rst.txt
index 40de308..3d02452 100644
--- a/_sources/examples/sg_execution_times.rst.txt
+++ b/_sources/examples/sg_execution_times.rst.txt
@@ -6,7 +6,7 @@
 
 Computation times
 =================
-**00:00.746** total execution time for 1 file **from examples**:
+**00:00.752** total execution time for 1 file **from examples**:
 
 .. container::
 
@@ -33,5 +33,5 @@ Computation times
      - Time
      - Mem (MB)
    * - :ref:`sphx_glr_examples_spatial_indexing.py` (``spatial_indexing.py``)
-     - 00:00.746
+     - 00:00.752
      - 0.0
diff --git a/_sources/examples/spatial_indexing.rst.txt b/_sources/examples/spatial_indexing.rst.txt
index 622d040..5ae530e 100644
--- a/_sources/examples/spatial_indexing.rst.txt
+++ b/_sources/examples/spatial_indexing.rst.txt
@@ -676,7 +676,7 @@ with the Euclidian norm (Pythagorean distance):
 
 .. rst-class:: sphx-glr-timing
 
-   **Total running time of the script:** (0 minutes 0.746 seconds)
+   **Total running time of the script:** (0 minutes 0.752 seconds)
 
 
 .. _sphx_glr_download_examples_spatial_indexing.py:
diff --git a/_sources/sg_execution_times.rst.txt b/_sources/sg_execution_times.rst.txt
index 698e271..93a3255 100644
--- a/_sources/sg_execution_times.rst.txt
+++ b/_sources/sg_execution_times.rst.txt
@@ -6,7 +6,7 @@
 
 Computation times
 =================
-**00:00.746** total execution time for 1 file **from all galleries**:
+**00:00.752** total execution time for 1 file **from all galleries**:
 
 .. container::
 
@@ -33,5 +33,5 @@ Computation times
      - Time
      - Mem (MB)
    * - :ref:`sphx_glr_examples_spatial_indexing.py` (``../examples/spatial_indexing.py``)
-     - 00:00.746
+     - 00:00.752
      - 0.0
diff --git a/_static/documentation_options.js b/_static/documentation_options.js
index 462d975..8d5909e 100644
--- a/_static/documentation_options.js
+++ b/_static/documentation_options.js
@@ -1,5 +1,5 @@
 const DOCUMENTATION_OPTIONS = {
-    VERSION: '0.1.6',
+    VERSION: '0.1.7',
     LANGUAGE: 'en',
     COLLAPSE_INDEX: false,
     BUILDER: 'html',
diff --git a/api.html b/api.html
index 70b7300..1d052f8 100644
--- a/api.html
+++ b/api.html
@@ -8,7 +8,7 @@
     
     
 
-    CellTree2d — Numba Celltree 0.1.6 documentation
+    CellTree2d — Numba Celltree 0.1.7 documentation
   
   
   
@@ -40,7 +40,7 @@
 
   
 
-    
+    
     
     
     
@@ -516,6 +516,32 @@
 
 
 
+
+
+locate_faces(vertices: ndarray, faces: ndarray) Tuple[ndarray, ndarray][source]#
+

Find the index of a face intersecting with another face.

+

Only sharing an edge also counts as an intersection, due to the use of +the separating axis theorem to define intersection. The area of the +overlap is zero in such a case.

+
+
Parameters:
+
    +
  • vertices (ndarray of floats with shape (n_point, 2)) – Corner coordinates (x, y) of the cells.

  • +
  • faces (ndarray of integers with shape (n_face, n_max_vert)) – Index identifying for every face the indices of its corner nodes. +If a face has less corner nodes than n_max_vert, its last indices +should be equal to fill_value.

  • +
+
+
Returns:
+

    +
  • face_indices (ndarray of integers with shape (n_found,)) – Indices of the faces.

  • +
  • tree_face_indices (ndarray of integers with shape (n_found,)) – Indices of the tree faces.

  • +
+

+
+
+
+
locate_points(points: ndarray) ndarray[source]#
@@ -630,6 +656,7 @@
  • CellTree2d.intersect_edges()
  • CellTree2d.intersect_faces()
  • CellTree2d.locate_boxes()
  • +
  • CellTree2d.locate_faces()
  • CellTree2d.locate_points()
  • CellTree2d.node_bounds
  • CellTree2d.to_dict_of_lists()
  • diff --git a/examples/index.html b/examples/index.html index 48198a8..3b9f9f0 100644 --- a/examples/index.html +++ b/examples/index.html @@ -8,7 +8,7 @@ - Examples — Numba Celltree 0.1.6 documentation + Examples — Numba Celltree 0.1.7 documentation @@ -40,7 +40,7 @@ - + diff --git a/examples/sg_execution_times.html b/examples/sg_execution_times.html index 92b4439..8e29394 100644 --- a/examples/sg_execution_times.html +++ b/examples/sg_execution_times.html @@ -8,7 +8,7 @@ - Computation times — Numba Celltree 0.1.6 documentation + Computation times — Numba Celltree 0.1.7 documentation @@ -40,7 +40,7 @@ - + @@ -382,7 +382,7 @@

    Computation times#

    -

    00:00.746 total execution time for 1 file from examples:

    +

    00:00.752 total execution time for 1 file from examples: