Zoltan::LoadBalance Class Reference

Zoltan::LoadBalance: A class for interfacing the Load Balancing functions of the Zoltan library in a C++/Object Oriented environment. More...

#include <Zoltan_LoadBalance.h>

List of all members.

Constructors/Destructors.

 LoadBalance (int argc=0, char **argv=0, float *ver=0)
 Constructor.
 ~LoadBalance ()
 Destructor.

General Load Balance Functionality

int Create (MPI_Comm communicator)
 Replaces Zoltan_Create.
int Set_QueryObject (QueryObject *query_obj_ptr)
 Register UserDerived/ApplicationSpecific Query Object to support callbacks.
int Set_MigrationObject (MigrationObject *migration_obj_ptr)
 Register UserDerived/ApplicationSpecific Migration Object to support callbacks.
int Set_Param (const std::string &param, const std::string &value)
 Replaces Zoltan_Set_Param.
int Balance (int *changes, int *num_gid_entries, int *num_lid_entries, int *num_import, ZOLTAN_ID_PTR *import_global_ids, ZOLTAN_ID_PTR *import_local_ids, int **import_procs, int *num_export, ZOLTAN_ID_PTR *export_global_ids, ZOLTAN_ID_PTR *export_local_ids, int **export_procs)
 Replaces Zoltan_LB_Balance.
void Evaluate (int print_stats, int *num_objects, float *object_weights, int *num_cut, float *cut_weights, int *num_boundary_objects, int *num_adj_procs)
 Replaces Zoltan_LB_Eval.
int Free_Data (ZOLTAN_ID_PTR *import_global_ids, ZOLTAN_ID_PTR *import_local_ids, int **import_procs, ZOLTAN_ID_PTR *export_global_ids, ZOLTAN_ID_PTR *export_local_ids, int **export_procs)
 Replaces Zoltan_LB_Free_Data.

Support for direct access to Zoltan callback functionality

int Set_Num_Edges_Fn (ZOLTAN_NUM_EDGES_FN *fn_ptr, void *data=0)
 Individual callback support.
int Set_Edge_List_Fn (ZOLTAN_EDGE_LIST_FN *fn_ptr, void *data=0)
int Set_Num_Geom_Fn (ZOLTAN_NUM_GEOM_FN *fn_ptr, void *data=0)
int Set_Geom_Fn (ZOLTAN_GEOM_FN *fn_ptr, void *data=0)
int Set_Num_Obj_Fn (ZOLTAN_NUM_OBJ_FN *fn_ptr, void *data=0)
int Set_Obj_List_Fn (ZOLTAN_OBJ_LIST_FN *fn_ptr, void *data=0)
int Set_First_Obj_Fn (ZOLTAN_FIRST_OBJ_FN *fn_ptr, void *data=0)
int Set_Next_Obj_Fn (ZOLTAN_NEXT_OBJ_FN *fn_ptr, void *data=0)
int Set_Num_Border_Obj_Fn (ZOLTAN_NUM_BORDER_OBJ_FN *fn_ptr, void *data=0)
int Set_Border_Obj_List_Fn (ZOLTAN_BORDER_OBJ_LIST_FN *fn_ptr, void *data=0)
int Set_First_Border_Obj_Fn (ZOLTAN_FIRST_BORDER_OBJ_FN *fn_ptr, void *data=0)
int Set_Next_Border_Obj_Fn (ZOLTAN_NEXT_BORDER_OBJ_FN *fn_ptr, void *data=0)
int Set_Num_Coarse_Obj_Fn (ZOLTAN_NUM_COARSE_OBJ_FN *fn_ptr, void *data=0)
int Set_Coarse_Obj_List_Fn (ZOLTAN_COARSE_OBJ_LIST_FN *fn_ptr, void *data=0)
int Set_First_Coarse_Obj_Fn (ZOLTAN_FIRST_COARSE_OBJ_FN *fn_ptr, void *data=0)
int Set_Next_Coarse_Obj_Fn (ZOLTAN_NEXT_COARSE_OBJ_FN *fn_ptr, void *data=0)
int Set_Num_Child_Fn (ZOLTAN_NUM_CHILD_FN *fn_ptr, void *data=0)
int Set_Child_List_Fn (ZOLTAN_CHILD_LIST_FN *fn_ptr, void *data=0)
int Set_Child_Weight_Fn (ZOLTAN_CHILD_WEIGHT_FN *fn_ptr, void *data=0)
int Set_Pre_Migrate_Fn (ZOLTAN_PRE_MIGRATE_FN *fn_ptr, void *data=0)
int Set_Mid_Migrate_Fn (ZOLTAN_MID_MIGRATE_FN *fn_ptr, void *data=0)
int Set_Post_Migrate_Fn (ZOLTAN_POST_MIGRATE_FN *fn_ptr, void *data=0)
int Set_Obj_Size_Fn (ZOLTAN_OBJ_SIZE_FN *fn_ptr, void *data=0)
int Set_Pack_Obj_Fn (ZOLTAN_PACK_OBJ_FN *fn_ptr, void *data=0)
int Set_Unpack_Obj_Fn (ZOLTAN_UNPACK_OBJ_FN *fn_ptr, void *data=0)

