Skip to main content

Python SDK and CLI for the Renku platform.

Project description

https://img.shields.io/travis/SwissDataScienceCenter/renku-python.svg https://img.shields.io/coveralls/SwissDataScienceCenter/renku-python.svg https://img.shields.io/github/tag/SwissDataScienceCenter/renku-python.svg https://img.shields.io/pypi/dm/renku.svg Documentation Status https://img.shields.io/github/license/SwissDataScienceCenter/renku-python.svg

A Python library for the Renku collaborative data science platform. It allows the user to create projects, manage datasets, and capture data provenance while performing analysis tasks.

NOTE:

renku-python is the python library for Renku that provides an SDK and a command-line interface (CLI). It does not start the Renku platform itself - for that, refer to the Renku docs on running the platform.

Installation

The latest release is available on PyPI and can be installed using pip:

$ pip install renku

The latest development versions are available on PyPI or from the Git repository:

$ pip install --dev renku
# - OR -
$ pip install -e git+https://github.com/SwissDataScienceCenter/renku-python.git#egg=renku

Use following installation steps based on your operating system and preferences if you would like to work with the command line interface and you do not need the Python library to be importable.

MacOS

The recommended way of installing Renku on MacOS is via Homebrew.

$ brew tap swissdatasciencecenter/renku
$ brew install renku

Pip Script Installer (pipsi)

You can use pipsi to isolate dependencies and to guarantee that there are no version conflicts. Make sure you have the pipsi command correctly installed and ~/.local/bin is in your $PATH.

$ pipsi install renku
$ which renku
~/.local/bin/renku

Docker

The containerized version of the CLI can be launched using Docker command.

$ docker run -it -v "$PWD":"$PWD" -w="$PWD" renku/renku-python renku

It makes sure your current directory is mounted to the same place in the container.

Usage

Initialize a renku project:

$ mkdir -p ~/temp/my-renku-project
$ cd ~/temp/my-renku-project
$ renku init

Create a dataset and add data to it:

$ renku dataset create my-dataset
$ renku dataset add my-dataset https://raw.githubusercontent.com/SwissDataScienceCenter/renku-python/master/README.rst

Run an analysis:

$ renku run wc < data/my-dataset/README.rst > wc_readme

Trace the data provenance:

$ renku log wc_readme

These are the basics, but there is much more that Renku allows you to do with your data analysis workflows. The full documentation will soon be available at: https://renku-python.readthedocs.io/

Changes

v0.3.3

(released 2018-12-07)

  • Fixes generated Homebrew formula.

  • Renames renku pull path to renku storage pull with deprecation warning.

v0.3.2

(released 2018-11-29)

  • Fixes display of workflows in renku log.

v0.3.1

(released 2018-11-29)

  • Fixes issues with parsing remote Git URLs.

v0.3.0

(released 2018-11-26)

  • Adds JSON-LD context to objects extracted from the Git repository (see renku show context --list).

  • Uses PROV-O and WFPROV as provenance vocabularies and generates “stable” object identifiers (@id) for RDF and JSON-LD output formats.

  • Refactors the log output to allow linking files and directories.

  • Adds support for aliasing tools and workflows.

  • Adds option to install shell completion (renku --install-completion).

  • Fixes initialization of Git submodules.

  • Uses relative submodule paths when appropriate.

  • Simplifies external storage configuration.

v0.2.0

(released 2018-09-25)

  • Refactored version using Git and Common Workflow Language.

v0.1.0

(released 2017-09-06)

  • Initial public release as Renga.

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

renku-0.3.4.dev54.tar.gz (154.8 kB view details)

Uploaded Source

Built Distribution

renku-0.3.4.dev54-py2.py3-none-any.whl (146.9 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file renku-0.3.4.dev54.tar.gz.

File metadata

  • Download URL: renku-0.3.4.dev54.tar.gz
  • Upload date:
  • Size: 154.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.3

File hashes

Hashes for renku-0.3.4.dev54.tar.gz
Algorithm Hash digest
SHA256 cf2039bbbe16e91be9d6a71a4d04052c05d8bd1c453a3ce982bf9a15fe7a861f
MD5 ee981825d23a5418d30bfc6835d4f20a
BLAKE2b-256 dbc62b7685d10b02608069f485c74488120774e9d7018f7312d4a53085039385

See more details on using hashes here.

File details

Details for the file renku-0.3.4.dev54-py2.py3-none-any.whl.

File metadata

  • Download URL: renku-0.3.4.dev54-py2.py3-none-any.whl
  • Upload date:
  • Size: 146.9 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.3

File hashes

Hashes for renku-0.3.4.dev54-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 eee72fc0a128089d01847a117b1d5e208a12c2cb6a350bac8f96dc03a7c317d0
MD5 946f99b6128908370e8f9807cb9f7d2f
BLAKE2b-256 7feee8646b03c0777e8f6f091ef213200fe73500c689f13b700a7d2f0c7e62ee

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page