Skip to content
Snippets Groups Projects
Commit f9219389 authored by EXT Jean-Matthieu Etancelin's avatar EXT Jean-Matthieu Etancelin
Browse files

fix problem

parent cd3aa06b
No related branches found
No related tags found
2 merge requests!24Resolve "Add python3.x support",!15WIP: Resolve "HySoP with tasks"
Pipeline #47578 failed
import datetime
import sys
from hysop.constants import Backend, MemoryOrdering
from hysop.constants import Backend, MemoryOrdering, HYSOP_DEFAULT_TASK_ID
from hysop.tools.string_utils import vprint_banner
from hysop.tools.contexts import Timer
from hysop.tools.decorators import debug
......@@ -30,7 +30,8 @@ class Problem(ComputationalGraph):
for node in ops if hasattr(node, 'impl_kwds') and 'variables' in node.impl_kwds
for f in node.impl_kwds['variables'].keys()])
if given_ops_have_tasks:
if len(set(ops_tasks)) == 1 and ops_tasks[0] == self.mpi_params.task_id:
pb_task_id = HYSOP_DEFAULT_TASK_ID if self.mpi_params is None else self.mpi_params.task_id
if len(set(ops_tasks)) == 1 and ops_tasks[0] == pb_task_id:
# Intertask is not needed this is a single task-problem
given_ops_have_tasks = False
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment