DNAnexus

Workflows written in the WDL format can easily be imported into the DNAnexus platform using tools provided by DNAnexus: dx-toolkit and dxCompiler. Below demonstrates how to run the 02_download_collection_files.wdl workflow via DNAnexus. This workflow should take between 5-10 minutes to run.

Prerequisites

Before beginning, ensure you have the following:

  1. A DNAnexus platform account (including free tier)
  2. java 8+
  3. python 3.5+
  4. (Optional) cURL
  5. (Optional) git

Getting Started

The following software and workflows are required and will be installed and used as part of this tutorial:

  1. 02_download_collection_files.wdl
  2. dx-toolkit
  3. dxCompiler

Download the worked examples repository by one of the following methods.

  1. Clone with Git
    1
    
    git clone https://github.com/DNAstack/dnastack-client-library-worked-examples.git
    
  2. Or download and unzip

It is assumed that all commands will be run from the root directory of this repository on your local machine. From the directory where you’ve downloaded the examples repository:

1
cd dnastack-client-library-worked-examples/

Download the latest version of dxCompiler by one of the following methods. This allows direct conversion and uploading of WDL workflows to DNAnexus.

  1. Using cURL:
    1
    
    curl -o dxCompiler.jar -L https://github.com/dnanexus/dxCompiler/releases/download/2.4.6/dxCompiler-2.4.6.jar
    
  2. Or download from the releases page to the current directory and rename the file to dxCompiler.jar.

Download and initialize dx-toolkit. You will be prompted to log into your DNAnexus account.

1
2
pip3 install dxpy
dxlogin

Create a project on DNAnexus where the workflow and associated files will be stored.


Running the workflow

Once your project has been setup, import the WDL workflow 02_download_collection_files.wdl to the DNAnexus platform using dxCompiler.

1
2
3
$ java -jar ./dxCompiler.jar compile ./examples/wdl/02_download_collection_files.wdl \
        -project dnastack-client-library-worked-examples \
        -folder /download_collection_files

To run the newly created workflow on the DNAnexus platform: Select the project folder and Workflow item, and press Run as Analysis.


To view the progress of the workflow at any time: select the Monitor tab.


Inputs or parameters of the workflow can be modified. For example, to download from a different collection.


The output files can be found in and downloaded from the folder specified in the Run dialog. In this case, the root of the DNAnexus project.