<jupyter_start><jupyter_text>Run compute on 4 WES servers - where the Horizontal demo goes nextRuns  compute on four different platforms. Three are WES servers and one is Google Cloud.The compute is only MD5 but this example shows the capability to orchestrate a set of servers which show diversity geographically, organizationally and on different technical platforms.<jupyter_code>from fasp.runner import FASPRunner

# The implementations we're using
from fasp.loc import crdcDRSClient
from fasp.workflow import sbcgcWESClient, GCPLSsamtools, ElixirWESClient, DNAStackWESClient
from fasp.search import DiscoverySearchClient

faspRunner = FASPRunner(program='Horizontal2')
settings = faspRunner.settings

sbProject = settings['SevenBridgesProject']

# Step 1 - Discovery
# query for relevant DRS objects
searchClient = DiscoverySearchClient('https://ga4gh-search-adapter-presto-public.prod.dnastack.com/')

# Step 3 - set up the classes that runs samtools on the two clouds
location = 'projects/{}/locations/{}'.format(settings['GCPProject'], settings['GCPPipelineRegion'])
sam2 = GCPLSsamtools(location, settings['GCPOutputBucket'])
mysams = {'s3':{'wes':sbcgcWESClient(settings['SevenBridgesProject']), 'access_id' : 's3'},
          'gs': {'wes':sam2, 'access_id': 'gs'},
         'el' : {'wes':ElixirWESClient('~/.keys/elixir_wes_credentials.json'), 'access_id' : 's3'},
         'dn' : {'wes':DNAStackWESClient('~/.keys/dnastack_wes_credentials.json'), 'access_id' : 'gs'}
         }


query = '''
    SELECT 'case_'||associated_entities__case_gdc_id , file_id
    FROM search_cloud.cshcodeathon.gdc_rel24_filedata_active 
    where data_format = 'BAM' 
    and project_disease_type = 'Breast Invasive Carcinoma'
    limit 1'''


for sam, samClient in mysams.items():
    drsClient = crdcDRSClient('~/.keys/crdc_credentials.json', samClient['access_id'])
    faspRunner.configure(searchClient, drsClient, samClient['wes'])
    faspRunner.runQuery(query, 'cross cloud SAMTools validation')
faspRunner.getFASPicon()<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.11322596388482187, 'fraction_numerical': 0.006832601268911664, 'mean_word_length': 5.6558441558441555, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 1, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '1', 'dir': 'jupyter-structured-clean-dedup', 'id': '412010', 'license': 'Apache-2.0', 'n_tokens_mistral': 674, 'n_tokens_neox': 647, 'n_words': 158, 'path': 'notebooks/Four WES servers.ipynb', 'repo_name': 'jb-adams/fasp-scripts', 'size': '2049'}