Turi Create  4.0
triangle_counting.hpp
1 /* Copyright © 2017 Apple Inc. All rights reserved.
2  *
3  * Use of this source code is governed by a BSD-3-clause license that can
4  * be found in the LICENSE.txt file or at https://opensource.org/licenses/BSD-3-Clause
5  */
6 #include <model_server/lib/toolkit_function_specification.hpp>
7 #ifndef TURI_UNITY_TRIANGLE_COUNTING
8 #define TURI_UNITY_TRIANGLE_COUNTING
9 
10 namespace turi {
11 namespace triangle_counting {
12 /**
13  * Obtains the registration for the Triangle Counting Toolkit
14  *
15  * Counts the number of undirected triangles in the graph.
16  * <b> Toolkit Name: triangle_counting </b>
17  *
18  * Accepted Parameters: None
19  *
20  * Returned Parameters:
21  * \li \b training_time (flexible_type: float). The training time of the algorithm in seconds
22  * excluding all other preprocessing stages.
23  *
24  * \li \b num_triangles (flexible_type: int) The total number of triangles found
25  *
26  * \li \b __graph__ (unity_graph). The graph object with the field "triangle_count",
27  * The triangle_count field (integer) on each vertex contains the number of
28  * triangles each vertex is involved in.
29  */
30 std::vector<toolkit_function_specification> get_toolkit_function_registration();
31 
32 } // namespace triangle_counting
33 } // namespace turi
34 #endif