diff --git a/notebooks/README.md b/notebooks/README.md
index 41952c6cd30..ba94766821c 100644
--- a/notebooks/README.md
+++ b/notebooks/README.md
@@ -36,13 +36,13 @@ Layout |
| | [Jaccard Similarity](algorithms/link_prediction/Jaccard-Similarity.ipynb) | Compute vertex similarity score using both:
- Jaccard Similarity
- Weighted Jaccard |
| | [Overlap Similarity](algorithms/link_prediction/Overlap-Similarity.ipynb) | Compute vertex similarity score using the Overlap Coefficient |
| Sampling |
-| | [Random Walk](sampling/RandomWalk.ipynb) | Compute Random Walk for a various number of seeds and path lengths |
+| | [Random Walk](algorithms/sampling/RandomWalk.ipynb) | Compute Random Walk for a various number of seeds and path lengths |
| Traversal | | |
-| | [BFS](traversal/BFS.ipynb) | Compute the Breadth First Search path from a starting vertex to every other vertex in a graph |
-| | [SSSP](traversal/SSSP.ipynb) | Single Source Shortest Path - compute the shortest path from a starting vertex to every other vertex |
+| | [BFS](algorithms/traversal/BFS.ipynb) | Compute the Breadth First Search path from a starting vertex to every other vertex in a graph |
+| | [SSSP](algorithms/traversal/SSSP.ipynb) | Single Source Shortest Path - compute the shortest path from a starting vertex to every other vertex |
| Structure | | |
-| | [Renumbering](structure/Renumber.ipynb)
[Renumbering 2](structure/Renumber-2.ipynb) | Renumber the vertex IDs in a graph (two sample notebooks) |
-| | [Symmetrize](structure/Symmetrize.ipynb) | Symmetrize the edges in a graph |
+| | [Renumbering](algorithms/structure/Renumber.ipynb)
[Renumbering 2](algorithms/structure/Renumber-2.ipynb) | Renumber the vertex IDs in a graph (two sample notebooks) |
+| | [Symmetrize](algorithms/structure/Symmetrize.ipynb) | Symmetrize the edges in a graph |
## RAPIDS notebooks
diff --git a/notebooks/algorithms/README.md b/notebooks/algorithms/README.md
index cfac699ec8e..7965970c7d9 100644
--- a/notebooks/algorithms/README.md
+++ b/notebooks/algorithms/README.md
@@ -36,15 +36,14 @@ Layout |
| [Link Prediction](link_prediction/README.md) | | |
| | [Jaccard Similarity](algorithms/link_prediction/Jaccard-Similarity.ipynb) | Compute vertex similarity score using both:
- Jaccard Similarity
- Weighted Jaccard |
| | [Overlap Similarity](algorithms/link_prediction/Overlap-Similarity.ipynb) | Compute vertex similarity score using the Overlap Coefficient |
-
[System Requirements](../README.md#requirements)
@@ -63,8 +62,4 @@ http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
-
-
-
-
-![RAPIDS](img/rapids_logo.png)
+![RAPIDS](../img/rapids_logo.png)
diff --git a/notebooks/algorithms/sampling/README.md b/notebooks/algorithms/sampling/README.md
new file mode 100644
index 00000000000..9c60adcb9e3
--- /dev/null
+++ b/notebooks/algorithms/sampling/README.md
@@ -0,0 +1,36 @@
+
+# cuGraph Sampling Algorithms
+
+
+
+CuGraph Sampling notebooks begin to address graph problems solved by random or other methods of sampling.
+These algorithms will solve problems like:
+
+* How to collect uniform samples from a large graph
+* Scaling down a large known graph
+* Exploring a huge unknown graph
+
+## Summary
+
+|Algorithm |Notebooks Containing |Description |
+| --------------- | ------------------------------------------------------------ | ------------------------------------------------------------ |
+|Random Walk | [RandomWalk](RandomWalk.ipynb) | Generates a Random path that exists in the graph starting from a seed vertex |
+
+[System Requirements](../../README.md#requirements)
+
+| Author Credit | Date | Update | cuGraph Version | Test Hardware |
+| --------------|------------|------------------|-----------------|----------------|
+| Brad Rees | 04/20/2021 | created | 0.19 | GV100, CUDA 11.0
+| Don Acosta | 08/29/2022 | tested / updated | 22.08 nightly | DGX Tesla V100 CUDA 11.5|
+
+## Copyright
+
+Copyright (c) 2021-2022, NVIDIA CORPORATION. All rights reserved.
+
+Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
+
+http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+
+![RAPIDS](../../img/rapids_logo.png)
diff --git a/notebooks/sampling/RandomWalk.ipynb b/notebooks/algorithms/sampling/RandomWalk.ipynb
similarity index 91%
rename from notebooks/sampling/RandomWalk.ipynb
rename to notebooks/algorithms/sampling/RandomWalk.ipynb
index caacf909259..9e58f78b4ea 100644
--- a/notebooks/sampling/RandomWalk.ipynb
+++ b/notebooks/algorithms/sampling/RandomWalk.ipynb
@@ -13,8 +13,9 @@
"| --------------|------------|----------------|-----------------|----------------|\n",
"| Brad Rees | 04/20/2021 | created | 0.19 | GV100, CUDA 11.0\n",
"| Ralph Liu | 06/22/2022 | updated/tested | 22.08 | TV100, CUDA 11.5\n",
+ "| Don Acosta | 08/28/2022 | updated/tested | 22.10 | TV100, CUDA 11.5\n",
"\n",
- "Currently NetworkX does not have a random walk function. There is code on StackOverflow that generats a random walk by getting a vertice and then randomly selection a neighbor and then repeating the process. "
+ "Currently NetworkX does not have a random walk function. There is code on StackOverflow that generates a random walk by getting a vertex and then randomly selecting a neighbor and then repeating the process. "
]
},
{
@@ -27,7 +28,7 @@
"Anthropological Research 33, 452-473 (1977).*\n",
"\n",
"\n",
- "![Karate Club](../img/zachary_black_lines.png)\n",
+ "\n",
"\n",
"\n",
"Because the test data has vertex IDs starting at 1, the auto-renumber feature of cuGraph (mentioned above) will be used so the starting vertex ID is zero for maximum efficiency. The resulting data will then be auto-unrenumbered, making the entire renumbering process transparent to users."
@@ -62,7 +63,7 @@
"metadata": {},
"outputs": [],
"source": [
- "gdf['wt'] = 1.0"
+ "gdf['weight'] = 1.0"
]
},
{
@@ -73,7 +74,7 @@
"source": [
"# Create a Graph - using the source (src) and destination (dst) vertex pairs from the Dataframe \n",
"G = cugraph.Graph()\n",
- "G.from_cudf_edgelist(gdf, source='src', destination='dst', edge_attr='wt')"
+ "G.from_cudf_edgelist(gdf, source='src', destination='dst', edge_attr='weight')"
]
},
{
@@ -166,7 +167,7 @@
],
"metadata": {
"kernelspec": {
- "display_name": "Python 3.9.7 ('base')",
+ "display_name": "Python 3.9.13 ('cugraph_dev')",
"language": "python",
"name": "python3"
},
@@ -180,11 +181,11 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
- "version": "3.9.7"
+ "version": "3.9.13"
},
"vscode": {
"interpreter": {
- "hash": "f708a36acfaef0acf74ccd43dfb58100269bf08fb79032a1e0a6f35bd9856f51"
+ "hash": "cee8a395f2f0c5a5bcf513ae8b620111f4346eff6dc64e1ea99c951b2ec68604"
}
}
},
diff --git a/notebooks/algorithms/structure/README.md b/notebooks/algorithms/structure/README.md
new file mode 100644
index 00000000000..b209ddba71c
--- /dev/null
+++ b/notebooks/algorithms/structure/README.md
@@ -0,0 +1,34 @@
+
+# cuGraph Structure Algorithms
+
+
+
+cuGraph Structure notebooks contain Jupyter Notebooks that demonstrate graph manipulations which support other cuGraph algorithms. Many cuGraph algorithms expect vertices ids formated as a contiguous list of integers. Some only support a directed graph. CuGraph structure algorithms encapsulate that functionality and make all those relying on them more efficient and independent of this aspect graph standardizing.
+
+## Summary
+
+|Algorithm |Notebooks Containing |Description |
+| --------------- | ------------------------------------------------------------ | ------------------------------------------------------------ |
+|Renumber | [Renumber](Renumber.ipynb) | Converts a graph with arbitrary vertex ids into a contiguous series of integers for efficient handling by many other cuGraph algorithms |
+|Renumber | [Renumber2](Renumber-2.ipynb) | Demonstrates how the renumber function can optimize graph processing by converting the underlying sparse matrix into an edgelist with a much small memory footprint. |
+|Symmetrize | [Symmetrize](Symmetrize.ipynb) |Demonstrates the functionality to transform an undirected graph into a directed graph with edges in each direction as needed for many other cuGraph algorithms.|
+
+
+[System Requirements](../../README.md#requirements)
+
+| Author Credit | Date | Update | cuGraph Version | Test Hardware |
+| --------------|------------|------------------|-----------------|----------------|
+| Brad Rees | 04/19/2021 | created | 0.19 | GV100, CUDA 11.0
+| Don Acosta | 08/29/2022 | tested / updated | 22.08 nightly | DGX Tesla V100 CUDA 11.5|
+
+## Copyright
+
+Copyright (c) 2019-2022, NVIDIA CORPORATION. All rights reserved.
+
+Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
+
+http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+
+![RAPIDS](../../img/rapids_logo.png)
diff --git a/notebooks/structure/Renumber-2.ipynb b/notebooks/algorithms/structure/Renumber-2.ipynb
similarity index 89%
rename from notebooks/structure/Renumber-2.ipynb
rename to notebooks/algorithms/structure/Renumber-2.ipynb
index 03858b3e52a..c4143b6a70b 100755
--- a/notebooks/structure/Renumber-2.ipynb
+++ b/notebooks/algorithms/structure/Renumber-2.ipynb
@@ -12,21 +12,14 @@
"\n",
"An alternative case is using renumbering to convert from one data type down to a contiguious sequence of integer IDs. This is useful when the dataset contain vertex IDs that are not integers. \n",
"\n",
- "\n",
"Notebook Credits\n",
"\n",
- "| Author | Date | Update |\n",
- "| --------------|------------|---------------------|\n",
- "| Brad Rees | 08/13/2019 | created |\n",
- "| Brad Rees | 07/08/2020 | updated |\n",
- "| Ralph Liu | 06/01/2022 | docs & code change |\n",
- "| | 06/22/2022 | update |\n",
- "\n",
- "RAPIDS Versions: 22.08 \n",
- "\n",
- "Test Hardware\n",
- "\n",
- "* Tesla V100 32G, CUDA 11.5\n",
+ "| Author Credit | Date | Update | cuGraph Version | Test Hardware |\n",
+ "| --------------|------------|--------------------|-----------------|----------------|\n",
+ "| Brad Rees | 08/13/2019 | created | 0.10 | GV100, CUDA 11.0\n",
+ "| Brad Rees | 07/08/2020 | updated | 0.15 | GV100, CUDA 11.0\n",
+ "| Ralph Liu | 06/22/2022 | docs & code change | 22.08 | TV100, CUDA 11.5\n",
+ "| Don Acosta | 08/28/2022 | updated/tested | 22.10 | TV100, CUDA 11.5\n",
"\n",
"\n",
"## Introduction\n",
@@ -53,7 +46,7 @@
"metadata": {},
"source": [
"### Test Data\n",
- "A cyber data set from the University of New South Wales is used, where just the IP edge pairs from been extracted"
+ "Using the IP edge pairs of a cyber data set from the University of New South Wales."
]
},
{
@@ -236,7 +229,7 @@
],
"metadata": {
"kernelspec": {
- "display_name": "Python 3.9.7 ('base')",
+ "display_name": "Python 3.9.13 ('cugraph_dev')",
"language": "python",
"name": "python3"
},
@@ -250,11 +243,11 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
- "version": "3.9.7"
+ "version": "3.9.13"
},
"vscode": {
"interpreter": {
- "hash": "f708a36acfaef0acf74ccd43dfb58100269bf08fb79032a1e0a6f35bd9856f51"
+ "hash": "cee8a395f2f0c5a5bcf513ae8b620111f4346eff6dc64e1ea99c951b2ec68604"
}
}
},
diff --git a/notebooks/structure/Renumber.ipynb b/notebooks/algorithms/structure/Renumber.ipynb
similarity index 92%
rename from notebooks/structure/Renumber.ipynb
rename to notebooks/algorithms/structure/Renumber.ipynb
index 903ed9df389..cc4d6901824 100755
--- a/notebooks/structure/Renumber.ipynb
+++ b/notebooks/algorithms/structure/Renumber.ipynb
@@ -13,17 +13,11 @@
"An alternative case is using renumbering to convert from one data type down to a contiguous sequence of integer IDs. This is useful when the dataset contain vertex IDs that are not integers. \n",
"\n",
"\n",
- "Notebook Credits\n",
- "* Original Authors: Chuck Hastings and Bradley Rees\n",
- "* Created: 08/13/2019\n",
- "* Updated: 06/22/2022\n",
- "\n",
- "RAPIDS Versions: 22.08 \n",
- "\n",
- "Test Hardware\n",
- "\n",
- "* Tesla V100 32G, CUDA 11.5\n",
- "\n",
+ "| Author Credit | Date | Update | cuGraph Version | Test Hardware |\n",
+ "| --------------------------------|-----------------|--------------------|-----------------|----------------|\n",
+ "| Brad Rees and Chuck Hastings | 08/13/2019 | created | 0.10 | GV100, CUDA 11.0\n",
+ "| Brad Rees | 06/22/2020 | updated | 0.15 | GV100, CUDA 11.0\n",
+ "| Don Acosta | 08/28/2022 | updated/tested | 22.10 | TV100, CUDA 11.5\n",
"## Introduction\n",
"\n",
"Demonstrate creating a graph with renumbering.\n",
@@ -38,9 +32,7 @@
"\n",
"Let us consider that a vertex is uniquely defined as a tuple of elements from the rows of a cuDF DataFrame. The primary restriction is that the number of elements in the tuple must be the same for both source vertices and destination vertices, and that the types of each element in the source tuple must be the same as the corresponding element in the destination tuple. This restriction is a natural restriction and should be obvious why this is required.\n",
"\n",
- "Renumbering takes the collection of tuples that uniquely identify vertices in the graph, eliminates duplicates, and assigns integer identifiers to the unique tuples. These integer identifiers are used as *internal* vertex identifiers within the cuGraph software.\n",
- "\n",
- "One of the features of the renumbering function is that it maps vertex ids of any size and structure down into a range that fits into 32-bit integers. The current cuGraph algorithms are limited to 32-bit signed integers as vertex ids. and the renumbering feature will allow the caller to translate ids that are 64-bit (or strings, or complex data types) into a densely packed 32-bit array of ids that can be used in cuGraph algorithms. Note that if there are more than 2^31 - 1 unique vertex ids then the renumber method will fail with an error indicating that there are too many vertices to renumber into a 32-bit signed integer."
+ "Renumbering takes the collection of tuples that uniquely identify vertices in the graph, eliminates duplicates, and assigns integer identifiers to the unique tuples. These integer identifiers are used as *internal* vertex identifiers within the cuGraph software.\n"
]
},
{
@@ -342,7 +334,7 @@
],
"metadata": {
"kernelspec": {
- "display_name": "Python 3.9.7 ('base')",
+ "display_name": "Python 3.9.13 ('cugraph_dev')",
"language": "python",
"name": "python3"
},
@@ -356,11 +348,11 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
- "version": "3.9.7"
+ "version": "3.9.13"
},
"vscode": {
"interpreter": {
- "hash": "f708a36acfaef0acf74ccd43dfb58100269bf08fb79032a1e0a6f35bd9856f51"
+ "hash": "cee8a395f2f0c5a5bcf513ae8b620111f4346eff6dc64e1ea99c951b2ec68604"
}
}
},
diff --git a/notebooks/structure/Symmetrize.ipynb b/notebooks/algorithms/structure/Symmetrize.ipynb
similarity index 85%
rename from notebooks/structure/Symmetrize.ipynb
rename to notebooks/algorithms/structure/Symmetrize.ipynb
index f0c57baf070..0357a2737b1 100755
--- a/notebooks/structure/Symmetrize.ipynb
+++ b/notebooks/algorithms/structure/Symmetrize.ipynb
@@ -8,16 +8,12 @@
"\n",
"In this notebook, we will use the _symmetrize_ function to create bi-directional edges in an undirected graph\n",
"\n",
- "Notebook Credits\n",
- "* Original Authors: Bradley Rees and James Wyles\n",
- "* Created: 08/13/2019\n",
- "* Updated: 06/22/2022\n",
"\n",
- "RAPIDS Versions: 22.08 \n",
- "\n",
- "Test Hardware\n",
- "\n",
- "* Tesla V100 32G, CUDA 11.5\n",
+ "| Author Credit | Date | Update | cuGraph Version | Test Hardware |\n",
+ "| --------------------------------|-----------------|--------------------|-----------------|----------------|\n",
+ "| Brad Rees and James Wyles | 08/13/2019 | created | 0.10 | GV100, CUDA 11.0\n",
+ "| Brad Rees | 06/22/2020 | updated | 0.15 | GV100, CUDA 11.0\n",
+ "| Don Acosta | 08/28/2022 | updated/tested | 22.10 | TV100, CUDA 11.5\n",
"\n",
"\n",
"## Introduction\n",
@@ -49,7 +45,7 @@
"Anthropological Research 33, 452-473 (1977).*\n",
"\n",
"\n",
- "![Karate Club](../img/zachary_black_lines.png)\n"
+ "\n"
]
},
{
@@ -70,7 +66,7 @@
"outputs": [],
"source": [
"# Read the unsymmetrized data \n",
- "unsym_data ='../data/karate_undirected.csv'\n",
+ "unsym_data ='../../data/karate_undirected.csv'\n",
"gdf = cudf.read_csv(unsym_data, names=[\"src\", \"dst\"], delimiter='\\t', dtype=[\"int32\", \"int32\"] )"
]
},
@@ -175,7 +171,7 @@
],
"metadata": {
"kernelspec": {
- "display_name": "Python 3.9.7 ('base')",
+ "display_name": "Python 3.9.13 ('cugraph_dev')",
"language": "python",
"name": "python3"
},
@@ -189,11 +185,11 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
- "version": "3.9.7"
+ "version": "3.9.13"
},
"vscode": {
"interpreter": {
- "hash": "f708a36acfaef0acf74ccd43dfb58100269bf08fb79032a1e0a6f35bd9856f51"
+ "hash": "cee8a395f2f0c5a5bcf513ae8b620111f4346eff6dc64e1ea99c951b2ec68604"
}
}
},
diff --git a/notebooks/traversal/BFS.ipynb b/notebooks/algorithms/traversal/BFS.ipynb
similarity index 90%
rename from notebooks/traversal/BFS.ipynb
rename to notebooks/algorithms/traversal/BFS.ipynb
index b9409e2f821..7c4b87f30c3 100755
--- a/notebooks/traversal/BFS.ipynb
+++ b/notebooks/algorithms/traversal/BFS.ipynb
@@ -7,18 +7,13 @@
"# Breadth First Search (BFS) \n",
"In this notebook, we will use cuGraph to compute the Breadth First Search path from a starting vertex to every other vertex in our training dataset.\n",
"\n",
- "Notebook Credits\n",
- "* Original Authors: Bradley Rees and James Wyles\n",
- "* Feature available since 0.6\n",
- "* Last Edit: 06/22/2022\n",
- "\n",
- "RAPIDS Versions: 22.08 \n",
- "\n",
- "Test Hardware\n",
- "\n",
- "* Tesla V100 32G, CUDA 11.5\n",
"\n",
"\n",
+ "| Author Credit | Date | Update | cuGraph Version | Test Hardware |\n",
+ "| --------------------------------|-----------------|--------------------|-----------------|----------------|\n",
+ "| Brad Rees and James Wyles | 08/13/2019 | created | 0.10 | GV100, CUDA 11.0\n",
+ "| Ralph Liu | 06/22/2020 | updated | 22.08 | GV100, CUDA 11.0\n",
+ "| Don Acosta | 08/28/2022 | updated/tested | 22.10 | TV100, CUDA 11.5\n",
"\n",
"## Introduction\n",
"\n",
@@ -42,7 +37,7 @@
"\n",
"\n",
"### Some notes about vertex IDs...\n",
- "* The current version of cuGraph requires that vertex IDs be representable as 32-bit integers, meaning graphs currently can contain at most 2^32 unique vertex IDs. However, this limitation is being actively addressed and a version of cuGraph that accommodates more than 2^32 vertices will be available in the near future.\n",
+ "\n",
"* cuGraph will automatically renumber graphs to an internal format consisting of a contiguous series of integers starting from 0, and convert back to the original IDs when returning data to the caller. If the vertex IDs of the data are already a contiguous series of integers starting from 0, the auto-renumbering step can be skipped for faster graph creation times.\n",
" * To skip auto-renumbering, set the `renumber` boolean arg to `False` when calling the appropriate graph creation API (eg. `G.from_cudf_edgelist(gdf_r, source='src', destination='dst', renumber=False)`).\n",
" * For more advanced renumbering support, see the examples in `structure/renumber.ipynb` and `structure/renumber-2.ipynb`\n"
@@ -58,7 +53,7 @@
"Anthropological Research 33, 452-473 (1977).*\n",
"\n",
"\n",
- "![Karate Club](../img/zachary_black_lines.png)\n",
+ "\n",
"\n",
"Our test data is small so that results can be visually verified"
]
@@ -268,7 +263,7 @@
],
"metadata": {
"kernelspec": {
- "display_name": "Python 3.9.7 ('base')",
+ "display_name": "Python 3.9.13 ('cugraph_dev')",
"language": "python",
"name": "python3"
},
@@ -282,11 +277,11 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
- "version": "3.9.7"
+ "version": "3.9.13"
},
"vscode": {
"interpreter": {
- "hash": "f708a36acfaef0acf74ccd43dfb58100269bf08fb79032a1e0a6f35bd9856f51"
+ "hash": "cee8a395f2f0c5a5bcf513ae8b620111f4346eff6dc64e1ea99c951b2ec68604"
}
}
},
diff --git a/notebooks/algorithms/traversal/README.md b/notebooks/algorithms/traversal/README.md
new file mode 100644
index 00000000000..4d4f37a0f8c
--- /dev/null
+++ b/notebooks/algorithms/traversal/README.md
@@ -0,0 +1,32 @@
+
+# cuGraph Traversal Algorithms
+
+
+
+CuGraph Traversal notebooks demonstrate various algorithms for finding paths through a graph.
+
+## Summary
+
+|Algorithm |Notebooks Containing |Description |
+| --------------- | ------------------------------------------------------------ | ------------------------------------------------------------ |
+|Breadth First Search | [BFS](BFS.ipynb) | Traverses all vertices reachable from a seed by exploring one hop at a time. |
+|Single Source Shortest Path | [SSSP](SSSP.ipynb) | Computes the shortest path from a single seed vertex to all the reachable vertices in the graph. |
+
+[System Requirements](../../README.md#requirements)
+
+| Author Credit | Date | Update | cuGraph Version | Test Hardware |
+| --------------|------------|------------------|-----------------|----------------|
+| Brad Rees | 08/13/2019 | created | 0.15 | GV100, CUDA 11.0
+| Don Acosta | 08/29/2022 | tested / updated | 22.10 nightly | DGX Tesla V100 CUDA 11.5|
+
+## Copyright
+
+Copyright (c) 2019-2022, NVIDIA CORPORATION. All rights reserved.
+
+Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
+
+http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+
+![RAPIDS](../../img/rapids_logo.png)
diff --git a/notebooks/traversal/SSSP.ipynb b/notebooks/algorithms/traversal/SSSP.ipynb
similarity index 83%
rename from notebooks/traversal/SSSP.ipynb
rename to notebooks/algorithms/traversal/SSSP.ipynb
index a5e981f38c2..0b5ff3d0932 100755
--- a/notebooks/traversal/SSSP.ipynb
+++ b/notebooks/algorithms/traversal/SSSP.ipynb
@@ -8,24 +8,16 @@
"\n",
"In this notebook, we will use cuGraph to compute the shortest path from a starting vertex to every other vertex in our training dataset.\n",
"\n",
- "Notebook Credits\n",
- "* Original Authors: Bradley Rees and James Wyles\n",
- "* available since release 0.6\n",
- "* Last Edit: 06/22/2022\n",
- "\n",
- "\n",
- "RAPIDS Versions: 22.08 \n",
- "\n",
- "Test Hardware\n",
- "\n",
- "* Tesla V100 32G, CUDA 11.5\n",
- "\n",
- "\n",
"\n",
+ "| Author Credit | Date | Update | cuGraph Version | Test Hardware |\n",
+ "| --------------------------------|-----------------|--------------------|-----------------|----------------|\n",
+ "| Brad Rees and James Wyles | 08/13/2019 | created | 0.10 | GV100, CUDA 11.0\n",
+ "| Ralph Liu | 06/22/2022 | updated | 22.08 | GV100, CUDA 11.0\n",
+ "| Don Acosta | 08/28/2022 | updated/tested | 22.10 | TV100, CUDA 11.5\n",
"\n",
"## Introduction\n",
"\n",
- "Single source shortest path computes the shortest paths from the given starting vertex to all other reachable vertices. \n",
+ "Single source shortest path computes the shortest paths from the given starting vertex to all other reachable vertices. For an example implementation which builds on this algorithm as a substitute for an all points shortest path see the [Cost Matrix](../../applications/CostMatrix.ipynb) notebook. \n",
"\n",
"To compute SSSP for a graph in cuGraph we use:\n",
"**cugraph.sssp(G, source)**\n",
@@ -42,7 +34,7 @@
"\n",
"\n",
"### Some notes about vertex IDs...\n",
- "* The current version of cuGraph requires that vertex IDs be representable as 32-bit integers, meaning graphs currently can contain at most 2^32 unique vertex IDs. However, this limitation is being actively addressed and a version of cuGraph that accommodates more than 2^32 vertices will be available in the near future.\n",
+ "\n",
"* cuGraph will automatically renumber graphs to an internal format consisting of a contiguous series of integers starting from 0, and convert back to the original IDs when returning data to the caller. If the vertex IDs of the data are already a contiguous series of integers starting from 0, the auto-renumbering step can be skipped for faster graph creation times.\n",
" * To skip auto-renumbering, set the `renumber` boolean arg to `False` when calling the appropriate graph creation API (eg. `G.from_cudf_edgelist(gdf_r, source='src', destination='dst', renumber=False)`).\n",
" * For more advanced renumbering support, see the examples in `structure/renumber.ipynb` and `structure/renumber-2.ipynb`\n"
@@ -58,7 +50,7 @@
"Anthropological Research 33, 452-473 (1977).*\n",
"\n",
"\n",
- "![Karate Club](../img/zachary_black_lines.png)\n",
+ "\n",
"\n",
"This is a small graph which allows for easy visual inspection to validate results. \n",
"__Note__: The Karate dataset starts with vertex ID 1 which the cuGraph analytics assume a zero-based starting ID. "
@@ -177,7 +169,7 @@
],
"metadata": {
"kernelspec": {
- "display_name": "Python 3.9.7 ('base')",
+ "display_name": "Python 3.9.13 ('cugraph_dev')",
"language": "python",
"name": "python3"
},
@@ -191,11 +183,11 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
- "version": "3.9.7"
+ "version": "3.9.13"
},
"vscode": {
"interpreter": {
- "hash": "f708a36acfaef0acf74ccd43dfb58100269bf08fb79032a1e0a6f35bd9856f51"
+ "hash": "cee8a395f2f0c5a5bcf513ae8b620111f4346eff6dc64e1ea99c951b2ec68604"
}
}
},
diff --git a/notebooks/cugraph_benchmarks/release.ipynb b/notebooks/cugraph_benchmarks/release.ipynb
index 4693265d057..8ba3c82ebbc 100644
--- a/notebooks/cugraph_benchmarks/release.ipynb
+++ b/notebooks/cugraph_benchmarks/release.ipynb
@@ -105,7 +105,7 @@
},
{
"cell_type": "code",
- "execution_count": null,
+ "execution_count": 20,
"metadata": {},
"outputs": [],
"source": [
@@ -129,7 +129,7 @@
},
{
"cell_type": "code",
- "execution_count": null,
+ "execution_count": 21,
"metadata": {},
"outputs": [],
"source": [
@@ -149,7 +149,7 @@
},
{
"cell_type": "code",
- "execution_count": null,
+ "execution_count": 22,
"metadata": {},
"outputs": [],
"source": [
@@ -171,12 +171,12 @@
"\n",
"\n",
"# TODO: Was set to quick for test\n",
- "data = data_quick\n"
+ "data = data_full\n"
]
},
{
"cell_type": "code",
- "execution_count": null,
+ "execution_count": 23,
"metadata": {},
"outputs": [],
"source": [
@@ -194,7 +194,7 @@
},
{
"cell_type": "code",
- "execution_count": null,
+ "execution_count": 24,
"metadata": {},
"outputs": [],
"source": [
@@ -222,7 +222,7 @@
},
{
"cell_type": "code",
- "execution_count": null,
+ "execution_count": 25,
"metadata": {},
"outputs": [],
"source": [
@@ -264,7 +264,7 @@
},
{
"cell_type": "code",
- "execution_count": null,
+ "execution_count": 26,
"metadata": {},
"outputs": [],
"source": [
@@ -299,7 +299,7 @@
},
{
"cell_type": "code",
- "execution_count": null,
+ "execution_count": 27,
"metadata": {},
"outputs": [],
"source": [
@@ -335,7 +335,7 @@
},
{
"cell_type": "code",
- "execution_count": null,
+ "execution_count": 28,
"metadata": {},
"outputs": [],
"source": [
@@ -374,7 +374,7 @@
},
{
"cell_type": "code",
- "execution_count": null,
+ "execution_count": 29,
"metadata": {},
"outputs": [],
"source": [
@@ -415,7 +415,7 @@
},
{
"cell_type": "code",
- "execution_count": null,
+ "execution_count": 30,
"metadata": {},
"outputs": [],
"source": [
@@ -456,7 +456,7 @@
},
{
"cell_type": "code",
- "execution_count": null,
+ "execution_count": 31,
"metadata": {},
"outputs": [],
"source": [
@@ -496,7 +496,7 @@
},
{
"cell_type": "code",
- "execution_count": null,
+ "execution_count": 32,
"metadata": {},
"outputs": [],
"source": [
@@ -531,7 +531,7 @@
},
{
"cell_type": "code",
- "execution_count": null,
+ "execution_count": 33,
"metadata": {},
"outputs": [],
"source": [
@@ -539,14 +539,13 @@
" t1 = perf_counter()\n",
" _G = create_nx_ugraph(_df)\n",
" nj = nx.jaccard_coefficient(_G)\n",
- " nj_list = list(nj) # gen -> list\n",
" t2 = perf_counter() - t1\n",
" return t2\n",
"\n",
"def cu_jaccard(_df):\n",
" t1 = perf_counter()\n",
" _G = create_cu_ugraph(_df)\n",
- " _ = cugraph.jaccard_coefficient(_G)\n",
+ " _ = list(cugraph.jaccard_coefficient(_G))\n",
" t2 = perf_counter() - t1\n",
" return t2\n",
"\n",
@@ -567,7 +566,7 @@
},
{
"cell_type": "code",
- "execution_count": null,
+ "execution_count": 34,
"metadata": {},
"outputs": [],
"source": [
@@ -603,7 +602,7 @@
},
{
"cell_type": "code",
- "execution_count": null,
+ "execution_count": 35,
"metadata": {},
"outputs": [],
"source": [
@@ -640,7 +639,7 @@
},
{
"cell_type": "code",
- "execution_count": null,
+ "execution_count": 36,
"metadata": {},
"outputs": [],
"source": [
@@ -650,9 +649,30 @@
},
{
"cell_type": "code",
- "execution_count": null,
+ "execution_count": 37,
"metadata": {},
- "outputs": [],
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Reading ./data/preferentialAttachment.mtx...\n",
+ "\tGDF Size 999970\n",
+ "\tcugraph Size 499985\n",
+ "\tcugraph Order 100000\n"
+ ]
+ },
+ {
+ "data": {
+ "text/plain": [
+ "0"
+ ]
+ },
+ "execution_count": 37,
+ "metadata": {},
+ "output_type": "execute_result"
+ }
+ ],
"source": [
"# do a simple pass just to get all the libraries initialized\n",
"# This cell might not be needed\n",
@@ -678,9 +698,28 @@
},
{
"cell_type": "code",
- "execution_count": null,
+ "execution_count": 38,
"metadata": {},
- "outputs": [],
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Reading ./data/preferentialAttachment.mtx...\n",
+ "\tdata in gdf 999970 and data in pandas 999970\n",
+ "\tKatz n.c.cx.\n",
+ "\tBC k=100 n. k = 100 c.cx. \n",
+ "\tLouvain n.c.cx. \n",
+ "\tTC n.c.cx. \n",
+ "\tWCC n.c.cx. \n",
+ "\tCore Number n.c.cx. \n",
+ "\tPageRank n.c.cx. \n",
+ "\tJaccard n.c.cx. \n",
+ "\tBFS n.c.cx. \n",
+ "\tSSSP n.c.cx. \n"
+ ]
+ }
+ ],
"source": [
"# arrays to capture performance gains\n",
"names = []\n",
@@ -943,9 +982,19 @@
},
{
"cell_type": "code",
- "execution_count": null,
+ "execution_count": 39,
"metadata": {},
- "outputs": [],
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "[' ', 'Katz', 'BC Estimate fixed', 'Louvain', 'TC', 'WCC', 'Core Number', 'PageRank', 'Jaccard', 'BFS', 'SSP']\n",
+ "preferentialAttachment\n",
+ "[145.30643917185208, 236.64781352415596, 4385.897320647833, 135.74325850737782, 34.89773706999491, 35.98962606492319, 148.4826107413348, 34.04823126698779, 41.64064391168044, 39.70684495453922]\n"
+ ]
+ }
+ ],
"source": [
"#Print results\n",
"print(algos)\n",
@@ -957,9 +1006,22 @@
},
{
"cell_type": "code",
- "execution_count": null,
+ "execution_count": 40,
"metadata": {},
- "outputs": [],
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "\n",
+ "------------\n",
+ "\n",
+ "[' ', 'Katz', 'BC Estimate fixed', 'Louvain', 'TC', 'WCC', 'Core Number', 'PageRank', 'Jaccard', 'BFS', 'SSP']\n",
+ "preferentialAttachment\n",
+ "[3.4762573984859073, 36.25720333229164, 134.55004466061635, 2.4608888173507344, 0.9039513041939133, 1.117330592113951, 2.4959144857253164, 0.09156219712459993, 1.006714469868979, 41.36659009325271]\n"
+ ]
+ }
+ ],
"source": [
"#Print results\n",
"print(\"\\n------------\\n\")\n",
@@ -1070,11 +1132,8 @@
}
],
"metadata": {
- "interpreter": {
- "hash": "f708a36acfaef0acf74ccd43dfb58100269bf08fb79032a1e0a6f35bd9856f51"
- },
"kernelspec": {
- "display_name": "Python 3.8.10 ('base')",
+ "display_name": "Python 3.9.13 ('cugraph_dev')",
"language": "python",
"name": "python3"
},
@@ -1088,7 +1147,12 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
- "version": "3.8.10"
+ "version": "3.9.13"
+ },
+ "vscode": {
+ "interpreter": {
+ "hash": "cee8a395f2f0c5a5bcf513ae8b620111f4346eff6dc64e1ea99c951b2ec68604"
+ }
}
},
"nbformat": 4,
diff --git a/notebooks/img/zachary_graph_path.png b/notebooks/img/zachary_graph_path.png
new file mode 100644
index 00000000000..224dc80128e
Binary files /dev/null and b/notebooks/img/zachary_graph_path.png differ
diff --git a/python/cugraph/cugraph/centrality/betweenness_centrality.py b/python/cugraph/cugraph/centrality/betweenness_centrality.py
index 8f8cb3fce95..c285238e49f 100644
--- a/python/cugraph/cugraph/centrality/betweenness_centrality.py
+++ b/python/cugraph/cugraph/centrality/betweenness_centrality.py
@@ -235,12 +235,12 @@ def edge_betweenness_centrality(
--------
>>> from cugraph.experimental.datasets import karate
>>> G = karate.get_graph(fetch=True)
- >>> bc = cugraph.betweenness_centrality(G)
+ >>> bc = cugraph.edge_betweenness_centrality(G)
"""
if weight is not None:
raise NotImplementedError(
- "weighted implementation of betweenness "
+ "weighted implementation of edge betweenness "
"centrality not currently supported"
)
if result_dtype not in [np.float32, np.float64]: