00001 /* 00002 This file is part of GraphLab. 00003 00004 GraphLab is free software: you can redistribute it and/or modify 00005 it under the terms of the GNU Lesser General Public License as 00006 published by the Free Software Foundation, either version 3 of 00007 the License, or (at your option) any later version. 00008 00009 GraphLab is distributed in the hope that it will be useful, 00010 but WITHOUT ANY WARRANTY; without even the implied warranty of 00011 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00012 GNU Lesser General Public License for more details. 00013 00014 You should have received a copy of the GNU Lesser General Public 00015 License along with GraphLab. If not, see <http://www.gnu.org/licenses/>. 00016 */ 00017 00018 #ifndef GRAPHLAB_MASTER_INCLUDES 00019 #define GRAPHLAB_MASTER_INCLUDES 00020 00021 00022 00023 // 00024 00025 #include <graphlab/engine/engine_includes.hpp> 00026 #include <graphlab/factors/factor_includes.hpp> 00027 #include <graphlab/graph/graph_includes.hpp> 00028 #include <graphlab/logger/logger_includes.hpp> 00029 #include <graphlab/monitoring/monitoring_includes.hpp> 00030 #include <graphlab/parallel/parallel_includes.hpp> 00031 #include <graphlab/schedulers/scheduler_includes.hpp> 00032 #include <graphlab/scope/scope_includes.hpp> 00033 #include <graphlab/serialization/serialization_includes.hpp> 00034 #include <graphlab/shared_data/shared_data_includes.hpp> 00035 #include <graphlab/tasks/task_includes.hpp> 00036 #include <graphlab/util/util_includes.hpp> 00037 00038 #include <graphlab/core.hpp> 00039 00040 00041 00042 00043 /** 00044 \namespace graphlab 00045 \brief The namespace containing all graphlab objects and functions. 00046 00047 All objects and functions used in graphlab are contained within the 00048 graphlab namespace. Forexample to access the graph type a user 00049 must therefore either include the graphlab namespace or use: 00050 00051 <code> 00052 graphlab::graph<VertexType, EdgeType> 00053 </code> 00054 00055 Because most of the graphlab types depend on the graph type we have 00056 created a templated struct called graphlab::types. \todo finish 00057 explanation. 00058 00059 */ 00060 namespace graphlab { 00061 00062 /** 00063 \brief A types datastructure which provides convenient specializations of all 00064 user-facing GraphLab types. 00065 00066 GraphLab is heavily templatized. The graphlab::types object provides a 00067 convenient way to access the GraphLab classes without requiring excessive 00068 angle brackets (< , >). The GraphLab types object is located in <graphlab.hpp>. 00069 To define a graphlab type object: 00070 00071 \code 00072 typedef graphlab::graph<vertex_data, edge_data> graph_type; 00073 typedef graphlab::types<graph_type> gl; 00074 \endcode 00075 00076 Now we can use gl::... to access all the available graphlab types. 00077 */ 00078 template<typename Graph> 00079 struct types { 00080 /// \brief The type of the Graph. 00081 typedef Graph graph; 00082 00083 typedef graphlab::disk_graph<typename Graph::vertex_data_type, 00084 typename Graph::edge_data_type> disk_graph; 00085 00086 /** \brief A convenient wrapper object around the commonly used 00087 portions of GraphLab. This is useful for most GraphLab 00088 applications. See the \ref graphlab::core object for more details. 00089 */ 00090 typedef graphlab::core<typename graph::vertex_data_type, 00091 typename graph::edge_data_type> core; 00092 00093 00094 typedef graphlab::command_line_options command_line_options; 00095 typedef graphlab::engine_options engine_options; 00096 00097 /// \brief The type of the data stored on each vertex of the Graph. 00098 typedef typename graph::vertex_data_type vertex_data_type; 00099 00100 /// \brief The type of the data stored on each edge of the Graph. 00101 typedef typename graph::edge_data_type edge_data_type; 00102 00103 typedef graphlab::update_task<graph> update_task; 00104 typedef typename update_task::update_function_type update_function; 00105 00106 typedef graphlab::iscope<graph> iscope; 00107 typedef graphlab::ischeduler<graph> ischeduler; 00108 typedef graphlab::icallback<graph> icallback; 00109 typedef graphlab::iengine<graph> iengine; 00110 typedef graphlab::imonitor<graph> imonitor; 00111 00112 typedef graphlab::glshared_sync_ops<Graph> glshared_sync_ops; 00113 typedef graphlab::glshared_apply_ops glshared_apply_ops; 00114 typedef graphlab::glshared_merge_ops glshared_merge_ops; 00115 00116 00117 00118 template<typename Scheduler, typename ScopeFactory> 00119 class asynchronous_engine: public graphlab::asynchronous_engine<graph, Scheduler, ScopeFactory> { }; 00120 00121 00122 typedef graphlab::fifo_scheduler<graph> fifo_scheduler; 00123 typedef graphlab::priority_scheduler<graph> priority_scheduler; 00124 typedef graphlab::sampling_scheduler<graph> sampling_scheduler; 00125 typedef graphlab::sweep_scheduler<graph> sweep_scheduler; 00126 typedef graphlab::multiqueue_fifo_scheduler<graph> multiqueue_fifo_scheduler; 00127 typedef graphlab::multiqueue_priority_scheduler<graph> multiqueue_priority_scheduler; 00128 typedef graphlab::clustered_priority_scheduler<graph> clustered_priority_scheduler; 00129 typedef graphlab::round_robin_scheduler<graph> round_robin_scheduler; 00130 typedef graphlab::chromatic_scheduler<graph> chromatic_scheduler; 00131 00132 00133 00134 00135 00136 00137 /// \brief The type of id assigned to each vertex. Equivalent to graphlab::vertex_id_t 00138 typedef graphlab::vertex_id_t vertex_id_t; 00139 /// \brief The type of id assigned to each vertex. Equivalent to graphlab::edge_id_t 00140 typedef graphlab::edge_id_t edge_id_t; 00141 00142 typedef typename graph::edge_list_type edge_list; 00143 00144 typedef graphlab::scheduler_options scheduler_options; 00145 typedef graphlab::sched_status sched_status; 00146 typedef graphlab::partition_method partition_method; 00147 typedef graphlab::scope_range scope_range; 00148 00149 template <typename T> 00150 class glshared:public graphlab::glshared<T> { }; 00151 00152 template <typename T> 00153 class glshared_const:public graphlab::glshared_const<T> { }; 00154 }; 00155 00156 } 00157 00158 00159 #endif 00160
1.7.1