Skip to content

Commit

Permalink
Update 2.sampling_api.md
Browse files Browse the repository at this point in the history
  • Loading branch information
AntiTopQuark authored Dec 25, 2024
1 parent 9f6aee4 commit a43bf6a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion docs/en-US/source/9.olap&procedure/3.learn/2.sampling_api.md
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,8 @@ EdgeInfo: A list of dictionaries containing metadata information for the edges.
Return value: This function does not return anything.

### 3.6 Node2Vec Sampling Operator
Perform biased random walks using the Node2Vec algorithm to generate node sequences and node embeddings that capture the network structure.
Node2Vec is a graph embedding algorithm that generates node sequences through random walks and embeds the nodes into a low-dimensional space using the Word2Vec algorithm. It combines the ideas of DFS and BFS, using parameters 𝑝 and 𝑞 to control the transition probabilities of the random walk, thereby balancing the capture of community structure (local) and structural equivalence (global) information. The resulting embedding vectors can be used for downstream tasks such as node classification, clustering, or link prediction.

```python
def Process(db_: lgraph_db_python.PyGraphDB, olapondb: lgraph_db_python.PyOlapOnDB, feature_num: size_t, p: cython.double, q: cython.double, walk_length: size_t, num_walks: size_t, sample_node: list, NodeInfo: list, EdgeInfo: list):
```
Expand Down

0 comments on commit a43bf6a

Please sign in to comment.