seapodym-parallel
Fish dynamics models with parameter estimations
|
The TaskDependencyManager assigns tasks with dependencies to TaskDependencyWorkers. The dependencies are arbitrary but do not involve any internal steps. Use this in conjunction with TaskWorker when the tasks have dependencies. More...
#include <TaskDependencyManager.h>
Public Member Functions | |
TaskDependencyManager (MPI_Comm comm, int numTasks) | |
void | addDependencies (int taskId, const std::set< int > &otherTaskIds) |
std::map< int, int > | run () const |
The TaskDependencyManager assigns tasks with dependencies to TaskDependencyWorkers. The dependencies are arbitrary but do not involve any internal steps. Use this in conjunction with TaskWorker when the tasks have dependencies.
Class TaskDependencyManager
TaskDependencyManager::TaskDependencyManager | ( | MPI_Comm | comm, |
int | numTasks ) |
Constructor
comm | communicator |
numTasks | number of tasks |
void TaskDependencyManager::addDependencies | ( | int | taskId, |
const std::set< int > & | otherTaskIds ) |
Add dependencies
taskId | Id of the dependent task |
otherTaskIds | Dependencies |
std::map< int, int > TaskDependencyManager::run | ( | ) | const |
Run the manager