Decomposition Augmentation

int Point_Assign (double *coords, int *proc)
 Replaces Zoltan_LB_Point_Assign.
int Box_Assign (double xmin, double ymin, double zmin, double xmax, double ymax, double zmax, int *procs, int *numprocs)
 Replaces Zoltan_LB_Box_Assign.

Migration Funtionality

int Compute_Destinations (int num_import, ZOLTAN_ID_PTR import_global_ids, ZOLTAN_ID_PTR import_local_ids, int *import_procs, int *num_export, ZOLTAN_ID_PTR *export_global_ids, ZOLTAN_ID_PTR *export_local_ids, int **export_procs)
 Replaces Zoltan_Compute_Destinations.
int Help_Migrate (int num_import, ZOLTAN_ID_PTR import_global_ids, ZOLTAN_ID_PTR import_local_ids, int *import_procs, int num_export, ZOLTAN_ID_PTR export_global_ids, ZOLTAN_ID_PTR export_local_ids, int *export_procs)
 Replaces Zoltan_Help_Migrate.

Extra

Zoltan_Struct * Return_Zoltan_Struct ()
 Direct access to underlying Zoltan_Struct Object.

Private Attributes

int ObjectID
Zoltan_Struct * LoadBalance_Ptr_
QueryObjectQueryObject_Ptr_
MigrationObjectMigrationObject_Ptr_

Static Private Attributes

int ObjectCount = 0


Detailed Description

Zoltan::LoadBalance: A class for interfacing the Load Balancing functions of the Zoltan library in a C++/Object Oriented environment.

The Zoltan::LoadBalance class is a wrapper for the C functions at the top level interface of Zoltan. The primary differences include the removal the Zoltan_Struct parameter since this object is now stored in the class and the use of user derived classes from Zoltan::QueryObject and Zoltan::MigrationObject for support of the "callback" functionality used by Zoltan.

Definition at line 35 of file Zoltan_LoadBalance.h.


Constructor & Destructor Documentation

Zoltan::LoadBalance::LoadBalance int  argc = 0,
char **  argv = 0,
float *  ver = 0
 

Constructor.

This constructor replaces the Zoltan_Initialize call. Params are the same.

Definition at line 36 of file Zoltan_LoadBalance.cpp.

Zoltan::LoadBalance::~LoadBalance  ) 
 

Destructor.

Definition at line 49 of file Zoltan_LoadBalance.cpp.


Member Function Documentation

int Zoltan::LoadBalance::Create MPI_Comm  communicator  ) 
 

Replaces Zoltan_Create.

Definition at line 55 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_QueryObject QueryObject query_obj_ptr  ) 
 

Register UserDerived/ApplicationSpecific Query Object to support callbacks.

