Public Member Functions | Private Member Functions | Private Attributes
CudaBelief< dim > Class Template Reference

Templated Belief Propagation. More...

#include <cudabelieft.h>

List of all members.

Public Member Functions

 CudaBelief (int w, int h, bool copyFromHost=true)
 Constructor.
void Execute (float **priors, float **beliefs, float *costh_d, float *costv_d)
 Execute Belief propagation on GPU.
void Execute (float **priors, float **beliefs, float *costh_d, float *costv_d, int loops, int depth)
 Execute Belief propagation on GPU.
 ~CudaBelief ()

Private Member Functions

void CollectMessages (float *costh_d, float *costv_d, int loop)
 Collect the messages send from node to node.
void ComputeBeliefs (int loop)
 Execute Belief Propagation.

Private Attributes

unsigned char * allocated_d
 Allocated space on GPU.
float * belief_d [dim]
bool copyFromHost
 Whether or not to allocate space on GPU.
int height
float * msgd_d [2 *dim]
float * msgl_d [2 *dim]
 Messages to left and right.
float * msgr_d [2 *dim]
float * msgu_d [2 *dim]
 Messages to top and bottom.
float * prior_d [dim]
 Space for priors and beliefs.
int width
 Image size.

Detailed Description

template<int dim>
class CudaBelief< dim >

Templated Belief Propagation.

Templated Belief Propagation given a foreground object id

Parameters:
dimID of foreground object

Definition at line 42 of file cudabelieft.h.


Constructor & Destructor Documentation

template<int dim>
CudaBelief< dim >::CudaBelief ( int  w,
int  h,
bool  copyFromHost = true 
)

Constructor.

Segmentation

Parameters:
wWidth of the Image
hHeight of the Image
copyFromHostWhether or not to allocate memory on the GPU for priors and beliefs
template<int dim>
CudaBelief< dim >::~CudaBelief ( )

Member Function Documentation

template<int dim>
void CudaBelief< dim >::CollectMessages ( float *  costh_d,
float *  costv_d,
int  loop 
) [private]

Collect the messages send from node to node.

Collect the messages send from node to node

Parameters:
costh_dSpace for horizontal messages (left and right)
costv_dSpace for vertical messages (top and bottom)
loopLoop id
template<int dim>
void CudaBelief< dim >::ComputeBeliefs ( int  loop) [private]

Execute Belief Propagation.

Execute Loopy Belief Propagation on GPU for some iterations

Parameters:
loopNumber of iterations
template<int dim>
void CudaBelief< dim >::Execute ( float **  priors,
float **  beliefs,
float *  costh_d,
float *  costv_d 
)

Execute Belief propagation on GPU.

Execute Belief propagation on GPU

Parameters:
priorsPrior probabilities
beliefsSpace for beliefs
costh_dHorizontal costs
costv_dVertical costs
template<int dim>
void CudaBelief< dim >::Execute ( float **  priors,
float **  beliefs,
float *  costh_d,
float *  costv_d,
int  loops,
int  depth 
)

Execute Belief propagation on GPU.

Execute Belief propagation on GPU

Parameters:
priorsPrior probabilities
beliefsSpace for beliefs
costh_dHorizontal costs
costv_dVertical costs
loopsNumber of iterations
depthDepth of propagation

Member Data Documentation

template<int dim>
unsigned char* CudaBelief< dim >::allocated_d [private]

Allocated space on GPU.

Definition at line 47 of file cudabelieft.h.

template<int dim>
float * CudaBelief< dim >::belief_d[dim] [private]

Definition at line 53 of file cudabelieft.h.

template<int dim>
bool CudaBelief< dim >::copyFromHost [private]

Whether or not to allocate space on GPU.

Definition at line 45 of file cudabelieft.h.

template<int dim>
int CudaBelief< dim >::height [private]

Definition at line 55 of file cudabelieft.h.

template<int dim>
float * CudaBelief< dim >::msgd_d[2 *dim] [private]

Definition at line 51 of file cudabelieft.h.

template<int dim>
float* CudaBelief< dim >::msgl_d[2 *dim] [private]

Messages to left and right.

Definition at line 49 of file cudabelieft.h.

template<int dim>
float * CudaBelief< dim >::msgr_d[2 *dim] [private]

Definition at line 49 of file cudabelieft.h.

template<int dim>
float* CudaBelief< dim >::msgu_d[2 *dim] [private]

Messages to top and bottom.

Definition at line 51 of file cudabelieft.h.

template<int dim>
float* CudaBelief< dim >::prior_d[dim] [private]

Space for priors and beliefs.

Definition at line 53 of file cudabelieft.h.

template<int dim>
int CudaBelief< dim >::width [private]

Image size.

Definition at line 55 of file cudabelieft.h.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Properties Friends Defines


active_realtime_segmentation
Author(s): Mårten Björkman. Maintained by Jeannette Bohg
autogenerated on Wed Jan 23 2013 15:46:44