Orchestrator for running python pipelines
Project description
orchestrator
Installation
pip install py-orchestrator
Example
from py_orchestrator.pipeline import Pipeline
from py_orchestrator.stage import Stage
class ActorOne(Stage):
def perform(self, state):
if not state:
state = 0
return self.configs['a'] + self.configs['b'] + state
class ActorTwo(Stage):
def perform(self, state):
if not state:
state = 0
return self.configs['c'] + self.configs['d'] + state
class TestPipeline:
def test_pipeline(self):
configs = {'a': 1, 'b': 2, 'c': 3, 'd': 4}
pipeline = Pipeline('test_pipeline', configs)
pipeline.add_stage(ActorOne)
pipeline.add_stage(ActorTwo)
assert pipeline.run() == 10
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
py_orchestrator-0.0.3.tar.gz
(2.1 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file py_orchestrator-0.0.3.tar.gz.
File metadata
- Download URL: py_orchestrator-0.0.3.tar.gz
- Upload date:
- Size: 2.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/3.7.3 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.8.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
13dc1001890c6c57b26c060fd43ea9ddade98ef3f85ffd993058c46ad756bae9
|
|
| MD5 |
4a733e19f418eba75ad17d2eaabfbed4
|
|
| BLAKE2b-256 |
0508f358527ad1336cf516361c12c1bff4231c9ce04b67d879f1bd044f326ed1
|
File details
Details for the file py_orchestrator-0.0.3-py3-none-any.whl.
File metadata
- Download URL: py_orchestrator-0.0.3-py3-none-any.whl
- Upload date:
- Size: 3.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/3.7.3 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.8.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a8eca96f2fedd8567eda1a757406fc54d617e446b244ec6c8e510d8531424807
|
|
| MD5 |
e49dc5f77ac93bb71f362d37b56fec5f
|
|
| BLAKE2b-256 |
0470a15c772793da5865f8040274d6ec00a0a5932c95df6f7d8f39253e9fa077
|