Skip to main content

Resolwe SDK for Python

Project description

Build Status Documentation Status Version on PyPI Supported Python versions Number of downloads from PyPI

The Resolwe SDK for Python supports writing tools for Resolwe dataflow package for Django framework and Resolwe Bioinformatics that includes the bioinformatics pipelines.

Docs & Help

Read detailed description in the documentation.

Install

To install, run:

pip install resdk

To install for development, run:

pip install -e .[docs,package,test]

Usage

Connect to the Resolwe server:

from resdk import Resolwe
re = Resolwe('me@mail.com', 'my_password', 'www.resolwe.com')

Get all collections and select the first one:

collections = re.collections()
collection = list(collections.values())[0]

Get expression objects and select the first one:

expressions = collection.data(type__startswith='data:expression:')
expression = expressions[0]

Print annotation:

expression.print_annotation()

Print file fields:

expression.print_downloads()

Download file:

filename = expression.annotation['output.exp']['value']['file']
file_stream = expression.download('output.exp')
with open(filename, 'w') as f:
    for part in file_stream:
        f.write(part)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

resdk-1.3.0.tar.gz (34.9 kB view hashes)

Uploaded Source

Built Distribution

resdk-1.3.0-py2.py3-none-any.whl (33.4 kB view hashes)

Uploaded Python 2 Python 3

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