Convert IPython Jupyter Notebooks to CWL tool
Project description
IPython2CWL
IPython2CWL is a tool for converting IPython Jupyter Notebooks to CWL (Common Workflow Language) Command Line Tools by simply providing typing annotation.
from ipython2cwl.iotypes import CWLFilePathInput, CWLFilePathOutput import csv input_filename: 'CWLFilePathInput' = 'data.csv' with open(input_filename) as f: csv_reader = csv.reader(f) data = [line for line in csv_reader] number_of_lines = len(data) result_file: 'CWLFilePathOutput' = 'number_of_lines.txt' with open(result_file, 'w') as f: f.write(str(number_of_lines))
IPython2CWL is based on repo2docker, the same tool used by mybinder. Now, by writing Jupyter Notebook and publishing them, including repo2docker configuration, the community can not only execute the notebooks remotely but also to use them as steps in scientific workflows.
Install
pip install ipython2cwl
Example
jupyter repo2cwl https://github.com/giannisdoukas/cwl-annotated-jupyter-notebook.git -o .
Docs
https://ipython2cwl.readthedocs.io/
Demo
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Filename, size | File type | Python version | Upload date | Hashes |
---|---|---|---|---|
Filename, size ipython2cwl-0.0.4-py3-none-any.whl (16.4 kB) | File type Wheel | Python version py3 | Upload date | Hashes View |
Filename, size ipython2cwl-0.0.4.tar.gz (11.4 kB) | File type Source | Python version None | Upload date | Hashes View |
Close
Hashes for ipython2cwl-0.0.4-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6e9c881f68fea9b87ff6cc36a827296938376d3c045f49e75213624bb750d199 |
|
MD5 | 1e14f8d9e5987a0d1e270f6c52fc3480 |
|
BLAKE2-256 | 62dd0d69828c2e949de5ff7439f6e59d4e3c27b1d077175632b3d1faa3e40842 |