Definition at line 234 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_MigrationObject MigrationObject migration_obj_ptr  ) 
 

Register UserDerived/ApplicationSpecific Migration Object to support callbacks.

Definition at line 345 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_Param const std::string &  param,
const std::string &  value
 

Replaces Zoltan_Set_Param.

Definition at line 387 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Balance int *  changes,
int *  num_gid_entries,
int *  num_lid_entries,
int *  num_import,
ZOLTAN_ID_PTR *  import_global_ids,
ZOLTAN_ID_PTR *  import_local_ids,
int **  import_procs,
int *  num_export,
ZOLTAN_ID_PTR *  export_global_ids,
ZOLTAN_ID_PTR *  export_local_ids,
int **  export_procs
 

Replaces Zoltan_LB_Balance.

Definition at line 394 of file Zoltan_LoadBalance.cpp.

void Zoltan::LoadBalance::Evaluate int  print_stats,
int *  num_objects,
float *  object_weights,
int *  num_cut,
float *  cut_weights,
int *  num_boundary_objects,
int *  num_adj_procs
 

Replaces Zoltan_LB_Eval.

Definition at line 432 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Free_Data ZOLTAN_ID_PTR *  import_global_ids,
ZOLTAN_ID_PTR *  import_local_ids,
int **  import_procs,
ZOLTAN_ID_PTR *  export_global_ids,
ZOLTAN_ID_PTR *  export_local_ids,
int **  export_procs
 

Replaces Zoltan_LB_Free_Data.

Definition at line 444 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_Num_Edges_Fn ZOLTAN_NUM_EDGES_FN *  fn_ptr,
void *  data = 0
 

Individual callback support.

Definition at line 82 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_Edge_List_Fn ZOLTAN_EDGE_LIST_FN *  fn_ptr,
void *  data = 0
 

Definition at line 88 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_Num_Geom_Fn ZOLTAN_NUM_GEOM_FN *  fn_ptr,
void *  data = 0
 

Definition at line 94 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_Geom_Fn ZOLTAN_GEOM_FN *  fn_ptr,
void *  data = 0
 

Definition at line 100 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_Num_Obj_Fn ZOLTAN_NUM_OBJ_FN *  fn_ptr,
void *  data = 0
 

Definition at line 106 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_Obj_List_Fn ZOLTAN_OBJ_LIST_FN *  fn_ptr,
void *  data = 0
 

Definition at line 112 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_First_Obj_Fn ZOLTAN_FIRST_OBJ_FN *  fn_ptr,
void *  data = 0
 

Definition at line 118 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_Next_Obj_Fn ZOLTAN_NEXT_OBJ_FN *  fn_ptr,
void *  data = 0
 

Definition at line 124 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_Num_Border_Obj_Fn ZOLTAN_NUM_BORDER_OBJ_FN *  fn_ptr,
void *  data = 0
 

Definition at line 130 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_Border_Obj_List_Fn ZOLTAN_BORDER_OBJ_LIST_FN *  fn_ptr,
void *  data = 0
 

Definition at line 136 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_First_Border_Obj_Fn ZOLTAN_FIRST_BORDER_OBJ_FN *  fn_ptr,
void *  data = 0
 

Definition at line 142 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_Next_Border_Obj_Fn ZOLTAN_NEXT_BORDER_OBJ_FN *  fn_ptr,
void *  data = 0
 

Definition at line 148 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_Num_Coarse_Obj_Fn ZOLTAN_NUM_COARSE_OBJ_FN *  fn_ptr,
void *  data = 0
 

Definition at line 154 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_Coarse_Obj_List_Fn ZOLTAN_COARSE_OBJ_LIST_FN *  fn_ptr,
void *  data = 0
 

Definition at line 160 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_First_Coarse_Obj_Fn ZOLTAN_FIRST_COARSE_OBJ_FN *  fn_ptr,
void *  data = 0
 

Definition at line 166 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_Next_Coarse_Obj_Fn ZOLTAN_NEXT_COARSE_OBJ_FN *  fn_ptr,
void *  data = 0
 

Definition at line 172 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_Num_Child_Fn ZOLTAN_NUM_CHILD_FN *  fn_ptr,
void *  data = 0
 

Definition at line 178 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_Child_List_Fn ZOLTAN_CHILD_LIST_FN *  fn_ptr,
void *  data = 0
 

Definition at line 184 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_Child_Weight_Fn ZOLTAN_CHILD_WEIGHT_FN *  fn_ptr,
void *  data = 0
 

Definition at line 190 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_Pre_Migrate_Fn ZOLTAN_PRE_MIGRATE_FN *  fn_ptr,
void *  data = 0
 

Definition at line 196 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_Mid_Migrate_Fn ZOLTAN_MID_MIGRATE_FN *  fn_ptr,
void *  data = 0
 

Definition at line 202 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_Post_Migrate_Fn ZOLTAN_POST_MIGRATE_FN *  fn_ptr,
void *  data = 0
 

Definition at line 208 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_Obj_Size_Fn ZOLTAN_OBJ_SIZE_FN *  fn_ptr,
void *  data = 0
 

Definition at line 214 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_Pack_Obj_Fn ZOLTAN_PACK_OBJ_FN *  fn_ptr,
void *  data = 0
 

Definition at line 220 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Set_Unpack_Obj_Fn ZOLTAN_UNPACK_OBJ_FN *  fn_ptr,
void *  data = 0
 

Definition at line 226 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Point_Assign double *  coords,
int *  proc
 

Replaces Zoltan_LB_Point_Assign.

Definition at line 456 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Box_Assign double  xmin,
double  ymin,
double  zmin,
double  xmax,
double  ymax,
double  zmax,
int *  procs,
int *  numprocs
 

Replaces Zoltan_LB_Box_Assign.

Definition at line 462 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Compute_Destinations int  num_import,
ZOLTAN_ID_PTR  import_global_ids,
ZOLTAN_ID_PTR  import_local_ids,
int *  import_procs,
int *  num_export,
ZOLTAN_ID_PTR *  export_global_ids,
ZOLTAN_ID_PTR *  export_local_ids,
int **  export_procs
 

Replaces Zoltan_Compute_Destinations.

Definition at line 476 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::Help_Migrate int  num_import,
ZOLTAN_ID_PTR  import_global_ids,
ZOLTAN_ID_PTR  import_local_ids,
int *  import_procs,
int  num_export,
ZOLTAN_ID_PTR  export_global_ids,
ZOLTAN_ID_PTR  export_local_ids,
int *  export_procs
 

Replaces Zoltan_Help_Migrate.

Definition at line 490 of file Zoltan_LoadBalance.cpp.

Zoltan_Struct* Zoltan::LoadBalance::Return_Zoltan_Struct  )  [inline]
 

Direct access to underlying Zoltan_Struct Object.

Definition at line 248 of file Zoltan_LoadBalance.h.


Member Data Documentation

int Zoltan::LoadBalance::ObjectCount = 0 [static, private]
 

Definition at line 34 of file Zoltan_LoadBalance.cpp.

int Zoltan::LoadBalance::ObjectID [private]
 

Definition at line 257 of file Zoltan_LoadBalance.h.

Zoltan_Struct* Zoltan::LoadBalance::LoadBalance_Ptr_ [private]
 

Definition at line 259 of file Zoltan_LoadBalance.h.

QueryObject* Zoltan::LoadBalance::QueryObject_Ptr_ [private]
 

Definition at line 261 of file Zoltan_LoadBalance.h.

MigrationObject* Zoltan::LoadBalance::MigrationObject_Ptr_ [private]
 

Definition at line 262 of file Zoltan_LoadBalance.h.


The documentation for this class was generated from the following files:
Generated on Thu Sep 18 12:32:07 2008 for EpetraExt Package Browser (Single Doxygen Collection) by doxygen 1.3.9.1