Skip to content

NGDSG/BAMSI-API

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

BAMSI-api

Official BAMSI python API.

Installation

git clone https://github.com/NGDSG/BAMSI-API.git

Usage

from src.api import BAMSIApiClient
KEY = 'test'
IP='localhost:8888/'
bamsi_client = BAMSIApiClient(KEY, IP)

Get information on the worker pool

active_workers = bamsi_client.active_workers()

Submit a filtering job

# Define a job
query = '{"regions" : "1:1-30000", "subpops" : "CHB,JPT,CHS", "format" : "b"}'
query_args = json.loads(query)

# Launch the job
job_tracking_id = bamsi_client.spawn(**query_args)

Status

job_status = bamsi_client.job_status(tracking=job_tracking_id)

DOI(Citation)

DOI

See examples/ for more.