STIR  6.2.0
Namespaces | Functions
distributed_test_functions.h File Reference

Declaration of test functions for the distributed namespace. More...

#include "mpi.h"
#include "stir/shared_ptr.h"
#include "stir/DataSymmetriesForViewSegmentNumbers.h"
#include "stir/DiscretisedDensity.h"
#include "stir/RelatedViewgrams.h"
#include "stir/Viewgram.h"
#include "stir/ProjDataInfo.h"
#include <iostream>
#include <fstream>

Go to the source code of this file.

Namespaces

 distributed
 Namespace for distributed computation with MPI.
 

Functions

void distributed::test_viewgram_slave (const stir::shared_ptr< stir::ProjDataInfo > &proj_data_info_ptr)
 
void distributed::test_viewgram_master (stir::Viewgram< float > viewgram, const stir::shared_ptr< stir::ProjDataInfo > &proj_data_info_ptr)
 
void distributed::test_image_estimate_master (const stir::DiscretisedDensity< 3, float > *input_image_ptr, int slave)
 
void distributed::test_image_estimate_slave ()
 
void distributed::test_related_viewgrams_master (const stir::shared_ptr< stir::ProjDataInfo > &proj_data_info_ptr, const stir::shared_ptr< stir::DataSymmetriesForViewSegmentNumbers > symmetries_sptr, stir::RelatedViewgrams< float > *y, int slave)
 
void distributed::test_related_viewgrams_slave (const stir::shared_ptr< stir::ProjDataInfo > &proj_data_info_ptr, const stir::shared_ptr< stir::DataSymmetriesForViewSegmentNumbers > symmetries_sptr)
 
void distributed::test_parameter_info_master (const std::string str, int slave, char const *const text)
 
void distributed::test_parameter_info_slave (const std::string str)
 
void distributed::test_bool_value_master (bool value, int slave)
 
void distributed::test_bool_value_slave ()
 
void distributed::test_int_value_master (int value, int slave)
 
void distributed::test_int_value_slave ()
 
void distributed::test_int_values_master (int slave)
 
void distributed::test_int_values_slave ()
 

Detailed Description

Declaration of test functions for the distributed namespace.

This is a collection of functions to test the function implemented in DistributedFunction.cxx . Each of the possible tests consists of a master and a slave function to be called by different processes.

Note that every master function has a corresponding slave function.

Todo:
Currently no independent test functions are implemented. The tests are used by embedding them into the reconstruction functions and calling them once.

This is only done in debug mode and can be enabled/disabled with the following parsing parameter:

enable distributed tests := 1

The default value is 0.

This obviously not a good way to do testing, so there is a need to write independent test functions. The problem with that is, that all needed objects have to be set up. The function headers give an idea of what would have to be constructed.

Author
Tobias Beisel