"src/vscode:/vscode.git/clone" did not exist on "2c6a6c97b3ff07b4b80ed3b53518d42eb38d4295"
Unverified Commit 619d735d authored by Hongzhi (Steve), Chen's avatar Hongzhi (Steve), Chen Committed by GitHub
Browse files

[Misc] Replace \xxx with @XXX in structured comment. (#4822)



* param

* brief

* note

* return

* tparam

* brief2

* file

* return2

* return

* blabla

* all
Co-authored-by: default avatarSteve <ubuntu@ip-172-31-34-29.ap-northeast-1.compute.internal>
parent 96297fb8
/*! /*!
* Copyright (c) 2018 by Contributors * Copyright (c) 2018 by Contributors
* \file graph/sampler/generic_randomwalk_cpu.h * @file graph/sampler/generic_randomwalk_cpu.h
* \brief DGL sampler - templated implementation definition of random walks on * @brief DGL sampler - templated implementation definition of random walks on
* CPU * CPU
*/ */
...@@ -38,20 +38,20 @@ template <typename IdxType> ...@@ -38,20 +38,20 @@ template <typename IdxType>
using TerminatePredicate = std::function<bool(IdxType *, dgl_id_t, int64_t)>; using TerminatePredicate = std::function<bool(IdxType *, dgl_id_t, int64_t)>;
/*! /*!
* \brief Select one successor of metapath-based random walk, given the path * @brief Select one successor of metapath-based random walk, given the path
* generated so far. * generated so far.
* *
* \param data The path generated so far, of type \c IdxType. * @param data The path generated so far, of type \c IdxType.
* \param curr The last node ID generated. * @param curr The last node ID generated.
* \param len The number of nodes generated so far. Note that the seed node is * @param len The number of nodes generated so far. Note that the seed node is
* always included as \c data[0], and the successors start from \c data[1]. * always included as \c data[0], and the successors start from \c data[1].
* *
* \param edges_by_type Vector of results from \c GetAdj() by edge type. * @param edges_by_type Vector of results from \c GetAdj() by edge type.
* \param metapath_data Edge types of given metapath. * @param metapath_data Edge types of given metapath.
* \param prob Transition probability per edge type. * @param prob Transition probability per edge type.
* \param terminate Predicate for terminating the current random walk path. * @param terminate Predicate for terminating the current random walk path.
* *
* \return A tuple of ID of next successor (-1 if not exist), the last traversed * @return A tuple of ID of next successor (-1 if not exist), the last traversed
* edge ID, as well as whether to terminate. * edge ID, as well as whether to terminate.
*/ */
template <DGLDeviceType XPU, typename IdxType> template <DGLDeviceType XPU, typename IdxType>
...@@ -104,21 +104,21 @@ std::tuple<dgl_id_t, dgl_id_t, bool> MetapathRandomWalkStep( ...@@ -104,21 +104,21 @@ std::tuple<dgl_id_t, dgl_id_t, bool> MetapathRandomWalkStep(
} }
/*! /*!
* \brief Select one successor of metapath-based random walk, given the path * @brief Select one successor of metapath-based random walk, given the path
* generated so far specifically for the uniform probability distribution. * generated so far specifically for the uniform probability distribution.
* *
* \param data The path generated so far, of type \c IdxType. * @param data The path generated so far, of type \c IdxType.
* \param curr The last node ID generated. * @param curr The last node ID generated.
* \param len The number of nodes generated so far. Note that the seed node is * @param len The number of nodes generated so far. Note that the seed node is
* always included as \c data[0], and the successors start from \c data[1]. * always included as \c data[0], and the successors start from \c data[1].
* *
* \param edges_by_type Vector of results from \c GetAdj() by edge type. * @param edges_by_type Vector of results from \c GetAdj() by edge type.
* \param metapath_data Edge types of given metapath. * @param metapath_data Edge types of given metapath.
* \param prob Transition probability per edge type, for this special case this * @param prob Transition probability per edge type, for this special case this
* will be a NullArray \param terminate Predicate for terminating the current * will be a NullArray \param terminate Predicate for terminating the current
* random walk path. * random walk path.
* *
* \return A pair of ID of next successor (-1 if not exist), as well as whether * @return A pair of ID of next successor (-1 if not exist), as well as whether
* to terminate. \note This function is called only if all the probability * to terminate. \note This function is called only if all the probability
* arrays are null. * arrays are null.
*/ */
...@@ -155,9 +155,9 @@ std::tuple<dgl_id_t, dgl_id_t, bool> MetapathRandomWalkStepUniform( ...@@ -155,9 +155,9 @@ std::tuple<dgl_id_t, dgl_id_t, bool> MetapathRandomWalkStepUniform(
} }
/*! /*!
* \brief Metapath-based random walk. * @brief Metapath-based random walk.
* \param hg The heterograph. * @param hg The heterograph.
* \param seeds A 1D array of seed nodes, with the type the source type of the * @param seeds A 1D array of seed nodes, with the type the source type of the
* first edge type in the metapath. \param metapath A 1D array of edge types * first edge type in the metapath. \param metapath A 1D array of edge types
* representing the metapath. \param prob A vector of 1D float arrays, * representing the metapath. \param prob A vector of 1D float arrays,
* indicating the transition probability of each edge by edge type. An empty * indicating the transition probability of each edge by edge type. An empty
......
/*! /*!
* Copyright (c) 2021 by Contributors * Copyright (c) 2021 by Contributors
* \file graph/sampling/node2vec.cc * @file graph/sampling/node2vec.cc
* \brief Dispatcher of DGL node2vec random walks * @brief Dispatcher of DGL node2vec random walks
*/ */
#include <dgl/array.h> #include <dgl/array.h>
......
/*! /*!
* Copyright (c) 2021 by Contributors * Copyright (c) 2021 by Contributors
* \file graph/sampling/node2vec_cpu.cc * @file graph/sampling/node2vec_cpu.cc
* \brief DGL sampler - CPU implementation of node2vec random walk with OpenMP * @brief DGL sampler - CPU implementation of node2vec random walk with OpenMP
*/ */
#include <dgl/array.h> #include <dgl/array.h>
......
/*! /*!
* Copyright (c) 2021 by Contributors * Copyright (c) 2021 by Contributors
* \file graph/sampling/node2vec_impl.h * @file graph/sampling/node2vec_impl.h
* \brief DGL sampler - templated implementation definition of node2vec random * @brief DGL sampler - templated implementation definition of node2vec random
* walks * walks
*/ */
...@@ -26,14 +26,14 @@ namespace sampling { ...@@ -26,14 +26,14 @@ namespace sampling {
namespace impl { namespace impl {
/*! /*!
* \brief Node2vec random walk. * @brief Node2vec random walk.
* \param hg The heterograph. * @param hg The heterograph.
* \param seeds A 1D array of seed nodes, with the type the source type of the * @param seeds A 1D array of seed nodes, with the type the source type of the
* first edge type in the metapath. * first edge type in the metapath.
* \param p Float, indicating likelihood of immediately revisiting a node in the * @param p Float, indicating likelihood of immediately revisiting a node in the
* walk. \param q Float, control parameter to interpolate between breadth-first * walk. \param q Float, control parameter to interpolate between breadth-first
* strategy and depth-first strategy. \param walk_length Int, length of walk. * strategy and depth-first strategy. \param walk_length Int, length of walk.
* \param prob A vector of 1D float arrays, indicating the transition * @param prob A vector of 1D float arrays, indicating the transition
* probability of each edge by edge type. An empty float array assumes * probability of each edge by edge type. An empty float array assumes
* uniform transition. \return A 2D array of shape (len(seeds), len(walk_length) * uniform transition. \return A 2D array of shape (len(seeds), len(walk_length)
* + 1) with node IDs. The paths that terminated early are padded with -1. * + 1) with node IDs. The paths that terminated early are padded with -1.
......
/*! /*!
* Copyright (c) 2021 by Contributors * Copyright (c) 2021 by Contributors
* \file graph/sampling/node2vec_randomwalk.cc * @file graph/sampling/node2vec_randomwalk.cc
* \brief DGL sampler - CPU implementation of node2vec random walk. * @brief DGL sampler - CPU implementation of node2vec random walk.
*/ */
#ifndef DGL_GRAPH_SAMPLING_RANDOMWALKS_NODE2VEC_RANDOMWALK_H_ #ifndef DGL_GRAPH_SAMPLING_RANDOMWALKS_NODE2VEC_RANDOMWALK_H_
...@@ -47,15 +47,15 @@ bool has_edge_between(const CSRMatrix &csr, dgl_id_t u, dgl_id_t v) { ...@@ -47,15 +47,15 @@ bool has_edge_between(const CSRMatrix &csr, dgl_id_t u, dgl_id_t v) {
} }
/*! /*!
* \brief Node2vec random walk step function * @brief Node2vec random walk step function
* \param data The path generated so far, of type \c IdxType. * @param data The path generated so far, of type \c IdxType.
* \param curr The last node ID generated. * @param curr The last node ID generated.
* \param pre The last last node ID generated * @param pre The last last node ID generated
* \param p Float, indicating likelihood of immediately revisiting a node in the * @param p Float, indicating likelihood of immediately revisiting a node in the
* walk. * walk.
* \param q Float, control parameter to interpolate between breadth-first * @param q Float, control parameter to interpolate between breadth-first
* strategy and depth-first strategy. * strategy and depth-first strategy.
* \param len The number of nodes generated so far. Note that the seed node is * @param len The number of nodes generated so far. Note that the seed node is
* always included as \c data[0], and the successors start from \c * always included as \c data[0], and the successors start from \c
* data[1]. \param csr The CSR matrix \param prob Transition probability \param * data[1]. \param csr The CSR matrix \param prob Transition probability \param
* terminate Predicate for terminating the current random walk path. \return A * terminate Predicate for terminating the current random walk path. \return A
......
/*! /*!
* Copyright (c) 2018 by Contributors * Copyright (c) 2018 by Contributors
* \file graph/sampling/randomwalk_cpu.cc * @file graph/sampling/randomwalk_cpu.cc
* \brief DGL sampler - CPU implementation of metapath-based random walk with * @brief DGL sampler - CPU implementation of metapath-based random walk with
* OpenMP * OpenMP
*/ */
......
/*! /*!
* Copyright (c) 2021-2022 by Contributors * Copyright (c) 2021-2022 by Contributors
* \file graph/sampling/randomwalk_gpu.cu * @file graph/sampling/randomwalk_gpu.cu
* \brief CUDA random walk sampleing * @brief CUDA random walk sampleing
*/ */
#include <curand_kernel.h> #include <curand_kernel.h>
...@@ -239,7 +239,7 @@ std::pair<IdArray, IdArray> RandomWalkUniform( ...@@ -239,7 +239,7 @@ std::pair<IdArray, IdArray> RandomWalkUniform(
} }
/** /**
* \brief Random walk for biased choice. We use inverse transform sampling to * @brief Random walk for biased choice. We use inverse transform sampling to
* choose the next step. * choose the next step.
*/ */
template <DGLDeviceType XPU, typename FloatType, typename IdType> template <DGLDeviceType XPU, typename FloatType, typename IdType>
......
/*! /*!
* Copyright (c) 2018 by Contributors * Copyright (c) 2018 by Contributors
* \file graph/sampling/randomwalk_with_restart_cpu.cc * @file graph/sampling/randomwalk_with_restart_cpu.cc
* \brief DGL sampler - CPU implementation of metapath-based random walk with * @brief DGL sampler - CPU implementation of metapath-based random walk with
* restart with OpenMP * restart with OpenMP
*/ */
......
/*! /*!
* Copyright (c) 2018 by Contributors * Copyright (c) 2018 by Contributors
* \file graph/sampling/randomwalks.cc * @file graph/sampling/randomwalks.cc
* \brief Dispatcher of different DGL random walks by device type * @brief Dispatcher of different DGL random walks by device type
*/ */
#include <dgl/array.h> #include <dgl/array.h>
......
/*! /*!
* Copyright (c) 2018 by Contributors * Copyright (c) 2018 by Contributors
* \file graph/sampler/generic_randomwalk_cpu.h * @file graph/sampler/generic_randomwalk_cpu.h
* \brief DGL sampler - templated implementation definition of random walks on * @brief DGL sampler - templated implementation definition of random walks on
* CPU * CPU
*/ */
...@@ -29,8 +29,8 @@ namespace impl { ...@@ -29,8 +29,8 @@ namespace impl {
namespace { namespace {
/*! /*!
* \brief Generic Random Walk. * @brief Generic Random Walk.
* \param seeds A 1D array of seed nodes, with the type the source type of the * @param seeds A 1D array of seed nodes, with the type the source type of the
* first edge type in the metapath. \param max_num_steps The maximum number of * first edge type in the metapath. \param max_num_steps The maximum number of
* steps of a random walk path. \param step The random walk step function with * steps of a random walk path. \param step The random walk step function with
* type \c StepFunc. \param max_nodes Throws an error if one of the values in \c * type \c StepFunc. \param max_nodes Throws an error if one of the values in \c
......
/*! /*!
* Copyright (c) 2018 by Contributors * Copyright (c) 2018 by Contributors
* \file graph/sampling/randomwalks_impl.h * @file graph/sampling/randomwalks_impl.h
* \brief DGL sampler - templated implementation definition of random walks * @brief DGL sampler - templated implementation definition of random walks
*/ */
#ifndef DGL_GRAPH_SAMPLING_RANDOMWALKS_RANDOMWALKS_IMPL_H_ #ifndef DGL_GRAPH_SAMPLING_RANDOMWALKS_RANDOMWALKS_IMPL_H_
...@@ -25,7 +25,7 @@ namespace sampling { ...@@ -25,7 +25,7 @@ namespace sampling {
namespace impl { namespace impl {
/*! /*!
* \brief Random walk step function * @brief Random walk step function
*/ */
template <typename IdxType> template <typename IdxType>
using StepFunc = std::function< using StepFunc = std::function<
...@@ -36,17 +36,17 @@ using StepFunc = std::function< ...@@ -36,17 +36,17 @@ using StepFunc = std::function<
int64_t)>; // # of steps int64_t)>; // # of steps
/*! /*!
* \brief Get the node types traversed by the metapath. * @brief Get the node types traversed by the metapath.
* \return A 1D array of shape (len(metapath) + 1,) with node type IDs. * @return A 1D array of shape (len(metapath) + 1,) with node type IDs.
*/ */
template <DGLDeviceType XPU, typename IdxType> template <DGLDeviceType XPU, typename IdxType>
TypeArray GetNodeTypesFromMetapath( TypeArray GetNodeTypesFromMetapath(
const HeteroGraphPtr hg, const TypeArray metapath); const HeteroGraphPtr hg, const TypeArray metapath);
/*! /*!
* \brief Metapath-based random walk. * @brief Metapath-based random walk.
* \param hg The heterograph. * @param hg The heterograph.
* \param seeds A 1D array of seed nodes, with the type the source type of the * @param seeds A 1D array of seed nodes, with the type the source type of the
* first edge type in the metapath. \param metapath A 1D array of edge types * first edge type in the metapath. \param metapath A 1D array of edge types
* representing the metapath. \param prob A vector of 1D float arrays, * representing the metapath. \param prob A vector of 1D float arrays,
* indicating the transition probability of each edge by edge type. An empty * indicating the transition probability of each edge by edge type. An empty
...@@ -63,9 +63,9 @@ std::pair<IdArray, IdArray> RandomWalk( ...@@ -63,9 +63,9 @@ std::pair<IdArray, IdArray> RandomWalk(
const std::vector<FloatArray> &prob); const std::vector<FloatArray> &prob);
/*! /*!
* \brief Metapath-based random walk with restart probability. * @brief Metapath-based random walk with restart probability.
* \param hg The heterograph. * @param hg The heterograph.
* \param seeds A 1D array of seed nodes, with the type the source type of the * @param seeds A 1D array of seed nodes, with the type the source type of the
* first edge type in the metapath. \param metapath A 1D array of edge types * first edge type in the metapath. \param metapath A 1D array of edge types
* representing the metapath. \param prob A vector of 1D float arrays, * representing the metapath. \param prob A vector of 1D float arrays,
* indicating the transition probability of each edge by edge type. An empty * indicating the transition probability of each edge by edge type. An empty
...@@ -83,10 +83,10 @@ std::pair<IdArray, IdArray> RandomWalkWithRestart( ...@@ -83,10 +83,10 @@ std::pair<IdArray, IdArray> RandomWalkWithRestart(
const std::vector<FloatArray> &prob, double restart_prob); const std::vector<FloatArray> &prob, double restart_prob);
/*! /*!
* \brief Metapath-based random walk with stepwise restart probability. Useful * @brief Metapath-based random walk with stepwise restart probability. Useful
* for PinSAGE-like models. * for PinSAGE-like models.
* \param hg The heterograph. * @param hg The heterograph.
* \param seeds A 1D array of seed nodes, with the type the source type of the * @param seeds A 1D array of seed nodes, with the type the source type of the
* first edge type in the metapath. \param metapath A 1D array of edge types * first edge type in the metapath. \param metapath A 1D array of edge types
* representing the metapath. \param prob A vector of 1D float arrays, * representing the metapath. \param prob A vector of 1D float arrays,
* indicating the transition probability of each edge by edge type. An empty * indicating the transition probability of each edge by edge type. An empty
......
/*! /*!
* Copyright (c) 2019 by Contributors * Copyright (c) 2019 by Contributors
* \file graph/serialize/dglgraph_data.h * @file graph/serialize/dglgraph_data.h
* \brief Graph serialization header * @brief Graph serialization header
*/ */
#ifndef DGL_GRAPH_SERIALIZE_DGLGRAPH_DATA_H_ #ifndef DGL_GRAPH_SERIALIZE_DGLGRAPH_DATA_H_
#define DGL_GRAPH_SERIALIZE_DGLGRAPH_DATA_H_ #define DGL_GRAPH_SERIALIZE_DGLGRAPH_DATA_H_
...@@ -56,7 +56,7 @@ class GraphData : public runtime::ObjectRef { ...@@ -56,7 +56,7 @@ class GraphData : public runtime::ObjectRef {
public: public:
DGL_DEFINE_OBJECT_REF_METHODS(GraphData, runtime::ObjectRef, GraphDataObject); DGL_DEFINE_OBJECT_REF_METHODS(GraphData, runtime::ObjectRef, GraphDataObject);
/*! \brief create a new GraphData reference */ /*! @brief create a new GraphData reference */
static GraphData Create() { static GraphData Create() {
return GraphData(std::make_shared<GraphDataObject>()); return GraphData(std::make_shared<GraphDataObject>());
} }
......
/*! /*!
* Copyright (c) 2019 by Contributors * Copyright (c) 2019 by Contributors
* \file graph/serialize/graph_serialize.cc * @file graph/serialize/graph_serialize.cc
* \brief Graph serialization implementation * @brief Graph serialization implementation
* *
* The storage structure is * The storage structure is
* { * {
......
/*! /*!
* Copyright (c) 2019 by Contributors * Copyright (c) 2019 by Contributors
* \file graph/serialize/graph_serialize.cc * @file graph/serialize/graph_serialize.cc
* \brief Graph serialization implementation * @brief Graph serialization implementation
* *
* The storage structure is * The storage structure is
* { * {
......
/*! /*!
* Copyright (c) 2019 by Contributors * Copyright (c) 2019 by Contributors
* \file graph/serialize/graph_serialize.h * @file graph/serialize/graph_serialize.h
* \brief Graph serialization header * @brief Graph serialization header
*/ */
#ifndef DGL_GRAPH_SERIALIZE_GRAPH_SERIALIZE_H_ #ifndef DGL_GRAPH_SERIALIZE_GRAPH_SERIALIZE_H_
#define DGL_GRAPH_SERIALIZE_GRAPH_SERIALIZE_H_ #define DGL_GRAPH_SERIALIZE_GRAPH_SERIALIZE_H_
...@@ -76,7 +76,7 @@ class StorageMetaData : public runtime::ObjectRef { ...@@ -76,7 +76,7 @@ class StorageMetaData : public runtime::ObjectRef {
DGL_DEFINE_OBJECT_REF_METHODS( DGL_DEFINE_OBJECT_REF_METHODS(
StorageMetaData, runtime::ObjectRef, StorageMetaDataObject); StorageMetaData, runtime::ObjectRef, StorageMetaDataObject);
/*! \brief create a new StorageMetaData reference */ /*! @brief create a new StorageMetaData reference */
static StorageMetaData Create() { static StorageMetaData Create() {
return StorageMetaData(std::make_shared<StorageMetaDataObject>()); return StorageMetaData(std::make_shared<StorageMetaDataObject>());
} }
......
/*! /*!
* Copyright (c) 2019 by Contributors * Copyright (c) 2019 by Contributors
* \file graph/serialize/heterograph_data.h * @file graph/serialize/heterograph_data.h
* \brief Graph serialization header * @brief Graph serialization header
*/ */
#ifndef DGL_GRAPH_SERIALIZE_HETEROGRAPH_DATA_H_ #ifndef DGL_GRAPH_SERIALIZE_HETEROGRAPH_DATA_H_
#define DGL_GRAPH_SERIALIZE_HETEROGRAPH_DATA_H_ #define DGL_GRAPH_SERIALIZE_HETEROGRAPH_DATA_H_
...@@ -97,7 +97,7 @@ class HeteroGraphData : public runtime::ObjectRef { ...@@ -97,7 +97,7 @@ class HeteroGraphData : public runtime::ObjectRef {
DGL_DEFINE_OBJECT_REF_METHODS( DGL_DEFINE_OBJECT_REF_METHODS(
HeteroGraphData, runtime::ObjectRef, HeteroGraphDataObject); HeteroGraphData, runtime::ObjectRef, HeteroGraphDataObject);
/*! \brief create a new GraphData reference */ /*! @brief create a new GraphData reference */
static HeteroGraphData Create( static HeteroGraphData Create(
HeteroGraphPtr gptr, List<Map<std::string, Value>> node_tensors, HeteroGraphPtr gptr, List<Map<std::string, Value>> node_tensors,
List<Map<std::string, Value>> edge_tensors, List<Value> ntype_names, List<Map<std::string, Value>> edge_tensors, List<Value> ntype_names,
...@@ -106,7 +106,7 @@ class HeteroGraphData : public runtime::ObjectRef { ...@@ -106,7 +106,7 @@ class HeteroGraphData : public runtime::ObjectRef {
gptr, node_tensors, edge_tensors, ntype_names, etype_names)); gptr, node_tensors, edge_tensors, ntype_names, etype_names));
} }
/*! \brief create an empty GraphData reference */ /*! @brief create an empty GraphData reference */
static HeteroGraphData Create() { static HeteroGraphData Create() {
return HeteroGraphData(std::make_shared<HeteroGraphDataObject>()); return HeteroGraphData(std::make_shared<HeteroGraphDataObject>());
} }
......
/*! /*!
* Copyright (c) 2019 by Contributors * Copyright (c) 2019 by Contributors
* \file graph/serialize/heterograph_serialize.cc * @file graph/serialize/heterograph_serialize.cc
* \brief DGLHeteroGraph serialization implementation * @brief DGLHeteroGraph serialization implementation
* *
* The storage structure is * The storage structure is
* { * {
......
/*! /*!
* Copyright (c) 2019 by Contributors * Copyright (c) 2019 by Contributors
* \file graph/serialize/tensor_serialize.cc * @file graph/serialize/tensor_serialize.cc
* \brief Graph serialization implementation * @brief Graph serialization implementation
*/ */
#include <dgl/packed_func_ext.h> #include <dgl/packed_func_ext.h>
#include <dgl/runtime/container.h> #include <dgl/runtime/container.h>
......
/*! /*!
* Copyright (c) 2020-2022 by Contributors * Copyright (c) 2020-2022 by Contributors
* \file graph/serailize/zerocopy_serializer.cc * @file graph/serailize/zerocopy_serializer.cc
* \brief serializer implementation. * @brief serializer implementation.
*/ */
#include <dgl/zerocopy_serializer.h> #include <dgl/zerocopy_serializer.h>
......
/*! /*!
* Copyright (c) 2018 by Contributors * Copyright (c) 2018 by Contributors
* \file graph/shared_mem_manager.cc * @file graph/shared_mem_manager.cc
* \brief DGL sampler implementation * @brief DGL sampler implementation
*/ */
#include "shared_mem_manager.h" #include "shared_mem_manager.h"
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment