Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members  

TaskManager Class Reference

Manages execution of tasks. More...

#include <taskmanager.h>

List of all members.

Public Methods

virtual void spawnSlaves ()
virtual void generateTasks ()
virtual void errorShutDown ()
void shutDown ()
void assignTask (int who)
void timeOut (int who)
void assignInitialTasks ()
void executeTasks ()
int packetCheck ()
void closeFile ()
void openStatisticsFile ()
void closeStatisticsFile ()
void appendToStatisticsFile ()
void ReadFile ()
int getMachineIndexFromSlave (int who)

Public Attributes

int nproc
char procHostMachines [MAXPROC][MAX_STR]
int nhost
int narch
int pingtimeout
int nres
char pesdefFileName [MAX_STR]
char * pescArgs [MAX_PESC_ARGS]
char resultsFolderName [MAX_STR]
pvmhostinfo * hostp
PESSlaveInfo slaves [MAXPROC]
PESNetworkAdapter NetAdapter
FILE * logFile
FILE * fstat
FILE * ferror

Detailed Description

Manages execution of tasks.

This class manages execution of tasks on PES. Contains host information. Also contains configuration information. Tasks are executed using this class and results are also collected with this class. So essentially this class encapsulates functionality of two sub modules. Configuration manager and task manager.

Onur Soysal

Member Function Documentation

void TaskManager::appendToStatisticsFile  

Append these tasks to statistics file

void TaskManager::assignInitialTasks  

This function assigns initial tasks to slaves.

void TaskManager::assignTask int    who

This function assigns a task to PES-C with local id 'who'. This function doesn't fail even if there is no task avaliable. Then the function just sends a warning message to the console.

void TaskManager::closeFile  

Stub function for log File operations.

void TaskManager::closeStatisticsFile  

Close statistics file

virtual void TaskManager::errorShutDown   [virtual]

Shuts Down the system and reports an error condition.

void TaskManager::executeTasks  

This function distributes tasks to PES-C's and executes them. This function is also responsible for fault checking.

virtual void TaskManager::generateTasks   [virtual]

Generates tasks to be used in the program

int TaskManager::getMachineIndexFromSlave int    who

Returns index of the machine, on which the slave program is running.

void TaskManager::openStatisticsFile  

Open statistics file

int TaskManager::packetCheck  

This function checks for incoming messages and gets the first message in queue. This message is processed and according changes are made.

void TaskManager::ReadFile  

Read Configuration File

void TaskManager::shutDown  

Shuts down the Task Manager. Normally only called by the destructor.

virtual void TaskManager::spawnSlaves   [virtual]

This function spawns PES-S applications on the server.

void TaskManager::timeOut int    who

This function signals time out of PES-C task with id 'who'.

Member Data Documentation

FILE* TaskManager::ferror

Pointer to Problematic tasks file

FILE* TaskManager::fstat

Pointer to Statistics file

pvmhostinfo* TaskManager::hostp

Host information

FILE* TaskManager::logFile

Standart log file.

int TaskManager::MAX_GENERATIONS

Maximum number of generations

int TaskManager::narch

Number of different architectures being used

PESNetworkAdapter TaskManager::NetAdapter

Network adapter to be used in communication with slave tasks

int TaskManager::nhost

Number of different hosts being used

int TaskManager::nproc

Number of processes being used

int TaskManager::nres

Number of results that has reached server

int TaskManager::NROBOTS

Number of robots to be used

int TaskManager::NTASKS

Total Number of tasks

Population* TaskManager::p

Population of solutions to be used

char* TaskManager::pescArgs[MAX_PESC_ARGS]

Arguments to be passed to pesc

char TaskManager::pesdefFileName[MAX_STR]

Name of pes definition file

int TaskManager::pingtimeout

The timeout

char TaskManager::procHostMachines[MAXPROC][MAX_STR]

The hosts to be used in this experiment

int TaskManager::RANDOM_SEED

GA Random number generator seed

char TaskManager::resultsFolderName[MAX_STR]

results folder name

char TaskManager::SLAVENAME[MAX_STR]

Name of the slave to be used

PESSlaveInfo TaskManager::slaves[MAXPROC]

Information about slaves.

int TaskManager::TASK_PER_EVAL

Tasks to be executed for each function evaluation

int TaskManager::TASK_STEPS

Number of Steps to be executed

PESTask* TaskManager::tasks

List of tasks

The documentation for this class was generated from the following file:
Generated on Thu Feb 12 18:42:57 2004 for ParallelizedEvolutionSystem by doxygen1.2.18