Program for creating data pipelines triggered by file creation events.
Project description
dpypeline
Program for creating data pipelines triggered by file creation events.
Version
0.1.0-beta.4
Python enviroment setup
To utilise this package, it should be installed within a dedicated Conda environment. You can create this environment using the following command:
conda create --name <environment_name> python=3.10
To activate the conda environment use:
conda activate <environment_name>
Alternatively, use virtualenv to setup and activate the environment:
python -m venv <environment_name>
source <envionment_name>/bin/activate
Installation
- Clone the repository:
git clone git@github.com:NOC-OI/dpyepline.git
- Navigate to the package directory:
After cloning the repository, navigate to the root directory of the package.
- Install in editable mode:
To install dpypeline in editable mode, execute the following comman from the root directory:
pip install -e .
This command will install the library in editable mode, allowing you to make changes to the code if needed.
- Alternative installation methods:
- Install from the GitHub repository directly:
pip install git+https://github.com/NOC-OI/dpypeline.git@main#egg=dpypeline
- Install from the PyPI repository:
pip install dpypeline
Unit tests
Run tests using pytest in the main directory:
pip install pytest
pytest
Examples
Python scripts
Examples of Python scripts explaining how to use this package can be found in the examples directory.
Command line interface (CLI)
The CLI provided by this package allows you to execute data pipelines defined in YAML files; however, it offers less flexibility compared to using the Python scripts. To run the dpypeline CLI, type, e.g., the following command:
dpypeline -i <input_file> > output 2> errors
Flags description
-hor--help: show an help message-i INPUT_FILEor--input INPUT_FILE: Filepath to the pipeline YAML file (by defaultpipelien.yaml)-vor--version: show dpypeline's version umber
Environment variables
There are a few environment variables that need to be set so that the application can run correctly:
CACHE_DIR: Path to the cache directory.
Software Workflow Overview
Pipeline architectures
Thread-based pipeline
In the thread-based pipeline, Akita enqueues events into an in-memory queue. These events are subsequently consumed by ConsumerSerial, which generates jobs for sequential execution within the ThreadPipeline (an alias for BasicPipeline).
Parallel pipeline
In the parallel pipeline, Akita enqueues events into an in-memory queue. These events are then consumed by ConsumerParallel, which generates futures that are executed concurrently by multiple Dask workers.
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
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 dpypeline-0.1.0b4.tar.gz.
File metadata
- Download URL: dpypeline-0.1.0b4.tar.gz
- Upload date:
- Size: 24.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
037025458aebde1e9536bf4285ae5a3563b4543b0315b2be282308edee981cf3
|
|
| MD5 |
e7dae6d549050992b3f701d1c860ce90
|
|
| BLAKE2b-256 |
ae5e72ff21133aa2b42a1e324f408ad31f4de33408738c0e5edf2d9aad7096ea
|
File details
Details for the file dpypeline-0.1.0b4-py3-none-any.whl.
File metadata
- Download URL: dpypeline-0.1.0b4-py3-none-any.whl
- Upload date:
- Size: 28.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fa7595fce24acf122d227c1418b052bb2ced095a967427715dfb0ac80ea7a94d
|
|
| MD5 |
584884652d3ccea58e60971e800d6e3b
|
|
| BLAKE2b-256 |
bbe1bde84680e9aa87067c56f34b78f9066c9032c68966f02152b3fee59889da
|