Illumina Basespace filesystem for PyFilesystem2
Project description
Readonly pyfilesystem2 interface to Illumina Basespace
Installing
pip install fs-basespace
Requires python3 version of basespace-python-sdk which can be installed from the develop branch.
pip install 'git+https://github.com/basespace/basespace-python-sdk#egg=BaseSpacePy-0.3&subdirectory=src'
Opening FS Basespace
With class constructor
from fs_basespace import BASESPACEFS
basespacefs = BASESPACEFS("/projects/{project-id}/appresults/{result-id}/files/{file-id}",
client_id = "{client-key}",
client_secret = "{client-secret}",
access_token = "{access_token}",
server_name = "{server_name} optional")
Default server name for Illumina is https://api.basespace.illumina.com/
With connection string
import fs
basespacefs = fs.open_fs("basespace://{clientKey}:{clientSecret}:{appToken}@{server}")
Advanced connection strings
Access to server root directory:
basespace://{clientKey}:{clientSecret}:{appToken}@{server}
Accessing projects:
basespace://{clientKey}:{clientSecret}:{appToken}@{server}!/projects/{projectId}
Accessing project sample files:
basespace://{clientKey}:{clientSecret}:{appToken}@{server}!/projects/{projectId}/samples/{sampleId}/files/{fileId}
Accessing project appResult files (bam, vcf, …):
basespace://{clientKey}:{clientSecret}:{appToken}@{server}!/projects/{projectId}/appresults/{resultId}/files/{fileId}
Downloading files
with open("local_file", "wb") as local_file:
basespacefs.download("path/to/remote/file/id", local_file)
Uploading files
Only readonly access to Basespace is implemented in this package. No upload possible yet.
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
fs-basespace-1.4.7.tar.gz
(13.4 kB
view details)
File details
Details for the file fs-basespace-1.4.7.tar.gz.
File metadata
- Download URL: fs-basespace-1.4.7.tar.gz
- Upload date:
- Size: 13.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.0.1 CPython/3.9.21
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2442370e0e8ea2f923deebface1856517de364ade758b4c2e4dd2dca3b5bbb2d
|
|
| MD5 |
cf723e50c6f7db9091cf779ebd7334b9
|
|
| BLAKE2b-256 |
2b1d33e02b68595edc9ddc156b7dbf1b6803dbdd218c52a0af2cb73dd965992d
|