Distributed computing for everyone in modern Python.
Project description
achilles
Extremely accessible distributed/parallel computing (B.Y.O.B. - Build Your Own Beowulf) in modern Python based on:
Twisted;dill;multiprocess(a fork ofmultiprocessingthat usesdillas its serializer); and,- lessons learned from studying
Hadoop,Apache Spark,Kubernetes,Apache Arrow,Parallel Python,Ray,Jug,Pathos,Disco,SCOOP,Cluster-Workersand the questions asked regarding these projects on StackOverflow.
The goal of the achilles project is to drastically reduce the barriers to entry for developers to use all of the computational power available on their networks by providing an accessible, highly flexible framework for building distributed/parallel computing applications with as little configuration and prior knowledge as possible.
As achilles continues to be actively developed, the project will be designed in alignment with our FOUR DEMANDS:
achillesmust be simple to use;achillesmust 'just work' at all scales, from running all of the components on an individual's laptop to deployment across thousands ofachilles_nodes;achillesmust be scalable and accommodate 'big data' workloads (i.e. files too large to open in memory on a single machine);achillesshould be fast as hell and regularly benchmarked against alternative solutions; and,achillesmust be SECURE. Currently,achillesis not suitable for deployment outside oflocalhost. We are currently working on an SSH implementation usingTwistedConch.
Consists of:
achilles_server.py- Runs a Twisted TCP server (
lineReceiverso that large packets aren't truncated) listening at the endpoint described in the.envconfiguration file. Establishes and maintains persistent connections withachilles_node(s), distributes computations among them at the instruction of theachilles_controller, and sends the result(s) to theachilles_controllerin theresponse_modespecified by the developer.
- Runs a Twisted TCP server (
achilles_node.py- Connect to the
achilles_serverand receive ID assignment. Wait for a job to be started, receive a function over the wire, receive an argument over the wire, perform the function on the argument, return the result to the server and then wait for more arguments - keep feeding the server results/receiving new arguments until all arguments have been exhausted (hungry consumer, forceful feeder).
- Connect to the
achilles_controller.py- Connect to the
achilles_serverand instruct it which function should be performed against which arguments in the specifiedresponse_mode. Verify the job and wait for the results to be returned -achilles_serverand itsachilles_node(s) will do the rest. - Available commands in
achilles_controllercommand interface (mapAPI also exposed - see below for details/examples):achilles_compute,cluster_status,kill_cluster,help
- Connect to the
Configuration files:
achilles_config.yaml- Use
pyYamlto load the configuration file for a job into theachilles_controllerif you decide to use thecommand_interface()CLI. See below for additional information on how to structure this file. - Args may be defined in this file.
- Use
achilles_function.pyachilles_function()is serialized usingdilland distributed to all connected clients as a part of thestartJob()handshake initiated after theachilles_controllerverifies the commencement of a job.achilles_args()andachilles_callback()may also be defined in this file.- Can also be defined dynamically along with
achilles_args()andachilles_callback(). SeeUsagefor details/examples.
.env- Use
python-dotenvto load the local file into the system's environmental variables for configuration and authentication. - Basic security precaution. To-do: explore encryption.
- Use
Installation
pip install --upgrade achilles
Usage
Deploy achilles_server:
from achilles.lineReceiver.achilles_server import runAchillesServerrunAchillesServer()-> run anachilles_serverusing the specified HOST and PORT in the package's.envfile (generate one if it does not exist).
Deploy achilles_node(s):
from achilles.lineReceiver.achilles_node import runAchillesNoderunAchillesNode()-> run anachilles_nodethat connects to the specified HOST and PORT in the package's.envfile (generate one if it does not exist).
Either deploy achilles_controller or use map API in your own scripts:
from achilles.lineReceiver.achilles_node import runAchillesNoderunAchillesNode()-> run anachilles_controllerthat connects to the specified HOST and PORT in the package's.envfile (generate one if it does not exist).runAchillesNode()automatically callscommand_interface()and presents the user with an easy-to-use CLI.
OR...
- XXXX
achilles is in the early stages of active development and your suggestions/contributions are kindly welcomed. achilles is written and maintained by Alejandro Peña. Email me at adpena<3gmail.com.
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 achilles-0.0.171.tar.gz.
File metadata
- Download URL: achilles-0.0.171.tar.gz
- Upload date:
- Size: 12.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.2 CPython/3.7.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
dd8d0649684bac9530f96369ab45c553936c9cd93c4054d53bf39cd68fc96f84
|
|
| MD5 |
3d9c3aed09e6d897701d16f22129ba7f
|
|
| BLAKE2b-256 |
b7b10dba0ac4aeee5a43e37299a9999d401ebfec27d6f23e63f00e735b96b0de
|
File details
Details for the file achilles-0.0.171-py3-none-any.whl.
File metadata
- Download URL: achilles-0.0.171-py3-none-any.whl
- Upload date:
- Size: 29.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.2 CPython/3.7.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
dabef655dc1d88f9c7c334d14b01ff863b7ef83e0ecb8b834d1c57257ae194e7
|
|
| MD5 |
6bed20fde939e54b88b17c8cc15f47e6
|
|
| BLAKE2b-256 |
1f13384db50de39d9547508f0497ef2225da97b1685f3f92ac7fb9ecce071d37
|