Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions executorlib/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
from executorlib.executor.base import BaseExecutor
from executorlib.executor.flux import (
FluxClusterExecutor,
FluxJobExecutor,
Expand All @@ -13,6 +14,7 @@

__all__: list[str] = [
"get_cache_data",
"BaseExecutor",
"FluxJobExecutor",
"FluxClusterExecutor",
"SingleNodeExecutor",
Expand Down
3 changes: 2 additions & 1 deletion executorlib/executor/base.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import queue
from abc import ABC
from concurrent.futures import (
Executor as FutureExecutor,
)
Expand All @@ -10,7 +11,7 @@
from executorlib.task_scheduler.base import TaskSchedulerBase


class ExecutorBase(FutureExecutor):
class BaseExecutor(FutureExecutor, ABC):
"""
Interface class for the executor.

Expand Down
6 changes: 3 additions & 3 deletions executorlib/executor/flux.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from typing import Callable, Optional, Union

from executorlib.executor.base import ExecutorBase
from executorlib.executor.base import BaseExecutor
from executorlib.standalone.inputcheck import (
check_command_line_argument_lst,
check_init_function,
Expand All @@ -17,7 +17,7 @@
from executorlib.task_scheduler.interactive.onetoone import OneProcessTaskScheduler


class FluxJobExecutor(ExecutorBase):
class FluxJobExecutor(BaseExecutor):
"""
The executorlib.Executor leverages either the message passing interface (MPI), the SLURM workload manager or
preferable the flux framework for distributing python functions within a given resource allocation. In contrast to
Expand Down Expand Up @@ -202,7 +202,7 @@ def __init__(
)


class FluxClusterExecutor(ExecutorBase):
class FluxClusterExecutor(BaseExecutor):
"""
The executorlib.Executor leverages either the message passing interface (MPI), the SLURM workload manager or
preferable the flux framework for distributing python functions within a given resource allocation. In contrast to
Expand Down
4 changes: 2 additions & 2 deletions executorlib/executor/single.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from typing import Callable, Optional, Union

from executorlib.executor.base import ExecutorBase
from executorlib.executor.base import BaseExecutor
from executorlib.standalone.inputcheck import (
check_command_line_argument_lst,
check_gpus_per_worker,
Expand All @@ -17,7 +17,7 @@
from executorlib.task_scheduler.interactive.onetoone import OneProcessTaskScheduler


class SingleNodeExecutor(ExecutorBase):
class SingleNodeExecutor(BaseExecutor):
"""
The executorlib.Executor leverages either the message passing interface (MPI), the SLURM workload manager or
preferable the flux framework for distributing python functions within a given resource allocation. In contrast to
Expand Down
6 changes: 3 additions & 3 deletions executorlib/executor/slurm.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from typing import Callable, Optional, Union

from executorlib.executor.base import ExecutorBase
from executorlib.executor.base import BaseExecutor
from executorlib.standalone.inputcheck import (
check_init_function,
check_plot_dependency_graph,
Expand All @@ -18,7 +18,7 @@
)


class SlurmClusterExecutor(ExecutorBase):
class SlurmClusterExecutor(BaseExecutor):
"""
The executorlib.Executor leverages either the message passing interface (MPI), the SLURM workload manager or
preferable the flux framework for distributing python functions within a given resource allocation. In contrast to
Expand Down Expand Up @@ -194,7 +194,7 @@ def __init__(
)


class SlurmJobExecutor(ExecutorBase):
class SlurmJobExecutor(BaseExecutor):
"""
The executorlib.Executor leverages either the message passing interface (MPI), the SLURM workload manager or
preferable the flux framework for distributing python functions within a given resource allocation. In contrast to
Expand Down
Loading