# EasySubmit
A Python library for simplified job scheduling and management on SLURM clusters.
[](https://python.org)
[](https://opensource.org/licenses/MIT)
## Overview
EasySubmit is a Python-based job scheduling and management system designed to seamlessly integrate with SLURM, a popular cluster management and job scheduling platform. This project aims to simplify the process of submitting, monitoring, and managing jobs on cluster environments through an intuitive Python API.
## Key Features
- **Simple API**: Easy-to-use Python interface for SLURM job submission
- **Task Management**: Define and configure tasks with type-safe configuration classes
- **Batch Scheduling**: Submit multiple experiments or jobs with different parameters
- **Profiling Support**: Optional integration with Scalene for performance profiling
- **Flexible Configuration**: Comprehensive SLURM configuration options
- **Type Safety**: Built with modern Python type hints for better development experience
## Installation
### From PyPI (Recommended)
```bash
pip install easysubmit
```
### From Source
```bash
# Clone the repository
git clone https://github.com/ysenarath/easysubmit.git
cd easysubmit
# Install in development mode
pip install -e .
```
### Optional Dependencies
For profiling support:
```bash
pip install easysubmit[scalene]
```
## Quick Start
Here's a simple example of how to use EasySubmit:
```python
from easysubmit import SLURMCluster, SLURMConfig, Task, TaskConfig
from easysubmit.base import schedule
# Define your task configuration
class ExperimentConfig(TaskConfig):
name: str = "MyExperiment"
learning_rate: float = 0.001
batch_size: int = 32
# Define your task
class Experiment(Task):
config: ExperimentConfig
def run(self):
print(f"Running experiment with lr={self.config.learning_rate}")
# Your experiment code here
# Configure SLURM settings
config = SLURMConfig(
partition="gpu",
nodes=1,
ntasks_per_node=1,
gres="gpu:1",
mem="16G"
)
# Create cluster and schedule jobs
cluster = SLURMCluster(config)
experiments = [
{"name": "MyExperiment", "learning_rate": 0.001, "batch_size": 32},
{"name": "MyExperiment", "learning_rate": 0.01, "batch_size": 64},
]
schedule(cluster, experiments)
```
## Core Components
### Task and TaskConfig
- `TaskConfig`: Define configuration parameters for your tasks with type safety
- `Task`: Base class for implementing your computational tasks
### SLURM Integration
- `SLURMCluster`: Interface to SLURM cluster management
- `SLURMConfig`: Comprehensive SLURM job configuration options
### Job Management
- `Job`: Represents individual jobs in the cluster
- `AutoTask`: Advanced task automation features
## Prerequisites
- Python 3.9 or higher
- Access to a SLURM cluster environment
- SLURM commands (`sbatch`, `squeue`, etc.) available in PATH
## Examples
Check out the `examples/` directory for more comprehensive usage examples:
- `examples/slurm_scheduler.py`: Basic SLURM job scheduling
- `examples/slurm_scheduler_with_profile.py`: Job scheduling with profiling
- `examples/tasks.py`: Task definition examples
## License
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
## Support
- **Issues**: [GitHub Issues](https://github.com/ysenarath/easysubmit/issues)
- **Documentation**: [GitHub README](https://github.com/ysenarath/easysubmit#readme)
- **Source Code**: [GitHub Repository](https://github.com/ysenarath/easysubmit)
Raw data
{
"_id": null,
"home_page": null,
"name": "easysubmit",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.9",
"maintainer_email": null,
"keywords": "batch-processing, cluster-computing, distributed-computing, hpc, job-scheduling, parallel-computing, scientific-computing, slurm, task-management, workflow",
"author": null,
"author_email": "Yasas Senarath <12231659+ysenarath@users.noreply.github.com>",
"download_url": "https://files.pythonhosted.org/packages/35/1b/0e631f561c20db9b1aea2d56cd3825b2712817b5cef6de4fde4846533632/easysubmit-0.2.4.tar.gz",
"platform": null,
"description": "# EasySubmit\n\nA Python library for simplified job scheduling and management on SLURM clusters.\n\n[](https://python.org)\n[](https://opensource.org/licenses/MIT)\n\n## Overview\n\nEasySubmit is a Python-based job scheduling and management system designed to seamlessly integrate with SLURM, a popular cluster management and job scheduling platform. This project aims to simplify the process of submitting, monitoring, and managing jobs on cluster environments through an intuitive Python API.\n\n## Key Features\n\n- **Simple API**: Easy-to-use Python interface for SLURM job submission\n- **Task Management**: Define and configure tasks with type-safe configuration classes\n- **Batch Scheduling**: Submit multiple experiments or jobs with different parameters\n- **Profiling Support**: Optional integration with Scalene for performance profiling\n- **Flexible Configuration**: Comprehensive SLURM configuration options\n- **Type Safety**: Built with modern Python type hints for better development experience\n\n## Installation\n\n### From PyPI (Recommended)\n```bash\npip install easysubmit\n```\n\n### From Source\n```bash\n# Clone the repository\ngit clone https://github.com/ysenarath/easysubmit.git\ncd easysubmit\n\n# Install in development mode\npip install -e .\n```\n\n### Optional Dependencies\nFor profiling support:\n```bash\npip install easysubmit[scalene]\n```\n\n## Quick Start\n\nHere's a simple example of how to use EasySubmit:\n\n```python\nfrom easysubmit import SLURMCluster, SLURMConfig, Task, TaskConfig\nfrom easysubmit.base import schedule\n\n# Define your task configuration\nclass ExperimentConfig(TaskConfig):\n name: str = \"MyExperiment\"\n learning_rate: float = 0.001\n batch_size: int = 32\n\n# Define your task\nclass Experiment(Task):\n config: ExperimentConfig\n \n def run(self):\n print(f\"Running experiment with lr={self.config.learning_rate}\")\n # Your experiment code here\n\n# Configure SLURM settings\nconfig = SLURMConfig(\n partition=\"gpu\",\n nodes=1,\n ntasks_per_node=1,\n gres=\"gpu:1\",\n mem=\"16G\"\n)\n\n# Create cluster and schedule jobs\ncluster = SLURMCluster(config)\nexperiments = [\n {\"name\": \"MyExperiment\", \"learning_rate\": 0.001, \"batch_size\": 32},\n {\"name\": \"MyExperiment\", \"learning_rate\": 0.01, \"batch_size\": 64},\n]\n\nschedule(cluster, experiments)\n```\n\n## Core Components\n\n### Task and TaskConfig\n- `TaskConfig`: Define configuration parameters for your tasks with type safety\n- `Task`: Base class for implementing your computational tasks\n\n### SLURM Integration\n- `SLURMCluster`: Interface to SLURM cluster management\n- `SLURMConfig`: Comprehensive SLURM job configuration options\n\n### Job Management\n- `Job`: Represents individual jobs in the cluster\n- `AutoTask`: Advanced task automation features\n\n## Prerequisites\n\n- Python 3.9 or higher\n- Access to a SLURM cluster environment\n- SLURM commands (`sbatch`, `squeue`, etc.) available in PATH\n\n## Examples\n\nCheck out the `examples/` directory for more comprehensive usage examples:\n\n- `examples/slurm_scheduler.py`: Basic SLURM job scheduling\n- `examples/slurm_scheduler_with_profile.py`: Job scheduling with profiling\n- `examples/tasks.py`: Task definition examples\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n\n## Support\n\n- **Issues**: [GitHub Issues](https://github.com/ysenarath/easysubmit/issues)\n- **Documentation**: [GitHub README](https://github.com/ysenarath/easysubmit#readme)\n- **Source Code**: [GitHub Repository](https://github.com/ysenarath/easysubmit)\n",
"bugtrack_url": null,
"license": null,
"summary": "A Python library for simplified job scheduling and management on SLURM clusters",
"version": "0.2.4",
"project_urls": {
"Documentation": "https://github.com/ysenarath/easysubmit#readme",
"Issues": "https://github.com/ysenarath/easysubmit/issues",
"Source": "https://github.com/ysenarath/easysubmit"
},
"split_keywords": [
"batch-processing",
" cluster-computing",
" distributed-computing",
" hpc",
" job-scheduling",
" parallel-computing",
" scientific-computing",
" slurm",
" task-management",
" workflow"
],
"urls": [
{
"comment_text": null,
"digests": {
"blake2b_256": "c58772b51cffeaaf2d05f7d434049c346c3967a862eb82a5c6cab73656e8d1ac",
"md5": "efa691d1445bb61f616f76e8b7868e8e",
"sha256": "96966f6e7a5a41ff9dc7eaab64840ff11597678b58dcd105e136b0879c5c3dc3"
},
"downloads": -1,
"filename": "easysubmit-0.2.4-py3-none-any.whl",
"has_sig": false,
"md5_digest": "efa691d1445bb61f616f76e8b7868e8e",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.9",
"size": 11475,
"upload_time": "2025-08-09T16:54:33",
"upload_time_iso_8601": "2025-08-09T16:54:33.804103Z",
"url": "https://files.pythonhosted.org/packages/c5/87/72b51cffeaaf2d05f7d434049c346c3967a862eb82a5c6cab73656e8d1ac/easysubmit-0.2.4-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "351b0e631f561c20db9b1aea2d56cd3825b2712817b5cef6de4fde4846533632",
"md5": "df12fe041abe547697e6292aa6806e40",
"sha256": "725168364daea668b67b28a81dda1214eea1d9546cac5ec02a6dd9800b3667ff"
},
"downloads": -1,
"filename": "easysubmit-0.2.4.tar.gz",
"has_sig": false,
"md5_digest": "df12fe041abe547697e6292aa6806e40",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.9",
"size": 69706,
"upload_time": "2025-08-09T16:54:34",
"upload_time_iso_8601": "2025-08-09T16:54:34.950077Z",
"url": "https://files.pythonhosted.org/packages/35/1b/0e631f561c20db9b1aea2d56cd3825b2712817b5cef6de4fde4846533632/easysubmit-0.2.4.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2025-08-09 16:54:34",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "ysenarath",
"github_project": "easysubmit#readme",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"requirements": [
{
"name": "nightjar",
"specs": [
[
"==",
"0.0.5"
]
]
},
{
"name": "typing-extensions",
"specs": [
[
"==",
"4.13.2"
]
]
}
],
"lcname": "easysubmit"
}