Skip to main content

train_node2vec_cpu

Function train_node2vec_cpu 

Source
pub fn train_node2vec_cpu(
    walks: Vec<Vec<u32>>,
    vocab_size: usize,
    args: CpuTrainArgs,
    neg_table: Arc<Vec<usize>>,
    seed: usize,
) -> (Matrix, Matrix)
Expand description

Train node2vec model on generated walks

§Params

  • walks - The generated random walks
  • vocab_size - Size of vocabulary (number of unique nodes)
  • args - Training arguments
  • neg_table - Negative sampling table
  • seed - Random seed for reproducibility

§Returns

Tuple of (input_matrix, output_matrix) containing learned embeddings