diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json new file mode 100644 index 00000000..ea27a584 --- /dev/null +++ b/.devcontainer/devcontainer.json @@ -0,0 +1,27 @@ +{ + "name": "nfcore", + "image": "nfcore/gitpod:latest", + "remoteUser": "gitpod", + + // Configure tool-specific properties. + "customizations": { + // Configure properties specific to VS Code. + "vscode": { + // Set *default* container specific settings.json values on container create. + "settings": { + "python.defaultInterpreterPath": "/opt/conda/bin/python", + "python.linting.enabled": true, + "python.linting.pylintEnabled": true, + "python.formatting.autopep8Path": "/opt/conda/bin/autopep8", + "python.formatting.yapfPath": "/opt/conda/bin/yapf", + "python.linting.flake8Path": "/opt/conda/bin/flake8", + "python.linting.pycodestylePath": "/opt/conda/bin/pycodestyle", + "python.linting.pydocstylePath": "/opt/conda/bin/pydocstyle", + "python.linting.pylintPath": "/opt/conda/bin/pylint" + }, + + // Add the IDs of extensions you want installed when the container is created. + "extensions": ["ms-python.python", "ms-python.vscode-pylance", "nf-core.nf-core-extensionpack"] + } + } +} diff --git a/.gitattributes b/.gitattributes index 050bb120..7a2dabc2 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1,3 +1,4 @@ *.config linguist-language=nextflow +*.nf.test linguist-language=nextflow modules/nf-core/** linguist-generated subworkflows/nf-core/** linguist-generated diff --git a/.github/CONTRIBUTING.md b/.github/CONTRIBUTING.md index e52f9152..029073ae 100644 --- a/.github/CONTRIBUTING.md +++ b/.github/CONTRIBUTING.md @@ -1,22 +1,20 @@ -# nf-core/treeval: Contributing Guidelines +# sanger-tol/treeval: Contributing Guidelines Hi there! -Many thanks for taking an interest in improving nf-core/treeval. +Many thanks for taking an interest in improving sanger-tol/treeval. -We try to manage the required tasks for nf-core/treeval using GitHub issues, you probably came to this page when creating one. +We try to manage the required tasks for sanger-tol/treeval using GitHub issues, you probably came to this page when creating one. Please use the pre-filled template to save time. However, don't be put off by this template - other more general issues and suggestions are welcome! Contributions to the code are even more welcome ;) -> If you need help using or modifying nf-core/treeval then the best place to ask is on the nf-core Slack [#treeval](https://nfcore.slack.com/channels/treeval) channel ([join our Slack here](https://nf-co.re/join/slack)). - ## Contribution workflow -If you'd like to write some code for nf-core/treeval, the standard workflow is as follows: +If you'd like to write some code for sanger-tol/treeval, the standard workflow is as follows: -1. Check that there isn't already an issue about your idea in the [nf-core/treeval issues](https://github.com/nf-core/treeval/issues) to avoid duplicating work. If there isn't one already, please create one so that others know you're working on this -2. [Fork](https://help.github.com/en/github/getting-started-with-github/fork-a-repo) the [nf-core/treeval repository](https://github.com/nf-core/treeval) to your GitHub account +1. Check that there isn't already an issue about your idea in the [sanger-tol/treeval issues](https://github.com/sanger-tol/treeval/issues) to avoid duplicating work. If there isn't one already, please create one so that others know you're working on this +2. [Fork](https://help.github.com/en/github/getting-started-with-github/fork-a-repo) the [sanger-tol/treeval repository](https://github.com/sanger-tol/treeval) to your GitHub account 3. Make the necessary changes / additions within your forked repository following [Pipeline conventions](#pipeline-contribution-conventions) 4. Use `nf-core schema build` and add any new parameters to the pipeline JSON schema (requires [nf-core tools](https://github.com/nf-core/tools) >= 1.10). 5. Submit a Pull Request against the `dev` branch and wait for the code to be reviewed and merged @@ -52,13 +50,9 @@ These tests are run both with the latest available version of `Nextflow` and als - Fix the bug, and bump version (X.Y.Z+1). - A PR should be made on `master` from patch to directly this particular bug. -## Getting help - -For further information/help, please consult the [nf-core/treeval documentation](https://nf-co.re/treeval/usage) and don't hesitate to get in touch on the nf-core Slack [#treeval](https://nfcore.slack.com/channels/treeval) channel ([join our Slack here](https://nf-co.re/join/slack)). - ## Pipeline contribution conventions -To make the nf-core/treeval code and processing logic more understandable for new contributors and to ensure quality, we semi-standardise the way the code and other contributions are written. +To make the sanger-tol/treeval code and processing logic more understandable for new contributors and to ensure quality, we semi-standardise the way the code and other contributions are written. ### Adding a new step @@ -101,3 +95,19 @@ If you are using a new feature from core Nextflow, you may bump the minimum requ ### Images and figures For overview images and other documents we follow the nf-core [style guidelines and examples](https://nf-co.re/developers/design_guidelines). + +## GitHub Codespaces + +This repo includes a devcontainer configuration which will create a GitHub Codespaces for Nextflow development! This is an online developer environment that runs in your browser, complete with VSCode and a terminal. + +To get started: + +- Open the repo in [Codespaces](https://github.com/sanger-tol/treeval/codespaces) +- Tools installed + - nf-core + - Nextflow + +Devcontainer specs: + +- [DevContainer config](.devcontainer/devcontainer.json) +- [Dockerfile](.devcontainer/Dockerfile) diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml index ccccf60f..c4de8d83 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.yml +++ b/.github/ISSUE_TEMPLATE/bug_report.yml @@ -2,14 +2,6 @@ name: Bug report description: Report something that is broken or incorrect labels: bug body: - - type: markdown - attributes: - value: | - Before you post this issue, please check the documentation: - - - [nf-core website: troubleshooting](https://nf-co.re/usage/troubleshooting) - - [nf-core/treeval pipeline documentation](https://nf-co.re/treeval/usage) - - type: textarea id: description attributes: @@ -17,34 +9,46 @@ body: description: A clear and concise description of what the bug is. validations: required: true - - type: textarea id: command_used attributes: label: Command used and terminal output - description: Steps to reproduce the behaviour. Please paste the command you used to launch the pipeline and the output from your terminal. + description: Steps to reproduce the behaviour. Please paste the command you used + to launch the pipeline and the output from your terminal. render: console - placeholder: | - $ nextflow run ... + placeholder: "$ nextflow run ... + Some output where something broke + " - type: textarea id: files attributes: label: Relevant files - description: | - Please drag and drop the relevant files here. Create a `.zip` archive if the extension is not allowed. - Your verbose log file `.nextflow.log` is often useful _(this is a hidden file in the directory where you launched the pipeline)_ as well as custom Nextflow configuration files. + description: "Please drag and drop the relevant files here. Create a `.zip` archive + if the extension is not allowed. + + Your verbose log file `.nextflow.log` is often useful _(this is a hidden file + in the directory where you launched the pipeline)_ as well as custom Nextflow + configuration files. + " - type: textarea id: system attributes: label: System information - description: | - * Nextflow version _(eg. 21.10.3)_ + description: "* Nextflow version _(eg. 22.10.1)_ + * Hardware _(eg. HPC, Desktop, Cloud)_ + * Executor _(eg. slurm, local, awsbatch)_ - * Container engine: _(e.g. Docker, Singularity, Conda, Podman, Shifter or Charliecloud)_ + + * Container engine: _(e.g. Docker, Singularity, Conda, Podman, Shifter, Charliecloud, + or Apptainer)_ + * OS _(eg. CentOS Linux, macOS, Linux Mint)_ - * Version of nf-core/treeval _(eg. 1.1, 1.5, 1.8.2)_ + + * Version of sanger-tol/treeval _(eg. 1.1, 1.5, 1.8.2)_ + + " diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml index 0421b450..8565dbea 100644 --- a/.github/ISSUE_TEMPLATE/config.yml +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -4,4 +4,4 @@ contact_links: about: Please join the nf-core community here - name: "Slack #treeval channel" url: https://nfcore.slack.com/channels/treeval - about: Discussion about the nf-core/treeval pipeline + about: Discussion about the sanger-tol/treeval pipeline diff --git a/.github/ISSUE_TEMPLATE/feature_request.yml b/.github/ISSUE_TEMPLATE/feature_request.yml index 10ddb054..122be55e 100644 --- a/.github/ISSUE_TEMPLATE/feature_request.yml +++ b/.github/ISSUE_TEMPLATE/feature_request.yml @@ -1,5 +1,5 @@ name: Feature request -description: Suggest an idea for the nf-core/treeval pipeline +description: Suggest an idea for the sanger-tol/treeval pipeline labels: enhancement body: - type: textarea diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index b90c66e8..354ab3df 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -1,22 +1,21 @@ ## PR checklist - [ ] This comment contains a description of changes (with reason). - [ ] If you've fixed a bug or added code that should be tested, add tests! - - [ ] If you've added a new tool - have you followed the pipeline conventions in the [contribution docs](https://github.com/nf-core/treeval/tree/master/.github/CONTRIBUTING.md) - - [ ] If necessary, also make a PR on the nf-core/treeval _branch_ on the [nf-core/test-datasets](https://github.com/nf-core/test-datasets) repository. +- [ ] If you've added a new tool - have you followed the pipeline conventions in the [contribution docs](https://github.com/sanger-tol/treeval/tree/master/.github/CONTRIBUTING.md) - [ ] Make sure your code lints (`nf-core lint`). - [ ] Ensure the test suite passes (`nextflow run . -profile test,docker --outdir `). - [ ] Usage Documentation in `docs/usage.md` is updated. diff --git a/.github/workflows/awsfulltest.yml b/.github/workflows/awsfulltest.yml deleted file mode 100644 index ef8c9103..00000000 --- a/.github/workflows/awsfulltest.yml +++ /dev/null @@ -1,30 +0,0 @@ -name: nf-core AWS full size tests -# This workflow is triggered on published releases. -# It can be additionally triggered manually with GitHub actions workflow dispatch button. -# It runs the -profile 'test_full' on AWS batch - -on: - release: - types: [published] - workflow_dispatch: -jobs: - run-tower: - name: Run AWS full tests - if: github.repository == 'nf-core/treeval' - runs-on: ubuntu-latest - steps: - - name: Launch workflow via tower - uses: nf-core/tower-action@v3 - # TODO nf-core: You can customise AWS full pipeline tests as required - # Add full size test data (but still relatively small datasets for few samples) - # on the `test_full.config` test runs with only one set of parameters - with: - workspace_id: ${{ secrets.TOWER_WORKSPACE_ID }} - access_token: ${{ secrets.TOWER_ACCESS_TOKEN }} - compute_env: ${{ secrets.TOWER_COMPUTE_ENV }} - workdir: s3://${{ secrets.AWS_S3_BUCKET }}/work/treeval/work-${{ github.sha }} - parameters: | - { - "outdir": "s3://${{ secrets.AWS_S3_BUCKET }}/treeval/results-${{ github.sha }}" - } - profiles: test_full,aws_tower diff --git a/.github/workflows/awstest.yml b/.github/workflows/awstest.yml deleted file mode 100644 index 6bb03b8c..00000000 --- a/.github/workflows/awstest.yml +++ /dev/null @@ -1,25 +0,0 @@ -name: nf-core AWS test -# This workflow can be triggered manually with the GitHub actions workflow dispatch button. -# It runs the -profile 'test' on AWS batch - -on: - workflow_dispatch: -jobs: - run-tower: - name: Run AWS tests - if: github.repository == 'nf-core/treeval' - runs-on: ubuntu-latest - steps: - # Launch workflow using Tower CLI tool action - - name: Launch workflow via tower - uses: nf-core/tower-action@v3 - with: - workspace_id: ${{ secrets.TOWER_WORKSPACE_ID }} - access_token: ${{ secrets.TOWER_ACCESS_TOKEN }} - compute_env: ${{ secrets.TOWER_COMPUTE_ENV }} - workdir: s3://${{ secrets.AWS_S3_BUCKET }}/work/treeval/work-${{ github.sha }} - parameters: | - { - "outdir": "s3://${{ secrets.AWS_S3_BUCKET }}/treeval/results-test-${{ github.sha }}" - } - profiles: test,aws_tower diff --git a/.github/workflows/branch.yml b/.github/workflows/branch.yml index c9b2ee49..c715d204 100644 --- a/.github/workflows/branch.yml +++ b/.github/workflows/branch.yml @@ -11,9 +11,9 @@ jobs: steps: # PRs to the nf-core repo master branch are only ok if coming from the nf-core repo `dev` or any `patch` branches - name: Check PRs - if: github.repository == 'nf-core/treeval' + if: github.repository == 'sanger-tol/treeval' run: | - { [[ ${{github.event.pull_request.head.repo.full_name }} == nf-core/treeval ]] && [[ $GITHUB_HEAD_REF = "dev" ]]; } || [[ $GITHUB_HEAD_REF == "patch" ]] + { [[ ${{github.event.pull_request.head.repo.full_name }} == sanger-tol/treeval ]] && [[ $GITHUB_HEAD_REF == "dev" ]]; } || [[ $GITHUB_HEAD_REF == "patch" ]] # If the above check failed, post a comment on the PR explaining the failure # NOTE - this doesn't currently work if the PR is coming from a fork, due to limitations in GitHub actions secrets diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 260349e0..b7e07eca 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -10,41 +10,42 @@ on: env: NXF_ANSI_LOG: false - CAPSULE_LOG: none + +concurrency: + group: "${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}" + cancel-in-progress: true jobs: test: name: Run pipeline with test data # Only run on push if this is the nf-core dev branch (merged PRs) - if: "${{ github.event_name != 'push' || (github.event_name == 'push' && github.repository == 'nf-core/treeval') }}" + if: "${{ github.event_name != 'push' || (github.event_name == 'push' && github.repository == 'sanger-tol/treeval') }}" runs-on: ubuntu-latest strategy: matrix: - # Nextflow versions - include: - # Test pipeline minimum Nextflow version - - NXF_VER: "21.10.3" - NXF_EDGE: "" - # Test latest edge release of Nextflow - - NXF_VER: "" - NXF_EDGE: "1" + NXF_VER: + - "22.10.1" + - "latest-everything" steps: - name: Check out pipeline code - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Install Nextflow - env: - NXF_VER: ${{ matrix.NXF_VER }} - # Uncomment only if the edge release is more recent than the latest stable release - # See https://github.com/nextflow-io/nextflow/issues/2467 - # NXF_EDGE: ${{ matrix.NXF_EDGE }} + uses: nf-core/setup-nextflow@v1 + with: + version: "${{ matrix.NXF_VER }}" + + - name: Download test data + # Download A fungal test data set that is full enough to show some real output. + run: | + curl https://tolit.cog.sanger.ac.uk/test-data/resources/treeval/TreeValTinyData.tar.gz | tar xzf - + + - name: Run RAPID pipeline with test data + # Remember that you can parallelise this by using strategy.matrix run: | - wget -qO- get.nextflow.io | bash - sudo mv nextflow /usr/local/bin/ + nextflow run ${GITHUB_WORKSPACE} -entry RAPID -profile test_github,docker --outdir ./results-rapid - - name: Run pipeline with test data - # TODO nf-core: You can customise CI pipeline run tests as required - # For example: adding multiple test runs with different parameters + - name: Run FULL pipeline with test data # Remember that you can parallelise this by using strategy.matrix run: | - nextflow run ${GITHUB_WORKSPACE} -profile test,docker --outdir ./results + nextflow run ${GITHUB_WORKSPACE} -profile test_github,docker --outdir ./results-full diff --git a/.github/workflows/clean-up.yml b/.github/workflows/clean-up.yml new file mode 100644 index 00000000..694e90ec --- /dev/null +++ b/.github/workflows/clean-up.yml @@ -0,0 +1,24 @@ +name: "Close user-tagged issues and PRs" +on: + schedule: + - cron: "0 0 * * 0" # Once a week + +jobs: + clean-up: + runs-on: ubuntu-latest + permissions: + issues: write + pull-requests: write + steps: + - uses: actions/stale@v7 + with: + stale-issue-message: "This issue has been tagged as awaiting-changes or awaiting-feedback by an nf-core contributor. Remove stale label or add a comment otherwise this issue will be closed in 20 days." + stale-pr-message: "This PR has been tagged as awaiting-changes or awaiting-feedback by an nf-core contributor. Remove stale label or add a comment if it is still useful." + close-issue-message: "This issue was closed because it has been tagged as awaiting-changes or awaiting-feedback by an nf-core contributor and then staled for 20 days with no activity." + days-before-stale: 30 + days-before-close: 20 + days-before-pr-close: -1 + any-of-labels: "awaiting-changes,awaiting-feedback" + exempt-issue-labels: "WIP" + exempt-pr-labels: "WIP" + repo-token: "${{ secrets.GITHUB_TOKEN }}" diff --git a/.github/workflows/fix-linting.yml b/.github/workflows/fix-linting.yml index d0230831..392d57f7 100644 --- a/.github/workflows/fix-linting.yml +++ b/.github/workflows/fix-linting.yml @@ -9,7 +9,7 @@ jobs: if: > contains(github.event.comment.html_url, '/pull/') && contains(github.event.comment.body, '@nf-core-bot fix linting') && - github.repository == 'nf-core/treeval' + github.repository == 'sanger-tol/treeval' runs-on: ubuntu-latest steps: # Use the @nf-core-bot token to check out so we can push later @@ -24,7 +24,7 @@ jobs: env: GITHUB_TOKEN: ${{ secrets.nf_core_bot_auth_token }} - - uses: actions/setup-node@v2 + - uses: actions/setup-node@v3 - name: Install Prettier run: npm install -g prettier @prettier/plugin-php @@ -34,9 +34,9 @@ jobs: id: prettier_status run: | if prettier --check ${GITHUB_WORKSPACE}; then - echo "::set-output name=result::pass" + echo "result=pass" >> $GITHUB_OUTPUT else - echo "::set-output name=result::fail" + echo "result=fail" >> $GITHUB_OUTPUT fi - name: Run 'prettier --write' diff --git a/.github/workflows/linting.yml b/.github/workflows/linting.yml index 77358dee..3f27dab4 100644 --- a/.github/workflows/linting.yml +++ b/.github/workflows/linting.yml @@ -4,6 +4,8 @@ name: nf-core linting # that the code meets the nf-core guidelines. on: push: + branches: + - dev pull_request: release: types: [published] @@ -12,9 +14,9 @@ jobs: EditorConfig: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - - uses: actions/setup-node@v2 + - uses: actions/setup-node@v3 - name: Install editorconfig-checker run: npm install -g editorconfig-checker @@ -25,9 +27,9 @@ jobs: Prettier: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - - uses: actions/setup-node@v2 + - uses: actions/setup-node@v3 - name: Install Prettier run: npm install -g prettier @@ -35,28 +37,54 @@ jobs: - name: Run Prettier --check run: prettier --check ${GITHUB_WORKSPACE} + PythonBlack: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + + - name: Check code lints with Black + uses: psf/black@stable + + # If the above check failed, post a comment on the PR explaining the failure + - name: Post PR comment + if: failure() + uses: mshick/add-pr-comment@v1 + with: + message: | + ## Python linting (`black`) is failing + + To keep the code consistent with lots of contributors, we run automated code consistency checks. + To fix this CI test, please run: + + * Install [`black`](https://black.readthedocs.io/en/stable/): `pip install black` + * Fix formatting errors in your pipeline: `black .` + + Once you push these changes the test should pass, and you can hide this comment :+1: + + We highly recommend setting up Black in your code editor so that this formatting is done automatically on save. Ask about it on Slack for help! + + Thanks again for your contribution! + repo-token: ${{ secrets.GITHUB_TOKEN }} + allow-repeats: false + nf-core: runs-on: ubuntu-latest steps: - name: Check out pipeline code - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Install Nextflow - env: - CAPSULE_LOG: none - run: | - wget -qO- get.nextflow.io | bash - sudo mv nextflow /usr/local/bin/ + uses: nf-core/setup-nextflow@v1 - - uses: actions/setup-python@v3 + - uses: actions/setup-python@v4 with: - python-version: "3.6" + python-version: "3.8" architecture: "x64" - name: Install dependencies run: | python -m pip install --upgrade pip - pip install nf-core + pip install nf-core==2.8.0 - name: Run nf-core lint env: @@ -71,7 +99,7 @@ jobs: - name: Upload linting log file artifact if: ${{ always() }} - uses: actions/upload-artifact@v2 + uses: actions/upload-artifact@v3 with: name: linting-logs path: | diff --git a/.github/workflows/linting_comment.yml b/.github/workflows/linting_comment.yml index 04758f61..0bbcd30f 100644 --- a/.github/workflows/linting_comment.yml +++ b/.github/workflows/linting_comment.yml @@ -18,7 +18,7 @@ jobs: - name: Get PR number id: pr_number - run: echo "::set-output name=pr_number::$(cat linting-logs/PR_number.txt)" + run: echo "pr_number=$(cat linting-logs/PR_number.txt)" >> $GITHUB_OUTPUT - name: Post PR comment uses: marocchino/sticky-pull-request-comment@v2 diff --git a/.github/workflows/sanger_test_full.yml b/.github/workflows/sanger_test_full.yml new file mode 100644 index 00000000..e028c6b6 --- /dev/null +++ b/.github/workflows/sanger_test_full.yml @@ -0,0 +1,43 @@ +name: sanger-tol LSF full size tests + +on: + push: + branches: + - main + - dev + workflow_dispatch: +jobs: + run-tower: + name: Run LSF full size tests + runs-on: ubuntu-latest + steps: + - name: Sets env vars for push + run: | + echo "REVISION=${{ github.sha }}" >> $GITHUB_ENV + if: github.event_name == 'push' + + - name: Sets env vars for workflow_dispatch + run: | + echo "REVISION=${{ github.sha }}" >> $GITHUB_ENV + if: github.event_name == 'workflow_dispatch' + + - name: Launch workflow via tower + uses: seqeralabs/action-tower-launch@v2 + with: + workspace_id: ${{ secrets.TOWER_WORKSPACE_ID }} + access_token: ${{ secrets.TOWER_ACCESS_TOKEN }} + compute_env: ${{ secrets.TOWER_COMPUTE_ENV }} + revision: ${{ env.REVISION }} + workdir: ${{ secrets.TOWER_WORKDIR_PARENT }}/work/${{ github.repository }}/work-${{ env.REVISION }} + parameters: | + { + "outdir": "${{ secrets.TOWER_WORKDIR_PARENT }}/results/${{ github.repository }}/results-${{ env.REVISION }}", + } + profiles: test_full,sanger,singularity,cleanup + + - uses: actions/upload-artifact@v3 + with: + name: Tower debug log file + path: | + tower_action_*.log + tower_action_*.json diff --git a/.gitpod.yml b/.gitpod.yml index 85d95ecc..7cc49dcd 100644 --- a/.gitpod.yml +++ b/.gitpod.yml @@ -1,14 +1,148 @@ -image: nfcore/gitpod:latest +image: gitpod/workspace-full-vnc +# Update 7th September to reflect code base changes +ports: + - name: JBrowseWeb + description: The JBrowse Webserver port + port: 3000 + onOpen: open-browser + visibility: public + + - name: HiGlass + description: The HiGlass port + port: 8989 + onOpen: open-browser + visibility: public + +tasks: + - name: Install Singularity 3.11.4 + # https://docs.sylabs.io/guides/3.0/user-guide/installation.html + init: | + cd /workspace/treeval-curation/ + + sudo apt-get update && sudo apt-get install -y \ + build-essential \ + libssl-dev \ + uuid-dev \ + libgpgme11-dev \ + squashfs-tools \ + libseccomp-dev \ + pkg-config + + mkdir -p $GOPATH/src/github.com/sylabs && \ + cd $GOPATH/src/github.com/sylabs && \ + wget https://github.com/sylabs/singularity/releases/download/v3.11.4/singularity-ce-3.11.4.tar.gz && \ + tar -xzf singularity-ce-3.11.4.tar.gz && \ + cd ./singularity-ce-3.11.4 && \ + ./mconfig + + ./mconfig && \ + make -C ./builddir && \ + sudo make -C ./builddir install + + - name: Install Nextflow + # https://www.nextflow.io/docs/latest/getstarted.html + init: | + cd /workspace/treeval-curation/ + + wget -qO- https://get.nextflow.io | bash + + chmod +x nextflow + + nextflow self-update + + - name: Install JBrowse2 + # https://jbrowse.org/jb2/download/#jbrowse-cli-tools + command: | + cd /workspace/treeval-curation/ + + npm install -g @jbrowse/cli + + jbrowse create jbrowse2 + + cd jbrowse2/ + + npx serve . -l 3000 + + - name: Install TreeVal Pipeline + # https://github.com/sanger-tol/treeval + init: | + cd /workspace/treeval-curation/ + + git clone -b pre-tag https://github.com/sanger-tol/treeval.git + + - name: Install Curtation Pretext + # https://github.com/sanger-tol/curationpretext + init: | + cd /workspace/treeval-curation/ + + git clone -b dev https://github.com/sanger-tol/curationpretext.git + + - name: Install HiGlass + # https://docs.higlass.io/tutorial.html + init: | + cd /workspace/treeval-curation/ + + pip install higlass-manage + + higlass-manage start + + - name: Alias Nextflow + init: | + cd /workspace/treeval-curation/ + + echo "alias nextflow_cmd='/workspace/treeval-curation/nextflow'" >> ~/.bashrc + + source ~/.bashrc + + - name: Download busco for nematode + init: | + cd /workspace/treeval-curation/ + + curl https://dp24.cog.sanger.ac.uk/Busco.tar.gz | tar xzf - + + - name: Download Nematode Test data and make synteny + init: | + cd /workspace/treeval-curation/ + + curl https://dp24.cog.sanger.ac.uk/Nematode.tar.gz | tar xzf - + + mkdir -p /workspace/treeval-curation/synteny/nematode/ + + cp /workspace/treeval-curation/Oscheius_DF5033/genomic_data/Oscheius_DF5033.fa /workspace/treeval-curation/synteny/nematode/SuperNematode.fa + + - name: Download Lepidoptera data + init: | + cd /workspace/treeval-curation/ + + curl https://dp24.cog.sanger.ac.uk/ilTorViri5.tar.gz | tar xzf - + + - name: Download Genomic Alignment data + init: | + cd /workspace/treeval-curation/ + + curl https://dp24.cog.sanger.ac.uk/AlignmentData.tar.gz | tar xzf - + + - name: Open Tutorial Page + init: | + gp preview https://bga23.org/treeval-curation/Tutorial/ + +github: + prebuilds: + # enable for the master/default branch (defaults to true) + master: true + # add a "Review in Gitpod" button as a comment to pull requests (defaults to true) + addComment: true + # add a "Review in Gitpod" button to pull requests (defaults to false) + addBadge: true + # add a label once the prebuild is ready to pull requests (defaults to false) + addLabel: prebuilt-in-gitpod vscode: extensions: # based on nf-core.nf-core-extensionpack - codezombiech.gitignore # Language support for .gitignore files - # - cssho.vscode-svgviewer # SVG viewer - esbenp.prettier-vscode # Markdown/CommonMark linting and style checking for Visual Studio Code - - eamodio.gitlens # Quickly glimpse into whom, why, and when a line or code block was changed - EditorConfig.EditorConfig # override user/workspace settings with settings found in .editorconfig files - - Gruntfuggly.todo-tree # Display TODO and FIXME in a tree view in the activity bar - mechatroner.rainbow-csv # Highlight columns in csv files in different colors - # - nextflow.nextflow # Nextflow syntax highlighting + - nextflow.nextflow # Nextflow syntax highlighting - oderwat.indent-rainbow # Highlight indentation level - streetsidesoftware.code-spell-checker # Spelling checker for source code diff --git a/.nf-core.yml b/.nf-core.yml index 3805dc81..c96cc78d 100644 --- a/.nf-core.yml +++ b/.nf-core.yml @@ -1 +1,20 @@ repository_type: pipeline +lint: + files_exist: + - assets/nf-core-treeval_logo_light.png + - conf/test_full.config + - docs/images/nf-core-treeval_logo_light.png + - docs/images/nf-core-treeval_logo_dark.png + files_unchanged: + - .github/workflows/linting.yml + - .github/CONTRIBUTING.md + - LICENSE + - .github/ISSUE_TEMPLATE/bug_report.yml + - assets/sendmail_template.txt + - lib/NfcoreTemplate.groovy + - .prettierignore + nextflow_config: + - manifest.name + - manifest.homePage + multiqc_config: + - report_comment diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml new file mode 100644 index 00000000..0c31cdb9 --- /dev/null +++ b/.pre-commit-config.yaml @@ -0,0 +1,5 @@ +repos: + - repo: https://github.com/pre-commit/mirrors-prettier + rev: "v2.7.1" + hooks: + - id: prettier diff --git a/.prettierignore b/.prettierignore index d0e7ae58..437d763d 100644 --- a/.prettierignore +++ b/.prettierignore @@ -1,4 +1,6 @@ email_template.html +adaptivecard.json +slackreport.json .nextflow* work/ data/ @@ -7,3 +9,4 @@ results/ testing/ testing* *.pyc +bin/ diff --git a/CHANGELOG.md b/CHANGELOG.md old mode 100644 new mode 100755 index ac7351de..79e4e815 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,16 +1,98 @@ -# nf-core/treeval: Changelog +# sanger-tol/treeval: Changelog The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). -## v1.0dev - [date] +## [1.0.0] - Ancient Atlantis - [2023-06-27] -Initial release of nf-core/treeval, created with the [nf-core](https://nf-co.re/) template. +Initial release of sanger-tol/treeval, created with the [nf-core](https://nf-co.re/) template. -### `Added` +The essential pathways of the gEVAL pipeline have now been converted to Nextflow DSL2 from vr-runner, snakemake and wr. Of the original pipeline there is only Bionano left to implement. -### `Fixed` +### Enhancements & Fixes -### `Dependencies` +- Updated to nf-core/tools template v2.8.0. +- Subworkflow to generate channels from input yaml. +- Subworkflow to generate genome summary file using samtools +- Subworkflow to generate busco gene tracks and ancestral busco mapping. +- Subworkflow to generate HiC maps with cooler, juicebox and pretext. +- Subworkflow to generate gene alignments using miniprot and minimap2. +- Subworkflow to generate insilico digest tracks. +- Subworkflow to generate longread coverage tracks from pacbio data. +- Subworkflow to generate punchlists detailing regions of interest in the genome. +- Subworkflow to generate repeat density tracks. +- Subworkflow to generate tracks detailing self complementary regions. +- Subworkflow to generate syntenic alignments to high quality genomes. +- Subworkflow to generate tracks containing telomeric sites. +- Custom Groovy for reporting to provide file metrics and resource usage. +- Citations and all docs (including walkthroughs). +- Added gitpod.yml for running in the cloud. This is the tutorial written for BGA23. -### `Deprecated` +### Parameters + +| Old Parameter | New Parameter | +| ------------- | ------------- | +| - | --input | + +### Software dependencies + +Note, since the pipeline is using Nextflow DSL2, each process will be run with its own Biocontainer. This means that on occasion it is entirely possible for the pipeline to be using different versions of the same tool. However, the overall software dependency changes compared to the last release have been listed below for reference. + +| Module | Old Version | New Versions | +| -------------------------------------- | ----------- | ---------------- | +| assign_ancestal ( pandas + Python ) | - | 1.5.2 + 3.9 | +| bamtobed_sort ( bedtools + samtools ) | - | 2.31.0 + 1.17 | +| bedtools | - | 2.31.0 | +| busco | - | 5.4.3 | +| bwa-mem2 | - | 2.2.1 | +| cat | - | 2.3.4 | +| chunk_fasta ( pyfasta ) | - | 0.5.2-1 | +| cooler | - | 0.9.2 | +| concat_block ( coreutils ) | - | 9.1 | +| concat_mummer ( coreutils ) | - | 9.1 | +| cram_filter_align_bwamem2_fixmate_sort | - | | +| ^ ( samtools + bwamem2 ) ^ | - | 1.16.1 + 2.2.1 | +| extract_ancestral ( python ) | - | 3.9 | +| extract_buscogene ( coreutils ) | - | 9.1 | +| extract_cov_id ( coreutils ) | - | 9.1 | +| extract_repeat ( perl ) | - | 5.26.2 | +| extract_telo ( coreutils ) | - | 9.1 | +| find_telomere_regions ( gcc ) | - | 7.1.0 | +| find_telomere_windows ( java-jdk ) | - | 8.0.112 | +| findhalfcoverage ( python ) | - | 3.9 | +| gap_length ( coreutils ) | - | 9.1 | +| generate_cram_csv ( samtools ) | - | 1.17 | +| get_largest_scaff ( coreutils ) | - | 9.1 | +| get_paired_contact_bed ( coreutils ) | - | 9.1 | +| get_synteny_genomes ( coreutils ) | - | 9.1 | +| getminmaxpunches ( coreutils ) | - | 9.1 | +| graphoverallcoverage ( perl ) | - | 5.26.2 | +| gnu-sort | - | 8.25 | +| juicer_tools_pre ( java-jdk ) | - | 8.0.112 | +| makecmap_cmap2bed ( python ) | - | 3.9 | +| makecmap_fa2cmapmulticolor ( perl ) | - | 5.26.2 | +| makecmap_renamecmapids ( perl ) | - | 5.26.2 | +| minimap2 + samtools | - | 2.24 + 1.14 | +| miniprot | - | 0.11--he4a0461_2 | +| mummer | - | 3.23 | +| paf_to_bed ( coreutils ) | - | 9.1 | +| paftools ( minimap2 + samtools ) | - | 2.24 + 1.14 | +| pretextmap + samtools | - | 0.1.9 + 1.17 | +| reformat_intersect ( coreutils ) | - | 9.1 | +| reformat_ids ( coreutils ) | - | 9.1 | +| replace_dots ( coreutils ) | - | 9.1 | +| samtools | - | 1.17 | +| selfcomp_alignmentblocks ( python ) | - | 3.9 | +| selfcomp_mapids ( python ) | - | 3.9 | +| selfcomp_mummer2bed ( python ) | - | 3.9 | +| selfcomp_splitfasta ( perl-bioperl ) | - | 1.7.8-1 | +| seqtk | - | 1.4 | +| tabix | - | 1.11 | +| ucsc | - | 377 | +| windowmasker (blast) | - | 2.14.0 | + +### Fixed + +### Dependencies + +### Deprecated diff --git a/CITATIONS.md b/CITATIONS.md old mode 100644 new mode 100755 index afc187af..d179e501 --- a/CITATIONS.md +++ b/CITATIONS.md @@ -1,35 +1,128 @@ -# nf-core/treeval: Citations +# sanger-tol/treeval: Citations ## [nf-core](https://pubmed.ncbi.nlm.nih.gov/32055031/) -> Ewels PA, Peltzer A, Fillinger S, Patel H, Alneberg J, Wilm A, Garcia MU, Di Tommaso P, Nahnsen S. The nf-core framework for community-curated bioinformatics pipelines. Nat Biotechnol. 2020 Mar;38(3):276-278. doi: 10.1038/s41587-020-0439-x. PubMed PMID: 32055031. +> Ewels, P. et al. 2020. ‘The NF-core framework for community-curated bioinformatics pipelines’, Nature Biotechnology, 38(3), pp. 276–278. doi:10.1038/s41587-020-0439-x. ## [Nextflow](https://pubmed.ncbi.nlm.nih.gov/28398311/) -> Di Tommaso P, Chatzou M, Floden EW, Barja PP, Palumbo E, Notredame C. Nextflow enables reproducible computational workflows. Nat Biotechnol. 2017 Apr 11;35(4):316-319. doi: 10.1038/nbt.3820. PubMed PMID: 28398311. +> Di Tommaso, P. et al. 2017. ‘Nextflow enables reproducible computational workflows’, Nature Biotechnology, 35(4), pp. 316–319. doi:10.1038/nbt.3820. ## Pipeline tools -- [FastQC](https://www.bioinformatics.babraham.ac.uk/projects/fastqc/) +- [Bedtools](https://bedtools.readthedocs.io/en/latest/) -- [MultiQC](https://pubmed.ncbi.nlm.nih.gov/27312411/) - > Ewels P, Magnusson M, Lundin S, Käller M. MultiQC: summarize analysis results for multiple tools and samples in a single report. Bioinformatics. 2016 Oct 1;32(19):3047-8. doi: 10.1093/bioinformatics/btw354. Epub 2016 Jun 16. PubMed PMID: 27312411; PubMed Central PMCID: PMC5039924. + > Quinlan, A.R. and Hall, I.M. 2010. ‘BEDTools: A flexible suite of utilities for comparing genomic features’, Bioinformatics, 26(6), pp. 841–842. doi:10.1093/bioinformatics/btq033. + +- [BUSCO](https://busco.ezlab.org) + + > Manni, M. et al. 2021. Busco update: Novel and streamlined workflows along with broader and deeper phylogenetic coverage for scoring of eukaryotic, prokaryotic, and viral genomes, Molecular biology and evolution. Available at: https://pubmed.ncbi.nlm.nih.gov/34320186/ (Accessed: 22 June 2023). + +- [bwa-mem2](https://ieeexplore.ieee.org/document/8820962) + + > Vasimuddin, Md. et al. 2019. ‘Efficient architecture-aware acceleration of BWA-mem for multicore systems’, 2019 IEEE International Parallel and Distributed Processing Symposium (IPDPS) [Preprint]. doi:10.1109/ipdps.2019.00041. + +- [Cooler](https://github.com/open2c/cooler) + + > Abdennur, N. and Mirny, L.A. 2019. ‘Cooler: Scalable storage for hi-C data and other genomically labeled arrays’, Bioinformatics, 36(1), pp. 311–316. doi:10.1093/bioinformatics/btz540. + +- [Find Telomere](https://github.com/VGP/vgp-assembly/tree/master/pipeline/telomere) + + > VGP. 2022. vgp-assembly telomere [online]. https://github.com/VGP/vgp-assembly/tree/master/pipeline/telomere. (Accessed on 28th February 2023). + +- [Juicer](https://github.com/aidenlab/juicer) + + > Durand, N.C. et al. 2016. ‘Juicer provides a one-click system for analyzing loop-resolution hi-C experiments’, Cell Systems, 3(1), pp. 95–98. doi:10.1016/j.cels.2016.07.002. + +- [Minimap2](https://pubmed.ncbi.nlm.nih.gov/34623391/) + + > Li, H. 2021. ‘New strategies to improve MINIMAP2 alignment accuracy’, Bioinformatics, 37(23), pp. 4572–4574. doi:10.1093/bioinformatics/btab705. + +- [Miniprot](https://arxiv.org/abs/2210.08052) + + > Li, H. 2022. Protein-to-genome alignment with miniprot (v2). Arxiv [e-journal]. (Accessed on 25th January 2023). doi: 10.48550/arXiv.2210.08052. + +- [Mummer](https://journals.plos.org/ploscompbiol/article?id=10.1371/journal.pcbi.1005944) + + > Marçais, G. et al. 2018. ‘Mummer4: A fast and versatile genome alignment system’, PLOS Computational Biology, 14(1). doi:10.1371/journal.pcbi.1005944. + +- [Pandas](https://pandas.pydata.org/) + + > Redback, J. 2022. pandas-dev/pandas: Pandas 1.4.3 [online]. Zenodo. doi: 10.5281/zenodo.6702671. (Accessed on 28th February 2023). + +- [Perl](https://perldoc.perl.org/perl) + + > Perl Organisation. 2023. Perl Language Reference v5.36.0. https://perldoc.perl.org/perl. (Accessed 28th February 2023). + +- [PretextMap](https://github.com/wtsi-hpag/PretextMap) + + > Harry, E. 2022. PretextView [online]. https://github.com/wtsi-hpag/PretextView. (Accessed on 7th June 2023). + +- [Pybedtools](https://github.com/daler/pybedtools) + + > Daler. 2022. pybedtools [online]. https://github.com/daler/pybedtools. (Accessed on 7th June 2023). + +- [Python: 3.10](https://docs.python.org/3.10/whatsnew/3.10.html) + + > Python Software Foundation. 2023. Python Language Reference v3.10. https://docs.python.org/3.10/whatsnew/3.10.html. (Accessed 28th February 2023). + +- [PyFasta](https://github.com/brentp/pyfasta/) + + > Brentp. 2018. pyfasta [online]. http://github.com/brentp/pyfasta/. (Accessed on 7th June 2023). + +- [Samtools](https://pubmed.ncbi.nlm.nih.gov/33590861/) + + > Di Tommaso, Paolo, et al. 2017. “Nextflow Enables Reproducible Computational Workflows.” Nature Biotechnology, 35(4), pp. 316–19, https://doi.org/10.1038/nbt.3820. + +- [SeqTK](https://github.com/lh3/seqtk) + + > Li, Heng. 2023. seqtk [online]. https://github.com/lh3/seqtk. (Accessed on 7th June 2023). + +- [staden_io_lib / iolib](https://github.com/jkbonfield/io_lib) + + > Bonfield JK. 2023. io_lib [online]. https://github.com/jkbonfield/io_lib. (Accessed on 7th June 2023). + +- [Tabix](http://www.htslib.org/doc/tabix.html) + + > Li, Heng. 2023. tabix [online]. http://www.htslib.org/doc/tabix.html. (Accessed on 7th June 2023). + +- [UCSC tools](https://github.com/ucscGenomeBrowser/kent/tree/master) + + > UCSC Genome Browser Group. 2023. kent [online]. https://github.com/ucscGenomeBrowser/kent/tree/master. (Accessed on 7th June 2023). + +- [WindowMasker](https://pubmed.ncbi.nlm.nih.gov/16287941/) + + > Morgulis, A., et al. 2006. WindowMasker: window-based masker for sequenced genomes. Bioinformatics. 22(2). pp.134–141. doi: 10.1093/bioinformatics/bti774. + +- [lep_busco_painter](https://www.biorxiv.org/content/10.1101/2023.05.12.540473v1.full.pdf) + + > Wright, C. et al. 2023. Chromosome evolution in Lepidoptera. bioRxiv. 540473. https://doi.org/10.1101/2023.05.12.540473 + +- [Java](https://docs.oracle.com/javase/8/docs/api/overview-summary.html) + + > Oracle. 2023. Java Documentation. https://docs.oracle.com/javase/8/docs/index.html. (Accessed on 25th September 2023). + +- [coreutils](https://github.com/coreutils/coreutils) + + > GNU Coreutils. 2023. coreutils [online]. https://github.com/coreutils/coreutils/releases/tag/v9.4. (Accessed on 25th September 2023). ## Software packaging/containerisation tools - [Anaconda](https://anaconda.com) - > Anaconda Software Distribution. Computer software. Vers. 2-2.4.0. Anaconda, Nov. 2016. Web. + > Anaconda Software Distribution. 2016. Computer software. Vers. 2-2.4.0. Anaconda, Web. - [Bioconda](https://pubmed.ncbi.nlm.nih.gov/29967506/) - > Grüning B, Dale R, Sjödin A, Chapman BA, Rowe J, Tomkins-Tinch CH, Valieris R, Köster J; Bioconda Team. Bioconda: sustainable and comprehensive software distribution for the life sciences. Nat Methods. 2018 Jul;15(7):475-476. doi: 10.1038/s41592-018-0046-7. PubMed PMID: 29967506. + > Di Tommaso, Paolo, et al. 2017. “Nextflow Enables Reproducible Computational Workflows.” Nature Biotechnology, 35(4), pp. 316–19, https://doi.org/10.1038/nbt.3820. - [BioContainers](https://pubmed.ncbi.nlm.nih.gov/28379341/) - > da Veiga Leprevost F, Grüning B, Aflitos SA, Röst HL, Uszkoreit J, Barsnes H, Vaudel M, Moreno P, Gatto L, Weber J, Bai M, Jimenez RC, Sachsenberg T, Pfeuffer J, Alvarez RV, Griss J, Nesvizhskii AI, Perez-Riverol Y. BioContainers: an open-source and community-driven framework for software standardization. Bioinformatics. 2017 Aug 15;33(16):2580-2582. doi: 10.1093/bioinformatics/btx192. PubMed PMID: 28379341; PubMed Central PMCID: PMC5870671. + > Grüning, Björn, et al. 2018. “Bioconda: sustainable and comprehensive software distribution for the life sciences". Nature Methods, 15, pp. 475-6, https://doi.org/10.1038/s41592-018-0046-7. - [Docker](https://dl.acm.org/doi/10.5555/2600239.2600241) + > Merkel, Dirk, et al. 2014. “Docker: Lightweight Linux Containers for Consistent Development and Deployment.". Association for Computing Machinery. 2014(239) + - [Singularity](https://pubmed.ncbi.nlm.nih.gov/28494014/) - > Kurtzer GM, Sochat V, Bauer MW. Singularity: Scientific containers for mobility of compute. PLoS One. 2017 May 11;12(5):e0177459. doi: 10.1371/journal.pone.0177459. eCollection 2017. PubMed PMID: 28494014; PubMed Central PMCID: PMC5426675. + > Kurtzer, Gregory M., et al. 2017. “Singularity: Scientific containers for mobility of compute.", PLOS ONE, 12(5), pp. e0177459, https://doi.org/10.1371/journal.pone.0177459. diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md old mode 100644 new mode 100755 diff --git a/LICENSE b/LICENSE old mode 100644 new mode 100755 index 2b0cab1e..ac4a5f34 --- a/LICENSE +++ b/LICENSE @@ -1,6 +1,6 @@ MIT License -Copyright (c) Yumi Sims, Damon-Lee Pointon, William Eagles +Copyright (c) 2022 - 2023 Genome Research Ltd. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/README.md b/README.md old mode 100644 new mode 100755 index 8c756107..436826b3 --- a/README.md +++ b/README.md @@ -1,148 +1,85 @@ -# ![nf-core/treeval](docs/images/nf-core-treeval_logo_light.png#gh-light-mode-only) ![nf-core/treeval](docs/images/nf-core-treeval_logo_dark.png#gh-dark-mode-only) - -[![GitHub Actions CI Status](https://github.com/nf-core/treeval/workflows/nf-core%20CI/badge.svg)](https://github.com/nf-core/treeval/actions?query=workflow%3A%22nf-core+CI%22) -[![GitHub Actions Linting Status](https://github.com/nf-core/treeval/workflows/nf-core%20linting/badge.svg)](https://github.com/nf-core/treeval/actions?query=workflow%3A%22nf-core+linting%22) -[![Cite with Zenodo](http://img.shields.io/badge/DOI-10.5281/zenodo.XXXXXXX-1073c8)](https://doi.org/10.5281/zenodo.XXXXXXX) - -[![Nextflow](https://img.shields.io/badge/nextflow%20DSL2-%E2%89%A521.10.3-23aa62.svg)](https://www.nextflow.io/) -[![run with conda](http://img.shields.io/badge/run%20with-conda-3EB049?logo=anaconda)](https://docs.conda.io/en/latest/) -[![run with docker](https://img.shields.io/badge/run%20with-docker-0db7ed?logo=docker)](https://www.docker.com/) -[![run with singularity](https://img.shields.io/badge/run%20with-singularity-1d355c.svg)](https://sylabs.io/docs/) -[![Launch on Nextflow Tower](https://img.shields.io/badge/Launch%20%F0%9F%9A%80-Nextflow%20Tower-%234256e7)](https://tower.nf/launch?pipeline=https://github.com/nf-core/treeval) +[![Cite with Zenodo](http://img.shields.io/badge/DOI-10.5281/zenodo.XXXXXXX-1073c8?labelColor=000000)](https://doi.org/10.5281/zenodo.XXXXXXX) +[![Nextflow](https://img.shields.io/badge/nextflow%20DSL2-%E2%89%A522.10.1-23aa62.svg)](https://www.nextflow.io/) +[![run with conda](http://img.shields.io/badge/run%20with-conda-3EB049?labelColor=000000&logo=anaconda)](https://docs.conda.io/en/latest/) +[![run with docker](https://img.shields.io/badge/run%20with-docker-0db7ed?labelColor=000000&logo=docker)](https://www.docker.com/) +[![run with singularity](https://img.shields.io/badge/run%20with-singularity-1d355c.svg?labelColor=000000)](https://sylabs.io/docs/) +[![Launch on Nextflow Tower](https://img.shields.io/badge/Launch%20%F0%9F%9A%80-Nextflow%20Tower-%234256e7)](https://tower.nf/launch?pipeline=https://github.com/sanger-tol/treeval) ## Introduction -**nf-core/treeval** is a pipeline to generate jBrowse compatible datafiles for genome curation. +**sanger-tol/treeval** is a bioinformatics best-practice analysis pipeline for the generation of data supplemental to the curation of reference quality genomes. This pipeline has been written to generate flat files compatible with [JBrowse2](https://jbrowse.org/jb2/). The pipeline is built using [Nextflow](https://www.nextflow.io), a workflow tool to run tasks across multiple compute infrastructures in a very portable manner. It uses Docker/Singularity containers making installation trivial and results highly reproducible. The [Nextflow DSL2](https://www.nextflow.io/docs/latest/dsl2.html) implementation of this pipeline uses one container per process which makes it much easier to maintain and update software dependencies. Where possible, these processes have been submitted to and installed from [nf-core/modules](https://github.com/nf-core/modules) in order to make them available to all nf-core pipelines, and to everyone within the Nextflow community! - - -## Pipeline summary - -The version 1 pipeline will be made up of the following steps: - -- INPUT_READ - - - The reading of the input yaml and conversion into channels for the sub-workflows. - - -- GENERATE_GENOME - - - Generate .genome for the input genome. - - Uses SAMTOOLS FAIDX. - - -- GENERATE_ALIGNMENT - - - Peptides will run pep_alignment.nf - - Uses Miniprot. - - - CDNA, RNA and CDS will run through nuc_alignment.nf - - Uses Minimap2. - - -- INSILICO DIGEST - - - Generates a map of enzymatic digests using 3 Bionano enzymes - - Uses Bionano software. - - -- SELFCOMP - - - Identifies regions of self-complementary sequence - - Uses Mummer. - -- SYNTENY +The treeval pipeline has a sister pipeline currently named [curationpretext](https://github.com/sanger-tol/curationpretext) which acts to regenerate the pretext maps and accessory files during genomic curation in order to confirm interventions. This pipeline is sufficiently different to the treeval implementation that it is written as it's own pipeline. - - Generates syntenic alignments between other high quality genomes. - - Uses Minimap2. +1. Parse input yaml ( YAML_INPUT ) +2. Generate my.genome file ( GENERATE_GENOME ) +3. Generate insilico digests of the input assembly ( INSILICO_DIGEST ) +4. Generate gene alignments with high quality data against the input assembly ( GENE_ALIGNMENT ) +5. Generate a repeat density graph ( REPEAT_DENSITY ) +6. Generate a gap track ( GAP_FINDER ) +7. Generate a map of self complementary sequence ( SELFCOMP ) +8. Generate syntenic alignments with a closely related high quality assembly ( SYNTENY ) +9. Generate a coverage track using PacBio data ( LONGREAD_COVERAGE ) +10. Generate HiC maps, pretext and higlass using HiC cram files ( HIC_MAPPING ) +11. Generate a telomere track based on input motif ( TELO_FINDER ) +12. Run Busco and convert results into bed format ( BUSCO_ANNOTATION ) +13. Ancestral Busco linkage if available for clade ( BUSCO_ANNOTATION:ANCESTRAL_GENE ) +## Usage -- ANCESTRAL ELEMENT ANALYSIS - - Lepidopteran Element Analysis - - Uses BUSCO and custom python scripts to parse ancestral lep genes - - This will eventually have a number of clade specific sub-workflows. +> **Note** +> If you are new to Nextflow and nf-core, please refer to [this page](https://nf-co.re/docs/usage/installation) on how +> to set-up Nextflow. Make sure to [test your setup](https://nf-co.re/docs/usage/introduction#how-to-run-a-pipeline) +> with `-profile test` before running the workflow on actual data. +Currently, it is advised to run the pipeline with docker or singularity as a small number of major modules do not currently have a conda env associated with them. -## Quick Start +Now, you can run the pipeline using: -1. Install [`Nextflow`](https://www.nextflow.io/docs/latest/getstarted.html#installation) (`>=21.10.3`) +```bash +# For the FULL pipeline +nextflow run main.nf -profile singularity --input treeval.yaml --outdir {OUTDIR} -2. Install any of [`Docker`](https://docs.docker.com/engine/installation/), [`Singularity`](https://www.sylabs.io/guides/3.0/user-guide/) (you can follow [this tutorial](https://singularity-tutorial.github.io/01-installation/)), [`Podman`](https://podman.io/), [`Shifter`](https://nersc.gitlab.io/development/shifter/how-to-use/) or [`Charliecloud`](https://hpc.github.io/charliecloud/) for full pipeline reproducibility _(you can use [`Conda`](https://conda.io/miniconda.html) both to install Nextflow itself and also to manage software within pipelines. Please only use it within pipelines as a last resort; see [docs](https://nf-co.re/usage/configuration#basic-configuration-profiles))_. +# For the RAPID subset +nextflow run main.nf -profile singularity --input treeval.yaml -entry RAPID --outdir {OUTDIR} +``` -3. Download the pipeline and test it on a minimal dataset with a single command: +An example treeval.yaml can be found [here](assets/local_testing/nxOscDF5033.yaml). - ```console - nextflow run nf-core/treeval -profile test,YOURPROFILE --outdir - ``` +Further documentation about the pipeline can be found in the following files: [usage](https://pipelines.tol.sanger.ac.uk/treeval/dev/usage), [parameters](https://pipelines.tol.sanger.ac.uk/treeval/dev/parameters) and [output](https://pipelines.tol.sanger.ac.uk/treeval/dev/output). - Note that some form of configuration will be needed so that Nextflow knows how to fetch the required software. This is usually done in the form of a config profile (`YOURPROFILE` in the example command above). You can chain multiple config profiles in a comma-separated string. - - > - The pipeline comes with config profiles called `docker`, `singularity`, `podman`, `shifter`, `charliecloud` and `conda` which instruct the pipeline to use the named tool for software management. For example, `-profile test,docker`. - > - Please check [nf-core/configs](https://github.com/nf-core/configs#documentation) to see if a custom config file to run nf-core pipelines already exists for your Institute. If so, you can simply use `-profile ` in your command. This will enable either `docker` or `singularity` and set the appropriate execution settings for your local compute environment. - > - If you are using `singularity`, please use the [`nf-core download`](https://nf-co.re/tools/#downloading-pipelines-for-offline-use) command to download images first, before running the pipeline. Setting the [`NXF_SINGULARITY_CACHEDIR` or `singularity.cacheDir`](https://www.nextflow.io/docs/latest/singularity.html?#singularity-docker-hub) Nextflow options enables you to store and re-use the images from a central location for future pipeline runs. - > - If you are using `conda`, it is highly recommended to use the [`NXF_CONDA_CACHEDIR` or `conda.cacheDir`](https://www.nextflow.io/docs/latest/conda.html) settings to store the environments in a central location for future pipeline runs. - -4. Start running your own analysis! - - - - ```console - nextflow run main.nf -profile singularity --input treeval.yaml - ``` - - LSF specific run - ```console - echo "nextflow run main.nf -profile singularity --input treeval.yaml" | bsub -Is -tty -e error -o out -n 10 -q normal -M10000 -R'select[mem>10000] rusage[mem=10000] span[hosts=1]' - ``` - -## Documentation - -The nf-core/treeval pipeline comes with documentation about the pipeline [usage](https://nf-co.re/treeval/usage), [parameters](https://nf-co.re/treeval/parameters) and [output](https://nf-co.re/treeval/output). +> **Warning:** +> Please provide pipeline parameters via the CLI or Nextflow `-params-file` option. Custom config files including those +> provided by the `-c` Nextflow option can be used to provide any configuration _**except for parameters**_; +> see [docs](https://nf-co.re/usage/configuration#custom-configuration-files). ## Credits -nf-core/treeval was originally written by Damon-Lee Pointon (@DLBPointon), Yumi Sims (@yumisims) and William Eagles (@weaglesBio). +sanger-tol/treeval has been written by Damon-Lee Pointon (@DLBPointon), Yumi Sims (@yumisims) and William Eagles (@weaglesBio). We thank the following people for their extensive assistance in the development of this pipeline: -@muffato -@gq1 -@ksenia-krasheninnikova -@priyanka-surana +
    +
  • @gq1 - For building the infrastructure around TreeVal and helping with code review
  • +
  • @ksenia-krasheninnikova - For help with C code implementation and YAML parsing
  • +
  • @mcshane - For guidance on algorithms
  • +
  • @muffato - For code reviews and code support
  • +
  • @priyanka-surana - For help with the majority of code reviews and code support
  • +
## Contributions and Support If you would like to contribute to this pipeline, please see the [contributing guidelines](.github/CONTRIBUTING.md). -For further information or help, don't hesitate to get in touch on the [Slack `#treeval` channel](https://nfcore.slack.com/channels/treeval) (you can join with [this invite](https://nf-co.re/join/slack)). - ## Citations - - -### Tools + -BedTools +If you use sanger-tol/treeval for your analysis, please cite it using the following doi: [10.5281/zenodo.XXXXXX](https://doi.org/10.5281/zenodo.XXXXXX). -Bionano CMAP - -BUSCO - -Minimap2 - -Miniprot - -Mummer - -Python3 - -Samtools - -TABIX - -UCSC +### Tools An extensive list of references for the tools used by the pipeline can be found in the [`CITATIONS.md`](CITATIONS.md) file. diff --git a/assets/adaptivecard.json b/assets/adaptivecard.json new file mode 100755 index 00000000..eac75b32 --- /dev/null +++ b/assets/adaptivecard.json @@ -0,0 +1,67 @@ +{ + "type": "message", + "attachments": [ + { + "contentType": "application/vnd.microsoft.card.adaptive", + "contentUrl": null, + "content": { + "\$schema": "http://adaptivecards.io/schemas/adaptive-card.json", + "msteams": { + "width": "Full" + }, + "type": "AdaptiveCard", + "version": "1.2", + "body": [ + { + "type": "TextBlock", + "size": "Large", + "weight": "Bolder", + "color": "<% if ( success ) { %>Good<% } else { %>Attention<%} %>", + "text": "sanger-tol/treeval v${version} - ${runName}", + "wrap": true + }, + { + "type": "TextBlock", + "spacing": "None", + "text": "Completed at ${dateComplete} (duration: ${duration})", + "isSubtle": true, + "wrap": true + }, + { + "type": "TextBlock", + "text": "<% if (success) { %>Pipeline completed successfully!<% } else { %>Pipeline completed with errors. The full error message was: ${errorReport}.<% } %>", + "wrap": true + }, + { + "type": "TextBlock", + "text": "The command used to launch the workflow was as follows:", + "wrap": true + }, + { + "type": "TextBlock", + "text": "${commandLine}", + "isSubtle": true, + "wrap": true + } + ], + "actions": [ + { + "type": "Action.ShowCard", + "title": "Pipeline Configuration", + "card": { + "type": "AdaptiveCard", + "\$schema": "http://adaptivecards.io/schemas/adaptive-card.json", + "body": [ + { + "type": "FactSet", + "facts": [<% out << summary.collect{ k,v -> "{\"title\": \"$k\", \"value\" : \"$v\"}"}.join(",\n") %> + ] + } + ] + } + } + ] + } + } + ] +} diff --git a/assets/busco_gene/busco.as b/assets/busco_gene/busco.as new file mode 100755 index 00000000..b40f17e3 --- /dev/null +++ b/assets/busco_gene/busco.as @@ -0,0 +1,11 @@ +table Merian +"busco merian elements" +( +string chrom; "Reference sequence chromosome or scaffold" +uint chromStart; "Start position of feature on chromosome" +uint chromEnd; "End position of feature on chromosome" +string name; "busco ID" +string score; "Score" +char[1] strand; "+ or - for strand" +string OrthoDBurl; "OrthoDB url" +) diff --git a/assets/busco_gene/lep_ancestral.tsv b/assets/busco_gene/lep_ancestral.tsv new file mode 100755 index 00000000..05155e8e --- /dev/null +++ b/assets/busco_gene/lep_ancestral.tsv @@ -0,0 +1,5287 @@ +buscoID Status ancestral Status2 Status3 +0at7088 Complete M27 0 1 +10001at7088 Complete M8 0 1 +10003at7088 Complete M11 0 1 +10006at7088 Complete M19 0 1 +1000at7088 Complete M25 0 1 +10013at7088 Complete M10 0 1 +10014at7088 Complete M1 0 1 +10015at7088 Complete M7 0 1 +10017at7088 Complete M19 0 1 +10020at7088 Complete M8 0 1 +10023at7088 Complete M10 0 1 +10024at7088 Complete M6 0 1 +10025at7088 Complete M25 0 1 +10029at7088 Complete M17 0 1 +1003at7088 Complete M4 0 1 +10043at7088 Complete M14 0 1 +10048at7088 Complete M8 0 1 +1004at7088 Complete M3 0 1 +10056at7088 Complete M2 0 1 +10057at7088 Complete M1 0 1 +10059at7088 Complete M12 0 1 +1005at7088 Complete M6 0 1 +10062at7088 Complete M28 0 1 +10066at7088 Complete M29 0 1 +10067at7088 Complete M3 0 1 +10068at7088 Complete M4 0 1 +10076at7088 Complete M7 0 1 +10079at7088 Complete M6 0 1 +1007at7088 Complete M16 0 1 +10082at7088 Complete M16 0 1 +10086at7088 Complete M22 0 1 +10087at7088 Complete M16 0 1 +10090at7088 Complete M4 0 1 +10093at7088 Complete M20 0 1 +10096at7088 Complete M6 0 1 +10097at7088 Complete M15 0 1 +1009at7088 Complete M3 0 1 +10101at7088 Complete MZ 0 1 +10102at7088 Complete M6 0 1 +10107at7088 Complete M26 0 1 +10109at7088 Complete M19 0 1 +1010at7088 Complete M4 0 1 +10110at7088 Complete M16 0 1 +10114at7088 Complete M15 0 1 +10118at7088 Complete M8 0 1 +1011at7088 Complete M10 0 1 +10121at7088 Complete M8 0 1 +10124at7088 Complete M4 0 1 +10125at7088 Complete M6 0 1 +10127at7088 Complete M8 0 1 +10139at7088 Complete M12 0 1 +1013at7088 Complete M1 0 1 +10142at7088 Complete M30 0 1 +10145at7088 Complete M18 0 1 +10146at7088 Complete M10 0 1 +10149at7088 Complete M6 0 1 +1014at7088 Complete M4 0 1 +10150at7088 Complete M24 0 1 +10151at7088 Complete M9 0 1 +10153at7088 Complete M16 0 1 +10157at7088 Complete M15 0 1 +10160at7088 Complete M19 0 1 +10163at7088 Complete M27 0 1 +10164at7088 Complete M17 0 1 +10171at7088 Complete M30 0 1 +10173at7088 Complete M16 0 1 +10174at7088 Complete M8 0 1 +10178at7088 Complete M2 0 1 +10179at7088 Complete M18 0 1 +10180at7088 Complete M11 0 1 +10181at7088 Complete M4 0 1 +10183at7088 Complete M4 0 1 +10186at7088 Complete M3 0 1 +10188at7088 Complete M4 0 1 +10189at7088 Complete M14 0 1 +10192at7088 Complete M7 0 1 +10193at7088 Complete M15 0 1 +10199at7088 Complete M11 0 1 +101at7088 Complete MZ 0 1 +10202at7088 Complete MZ 0 1 +10206at7088 Complete M23 0 1 +10208at7088 Complete M11 0 1 +1020at7088 Complete M16 0 1 +10212at7088 Complete M18 0 1 +10213at7088 Complete MZ 0 1 +10214at7088 Complete M20 0 1 +10215at7088 Complete M19 0 1 +10219at7088 Complete M10 0 1 +1021at7088 Complete M12 0 1 +10220at7088 Complete M10 0 1 +10224at7088 Complete M18 0 1 +10225at7088 Complete M24 0 1 +10235at7088 Complete M5 0 1 +10238at7088 Complete M9 0 1 +10239at7088 Complete M13 0 1 +10240at7088 Complete M5 0 1 +10243at7088 Complete M9 0 1 +10244at7088 Complete M3 0 1 +10248at7088 Complete M7 0 1 +10250at7088 Complete M10 0 1 +10255at7088 Complete M1 0 1 +10256at7088 Complete M20 0 1 +10259at7088 Complete M18 0 1 +10261at7088 Complete M9 0 1 +10267at7088 Complete M9 0 1 +10268at7088 Complete M22 0 1 +10269at7088 Complete M2 0 1 +1026at7088 Complete M15 0 1 +10270at7088 Complete M12 0 1 +1027at7088 Complete M2 0 1 +10285at7088 Complete M8 0 1 +10287at7088 Complete M16 0 1 +10289at7088 Complete M24 0 1 +10291at7088 Complete M5 0 1 +10292at7088 Complete M1 0 1 +10294at7088 Complete M20 0 1 +10296at7088 Complete M9 0 1 +10299at7088 Complete M10 0 1 +10304at7088 Complete M16 0 1 +10308at7088 Complete M13 0 1 +10313at7088 Complete M20 0 1 +10316at7088 Complete M12 0 1 +10318at7088 Complete M5 0 1 +10319at7088 Complete M18 0 1 +10326at7088 Complete M10 0 1 +1032at7088 Complete MZ 0 1 +10331at7088 Complete M27 0 1 +10333at7088 Complete M21 0 1 +10334at7088 Complete M9 0 1 +10335at7088 Complete M4 0 1 +1033at7088 Complete M5 0 1 +10341at7088 Complete M18 0 1 +10343at7088 Complete M12 0 1 +10345at7088 Complete M5 0 1 +10346at7088 Complete M3 0 1 +10347at7088 Complete M4 0 1 +10348at7088 Complete M3 0 1 +10351at7088 Complete M14 0 1 +10352at7088 Complete M16 0 1 +10359at7088 Complete M15 0 1 +10360at7088 Complete M20 0 1 +10367at7088 Complete M6 0 1 +10368at7088 Complete M21 0 1 +10369at7088 Complete M11 0 1 +10374at7088 Complete M25 0 1 +10377at7088 Complete M18 0 1 +10379at7088 Complete M21 0 1 +1037at7088 Complete M15 0 1 +10386at7088 Complete M10 0 1 +10387at7088 Complete M1 0 1 +1038at7088 Complete MZ 0 1 +10391at7088 Complete M23 0 1 +10392at7088 Complete M4 0 1 +10396at7088 Complete M7 0 1 +10397at7088 Complete M2 0 1 +10398at7088 Complete M8 0 1 +103at7088 Complete M20 0 1 +10401at7088 Complete M16 0 1 +10406at7088 Complete M1 0 1 +10410at7088 Complete M11 0 1 +10414at7088 Complete M22 0 1 +10415at7088 Complete M21 0 1 +10418at7088 Complete MZ 0 1 +10423at7088 Complete M13 0 1 +10424at7088 Complete M14 0 1 +10425at7088 Complete M4 0 1 +10428at7088 Complete M10 0 1 +10429at7088 Complete MZ 0 1 +10431at7088 Complete M1 0 1 +10432at7088 Complete M25 0 1 +10437at7088 Complete M8 0 1 +10444at7088 Complete M24 0 1 +10445at7088 Complete M1 0 1 +10447at7088 Complete M5 0 1 +10452at7088 Complete M6 0 1 +10456at7088 Complete M1 0 1 +10457at7088 Complete M21 0 1 +10459at7088 Complete M3 0 1 +10460at7088 Complete M4 0 1 +10462at7088 Complete M3 0 1 +10474at7088 Complete M19 0 1 +10476at7088 Complete M4 0 1 +10479at7088 Complete M24 0 1 +1047at7088 Complete M10 0 1 +10480at7088 Complete M24 0 1 +10482at7088 Complete M12 0 1 +10489at7088 Complete M14 0 1 +10494at7088 Complete M19 0 1 +10496at7088 Complete M9 0 1 +10502at7088 Complete M8 0 1 +10506at7088 Complete M7 0 1 +10508at7088 Complete M1 0 1 +1050at7088 Complete M7 0 1 +10511at7088 Complete M14 0 1 +10512at7088 Complete M18 0 1 +10513at7088 Complete M7 0 1 +10516at7088 Complete M6 0 1 +10517at7088 Complete M30 0 1 +10521at7088 Complete M1 0 1 +10527at7088 Complete M12 0 1 +10528at7088 Complete M7 0 1 +10529at7088 Complete M16 0 1 +10530at7088 Complete M22 0 1 +10533at7088 Complete M22 0 1 +10536at7088 Complete M3 0 1 +10538at7088 Complete M26 0 1 +1053at7088 Complete M16 0 1 +10541at7088 Complete M9 0 1 +10542at7088 Complete M1 0 1 +10543at7088 Complete M18 0 1 +10546at7088 Complete M9 0 1 +10547at7088 Complete M15 0 1 +10549at7088 Complete M25 0 1 +10550at7088 Complete M10 0 1 +10553at7088 Complete M6 0 1 +10556at7088 Complete M19 0 1 +10558at7088 Complete M22 0 1 +10559at7088 Complete M30 0 1 +10562at7088 Complete M23 0 1 +10565at7088 Complete M7 0 1 +10568at7088 Complete M11 0 1 +1056at7088 Complete M1 0 1 +10570at7088 Complete M2 0 1 +10571at7088 Complete M12 0 1 +10573at7088 Complete M5 0 1 +1057at7088 Complete M21 0 1 +10580at7088 Complete M12 0 1 +10581at7088 Complete M6 0 1 +10582at7088 Complete M22 0 1 +10583at7088 Complete M9 0 1 +10586at7088 Complete M2 0 1 +10588at7088 Complete M17 0 1 +1058at7088 Complete M11 0 1 +10593at7088 Complete M13 0 1 +10598at7088 Complete M8 0 1 +105at7088 Complete M27 0 1 +10601at7088 Complete M25 0 1 +10603at7088 Complete M2 0 1 +10609at7088 Complete M23 0 1 +10613at7088 Complete M4 0 1 +10619at7088 Complete M27 0 1 +10620at7088 Complete M28 0 1 +10625at7088 Complete M8 0 1 +10626at7088 Complete M6 0 1 +10628at7088 Complete M14 0 1 +10633at7088 Complete M18 0 1 +10635at7088 Complete M20 0 1 +10636at7088 Complete M8 0 1 +1063at7088 Complete M15 0 1 +10646at7088 Complete M5 0 1 +10648at7088 Complete M3 0 1 +10650at7088 Complete M3 0 1 +10651at7088 Complete M2 0 1 +10659at7088 Complete M24 0 1 +1065at7088 Complete M27 0 1 +10660at7088 Complete M1 0 1 +10661at7088 Complete M2 0 1 +10662at7088 Complete M11 0 1 +10663at7088 Complete M11 0 1 +10666at7088 Complete M20 0 1 +10667at7088 Complete M19 0 1 +10669at7088 Complete M5 0 1 +1066at7088 Complete MZ 0 1 +10671at7088 Complete M10 0 1 +10673at7088 Complete M25 0 1 +10674at7088 Complete M12 0 1 +10676at7088 Complete M2 0 1 +10677at7088 Complete M27 0 1 +10678at7088 Complete M6 0 1 +10681at7088 Complete M18 0 1 +10683at7088 Complete M1 0 1 +10689at7088 Complete M8 0 1 +1068at7088 Complete M13 0 1 +10690at7088 Complete M14 0 1 +10692at7088 Complete M16 0 1 +10693at7088 Complete M9 0 1 +10694at7088 Complete M6 0 1 +10698at7088 Complete MZ 0 1 +10699at7088 Complete M3 0 1 +106at7088 Complete M8 0 1 +10704at7088 Complete M22 0 1 +10707at7088 Complete M4 0 1 +10709at7088 Complete M8 0 1 +1070at7088 Complete M10 0 1 +10712at7088 Complete M15 0 1 +10713at7088 Complete M1 0 1 +10716at7088 Complete M20 0 1 +10717at7088 Complete M2 0 1 +10721at7088 Complete M2 0 1 +10724at7088 Complete M11 0 1 +10728at7088 Complete M11 0 1 +10734at7088 Complete M26 0 1 +10735at7088 Complete M2 0 1 +10738at7088 Complete M4 0 1 +10740at7088 Complete M2 0 1 +10747at7088 Complete M16 0 1 +10749at7088 Complete M11 0 1 +10750at7088 Complete M17 0 1 +1075at7088 Complete M2 0 1 +10766at7088 Complete M18 0 1 +10768at7088 Complete MZ 0 1 +1076at7088 Complete M17 0 1 +10773at7088 Complete M18 0 1 +10778at7088 Complete M24 0 1 +10780at7088 Complete M6 0 1 +10782at7088 Complete M5 0 1 +10783at7088 Complete M16 0 1 +10784at7088 Complete M13 0 1 +10789at7088 Complete M24 0 1 +1078at7088 Complete M4 0 1 +10791at7088 Complete M15 0 1 +10792at7088 Complete M6 0 1 +10793at7088 Complete M21 0 1 +10796at7088 Complete M1 0 1 +10799at7088 Complete M5 0 1 +1079at7088 Complete M2 0 1 +10801at7088 Complete M20 0 1 +1080at7088 Complete M19 0 1 +10810at7088 Complete M18 0 1 +10812at7088 Complete M6 0 1 +10814at7088 Complete M20 0 1 +10816at7088 Complete M11 0 1 +10818at7088 Complete M16 0 1 +10821at7088 Complete M13 0 1 +10822at7088 Complete M5 0 1 +10826at7088 Complete M16 0 1 +10827at7088 Complete M4 0 1 +10829at7088 Complete M9 0 1 +1082at7088 Complete M8 0 1 +10830at7088 Complete M21 0 1 +1083at7088 Complete MZ 0 1 +10841at7088 Complete M5 0 1 +1084at7088 Complete M23 0 1 +10853at7088 Complete MZ 0 1 +10858at7088 Complete M23 0 1 +1085at7088 Complete M10 0 1 +10862at7088 Complete M8 0 1 +10865at7088 Complete M6 0 1 +1086at7088 Complete M6 0 1 +10875at7088 Complete M17 0 1 +10878at7088 Complete M4 0 1 +10879at7088 Complete M25 0 1 +10887at7088 Complete M20 0 1 +1088at7088 Complete M8 0 1 +10896at7088 Complete M5 0 1 +10898at7088 Complete M6 0 1 +1089at7088 Complete M9 0 1 +10904at7088 Complete M3 0 1 +10906at7088 Complete M10 0 1 +10908at7088 Complete M11 0 1 +1090at7088 Complete MZ 0 1 +10913at7088 Complete M17 0 1 +10915at7088 Complete M6 0 1 +10916at7088 Complete M3 0 1 +10917at7088 Complete M17 0 1 +10926at7088 Complete M2 0 1 +10929at7088 Complete M12 0 1 +10930at7088 Complete M23 0 1 +10933at7088 Complete M13 0 1 +10936at7088 Complete M3 0 1 +10939at7088 Complete M3 0 1 +10940at7088 Complete M6 0 1 +10943at7088 Complete M11 0 1 +10947at7088 Complete M9 0 1 +10948at7088 Complete MZ 0 1 +1094at7088 Complete M17 0 1 +10952at7088 Complete M3 0 1 +10953at7088 Complete M11 0 1 +10959at7088 Complete M13 0 1 +10960at7088 Complete M21 0 1 +10963at7088 Complete M14 0 1 +10965at7088 Complete M18 0 1 +10966at7088 Complete M19 0 1 +10973at7088 Complete M18 0 1 +10976at7088 Complete M23 0 1 +10977at7088 Complete M9 0 1 +10981at7088 Complete M1 0 1 +10982at7088 Complete M9 0 1 +10983at7088 Complete M20 0 1 +10988at7088 Complete M10 0 1 +10990at7088 Complete M17 0 1 +10997at7088 Complete M4 0 1 +10999at7088 Complete M11 0 1 +11004at7088 Complete M18 0 1 +1100at7088 Complete M20 0 1 +11010at7088 Complete M12 0 1 +11011at7088 Complete M13 0 1 +11014at7088 Complete M4 0 1 +11018at7088 Complete M11 0 1 +11020at7088 Complete M10 0 1 +11022at7088 Complete M18 0 1 +11023at7088 Complete M3 0 1 +11026at7088 Complete M6 0 1 +11029at7088 Complete M6 0 1 +11030at7088 Complete M14 0 1 +11032at7088 Complete M20 0 1 +11033at7088 Complete M11 0 1 +11034at7088 Complete MZ 0 1 +11039at7088 Complete M9 0 1 +11041at7088 Complete M9 0 1 +11043at7088 Complete M8 0 1 +11046at7088 Complete M20 0 1 +11053at7088 Complete M24 0 1 +11054at7088 Complete M2 0 1 +11056at7088 Complete M10 0 1 +11058at7088 Complete M20 0 1 +11059at7088 Complete M21 0 1 +11060at7088 Complete M3 0 1 +11062at7088 Complete M17 0 1 +11063at7088 Complete M6 0 1 +11065at7088 Complete M11 0 1 +11066at7088 Complete M21 0 1 +11067at7088 Complete M5 0 1 +11069at7088 Complete M18 0 1 +11070at7088 Complete M15 0 1 +11072at7088 Complete M22 0 1 +1107at7088 Complete M4 0 1 +11080at7088 Complete M28 0 1 +11086at7088 Complete M21 0 1 +11089at7088 Complete M1 0 1 +1108at7088 Complete M17 0 1 +11090at7088 Complete M5 0 1 +11095at7088 Complete M15 0 1 +11100at7088 Complete M1 0 1 +11101at7088 Complete M5 0 1 +11106at7088 Complete M1 0 1 +11110at7088 Complete M6 0 1 +11111at7088 Complete M3 0 1 +11115at7088 Complete M6 0 1 +11119at7088 Complete M14 0 1 +1111at7088 Complete M14 0 1 +11122at7088 Complete M8 0 1 +11124at7088 Complete M3 0 1 +11127at7088 Complete M13 0 1 +11132at7088 Complete M25 0 1 +1113at7088 Complete M7 0 1 +11142at7088 Complete M2 0 1 +11144at7088 Complete M4 0 1 +11147at7088 Complete M15 0 1 +11148at7088 Complete M15 0 1 +1114at7088 Complete M14 0 1 +11150at7088 Complete M30 0 1 +11151at7088 Complete M17 0 1 +11158at7088 Complete M16 0 1 +11160at7088 Complete MZ 0 1 +11161at7088 Complete M4 0 1 +11165at7088 Complete M5 0 1 +11166at7088 Complete M28 0 1 +11174at7088 Complete M6 0 1 +11175at7088 Complete MZ 0 1 +11177at7088 Complete M13 0 1 +11178at7088 Complete M23 0 1 +1117at7088 Complete M16 0 1 +11184at7088 Complete M2 0 1 +11185at7088 Complete M18 0 1 +11189at7088 Complete M15 0 1 +1118at7088 Complete M6 0 1 +11190at7088 Complete M4 0 1 +11191at7088 Complete M12 0 1 +11192at7088 Complete M17 0 1 +11195at7088 Complete M24 0 1 +11198at7088 Complete M5 0 1 +11201at7088 Complete M14 0 1 +1120at7088 Complete M1 0 1 +11213at7088 Complete M10 0 1 +11214at7088 Complete M8 0 1 +11215at7088 Complete M5 0 1 +11218at7088 Complete M30 0 1 +1121at7088 Complete M20 0 1 +11221at7088 Complete M5 0 1 +11224at7088 Complete M24 0 1 +11225at7088 Complete M19 0 1 +11231at7088 Complete M17 0 1 +11233at7088 Complete M18 0 1 +11234at7088 Complete M15 0 1 +11235at7088 Complete M16 0 1 +11237at7088 Complete M14 0 1 +11239at7088 Complete M11 0 1 +1123at7088 Complete M23 0 1 +11240at7088 Complete M21 0 1 +1124at7088 Complete M16 0 1 +11256at7088 Complete M14 0 1 +11258at7088 Complete M15 0 1 +11260at7088 Complete M21 0 1 +11262at7088 Complete M9 0 1 +11264at7088 Complete M3 0 1 +11265at7088 Complete M8 0 1 +11268at7088 Complete M7 0 1 +11269at7088 Complete M4 0 1 +1126at7088 Complete M5 0 1 +11272at7088 Complete M10 0 1 +11273at7088 Complete M19 0 1 +11274at7088 Complete M3 0 1 +11275at7088 Complete M2 0 1 +11282at7088 Complete M4 0 1 +11283at7088 Complete M8 0 1 +11285at7088 Complete M7 0 1 +11288at7088 Complete M10 0 1 +11292at7088 Complete M14 0 1 +11293at7088 Complete M5 0 1 +11294at7088 Complete M13 0 1 +11295at7088 Complete M6 0 1 +11298at7088 Complete M10 0 1 +112at7088 Complete M3 0 1 +11302at7088 Complete M10 0 1 +11303at7088 Complete M8 0 1 +1130at7088 Complete M11 0 1 +11311at7088 Complete M3 0 1 +11312at7088 Complete M4 0 1 +11313at7088 Complete M7 0 1 +11318at7088 Complete M22 0 1 +1131at7088 Complete M3 0 1 +11321at7088 Complete M18 0 1 +11334at7088 Complete M5 0 1 +11335at7088 Complete M5 0 1 +11336at7088 Complete M6 0 1 +11337at7088 Complete M16 0 1 +11338at7088 Complete M7 0 1 +1133at7088 Complete M8 0 1 +11342at7088 Complete M18 0 1 +11346at7088 Complete M4 0 1 +11349at7088 Complete M17 0 1 +1134at7088 Complete M10 0 1 +11350at7088 Complete M5 0 1 +11353at7088 Complete M8 0 1 +11356at7088 Complete M1 0 1 +11359at7088 Complete M15 0 1 +1135at7088 Complete M15 0 1 +11363at7088 Complete M12 0 1 +11365at7088 Complete M4 0 1 +11367at7088 Complete M29 0 1 +11368at7088 Complete M1 0 1 +1136at7088 Complete M2 0 1 +11372at7088 Complete M6 0 1 +11374at7088 Complete M14 0 1 +11375at7088 Complete M3 0 1 +11377at7088 Complete M10 0 1 +11378at7088 Complete M3 0 1 +11379at7088 Complete M7 0 1 +11380at7088 Complete M13 0 1 +11382at7088 Complete M25 0 1 +11383at7088 Complete M4 0 1 +11389at7088 Complete M10 0 1 +11390at7088 Complete M8 0 1 +11393at7088 Complete M30 0 1 +11396at7088 Complete M2 0 1 +11397at7088 Complete M1 0 1 +1139at7088 Complete M1 0 1 +113at7088 Complete MZ 0 1 +11401at7088 Complete M23 0 1 +11403at7088 Complete M21 0 1 +11404at7088 Complete M15 0 1 +11405at7088 Complete M12 0 1 +1140at7088 Complete M17 0 1 +11416at7088 Complete M3 0 1 +11418at7088 Complete M12 0 1 +1141at7088 Complete M3 0 1 +11423at7088 Complete M9 0 1 +11426at7088 Complete M4 0 1 +11428at7088 Complete MZ 0 1 +11437at7088 Complete M12 0 1 +11438at7088 Complete M8 0 1 +1143at7088 Complete M23 0 1 +11441at7088 Complete M1 0 1 +11442at7088 Complete M18 0 1 +1144at7088 Complete MZ 0 1 +11450at7088 Complete M10 0 1 +11451at7088 Complete M1 0 1 +11454at7088 Complete M1 0 1 +11456at7088 Complete M3 0 1 +1145at7088 Complete M18 0 1 +11462at7088 Complete M6 0 1 +11474at7088 Complete M4 0 1 +11479at7088 Complete M15 0 1 +11482at7088 Complete M25 0 1 +11483at7088 Complete M1 0 1 +11484at7088 Complete M4 0 1 +11489at7088 Complete M19 0 1 +11490at7088 Complete M12 0 1 +11492at7088 Complete M4 0 1 +11493at7088 Complete M1 0 1 +11500at7088 Complete M26 0 1 +11501at7088 Complete M3 0 1 +11505at7088 Complete M2 0 1 +11507at7088 Complete M3 0 1 +1150at7088 Complete M8 0 1 +11511at7088 Complete M9 0 1 +11512at7088 Complete M15 0 1 +11516at7088 Complete M4 0 1 +11518at7088 Complete M5 0 1 +11519at7088 Complete M11 0 1 +11522at7088 Complete M21 0 1 +11525at7088 Complete M1 0 1 +1152at7088 Complete M9 0 1 +11533at7088 Complete M11 0 1 +11534at7088 Complete M9 0 1 +11536at7088 Complete M23 0 1 +11537at7088 Complete M4 0 1 +1153at7088 Complete M7 0 1 +11546at7088 Complete M8 0 1 +11547at7088 Complete M1 0 1 +11548at7088 Complete M11 0 1 +11549at7088 Complete M24 0 1 +1154at7088 Complete M19 0 1 +11550at7088 Complete M19 0 1 +11558at7088 Complete M1 0 1 +11560at7088 Complete M2 0 1 +11563at7088 Complete M17 0 1 +11571at7088 Complete M9 0 1 +11575at7088 Complete M18 0 1 +11576at7088 Complete M28 0 1 +11580at7088 Complete MZ 0 1 +11581at7088 Complete M2 0 1 +11582at7088 Complete M14 0 1 +11587at7088 Complete M3 0 1 +11589at7088 Complete M12 0 1 +11592at7088 Complete M10 0 1 +11593at7088 Complete M5 0 1 +11594at7088 Complete M4 0 1 +11597at7088 Complete M1 0 1 +11598at7088 Complete M2 0 1 +11599at7088 Complete M1 0 1 +11607at7088 Complete M6 0 1 +11608at7088 Complete M4 0 1 +11609at7088 Complete M7 0 1 +11616at7088 Complete M11 0 1 +11619at7088 Complete MZ 0 1 +1161at7088 Complete M17 0 1 +11621at7088 Complete M19 0 1 +11630at7088 Complete M7 0 1 +11633at7088 Complete M12 0 1 +11638at7088 Complete M27 0 1 +11644at7088 Complete MZ 0 1 +11648at7088 Complete M14 0 1 +11650at7088 Complete MZ 0 1 +11655at7088 Complete M29 0 1 +11656at7088 Complete M11 0 1 +11657at7088 Complete M27 0 1 +11659at7088 Complete M14 0 1 +1165at7088 Complete M6 0 1 +11660at7088 Complete M30 0 1 +11662at7088 Complete M3 0 1 +11664at7088 Complete M6 0 1 +11665at7088 Complete M8 0 1 +11666at7088 Complete M15 0 1 +11669at7088 Complete M6 0 1 +11672at7088 Complete M16 0 1 +11677at7088 Complete M18 0 1 +1167at7088 Complete M5 0 1 +11681at7088 Complete M13 0 1 +11687at7088 Complete M4 0 1 +1168at7088 Complete M16 0 1 +11693at7088 Complete M2 0 1 +11699at7088 Complete M1 0 1 +116at7088 Complete M1 0 1 +11701at7088 Complete M10 0 1 +11702at7088 Complete M3 0 1 +11703at7088 Complete M4 0 1 +11704at7088 Complete M17 0 1 +11706at7088 Complete M18 0 1 +11710at7088 Complete M6 0 1 +11718at7088 Complete M13 0 1 +11719at7088 Complete M11 0 1 +1171at7088 Complete M7 0 1 +11729at7088 Complete M16 0 1 +1172at7088 Complete M16 0 1 +11731at7088 Complete M18 0 1 +1173at7088 Complete M11 0 1 +11747at7088 Complete M8 0 1 +1174at7088 Complete M23 0 1 +11752at7088 Complete M6 0 1 +11754at7088 Complete M3 0 1 +11760at7088 Complete M26 0 1 +11761at7088 Complete M2 0 1 +11764at7088 Complete M3 0 1 +11765at7088 Complete M8 0 1 +11766at7088 Complete M19 0 1 +11767at7088 Complete M9 0 1 +11769at7088 Complete M10 0 1 +11770at7088 Complete M21 0 1 +11777at7088 Complete M14 0 1 +11779at7088 Complete M20 0 1 +11780at7088 Complete M9 0 1 +11785at7088 Complete M3 0 1 +11786at7088 Complete M1 0 1 +11787at7088 Complete M14 0 1 +1178at7088 Complete M4 0 1 +11793at7088 Complete M24 0 1 +11794at7088 Complete M16 0 1 +11796at7088 Complete M10 0 1 +11799at7088 Complete M3 0 1 +1179at7088 Complete M17 0 1 +11800at7088 Complete M18 0 1 +11803at7088 Complete M10 0 1 +1180at7088 Complete M19 0 1 +11810at7088 Complete M7 0 1 +11811at7088 Complete M30 0 1 +11812at7088 Complete M19 0 1 +11815at7088 Complete M23 0 1 +11817at7088 Complete M17 0 1 +11828at7088 Complete M3 0 1 +1182at7088 Complete M11 0 1 +11833at7088 Complete M2 0 1 +11834at7088 Complete M15 0 1 +11835at7088 Complete M27 0 1 +11842at7088 Complete M15 0 1 +11847at7088 Complete M4 0 1 +11848at7088 Complete M3 0 1 +11855at7088 Complete M19 0 1 +11856at7088 Complete M25 0 1 +11857at7088 Complete M23 0 1 +11858at7088 Complete M22 0 1 +11860at7088 Complete MZ 0 1 +11864at7088 Complete M2 0 1 +11870at7088 Complete M20 0 1 +11872at7088 Complete M21 0 1 +11877at7088 Complete M21 0 1 +1187at7088 Complete M15 0 1 +11880at7088 Complete M23 0 1 +11881at7088 Complete M6 0 1 +11882at7088 Complete M15 0 1 +11890at7088 Complete M2 0 1 +11894at7088 Complete M1 0 1 +11898at7088 Complete M7 0 1 +11901at7088 Complete M2 0 1 +11910at7088 Complete M9 0 1 +11921at7088 Complete M3 0 1 +11922at7088 Complete M1 0 1 +11923at7088 Complete M13 0 1 +11929at7088 Complete M4 0 1 +11930at7088 Complete M15 0 1 +11932at7088 Complete M24 0 1 +11937at7088 Complete M3 0 1 +11941at7088 Complete M3 0 1 +11944at7088 Complete M5 0 1 +11950at7088 Complete M4 0 1 +11956at7088 Complete M10 0 1 +11957at7088 Complete MZ 0 1 +11958at7088 Complete M14 0 1 +11960at7088 Complete M2 0 1 +11961at7088 Complete M14 0 1 +11963at7088 Complete M23 0 1 +11965at7088 Complete M11 0 1 +11967at7088 Complete M7 0 1 +11969at7088 Complete M17 0 1 +11970at7088 Complete M10 0 1 +11972at7088 Complete M2 0 1 +11973at7088 Complete M17 0 1 +11977at7088 Complete M4 0 1 +11978at7088 Complete M13 0 1 +1197at7088 Complete M26 0 1 +11982at7088 Complete M17 0 1 +11983at7088 Complete M14 0 1 +11984at7088 Complete M17 0 1 +11985at7088 Complete M20 0 1 +1198at7088 Complete M16 0 1 +11990at7088 Complete M16 0 1 +11996at7088 Complete M19 0 1 +11997at7088 Complete M11 0 1 +1199at7088 Complete M16 0 1 +11at7088 Complete M11 0 1 +12003at7088 Complete M13 0 1 +12004at7088 Complete M6 0 1 +12006at7088 Complete M14 0 1 +12008at7088 Complete M2 0 1 +1200at7088 Complete M6 0 1 +12011at7088 Complete M11 0 1 +12012at7088 Complete M3 0 1 +12013at7088 Complete M10 0 1 +12016at7088 Complete M6 0 1 +12017at7088 Complete M14 0 1 +12021at7088 Complete M19 0 1 +12023at7088 Complete M21 0 1 +12024at7088 Complete M4 0 1 +12026at7088 Complete M4 0 1 +12028at7088 Complete M8 0 1 +12029at7088 Complete M9 0 1 +12030at7088 Complete M9 0 1 +12031at7088 Complete M10 0 1 +12036at7088 Complete M6 0 1 +12043at7088 Complete M7 0 1 +12054at7088 Complete M2 0 1 +12055at7088 Complete M12 0 1 +12056at7088 Complete M17 0 1 +12058at7088 Complete M18 0 1 +12059at7088 Complete M2 0 1 +12060at7088 Complete M23 0 1 +12061at7088 Complete M19 0 1 +1206at7088 Complete M5 0 1 +12070at7088 Complete M28 0 1 +12073at7088 Complete M9 0 1 +12075at7088 Complete M25 0 1 +12076at7088 Complete M22 0 1 +12082at7088 Complete M15 0 1 +12084at7088 Complete M6 0 1 +12087at7088 Complete M13 0 1 +1208at7088 Complete M1 0 1 +12090at7088 Complete M22 0 1 +12091at7088 Complete M9 0 1 +12093at7088 Complete M11 0 1 +12094at7088 Complete M17 0 1 +12095at7088 Complete M6 0 1 +12096at7088 Complete M17 0 1 +12101at7088 Complete M22 0 1 +12113at7088 Complete M13 0 1 +12117at7088 Complete M13 0 1 +12120at7088 Complete M3 0 1 +12123at7088 Complete M21 0 1 +12125at7088 Complete M18 0 1 +12127at7088 Complete M13 0 1 +1212at7088 Complete M9 0 1 +12133at7088 Complete M7 0 1 +12136at7088 Complete M5 0 1 +12139at7088 Complete M7 0 1 +12140at7088 Complete M18 0 1 +12141at7088 Complete M15 0 1 +12143at7088 Complete M5 0 1 +12148at7088 Complete M4 0 1 +1214at7088 Complete M1 0 1 +12152at7088 Complete M15 0 1 +12153at7088 Complete M15 0 1 +12154at7088 Complete M13 0 1 +12164at7088 Complete M15 0 1 +12173at7088 Complete M1 0 1 +12174at7088 Complete M4 0 1 +1217at7088 Complete M3 0 1 +12180at7088 Complete MZ 0 1 +12183at7088 Complete M20 0 1 +12184at7088 Complete M10 0 1 +12185at7088 Complete M8 0 1 +12187at7088 Complete M14 0 1 +1218at7088 Complete M3 0 1 +12193at7088 Complete M19 0 1 +12198at7088 Complete M10 0 1 +12204at7088 Complete M12 0 1 +1220at7088 Complete M20 0 1 +12210at7088 Complete M8 0 1 +12212at7088 Complete MZ 0 1 +12217at7088 Complete M5 0 1 +12218at7088 Complete M15 0 1 +12219at7088 Complete M11 0 1 +12221at7088 Complete M5 0 1 +12223at7088 Complete M17 0 1 +12225at7088 Complete M20 0 1 +12226at7088 Complete M7 0 1 +12229at7088 Complete M4 0 1 +1222at7088 Complete M15 0 1 +12233at7088 Complete M16 0 1 +12235at7088 Complete M7 0 1 +12237at7088 Complete M23 0 1 +1223at7088 Complete M1 0 1 +12241at7088 Complete M5 0 1 +12243at7088 Complete M12 0 1 +12251at7088 Complete M12 0 1 +12254at7088 Complete M4 0 1 +12264at7088 Complete M11 0 1 +12268at7088 Complete M29 0 1 +12271at7088 Complete M19 0 1 +12273at7088 Complete M19 0 1 +12274at7088 Complete M5 0 1 +12275at7088 Complete M21 0 1 +12276at7088 Complete M13 0 1 +12293at7088 Complete M12 0 1 +12295at7088 Complete M12 0 1 +122at7088 Complete M17 0 1 +12300at7088 Complete M9 0 1 +12310at7088 Complete M16 0 1 +12313at7088 Complete M4 0 1 +12320at7088 Complete M9 0 1 +12322at7088 Complete M4 0 1 +12326at7088 Complete M7 0 1 +12332at7088 Complete M23 0 1 +12334at7088 Complete M19 0 1 +12339at7088 Complete M17 0 1 +12341at7088 Complete M22 0 1 +12343at7088 Complete M16 0 1 +12347at7088 Complete M1 0 1 +12349at7088 Complete M1 0 1 +1234at7088 Complete M6 0 1 +12350at7088 Complete M24 0 1 +12354at7088 Complete M25 0 1 +12355at7088 Complete M16 0 1 +1235at7088 Complete M8 0 1 +12363at7088 Complete M1 0 1 +12364at7088 Complete M12 0 1 +12367at7088 Complete M30 0 1 +12369at7088 Complete M6 0 1 +1236at7088 Complete M16 0 1 +12375at7088 Complete M2 0 1 +12378at7088 Complete M15 0 1 +1237at7088 Complete M3 0 1 +12386at7088 Complete MZ 0 1 +12389at7088 Complete M4 0 1 +12390at7088 Complete M10 0 1 +12391at7088 Complete M4 0 1 +12396at7088 Complete M17 0 1 +12397at7088 Complete M1 0 1 +123at7088 Complete M14 0 1 +12400at7088 Complete M25 0 1 +12401at7088 Complete M2 0 1 +12403at7088 Complete M2 0 1 +12406at7088 Complete M4 0 1 +12413at7088 Complete M14 0 1 +12416at7088 Complete M2 0 1 +12418at7088 Complete M2 0 1 +12419at7088 Complete M12 0 1 +12420at7088 Complete M27 0 1 +12422at7088 Complete M5 0 1 +12426at7088 Complete M4 0 1 +12427at7088 Complete M7 0 1 +12429at7088 Complete M1 0 1 +1242at7088 Complete M9 0 1 +12442at7088 Complete M3 0 1 +12443at7088 Complete M19 0 1 +12444at7088 Complete M2 0 1 +12445at7088 Complete M22 0 1 +12449at7088 Complete M18 0 1 +12450at7088 Complete M7 0 1 +12453at7088 Complete M1 0 1 +1245at7088 Complete M1 0 1 +1246at7088 Complete M11 0 1 +12471at7088 Complete M13 0 1 +12472at7088 Complete M13 0 1 +12481at7088 Complete M12 0 1 +12483at7088 Complete M7 0 1 +12484at7088 Complete M16 0 1 +1248at7088 Complete M13 0 1 +12492at7088 Complete M14 0 1 +12496at7088 Complete M13 0 1 +12503at7088 Complete M15 0 1 +12504at7088 Complete M24 0 1 +12505at7088 Complete M5 0 1 +12507at7088 Complete M13 0 1 +12508at7088 Complete M29 0 1 +1250at7088 Complete M20 0 1 +12510at7088 Complete M10 0 1 +12517at7088 Complete M6 0 1 +1251at7088 Complete M1 0 1 +12530at7088 Complete M26 0 1 +12531at7088 Complete M8 0 1 +12535at7088 Complete M20 0 1 +1253at7088 Complete M2 0 1 +12540at7088 Complete M28 0 1 +12542at7088 Complete M13 0 1 +12543at7088 Complete M18 0 1 +12544at7088 Complete M23 0 1 +12547at7088 Complete M11 0 1 +12550at7088 Complete M4 0 1 +12562at7088 Complete M2 0 1 +12564at7088 Complete M20 0 1 +12566at7088 Complete M16 0 1 +12567at7088 Complete M26 0 1 +1256at7088 Complete M3 0 1 +12572at7088 Complete MZ 0 1 +12574at7088 Complete M15 0 1 +12576at7088 Complete M2 0 1 +12585at7088 Complete M7 0 1 +12589at7088 Complete M6 0 1 +1258at7088 Complete M26 0 1 +12598at7088 Complete M8 0 1 +1259at7088 Complete M23 0 1 +12603at7088 Complete M15 0 1 +12605at7088 Complete M29 0 1 +12607at7088 Complete M20 0 1 +12609at7088 Complete M9 0 1 +12613at7088 Complete M14 0 1 +12617at7088 Complete M20 0 1 +12618at7088 Complete M20 0 1 +12626at7088 Complete M4 0 1 +12628at7088 Complete M15 0 1 +12632at7088 Complete M11 0 1 +12633at7088 Complete M23 0 1 +1263at7088 Complete M18 0 1 +12640at7088 Complete M11 0 1 +12646at7088 Complete M19 0 1 +1264at7088 Complete M5 0 1 +12653at7088 Complete M4 0 1 +12656at7088 Complete M2 0 1 +12660at7088 Complete M3 0 1 +12668at7088 Complete M11 0 1 +12669at7088 Complete MZ 0 1 +12671at7088 Complete M1 0 1 +12673at7088 Complete M1 0 1 +12676at7088 Complete M3 0 1 +12679at7088 Complete M1 0 1 +12680at7088 Complete M9 0 1 +12691at7088 Complete M22 0 1 +12696at7088 Complete M1 0 1 +12699at7088 Complete M26 0 1 +126at7088 Complete M17 0 1 +12704at7088 Complete M23 0 1 +12705at7088 Complete M22 0 1 +12706at7088 Complete MZ 0 1 +12707at7088 Complete M1 0 1 +12709at7088 Complete M25 0 1 +12710at7088 Complete M1 0 1 +12712at7088 Complete M4 0 1 +12713at7088 Complete M12 0 1 +12730at7088 Complete M11 0 1 +12731at7088 Complete M4 0 1 +12733at7088 Complete M7 0 1 +12736at7088 Complete MZ 0 1 +12738at7088 Complete M5 0 1 +1273at7088 Complete M1 0 1 +12744at7088 Complete M11 0 1 +12748at7088 Complete M2 0 1 +1275at7088 Complete M6 0 1 +12763at7088 Complete M9 0 1 +12765at7088 Complete M5 0 1 +12771at7088 Complete M3 0 1 +12773at7088 Complete M7 0 1 +12774at7088 Complete M2 0 1 +12777at7088 Complete M4 0 1 +12778at7088 Complete M5 0 1 +12779at7088 Complete M11 0 1 +12789at7088 Complete M29 0 1 +1278at7088 Complete M2 0 1 +12790at7088 Complete M2 0 1 +12792at7088 Complete M20 0 1 +127at7088 Complete M20 0 1 +12804at7088 Complete M4 0 1 +12810at7088 Complete M4 0 1 +12813at7088 Complete M1 0 1 +12815at7088 Complete M2 0 1 +12817at7088 Complete M17 0 1 +12819at7088 Complete M17 0 1 +1281at7088 Complete M3 0 1 +12820at7088 Complete M22 0 1 +12821at7088 Complete M6 0 1 +12829at7088 Complete M3 0 1 +12830at7088 Complete M9 0 1 +12831at7088 Complete M6 0 1 +12834at7088 Complete M3 0 1 +12838at7088 Complete M15 0 1 +1283at7088 Complete M12 0 1 +12842at7088 Complete M14 0 1 +12847at7088 Complete M17 0 1 +12861at7088 Complete M5 0 1 +12883at7088 Complete M7 0 1 +12884at7088 Complete M5 0 1 +12885at7088 Complete M1 0 1 +12891at7088 Complete M29 0 1 +12892at7088 Complete M16 0 1 +12893at7088 Complete M17 0 1 +12894at7088 Complete M24 0 1 +12895at7088 Complete M4 0 1 +12896at7088 Complete M13 0 1 +12899at7088 Complete M14 0 1 +128at7088 Complete M4 0 1 +12900at7088 Complete M28 0 1 +12903at7088 Complete M17 0 1 +12904at7088 Complete M6 0 1 +12905at7088 Complete M12 0 1 +12910at7088 Complete M8 0 1 +12919at7088 Complete M16 0 1 +1291at7088 Complete M8 0 1 +12920at7088 Complete M13 0 1 +12935at7088 Complete M16 0 1 +12938at7088 Complete M3 0 1 +12959at7088 Complete M7 0 1 +1295at7088 Complete M8 0 1 +12960at7088 Complete M1 0 1 +12964at7088 Complete M21 0 1 +12967at7088 Complete M1 0 1 +1298at7088 Complete M13 0 1 +12990at7088 Complete M8 0 1 +12993at7088 Complete M23 0 1 +12998at7088 Complete M16 0 1 +1299at7088 Complete M5 0 1 +13002at7088 Complete M30 0 1 +13003at7088 Complete M24 0 1 +13004at7088 Complete M22 0 1 +13008at7088 Complete M5 0 1 +1300at7088 Complete M17 0 1 +13010at7088 Complete M3 0 1 +13014at7088 Complete M9 0 1 +13019at7088 Complete M8 0 1 +13020at7088 Complete M13 0 1 +13024at7088 Complete M3 0 1 +13027at7088 Complete M16 0 1 +13029at7088 Complete M7 0 1 +13032at7088 Complete M15 0 1 +13033at7088 Complete M23 0 1 +13034at7088 Complete M17 0 1 +13037at7088 Complete M12 0 1 +13038at7088 Complete MZ 0 1 +13041at7088 Complete M1 0 1 +13042at7088 Complete M11 0 1 +13043at7088 Complete M18 0 1 +13047at7088 Complete M3 0 1 +13049at7088 Complete M5 0 1 +1304at7088 Complete M1 0 1 +13053at7088 Complete M2 0 1 +13057at7088 Complete M3 0 1 +13058at7088 Complete M7 0 1 +13059at7088 Complete M3 0 1 +13065at7088 Complete M17 0 1 +13066at7088 Complete M21 0 1 +13067at7088 Complete M4 0 1 +1306at7088 Complete M6 0 1 +13070at7088 Complete M12 0 1 +13072at7088 Complete M10 0 1 +13075at7088 Complete M22 0 1 +1307at7088 Complete M7 0 1 +13081at7088 Complete M10 0 1 +13082at7088 Complete M22 0 1 +13085at7088 Complete M14 0 1 +13088at7088 Complete M23 0 1 +13091at7088 Complete M10 0 1 +13093at7088 Complete M2 0 1 +13095at7088 Complete M23 0 1 +13097at7088 Complete M9 0 1 +13099at7088 Complete M17 0 1 +13102at7088 Complete M15 0 1 +13105at7088 Complete M15 0 1 +13106at7088 Complete M3 0 1 +13107at7088 Complete M17 0 1 +13109at7088 Complete M2 0 1 +13110at7088 Complete M8 0 1 +13112at7088 Complete M21 0 1 +13114at7088 Complete MZ 0 1 +13117at7088 Complete M6 0 1 +13119at7088 Complete M22 0 1 +13122at7088 Complete M2 0 1 +13124at7088 Complete M20 0 1 +13129at7088 Complete M15 0 1 +13134at7088 Complete M4 0 1 +1313at7088 Complete M7 0 1 +13140at7088 Complete M3 0 1 +13142at7088 Complete M3 0 1 +1314at7088 Complete M7 0 1 +13155at7088 Complete M18 0 1 +13157at7088 Complete M12 0 1 +13158at7088 Complete M18 0 1 +13166at7088 Complete M20 0 1 +13168at7088 Complete M2 0 1 +13169at7088 Complete M6 0 1 +13171at7088 Complete M8 0 1 +13172at7088 Complete M1 0 1 +13173at7088 Complete M10 0 1 +13174at7088 Complete M9 0 1 +1317at7088 Complete M24 0 1 +13181at7088 Complete M14 0 1 +13182at7088 Complete M2 0 1 +13184at7088 Complete M22 0 1 +13185at7088 Complete M4 0 1 +13188at7088 Complete M9 0 1 +13189at7088 Complete M6 0 1 +1318at7088 Complete M25 0 1 +13193at7088 Complete M10 0 1 +13194at7088 Complete M6 0 1 +13198at7088 Complete M3 0 1 +13199at7088 Complete M12 0 1 +1319at7088 Complete MZ 0 1 +13200at7088 Complete M6 0 1 +1320at7088 Complete M6 0 1 +13213at7088 Complete M15 0 1 +13216at7088 Complete M2 0 1 +13218at7088 Complete M9 0 1 +13220at7088 Complete M14 0 1 +13221at7088 Complete M12 0 1 +13223at7088 Complete MZ 0 1 +13224at7088 Complete M3 0 1 +13230at7088 Complete M14 0 1 +13243at7088 Complete M5 0 1 +1324at7088 Complete M8 0 1 +13250at7088 Complete M2 0 1 +13255at7088 Complete M4 0 1 +13259at7088 Complete M4 0 1 +1325at7088 Complete M9 0 1 +13263at7088 Complete M26 0 1 +13265at7088 Complete M16 0 1 +13267at7088 Complete M16 0 1 +1326at7088 Complete M3 0 1 +13278at7088 Complete M1 0 1 +13282at7088 Complete M16 0 1 +13284at7088 Complete M3 0 1 +13285at7088 Complete M16 0 1 +13289at7088 Complete M4 0 1 +13295at7088 Complete M24 0 1 +13296at7088 Complete M16 0 1 +13303at7088 Complete M15 0 1 +13305at7088 Complete M22 0 1 +13307at7088 Complete M19 0 1 +13308at7088 Complete M1 0 1 +1330at7088 Complete M14 0 1 +13310at7088 Complete M8 0 1 +13314at7088 Complete M5 0 1 +13315at7088 Complete M24 0 1 +13317at7088 Complete M18 0 1 +13319at7088 Complete M11 0 1 +13321at7088 Complete M16 0 1 +13323at7088 Complete MZ 0 1 +13326at7088 Complete M17 0 1 +13332at7088 Complete M12 0 1 +13338at7088 Complete M3 0 1 +13340at7088 Complete M7 0 1 +13341at7088 Complete M2 0 1 +13346at7088 Complete M25 0 1 +13347at7088 Complete M9 0 1 +13348at7088 Complete M23 0 1 +13351at7088 Complete M10 0 1 +13356at7088 Complete M15 0 1 +13358at7088 Complete M13 0 1 +1335at7088 Complete M23 0 1 +13365at7088 Complete M8 0 1 +13369at7088 Complete M7 0 1 +1336at7088 Complete M1 0 1 +13373at7088 Complete M22 0 1 +13375at7088 Complete MZ 0 1 +13381at7088 Complete M21 0 1 +13388at7088 Complete M12 0 1 +1338at7088 Complete M4 0 1 +13394at7088 Complete M6 0 1 +13395at7088 Complete M12 0 1 +13398at7088 Complete M2 0 1 +13399at7088 Complete M3 0 1 +133at7088 Complete M8 0 1 +13406at7088 Complete M9 0 1 +13411at7088 Complete M3 0 1 +13413at7088 Complete M12 0 1 +13414at7088 Complete M5 0 1 +13421at7088 Complete M7 0 1 +13424at7088 Complete M3 0 1 +13425at7088 Complete M19 0 1 +13435at7088 Complete M14 0 1 +13437at7088 Complete M19 0 1 +1343at7088 Complete M12 0 1 +13443at7088 Complete M9 0 1 +13445at7088 Complete M4 0 1 +13447at7088 Complete M12 0 1 +13451at7088 Complete M10 0 1 +13463at7088 Complete M21 0 1 +13464at7088 Complete M3 0 1 +13465at7088 Complete M7 0 1 +13467at7088 Complete M25 0 1 +13468at7088 Complete M2 0 1 +1346at7088 Complete MZ 0 1 +13478at7088 Complete M22 0 1 +1347at7088 Complete M8 0 1 +13481at7088 Complete M1 0 1 +13483at7088 Complete M13 0 1 +13484at7088 Complete M5 0 1 +1348at7088 Complete M3 0 1 +13495at7088 Complete M19 0 1 +13500at7088 Complete M9 0 1 +13501at7088 Complete M7 0 1 +13504at7088 Complete M15 0 1 +13506at7088 Complete M23 0 1 +1350at7088 Complete M14 0 1 +13519at7088 Complete M9 0 1 +1351at7088 Complete M22 0 1 +13527at7088 Complete M7 0 1 +13528at7088 Complete M7 0 1 +13530at7088 Complete M12 0 1 +13532at7088 Complete M2 0 1 +13533at7088 Complete M10 0 1 +13534at7088 Complete M22 0 1 +1353at7088 Complete M2 0 1 +13549at7088 Complete M13 0 1 +13554at7088 Complete M5 0 1 +13555at7088 Complete M29 0 1 +1355at7088 Complete MZ 0 1 +13561at7088 Complete M1 0 1 +13565at7088 Complete M2 0 1 +13568at7088 Complete M15 0 1 +1356at7088 Complete M14 0 1 +13582at7088 Complete M10 0 1 +13586at7088 Complete M12 0 1 +1358at7088 Complete M3 0 1 +13592at7088 Complete M20 0 1 +13596at7088 Complete M18 0 1 +13602at7088 Complete M7 0 1 +13603at7088 Complete M9 0 1 +13604at7088 Complete M1 0 1 +13607at7088 Complete M7 0 1 +13608at7088 Complete M30 0 1 +1360at7088 Complete M21 0 1 +13612at7088 Complete M6 0 1 +13617at7088 Complete M7 0 1 +13620at7088 Complete M8 0 1 +13623at7088 Complete M1 0 1 +1362at7088 Complete M2 0 1 +13634at7088 Complete M21 0 1 +13637at7088 Complete M11 0 1 +13638at7088 Complete M5 0 1 +13644at7088 Complete M21 0 1 +13651at7088 Complete M1 0 1 +13654at7088 Complete M12 0 1 +13655at7088 Complete M9 0 1 +13664at7088 Complete M25 0 1 +1366at7088 Complete M16 0 1 +13670at7088 Complete M6 0 1 +13677at7088 Complete M15 0 1 +13682at7088 Complete M3 0 1 +13687at7088 Complete M10 0 1 +1368at7088 Complete M8 0 1 +13698at7088 Complete M4 0 1 +1369at7088 Complete M18 0 1 +136at7088 Complete M1 0 1 +13703at7088 Complete M4 0 1 +13710at7088 Complete M22 0 1 +13714at7088 Complete M14 0 1 +13718at7088 Complete M9 0 1 +13724at7088 Complete M3 0 1 +1372at7088 Complete M10 0 1 +13730at7088 Complete M17 0 1 +13731at7088 Complete M4 0 1 +13733at7088 Complete M12 0 1 +13737at7088 Complete M25 0 1 +13748at7088 Complete M1 0 1 +13753at7088 Complete M24 0 1 +13755at7088 Complete M3 0 1 +13761at7088 Complete M24 0 1 +13763at7088 Complete M14 0 1 +13774at7088 Complete M22 0 1 +13775at7088 Complete M16 0 1 +13777at7088 Complete M1 0 1 +1377at7088 Complete M9 0 1 +13782at7088 Complete M2 0 1 +13787at7088 Complete M10 0 1 +13790at7088 Complete M19 0 1 +13793at7088 Complete M8 0 1 +13796at7088 Complete M3 0 1 +13798at7088 Complete M22 0 1 +137at7088 Complete M15 0 1 +13803at7088 Complete M5 0 1 +13805at7088 Complete M9 0 1 +13808at7088 Complete M22 0 1 +13809at7088 Complete M3 0 1 +1380at7088 Complete M12 0 1 +13811at7088 Complete M14 0 1 +13813at7088 Complete M19 0 1 +13815at7088 Complete M7 0 1 +13829at7088 Complete M5 0 1 +1382at7088 Complete M14 0 1 +13834at7088 Complete M4 0 1 +13858at7088 Complete M13 0 1 +13859at7088 Complete M6 0 1 +13870at7088 Complete M3 0 1 +13877at7088 Complete M17 0 1 +1388at7088 Complete M12 0 1 +13890at7088 Complete M17 0 1 +13897at7088 Complete M23 0 1 +138at7088 Complete M8 0 1 +13902at7088 Complete M2 0 1 +13904at7088 Complete M1 0 1 +13907at7088 Complete M18 0 1 +1390at7088 Complete M28 0 1 +13916at7088 Complete M11 0 1 +1391at7088 Complete M6 0 1 +1392at7088 Complete M14 0 1 +13936at7088 Complete M13 0 1 +13941at7088 Complete M12 0 1 +13943at7088 Complete M9 0 1 +13947at7088 Complete M7 0 1 +13949at7088 Complete M2 0 1 +13952at7088 Complete M19 0 1 +13955at7088 Complete M15 0 1 +1395at7088 Complete M13 0 1 +13961at7088 Complete M9 0 1 +1396at7088 Complete M6 0 1 +13972at7088 Complete M11 0 1 +13977at7088 Complete M14 0 1 +1397at7088 Complete M20 0 1 +13984at7088 Complete M5 0 1 +13986at7088 Complete M26 0 1 +13989at7088 Complete M28 0 1 +1398at7088 Complete M13 0 1 +13991at7088 Complete M12 0 1 +13994at7088 Complete M16 0 1 +13995at7088 Complete M14 0 1 +13998at7088 Complete M5 0 1 +139at7088 Complete M19 0 1 +13at7088 Complete M2 0 1 +14000at7088 Complete M2 0 1 +14009at7088 Complete M2 0 1 +14011at7088 Complete M13 0 1 +14013at7088 Complete M18 0 1 +14016at7088 Complete M7 0 1 +14018at7088 Complete M4 0 1 +1401at7088 Complete M7 0 1 +14028at7088 Complete M14 0 1 +14032at7088 Complete M19 0 1 +14037at7088 Complete M16 0 1 +1403at7088 Complete M2 0 1 +14046at7088 Complete M12 0 1 +14061at7088 Complete M13 0 1 +14069at7088 Complete M21 0 1 +14070at7088 Complete M12 0 1 +14072at7088 Complete M4 0 1 +14075at7088 Complete M7 0 1 +1407at7088 Complete M18 0 1 +14082at7088 Complete M10 0 1 +14083at7088 Complete M12 0 1 +14094at7088 Complete M16 0 1 +14098at7088 Complete M18 0 1 +140at7088 Complete M5 0 1 +14101at7088 Complete M10 0 1 +14104at7088 Complete M13 0 1 +14105at7088 Complete MZ 0 1 +14106at7088 Complete M13 0 1 +14107at7088 Complete M21 0 1 +14112at7088 Complete M10 0 1 +14119at7088 Complete M30 0 1 +1411at7088 Complete M3 0 1 +14123at7088 Complete M18 0 1 +14127at7088 Complete M17 0 1 +14130at7088 Complete M17 0 1 +14132at7088 Complete M19 0 1 +14137at7088 Complete M9 0 1 +14138at7088 Complete M9 0 1 +14139at7088 Complete M7 0 1 +1413at7088 Complete M3 0 1 +14141at7088 Complete M13 0 1 +14144at7088 Complete M20 0 1 +14147at7088 Complete M19 0 1 +14149at7088 Complete M1 0 1 +14156at7088 Complete M5 0 1 +14165at7088 Complete M1 0 1 +14167at7088 Complete M5 0 1 +14175at7088 Complete M21 0 1 +14176at7088 Complete M8 0 1 +14177at7088 Complete M29 0 1 +14179at7088 Complete M5 0 1 +1417at7088 Complete M1 0 1 +14181at7088 Complete M7 0 1 +14184at7088 Complete M9 0 1 +14186at7088 Complete M30 0 1 +1418at7088 Complete M13 0 1 +14190at7088 Complete M18 0 1 +14194at7088 Complete M15 0 1 +1419at7088 Complete M30 0 1 +14203at7088 Complete M24 0 1 +14205at7088 Complete M19 0 1 +14213at7088 Complete M9 0 1 +14214at7088 Complete M8 0 1 +14216at7088 Complete M7 0 1 +1421at7088 Complete M2 0 1 +14229at7088 Complete M29 0 1 +1422at7088 Complete M1 0 1 +14230at7088 Complete M8 0 1 +14231at7088 Complete M9 0 1 +14232at7088 Complete M14 0 1 +14239at7088 Complete M8 0 1 +14240at7088 Complete M12 0 1 +14245at7088 Complete M11 0 1 +14247at7088 Complete M21 0 1 +14249at7088 Complete M1 0 1 +14250at7088 Complete M12 0 1 +14251at7088 Complete M10 0 1 +14261at7088 Complete M12 0 1 +14265at7088 Complete M4 0 1 +14273at7088 Complete M6 0 1 +14278at7088 Complete M4 0 1 +14284at7088 Complete M15 0 1 +14287at7088 Complete M10 0 1 +14288at7088 Complete M16 0 1 +14290at7088 Complete M23 0 1 +14292at7088 Complete M17 0 1 +14294at7088 Complete M18 0 1 +14296at7088 Complete M10 0 1 +14309at7088 Complete M24 0 1 +14313at7088 Complete M17 0 1 +14314at7088 Complete M20 0 1 +14318at7088 Complete MZ 0 1 +14319at7088 Complete MZ 0 1 +1431at7088 Complete M10 0 1 +14326at7088 Complete M2 0 1 +14327at7088 Complete M6 0 1 +1432at7088 Complete M2 0 1 +14331at7088 Complete M4 0 1 +14332at7088 Complete M6 0 1 +14333at7088 Complete M20 0 1 +14334at7088 Complete M8 0 1 +14335at7088 Complete M13 0 1 +14336at7088 Complete M7 0 1 +14338at7088 Complete M2 0 1 +14339at7088 Complete M3 0 1 +14343at7088 Complete M26 0 1 +14346at7088 Complete M5 0 1 +14348at7088 Complete M17 0 1 +14349at7088 Complete M9 0 1 +14355at7088 Complete M7 0 1 +14365at7088 Complete M9 0 1 +14369at7088 Complete M8 0 1 +1436at7088 Complete M17 0 1 +14372at7088 Complete M15 0 1 +1437at7088 Complete M1 0 1 +14389at7088 Complete M3 0 1 +14391at7088 Complete M12 0 1 +14393at7088 Complete M18 0 1 +14395at7088 Complete M5 0 1 +14403at7088 Complete M7 0 1 +14404at7088 Complete M13 0 1 +14406at7088 Complete M2 0 1 +1440at7088 Complete M11 0 1 +14417at7088 Complete M10 0 1 +14418at7088 Complete M7 0 1 +1441at7088 Complete M8 0 1 +14421at7088 Complete M3 0 1 +14422at7088 Complete M11 0 1 +14424at7088 Complete M22 0 1 +1442at7088 Complete M16 0 1 +14433at7088 Complete MZ 0 1 +1443at7088 Complete M4 0 1 +14443at7088 Complete M6 0 1 +14444at7088 Complete M26 0 1 +14449at7088 Complete M30 0 1 +1444at7088 Complete M20 0 1 +14451at7088 Complete M14 0 1 +14456at7088 Complete M1 0 1 +14465at7088 Complete M26 0 1 +14467at7088 Complete M11 0 1 +14468at7088 Complete M7 0 1 +1446at7088 Complete M14 0 1 +14475at7088 Complete M8 0 1 +14495at7088 Complete M16 0 1 +14497at7088 Complete M2 0 1 +1449at7088 Complete M9 0 1 +14510at7088 Complete M12 0 1 +14511at7088 Complete M14 0 1 +14512at7088 Complete M9 0 1 +14514at7088 Complete M11 0 1 +1451at7088 Complete M1 0 1 +14521at7088 Complete M13 0 1 +14524at7088 Complete M9 0 1 +14530at7088 Complete M3 0 1 +14532at7088 Complete M12 0 1 +14536at7088 Complete M3 0 1 +1453at7088 Complete M15 0 1 +14540at7088 Complete M2 0 1 +14548at7088 Complete M1 0 1 +14549at7088 Complete M2 0 1 +14556at7088 Complete M6 0 1 +14566at7088 Complete M4 0 1 +14573at7088 Complete M1 0 1 +14577at7088 Complete M9 0 1 +14580at7088 Complete M8 0 1 +14582at7088 Complete M24 0 1 +14592at7088 Complete M2 0 1 +14593at7088 Complete M17 0 1 +14594at7088 Complete M8 0 1 +14598at7088 Complete M5 0 1 +14599at7088 Complete M11 0 1 +1459at7088 Complete M26 0 1 +145at7088 Complete M20 0 1 +14604at7088 Complete M11 0 1 +14614at7088 Complete M13 0 1 +1461at7088 Complete M16 0 1 +14621at7088 Complete M23 0 1 +14623at7088 Complete M10 0 1 +14628at7088 Complete M12 0 1 +14633at7088 Complete M1 0 1 +14636at7088 Complete M6 0 1 +1463at7088 Complete M14 0 1 +14641at7088 Complete M18 0 1 +14653at7088 Complete M23 0 1 +14655at7088 Complete M2 0 1 +1465at7088 Complete M4 0 1 +14664at7088 Complete M26 0 1 +14668at7088 Complete M14 0 1 +14675at7088 Complete M8 0 1 +14687at7088 Complete M8 0 1 +14688at7088 Complete M5 0 1 +14689at7088 Complete M5 0 1 +1468at7088 Complete M30 0 1 +14690at7088 Complete M11 0 1 +14697at7088 Complete M4 0 1 +14698at7088 Complete M14 0 1 +1469at7088 Complete M18 0 1 +14701at7088 Complete M5 0 1 +14706at7088 Complete M1 0 1 +14709at7088 Complete M13 0 1 +14711at7088 Complete M7 0 1 +14714at7088 Complete M14 0 1 +14724at7088 Complete M2 0 1 +14727at7088 Complete M2 0 1 +14729at7088 Complete M2 0 1 +1472at7088 Complete M20 0 1 +14735at7088 Complete M7 0 1 +14738at7088 Complete MZ 0 1 +14739at7088 Complete M16 0 1 +1473at7088 Complete M6 0 1 +14740at7088 Complete M12 0 1 +14749at7088 Complete M16 0 1 +14753at7088 Complete M8 0 1 +14755at7088 Complete M16 0 1 +14758at7088 Complete M4 0 1 +14762at7088 Complete M19 0 1 +1477at7088 Complete M4 0 1 +14783at7088 Complete M17 0 1 +14785at7088 Complete M22 0 1 +14798at7088 Complete M8 0 1 +1479at7088 Complete M15 0 1 +14814at7088 Complete M8 0 1 +14815at7088 Complete M6 0 1 +14829at7088 Complete M11 0 1 +14831at7088 Complete M2 0 1 +14835at7088 Complete MZ 0 1 +14836at7088 Complete M17 0 1 +14844at7088 Complete M3 0 1 +14845at7088 Complete M24 0 1 +14849at7088 Complete M5 0 1 +14850at7088 Complete M18 0 1 +14870at7088 Complete M1 0 1 +14883at7088 Complete MZ 0 1 +14886at7088 Complete M5 0 1 +14887at7088 Complete M6 0 1 +14889at7088 Complete M6 0 1 +1488at7088 Complete M6 0 1 +14894at7088 Complete M16 0 1 +14895at7088 Complete M3 0 1 +14896at7088 Complete M23 0 1 +1489at7088 Complete M7 0 1 +148at7088 Complete M12 0 1 +14909at7088 Complete MZ 0 1 +1490at7088 Complete M2 0 1 +14916at7088 Complete M1 0 1 +14918at7088 Complete M20 0 1 +14920at7088 Complete M5 0 1 +14928at7088 Complete M6 0 1 +14930at7088 Complete M11 0 1 +14938at7088 Complete M13 0 1 +14940at7088 Complete M21 0 1 +14943at7088 Complete M3 0 1 +14944at7088 Complete M17 0 1 +14948at7088 Complete M14 0 1 +14949at7088 Complete M16 0 1 +14955at7088 Complete M4 0 1 +14960at7088 Complete M4 0 1 +1496at7088 Complete M27 0 1 +14971at7088 Complete M30 0 1 +14973at7088 Complete M15 0 1 +14982at7088 Complete M9 0 1 +14986at7088 Complete M1 0 1 +14987at7088 Complete M11 0 1 +14988at7088 Complete M13 0 1 +14995at7088 Complete M26 0 1 +14998at7088 Complete M22 0 1 +15003at7088 Complete M12 0 1 +15007at7088 Complete M19 0 1 +1500at7088 Complete M5 0 1 +15010at7088 Complete M8 0 1 +15011at7088 Complete M11 0 1 +15016at7088 Complete M5 0 1 +15019at7088 Complete M13 0 1 +1501at7088 Complete M1 0 1 +15035at7088 Complete M30 0 1 +15036at7088 Complete M1 0 1 +15039at7088 Complete M7 0 1 +1503at7088 Complete M4 0 1 +15043at7088 Complete M10 0 1 +1504at7088 Complete M6 0 1 +15050at7088 Complete M12 0 1 +15055at7088 Complete M12 0 1 +1505at7088 Complete M19 0 1 +15065at7088 Complete M7 0 1 +1506at7088 Complete M11 0 1 +15078at7088 Complete M4 0 1 +1507at7088 Complete M15 0 1 +15080at7088 Complete M2 0 1 +15087at7088 Complete M22 0 1 +1508at7088 Complete M11 0 1 +15091at7088 Complete M11 0 1 +1509at7088 Complete M25 0 1 +15100at7088 Complete M19 0 1 +15107at7088 Complete M16 0 1 +15109at7088 Complete M14 0 1 +1510at7088 Complete M9 0 1 +15116at7088 Complete M4 0 1 +15117at7088 Complete MZ 0 1 +15118at7088 Complete M15 0 1 +15119at7088 Complete M3 0 1 +1511at7088 Complete M4 0 1 +15123at7088 Complete M3 0 1 +15125at7088 Complete M10 0 1 +15126at7088 Complete M16 0 1 +15136at7088 Complete MZ 0 1 +15145at7088 Complete M6 0 1 +15149at7088 Complete M12 0 1 +1514at7088 Complete M1 0 1 +15151at7088 Complete M1 0 1 +1515at7088 Complete M1 0 1 +15162at7088 Complete M13 0 1 +15172at7088 Complete M5 0 1 +15186at7088 Complete M8 0 1 +15190at7088 Complete M6 0 1 +15191at7088 Complete M16 0 1 +15192at7088 Complete M18 0 1 +15193at7088 Complete M21 0 1 +15195at7088 Complete M7 0 1 +1519at7088 Complete M18 0 1 +15205at7088 Complete M13 0 1 +15207at7088 Complete M14 0 1 +15219at7088 Complete M26 0 1 +15223at7088 Complete M6 0 1 +15225at7088 Complete M2 0 1 +15226at7088 Complete M13 0 1 +15234at7088 Complete M7 0 1 +15237at7088 Complete M12 0 1 +1523at7088 Complete M1 0 1 +15240at7088 Complete M7 0 1 +15241at7088 Complete M9 0 1 +15247at7088 Complete M5 0 1 +15248at7088 Complete M2 0 1 +1525at7088 Complete M4 0 1 +15262at7088 Complete M12 0 1 +15269at7088 Complete M17 0 1 +15270at7088 Complete M12 0 1 +15271at7088 Complete M22 0 1 +15272at7088 Complete M11 0 1 +15278at7088 Complete M29 0 1 +15284at7088 Complete M11 0 1 +15289at7088 Complete M19 0 1 +15291at7088 Complete M1 0 1 +15293at7088 Complete M26 0 1 +1530at7088 Complete M9 0 1 +15311at7088 Complete M9 0 1 +15312at7088 Complete M15 0 1 +1531at7088 Complete M6 0 1 +15320at7088 Complete M13 0 1 +15325at7088 Complete M15 0 1 +1532at7088 Complete MZ 0 1 +15337at7088 Complete M16 0 1 +15342at7088 Complete M17 0 1 +15355at7088 Complete M18 0 1 +15368at7088 Complete M1 0 1 +15379at7088 Complete M5 0 1 +1537at7088 Complete M1 0 1 +15382at7088 Complete M16 0 1 +15405at7088 Complete M19 0 1 +15435at7088 Complete M21 0 1 +15437at7088 Complete M18 0 1 +1543at7088 Complete M2 0 1 +15440at7088 Complete M10 0 1 +1544at7088 Complete M6 0 1 +15450at7088 Complete M1 0 1 +15453at7088 Complete M13 0 1 +1545at7088 Complete M28 0 1 +15461at7088 Complete M25 0 1 +15464at7088 Complete M15 0 1 +15470at7088 Complete MZ 0 1 +1547at7088 Complete M10 0 1 +15484at7088 Complete M25 0 1 +15488at7088 Complete M15 0 1 +1549at7088 Complete M23 0 1 +15500at7088 Complete M6 0 1 +15506at7088 Complete M18 0 1 +15508at7088 Complete M8 0 1 +15509at7088 Complete M4 0 1 +1550at7088 Complete M1 0 1 +15518at7088 Complete M19 0 1 +1551at7088 Complete M12 0 1 +15522at7088 Complete M1 0 1 +15525at7088 Complete M24 0 1 +15539at7088 Complete M14 0 1 +1553at7088 Complete M27 0 1 +15552at7088 Complete M6 0 1 +1555at7088 Complete M3 0 1 +15565at7088 Complete M21 0 1 +15566at7088 Complete M23 0 1 +15570at7088 Complete M2 0 1 +1557at7088 Complete M14 0 1 +15581at7088 Complete M1 0 1 +15583at7088 Complete M17 0 1 +1558at7088 Complete M8 0 1 +15593at7088 Complete M17 0 1 +155at7088 Complete M18 0 1 +15613at7088 Complete M3 0 1 +15617at7088 Complete M25 0 1 +15626at7088 Complete M3 0 1 +1562at7088 Complete M8 0 1 +15633at7088 Complete M12 0 1 +15635at7088 Complete M15 0 1 +1563at7088 Complete M4 0 1 +15648at7088 Complete M3 0 1 +1564at7088 Complete M16 0 1 +15652at7088 Complete M22 0 1 +1565at7088 Complete M8 0 1 +1566at7088 Complete M24 0 1 +15672at7088 Complete M13 0 1 +15673at7088 Complete M6 0 1 +1567at7088 Complete M17 0 1 +15680at7088 Complete M16 0 1 +1568at7088 Complete M14 0 1 +15695at7088 Complete M19 0 1 +15704at7088 Complete M24 0 1 +15705at7088 Complete M11 0 1 +15707at7088 Complete M26 0 1 +1571at7088 Complete M2 0 1 +15737at7088 Complete M9 0 1 +15738at7088 Complete M4 0 1 +1574at7088 Complete M4 0 1 +15754at7088 Complete M10 0 1 +15758at7088 Complete M29 0 1 +1575at7088 Complete M5 0 1 +1576at7088 Complete M3 0 1 +15771at7088 Complete M4 0 1 +15779at7088 Complete M24 0 1 +1577at7088 Complete M24 0 1 +15781at7088 Complete M17 0 1 +15805at7088 Complete M11 0 1 +15808at7088 Complete M28 0 1 +15816at7088 Complete M15 0 1 +15819at7088 Complete M2 0 1 +15831at7088 Complete M6 0 1 +1583at7088 Complete M6 0 1 +15853at7088 Complete M27 0 1 +15860at7088 Complete M18 0 1 +15864at7088 Complete MZ 0 1 +1586at7088 Complete M10 0 1 +1587at7088 Complete M13 0 1 +15894at7088 Complete M16 0 1 +1589at7088 Complete M26 0 1 +158at7088 Complete M11 0 1 +1590at7088 Complete M9 0 1 +1591at7088 Complete M17 0 1 +15922at7088 Complete M21 0 1 +1592at7088 Complete M15 0 1 +15939at7088 Complete M18 0 1 +15940at7088 Complete M16 0 1 +1594at7088 Complete M11 0 1 +1595at7088 Complete M4 0 1 +15966at7088 Complete M20 0 1 +1596at7088 Complete M12 0 1 +15973at7088 Complete M2 0 1 +1598at7088 Complete M2 0 1 +159at7088 Complete M14 0 1 +16009at7088 Complete M10 0 1 +1600at7088 Complete M14 0 1 +16011at7088 Complete M21 0 1 +16012at7088 Complete M14 0 1 +1601at7088 Complete M8 0 1 +16028at7088 Complete M16 0 1 +16035at7088 Complete M21 0 1 +16049at7088 Complete M22 0 1 +1605at7088 Complete M4 0 1 +16066at7088 Complete M20 0 1 +16069at7088 Complete M4 0 1 +1606at7088 Complete M20 0 1 +16071at7088 Complete M3 0 1 +1607at7088 Complete M6 0 1 +16088at7088 Complete M5 0 1 +1608at7088 Complete M17 0 1 +1609at7088 Complete M6 0 1 +160at7088 Complete M10 0 1 +16103at7088 Complete M6 0 1 +16112at7088 Complete M17 0 1 +16115at7088 Complete M7 0 1 +1612at7088 Complete M19 0 1 +1613at7088 Complete M12 0 1 +16140at7088 Complete M24 0 1 +1614at7088 Complete M9 0 1 +16159at7088 Complete M8 0 1 +16168at7088 Complete M30 0 1 +16180at7088 Complete M26 0 1 +16196at7088 Complete M17 0 1 +1619at7088 Complete M11 0 1 +1623at7088 Complete M17 0 1 +16248at7088 Complete M11 0 1 +16250at7088 Complete M18 0 1 +16252at7088 Complete M21 0 1 +1625at7088 Complete M1 0 1 +1626at7088 Complete M29 0 1 +1627at7088 Complete M12 0 1 +16282at7088 Complete M7 0 1 +1628at7088 Complete M28 0 1 +16293at7088 Complete M23 0 1 +16306at7088 Complete MZ 0 1 +16335at7088 Complete M7 0 1 +1635at7088 Complete M5 0 1 +1636at7088 Complete M4 0 1 +1637at7088 Complete M10 0 1 +1638at7088 Complete M18 0 1 +163at7088 Complete M9 0 1 +16400at7088 Complete M5 0 1 +1641at7088 Complete M11 0 1 +1642at7088 Complete M7 0 1 +1644at7088 Complete M3 0 1 +1645at7088 Complete M19 0 1 +16468at7088 Complete M2 0 1 +1647at7088 Complete M2 0 1 +1648at7088 Complete M1 0 1 +1650at7088 Complete M23 0 1 +16513at7088 Complete M16 0 1 +16527at7088 Complete M27 0 1 +1652at7088 Complete M1 0 1 +1657at7088 Complete M28 0 1 +16607at7088 Complete M24 0 1 +1660at7088 Complete M12 0 1 +1661at7088 Complete M1 0 1 +1662at7088 Complete MZ 0 1 +16641at7088 Complete M25 0 1 +16647at7088 Complete MZ 0 1 +1665at7088 Complete M1 0 1 +16663at7088 Complete M16 0 1 +16668at7088 Complete M1 0 1 +1667at7088 Complete M1 0 1 +1670at7088 Complete M3 0 1 +16739at7088 Complete M21 0 1 +1678at7088 Complete M14 0 1 +1679at7088 Complete M7 0 1 +1681at7088 Complete M7 0 1 +1682at7088 Complete M2 0 1 +1683at7088 Complete M10 0 1 +1684at7088 Complete M21 0 1 +16855at7088 Complete M10 0 1 +1685at7088 Complete M22 0 1 +1686at7088 Complete M11 0 1 +1687at7088 Complete M12 0 1 +16938at7088 Complete M30 0 1 +1693at7088 Complete M20 0 1 +1695at7088 Complete M20 0 1 +1696at7088 Complete M12 0 1 +16982at7088 Complete M10 0 1 +1699at7088 Complete M22 0 1 +1700at7088 Complete M1 0 1 +1701at7088 Complete M12 0 1 +1705at7088 Complete M19 0 1 +1707at7088 Complete M10 0 1 +1709at7088 Complete MZ 0 1 +1711at7088 Complete M23 0 1 +1718at7088 Complete M2 0 1 +1723at7088 Complete M12 0 1 +1724at7088 Complete M2 0 1 +1725at7088 Complete M22 0 1 +1728at7088 Complete M2 0 1 +1729at7088 Complete M20 0 1 +1731at7088 Complete M21 0 1 +1734at7088 Complete M3 0 1 +1735at7088 Complete M23 0 1 +1738at7088 Complete M14 0 1 +173at7088 Complete M17 0 1 +1742at7088 Complete M1 0 1 +1744at7088 Complete M5 0 1 +1745at7088 Complete M18 0 1 +1746at7088 Complete M27 0 1 +1750at7088 Complete M4 0 1 +1752at7088 Complete M8 0 1 +1753at7088 Complete M9 0 1 +1755at7088 Complete M19 0 1 +1758at7088 Complete M23 0 1 +1760at7088 Complete M26 0 1 +1761at7088 Complete M5 0 1 +1764at7088 Complete M13 0 1 +1768at7088 Complete M7 0 1 +1770at7088 Complete M12 0 1 +1772at7088 Complete M3 0 1 +1775at7088 Complete M2 0 1 +177at7088 Complete M8 0 1 +1783at7088 Complete M1 0 1 +1785at7088 Complete M3 0 1 +1787at7088 Complete M2 0 1 +1789at7088 Complete MZ 0 1 +1793at7088 Complete MZ 0 1 +179at7088 Complete M6 0 1 +1800at7088 Complete M14 0 1 +1801at7088 Complete M9 0 1 +1806at7088 Complete M6 0 1 +1809at7088 Complete M8 0 1 +1810at7088 Complete M8 0 1 +1811at7088 Complete M4 0 1 +1812at7088 Complete M5 0 1 +1819at7088 Complete M5 0 1 +1822at7088 Complete M19 0 1 +1826at7088 Complete M12 0 1 +1827at7088 Complete M8 0 1 +1828at7088 Complete M18 0 1 +1829at7088 Complete M9 0 1 +1835at7088 Complete M22 0 1 +1836at7088 Complete M15 0 1 +1837at7088 Complete M14 0 1 +183at7088 Complete M6 0 1 +1841at7088 Complete M10 0 1 +1845at7088 Complete M23 0 1 +1846at7088 Complete M5 0 1 +1847at7088 Complete M18 0 1 +184at7088 Complete M18 0 1 +1851at7088 Complete M30 0 1 +1857at7088 Complete M30 0 1 +1862at7088 Complete M17 0 1 +1865at7088 Complete M21 0 1 +1868at7088 Complete M3 0 1 +1869at7088 Complete M15 0 1 +186at7088 Complete M4 0 1 +1871at7088 Complete M3 0 1 +1872at7088 Complete M19 0 1 +1873at7088 Complete M4 0 1 +1874at7088 Complete M1 0 1 +1881at7088 Complete M3 0 1 +1882at7088 Complete M2 0 1 +1884at7088 Complete M22 0 1 +1885at7088 Complete M3 0 1 +1889at7088 Complete M3 0 1 +1890at7088 Complete M17 0 1 +1892at7088 Complete M4 0 1 +1893at7088 Complete M4 0 1 +18at7088 Complete M11 0 1 +1900at7088 Complete M22 0 1 +1901at7088 Complete M21 0 1 +1902at7088 Complete M19 0 1 +1904at7088 Complete M3 0 1 +1907at7088 Complete M23 0 1 +190at7088 Complete M27 0 1 +1910at7088 Complete M26 0 1 +1911at7088 Complete M12 0 1 +1913at7088 Complete M5 0 1 +1918at7088 Complete M7 0 1 +1922at7088 Complete M2 0 1 +1924at7088 Complete M23 0 1 +1927at7088 Complete M1 0 1 +1928at7088 Complete M14 0 1 +1929at7088 Complete M8 0 1 +1931at7088 Complete M19 0 1 +1932at7088 Complete M19 0 1 +1934at7088 Complete M9 0 1 +1935at7088 Complete M14 0 1 +1936at7088 Complete M4 0 1 +1938at7088 Complete M3 0 1 +1939at7088 Complete M11 0 1 +193at7088 Complete M5 0 1 +1940at7088 Complete M3 0 1 +1941at7088 Complete M2 0 1 +1942at7088 Complete M14 0 1 +1943at7088 Complete M27 0 1 +1945at7088 Complete M3 0 1 +1946at7088 Complete M1 0 1 +1947at7088 Complete M26 0 1 +1950at7088 Complete M3 0 1 +1951at7088 Complete M16 0 1 +1952at7088 Complete M10 0 1 +1953at7088 Complete M6 0 1 +1955at7088 Complete M5 0 1 +1956at7088 Complete M20 0 1 +1958at7088 Complete M7 0 1 +1959at7088 Complete M11 0 1 +1960at7088 Complete M13 0 1 +1962at7088 Complete M25 0 1 +1968at7088 Complete M4 0 1 +196at7088 Complete M6 0 1 +1970at7088 Complete M14 0 1 +1974at7088 Complete M18 0 1 +1982at7088 Complete M12 0 1 +1984at7088 Complete M9 0 1 +1985at7088 Complete M19 0 1 +1987at7088 Complete M18 0 1 +1990at7088 Complete M19 0 1 +1992at7088 Complete M27 0 1 +1993at7088 Complete M14 0 1 +1994at7088 Complete M28 0 1 +1999at7088 Complete M20 0 1 +1at7088 Complete MZ 0 1 +2001at7088 Complete M11 0 1 +2003at7088 Complete MZ 0 1 +200at7088 Complete M16 0 1 +2015at7088 Complete M1 0 1 +2019at7088 Complete MZ 0 1 +201at7088 Complete M13 0 1 +2021at7088 Complete MZ 0 1 +2023at7088 Complete M2 0 1 +2026at7088 Complete M26 0 1 +2028at7088 Complete MZ 0 1 +2029at7088 Complete M7 0 1 +2030at7088 Complete M8 0 1 +2031at7088 Complete M6 0 1 +2032at7088 Complete M22 0 1 +2034at7088 Complete M29 0 1 +2035at7088 Complete M9 0 1 +2036at7088 Complete M26 0 1 +2037at7088 Complete M19 0 1 +2038at7088 Complete M16 0 1 +2041at7088 Complete M9 0 1 +204at7088 Complete M2 0 1 +2051at7088 Complete M6 0 1 +2052at7088 Complete M9 0 1 +2054at7088 Complete M11 0 1 +2055at7088 Complete M21 0 1 +2056at7088 Complete M27 0 1 +2060at7088 Complete M8 0 1 +2067at7088 Complete M9 0 1 +2068at7088 Complete M2 0 1 +206at7088 Complete M3 0 1 +2072at7088 Complete M24 0 1 +2073at7088 Complete M10 0 1 +2078at7088 Complete M18 0 1 +2079at7088 Complete M3 0 1 +207at7088 Complete M8 0 1 +2081at7088 Complete M17 0 1 +2084at7088 Complete M7 0 1 +2086at7088 Complete M4 0 1 +2087at7088 Complete M12 0 1 +208at7088 Complete M2 0 1 +2090at7088 Complete M19 0 1 +2097at7088 Complete M7 0 1 +2099at7088 Complete M5 0 1 +20at7088 Complete M13 0 1 +2101at7088 Complete M20 0 1 +2103at7088 Complete M25 0 1 +2109at7088 Complete M14 0 1 +210at7088 Complete M2 0 1 +2110at7088 Complete MZ 0 1 +2118at7088 Complete M11 0 1 +211at7088 Complete M4 0 1 +2121at7088 Complete M15 0 1 +2122at7088 Complete M13 0 1 +2124at7088 Complete M2 0 1 +2126at7088 Complete M20 0 1 +212at7088 Complete MZ 0 1 +2130at7088 Complete M30 0 1 +2131at7088 Complete M27 0 1 +2133at7088 Complete M3 0 1 +2136at7088 Complete M3 0 1 +2137at7088 Complete M3 0 1 +2138at7088 Complete M1 0 1 +2139at7088 Complete M5 0 1 +2141at7088 Complete M24 0 1 +2143at7088 Complete M6 0 1 +2145at7088 Complete M10 0 1 +2149at7088 Complete M1 0 1 +2150at7088 Complete M8 0 1 +2154at7088 Complete M16 0 1 +2156at7088 Complete M13 0 1 +2158at7088 Complete M2 0 1 +215at7088 Complete M12 0 1 +2160at7088 Complete M9 0 1 +2163at7088 Complete M15 0 1 +2164at7088 Complete M1 0 1 +2166at7088 Complete M27 0 1 +2169at7088 Complete M8 0 1 +2173at7088 Complete MZ 0 1 +2174at7088 Complete M7 0 1 +2177at7088 Complete M13 0 1 +2178at7088 Complete M6 0 1 +2181at7088 Complete M25 0 1 +2182at7088 Complete M12 0 1 +2183at7088 Complete M19 0 1 +2185at7088 Complete M19 0 1 +2188at7088 Complete M2 0 1 +2190at7088 Complete M17 0 1 +2191at7088 Complete M4 0 1 +2194at7088 Complete M1 0 1 +2201at7088 Complete MZ 0 1 +2208at7088 Complete M17 0 1 +220at7088 Complete M7 0 1 +2211at7088 Complete M16 0 1 +2215at7088 Complete M24 0 1 +2220at7088 Complete M7 0 1 +2222at7088 Complete M21 0 1 +2223at7088 Complete M28 0 1 +2225at7088 Complete M30 0 1 +2227at7088 Complete M24 0 1 +2230at7088 Complete M4 0 1 +2233at7088 Complete M4 0 1 +2234at7088 Complete MZ 0 1 +2236at7088 Complete M1 0 1 +2240at7088 Complete M5 0 1 +2242at7088 Complete M15 0 1 +2243at7088 Complete M11 0 1 +2248at7088 Complete M16 0 1 +2250at7088 Complete M10 0 1 +2251at7088 Complete M14 0 1 +2255at7088 Complete M5 0 1 +2258at7088 Complete MZ 0 1 +2259at7088 Complete M2 0 1 +2261at7088 Complete M15 0 1 +2269at7088 Complete M3 0 1 +2271at7088 Complete M4 0 1 +2272at7088 Complete M4 0 1 +2273at7088 Complete MZ 0 1 +2276at7088 Complete M10 0 1 +2278at7088 Complete M4 0 1 +2279at7088 Complete M16 0 1 +2285at7088 Complete M1 0 1 +2287at7088 Complete M3 0 1 +2289at7088 Complete M13 0 1 +2290at7088 Complete M12 0 1 +2294at7088 Complete MZ 0 1 +2295at7088 Complete M12 0 1 +2301at7088 Complete M10 0 1 +2304at7088 Complete M2 0 1 +2313at7088 Complete M12 0 1 +2318at7088 Complete M5 0 1 +231at7088 Complete M16 0 1 +2321at7088 Complete MZ 0 1 +2322at7088 Complete M20 0 1 +2324at7088 Complete M9 0 1 +2325at7088 Complete M8 0 1 +2327at7088 Complete M6 0 1 +2329at7088 Complete M5 0 1 +232at7088 Complete M4 0 1 +2331at7088 Complete MZ 0 1 +2332at7088 Complete M4 0 1 +2334at7088 Complete M9 0 1 +2335at7088 Complete M19 0 1 +2338at7088 Complete M4 0 1 +2339at7088 Complete M29 0 1 +2340at7088 Complete M5 0 1 +2350at7088 Complete M20 0 1 +2351at7088 Complete M2 0 1 +2353at7088 Complete M28 0 1 +2357at7088 Complete M28 0 1 +2359at7088 Complete M1 0 1 +235at7088 Complete M1 0 1 +2362at7088 Complete MZ 0 1 +2363at7088 Complete M2 0 1 +2366at7088 Complete M1 0 1 +2367at7088 Complete M2 0 1 +236at7088 Complete M2 0 1 +2370at7088 Complete M17 0 1 +2371at7088 Complete M7 0 1 +2372at7088 Complete M19 0 1 +2378at7088 Complete M2 0 1 +2379at7088 Complete M26 0 1 +2384at7088 Complete M13 0 1 +2385at7088 Complete M22 0 1 +2386at7088 Complete M1 0 1 +2390at7088 Complete M4 0 1 +2394at7088 Complete M18 0 1 +2398at7088 Complete M11 0 1 +2403at7088 Complete M12 0 1 +2408at7088 Complete M8 0 1 +2409at7088 Complete M10 0 1 +2410at7088 Complete M9 0 1 +2411at7088 Complete M1 0 1 +2414at7088 Complete M14 0 1 +2415at7088 Complete M6 0 1 +2418at7088 Complete M8 0 1 +2420at7088 Complete M21 0 1 +2421at7088 Complete M11 0 1 +2424at7088 Complete M3 0 1 +2428at7088 Complete MZ 0 1 +242at7088 Complete M10 0 1 +2432at7088 Complete M4 0 1 +2434at7088 Complete M4 0 1 +2435at7088 Complete M16 0 1 +2440at7088 Complete M4 0 1 +2442at7088 Complete MZ 0 1 +2447at7088 Complete M13 0 1 +2448at7088 Complete MZ 0 1 +2449at7088 Complete M1 0 1 +2451at7088 Complete M16 0 1 +2452at7088 Complete M14 0 1 +2453at7088 Complete M26 0 1 +2454at7088 Complete M2 0 1 +2455at7088 Complete M4 0 1 +2456at7088 Complete M12 0 1 +2459at7088 Complete M14 0 1 +2460at7088 Complete M12 0 1 +2461at7088 Complete M14 0 1 +2465at7088 Complete M15 0 1 +2469at7088 Complete M25 0 1 +246at7088 Complete M11 0 1 +2470at7088 Complete M7 0 1 +2475at7088 Complete M15 0 1 +2481at7088 Complete M11 0 1 +2482at7088 Complete M27 0 1 +2483at7088 Complete M29 0 1 +2486at7088 Complete M7 0 1 +248at7088 Complete M20 0 1 +2490at7088 Complete M14 0 1 +2496at7088 Complete M18 0 1 +2497at7088 Complete M6 0 1 +2498at7088 Complete M20 0 1 +2501at7088 Complete M21 0 1 +2504at7088 Complete M5 0 1 +2507at7088 Complete M23 0 1 +2509at7088 Complete M11 0 1 +250at7088 Complete M16 0 1 +2510at7088 Complete MZ 0 1 +2517at7088 Complete M2 0 1 +2518at7088 Complete M19 0 1 +2519at7088 Complete MZ 0 1 +251at7088 Complete M3 0 1 +2522at7088 Complete M17 0 1 +2523at7088 Complete M23 0 1 +2527at7088 Complete M21 0 1 +2528at7088 Complete M20 0 1 +2529at7088 Complete M8 0 1 +2530at7088 Complete M4 0 1 +2535at7088 Complete M7 0 1 +2543at7088 Complete M3 0 1 +2545at7088 Complete M2 0 1 +2546at7088 Complete M18 0 1 +2547at7088 Complete M15 0 1 +2548at7088 Complete M22 0 1 +254at7088 Complete M4 0 1 +2552at7088 Complete M13 0 1 +2553at7088 Complete M3 0 1 +2554at7088 Complete M10 0 1 +2557at7088 Complete M9 0 1 +2560at7088 Complete M15 0 1 +2563at7088 Complete M25 0 1 +2566at7088 Complete M5 0 1 +2568at7088 Complete M3 0 1 +2577at7088 Complete M17 0 1 +2580at7088 Complete M2 0 1 +2583at7088 Complete M29 0 1 +2585at7088 Complete M2 0 1 +2587at7088 Complete M2 0 1 +2589at7088 Complete M9 0 1 +258at7088 Complete M28 0 1 +2594at7088 Complete M12 0 1 +2596at7088 Complete M1 0 1 +2599at7088 Complete M5 0 1 +259at7088 Complete M27 0 1 +25at7088 Complete M11 0 1 +2600at7088 Complete M3 0 1 +2603at7088 Complete M2 0 1 +2608at7088 Complete M1 0 1 +2610at7088 Complete M15 0 1 +2614at7088 Complete M10 0 1 +2615at7088 Complete M22 0 1 +2618at7088 Complete M3 0 1 +2621at7088 Complete M6 0 1 +2624at7088 Complete M9 0 1 +2629at7088 Complete M6 0 1 +2633at7088 Complete M15 0 1 +2635at7088 Complete M1 0 1 +2637at7088 Complete M8 0 1 +2639at7088 Complete MZ 0 1 +263at7088 Complete M22 0 1 +2640at7088 Complete M2 0 1 +2643at7088 Complete M3 0 1 +2645at7088 Complete M14 0 1 +2647at7088 Complete M11 0 1 +2649at7088 Complete M11 0 1 +2652at7088 Complete M2 0 1 +2653at7088 Complete M4 0 1 +2657at7088 Complete M4 0 1 +2658at7088 Complete M4 0 1 +2659at7088 Complete M7 0 1 +2662at7088 Complete M17 0 1 +2663at7088 Complete M19 0 1 +2666at7088 Complete M13 0 1 +2668at7088 Complete M11 0 1 +266at7088 Complete MZ 0 1 +2671at7088 Complete M27 0 1 +2672at7088 Complete M29 0 1 +2679at7088 Complete M1 0 1 +2686at7088 Complete M18 0 1 +2687at7088 Complete M20 0 1 +2690at7088 Complete M9 0 1 +2694at7088 Complete M6 0 1 +2696at7088 Complete MZ 0 1 +2699at7088 Complete M3 0 1 +26at7088 Complete M1 0 1 +2700at7088 Complete M21 0 1 +2701at7088 Complete M14 0 1 +2703at7088 Complete M12 0 1 +2704at7088 Complete M17 0 1 +270at7088 Complete MZ 0 1 +2710at7088 Complete M7 0 1 +2714at7088 Complete M22 0 1 +2715at7088 Complete M2 0 1 +2718at7088 Complete M3 0 1 +2719at7088 Complete M4 0 1 +271at7088 Complete M5 0 1 +2721at7088 Complete M19 0 1 +2729at7088 Complete M4 0 1 +2730at7088 Complete M6 0 1 +2731at7088 Complete M7 0 1 +2733at7088 Complete M4 0 1 +2734at7088 Complete M14 0 1 +2738at7088 Complete M19 0 1 +273at7088 Complete M18 0 1 +2740at7088 Complete M15 0 1 +2743at7088 Complete M6 0 1 +2744at7088 Complete M1 0 1 +2746at7088 Complete M24 0 1 +2747at7088 Complete M5 0 1 +274at7088 Complete M7 0 1 +2750at7088 Complete M6 0 1 +2754at7088 Complete M21 0 1 +2756at7088 Complete M3 0 1 +2758at7088 Complete M3 0 1 +2761at7088 Complete M13 0 1 +2762at7088 Complete M17 0 1 +2766at7088 Complete M28 0 1 +2768at7088 Complete M20 0 1 +2770at7088 Complete M22 0 1 +2772at7088 Complete M13 0 1 +2774at7088 Complete M8 0 1 +2775at7088 Complete M3 0 1 +2787at7088 Complete M12 0 1 +2788at7088 Complete M19 0 1 +278at7088 Complete M1 0 1 +2791at7088 Complete M19 0 1 +2796at7088 Complete M6 0 1 +2797at7088 Complete M5 0 1 +2798at7088 Complete M6 0 1 +27at7088 Complete MZ 0 1 +2802at7088 Complete M4 0 1 +2803at7088 Complete M3 0 1 +2804at7088 Complete M22 0 1 +2805at7088 Complete M1 0 1 +2811at7088 Complete M4 0 1 +2813at7088 Complete M21 0 1 +2815at7088 Complete M4 0 1 +2816at7088 Complete M10 0 1 +2818at7088 Complete M20 0 1 +2819at7088 Complete M22 0 1 +281at7088 Complete M4 0 1 +2821at7088 Complete M7 0 1 +2826at7088 Complete M16 0 1 +2829at7088 Complete M16 0 1 +2830at7088 Complete M6 0 1 +2833at7088 Complete M3 0 1 +2834at7088 Complete M13 0 1 +2835at7088 Complete M5 0 1 +2842at7088 Complete M19 0 1 +2845at7088 Complete M18 0 1 +2848at7088 Complete M2 0 1 +2855at7088 Complete M23 0 1 +2857at7088 Complete M1 0 1 +2859at7088 Complete M4 0 1 +2860at7088 Complete M10 0 1 +2864at7088 Complete M7 0 1 +2873at7088 Complete M16 0 1 +2877at7088 Complete M27 0 1 +2884at7088 Complete M10 0 1 +2885at7088 Complete M11 0 1 +288at7088 Complete M26 0 1 +2890at7088 Complete M18 0 1 +2891at7088 Complete M2 0 1 +2893at7088 Complete M7 0 1 +2895at7088 Complete M2 0 1 +28at7088 Complete M1 0 1 +2902at7088 Complete MZ 0 1 +2905at7088 Complete MZ 0 1 +2906at7088 Complete M22 0 1 +2910at7088 Complete M5 0 1 +2912at7088 Complete M2 0 1 +2913at7088 Complete M16 0 1 +2917at7088 Complete M2 0 1 +2918at7088 Complete M8 0 1 +2926at7088 Complete M1 0 1 +2928at7088 Complete M9 0 1 +2930at7088 Complete M15 0 1 +2931at7088 Complete M3 0 1 +2932at7088 Complete M17 0 1 +2934at7088 Complete M18 0 1 +2935at7088 Complete M2 0 1 +2936at7088 Complete M11 0 1 +2938at7088 Complete MZ 0 1 +2939at7088 Complete M21 0 1 +2940at7088 Complete M15 0 1 +2942at7088 Complete MZ 0 1 +2943at7088 Complete M13 0 1 +2945at7088 Complete M15 0 1 +2948at7088 Complete M5 0 1 +2949at7088 Complete M2 0 1 +2952at7088 Complete M14 0 1 +2953at7088 Complete M3 0 1 +2959at7088 Complete M21 0 1 +2965at7088 Complete M6 0 1 +2966at7088 Complete M9 0 1 +296at7088 Complete MZ 0 1 +2972at7088 Complete M2 0 1 +2976at7088 Complete M7 0 1 +2978at7088 Complete M16 0 1 +2979at7088 Complete M2 0 1 +2980at7088 Complete M19 0 1 +2981at7088 Complete M2 0 1 +2982at7088 Complete M13 0 1 +2984at7088 Complete M3 0 1 +2987at7088 Complete M6 0 1 +2990at7088 Complete M12 0 1 +2991at7088 Complete M2 0 1 +2994at7088 Complete M7 0 1 +2995at7088 Complete M15 0 1 +2998at7088 Complete M7 0 1 +2999at7088 Complete M8 0 1 +2at7088 Complete M4 0 1 +3000at7088 Complete M21 0 1 +3003at7088 Complete MZ 0 1 +3004at7088 Complete M16 0 1 +3005at7088 Complete M1 0 1 +3006at7088 Complete M18 0 1 +3010at7088 Complete M17 0 1 +3012at7088 Complete M6 0 1 +3016at7088 Complete M20 0 1 +3018at7088 Complete MZ 0 1 +3021at7088 Complete M1 0 1 +3023at7088 Complete M11 0 1 +3025at7088 Complete M7 0 1 +3026at7088 Complete M7 0 1 +3027at7088 Complete M24 0 1 +3029at7088 Complete M2 0 1 +302at7088 Complete M27 0 1 +3030at7088 Complete M14 0 1 +3032at7088 Complete M15 0 1 +303at7088 Complete M1 0 1 +3040at7088 Complete M1 0 1 +3042at7088 Complete M7 0 1 +3045at7088 Complete M6 0 1 +3047at7088 Complete M13 0 1 +3048at7088 Complete M18 0 1 +3051at7088 Complete M16 0 1 +3053at7088 Complete M26 0 1 +3055at7088 Complete M2 0 1 +3057at7088 Complete M8 0 1 +3059at7088 Complete M12 0 1 +3065at7088 Complete M27 0 1 +3066at7088 Complete M7 0 1 +3067at7088 Complete M4 0 1 +3069at7088 Complete M30 0 1 +3071at7088 Complete M1 0 1 +3074at7088 Complete M7 0 1 +3075at7088 Complete M13 0 1 +3078at7088 Complete M1 0 1 +3079at7088 Complete M1 0 1 +307at7088 Complete M18 0 1 +3080at7088 Complete M8 0 1 +3084at7088 Complete M1 0 1 +3086at7088 Complete M18 0 1 +3093at7088 Complete M18 0 1 +3094at7088 Complete M4 0 1 +3104at7088 Complete M26 0 1 +3105at7088 Complete M17 0 1 +3107at7088 Complete M19 0 1 +3110at7088 Complete M6 0 1 +3114at7088 Complete M7 0 1 +3115at7088 Complete MZ 0 1 +3118at7088 Complete M1 0 1 +311at7088 Complete M19 0 1 +3122at7088 Complete M12 0 1 +3123at7088 Complete M13 0 1 +3125at7088 Complete M15 0 1 +3126at7088 Complete M12 0 1 +3127at7088 Complete M5 0 1 +3128at7088 Complete M5 0 1 +3129at7088 Complete M5 0 1 +3131at7088 Complete M10 0 1 +3132at7088 Complete M14 0 1 +3133at7088 Complete M18 0 1 +3135at7088 Complete M12 0 1 +3137at7088 Complete M11 0 1 +3144at7088 Complete M10 0 1 +3145at7088 Complete M13 0 1 +3152at7088 Complete M2 0 1 +3153at7088 Complete M5 0 1 +3155at7088 Complete M5 0 1 +3159at7088 Complete M7 0 1 +315at7088 Complete M15 0 1 +3160at7088 Complete M18 0 1 +3161at7088 Complete M7 0 1 +3162at7088 Complete MZ 0 1 +3163at7088 Complete M2 0 1 +3165at7088 Complete MZ 0 1 +3166at7088 Complete M8 0 1 +3167at7088 Complete M6 0 1 +316at7088 Complete M9 0 1 +3174at7088 Complete M20 0 1 +3175at7088 Complete M3 0 1 +3178at7088 Complete M11 0 1 +3180at7088 Complete M11 0 1 +3183at7088 Complete M1 0 1 +3186at7088 Complete M5 0 1 +3187at7088 Complete M17 0 1 +3188at7088 Complete M14 0 1 +318at7088 Complete M6 0 1 +3195at7088 Complete M3 0 1 +3197at7088 Complete M3 0 1 +3198at7088 Complete M8 0 1 +31at7088 Complete M27 0 1 +3200at7088 Complete M17 0 1 +3204at7088 Complete M21 0 1 +3207at7088 Complete M4 0 1 +3209at7088 Complete M16 0 1 +3211at7088 Complete M14 0 1 +3212at7088 Complete M9 0 1 +3216at7088 Complete M21 0 1 +3218at7088 Complete M1 0 1 +3219at7088 Complete M6 0 1 +321at7088 Complete MZ 0 1 +3220at7088 Complete M22 0 1 +3221at7088 Complete M5 0 1 +3224at7088 Complete M12 0 1 +3225at7088 Complete M14 0 1 +3226at7088 Complete M4 0 1 +3228at7088 Complete M20 0 1 +322at7088 Complete M18 0 1 +3231at7088 Complete M21 0 1 +3234at7088 Complete M17 0 1 +3237at7088 Complete MZ 0 1 +3241at7088 Complete M1 0 1 +3242at7088 Complete M11 0 1 +3245at7088 Complete MZ 0 1 +3248at7088 Complete M13 0 1 +324at7088 Complete M2 0 1 +3250at7088 Complete M10 0 1 +3251at7088 Complete M6 0 1 +3253at7088 Complete M14 0 1 +3254at7088 Complete M8 0 1 +3255at7088 Complete M10 0 1 +3257at7088 Complete M12 0 1 +3258at7088 Complete M19 0 1 +3259at7088 Complete M18 0 1 +325at7088 Complete M5 0 1 +3265at7088 Complete M4 0 1 +3269at7088 Complete M1 0 1 +326at7088 Complete M1 0 1 +3272at7088 Complete M12 0 1 +3273at7088 Complete M1 0 1 +3275at7088 Complete M1 0 1 +3276at7088 Complete M12 0 1 +3277at7088 Complete M2 0 1 +3278at7088 Complete M3 0 1 +3279at7088 Complete MZ 0 1 +327at7088 Complete M8 0 1 +3284at7088 Complete M11 0 1 +3287at7088 Complete M9 0 1 +328at7088 Complete M12 0 1 +3290at7088 Complete M9 0 1 +3293at7088 Complete M4 0 1 +3297at7088 Complete M11 0 1 +3298at7088 Complete M4 0 1 +3306at7088 Complete M6 0 1 +3307at7088 Complete M15 0 1 +3312at7088 Complete M14 0 1 +3313at7088 Complete M11 0 1 +3314at7088 Complete M21 0 1 +3315at7088 Complete M14 0 1 +3323at7088 Complete M17 0 1 +3324at7088 Complete M16 0 1 +3326at7088 Complete M2 0 1 +3327at7088 Complete M7 0 1 +332at7088 Complete M2 0 1 +3330at7088 Complete M18 0 1 +3331at7088 Complete M21 0 1 +3332at7088 Complete M11 0 1 +3338at7088 Complete M9 0 1 +3339at7088 Complete M3 0 1 +3343at7088 Complete M2 0 1 +3345at7088 Complete M20 0 1 +3348at7088 Complete M13 0 1 +3351at7088 Complete M17 0 1 +3352at7088 Complete M24 0 1 +3353at7088 Complete M23 0 1 +3356at7088 Complete M8 0 1 +3358at7088 Complete M21 0 1 +3359at7088 Complete M16 0 1 +335at7088 Complete M28 0 1 +3361at7088 Complete M7 0 1 +3362at7088 Complete M22 0 1 +3363at7088 Complete M21 0 1 +3364at7088 Complete M21 0 1 +3365at7088 Complete M14 0 1 +3366at7088 Complete M8 0 1 +3368at7088 Complete M15 0 1 +3372at7088 Complete M23 0 1 +3373at7088 Complete M8 0 1 +3379at7088 Complete M6 0 1 +3381at7088 Complete M10 0 1 +3383at7088 Complete M30 0 1 +3384at7088 Complete MZ 0 1 +3387at7088 Complete M2 0 1 +3388at7088 Complete M6 0 1 +3389at7088 Complete M9 0 1 +338at7088 Complete M8 0 1 +3390at7088 Complete M5 0 1 +3393at7088 Complete M1 0 1 +3396at7088 Complete M2 0 1 +33at7088 Complete M1 0 1 +3400at7088 Complete M9 0 1 +3401at7088 Complete M5 0 1 +3402at7088 Complete M5 0 1 +3404at7088 Complete M4 0 1 +3409at7088 Complete M21 0 1 +340at7088 Complete M19 0 1 +3410at7088 Complete M18 0 1 +3415at7088 Complete M10 0 1 +3416at7088 Complete M26 0 1 +3417at7088 Complete M3 0 1 +3419at7088 Complete M2 0 1 +3424at7088 Complete M6 0 1 +342at7088 Complete M10 0 1 +3430at7088 Complete M5 0 1 +3431at7088 Complete M1 0 1 +3433at7088 Complete M3 0 1 +3435at7088 Complete M12 0 1 +3442at7088 Complete M7 0 1 +3443at7088 Complete M26 0 1 +3447at7088 Complete MZ 0 1 +3451at7088 Complete M9 0 1 +3453at7088 Complete M13 0 1 +345at7088 Complete M24 0 1 +3460at7088 Complete M4 0 1 +3468at7088 Complete M18 0 1 +3471at7088 Complete M10 0 1 +3473at7088 Complete M8 0 1 +3474at7088 Complete M14 0 1 +3477at7088 Complete M19 0 1 +3478at7088 Complete MZ 0 1 +3479at7088 Complete M5 0 1 +3480at7088 Complete M1 0 1 +3485at7088 Complete M9 0 1 +3486at7088 Complete M8 0 1 +3489at7088 Complete M1 0 1 +3491at7088 Complete M14 0 1 +3493at7088 Complete M10 0 1 +3494at7088 Complete M13 0 1 +3496at7088 Complete M6 0 1 +3497at7088 Complete M21 0 1 +34at7088 Complete M1 0 1 +3503at7088 Complete M16 0 1 +3504at7088 Complete M3 0 1 +3507at7088 Complete M19 0 1 +3508at7088 Complete M9 0 1 +350at7088 Complete M4 0 1 +3510at7088 Complete M3 0 1 +3514at7088 Complete M11 0 1 +3516at7088 Complete M17 0 1 +3517at7088 Complete M6 0 1 +3519at7088 Complete M12 0 1 +3520at7088 Complete M15 0 1 +3521at7088 Complete M14 0 1 +3524at7088 Complete M13 0 1 +3526at7088 Complete M14 0 1 +3528at7088 Complete M11 0 1 +3529at7088 Complete M5 0 1 +3537at7088 Complete M7 0 1 +3539at7088 Complete M2 0 1 +353at7088 Complete M27 0 1 +3541at7088 Complete M4 0 1 +3542at7088 Complete M18 0 1 +3548at7088 Complete M3 0 1 +3549at7088 Complete M25 0 1 +354at7088 Complete M15 0 1 +3551at7088 Complete M9 0 1 +3556at7088 Complete M19 0 1 +3558at7088 Complete M1 0 1 +355at7088 Complete M15 0 1 +3563at7088 Complete M9 0 1 +3564at7088 Complete M6 0 1 +3567at7088 Complete M5 0 1 +356at7088 Complete M18 0 1 +3571at7088 Complete M6 0 1 +3577at7088 Complete M20 0 1 +357at7088 Complete M22 0 1 +3580at7088 Complete M10 0 1 +3584at7088 Complete MZ 0 1 +3587at7088 Complete M5 0 1 +3589at7088 Complete M19 0 1 +3592at7088 Complete M15 0 1 +3594at7088 Complete M4 0 1 +3595at7088 Complete M3 0 1 +3596at7088 Complete M7 0 1 +3597at7088 Complete M9 0 1 +3598at7088 Complete M6 0 1 +3599at7088 Complete M20 0 1 +3600at7088 Complete M5 0 1 +3602at7088 Complete M9 0 1 +3604at7088 Complete M2 0 1 +3607at7088 Complete M24 0 1 +3608at7088 Complete M28 0 1 +360at7088 Complete MZ 0 1 +3611at7088 Complete M25 0 1 +3616at7088 Complete M21 0 1 +3618at7088 Complete M20 0 1 +3631at7088 Complete M1 0 1 +3633at7088 Complete M4 0 1 +3634at7088 Complete M3 0 1 +363at7088 Complete M16 0 1 +3641at7088 Complete M2 0 1 +3648at7088 Complete M1 0 1 +3653at7088 Complete M19 0 1 +3656at7088 Complete MZ 0 1 +3658at7088 Complete M5 0 1 +3659at7088 Complete M3 0 1 +3660at7088 Complete M8 0 1 +3662at7088 Complete M8 0 1 +3663at7088 Complete M19 0 1 +3664at7088 Complete M4 0 1 +3665at7088 Complete M1 0 1 +3666at7088 Complete M2 0 1 +3667at7088 Complete M2 0 1 +3668at7088 Complete MZ 0 1 +366at7088 Complete M5 0 1 +3671at7088 Complete M4 0 1 +3672at7088 Complete M4 0 1 +3673at7088 Complete M15 0 1 +3675at7088 Complete M2 0 1 +3678at7088 Complete M15 0 1 +367at7088 Complete M13 0 1 +3680at7088 Complete M1 0 1 +3681at7088 Complete M28 0 1 +3683at7088 Complete M29 0 1 +3684at7088 Complete M3 0 1 +3686at7088 Complete MZ 0 1 +3689at7088 Complete M4 0 1 +3695at7088 Complete M17 0 1 +36at7088 Complete M16 0 1 +3709at7088 Complete M3 0 1 +3718at7088 Complete M19 0 1 +3722at7088 Complete M27 0 1 +3725at7088 Complete M8 0 1 +3726at7088 Complete M5 0 1 +3727at7088 Complete M5 0 1 +3730at7088 Complete M30 0 1 +3735at7088 Complete M9 0 1 +3742at7088 Complete M1 0 1 +3743at7088 Complete M2 0 1 +3745at7088 Complete M13 0 1 +3749at7088 Complete M5 0 1 +3753at7088 Complete M17 0 1 +3756at7088 Complete M20 0 1 +375at7088 Complete M15 0 1 +3760at7088 Complete M1 0 1 +3767at7088 Complete M14 0 1 +3773at7088 Complete M11 0 1 +3774at7088 Complete M24 0 1 +3775at7088 Complete M7 0 1 +3779at7088 Complete M5 0 1 +3780at7088 Complete M21 0 1 +3785at7088 Complete M4 0 1 +3791at7088 Complete M7 0 1 +3793at7088 Complete M18 0 1 +3794at7088 Complete M11 0 1 +3795at7088 Complete MZ 0 1 +3799at7088 Complete M3 0 1 +37at7088 Complete MZ 0 1 +3800at7088 Complete MZ 0 1 +3802at7088 Complete M13 0 1 +3804at7088 Complete M9 0 1 +3807at7088 Complete M12 0 1 +380at7088 Complete M7 0 1 +3811at7088 Complete MZ 0 1 +3817at7088 Complete M16 0 1 +3818at7088 Complete M29 0 1 +3821at7088 Complete M1 0 1 +3823at7088 Complete M19 0 1 +3825at7088 Complete M1 0 1 +3827at7088 Complete M20 0 1 +3829at7088 Complete M7 0 1 +382at7088 Complete M12 0 1 +3830at7088 Complete M8 0 1 +3833at7088 Complete M12 0 1 +3834at7088 Complete M4 0 1 +3839at7088 Complete M18 0 1 +383at7088 Complete M4 0 1 +3840at7088 Complete M24 0 1 +3842at7088 Complete M9 0 1 +3845at7088 Complete M7 0 1 +384at7088 Complete M2 0 1 +3853at7088 Complete M17 0 1 +3855at7088 Complete M17 0 1 +3859at7088 Complete M2 0 1 +385at7088 Complete M14 0 1 +3860at7088 Complete M11 0 1 +3864at7088 Complete M14 0 1 +3865at7088 Complete M22 0 1 +3866at7088 Complete M29 0 1 +3869at7088 Complete M4 0 1 +386at7088 Complete M5 0 1 +3870at7088 Complete M2 0 1 +3872at7088 Complete M20 0 1 +3873at7088 Complete M9 0 1 +3874at7088 Complete M13 0 1 +3876at7088 Complete M4 0 1 +3879at7088 Complete M1 0 1 +3882at7088 Complete M6 0 1 +3885at7088 Complete M3 0 1 +3887at7088 Complete M2 0 1 +3888at7088 Complete M9 0 1 +3889at7088 Complete M1 0 1 +3890at7088 Complete M16 0 1 +3898at7088 Complete M12 0 1 +3899at7088 Complete M3 0 1 +389at7088 Complete MZ 0 1 +38at7088 Complete M27 0 1 +3904at7088 Complete M14 0 1 +3905at7088 Complete M21 0 1 +3908at7088 Complete M3 0 1 +3911at7088 Complete M5 0 1 +3912at7088 Complete M6 0 1 +3915at7088 Complete M5 0 1 +3916at7088 Complete M15 0 1 +3919at7088 Complete M12 0 1 +391at7088 Complete MZ 0 1 +3921at7088 Complete M2 0 1 +3923at7088 Complete M14 0 1 +3924at7088 Complete M7 0 1 +3925at7088 Complete M10 0 1 +3926at7088 Complete M29 0 1 +3929at7088 Complete M12 0 1 +392at7088 Complete M3 0 1 +3931at7088 Complete M1 0 1 +3938at7088 Complete M4 0 1 +3939at7088 Complete M8 0 1 +393at7088 Complete M20 0 1 +3946at7088 Complete M24 0 1 +3947at7088 Complete M21 0 1 +3949at7088 Complete M17 0 1 +394at7088 Complete M18 0 1 +3955at7088 Complete M20 0 1 +3956at7088 Complete M12 0 1 +3963at7088 Complete M2 0 1 +3964at7088 Complete M15 0 1 +3966at7088 Complete M4 0 1 +3969at7088 Complete M4 0 1 +396at7088 Complete M6 0 1 +3973at7088 Complete M15 0 1 +3975at7088 Complete M7 0 1 +3982at7088 Complete M7 0 1 +3985at7088 Complete MZ 0 1 +3989at7088 Complete M24 0 1 +3990at7088 Complete M3 0 1 +3994at7088 Complete M20 0 1 +3997at7088 Complete M4 0 1 +3998at7088 Complete M10 0 1 +3at7088 Complete M6 0 1 +4002at7088 Complete M1 0 1 +4008at7088 Complete M15 0 1 +4009at7088 Complete M1 0 1 +4010at7088 Complete M2 0 1 +4011at7088 Complete M22 0 1 +4013at7088 Complete M7 0 1 +4017at7088 Complete MZ 0 1 +401at7088 Complete M6 0 1 +4020at7088 Complete M19 0 1 +4021at7088 Complete M20 0 1 +4024at7088 Complete M12 0 1 +4025at7088 Complete M11 0 1 +4027at7088 Complete M21 0 1 +4029at7088 Complete M22 0 1 +4030at7088 Complete M20 0 1 +4031at7088 Complete M4 0 1 +4032at7088 Complete M19 0 1 +4036at7088 Complete M5 0 1 +4037at7088 Complete M9 0 1 +4041at7088 Complete M1 0 1 +4043at7088 Complete M15 0 1 +4046at7088 Complete M11 0 1 +4052at7088 Complete M13 0 1 +4059at7088 Complete M9 0 1 +4063at7088 Complete M27 0 1 +4064at7088 Complete M13 0 1 +4066at7088 Complete M7 0 1 +4067at7088 Complete M3 0 1 +4068at7088 Complete M4 0 1 +4069at7088 Complete M13 0 1 +4070at7088 Complete M10 0 1 +4073at7088 Complete M1 0 1 +4077at7088 Complete M15 0 1 +4078at7088 Complete MZ 0 1 +4079at7088 Complete M3 0 1 +4081at7088 Complete M11 0 1 +4085at7088 Complete M3 0 1 +4089at7088 Complete MZ 0 1 +408at7088 Complete M1 0 1 +4090at7088 Complete M5 0 1 +4092at7088 Complete M18 0 1 +4093at7088 Complete MZ 0 1 +4100at7088 Complete M8 0 1 +4108at7088 Complete M11 0 1 +4109at7088 Complete M7 0 1 +4110at7088 Complete M17 0 1 +4114at7088 Complete M22 0 1 +4118at7088 Complete M13 0 1 +4119at7088 Complete MZ 0 1 +4121at7088 Complete M26 0 1 +4123at7088 Complete M8 0 1 +412at7088 Complete M4 0 1 +4130at7088 Complete M4 0 1 +4131at7088 Complete M1 0 1 +4132at7088 Complete M19 0 1 +4141at7088 Complete M6 0 1 +4142at7088 Complete M22 0 1 +4144at7088 Complete M23 0 1 +4147at7088 Complete M19 0 1 +4150at7088 Complete M5 0 1 +4153at7088 Complete M1 0 1 +4162at7088 Complete M29 0 1 +4163at7088 Complete M26 0 1 +4165at7088 Complete MZ 0 1 +4167at7088 Complete MZ 0 1 +4172at7088 Complete M4 0 1 +4173at7088 Complete M11 0 1 +4174at7088 Complete M21 0 1 +4175at7088 Complete M15 0 1 +4176at7088 Complete MZ 0 1 +4178at7088 Complete M2 0 1 +417at7088 Complete M14 0 1 +4180at7088 Complete M24 0 1 +4181at7088 Complete M3 0 1 +4182at7088 Complete M20 0 1 +4185at7088 Complete M3 0 1 +4189at7088 Complete M5 0 1 +4190at7088 Complete M9 0 1 +4197at7088 Complete M22 0 1 +4198at7088 Complete M16 0 1 +4199at7088 Complete M11 0 1 +41at7088 Complete M6 0 1 +4200at7088 Complete M10 0 1 +4202at7088 Complete M8 0 1 +4204at7088 Complete M3 0 1 +4208at7088 Complete M5 0 1 +420at7088 Complete M16 0 1 +4212at7088 Complete M7 0 1 +4214at7088 Complete M22 0 1 +4219at7088 Complete M9 0 1 +4223at7088 Complete M10 0 1 +4226at7088 Complete MZ 0 1 +4227at7088 Complete M6 0 1 +4229at7088 Complete M19 0 1 +4235at7088 Complete M5 0 1 +4237at7088 Complete M5 0 1 +4238at7088 Complete M12 0 1 +4241at7088 Complete M14 0 1 +4242at7088 Complete M23 0 1 +4243at7088 Complete M1 0 1 +4244at7088 Complete M6 0 1 +4247at7088 Complete M7 0 1 +4251at7088 Complete M17 0 1 +4253at7088 Complete M19 0 1 +4256at7088 Complete M23 0 1 +4260at7088 Complete M18 0 1 +4263at7088 Complete M2 0 1 +4264at7088 Complete M22 0 1 +4266at7088 Complete M22 0 1 +4267at7088 Complete M9 0 1 +4268at7088 Complete M8 0 1 +4269at7088 Complete M3 0 1 +4270at7088 Complete M25 0 1 +4271at7088 Complete M3 0 1 +4272at7088 Complete M10 0 1 +4275at7088 Complete MZ 0 1 +4279at7088 Complete M30 0 1 +427at7088 Complete M28 0 1 +4286at7088 Complete M18 0 1 +4287at7088 Complete M7 0 1 +4288at7088 Complete M16 0 1 +4297at7088 Complete M7 0 1 +4298at7088 Complete M24 0 1 +429at7088 Complete M15 0 1 +4300at7088 Complete M1 0 1 +4301at7088 Complete M9 0 1 +4304at7088 Complete M9 0 1 +4305at7088 Complete M5 0 1 +4306at7088 Complete M6 0 1 +4307at7088 Complete MZ 0 1 +4308at7088 Complete M8 0 1 +430at7088 Complete M18 0 1 +4315at7088 Complete M17 0 1 +4317at7088 Complete M15 0 1 +4318at7088 Complete M3 0 1 +4320at7088 Complete M1 0 1 +4322at7088 Complete M9 0 1 +4323at7088 Complete M23 0 1 +4325at7088 Complete M5 0 1 +4331at7088 Complete M5 0 1 +4333at7088 Complete MZ 0 1 +4335at7088 Complete M2 0 1 +4346at7088 Complete M29 0 1 +4348at7088 Complete M16 0 1 +434at7088 Complete M3 0 1 +4350at7088 Complete M18 0 1 +4352at7088 Complete M1 0 1 +4354at7088 Complete M7 0 1 +4360at7088 Complete M1 0 1 +4362at7088 Complete M9 0 1 +4364at7088 Complete M25 0 1 +4368at7088 Complete M1 0 1 +4369at7088 Complete M5 0 1 +4370at7088 Complete M1 0 1 +4371at7088 Complete M4 0 1 +4377at7088 Complete M12 0 1 +4379at7088 Complete M8 0 1 +437at7088 Complete M21 0 1 +4383at7088 Complete M4 0 1 +4392at7088 Complete M2 0 1 +4398at7088 Complete M1 0 1 +43at7088 Complete M13 0 1 +4400at7088 Complete M17 0 1 +4401at7088 Complete M28 0 1 +4402at7088 Complete M21 0 1 +4403at7088 Complete M18 0 1 +4405at7088 Complete M3 0 1 +4406at7088 Complete M2 0 1 +4412at7088 Complete M1 0 1 +4414at7088 Complete MZ 0 1 +4415at7088 Complete M5 0 1 +4416at7088 Complete M3 0 1 +4417at7088 Complete M5 0 1 +4418at7088 Complete M17 0 1 +4420at7088 Complete M7 0 1 +4422at7088 Complete M3 0 1 +4423at7088 Complete M11 0 1 +4425at7088 Complete M21 0 1 +4427at7088 Complete M17 0 1 +4434at7088 Complete M8 0 1 +4439at7088 Complete M7 0 1 +443at7088 Complete M6 0 1 +4440at7088 Complete M12 0 1 +4443at7088 Complete M14 0 1 +4449at7088 Complete MZ 0 1 +4451at7088 Complete M5 0 1 +4454at7088 Complete M19 0 1 +4455at7088 Complete M11 0 1 +4457at7088 Complete M1 0 1 +445at7088 Complete M13 0 1 +4462at7088 Complete M16 0 1 +4469at7088 Complete M10 0 1 +4471at7088 Complete M2 0 1 +4473at7088 Complete MZ 0 1 +4477at7088 Complete M1 0 1 +4479at7088 Complete M14 0 1 +4480at7088 Complete M20 0 1 +4481at7088 Complete M6 0 1 +4483at7088 Complete M3 0 1 +4485at7088 Complete M28 0 1 +4486at7088 Complete M27 0 1 +4487at7088 Complete M9 0 1 +4492at7088 Complete M11 0 1 +4493at7088 Complete M2 0 1 +4497at7088 Complete M3 0 1 +4499at7088 Complete M6 0 1 +4500at7088 Complete M21 0 1 +4502at7088 Complete M8 0 1 +4504at7088 Complete M29 0 1 +450at7088 Complete M3 0 1 +4524at7088 Complete M10 0 1 +4527at7088 Complete M1 0 1 +4528at7088 Complete M21 0 1 +4533at7088 Complete MZ 0 1 +4539at7088 Complete M17 0 1 +4541at7088 Complete M10 0 1 +4545at7088 Complete M20 0 1 +4546at7088 Complete M10 0 1 +4549at7088 Complete M26 0 1 +4554at7088 Complete M8 0 1 +4555at7088 Complete M6 0 1 +4557at7088 Complete M1 0 1 +455at7088 Complete M1 0 1 +4560at7088 Complete M9 0 1 +456at7088 Complete M15 0 1 +4576at7088 Complete M16 0 1 +4579at7088 Complete M8 0 1 +458at7088 Complete M17 0 1 +4595at7088 Complete M24 0 1 +4597at7088 Complete M21 0 1 +4602at7088 Complete M7 0 1 +4605at7088 Complete M4 0 1 +4608at7088 Complete M8 0 1 +4609at7088 Complete M17 0 1 +4610at7088 Complete M20 0 1 +4616at7088 Complete MZ 0 1 +461at7088 Complete M4 0 1 +4621at7088 Complete M5 0 1 +4623at7088 Complete M10 0 1 +4624at7088 Complete MZ 0 1 +4625at7088 Complete M25 0 1 +4626at7088 Complete MZ 0 1 +4627at7088 Complete M2 0 1 +4630at7088 Complete M2 0 1 +4631at7088 Complete M12 0 1 +4632at7088 Complete M6 0 1 +4633at7088 Complete M19 0 1 +4639at7088 Complete M19 0 1 +4645at7088 Complete M23 0 1 +4649at7088 Complete M23 0 1 +464at7088 Complete M13 0 1 +4650at7088 Complete M11 0 1 +4653at7088 Complete M3 0 1 +4654at7088 Complete M15 0 1 +4655at7088 Complete M29 0 1 +4656at7088 Complete M9 0 1 +4657at7088 Complete M12 0 1 +4663at7088 Complete M11 0 1 +4664at7088 Complete M19 0 1 +4668at7088 Complete M17 0 1 +4670at7088 Complete M7 0 1 +4671at7088 Complete M4 0 1 +4674at7088 Complete M21 0 1 +4677at7088 Complete M21 0 1 +467at7088 Complete M7 0 1 +4680at7088 Complete M20 0 1 +4681at7088 Complete M7 0 1 +4685at7088 Complete M26 0 1 +4688at7088 Complete M4 0 1 +4689at7088 Complete M22 0 1 +468at7088 Complete M5 0 1 +4690at7088 Complete M23 0 1 +4692at7088 Complete M21 0 1 +4694at7088 Complete M17 0 1 +4698at7088 Complete M3 0 1 +46at7088 Complete M6 0 1 +4707at7088 Complete M22 0 1 +4709at7088 Complete M9 0 1 +4710at7088 Complete M14 0 1 +4718at7088 Complete M6 0 1 +4719at7088 Complete M4 0 1 +4723at7088 Complete M16 0 1 +4724at7088 Complete M1 0 1 +4726at7088 Complete M4 0 1 +4729at7088 Complete M29 0 1 +4731at7088 Complete M13 0 1 +4735at7088 Complete M16 0 1 +4739at7088 Complete M3 0 1 +4740at7088 Complete M6 0 1 +4742at7088 Complete M18 0 1 +4744at7088 Complete M9 0 1 +4746at7088 Complete M30 0 1 +4748at7088 Complete MZ 0 1 +4749at7088 Complete M12 0 1 +4750at7088 Complete M3 0 1 +4752at7088 Complete M10 0 1 +4753at7088 Complete M2 0 1 +4760at7088 Complete M19 0 1 +4761at7088 Complete M2 0 1 +4764at7088 Complete M30 0 1 +4768at7088 Complete M2 0 1 +4776at7088 Complete M19 0 1 +4778at7088 Complete M4 0 1 +4779at7088 Complete M15 0 1 +4782at7088 Complete M5 0 1 +4784at7088 Complete M1 0 1 +4789at7088 Complete M10 0 1 +478at7088 Complete M3 0 1 +4790at7088 Complete M18 0 1 +4795at7088 Complete M3 0 1 +4799at7088 Complete MZ 0 1 +479at7088 Complete M16 0 1 +47at7088 Complete M3 0 1 +4802at7088 Complete M7 0 1 +4806at7088 Complete M30 0 1 +4810at7088 Complete M3 0 1 +4811at7088 Complete M9 0 1 +4812at7088 Complete M14 0 1 +4816at7088 Complete M10 0 1 +481at7088 Complete M10 0 1 +4820at7088 Complete M14 0 1 +4821at7088 Complete M8 0 1 +4823at7088 Complete M6 0 1 +4824at7088 Complete M13 0 1 +4834at7088 Complete M7 0 1 +4837at7088 Complete M5 0 1 +4838at7088 Complete MZ 0 1 +4839at7088 Complete M14 0 1 +4842at7088 Complete M5 0 1 +4845at7088 Complete M7 0 1 +4847at7088 Complete M18 0 1 +4848at7088 Complete MZ 0 1 +4849at7088 Complete M10 0 1 +4851at7088 Complete M7 0 1 +4854at7088 Complete M4 0 1 +4855at7088 Complete M9 0 1 +4858at7088 Complete M15 0 1 +4860at7088 Complete M21 0 1 +4864at7088 Complete M9 0 1 +4866at7088 Complete MZ 0 1 +4869at7088 Complete M2 0 1 +486at7088 Complete M5 0 1 +4870at7088 Complete M8 0 1 +4872at7088 Complete M23 0 1 +4877at7088 Complete M12 0 1 +4878at7088 Complete M1 0 1 +4880at7088 Complete M6 0 1 +4884at7088 Complete M7 0 1 +4887at7088 Complete M2 0 1 +4889at7088 Complete M20 0 1 +488at7088 Complete M23 0 1 +4891at7088 Complete M9 0 1 +4893at7088 Complete M13 0 1 +4894at7088 Complete M17 0 1 +4896at7088 Complete M6 0 1 +4899at7088 Complete M1 0 1 +489at7088 Complete M17 0 1 +48at7088 Complete M20 0 1 +4900at7088 Complete M15 0 1 +4908at7088 Complete M12 0 1 +490at7088 Complete M4 0 1 +4910at7088 Complete M22 0 1 +4915at7088 Complete M18 0 1 +4916at7088 Complete M2 0 1 +4918at7088 Complete M7 0 1 +4922at7088 Complete M11 0 1 +4923at7088 Complete M11 0 1 +4929at7088 Complete M7 0 1 +492at7088 Complete M12 0 1 +4930at7088 Complete M7 0 1 +4932at7088 Complete M1 0 1 +4934at7088 Complete M3 0 1 +4935at7088 Complete M20 0 1 +4936at7088 Complete M12 0 1 +4942at7088 Complete M21 0 1 +4948at7088 Complete M10 0 1 +4949at7088 Complete M5 0 1 +494at7088 Complete M13 0 1 +4950at7088 Complete M10 0 1 +4952at7088 Complete M16 0 1 +4953at7088 Complete M25 0 1 +4954at7088 Complete M23 0 1 +4955at7088 Complete MZ 0 1 +4956at7088 Complete M3 0 1 +4958at7088 Complete M21 0 1 +4959at7088 Complete M4 0 1 +495at7088 Complete M1 0 1 +4964at7088 Complete M23 0 1 +4967at7088 Complete M10 0 1 +4969at7088 Complete M9 0 1 +496at7088 Complete M26 0 1 +4974at7088 Complete M11 0 1 +4975at7088 Complete M19 0 1 +4989at7088 Complete M9 0 1 +498at7088 Complete M9 0 1 +4990at7088 Complete M3 0 1 +4993at7088 Complete M9 0 1 +4996at7088 Complete M15 0 1 +4998at7088 Complete M22 0 1 +499at7088 Complete M4 0 1 +49at7088 Complete M4 0 1 +4at7088 Complete M21 0 1 +5002at7088 Complete M3 0 1 +5004at7088 Complete M12 0 1 +5006at7088 Complete M8 0 1 +5009at7088 Complete M13 0 1 +5012at7088 Complete M4 0 1 +5016at7088 Complete M3 0 1 +5019at7088 Complete M26 0 1 +5021at7088 Complete M4 0 1 +5026at7088 Complete M3 0 1 +5030at7088 Complete MZ 0 1 +5031at7088 Complete M15 0 1 +5035at7088 Complete M20 0 1 +5036at7088 Complete M6 0 1 +5038at7088 Complete M19 0 1 +5040at7088 Complete M6 0 1 +5044at7088 Complete M5 0 1 +5046at7088 Complete M9 0 1 +5048at7088 Complete M28 0 1 +504at7088 Complete M10 0 1 +5050at7088 Complete M15 0 1 +5051at7088 Complete M2 0 1 +5053at7088 Complete M29 0 1 +5055at7088 Complete M7 0 1 +5056at7088 Complete M4 0 1 +5057at7088 Complete M11 0 1 +505at7088 Complete M8 0 1 +5064at7088 Complete M19 0 1 +5066at7088 Complete M15 0 1 +506at7088 Complete MZ 0 1 +5070at7088 Complete M2 0 1 +5074at7088 Complete M19 0 1 +5075at7088 Complete M7 0 1 +5078at7088 Complete M5 0 1 +5082at7088 Complete M14 0 1 +5083at7088 Complete M15 0 1 +5091at7088 Complete M25 0 1 +5093at7088 Complete M10 0 1 +5094at7088 Complete M3 0 1 +5095at7088 Complete M12 0 1 +5098at7088 Complete M8 0 1 +5099at7088 Complete M6 0 1 +509at7088 Complete M15 0 1 +50at7088 Complete M9 0 1 +5101at7088 Complete M18 0 1 +5107at7088 Complete M2 0 1 +5108at7088 Complete M23 0 1 +5110at7088 Complete M12 0 1 +5114at7088 Complete M15 0 1 +511at7088 Complete M8 0 1 +5120at7088 Complete M6 0 1 +5128at7088 Complete M2 0 1 +5129at7088 Complete M3 0 1 +5130at7088 Complete M6 0 1 +5135at7088 Complete M23 0 1 +5139at7088 Complete M2 0 1 +513at7088 Complete M11 0 1 +5144at7088 Complete M23 0 1 +5145at7088 Complete M1 0 1 +5146at7088 Complete M8 0 1 +5147at7088 Complete M3 0 1 +5149at7088 Complete M4 0 1 +5151at7088 Complete M27 0 1 +5157at7088 Complete M26 0 1 +5159at7088 Complete M18 0 1 +515at7088 Complete M9 0 1 +5162at7088 Complete M25 0 1 +5164at7088 Complete M12 0 1 +5166at7088 Complete M1 0 1 +5168at7088 Complete M9 0 1 +516at7088 Complete M9 0 1 +5172at7088 Complete M7 0 1 +5173at7088 Complete M12 0 1 +517at7088 Complete M2 0 1 +5181at7088 Complete M3 0 1 +5182at7088 Complete M23 0 1 +5183at7088 Complete M7 0 1 +5184at7088 Complete M4 0 1 +5187at7088 Complete M30 0 1 +518at7088 Complete M13 0 1 +5190at7088 Complete M5 0 1 +5191at7088 Complete M15 0 1 +5193at7088 Complete M2 0 1 +5194at7088 Complete M16 0 1 +5196at7088 Complete M7 0 1 +5197at7088 Complete MZ 0 1 +5199at7088 Complete M9 0 1 +519at7088 Complete M21 0 1 +51at7088 Complete M6 0 1 +5201at7088 Complete M9 0 1 +5203at7088 Complete M10 0 1 +5205at7088 Complete M3 0 1 +5206at7088 Complete M11 0 1 +5213at7088 Complete M11 0 1 +5216at7088 Complete M9 0 1 +5219at7088 Complete M4 0 1 +5223at7088 Complete M2 0 1 +5227at7088 Complete M19 0 1 +522at7088 Complete M11 0 1 +5239at7088 Complete M14 0 1 +5242at7088 Complete M17 0 1 +5244at7088 Complete M24 0 1 +5249at7088 Complete M2 0 1 +5250at7088 Complete M3 0 1 +5251at7088 Complete M20 0 1 +5252at7088 Complete M12 0 1 +5256at7088 Complete M3 0 1 +5258at7088 Complete M8 0 1 +5260at7088 Complete M4 0 1 +5265at7088 Complete M3 0 1 +5266at7088 Complete M25 0 1 +526at7088 Complete M20 0 1 +5270at7088 Complete M8 0 1 +5277at7088 Complete M19 0 1 +527at7088 Complete M19 0 1 +5281at7088 Complete M8 0 1 +5284at7088 Complete M6 0 1 +5290at7088 Complete M23 0 1 +5291at7088 Complete M25 0 1 +5292at7088 Complete M12 0 1 +5293at7088 Complete M5 0 1 +5295at7088 Complete M8 0 1 +5299at7088 Complete M10 0 1 +52at7088 Complete M18 0 1 +5301at7088 Complete M1 0 1 +5302at7088 Complete M23 0 1 +5303at7088 Complete M4 0 1 +530at7088 Complete M12 0 1 +5311at7088 Complete M16 0 1 +5312at7088 Complete M19 0 1 +5313at7088 Complete M11 0 1 +5314at7088 Complete M22 0 1 +5317at7088 Complete M5 0 1 +5319at7088 Complete M26 0 1 +531at7088 Complete M1 0 1 +5321at7088 Complete M8 0 1 +5322at7088 Complete M3 0 1 +5323at7088 Complete M7 0 1 +5326at7088 Complete M18 0 1 +5327at7088 Complete M6 0 1 +5328at7088 Complete M4 0 1 +532at7088 Complete M25 0 1 +5333at7088 Complete M24 0 1 +5337at7088 Complete M7 0 1 +5341at7088 Complete M27 0 1 +5342at7088 Complete M3 0 1 +5351at7088 Complete M22 0 1 +5355at7088 Complete M1 0 1 +5361at7088 Complete M3 0 1 +5362at7088 Complete M13 0 1 +5364at7088 Complete M13 0 1 +5369at7088 Complete M1 0 1 +5370at7088 Complete M1 0 1 +5371at7088 Complete M19 0 1 +5373at7088 Complete M3 0 1 +5377at7088 Complete M18 0 1 +5380at7088 Complete M1 0 1 +5381at7088 Complete M21 0 1 +5383at7088 Complete M10 0 1 +5385at7088 Complete M9 0 1 +538at7088 Complete M16 0 1 +5391at7088 Complete M9 0 1 +5392at7088 Complete M28 0 1 +5394at7088 Complete M2 0 1 +5397at7088 Complete M10 0 1 +5398at7088 Complete M11 0 1 +5404at7088 Complete M5 0 1 +5406at7088 Complete M21 0 1 +5410at7088 Complete M2 0 1 +5413at7088 Complete M8 0 1 +5415at7088 Complete M30 0 1 +5423at7088 Complete M22 0 1 +5424at7088 Complete M2 0 1 +5425at7088 Complete M1 0 1 +5427at7088 Complete M16 0 1 +543at7088 Complete M27 0 1 +5440at7088 Complete M17 0 1 +5443at7088 Complete MZ 0 1 +5446at7088 Complete M4 0 1 +544at7088 Complete M7 0 1 +5450at7088 Complete M29 0 1 +5453at7088 Complete M1 0 1 +5455at7088 Complete M4 0 1 +5457at7088 Complete M19 0 1 +5463at7088 Complete MZ 0 1 +5464at7088 Complete M16 0 1 +5474at7088 Complete MZ 0 1 +547at7088 Complete M27 0 1 +5480at7088 Complete M18 0 1 +5483at7088 Complete M9 0 1 +5486at7088 Complete M1 0 1 +5487at7088 Complete M2 0 1 +5488at7088 Complete M8 0 1 +5496at7088 Complete M19 0 1 +54at7088 Complete M9 0 1 +5500at7088 Complete M9 0 1 +5506at7088 Complete M21 0 1 +5507at7088 Complete M10 0 1 +5508at7088 Complete M21 0 1 +550at7088 Complete M14 0 1 +5520at7088 Complete M2 0 1 +5523at7088 Complete M9 0 1 +552at7088 Complete M13 0 1 +5530at7088 Complete M22 0 1 +5531at7088 Complete M20 0 1 +5533at7088 Complete M15 0 1 +5535at7088 Complete M4 0 1 +5536at7088 Complete M13 0 1 +5538at7088 Complete M14 0 1 +5539at7088 Complete M14 0 1 +553at7088 Complete M23 0 1 +5541at7088 Complete M12 0 1 +5547at7088 Complete M7 0 1 +5550at7088 Complete M27 0 1 +5555at7088 Complete M11 0 1 +5556at7088 Complete M21 0 1 +5557at7088 Complete M3 0 1 +5558at7088 Complete M13 0 1 +5559at7088 Complete M24 0 1 +5560at7088 Complete M3 0 1 +5563at7088 Complete M5 0 1 +5565at7088 Complete M18 0 1 +5567at7088 Complete MZ 0 1 +556at7088 Complete M4 0 1 +5570at7088 Complete M2 0 1 +5571at7088 Complete M3 0 1 +5576at7088 Complete M8 0 1 +5580at7088 Complete M17 0 1 +5584at7088 Complete M2 0 1 +5585at7088 Complete M8 0 1 +5586at7088 Complete M5 0 1 +5587at7088 Complete M26 0 1 +5589at7088 Complete M13 0 1 +558at7088 Complete M9 0 1 +5595at7088 Complete M20 0 1 +5598at7088 Complete M25 0 1 +5599at7088 Complete M9 0 1 +559at7088 Complete MZ 0 1 +5603at7088 Complete M21 0 1 +5606at7088 Complete M28 0 1 +5611at7088 Complete M8 0 1 +5614at7088 Complete M20 0 1 +5616at7088 Complete M16 0 1 +5622at7088 Complete M1 0 1 +5623at7088 Complete M15 0 1 +5625at7088 Complete M13 0 1 +5626at7088 Complete M4 0 1 +5627at7088 Complete M7 0 1 +5628at7088 Complete M1 0 1 +562at7088 Complete M10 0 1 +5634at7088 Complete M23 0 1 +5636at7088 Complete M9 0 1 +5638at7088 Complete MZ 0 1 +5639at7088 Complete M10 0 1 +563at7088 Complete M6 0 1 +5643at7088 Complete M9 0 1 +5648at7088 Complete M2 0 1 +5650at7088 Complete M4 0 1 +5651at7088 Complete M6 0 1 +5653at7088 Complete M5 0 1 +5665at7088 Complete M17 0 1 +5668at7088 Complete M7 0 1 +566at7088 Complete M3 0 1 +5671at7088 Complete M19 0 1 +5672at7088 Complete M17 0 1 +5674at7088 Complete M1 0 1 +5676at7088 Complete M1 0 1 +5679at7088 Complete M8 0 1 +5689at7088 Complete M2 0 1 +5690at7088 Complete M3 0 1 +5693at7088 Complete M2 0 1 +5694at7088 Complete M13 0 1 +5699at7088 Complete M1 0 1 +569at7088 Complete M3 0 1 +56at7088 Complete M13 0 1 +5700at7088 Complete M8 0 1 +5702at7088 Complete M9 0 1 +5703at7088 Complete M1 0 1 +5705at7088 Complete MZ 0 1 +5708at7088 Complete M1 0 1 +5710at7088 Complete M22 0 1 +5711at7088 Complete M9 0 1 +5712at7088 Complete M4 0 1 +5713at7088 Complete M30 0 1 +5715at7088 Complete M17 0 1 +5716at7088 Complete M13 0 1 +5717at7088 Complete M9 0 1 +571at7088 Complete M21 0 1 +5721at7088 Complete M22 0 1 +5722at7088 Complete M18 0 1 +5723at7088 Complete M7 0 1 +5724at7088 Complete M6 0 1 +5728at7088 Complete M10 0 1 +572at7088 Complete M3 0 1 +5732at7088 Complete MZ 0 1 +5733at7088 Complete M10 0 1 +5734at7088 Complete M7 0 1 +5735at7088 Complete M17 0 1 +5738at7088 Complete M24 0 1 +5740at7088 Complete M3 0 1 +5742at7088 Complete M14 0 1 +5743at7088 Complete M4 0 1 +5748at7088 Complete M1 0 1 +5759at7088 Complete M23 0 1 +5761at7088 Complete M7 0 1 +5762at7088 Complete M23 0 1 +5765at7088 Complete M19 0 1 +5767at7088 Complete M22 0 1 +5772at7088 Complete MZ 0 1 +5773at7088 Complete M9 0 1 +5775at7088 Complete M5 0 1 +5776at7088 Complete M16 0 1 +5781at7088 Complete M22 0 1 +5782at7088 Complete M7 0 1 +5786at7088 Complete M17 0 1 +5787at7088 Complete M18 0 1 +578at7088 Complete MZ 0 1 +5792at7088 Complete M23 0 1 +5793at7088 Complete M25 0 1 +5794at7088 Complete M9 0 1 +5795at7088 Complete M3 0 1 +5797at7088 Complete M2 0 1 +5798at7088 Complete M2 0 1 +5799at7088 Complete M15 0 1 +57at7088 Complete M1 0 1 +5802at7088 Complete M7 0 1 +5806at7088 Complete M4 0 1 +5810at7088 Complete M3 0 1 +5812at7088 Complete M11 0 1 +5817at7088 Complete M30 0 1 +5819at7088 Complete M5 0 1 +5820at7088 Complete M21 0 1 +5821at7088 Complete M16 0 1 +5822at7088 Complete M4 0 1 +5825at7088 Complete M19 0 1 +5826at7088 Complete M4 0 1 +5827at7088 Complete M7 0 1 +5828at7088 Complete MZ 0 1 +5832at7088 Complete M1 0 1 +5833at7088 Complete M13 0 1 +5835at7088 Complete M13 0 1 +5837at7088 Complete MZ 0 1 +583at7088 Complete M13 0 1 +5840at7088 Complete M4 0 1 +5844at7088 Complete M16 0 1 +584at7088 Complete M12 0 1 +5851at7088 Complete M7 0 1 +5852at7088 Complete MZ 0 1 +5858at7088 Complete M12 0 1 +5863at7088 Complete M25 0 1 +5864at7088 Complete M22 0 1 +5866at7088 Complete M4 0 1 +5873at7088 Complete M15 0 1 +5878at7088 Complete M20 0 1 +5881at7088 Complete M4 0 1 +5884at7088 Complete M5 0 1 +5885at7088 Complete M9 0 1 +5887at7088 Complete M17 0 1 +5889at7088 Complete M1 0 1 +5890at7088 Complete M3 0 1 +5891at7088 Complete M25 0 1 +5898at7088 Complete M2 0 1 +589at7088 Complete M4 0 1 +5900at7088 Complete M25 0 1 +590at7088 Complete M9 0 1 +5912at7088 Complete M11 0 1 +5916at7088 Complete M19 0 1 +5917at7088 Complete M16 0 1 +5919at7088 Complete M20 0 1 +5920at7088 Complete M29 0 1 +5922at7088 Complete M13 0 1 +5925at7088 Complete M16 0 1 +5933at7088 Complete M14 0 1 +5936at7088 Complete M1 0 1 +5937at7088 Complete M9 0 1 +5938at7088 Complete M5 0 1 +5945at7088 Complete M11 0 1 +5949at7088 Complete M22 0 1 +5950at7088 Complete M10 0 1 +5952at7088 Complete M20 0 1 +5954at7088 Complete M12 0 1 +5957at7088 Complete M24 0 1 +5963at7088 Complete M14 0 1 +5964at7088 Complete M2 0 1 +5967at7088 Complete M19 0 1 +5969at7088 Complete M6 0 1 +5974at7088 Complete M1 0 1 +5975at7088 Complete M10 0 1 +5978at7088 Complete M2 0 1 +5979at7088 Complete M30 0 1 +5980at7088 Complete MZ 0 1 +5982at7088 Complete M21 0 1 +5987at7088 Complete M16 0 1 +598at7088 Complete M3 0 1 +5991at7088 Complete M26 0 1 +599at7088 Complete M21 0 1 +59at7088 Complete M11 0 1 +6000at7088 Complete M23 0 1 +6001at7088 Complete M1 0 1 +6006at7088 Complete M1 0 1 +6007at7088 Complete M16 0 1 +600at7088 Complete M2 0 1 +6012at7088 Complete M2 0 1 +6013at7088 Complete M13 0 1 +601at7088 Complete M7 0 1 +6020at7088 Complete M12 0 1 +6021at7088 Complete M14 0 1 +6022at7088 Complete M25 0 1 +6023at7088 Complete M22 0 1 +6025at7088 Complete M11 0 1 +6031at7088 Complete M22 0 1 +6032at7088 Complete M21 0 1 +6033at7088 Complete M12 0 1 +6038at7088 Complete M11 0 1 +603at7088 Complete M23 0 1 +6043at7088 Complete M8 0 1 +6044at7088 Complete M7 0 1 +6047at7088 Complete M13 0 1 +6050at7088 Complete M9 0 1 +6051at7088 Complete M7 0 1 +6055at7088 Complete M15 0 1 +6061at7088 Complete M5 0 1 +6062at7088 Complete M1 0 1 +6063at7088 Complete M25 0 1 +6066at7088 Complete M6 0 1 +6067at7088 Complete M15 0 1 +6074at7088 Complete M8 0 1 +6076at7088 Complete M24 0 1 +6077at7088 Complete M3 0 1 +6079at7088 Complete M8 0 1 +6080at7088 Complete M7 0 1 +6081at7088 Complete M5 0 1 +6083at7088 Complete M20 0 1 +6084at7088 Complete M2 0 1 +6085at7088 Complete M15 0 1 +6089at7088 Complete M2 0 1 +608at7088 Complete M13 0 1 +6091at7088 Complete M10 0 1 +6093at7088 Complete M9 0 1 +6097at7088 Complete M11 0 1 +6099at7088 Complete M18 0 1 +609at7088 Complete M21 0 1 +60at7088 Complete M9 0 1 +6101at7088 Complete M4 0 1 +6104at7088 Complete M8 0 1 +6105at7088 Complete M27 0 1 +6108at7088 Complete MZ 0 1 +6109at7088 Complete M5 0 1 +6110at7088 Complete M14 0 1 +6112at7088 Complete M16 0 1 +6115at7088 Complete M12 0 1 +6116at7088 Complete M8 0 1 +6117at7088 Complete M15 0 1 +6119at7088 Complete M2 0 1 +611at7088 Complete M21 0 1 +6122at7088 Complete M5 0 1 +6123at7088 Complete M11 0 1 +6126at7088 Complete M23 0 1 +6129at7088 Complete M11 0 1 +6130at7088 Complete M28 0 1 +6131at7088 Complete M29 0 1 +6135at7088 Complete M14 0 1 +6139at7088 Complete M24 0 1 +613at7088 Complete M1 0 1 +6140at7088 Complete M10 0 1 +6143at7088 Complete M11 0 1 +6145at7088 Complete M20 0 1 +614at7088 Complete M6 0 1 +6156at7088 Complete M4 0 1 +6157at7088 Complete MZ 0 1 +6159at7088 Complete M4 0 1 +6162at7088 Complete M6 0 1 +6166at7088 Complete M21 0 1 +616at7088 Complete M4 0 1 +6171at7088 Complete M19 0 1 +6172at7088 Complete MZ 0 1 +6173at7088 Complete M14 0 1 +6174at7088 Complete M18 0 1 +6175at7088 Complete M6 0 1 +6178at7088 Complete M18 0 1 +6179at7088 Complete M25 0 1 +6180at7088 Complete M1 0 1 +6181at7088 Complete M7 0 1 +6186at7088 Complete M12 0 1 +6191at7088 Complete M18 0 1 +6196at7088 Complete M7 0 1 +6198at7088 Complete M23 0 1 +6199at7088 Complete M2 0 1 +6201at7088 Complete M10 0 1 +6205at7088 Complete M14 0 1 +6207at7088 Complete M27 0 1 +6208at7088 Complete M4 0 1 +6209at7088 Complete M1 0 1 +620at7088 Complete M12 0 1 +6210at7088 Complete MZ 0 1 +6213at7088 Complete M11 0 1 +6214at7088 Complete M10 0 1 +6215at7088 Complete M9 0 1 +6216at7088 Complete M5 0 1 +6218at7088 Complete M23 0 1 +6219at7088 Complete M7 0 1 +621at7088 Complete M22 0 1 +6221at7088 Complete M22 0 1 +6225at7088 Complete M26 0 1 +6226at7088 Complete M13 0 1 +622at7088 Complete M27 0 1 +6230at7088 Complete MZ 0 1 +6239at7088 Complete M6 0 1 +6240at7088 Complete M4 0 1 +6241at7088 Complete M10 0 1 +6242at7088 Complete M20 0 1 +6243at7088 Complete M13 0 1 +6247at7088 Complete M9 0 1 +6249at7088 Complete M12 0 1 +6253at7088 Complete M15 0 1 +6255at7088 Complete M17 0 1 +6261at7088 Complete M16 0 1 +6263at7088 Complete M7 0 1 +6264at7088 Complete M5 0 1 +6265at7088 Complete M16 0 1 +6267at7088 Complete M23 0 1 +6269at7088 Complete M25 0 1 +6273at7088 Complete M26 0 1 +6279at7088 Complete M16 0 1 +627at7088 Complete M1 0 1 +6284at7088 Complete M1 0 1 +6285at7088 Complete M3 0 1 +6287at7088 Complete M4 0 1 +6289at7088 Complete M10 0 1 +628at7088 Complete M3 0 1 +6290at7088 Complete M8 0 1 +6294at7088 Complete M23 0 1 +6295at7088 Complete M4 0 1 +6299at7088 Complete M12 0 1 +6300at7088 Complete M21 0 1 +6302at7088 Complete M17 0 1 +6308at7088 Complete M29 0 1 +6309at7088 Complete M2 0 1 +6311at7088 Complete M24 0 1 +6320at7088 Complete M2 0 1 +6321at7088 Complete M1 0 1 +6325at7088 Complete M4 0 1 +6329at7088 Complete M8 0 1 +632at7088 Complete M1 0 1 +6330at7088 Complete M6 0 1 +6332at7088 Complete M13 0 1 +6335at7088 Complete M10 0 1 +6336at7088 Complete M5 0 1 +6339at7088 Complete M11 0 1 +633at7088 Complete M17 0 1 +6342at7088 Complete M25 0 1 +6343at7088 Complete M5 0 1 +6346at7088 Complete M8 0 1 +6347at7088 Complete M1 0 1 +6348at7088 Complete M19 0 1 +6349at7088 Complete M21 0 1 +6351at7088 Complete M14 0 1 +6352at7088 Complete M8 0 1 +6353at7088 Complete M14 0 1 +6358at7088 Complete M22 0 1 +6365at7088 Complete M2 0 1 +6366at7088 Complete M19 0 1 +6373at7088 Complete M6 0 1 +6374at7088 Complete M3 0 1 +637at7088 Complete M18 0 1 +6381at7088 Complete M14 0 1 +6385at7088 Complete M23 0 1 +6386at7088 Complete M18 0 1 +638at7088 Complete M8 0 1 +6394at7088 Complete M3 0 1 +6395at7088 Complete M14 0 1 +639at7088 Complete MZ 0 1 +63at7088 Complete M15 0 1 +6401at7088 Complete M19 0 1 +6403at7088 Complete M9 0 1 +6404at7088 Complete M17 0 1 +6407at7088 Complete M7 0 1 +6410at7088 Complete M8 0 1 +6413at7088 Complete M27 0 1 +6414at7088 Complete M16 0 1 +6420at7088 Complete M13 0 1 +6421at7088 Complete M14 0 1 +6427at7088 Complete MZ 0 1 +642at7088 Complete M11 0 1 +6432at7088 Complete MZ 0 1 +6433at7088 Complete M4 0 1 +6436at7088 Complete M15 0 1 +6437at7088 Complete M28 0 1 +6438at7088 Complete M10 0 1 +6439at7088 Complete M18 0 1 +643at7088 Complete M1 0 1 +6443at7088 Complete M18 0 1 +6446at7088 Complete M12 0 1 +6449at7088 Complete M11 0 1 +6450at7088 Complete M1 0 1 +6453at7088 Complete M20 0 1 +6454at7088 Complete M19 0 1 +6462at7088 Complete M11 0 1 +6464at7088 Complete M19 0 1 +6467at7088 Complete M19 0 1 +6471at7088 Complete MZ 0 1 +6477at7088 Complete M14 0 1 +647at7088 Complete M4 0 1 +6481at7088 Complete M17 0 1 +6486at7088 Complete M10 0 1 +6487at7088 Complete M13 0 1 +6499at7088 Complete M28 0 1 +649at7088 Complete M24 0 1 +64at7088 Complete M4 0 1 +6501at7088 Complete M22 0 1 +6502at7088 Complete M17 0 1 +6503at7088 Complete M24 0 1 +6508at7088 Complete M23 0 1 +6512at7088 Complete M25 0 1 +6513at7088 Complete M7 0 1 +6515at7088 Complete M25 0 1 +6518at7088 Complete M10 0 1 +6522at7088 Complete M19 0 1 +6523at7088 Complete M4 0 1 +6525at7088 Complete M18 0 1 +6528at7088 Complete M22 0 1 +652at7088 Complete M12 0 1 +6538at7088 Complete M10 0 1 +6540at7088 Complete M22 0 1 +6542at7088 Complete M15 0 1 +6548at7088 Complete MZ 0 1 +6552at7088 Complete M20 0 1 +6555at7088 Complete M12 0 1 +6556at7088 Complete M15 0 1 +6558at7088 Complete M2 0 1 +655at7088 Complete M15 0 1 +6562at7088 Complete M8 0 1 +6570at7088 Complete M18 0 1 +6571at7088 Complete M6 0 1 +6572at7088 Complete MZ 0 1 +6573at7088 Complete M6 0 1 +6579at7088 Complete M10 0 1 +657at7088 Complete M4 0 1 +6582at7088 Complete M14 0 1 +6583at7088 Complete M26 0 1 +6585at7088 Complete M22 0 1 +6589at7088 Complete M4 0 1 +658at7088 Complete M1 0 1 +6594at7088 Complete M13 0 1 +6597at7088 Complete M6 0 1 +6598at7088 Complete M14 0 1 +659at7088 Complete M14 0 1 +65at7088 Complete M23 0 1 +6601at7088 Complete M21 0 1 +6602at7088 Complete M6 0 1 +6606at7088 Complete M3 0 1 +6607at7088 Complete M19 0 1 +660at7088 Complete M1 0 1 +6614at7088 Complete M14 0 1 +6616at7088 Complete M3 0 1 +6620at7088 Complete M11 0 1 +6622at7088 Complete M18 0 1 +6627at7088 Complete M19 0 1 +6628at7088 Complete M4 0 1 +662at7088 Complete M13 0 1 +6636at7088 Complete M14 0 1 +6637at7088 Complete M1 0 1 +6642at7088 Complete M8 0 1 +6644at7088 Complete M15 0 1 +6645at7088 Complete M7 0 1 +6646at7088 Complete M24 0 1 +664at7088 Complete M19 0 1 +6652at7088 Complete M9 0 1 +6655at7088 Complete M9 0 1 +6657at7088 Complete M3 0 1 +6663at7088 Complete M19 0 1 +6668at7088 Complete M18 0 1 +666at7088 Complete M7 0 1 +6670at7088 Complete M10 0 1 +6671at7088 Complete M8 0 1 +6673at7088 Complete M22 0 1 +6674at7088 Complete M22 0 1 +6678at7088 Complete M30 0 1 +667at7088 Complete M8 0 1 +6680at7088 Complete M15 0 1 +6681at7088 Complete M16 0 1 +6683at7088 Complete M11 0 1 +6684at7088 Complete M14 0 1 +6687at7088 Complete M12 0 1 +6688at7088 Complete M12 0 1 +6690at7088 Complete M12 0 1 +6691at7088 Complete M8 0 1 +66at7088 Complete M7 0 1 +6701at7088 Complete M11 0 1 +6703at7088 Complete M3 0 1 +6707at7088 Complete M9 0 1 +670at7088 Complete M28 0 1 +6720at7088 Complete M7 0 1 +6722at7088 Complete M1 0 1 +6723at7088 Complete M6 0 1 +6725at7088 Complete M3 0 1 +6728at7088 Complete M16 0 1 +672at7088 Complete M2 0 1 +6737at7088 Complete M15 0 1 +6742at7088 Complete M2 0 1 +6744at7088 Complete M25 0 1 +6745at7088 Complete M8 0 1 +6751at7088 Complete M9 0 1 +6753at7088 Complete M2 0 1 +6754at7088 Complete M4 0 1 +6757at7088 Complete M13 0 1 +675at7088 Complete M11 0 1 +6769at7088 Complete M14 0 1 +6770at7088 Complete M19 0 1 +6771at7088 Complete M10 0 1 +6775at7088 Complete M16 0 1 +6779at7088 Complete M14 0 1 +6780at7088 Complete M9 0 1 +6782at7088 Complete M1 0 1 +6783at7088 Complete M3 0 1 +6786at7088 Complete M25 0 1 +6787at7088 Complete M17 0 1 +6788at7088 Complete M1 0 1 +6789at7088 Complete M8 0 1 +678at7088 Complete M4 0 1 +6791at7088 Complete M17 0 1 +6795at7088 Complete M22 0 1 +6796at7088 Complete M3 0 1 +6797at7088 Complete M15 0 1 +6798at7088 Complete M8 0 1 +6809at7088 Complete M5 0 1 +680at7088 Complete M7 0 1 +6810at7088 Complete M8 0 1 +6811at7088 Complete M11 0 1 +6817at7088 Complete M6 0 1 +6818at7088 Complete MZ 0 1 +6819at7088 Complete M15 0 1 +681at7088 Complete M19 0 1 +6821at7088 Complete M3 0 1 +6823at7088 Complete M11 0 1 +6825at7088 Complete M10 0 1 +6826at7088 Complete M4 0 1 +6830at7088 Complete M13 0 1 +6835at7088 Complete M26 0 1 +6837at7088 Complete M18 0 1 +6841at7088 Complete M15 0 1 +6845at7088 Complete M18 0 1 +6846at7088 Complete M9 0 1 +6847at7088 Complete M4 0 1 +6853at7088 Complete M7 0 1 +6855at7088 Complete M13 0 1 +6857at7088 Complete M12 0 1 +6860at7088 Complete M19 0 1 +6861at7088 Complete M19 0 1 +6862at7088 Complete M10 0 1 +6871at7088 Complete M1 0 1 +6873at7088 Complete M1 0 1 +6874at7088 Complete M28 0 1 +6884at7088 Complete M23 0 1 +6885at7088 Complete M19 0 1 +6893at7088 Complete M10 0 1 +6896at7088 Complete M5 0 1 +6899at7088 Complete M5 0 1 +68at7088 Complete MZ 0 1 +6900at7088 Complete M1 0 1 +6903at7088 Complete M6 0 1 +6906at7088 Complete M1 0 1 +6908at7088 Complete M28 0 1 +6909at7088 Complete M9 0 1 +690at7088 Complete M10 0 1 +6912at7088 Complete M12 0 1 +6913at7088 Complete M4 0 1 +6914at7088 Complete M15 0 1 +6918at7088 Complete M3 0 1 +6919at7088 Complete M1 0 1 +6926at7088 Complete M6 0 1 +692at7088 Complete M2 0 1 +6935at7088 Complete M14 0 1 +6936at7088 Complete M21 0 1 +6937at7088 Complete M15 0 1 +6938at7088 Complete M5 0 1 +6940at7088 Complete M11 0 1 +6944at7088 Complete M16 0 1 +6950at7088 Complete M30 0 1 +6951at7088 Complete M2 0 1 +6955at7088 Complete M7 0 1 +6959at7088 Complete M7 0 1 +695at7088 Complete M6 0 1 +6967at7088 Complete M25 0 1 +696at7088 Complete M1 0 1 +6971at7088 Complete M18 0 1 +6979at7088 Complete M3 0 1 +6980at7088 Complete M15 0 1 +6982at7088 Complete M20 0 1 +6983at7088 Complete M5 0 1 +6985at7088 Complete M10 0 1 +6987at7088 Complete M12 0 1 +6988at7088 Complete M3 0 1 +6989at7088 Complete M2 0 1 +6991at7088 Complete M10 0 1 +6996at7088 Complete M24 0 1 +69at7088 Complete M12 0 1 +6at7088 Complete M6 0 1 +7001at7088 Complete M17 0 1 +7002at7088 Complete M20 0 1 +7004at7088 Complete MZ 0 1 +7005at7088 Complete M17 0 1 +7007at7088 Complete M16 0 1 +7009at7088 Complete M18 0 1 +7010at7088 Complete MZ 0 1 +7017at7088 Complete M13 0 1 +701at7088 Complete M9 0 1 +7024at7088 Complete M1 0 1 +7025at7088 Complete M6 0 1 +7040at7088 Complete M20 0 1 +7041at7088 Complete M5 0 1 +7044at7088 Complete M13 0 1 +7045at7088 Complete M25 0 1 +7047at7088 Complete M23 0 1 +7048at7088 Complete M23 0 1 +7051at7088 Complete M14 0 1 +7052at7088 Complete M9 0 1 +7053at7088 Complete M1 0 1 +7056at7088 Complete M28 0 1 +7058at7088 Complete M2 0 1 +705at7088 Complete M14 0 1 +7060at7088 Complete M5 0 1 +7062at7088 Complete M3 0 1 +7064at7088 Complete MZ 0 1 +7067at7088 Complete M2 0 1 +7070at7088 Complete M16 0 1 +7071at7088 Complete M3 0 1 +7081at7088 Complete M19 0 1 +7082at7088 Complete M2 0 1 +7084at7088 Complete M2 0 1 +7087at7088 Complete M16 0 1 +7088at7088 Complete M13 0 1 +7089at7088 Complete M16 0 1 +708at7088 Complete MZ 0 1 +7090at7088 Complete M9 0 1 +7092at7088 Complete M4 0 1 +7097at7088 Complete M12 0 1 +70at7088 Complete M9 0 1 +7101at7088 Complete M5 0 1 +7106at7088 Complete M4 0 1 +7108at7088 Complete M7 0 1 +7112at7088 Complete M3 0 1 +7114at7088 Complete M11 0 1 +7115at7088 Complete M7 0 1 +7117at7088 Complete M21 0 1 +7118at7088 Complete M3 0 1 +7119at7088 Complete M13 0 1 +711at7088 Complete M1 0 1 +7122at7088 Complete M14 0 1 +7123at7088 Complete M4 0 1 +7125at7088 Complete M18 0 1 +7126at7088 Complete M15 0 1 +7128at7088 Complete M15 0 1 +7129at7088 Complete M1 0 1 +7133at7088 Complete M10 0 1 +713at7088 Complete M28 0 1 +7142at7088 Complete M20 0 1 +7146at7088 Complete M24 0 1 +7147at7088 Complete M2 0 1 +714at7088 Complete M9 0 1 +7153at7088 Complete M23 0 1 +7154at7088 Complete M20 0 1 +7156at7088 Complete M28 0 1 +7159at7088 Complete M4 0 1 +7160at7088 Complete M20 0 1 +7162at7088 Complete M2 0 1 +7163at7088 Complete M8 0 1 +7166at7088 Complete M8 0 1 +716at7088 Complete M22 0 1 +7170at7088 Complete M14 0 1 +7172at7088 Complete M8 0 1 +7176at7088 Complete M2 0 1 +7177at7088 Complete M22 0 1 +717at7088 Complete M4 0 1 +7181at7088 Complete M3 0 1 +7182at7088 Complete M22 0 1 +7184at7088 Complete M5 0 1 +7185at7088 Complete M15 0 1 +7188at7088 Complete M22 0 1 +718at7088 Complete M2 0 1 +7192at7088 Complete M11 0 1 +7194at7088 Complete M16 0 1 +7199at7088 Complete M2 0 1 +7200at7088 Complete M16 0 1 +7201at7088 Complete M6 0 1 +7204at7088 Complete M4 0 1 +7205at7088 Complete M16 0 1 +7206at7088 Complete M21 0 1 +7207at7088 Complete M5 0 1 +7219at7088 Complete M20 0 1 +721at7088 Complete M26 0 1 +7220at7088 Complete M21 0 1 +7223at7088 Complete M2 0 1 +7227at7088 Complete M22 0 1 +7229at7088 Complete M29 0 1 +7230at7088 Complete M12 0 1 +7237at7088 Complete M17 0 1 +7238at7088 Complete M15 0 1 +723at7088 Complete M6 0 1 +7246at7088 Complete M22 0 1 +7248at7088 Complete M10 0 1 +724at7088 Complete M13 0 1 +7253at7088 Complete M9 0 1 +7254at7088 Complete M10 0 1 +7258at7088 Complete M9 0 1 +7260at7088 Complete MZ 0 1 +7263at7088 Complete M3 0 1 +7264at7088 Complete M20 0 1 +7267at7088 Complete M1 0 1 +7268at7088 Complete M15 0 1 +7271at7088 Complete M7 0 1 +7272at7088 Complete MZ 0 1 +7277at7088 Complete M6 0 1 +7283at7088 Complete M15 0 1 +7285at7088 Complete M8 0 1 +7286at7088 Complete M22 0 1 +7288at7088 Complete M5 0 1 +7290at7088 Complete M28 0 1 +7295at7088 Complete M7 0 1 +7298at7088 Complete M2 0 1 +7299at7088 Complete MZ 0 1 +72at7088 Complete M3 0 1 +7301at7088 Complete M16 0 1 +7303at7088 Complete M21 0 1 +7307at7088 Complete M2 0 1 +7308at7088 Complete M10 0 1 +730at7088 Complete M2 0 1 +7313at7088 Complete M24 0 1 +7314at7088 Complete M1 0 1 +731at7088 Complete M5 0 1 +7324at7088 Complete M11 0 1 +7326at7088 Complete M9 0 1 +7331at7088 Complete M5 0 1 +7332at7088 Complete M21 0 1 +7335at7088 Complete M17 0 1 +7336at7088 Complete MZ 0 1 +7342at7088 Complete M13 0 1 +7348at7088 Complete M2 0 1 +7350at7088 Complete M11 0 1 +7354at7088 Complete M10 0 1 +7355at7088 Complete M4 0 1 +7356at7088 Complete M1 0 1 +7357at7088 Complete M2 0 1 +7360at7088 Complete MZ 0 1 +7361at7088 Complete M4 0 1 +7363at7088 Complete MZ 0 1 +7370at7088 Complete M13 0 1 +7371at7088 Complete M20 0 1 +7376at7088 Complete M5 0 1 +7377at7088 Complete M11 0 1 +7378at7088 Complete M10 0 1 +7379at7088 Complete M2 0 1 +7380at7088 Complete M2 0 1 +7382at7088 Complete M7 0 1 +7385at7088 Complete M25 0 1 +7392at7088 Complete M5 0 1 +7395at7088 Complete M7 0 1 +7397at7088 Complete M9 0 1 +7400at7088 Complete M10 0 1 +7406at7088 Complete M22 0 1 +7409at7088 Complete M26 0 1 +7410at7088 Complete MZ 0 1 +7415at7088 Complete M9 0 1 +7416at7088 Complete M17 0 1 +7419at7088 Complete M13 0 1 +741at7088 Complete M11 0 1 +7420at7088 Complete M1 0 1 +7427at7088 Complete M5 0 1 +7429at7088 Complete MZ 0 1 +742at7088 Complete M2 0 1 +7430at7088 Complete M19 0 1 +7431at7088 Complete M13 0 1 +7432at7088 Complete M10 0 1 +7435at7088 Complete M15 0 1 +7436at7088 Complete M11 0 1 +7442at7088 Complete M7 0 1 +7446at7088 Complete M6 0 1 +7447at7088 Complete M13 0 1 +7449at7088 Complete M3 0 1 +7454at7088 Complete M14 0 1 +7456at7088 Complete M6 0 1 +7459at7088 Complete M3 0 1 +7461at7088 Complete M7 0 1 +7465at7088 Complete M28 0 1 +7466at7088 Complete M5 0 1 +7471at7088 Complete M9 0 1 +7472at7088 Complete M10 0 1 +7473at7088 Complete M24 0 1 +7475at7088 Complete M2 0 1 +7476at7088 Complete M21 0 1 +7478at7088 Complete M3 0 1 +7479at7088 Complete M8 0 1 +7481at7088 Complete M5 0 1 +7492at7088 Complete M8 0 1 +7494at7088 Complete M1 0 1 +7495at7088 Complete M15 0 1 +7497at7088 Complete M1 0 1 +74at7088 Complete M5 0 1 +7500at7088 Complete M18 0 1 +7501at7088 Complete M21 0 1 +7506at7088 Complete M12 0 1 +7508at7088 Complete M25 0 1 +7512at7088 Complete M17 0 1 +7513at7088 Complete M13 0 1 +7520at7088 Complete M11 0 1 +7523at7088 Complete M2 0 1 +7527at7088 Complete M9 0 1 +752at7088 Complete MZ 0 1 +7530at7088 Complete M4 0 1 +7544at7088 Complete M13 0 1 +7550at7088 Complete M16 0 1 +7555at7088 Complete M3 0 1 +7556at7088 Complete M8 0 1 +7559at7088 Complete M21 0 1 +7560at7088 Complete M8 0 1 +7561at7088 Complete M6 0 1 +7566at7088 Complete M8 0 1 +7567at7088 Complete M12 0 1 +7568at7088 Complete MZ 0 1 +756at7088 Complete M4 0 1 +7573at7088 Complete M27 0 1 +7574at7088 Complete MZ 0 1 +7576at7088 Complete M14 0 1 +7577at7088 Complete M14 0 1 +757at7088 Complete M14 0 1 +7584at7088 Complete M17 0 1 +7586at7088 Complete M17 0 1 +758at7088 Complete M5 0 1 +7591at7088 Complete M16 0 1 +7592at7088 Complete M1 0 1 +7594at7088 Complete M17 0 1 +7595at7088 Complete M6 0 1 +7597at7088 Complete M7 0 1 +7598at7088 Complete M1 0 1 +7607at7088 Complete M30 0 1 +7608at7088 Complete M13 0 1 +7611at7088 Complete M11 0 1 +7614at7088 Complete M5 0 1 +7618at7088 Complete M1 0 1 +761at7088 Complete M12 0 1 +7622at7088 Complete M1 0 1 +7627at7088 Complete M1 0 1 +7629at7088 Complete M14 0 1 +7633at7088 Complete MZ 0 1 +7635at7088 Complete M13 0 1 +7642at7088 Complete M10 0 1 +764at7088 Complete M7 0 1 +7654at7088 Complete M14 0 1 +7656at7088 Complete M16 0 1 +7659at7088 Complete M3 0 1 +765at7088 Complete M10 0 1 +7664at7088 Complete M6 0 1 +7667at7088 Complete M21 0 1 +7668at7088 Complete M17 0 1 +7669at7088 Complete M2 0 1 +7670at7088 Complete M10 0 1 +7672at7088 Complete M11 0 1 +7674at7088 Complete M13 0 1 +7675at7088 Complete M17 0 1 +7676at7088 Complete M8 0 1 +7678at7088 Complete M5 0 1 +7681at7088 Complete M3 0 1 +7682at7088 Complete M2 0 1 +7690at7088 Complete M2 0 1 +7696at7088 Complete M5 0 1 +7698at7088 Complete M14 0 1 +7699at7088 Complete M8 0 1 +769at7088 Complete M8 0 1 +7705at7088 Complete M13 0 1 +7706at7088 Complete M13 0 1 +7707at7088 Complete M18 0 1 +7708at7088 Complete M11 0 1 +7712at7088 Complete M1 0 1 +7714at7088 Complete M5 0 1 +7719at7088 Complete M8 0 1 +7720at7088 Complete M11 0 1 +7721at7088 Complete M1 0 1 +7722at7088 Complete MZ 0 1 +7723at7088 Complete M6 0 1 +7726at7088 Complete M20 0 1 +7727at7088 Complete M6 0 1 +7729at7088 Complete MZ 0 1 +772at7088 Complete M5 0 1 +7731at7088 Complete M20 0 1 +7732at7088 Complete M15 0 1 +7737at7088 Complete M15 0 1 +7738at7088 Complete M23 0 1 +7742at7088 Complete M1 0 1 +7744at7088 Complete M15 0 1 +7749at7088 Complete M14 0 1 +774at7088 Complete M23 0 1 +7751at7088 Complete M20 0 1 +7754at7088 Complete M18 0 1 +7755at7088 Complete M11 0 1 +775at7088 Complete M3 0 1 +7763at7088 Complete M24 0 1 +7765at7088 Complete M21 0 1 +7768at7088 Complete M1 0 1 +7770at7088 Complete M12 0 1 +7772at7088 Complete M12 0 1 +7773at7088 Complete M2 0 1 +7774at7088 Complete M6 0 1 +7777at7088 Complete M13 0 1 +7778at7088 Complete M1 0 1 +7783at7088 Complete M3 0 1 +7787at7088 Complete M2 0 1 +7789at7088 Complete M12 0 1 +7790at7088 Complete M12 0 1 +7791at7088 Complete M8 0 1 +7792at7088 Complete M12 0 1 +7797at7088 Complete M20 0 1 +7798at7088 Complete M15 0 1 +7805at7088 Complete M25 0 1 +780at7088 Complete M2 0 1 +7811at7088 Complete M15 0 1 +7813at7088 Complete M5 0 1 +7815at7088 Complete M1 0 1 +7817at7088 Complete M23 0 1 +7819at7088 Complete M8 0 1 +781at7088 Complete MZ 0 1 +7821at7088 Complete MZ 0 1 +7823at7088 Complete M10 0 1 +7829at7088 Complete M4 0 1 +7830at7088 Complete M5 0 1 +7833at7088 Complete M16 0 1 +7837at7088 Complete M11 0 1 +7838at7088 Complete M5 0 1 +7847at7088 Complete M5 0 1 +7853at7088 Complete M16 0 1 +7854at7088 Complete M29 0 1 +7855at7088 Complete M18 0 1 +7856at7088 Complete M8 0 1 +7857at7088 Complete M7 0 1 +7858at7088 Complete M6 0 1 +7860at7088 Complete M2 0 1 +7862at7088 Complete M1 0 1 +7869at7088 Complete M17 0 1 +7871at7088 Complete M15 0 1 +7876at7088 Complete M2 0 1 +787at7088 Complete M6 0 1 +7882at7088 Complete M4 0 1 +7884at7088 Complete M7 0 1 +7887at7088 Complete M20 0 1 +7890at7088 Complete M2 0 1 +7894at7088 Complete M1 0 1 +7897at7088 Complete M15 0 1 +7899at7088 Complete M1 0 1 +78at7088 Complete M14 0 1 +7900at7088 Complete M6 0 1 +7901at7088 Complete M13 0 1 +7902at7088 Complete M16 0 1 +7904at7088 Complete M12 0 1 +7905at7088 Complete M2 0 1 +7909at7088 Complete M11 0 1 +790at7088 Complete MZ 0 1 +7911at7088 Complete M10 0 1 +7914at7088 Complete M18 0 1 +7915at7088 Complete M10 0 1 +7918at7088 Complete M15 0 1 +7919at7088 Complete M17 0 1 +791at7088 Complete M20 0 1 +7920at7088 Complete M6 0 1 +7921at7088 Complete M1 0 1 +7926at7088 Complete M21 0 1 +7928at7088 Complete M2 0 1 +7932at7088 Complete M9 0 1 +7933at7088 Complete M3 0 1 +7935at7088 Complete M25 0 1 +793at7088 Complete M3 0 1 +7940at7088 Complete MZ 0 1 +7948at7088 Complete M22 0 1 +794at7088 Complete M13 0 1 +7952at7088 Complete M20 0 1 +7953at7088 Complete M5 0 1 +7956at7088 Complete M11 0 1 +795at7088 Complete M3 0 1 +7966at7088 Complete M2 0 1 +7967at7088 Complete M4 0 1 +7968at7088 Complete M15 0 1 +796at7088 Complete M19 0 1 +7970at7088 Complete M11 0 1 +7972at7088 Complete M11 0 1 +7975at7088 Complete MZ 0 1 +7976at7088 Complete M13 0 1 +7978at7088 Complete M26 0 1 +7980at7088 Complete M14 0 1 +7984at7088 Complete M10 0 1 +7986at7088 Complete M14 0 1 +7987at7088 Complete MZ 0 1 +7988at7088 Complete M11 0 1 +7989at7088 Complete MZ 0 1 +7990at7088 Complete M14 0 1 +7991at7088 Complete M3 0 1 +7993at7088 Complete M22 0 1 +7994at7088 Complete M21 0 1 +7996at7088 Complete M8 0 1 +7997at7088 Complete M14 0 1 +799at7088 Complete M1 0 1 +8001at7088 Complete M5 0 1 +8006at7088 Complete M23 0 1 +8007at7088 Complete M12 0 1 +8008at7088 Complete M9 0 1 +8009at7088 Complete M9 0 1 +800at7088 Complete M1 0 1 +8010at7088 Complete M12 0 1 +8011at7088 Complete M17 0 1 +8012at7088 Complete M17 0 1 +8013at7088 Complete M10 0 1 +8015at7088 Complete M6 0 1 +8019at7088 Complete M24 0 1 +802at7088 Complete M8 0 1 +8031at7088 Complete M3 0 1 +8032at7088 Complete M8 0 1 +8033at7088 Complete M2 0 1 +8034at7088 Complete M4 0 1 +8039at7088 Complete M20 0 1 +8040at7088 Complete M26 0 1 +8043at7088 Complete M28 0 1 +8044at7088 Complete MZ 0 1 +8045at7088 Complete M10 0 1 +8046at7088 Complete M20 0 1 +8048at7088 Complete M3 0 1 +8050at7088 Complete M13 0 1 +8051at7088 Complete M12 0 1 +8052at7088 Complete MZ 0 1 +8053at7088 Complete M24 0 1 +8055at7088 Complete M13 0 1 +8057at7088 Complete M20 0 1 +805at7088 Complete M28 0 1 +8065at7088 Complete M3 0 1 +8067at7088 Complete M5 0 1 +806at7088 Complete M23 0 1 +8071at7088 Complete M27 0 1 +8072at7088 Complete M12 0 1 +8073at7088 Complete M14 0 1 +8079at7088 Complete M21 0 1 +8080at7088 Complete MZ 0 1 +8081at7088 Complete M15 0 1 +8084at7088 Complete M17 0 1 +8088at7088 Complete M24 0 1 +8089at7088 Complete M17 0 1 +8097at7088 Complete M3 0 1 +8098at7088 Complete M2 0 1 +8100at7088 Complete MZ 0 1 +8101at7088 Complete M18 0 1 +8102at7088 Complete M3 0 1 +8103at7088 Complete M30 0 1 +8106at7088 Complete M9 0 1 +8107at7088 Complete M13 0 1 +8111at7088 Complete M14 0 1 +8116at7088 Complete M29 0 1 +8117at7088 Complete M1 0 1 +8118at7088 Complete M19 0 1 +8120at7088 Complete M2 0 1 +8122at7088 Complete M13 0 1 +8129at7088 Complete M23 0 1 +8131at7088 Complete M20 0 1 +8132at7088 Complete MZ 0 1 +8136at7088 Complete M4 0 1 +8139at7088 Complete M10 0 1 +8144at7088 Complete M19 0 1 +8148at7088 Complete M11 0 1 +8149at7088 Complete M17 0 1 +8150at7088 Complete M4 0 1 +8151at7088 Complete M12 0 1 +8153at7088 Complete M30 0 1 +8156at7088 Complete M22 0 1 +8166at7088 Complete M18 0 1 +8167at7088 Complete M15 0 1 +8171at7088 Complete M7 0 1 +8172at7088 Complete M20 0 1 +8174at7088 Complete M28 0 1 +8175at7088 Complete M27 0 1 +8177at7088 Complete M6 0 1 +817at7088 Complete M13 0 1 +8180at7088 Complete M4 0 1 +8182at7088 Complete M20 0 1 +8183at7088 Complete M22 0 1 +8185at7088 Complete M22 0 1 +8186at7088 Complete M13 0 1 +818at7088 Complete M13 0 1 +8190at7088 Complete M19 0 1 +8201at7088 Complete M3 0 1 +8204at7088 Complete M9 0 1 +8205at7088 Complete M12 0 1 +8211at7088 Complete M9 0 1 +8212at7088 Complete M1 0 1 +8214at7088 Complete M5 0 1 +8215at7088 Complete M21 0 1 +8217at7088 Complete M18 0 1 +8219at7088 Complete M2 0 1 +821at7088 Complete M8 0 1 +8222at7088 Complete M29 0 1 +822at7088 Complete MZ 0 1 +8235at7088 Complete M5 0 1 +8236at7088 Complete M2 0 1 +8238at7088 Complete M7 0 1 +8240at7088 Complete M23 0 1 +8247at7088 Complete M8 0 1 +8248at7088 Complete M17 0 1 +8254at7088 Complete M15 0 1 +8255at7088 Complete M8 0 1 +8258at7088 Complete M6 0 1 +8259at7088 Complete M4 0 1 +8264at7088 Complete M28 0 1 +826at7088 Complete M4 0 1 +8270at7088 Complete M18 0 1 +8271at7088 Complete M14 0 1 +8273at7088 Complete M6 0 1 +8274at7088 Complete M2 0 1 +8275at7088 Complete M9 0 1 +8276at7088 Complete M18 0 1 +8277at7088 Complete M2 0 1 +8280at7088 Complete M10 0 1 +8282at7088 Complete M10 0 1 +8286at7088 Complete M21 0 1 +828at7088 Complete M7 0 1 +8298at7088 Complete M3 0 1 +829at7088 Complete M15 0 1 +8300at7088 Complete M11 0 1 +8301at7088 Complete M8 0 1 +8306at7088 Complete M30 0 1 +8310at7088 Complete M17 0 1 +8312at7088 Complete M19 0 1 +8313at7088 Complete MZ 0 1 +8314at7088 Complete M2 0 1 +8317at7088 Complete M1 0 1 +8323at7088 Complete M17 0 1 +8324at7088 Complete M9 0 1 +8327at7088 Complete MZ 0 1 +8340at7088 Complete M5 0 1 +8342at7088 Complete M3 0 1 +8343at7088 Complete M10 0 1 +8344at7088 Complete M6 0 1 +8346at7088 Complete M17 0 1 +8352at7088 Complete M5 0 1 +8354at7088 Complete M29 0 1 +8356at7088 Complete M10 0 1 +8359at7088 Complete MZ 0 1 +835at7088 Complete M3 0 1 +8365at7088 Complete M6 0 1 +8367at7088 Complete M15 0 1 +8370at7088 Complete M6 0 1 +8371at7088 Complete M5 0 1 +8372at7088 Complete M2 0 1 +8373at7088 Complete M15 0 1 +8375at7088 Complete M15 0 1 +8377at7088 Complete MZ 0 1 +8380at7088 Complete M11 0 1 +8384at7088 Complete M20 0 1 +8385at7088 Complete M14 0 1 +8386at7088 Complete M9 0 1 +8388at7088 Complete M8 0 1 +8392at7088 Complete M17 0 1 +8393at7088 Complete M1 0 1 +8394at7088 Complete M12 0 1 +8396at7088 Complete M6 0 1 +839at7088 Complete M27 0 1 +83at7088 Complete M27 0 1 +8400at7088 Complete M9 0 1 +8402at7088 Complete M23 0 1 +8403at7088 Complete M24 0 1 +8406at7088 Complete M13 0 1 +8408at7088 Complete M21 0 1 +840at7088 Complete MZ 0 1 +8416at7088 Complete M9 0 1 +8418at7088 Complete M20 0 1 +841at7088 Complete M5 0 1 +8420at7088 Complete M10 0 1 +8426at7088 Complete M11 0 1 +8427at7088 Complete M2 0 1 +8432at7088 Complete M5 0 1 +8438at7088 Complete M15 0 1 +8440at7088 Complete M15 0 1 +8441at7088 Complete M7 0 1 +8443at7088 Complete M16 0 1 +844at7088 Complete M8 0 1 +8453at7088 Complete M17 0 1 +845at7088 Complete M10 0 1 +8464at7088 Complete M22 0 1 +8465at7088 Complete M16 0 1 +8467at7088 Complete M8 0 1 +8469at7088 Complete MZ 0 1 +8471at7088 Complete M6 0 1 +8476at7088 Complete M21 0 1 +8477at7088 Complete M10 0 1 +8479at7088 Complete M6 0 1 +8483at7088 Complete M2 0 1 +8484at7088 Complete M21 0 1 +8487at7088 Complete M10 0 1 +8491at7088 Complete M4 0 1 +8492at7088 Complete M30 0 1 +8493at7088 Complete M8 0 1 +849at7088 Complete M11 0 1 +84at7088 Complete M14 0 1 +8504at7088 Complete M13 0 1 +8509at7088 Complete M9 0 1 +8514at7088 Complete M4 0 1 +8515at7088 Complete M6 0 1 +8517at7088 Complete M15 0 1 +851at7088 Complete M16 0 1 +8521at7088 Complete M22 0 1 +8522at7088 Complete M16 0 1 +8524at7088 Complete M3 0 1 +8529at7088 Complete MZ 0 1 +8536at7088 Complete M5 0 1 +853at7088 Complete M3 0 1 +8549at7088 Complete M23 0 1 +8550at7088 Complete M5 0 1 +8553at7088 Complete M3 0 1 +8554at7088 Complete M8 0 1 +8559at7088 Complete M23 0 1 +8564at7088 Complete M19 0 1 +8570at7088 Complete M8 0 1 +8571at7088 Complete MZ 0 1 +8572at7088 Complete M17 0 1 +8578at7088 Complete M21 0 1 +8579at7088 Complete M22 0 1 +8582at7088 Complete M14 0 1 +8584at7088 Complete MZ 0 1 +8585at7088 Complete M14 0 1 +8586at7088 Complete M12 0 1 +8587at7088 Complete M18 0 1 +8591at7088 Complete M22 0 1 +8595at7088 Complete M8 0 1 +8596at7088 Complete M7 0 1 +8605at7088 Complete M15 0 1 +8607at7088 Complete M7 0 1 +860at7088 Complete M2 0 1 +8611at7088 Complete M20 0 1 +8612at7088 Complete M9 0 1 +8613at7088 Complete M8 0 1 +8615at7088 Complete M8 0 1 +8618at7088 Complete M24 0 1 +861at7088 Complete M23 0 1 +8620at7088 Complete M29 0 1 +8625at7088 Complete M1 0 1 +8628at7088 Complete M3 0 1 +8630at7088 Complete M9 0 1 +8633at7088 Complete M1 0 1 +8635at7088 Complete M6 0 1 +8636at7088 Complete M3 0 1 +8637at7088 Complete M18 0 1 +8638at7088 Complete M5 0 1 +8642at7088 Complete M5 0 1 +8643at7088 Complete M18 0 1 +8644at7088 Complete M10 0 1 +8650at7088 Complete M7 0 1 +8652at7088 Complete M16 0 1 +8653at7088 Complete M4 0 1 +8659at7088 Complete M15 0 1 +865at7088 Complete M25 0 1 +8665at7088 Complete M14 0 1 +8667at7088 Complete M19 0 1 +8669at7088 Complete M23 0 1 +866at7088 Complete M21 0 1 +8672at7088 Complete M14 0 1 +8673at7088 Complete M9 0 1 +867at7088 Complete M16 0 1 +8685at7088 Complete M1 0 1 +8691at7088 Complete M11 0 1 +8694at7088 Complete M11 0 1 +8696at7088 Complete M4 0 1 +8698at7088 Complete M7 0 1 +86at7088 Complete M8 0 1 +8700at7088 Complete M2 0 1 +8703at7088 Complete M7 0 1 +8708at7088 Complete M7 0 1 +8709at7088 Complete M24 0 1 +8710at7088 Complete M7 0 1 +8711at7088 Complete M22 0 1 +8712at7088 Complete MZ 0 1 +8715at7088 Complete M2 0 1 +8716at7088 Complete M14 0 1 +8718at7088 Complete M25 0 1 +8719at7088 Complete M8 0 1 +871at7088 Complete M17 0 1 +8724at7088 Complete M12 0 1 +8732at7088 Complete M21 0 1 +8733at7088 Complete MZ 0 1 +8735at7088 Complete M18 0 1 +8738at7088 Complete M7 0 1 +8739at7088 Complete M12 0 1 +8742at7088 Complete M2 0 1 +8745at7088 Complete M7 0 1 +8751at7088 Complete M3 0 1 +8753at7088 Complete M14 0 1 +8757at7088 Complete M20 0 1 +875at7088 Complete M7 0 1 +8760at7088 Complete M8 0 1 +8763at7088 Complete M8 0 1 +8764at7088 Complete M8 0 1 +8767at7088 Complete M11 0 1 +8769at7088 Complete M1 0 1 +8770at7088 Complete M5 0 1 +8777at7088 Complete M13 0 1 +8778at7088 Complete MZ 0 1 +8779at7088 Complete M3 0 1 +877at7088 Complete M26 0 1 +8781at7088 Complete M18 0 1 +8786at7088 Complete M3 0 1 +8787at7088 Complete M1 0 1 +8789at7088 Complete M3 0 1 +8793at7088 Complete MZ 0 1 +8794at7088 Complete M15 0 1 +8798at7088 Complete M10 0 1 +879at7088 Complete M20 0 1 +8804at7088 Complete M12 0 1 +8806at7088 Complete M19 0 1 +8807at7088 Complete M4 0 1 +8809at7088 Complete M26 0 1 +8811at7088 Complete M11 0 1 +8812at7088 Complete M8 0 1 +8817at7088 Complete M5 0 1 +8818at7088 Complete M1 0 1 +8819at7088 Complete M5 0 1 +8820at7088 Complete M6 0 1 +8829at7088 Complete M21 0 1 +8834at7088 Complete M23 0 1 +883at7088 Complete M7 0 1 +8841at7088 Complete M2 0 1 +8842at7088 Complete M3 0 1 +8846at7088 Complete M1 0 1 +8849at7088 Complete M9 0 1 +8854at7088 Complete M13 0 1 +8859at7088 Complete M26 0 1 +885at7088 Complete M1 0 1 +8860at7088 Complete M9 0 1 +8861at7088 Complete M18 0 1 +8862at7088 Complete M6 0 1 +8863at7088 Complete M17 0 1 +8864at7088 Complete M8 0 1 +886at7088 Complete M14 0 1 +8873at7088 Complete M20 0 1 +8874at7088 Complete M12 0 1 +8875at7088 Complete M3 0 1 +8877at7088 Complete M6 0 1 +8881at7088 Complete M16 0 1 +8882at7088 Complete MZ 0 1 +8885at7088 Complete M3 0 1 +8886at7088 Complete M1 0 1 +8890at7088 Complete M10 0 1 +8895at7088 Complete M9 0 1 +8896at7088 Complete M20 0 1 +8897at7088 Complete M14 0 1 +8898at7088 Complete M6 0 1 +88at7088 Complete M1 0 1 +8900at7088 Complete M11 0 1 +8901at7088 Complete M5 0 1 +8902at7088 Complete M21 0 1 +8908at7088 Complete M3 0 1 +890at7088 Complete M10 0 1 +8912at7088 Complete M2 0 1 +8914at7088 Complete M12 0 1 +8915at7088 Complete M3 0 1 +8916at7088 Complete M1 0 1 +8920at7088 Complete M8 0 1 +8923at7088 Complete M14 0 1 +8927at7088 Complete M3 0 1 +8928at7088 Complete MZ 0 1 +8930at7088 Complete M11 0 1 +8931at7088 Complete M21 0 1 +8934at7088 Complete M2 0 1 +8937at7088 Complete M6 0 1 +893at7088 Complete M4 0 1 +8946at7088 Complete M4 0 1 +8953at7088 Complete M6 0 1 +8954at7088 Complete M2 0 1 +8955at7088 Complete M21 0 1 +8957at7088 Complete M2 0 1 +895at7088 Complete M12 0 1 +8962at7088 Complete M9 0 1 +8967at7088 Complete M10 0 1 +8971at7088 Complete M8 0 1 +8973at7088 Complete M16 0 1 +8974at7088 Complete M5 0 1 +8976at7088 Complete M2 0 1 +8978at7088 Complete M11 0 1 +897at7088 Complete M4 0 1 +8981at7088 Complete M3 0 1 +8982at7088 Complete M11 0 1 +8984at7088 Complete M17 0 1 +8986at7088 Complete M2 0 1 +8988at7088 Complete M17 0 1 +8990at7088 Complete M9 0 1 +8993at7088 Complete M5 0 1 +8994at7088 Complete M26 0 1 +899at7088 Complete M6 0 1 +9004at7088 Complete M25 0 1 +9006at7088 Complete M1 0 1 +9012at7088 Complete M2 0 1 +901at7088 Complete M9 0 1 +9020at7088 Complete M22 0 1 +9021at7088 Complete M28 0 1 +9025at7088 Complete M1 0 1 +9031at7088 Complete M13 0 1 +9032at7088 Complete M22 0 1 +9036at7088 Complete M13 0 1 +903at7088 Complete M3 0 1 +9044at7088 Complete M3 0 1 +9047at7088 Complete M6 0 1 +9052at7088 Complete M21 0 1 +9053at7088 Complete M26 0 1 +9055at7088 Complete M11 0 1 +9056at7088 Complete M3 0 1 +9060at7088 Complete M20 0 1 +9061at7088 Complete M5 0 1 +9062at7088 Complete M10 0 1 +9067at7088 Complete M4 0 1 +9068at7088 Complete M23 0 1 +9069at7088 Complete M12 0 1 +9074at7088 Complete M15 0 1 +9081at7088 Complete M26 0 1 +9088at7088 Complete M26 0 1 +9098at7088 Complete M1 0 1 +9099at7088 Complete M6 0 1 +909at7088 Complete M13 0 1 +9101at7088 Complete MZ 0 1 +9102at7088 Complete M6 0 1 +9103at7088 Complete M10 0 1 +9106at7088 Complete M18 0 1 +9108at7088 Complete M3 0 1 +9113at7088 Complete M10 0 1 +9117at7088 Complete M1 0 1 +9119at7088 Complete M17 0 1 +911at7088 Complete M17 0 1 +9121at7088 Complete M29 0 1 +9123at7088 Complete M19 0 1 +9124at7088 Complete M1 0 1 +9125at7088 Complete M3 0 1 +9127at7088 Complete M4 0 1 +912at7088 Complete M26 0 1 +9131at7088 Complete M13 0 1 +9134at7088 Complete M18 0 1 +9135at7088 Complete M15 0 1 +9136at7088 Complete M2 0 1 +913at7088 Complete M10 0 1 +9142at7088 Complete M17 0 1 +9144at7088 Complete M27 0 1 +9145at7088 Complete M18 0 1 +9146at7088 Complete M14 0 1 +9149at7088 Complete M21 0 1 +9150at7088 Complete M5 0 1 +9155at7088 Complete MZ 0 1 +9162at7088 Complete M9 0 1 +9169at7088 Complete M5 0 1 +9171at7088 Complete M10 0 1 +9176at7088 Complete M26 0 1 +9179at7088 Complete MZ 0 1 +917at7088 Complete M11 0 1 +9180at7088 Complete M16 0 1 +9182at7088 Complete M21 0 1 +9185at7088 Complete M5 0 1 +9187at7088 Complete M13 0 1 +9188at7088 Complete M11 0 1 +9191at7088 Complete M4 0 1 +9194at7088 Complete M17 0 1 +9198at7088 Complete M16 0 1 +9200at7088 Complete M27 0 1 +9205at7088 Complete M2 0 1 +9209at7088 Complete M18 0 1 +9210at7088 Complete MZ 0 1 +9211at7088 Complete M13 0 1 +9213at7088 Complete M10 0 1 +9214at7088 Complete M20 0 1 +9216at7088 Complete M10 0 1 +9217at7088 Complete M20 0 1 +9218at7088 Complete M8 0 1 +9222at7088 Complete M6 0 1 +9224at7088 Complete M8 0 1 +9232at7088 Complete M5 0 1 +9236at7088 Complete M1 0 1 +9237at7088 Complete MZ 0 1 +9240at7088 Complete M11 0 1 +9241at7088 Complete M10 0 1 +9243at7088 Complete M7 0 1 +9246at7088 Complete M2 0 1 +924at7088 Complete M4 0 1 +9252at7088 Complete M25 0 1 +9254at7088 Complete M7 0 1 +9258at7088 Complete M23 0 1 +9260at7088 Complete M1 0 1 +9265at7088 Complete M13 0 1 +9271at7088 Complete M6 0 1 +9272at7088 Complete M24 0 1 +9274at7088 Complete M14 0 1 +9275at7088 Complete M21 0 1 +9276at7088 Complete M18 0 1 +9278at7088 Complete M7 0 1 +927at7088 Complete M8 0 1 +9282at7088 Complete M9 0 1 +9285at7088 Complete M14 0 1 +9286at7088 Complete M7 0 1 +9288at7088 Complete M3 0 1 +9289at7088 Complete M8 0 1 +9290at7088 Complete M19 0 1 +9292at7088 Complete M18 0 1 +9293at7088 Complete M22 0 1 +9294at7088 Complete M7 0 1 +9297at7088 Complete M24 0 1 +929at7088 Complete M3 0 1 +9301at7088 Complete M16 0 1 +9304at7088 Complete M7 0 1 +9309at7088 Complete MZ 0 1 +9316at7088 Complete M12 0 1 +9319at7088 Complete M22 0 1 +9322at7088 Complete M3 0 1 +9326at7088 Complete M8 0 1 +9331at7088 Complete M28 0 1 +9332at7088 Complete M11 0 1 +9333at7088 Complete M5 0 1 +9336at7088 Complete M13 0 1 +9337at7088 Complete M1 0 1 +9338at7088 Complete M8 0 1 +9339at7088 Complete M20 0 1 +933at7088 Complete M16 0 1 +9343at7088 Complete M17 0 1 +9345at7088 Complete M2 0 1 +934at7088 Complete M9 0 1 +9360at7088 Complete M13 0 1 +9362at7088 Complete M22 0 1 +9364at7088 Complete M7 0 1 +9365at7088 Complete M25 0 1 +9366at7088 Complete M16 0 1 +9367at7088 Complete M3 0 1 +9374at7088 Complete M22 0 1 +9380at7088 Complete M4 0 1 +9381at7088 Complete M16 0 1 +9386at7088 Complete M17 0 1 +9388at7088 Complete M6 0 1 +9389at7088 Complete M11 0 1 +938at7088 Complete M7 0 1 +9392at7088 Complete M11 0 1 +9395at7088 Complete M13 0 1 +9397at7088 Complete M12 0 1 +9401at7088 Complete M19 0 1 +9402at7088 Complete M5 0 1 +9409at7088 Complete M8 0 1 +9413at7088 Complete M16 0 1 +9417at7088 Complete M4 0 1 +9419at7088 Complete M8 0 1 +9430at7088 Complete M25 0 1 +9431at7088 Complete M7 0 1 +9432at7088 Complete M20 0 1 +9435at7088 Complete M13 0 1 +9436at7088 Complete M9 0 1 +9439at7088 Complete M19 0 1 +9441at7088 Complete M3 0 1 +9442at7088 Complete M12 0 1 +9443at7088 Complete M14 0 1 +9448at7088 Complete M14 0 1 +944at7088 Complete M11 0 1 +9451at7088 Complete M11 0 1 +9452at7088 Complete M19 0 1 +9458at7088 Complete M15 0 1 +9465at7088 Complete M27 0 1 +9468at7088 Complete M23 0 1 +946at7088 Complete M20 0 1 +9470at7088 Complete M4 0 1 +9472at7088 Complete M27 0 1 +9475at7088 Complete M10 0 1 +9477at7088 Complete M24 0 1 +947at7088 Complete M1 0 1 +9480at7088 Complete M3 0 1 +9481at7088 Complete M1 0 1 +9492at7088 Complete M11 0 1 +9494at7088 Complete M29 0 1 +949at7088 Complete M7 0 1 +9503at7088 Complete M8 0 1 +9505at7088 Complete M9 0 1 +9506at7088 Complete M7 0 1 +950at7088 Complete M8 0 1 +9511at7088 Complete M2 0 1 +9513at7088 Complete M18 0 1 +9515at7088 Complete M19 0 1 +9517at7088 Complete M29 0 1 +9518at7088 Complete M20 0 1 +9519at7088 Complete M9 0 1 +951at7088 Complete M13 0 1 +9521at7088 Complete M2 0 1 +9524at7088 Complete M23 0 1 +9526at7088 Complete MZ 0 1 +9527at7088 Complete M7 0 1 +9528at7088 Complete M2 0 1 +9533at7088 Complete M1 0 1 +9534at7088 Complete M1 0 1 +9535at7088 Complete M10 0 1 +9543at7088 Complete M12 0 1 +9544at7088 Complete M16 0 1 +9548at7088 Complete M3 0 1 +9549at7088 Complete M13 0 1 +954at7088 Complete M19 0 1 +9554at7088 Complete M2 0 1 +9556at7088 Complete M29 0 1 +9559at7088 Complete M20 0 1 +9563at7088 Complete M18 0 1 +9564at7088 Complete M19 0 1 +9567at7088 Complete M11 0 1 +9568at7088 Complete M17 0 1 +9571at7088 Complete M2 0 1 +9575at7088 Complete M23 0 1 +9576at7088 Complete M21 0 1 +9577at7088 Complete M7 0 1 +9580at7088 Complete M4 0 1 +9582at7088 Complete M12 0 1 +9595at7088 Complete M3 0 1 +9597at7088 Complete M4 0 1 +9598at7088 Complete M2 0 1 +9601at7088 Complete M10 0 1 +9603at7088 Complete M22 0 1 +9604at7088 Complete M6 0 1 +9609at7088 Complete MZ 0 1 +9611at7088 Complete M20 0 1 +9618at7088 Complete M4 0 1 +9619at7088 Complete M3 0 1 +961at7088 Complete M3 0 1 +9623at7088 Complete M10 0 1 +9628at7088 Complete M10 0 1 +962at7088 Complete M16 0 1 +9630at7088 Complete M3 0 1 +9631at7088 Complete M19 0 1 +9638at7088 Complete M11 0 1 +963at7088 Complete M7 0 1 +9640at7088 Complete M5 0 1 +9647at7088 Complete M4 0 1 +9648at7088 Complete M9 0 1 +964at7088 Complete M1 0 1 +9651at7088 Complete M2 0 1 +9655at7088 Complete M27 0 1 +9656at7088 Complete M23 0 1 +9657at7088 Complete M13 0 1 +9662at7088 Complete MZ 0 1 +9663at7088 Complete M23 0 1 +9665at7088 Complete M3 0 1 +9666at7088 Complete M14 0 1 +9669at7088 Complete M26 0 1 +966at7088 Complete M10 0 1 +9680at7088 Complete M4 0 1 +9682at7088 Complete M22 0 1 +9688at7088 Complete M16 0 1 +9689at7088 Complete M16 0 1 +968at7088 Complete M13 0 1 +9693at7088 Complete M22 0 1 +9694at7088 Complete M27 0 1 +9695at7088 Complete M1 0 1 +9698at7088 Complete M23 0 1 +9699at7088 Complete M12 0 1 +96at7088 Complete MZ 0 1 +9701at7088 Complete M15 0 1 +9709at7088 Complete M15 0 1 +9710at7088 Complete M21 0 1 +9711at7088 Complete M1 0 1 +9713at7088 Complete M11 0 1 +9715at7088 Complete M13 0 1 +9721at7088 Complete MZ 0 1 +9722at7088 Complete M8 0 1 +9724at7088 Complete M19 0 1 +9729at7088 Complete M9 0 1 +972at7088 Complete M9 0 1 +9730at7088 Complete M1 0 1 +9731at7088 Complete M5 0 1 +9737at7088 Complete M2 0 1 +9739at7088 Complete M10 0 1 +9745at7088 Complete M2 0 1 +9748at7088 Complete M9 0 1 +9749at7088 Complete M7 0 1 +974at7088 Complete M25 0 1 +9750at7088 Complete M2 0 1 +9752at7088 Complete M15 0 1 +9755at7088 Complete M29 0 1 +9759at7088 Complete M1 0 1 +975at7088 Complete MZ 0 1 +9760at7088 Complete M20 0 1 +9765at7088 Complete M24 0 1 +9768at7088 Complete MZ 0 1 +9770at7088 Complete M6 0 1 +9775at7088 Complete M14 0 1 +9777at7088 Complete M6 0 1 +9780at7088 Complete M6 0 1 +9781at7088 Complete M3 0 1 +9782at7088 Complete M2 0 1 +9784at7088 Complete M8 0 1 +9785at7088 Complete M15 0 1 +9788at7088 Complete M14 0 1 +978at7088 Complete M10 0 1 +9790at7088 Complete M23 0 1 +9791at7088 Complete M7 0 1 +9793at7088 Complete MZ 0 1 +979at7088 Complete M18 0 1 +9800at7088 Complete M7 0 1 +9802at7088 Complete M25 0 1 +9803at7088 Complete M1 0 1 +9807at7088 Complete M8 0 1 +9809at7088 Complete M23 0 1 +980at7088 Complete M15 0 1 +9810at7088 Complete M6 0 1 +9817at7088 Complete M5 0 1 +9818at7088 Complete M3 0 1 +9819at7088 Complete M13 0 1 +981at7088 Complete M4 0 1 +9820at7088 Complete M21 0 1 +9824at7088 Complete M6 0 1 +9825at7088 Complete M12 0 1 +9828at7088 Complete M18 0 1 +982at7088 Complete M25 0 1 +9830at7088 Complete M9 0 1 +9835at7088 Complete M2 0 1 +9836at7088 Complete M3 0 1 +9837at7088 Complete M13 0 1 +9839at7088 Complete M26 0 1 +983at7088 Complete M8 0 1 +9840at7088 Complete M5 0 1 +9846at7088 Complete M13 0 1 +9847at7088 Complete M16 0 1 +9848at7088 Complete M13 0 1 +984at7088 Complete M8 0 1 +9850at7088 Complete M28 0 1 +9860at7088 Complete M14 0 1 +9861at7088 Complete M14 0 1 +9862at7088 Complete M5 0 1 +9864at7088 Complete M19 0 1 +9865at7088 Complete M1 0 1 +9866at7088 Complete M3 0 1 +9867at7088 Complete M7 0 1 +986at7088 Complete M7 0 1 +9871at7088 Complete M10 0 1 +9874at7088 Complete M10 0 1 +9878at7088 Complete M23 0 1 +9881at7088 Complete M5 0 1 +9884at7088 Complete M1 0 1 +9885at7088 Complete M16 0 1 +988at7088 Complete M1 0 1 +9890at7088 Complete M29 0 1 +9891at7088 Complete M16 0 1 +9896at7088 Complete M14 0 1 +9897at7088 Complete M3 0 1 +9899at7088 Complete M13 0 1 +989at7088 Complete M10 0 1 +9900at7088 Complete M9 0 1 +9903at7088 Complete M3 0 1 +9904at7088 Complete M11 0 1 +9911at7088 Complete M19 0 1 +9914at7088 Complete M5 0 1 +9918at7088 Complete M26 0 1 +9926at7088 Complete M11 0 1 +9927at7088 Complete M25 0 1 +992at7088 Complete M20 0 1 +9931at7088 Complete M16 0 1 +9935at7088 Complete M1 0 1 +993at7088 Complete M19 0 1 +9943at7088 Complete M18 0 1 +9947at7088 Complete M25 0 1 +9949at7088 Complete M2 0 1 +994at7088 Complete M17 0 1 +9952at7088 Complete M2 0 1 +9956at7088 Complete M8 0 1 +9957at7088 Complete M5 0 1 +9960at7088 Complete M28 0 1 +9962at7088 Complete M17 0 1 +9965at7088 Complete M11 0 1 +9967at7088 Complete M4 0 1 +9976at7088 Complete M1 0 1 +9977at7088 Complete M17 0 1 +9978at7088 Complete M14 0 1 +9981at7088 Complete M15 0 1 +9985at7088 Complete M26 0 1 +9987at7088 Complete M12 0 1 +998at7088 Complete M2 0 1 +9990at7088 Complete M4 0 1 +9992at7088 Complete M8 0 1 +9999at7088 Complete M26 0 1 +999at7088 Complete M23 0 1 diff --git a/assets/digest/digest.as b/assets/digest/digest.as old mode 100644 new mode 100755 index 5ded115f..5b6272fa --- a/assets/digest/digest.as +++ b/assets/digest/digest.as @@ -1,9 +1,9 @@ table insilico_digest "bionano digest cut sites" ( -string chrom; "Reference sequence chromosome or scaffold" -uint chromStart; "Start position of feature on chromosome" -uint chromEnd; "End position of feature on chromosome" -string name; "Name of enzyme" -string length; "length of fragment" +string chrom; "Reference sequence chromosome or scaffold" +uint chromStart; "Start position of feature on chromosome" +uint chromEnd; "End position of feature on chromosome" +string name; "Name of enzyme" +string length; "length of fragment" ) diff --git a/assets/email_template.html b/assets/email_template.html index 30814217..6d58d16e 100644 --- a/assets/email_template.html +++ b/assets/email_template.html @@ -4,21 +4,21 @@ - - nf-core/treeval Pipeline Report + + sanger-tol/treeval Pipeline Report
-

nf-core/treeval v${version}

+

sanger-tol/treeval v${version}

Run Name: $runName

<% if (!success){ out << """
-

nf-core/treeval execution completed unsuccessfully!

+

sanger-tol/treeval execution completed unsuccessfully!

The exit status of the task that caused the workflow execution to fail was: $exitStatus.

The full error message was:

${errorReport}
@@ -27,7 +27,7 @@

nf-core/treeval execution completed un } else { out << """
- nf-core/treeval execution completed successfully! + sanger-tol/treeval execution completed successfully!
""" } @@ -44,8 +44,8 @@

Pipeline Configuration:

-

nf-core/treeval

-

https://github.com/nf-core/treeval

+

sanger-tol/treeval

+

https://github.com/sanger-tol/treeval

diff --git a/assets/email_template.txt b/assets/email_template.txt index 2470f97d..fc03acac 100644 --- a/assets/email_template.txt +++ b/assets/email_template.txt @@ -1,19 +1,10 @@ ----------------------------------------------------- - ,--./,-. - ___ __ __ __ ___ /,-._.--~\\ - |\\ | |__ __ / ` / \\ |__) |__ } { - | \\| | \\__, \\__/ | \\ |___ \\`-._,-`-, - `._,._,' - nf-core/treeval v${version} ----------------------------------------------------- - Run Name: $runName <% if (success){ - out << "## nf-core/treeval execution completed successfully! ##" + out << "## sanger-tol/treeval execution completed successfully! ##" } else { out << """#################################################### -## nf-core/treeval execution completed unsuccessfully! ## +## sanger-tol/treeval execution completed unsuccessfully! ## #################################################### The exit status of the task that caused the workflow execution to fail was: $exitStatus. The full error message was: @@ -36,5 +27,5 @@ Pipeline Configuration: <% out << summary.collect{ k,v -> " - $k: $v" }.join("\n") %> -- -nf-core/treeval -https://github.com/nf-core/treeval +sanger-tol/treeval +https://github.com/sanger-tol/treeval diff --git a/assets/gene_alignment/assm_cdna.as b/assets/gene_alignment/assm_cdna.as old mode 100644 new mode 100755 index f8e7afbe..30552cc5 --- a/assets/gene_alignment/assm_cdna.as +++ b/assets/gene_alignment/assm_cdna.as @@ -8,5 +8,5 @@ string name; "Name of gene" uint score; "Score" char[1] strand; "+ or - for strand" string geneSymbol; "Gene Symbol" -string ensemblId; "Ensembl Accession number" +string ensemblId; "Ensembl Accession number" ) diff --git a/assets/gene_alignment/assm_cds.as b/assets/gene_alignment/assm_cds.as old mode 100644 new mode 100755 index 63002786..4306c459 --- a/assets/gene_alignment/assm_cds.as +++ b/assets/gene_alignment/assm_cds.as @@ -8,5 +8,5 @@ string name; "Name of gene" uint score; "Score" char[1] strand; "+ or - for strand" string geneSymbol; "Gene Symbol" -string ensemblId; "Ensembl Accession number" +string ensemblId; "Ensembl Accession number" ) diff --git a/assets/gene_alignment/assm_pep.as b/assets/gene_alignment/assm_pep.as old mode 100644 new mode 100755 index a63070c7..40b8701f --- a/assets/gene_alignment/assm_pep.as +++ b/assets/gene_alignment/assm_pep.as @@ -8,5 +8,5 @@ string name; "Name of gene" uint score; "Score" char[1] strand; "+ or - for strand" string geneSymbol; "Gene Symbol" -string ensemblId; "Ensembl Accession number" +string ensemblId; "Ensembl Accession number" ) diff --git a/assets/gene_alignment/assm_rna.as b/assets/gene_alignment/assm_rna.as old mode 100644 new mode 100755 index 9edf6cbd..f28bdf37 --- a/assets/gene_alignment/assm_rna.as +++ b/assets/gene_alignment/assm_rna.as @@ -8,5 +8,5 @@ string name; "Name of gene" uint score; "Score" char[1] strand; "+ or - for strand" string geneSymbol; "Gene Symbol" -string ensemblId; "Ensembl Accession number" +string ensemblId; "Ensembl Accession number" ) diff --git a/assets/github_testing/TreeValTinyTest.yaml b/assets/github_testing/TreeValTinyTest.yaml new file mode 100755 index 00000000..d9152241 --- /dev/null +++ b/assets/github_testing/TreeValTinyTest.yaml @@ -0,0 +1,31 @@ +assembly: + level: scaffold + sample_id: grTriPseu1 + latin_name: to_provide_taxonomic_rank + classT: fungi + asmVersion: 1 + dbVersion: "1" + gevalType: DTOL +reference_file: /home/runner/work/treeval/treeval/TreeValTinyData/assembly/draft/grTriPseu1.fa +assem_reads: + pacbio: /home/runner/work/treeval/treeval/TreeValTinyData/genomic_data/pacbio/ + hic: /home/runner/work/treeval/treeval/TreeValTinyData/genomic_data/hic-arima/ + supplementary: path +alignment: + data_dir: /home/runner/work/treeval/treeval/TreeValTinyData/gene_alignment_data/ + common_name: "" # For future implementation (adding bee, wasp, ant etc) + geneset: "LaetiporusSulphureus.gfLaeSulp1" + #Path should end up looking like "{data_dir}{classT}/{common_name}/csv_data/{geneset}-data.csv" +self_comp: + motif_len: 0 + mummer_chunk: 10 +synteny: + synteny_genome_path: /home/runner/work/treeval/treeval/TreeValTinyData/synteny/ +outdir: "NEEDS TESTING" +intron: + size: "50k" +telomere: + teloseq: TTAGGG +busco: + lineages_path: /home/runner/work/treeval/treeval/TreeValTinyData/busco/subset/ + lineage: fungi_odb10 diff --git a/assets/local_testing/nxOscDF5033-BGA.yaml b/assets/local_testing/nxOscDF5033-BGA.yaml new file mode 100755 index 00000000..ecb2ff1a --- /dev/null +++ b/assets/local_testing/nxOscDF5033-BGA.yaml @@ -0,0 +1,26 @@ +assembly: + sample_id: Oscheius_DF5033 + latin_name: to_provide_taxonomic_rank # Not currently in use + classT: nematode + asmVersion: 1 + gevalType: DTOL +reference_file: /workspace/treeval-curation/Oscheius_DF5033/genomic_data/Oscheius_DF5033.fa +assem_reads: + pacbio: /workspace/treeval-curation/Oscheius_DF5033/pacbio/ + hic: /workspace/treeval-curation/Oscheius_DF5033/hic-arima2/ + supplementary: path # Not currently in use +alignment: + data_dir: /workspace/treeval-curation/gene_alignment_data/ + geneset: "OscheiusTipulae.ASM1342590v1,CaenorhabditisElegans.WBcel235,Gae_host.Gae" +self_comp: + motif_len: 0 + mummer_chunk: 10 +intron: + size: "50k" +telomere: + teloseq: TTAGGG +synteny: + synteny_genome_path: /workspace/treeval-curation/synteny/ # Will not exist +busco: + lineages_path: /workspace/treeval-curation/busco/v5 + lineage: nematoda_odb10 diff --git a/assets/local_testing/nxOscDF5033.yaml b/assets/local_testing/nxOscDF5033.yaml new file mode 100755 index 00000000..86ac7182 --- /dev/null +++ b/assets/local_testing/nxOscDF5033.yaml @@ -0,0 +1,29 @@ +assembly: + level: scaffold + sample_id: Oscheius_DF5033 + latin_name: to_provide_taxonomic_rank + classT: nematode + asmVersion: 1 + gevalType: DTOL +reference_file: /lustre/scratch123/tol/resources/treeval/treeval-testdata/TreeValSmallData/Oscheius_DF5033/assembly/draft/DF5033.hifiasm.noTelos.20211120/DF5033.noTelos.hifiasm.purged.noCont.noMito.fasta +assem_reads: + pacbio: /lustre/scratch123/tol/resources/treeval/treeval-testdata/TreeValSmallData/Oscheius_DF5033/genomic_data/nxOscSpes1/pacbio/fasta/ + hic: /lustre/scratch123/tol/resources/treeval/treeval-testdata/TreeValSmallData/Oscheius_DF5033/genomic_data/nxOscSpes1/hic-arima2/full/ + supplementary: path +alignment: + data_dir: /lustre/scratch123/tol/resources/treeval/gene_alignment_data/ + common_name: "" # For future implementation (adding bee, wasp, ant etc) + geneset: "OscheiusTipulae.ASM1342590v1,CaenorhabditisElegans.WBcel235,Gae_host.Gae" + #Path should end up looking like "{data_dir}{classT}/{common_name}/csv_data/{geneset}-data.csv" +self_comp: + motif_len: 0 + mummer_chunk: 10 +intron: + size: "50k" +telomere: + teloseq: TTAGGG +synteny: + synteny_genome_path: /lustre/scratch123/tol/resources/treeval/synteny/ +busco: + lineages_path: /lustre/scratch123/tol/resources/busco/v5 + lineage: nematoda_odb10 diff --git a/assets/local_testing/nxOscSUBSET.yaml b/assets/local_testing/nxOscSUBSET.yaml new file mode 100755 index 00000000..7f7fab4c --- /dev/null +++ b/assets/local_testing/nxOscSUBSET.yaml @@ -0,0 +1,30 @@ +assembly: + level: scaffold + sample_id: OscheiusSUBSET + latin_name: to_provide_taxonomic_rank + classT: nematode + asmVersion: 1 + gevalType: DTOL +reference_file: /lustre/scratch123/tol/resources/treeval/treeval-testdata/TreeValSmallData/Oscheius_SUBSET/assembly/draft/SUBSET_genome/Oscheius_SUBSET.fasta +#/lustre/scratch123/tol/resources/treeval/nextflow_test_data/Oscheius_DF5033/assembly/draft/DF5033.hifiasm.noTelos.20211120/DF5033.noTelos.hifiasm.purged.noCont.noMito.fasta +assem_reads: + pacbio: /lustre/scratch123/tol/resources/treeval/treeval-testdata/TreeValSmallData/Oscheius_SUBSET/genomic_data/pacbio/ + hic: /lustre/scratch123/tol/resources/treeval/treeval-testdata/TreeValSmallData/Oscheius_DF5033/genomic_data/nxOscSpes1/hic-arima2/subset/ + supplementary: path +alignment: + data_dir: /lustre/scratch123/tol/resources/treeval/gene_alignment_data/ + common_name: "" # For future implementation (adding bee, wasp, ant etc) + geneset: "Gae_host.Gae" + #Path should end up looking like "{data_dir}{classT}/{common_name}/csv_data/{geneset}-data.csv" +self_comp: + motif_len: 0 + mummer_chunk: 4 +intron: + size: "50k" +telomere: + teloseq: TTAGGG +synteny: + synteny_genome_path: /lustre/scratch123/tol/resources/treeval/synteny/ +busco: + lineages_path: /lustre/scratch123/tol/resources/busco/v5 + lineage: nematoda_odb10 diff --git a/assets/methods_description_template.yml b/assets/methods_description_template.yml new file mode 100755 index 00000000..6a3f02fd --- /dev/null +++ b/assets/methods_description_template.yml @@ -0,0 +1,25 @@ +id: "sanger-tol-treeval-methods-description" +description: "Suggested text and references to use when describing pipeline usage within the methods section of a publication." +section_name: "sanger-tol/treeval Methods Description" +section_href: "https://github.com/sanger-tol/treeval" +plot_type: "html" +## TODO nf-core: Update the HTML below to your prefered methods description, e.g. add publication citation for this pipeline +## You inject any metadata in the Nextflow '${workflow}' object +data: | +

Methods

+

Data was processed using sanger-tol/treeval v${workflow.manifest.version} ${doi_text} of the sanger-tol collection of workflows, created using nf-core (Ewels et al., 2020).

+

The pipeline was executed with Nextflow v${workflow.nextflow.version} (Di Tommaso et al., 2017) with the following command:

+
${workflow.commandLine}
+

References

+
    +
  • Di Tommaso, P., Chatzou, M., Floden, E. W., Barja, P. P., Palumbo, E., & Notredame, C. (2017). Nextflow enables reproducible computational workflows. Nature Biotechnology, 35(4), 316-319. https://doi.org/10.1038/nbt.3820
  • +
  • Ewels, P. A., Peltzer, A., Fillinger, S., Patel, H., Alneberg, J., Wilm, A., Garcia, M. U., Di Tommaso, P., & Nahnsen, S. (2020). The nf-core framework for community-curated bioinformatics pipelines. Nature Biotechnology, 38(3), 276-278. https://doi.org/10.1038/s41587-020-0439-x
  • +
+
+
Notes:
+
    + ${nodoi_text} +
  • The command above does not include parameters contained in any configs or profiles that may have been used. Ensure the config file is also uploaded with your publication!
  • +
  • You should also cite all software used within this run. Check the "Software Versions" of this report to get version information.
  • +
+
diff --git a/assets/multiqc_config.yml b/assets/multiqc_config.yml new file mode 100755 index 00000000..e68a4f0a --- /dev/null +++ b/assets/multiqc_config.yml @@ -0,0 +1,12 @@ +report_comment: > + This report has been generated by the sanger-tol/treeval + analysis pipeline. +report_section_order: + "sanger-tol-treeval-methods-description": + order: -1000 + software_versions: + order: -1001 + "sanger-tol-treeval-summary": + order: -1002 + +export_plots: true diff --git a/assets/nematode/csv_data/s3_Gae_Host.Gae-data.csv b/assets/nematode/csv_data/s3_Gae_Host.Gae-data.csv new file mode 100755 index 00000000..dca2b3dd --- /dev/null +++ b/assets/nematode/csv_data/s3_Gae_Host.Gae-data.csv @@ -0,0 +1,5 @@ +org, type, data_file +Gae_host.Gae, cdna, https://tolit.cog.sanger.ac.uk/test-data/Gae_host/genomic_data/gene_alignment/Gae_host5000cdna.MOD.fa +Gae_host.Gae, cds, https://tolit.cog.sanger.ac.uk/test-data/Gae_host/genomic_data/gene_alignment/Gae_host12003cds.MOD.fa +Gae_host.Gae, pep, https://tolit.cog.sanger.ac.uk/test-data/Gae_host/genomic_data/gene_alignment/Gae_host12005pep.MOD.fa +Gae_host.Gae, rna, https://tolit.cog.sanger.ac.uk/test-data/Gae_host/genomic_data/gene_alignment/Gae_host18005rna.MOD.fa diff --git a/assets/nf-core-treeval_logo_light.png b/assets/nf-core-treeval_logo_light.png deleted file mode 100644 index 074f9c6a..00000000 Binary files a/assets/nf-core-treeval_logo_light.png and /dev/null differ diff --git a/assets/samplesheet.csv b/assets/samplesheet.csv deleted file mode 100644 index 5f653ab7..00000000 --- a/assets/samplesheet.csv +++ /dev/null @@ -1,3 +0,0 @@ -sample,fastq_1,fastq_2 -SAMPLE_PAIRED_END,/path/to/fastq/files/AEG588A1_S1_L002_R1_001.fastq.gz,/path/to/fastq/files/AEG588A1_S1_L002_R2_001.fastq.gz -SAMPLE_SINGLE_END,/path/to/fastq/files/AEG588A4_S4_L003_R1_001.fastq.gz, diff --git a/assets/schema_input.json b/assets/schema_input.json old mode 100644 new mode 100755 index 97cc8f59..5b387a7d --- a/assets/schema_input.json +++ b/assets/schema_input.json @@ -1,36 +1,140 @@ { "$schema": "http://json-schema.org/draft-07/schema", - "$id": "https://raw.githubusercontent.com/nf-core/treeval/master/assets/schema_input.json", - "title": "nf-core/treeval pipeline - params.input schema", + "$id": "https://raw.githubusercontent.com/sanger-tol/treeval/master/assets/schema_input.json", + "title": "sanger-tol/treeval pipeline - params.input schema", "description": "Schema for the file provided with params.input", "type": "array", "items": { "type": "object", "properties": { - "sample": { + "assembly": { + "type": "object", + "properties": { + "sample_id": { + "type": "string", + "errorMessage": "Sample name must be provided and cannot contain spaces" + }, + "latin_name": { + "type": "string", + "errorMessage": "The scientific name for the assembly" + }, + "classT": { + "type": "string", + "errorMessage": "The Clade of the assembly. Used as the syntenic group and to complete the gene_alignment data dir." + }, + "TicketType": { + "type": "string", + "errorMessage": "Not currently in use. Single word description of associated project." + } + } + }, + "reference_file": { "type": "string", - "pattern": "^\\S+$", - "errorMessage": "Sample name must be provided and cannot contain spaces" + "pattern": "^\\S+\\.f(ast)a$", + "errorMessage": "Assembly input file, decompressed" }, - "fastq_1": { + "assem_reads": { + "type": "object", + "properties": { + "pacbio": { + "type": "string", + "errorMessage": "Path to folder containing fasta.gz files" + }, + "hic": { + "type": "string", + "errorMessage": "Path to folder containing .cram and .crai files" + }, + "supplementary": { + "type": "string", + "errorMessage": "Not currently in use. Placeholder for future use" + } + } + }, + "alignment": { + "type": "object", + "properties": { + "data_dir": { + "type": "string", + "errorMessage": "Gene Alignment data directory" + }, + "common_name": { + "type": "string", + "errorMessage": "Not currently in use. Common identifier for group (adding bee, wasp, ant as sub division for clade)" + }, + "geneset": { + "type": "string", + "errorMessage": "A csv list of organisms to run against." + } + } + }, + "self_comp": { + "type": "object", + "properties": { + "motif_len": { + "type": "integer", + "errorMessage": "Length of motif to be used in self comp search" + }, + "mummer_chunk": { + "type": "integer", + "errorMessage": "Size of chunks to be used my Mummer" + } + } + }, + "synteny": { + "type": "object", + "properties": { + "synteny_genome_path": { + "type": "string", + "errorMessage": "Syntenic Genome Directory Path" + } + } + }, + "outdir": { "type": "string", - "pattern": "^\\S+\\.f(ast)?q\\.gz$", - "errorMessage": "FastQ file for reads 1 must be provided, cannot contain spaces and must have extension '.fq.gz' or '.fastq.gz'" + "errorMessage": "Out directory path, can be changed via cli" + }, + "intron": { + "type": "object", + "properties": { + "size": { + "type": "string", + "errorMessage": "Base pair size of introns, defaults to 50k" + } + } + }, + "telomere": { + "type": "object", + "properties": { + "teloseq": { + "type": "string", + "errorMessage": "Expected telomeric motif" + } + } }, - "fastq_2": { - "errorMessage": "FastQ file for reads 2 cannot contain spaces and must have extension '.fq.gz' or '.fastq.gz'", - "anyOf": [ - { + "busco": { + "type": "object", + "properties": { + "lineage_path": { "type": "string", - "pattern": "^\\S+\\.f(ast)?q\\.gz$" + "errorMessage": "Path to directory containing lineages folder" }, - { + "lineage": { "type": "string", - "maxLength": 0 + "errorMessage": "busco lineage to run" } - ] + } } }, - "required": ["sample", "fastq_1"] + "required": [ + "busco", + "telomere", + "intron", + "synteny", + "self_comp", + "alignment", + "assem_reads", + "reference_file", + "assembly" + ] } } diff --git a/assets/self_comp/selfcomp.as b/assets/self_comp/selfcomp.as old mode 100644 new mode 100755 index f8a534d5..67f8cdc3 --- a/assets/self_comp/selfcomp.as +++ b/assets/self_comp/selfcomp.as @@ -4,10 +4,7 @@ table selfcomp string chrom; "Reference sequence chromosome or scaffold id" uint chromStart; "Start position of feature on chromosome" uint chromEnd; "End position of feature on chromosome" -string name; "Querysequence chromosome or scaffold id" -string length; "Length of the motif" -char[1] strand; "+ or - for strand of query seq" -string qStart; "Start position of feature on query sequence" -string qEnd; "End position of feature on query sequence" -string qLength; "Length of feature on query sequence" +string qName; "Query sequence chromosome or scaffold id" +string qStart; "Start position of feature on query sequence" +string qEnd; "End position of feature on query sequence" ) diff --git a/assets/sendmail_template.txt b/assets/sendmail_template.txt old mode 100644 new mode 100755 index 3fee99f5..3d299c57 --- a/assets/sendmail_template.txt +++ b/assets/sendmail_template.txt @@ -9,12 +9,12 @@ Content-Type: text/html; charset=utf-8 $email_html --nfcoremimeboundary -Content-Type: image/png;name="nf-core-treeval_logo.png" +Content-Type: image/png;name="sanger-tol-treeval_logo.png" Content-Transfer-Encoding: base64 Content-ID: -Content-Disposition: inline; filename="nf-core-treeval_logo_light.png" +Content-Disposition: inline; filename="sanger-tol-treeval_logo_light.png" -<% out << new File("$projectDir/assets/nf-core-treeval_logo_light.png"). +<% out << new File("$projectDir/treeval/docs/images/nf-core-treeval_logo_light.png"). bytes. encodeBase64(). toString(). @@ -26,7 +26,7 @@ Content-Disposition: inline; filename="nf-core-treeval_logo_light.png" join( '\n' ) %> <% -if (mqcFile){ +if ( mqcFile ){ def mqcFileObj = new File("$mqcFile") if (mqcFileObj.length() < mqcMaxSize){ out << """ diff --git a/assets/slackreport.json b/assets/slackreport.json new file mode 100755 index 00000000..bdc3b859 --- /dev/null +++ b/assets/slackreport.json @@ -0,0 +1,34 @@ +{ + "attachments": [ + { + "fallback": "Plain-text summary of the attachment.", + "color": "<% if ( success ) { %>good<% } else { %>danger<%} %>", + "author_name": "sanger-tol/treeval v${version} - ${runName}", + "author_icon": "https://www.nextflow.io/docs/latest/_static/favicon.ico", + "text": "<% if (success) { %>Pipeline completed successfully!<% } else { %>Pipeline completed with errors<% } %>", + "fields": [ + { + "title": "Command used to launch the workflow", + "value": "```${commandLine}```", + "short": false + } + <% + if (!success) { %> + , + { + "title": "Full error message", + "value": "```${errorReport}```", + "short": false + }, + { + "title": "Pipeline configuration", + "value": "<% out << summary.collect{ k,v -> k == "hook_url" ? "_${k}_: (_hidden_)" : ( ( v.class.toString().contains('Path') || ( v.class.toString().contains('String') && v.contains('/') ) ) ? "_${k}_: `${v}`" : (v.class.toString().contains('DateTime') ? ("_${k}_: " + v.format(java.time.format.DateTimeFormatter.ofLocalizedDateTime(java.time.format.FormatStyle.MEDIUM))) : "_${k}_: ${v}") ) }.join(",\n") %>", + "short": false + } + <% } + %> + ], + "footer": "Completed at <% out << dateComplete.format(java.time.format.DateTimeFormatter.ofLocalizedDateTime(java.time.format.FormatStyle.MEDIUM)) %> (duration: ${duration})" + } + ] +} diff --git a/assets/treeval_test.yaml b/assets/treeval_test.yaml deleted file mode 100644 index 9f4276f6..00000000 --- a/assets/treeval_test.yaml +++ /dev/null @@ -1,25 +0,0 @@ -assembly: - sizeClass: '' # S if {genome => 4Gb} else L - level: scaffold - sample_id: nxOscDoli1 - classT: nematode - asmVersion: PB.a1 - dbVersion: "1" - gevalType: DTOL -reference_file: /lustre/scratch123/tol/teams/grit/geval_pipeline/geval_runs/DTOL/nxOscDoli1_1/data/DTOL_nxOscDoli1_1_FULL.fa -assembly_reads: - pacbio: path - hic: path - supplementary: path|na -alignment: - data_dir: /nfs/team135/dp24/treeval_testdata/gene_alignment_data/ - common_name: "" # For future implementation (adding bee, wasp, ant etc) - geneset: "Gae_host.Gae,CSKR_v2.CSKR" - #Path should end up looking like "{data_dir}{classT}/{common_name}/csv_data/{geneset}-data.csv" -self_comp: - motif_len: 0 - mummer_chunk: 10 -synteny: - synteny_genome_path: "/nfs/team135/dp24/treeval_testdata/synteny_data" -outdir: "NEEDS TESTING" -intron: "50k" \ No newline at end of file diff --git a/bin/assign_anc.py b/bin/assign_anc.py new file mode 100755 index 00000000..413abca6 --- /dev/null +++ b/bin/assign_anc.py @@ -0,0 +1,68 @@ +#!/usr/bin/env python3 +import pandas as pd +import optparse + + +# Script originally developed by Yumi Sims (yy5@sanger.ac.uk) + +parser = optparse.OptionParser(version="%prog 1.0") +parser.add_option( + "-l", + "--locationfile", + dest="locationfile", + default="default.locationfile", +) + +parser.add_option( + "-f", + "--fulltable", + dest="fulltable", + default="default.fulltable", +) + +parser.add_option( + "-c", + "--csvfile", + dest="csvfile", + default="default.csvfile", +) + +options, remainder = parser.parse_args() +locationfile = options.locationfile +fulltable = options.fulltable +csvfile = options.csvfile + +location = pd.read_csv(locationfile, sep="\t", comment="#") + +full_table = pd.read_csv(fulltable, sep="\t", header=None, comment="#") + +fulltable_colnames = [ + "buscoID", + "Status", + "Sequence", + "Gene Start", + "Gene End", + "Strand", + "Score", + "Length", + "OrthoDB url", + "Description", +] + +full_table.columns = fulltable_colnames + +df = location.merge(full_table, on="buscoID") + +df_a = df.loc[:, "Sequence":"Gene End"] + +df_new = df_a.join(df[["assigned_chr"]]).join(df[["Score"]]).join(df[["Strand"]]).join(df[["OrthoDB url"]]) + +df_new.fillna("NA", inplace=True) + +dfnoNa = df_new[df_new.Sequence != "NA"] + +df_final = dfnoNa.reset_index(drop=True) + +df_final = df_final.astype({"Gene End": "int", "Gene Start": "int"}) + +df_final.to_csv(csvfile, index=False, header=False, sep="\t") diff --git a/bin/bed_to_contacts.sh b/bin/bed_to_contacts.sh new file mode 100755 index 00000000..b2e884ca --- /dev/null +++ b/bin/bed_to_contacts.sh @@ -0,0 +1,2 @@ +#!/bin/bash +paste -d '\t' - - < $1 | awk 'BEGIN {FS="\t"; OFS="\t"} {if ($1 > $7) {print substr($4,1,length($4)-2),$12,$7,$8,"16",$6,$1,$2,"8",$11,$5} else {print substr($4,1,length($4)-2),$6,$1,$2,"8",$12,$7,$8,"16",$5,$11} }' | tr '\-+' '01' | sort -k3,3d -k7,7d | awk 'NF==11' diff --git a/bin/build_alignment_block.py b/bin/build_alignment_block.py new file mode 100755 index 00000000..10424812 --- /dev/null +++ b/bin/build_alignment_block.py @@ -0,0 +1,135 @@ +#!/usr/bin/env python + +import pandas as pd +import os +import sys +import string +import random +import csv +import optparse +import pybedtools +from pybedtools import BedTool + + +def sort_blocks(df): + return df.sort_values(["rstart", "qstart"], ascending=[True, True]) + + +def get_block(df, index): + block = pd.DataFrame([]) + if index < (len(small_cluster_sort.index) - 2): + if df.iloc[index].loc["qstart"] > df.iloc[index + 1].loc["qstart"]: + block = df[0 : index + 1] + leftover = df[index + 1 : len(df.index) - 1] + qmin = leftover[["qstart"]].min() + print(qmin) + index_list = list(range(0, index + 1)) + df.drop(df.index[index_list], inplace=True) + + return block, df + + +def arrange_fields(df): + df["fragid"] = df["qchr"].str.cat(df["qstart"].astype(str), sep=":").str.cat(df["qend"].astype(str), sep=":") + + return df[["refchr", "rstart", "rend", "fragid", "qstrand"]] + + +def build_block(mylist): + qmin = 0 + qlist = [] + nlist = [] + + for idx, x in enumerate(mylist): + if idx < len(mylist) - 1: + qcurrent = int(x[6]) + rcurrent = int(x[1]) + qnext = mylist[idx + 1][6] + leftover = mylist[idx : len(mylist)] + + # leftd = int(max((x[6]-qcurrent for x in leftover), default=0)) + + leftd = list(x[6] - qmin for x in leftover) + + positives = [x for x in leftd if x > 0] + + min_value = min((positives), default=0) + + indmin = leftd.index(min_value) + + rm = leftover[indmin][1] + + if qcurrent > qmin and qcurrent < qnext and rm == rcurrent: + qmin = qcurrent + qlist.append(idx) + + if qcurrent > qmin and qcurrent < qnext and rm > rcurrent: + nlist.append(idx) + + if qcurrent > qmin and qcurrent > qnext: + nlist.append(idx) + + if qcurrent < qmin and qcurrent > qnext: + nlist.append(idx) + + if idx == len(mylist) - 1: + if mylist[idx][6] > qmin: + qlist.append(idx) + else: + nlist.append(idx) + + alignment_chain = [mylist[i] for i in qlist] + new_list = [mylist[i] for i in nlist] + return alignment_chain, new_list + + +#########main########## + +parser = optparse.OptionParser(version="%prog 1.0") +parser.add_option( + "-i", + "--input", + dest="input_bedfile", + default="default.input", +) +parser.add_option( + "-o", + "--output", + dest="out_bedfile", + default="default.output", +) +options, remainder = parser.parse_args() + +inbed = options.input_bedfile +outbed = options.out_bedfile + +fo = open(outbed, "a") + +sc = pd.read_csv(inbed, sep="\t", comment="#", header=None) + +sc.columns = ["refchr", "rstart", "rend", "qchr", "maplen", "qstrand", "qstart", "qend", "qlen"] + +ans = [y for x, y in sc.groupby("refchr")] + +for mycluster in ans: + for small_cluster in [y for x, y in mycluster.groupby("qchr")]: + small_cluster_sort = sort_blocks(small_cluster) + + newdf = small_cluster_sort.reset_index(drop=True) + + newlist = newdf.values.tolist() + + while newlist: + blocks, newlist = build_block(newlist) + + # fileprefix = "".join(random.choices(string.ascii_lowercase + string.digits, k=12)) + # filename = fileprefix + ".block" + newblocks = [ + [x if i != 3 else y[3] + ":" + str(y[6]) + ":" + str(y[7]) for i, x in enumerate(y)] for y in blocks + ] + + a = pybedtools.BedTool(newblocks) + merged = a.merge(d=100000, c="4,7,8", o="collapse,min,max", delim="|") + fo.write(str(merged)) + +fo.close() diff --git a/bin/buscopainter.py b/bin/buscopainter.py new file mode 100755 index 00000000..ae82ce65 --- /dev/null +++ b/bin/buscopainter.py @@ -0,0 +1,182 @@ +#!/usr/bin/env python +import sys +import argparse + + +# Script originally developed by Charlotte Wright (cw22@sanger.ac.uk) +def parse_table(table_file): + with open(table_file, "r") as table: + table_dict, chr_list = {}, [] + for line in table: + if not line.startswith("#"): + cols = line.rstrip("\n").split() + buscoID, status = cols[0], cols[1] + if status == "Complete": # busco_type can either be "Complete" or "Duplicated" + chr, start, stop = cols[2], int(cols[3]), int(cols[4]) + table_dict[buscoID] = [chr, start, stop] + if not chr in chr_list: + chr_list.append(chr) + return table_dict, sorted(chr_list) + + +def parse_query_table(table_file): # use this function only if interested in assiging duplicated buscos + with open(table_file, "r") as table: + table_dict, table_dict_dup, chr_list = {}, {}, [] + for line in table: + if not line.startswith("#"): + cols = line.rstrip("\n").split() + buscoID, status = cols[0], cols[1] + if status == "Duplicated": # busco_type can either be "Complete" or "Duplicated" + chr, start, stop = cols[2], int(cols[3]), int(cols[4]) + if buscoID in table_dict.keys(): + table_dict_dup[buscoID] = [chr, start, stop] + else: + table_dict[buscoID] = [chr, start, stop] + if not chr in chr_list: + chr_list.append(chr) + return table_dict, table_dict_dup, sorted(chr_list) + + +def print_summary_table(reference_table_dict, reference_chr_list, query_table_dict, query_chr_list, summary_table_file): + with open(summary_table_file, "w") as summary_table: + summary_table.write( + "%s\t%s\t%s\t%s\t%s\t%s" + % ( + "query_chr", + "assigned_chr", + "assigned_chr_busco_count", + "total_query_chr_busco_chr", + "perc", + "\t".join("ref_" + (x) + "_count" for x in reference_chr_list), + ) + + "\n" + ) + assignment_dict = {} + top_chr_dict = {} + for chr in query_chr_list: + assignment_dict[chr] = [] + for i in range(0, len(reference_chr_list)): + assignment_dict[chr].append(0) + for buscoID, position_list in query_table_dict.items(): + query_chr, query_start, query_stop = position_list + try: + reference_chr = reference_table_dict[buscoID][0] + except KeyError: + pass + assignment_dict[query_chr][reference_chr_list.index(reference_chr)] += 1 + for chr, count_list in assignment_dict.items(): + top_chr, top_chr_count, total = "", 0, 0 + for reference_chr in reference_chr_list: + index = reference_chr_list.index(reference_chr) + count = count_list[index] + total += count + if not top_chr == "": + if count > top_chr_count: + top_chr, top_chr_count = reference_chr, count + else: + top_chr, top_chr_count = reference_chr, count + perc = round((top_chr_count / total), 2) + summary_table.write( + "%s\t%s\t%s\t%s\t%s\t%s" + % (chr, top_chr, top_chr_count, total, perc, "\t".join(str(x) for x in count_list)) + + "\n" + ) + top_chr_dict[chr] = top_chr + return top_chr_dict + + +def print_location_table(reference_table_dict, query_table_dict, location_table_file, top_chr_dict): + with open(location_table_file, "w") as location_table: + location_table.write( + "%s\t%s\t%s\t%s\t%s" % ("buscoID", "query_chr", "position", "assigned_chr", "status") + "\n" + ) + for buscoID, position_list in query_table_dict.items(): + query_chr, query_start, query_stop = position_list + position = (query_start + query_stop) / 2 + try: + reference_chr = reference_table_dict[buscoID][0] + if reference_chr != top_chr_dict[query_chr]: + status = reference_chr + else: + status = "self" + location_table.write( + "%s\t%s\t%s\t%s\t%s" % (buscoID, query_chr, position, reference_chr, status) + "\n" + ) + except KeyError: + pass + + +def print_dups_location_table( + reference_table_dict, query_table_dict, query_table_dict2, location_table_file, top_chr_dict +): + with open(location_table_file, "w") as location_table: + location_table.write( + "%s\t%s\t%s\t%s\t%s\t%s" % ("buscoID", "query_chr", "query_start", "query_end", "assigned_chr", "status") + + "\n" + ) + for buscoID, position_list in query_table_dict.items(): + query_chr, query_start, query_stop = position_list + position = (query_start + query_stop) / 2 + try: + reference_chr = reference_table_dict[buscoID][0] + if reference_chr != top_chr_dict[query_chr]: + status = reference_chr + else: + status = "self" + location_table.write( + "%s\t%s\t%s\t%s\t%s\t%s" % (buscoID, query_chr, query_start, query_stop, reference_chr, status) + + "\n" + ) + except KeyError: + pass + for buscoID, position_list in query_table_dict2.items(): + query_chr, query_start, query_stop = position_list + position = (query_start + query_stop) / 2 + try: + reference_chr = reference_table_dict[buscoID][0] + if reference_chr != top_chr_dict[query_chr]: + status = reference_chr + else: + status = "self" + location_table.write( + "%s\t%s\t%s\t%s\t%s\t%s" % (buscoID, query_chr, query_start, query_stop, reference_chr, status) + + "\n" + ) + except KeyError: + pass + + +if __name__ == "__main__": + SCRIPT = "buscopainter.py" + # argument set up + parser = argparse.ArgumentParser() + parser.add_argument("-v", "--version", action="version", version="1.0") + parser.add_argument( + "-r", "--reference_table", type=str, help="full_table.tsv file for reference species", required=True + ) + parser.add_argument("-q", "--query_table", type=str, help="full_table.tsv for query species", required=True) + parser.add_argument("-p", "--prefix", type=str, help="prefix for output file names", default="buscopainter") + args = parser.parse_args() + reference_table_file = args.reference_table + query_table_file = args.query_table + prefix = args.prefix + summary_table_file = prefix + "_summary.tsv" + location_table_file = prefix + "_complete_location.tsv" + # run the functions + reference_table_dict, reference_chr_list = parse_table(reference_table_file) # get all complete buscos + query_table_dict, query_chr_list = parse_table(query_table_file) # get all complete buscos as usual + top_chr_dict = print_summary_table( + reference_table_dict, reference_chr_list, query_table_dict, query_chr_list, summary_table_file + ) # work out top_chr dict using complete buscos as usual + print("[+] Written output files successfully:") + print("[+] " + summary_table_file) + print("[+] " + location_table_file) + query_table_dup1_dict, query_table_dup2_dict, query_chr_dup_list = parse_query_table( + query_table_file + ) # get all duplicated buscos + print_location_table(reference_table_dict, query_table_dict, location_table_file, top_chr_dict) + location_table_file = prefix + "_duplicated_location.tsv" + print_dups_location_table( + reference_table_dict, query_table_dup1_dict, query_table_dup2_dict, location_table_file, top_chr_dict + ) + print("[+] " + location_table_file) diff --git a/bin/cmap2bed.py b/bin/cmap2bed.py new file mode 100755 index 00000000..ec8b96d0 --- /dev/null +++ b/bin/cmap2bed.py @@ -0,0 +1,83 @@ +#!/usr/bin/env python + +import optparse +import sys +import io +import string + +# Script originally developed by Yumi Sims (yy5@sanger.ac.uk) + +parser = optparse.OptionParser(version="%prog 1.0") +parser.add_option( + "-t", + "--inputfile", + dest="inputfile", + default="default.input", +) + +parser.add_option( + "-z", + "--enzyme", + dest="enzyme", + default="default.enzyme", +) + +options, remainder = parser.parse_args() + +enzyme = options.enzyme + + +def join2lines(previous_line, current_line): + return (previous_line.strip() + "\t" + current_line.strip()).split("\t") + + +def get_fields(line): + mylist = line.split("\t") + return mylist[0] + "\t" + mylist[5] + + +def reformat_cmap(cmap, enzyme): + my_file = open(cmap, "r") + my_new_file = [] + if my_file: + current_line = my_file.readline() + + for line in my_file: + previous_line = current_line + current_line = line + mylinelist = join2lines(get_fields(previous_line), get_fields(current_line)) + if mylinelist[0] == mylinelist[2]: + my_new_file.append( + mylinelist[0] + + "\t" + + str(int(float(mylinelist[1]))) + + "\t" + + str(int(float(mylinelist[3]))) + + "\t" + + enzyme + + "\t" + + str(int(float(mylinelist[3])) - int(float(mylinelist[1]))) + ) + else: + my_new_file.append( + mylinelist[2] + + "\t" + + "0" + + "\t" + + str(int(float(mylinelist[3]))) + + "\t" + + enzyme + + "\t" + + str(int(float(mylinelist[3]))) + ) + + firtLineList = my_new_file[0].split("\t") + firtline = firtLineList[0] + "\t" + "0" + "\t" + firtLineList[1] + "\t" + enzyme + "\t" + firtLineList[1] + my_new_file.insert(0, firtline) + return my_new_file + + +mymap = reformat_cmap(options.inputfile, enzyme) + +for line in mymap: + print(line) diff --git a/bin/extract_cov_iden.sh b/bin/extract_cov_iden.sh new file mode 100755 index 00000000..977a388b --- /dev/null +++ b/bin/extract_cov_iden.sh @@ -0,0 +1,18 @@ +#!/bin/bash + +# extract_cov_iden.sh +# ------------------- +# A shell script to convert a +# extract coverage information from +# PAF header and reorganising the data +# ------------------- +# Author = yy5 + +version='1.0.0' + +if [ $1 == '-v']; +then + echo "$version" +else + grep '##PAF' $1 | sed 's/##PAF\t//g'|awk 'BEGIN{FS="\t";}{a[$1]++;if(a[$1]==2)print v[$1] ORS $0;if(a[$1]>2)print;v[$1]=$0;}' | awk '$(NF+1) = ($10/$11)*100'|awk '$(NF+1) = ($10/($2*3))*100'|awk -vOFS='\t' '{print $6,$8,$9,$1,$2,$10,$(NF-1),$NF}' > $2 +fi diff --git a/bin/extract_repeat.pl b/bin/extract_repeat.pl new file mode 100755 index 00000000..ae18add9 --- /dev/null +++ b/bin/extract_repeat.pl @@ -0,0 +1,18 @@ +#!/usr/local/bin/perl + +use strict; + +my $file = shift; +open(IN,$file); +my $last; +while () { + if (/\>(\S+)/) { + $last = $1; + } + elsif (/(\d+)\s+-\s+(\d+)/) { + print "$last\t$1\t$2\n"; + } + else { + die("Eh? $_"); + } +} diff --git a/bin/fa2cmap_multi_color.pl b/bin/fa2cmap_multi_color.pl new file mode 100755 index 00000000..10150fa2 --- /dev/null +++ b/bin/fa2cmap_multi_color.pl @@ -0,0 +1,1004 @@ +#!/usr/local/bin/perl +################################################################################# +# File: fa2cmap_multi_color.pl # +# Date: 10/06/2016 # +# Purpose: Transform fasta file to BioNano cmap file format (Color-aware) # +# # +# Author: Xiang Zhou, Computational Biologist # +# Email : xzhou@bionanogenomics.com # +# Affiliation: Research Department, BioNano Genomics Inc. # +# # +# Usage: # +# fa2cmap_multi_color.pl [options] # +# Options: # +# -h : This help message # +# -v : Print program version information # +# -i : Input fasta file (Required) # +# -k : Input key file (If provided, use as contigIDs rather than sequentially)# +# -o : Output folder (Default: the same as the input file) # +# -e : Name or sequence of the enzyme (or a combination of name and sequence # +# in the format of name:sequence) followed by channel # (Can be multiple)# +# -m : Filter: Minimum sites (Integer, default: 0) # +# -M : Filter: Minimum size (kb) (Integer, default: 0) # +# -B : Output BED file of Nbase gaps (Default: OFF) # +# -g : Minimum N gap size (bp) when generating Nbase gap file (Default: 1000) # +# -W : For web use only, and must be the first option (Default: OFF) # +# -S : Add an additional column, Strand, to the cmap file (Default: OFF) # +# # +# NOTE: CMAP index is 1-based, and is color-aware. # +################################################################################# + +use strict; +use POSIX; +use File::Spec; +use File::Basename; +use File::Spec::Functions; +#use List::MoreUtils qw(uniq); +#use Getopt::Std; +use File::Path qw(make_path); +use Getopt::Long qw(:config no_ignore_case); +#use File::Slurp qw(edit_file_lines); +#$Getopt::Std::STANDARD_HELP_VERSION = 1; +use warnings; +use v5.26; +use experimental 'smartmatch'; + +sub Init; +sub Usage; +sub Version; +sub Find_enzymes; +sub Print_cmap_header; +sub Generate_cmap; +sub Get_and_set_enzyme_sequence; +sub is_enzyme_name; +sub is_nt_sequence; +sub is_enzyme_name_and_sequence; +sub Uniq; +sub Get_distance; +sub Get_N50; +sub Get_N90; +sub StdDev; +sub getNGaps; +sub printNGaps; + +my %enzyme = ( + "BspQI" => "GCTCTTC", + "BbvCI" => "CCTCAGC", + "BsmI" => "GAATGC", + "BsrDI" => "GCAATG", + "bseCI" => "ATCGAT", + "DLE1" => "CTTAAG", + "BssSI" => "CACGAG" + + # You can add more enzymes here ... +); +my (@enzymes, @enzyme_sequences, @color, @color_uniq); +my ($min_labels, $min_length, $minNGapSize) = (0, 0, 1000); +my ($FASTA, $CMAP, $KEY, $BED, $SUMMARY, $STATUS, $ERROR, $KEY_IN); + +# Autoflush for files +my $old_fh = select($STATUS); +local $| = 1; +select($old_fh); + +my $num_args = $#ARGV; +my $argvs = ""; +for(my $i = 0; $i <= $num_args; $i++){ + $argvs .= " $ARGV[$i]"; + } +my ($help, $version, $web, $strand, $keyfile, $input, $output, $nbase_bed, $bedfile); +my ($strand_header, $strand_header_type) = ("", ""); +my (@loci, @loci_tmp); +my (%color, %color_to_enzyme_sequence, %strand); +my ($count, $num_cmaps, $total_nicks) = (0, 0, 0); +my @num_nicks; # For each channel +my @num_nicks_global; # For each channel +my @density; # For each channel +my @total_label_distance; # For each channel +my @label_distances_by_channel; # Two-dimensional array containing label distances of each channel +my $density_global; +my ($total_length_original, $total_length_filtered, $total_label_distance_filtered) = (0, 0, 0); +my (@length_filtered, @label_distance_filtered); +my $nGaps = {}; # hashref variable for NGap begin/end with minNGapSize - Zhanyang + +my ($command, $seq, $seq_length, $tmp); +my ($fastaHeader, $fastaHeader_previous); +my ($A, $C, $G, $T, $N, $global_N, $global_GC, $global_ACGT, $global_ACGTN); +my ($N_percentage, $GC_percentage, $global_N_percentage, $global_GC_percentage); + +Init(); +my ($filename, $filename_key, $filename_bed, $filename_summary, $filename_status, $filename_error) = ($input) x 6; + +for(my $i = 0; $i < @color_uniq; $i++){ + @num_nicks_global[$color_uniq[$i]] = 0; + } +for(my $i = 0; $i < @enzymes; $i++){ + $tmp .= "_$enzymes[$i]"; + } + +# If output folder is not defined, use the input folder +if($output){ + #if(substr($output, -1) eq "/"){ + # $filename = $output . (split("/", $input))[-1]; + # $filename_key = $output . (split("/", $input))[-1]; + #} + #else{ + # $filename = $output . "/" . (split("/", $input))[-1]; + # $filename_key = $output . "/" . (split("/", $input))[-1]; + #} + + # TODO: Convert ".." to absolute path! + my ($nothing, $out_dir) = fileparse($output."/"); + #mkdir($out_dir); + make_path($out_dir) unless (-d $out_dir); + #print "\nOUTPUT_DIR\n", $out_dir, "\n\n"; + + $filename = basename($filename); + $filename = catfile($out_dir, $filename); + $filename_key = basename($filename_key); + $filename_key = catfile($out_dir, $filename_key); + $filename_bed = basename($filename_bed); + $filename_bed = catfile($out_dir, $filename_bed); + $filename_summary = basename($filename_summary); + $filename_summary = catfile($out_dir, $filename_summary); + $filename_status = catfile($out_dir, "status.txt"); + $filename_error = catfile($out_dir, "error.txt"); +} +else{ + my ($nothing, $in_dir) = fileparse($input); + $filename_status = catfile($in_dir, "status.txt"); + $filename_error = catfile($in_dir, "error.txt"); +} +$filename =~ s/(\S+)\.\w+$/$1${tmp}_${min_length}kb_${min_labels}labels.cmap/; +$filename_key =~ s/(\S+)\.\w+$/$1${tmp}_${min_length}kb_${min_labels}labels_key.txt/; +$filename_summary =~ s/(\S+)\.\w+$/$1${tmp}_${min_length}kb_${min_labels}labels_summary.txt/; +$filename_bed =~ s/(\S+)\.\w+$/$1_min${minNGapSize}_nbase.bed/; + +open($STATUS, ">$filename_status") || die ("ERROR: Can't open $filename_status: $!\n"); +printf $STATUS("0%% done\n"); +my $num_contigs = 0; +my $ct = 0; +open($FASTA, $input) || die ("ERROR: Can't open $input: $!\n"); +while(my $line = <$FASTA>){ + if($ct == 0){ + $ct++; + #chomp $line; + #$line =~ s/\r//g; + #if( $line ne "" && !($line =~ /^[>ACGTNacgtn]/) ){ + if(! ($line =~ /^>/) ){ + open($ERROR, ">$filename_error") || die ("ERROR: Can't open $filename_error: $!\n"); + print ("ERROR: Invalid input file!\n"); + print $ERROR("ERROR: Invalid input file!\n"); + close($ERROR); + Usage(); + } + } + if($line =~ /^>/){ + $num_contigs++; + } +} +close($FASTA); + +my %table; +if( defined($keyfile) ){ + open($KEY_IN, $keyfile) || die ("ERROR: Can't open $keyfile: $!\n"); + while(my $line = <$KEY_IN>){ + if($line =~ /^#/){ + next; + } + else{ + chomp $line; + $line =~ s/\r//g; + + my @x = split("\t", $line); + $table{$x[1]} = $x[0]; + } + } + close($KEY_IN); +} + +open($KEY, ">$filename_key") || die ("ERROR: Can't open $filename_key: $!\n"); +print $KEY("# CMAP = ", File::Spec -> rel2abs($filename), "\n"); +print $KEY("# filter: Minimum Sites = $min_labels\n"); +print $KEY("# filter: Minimum Size (kb) = $min_length\n"); +print $KEY("CompntId\tCompntName\tCompntLength\n"); + +open($SUMMARY, ">$filename_summary") || die ("ERROR: Can't open $filename_summary: $!\n"); +print $SUMMARY("#PARAMS\n"); +print $SUMMARY("Version:\t", '$Id: fa2cmap_multi_color.pl 7821 2018-08-09 17:30:15Z twang $', "\n"); +print $SUMMARY("Command:\t", "$0", $argvs, "\n"); +print $SUMMARY("Input file:\t", File::Spec -> rel2abs($input), "\n"); +print $SUMMARY("Output file:\t", File::Spec -> rel2abs($filename), "\n"); +print $SUMMARY("ID keyfile:\t", File::Spec -> rel2abs($filename_key), "\n"); +if($nbase_bed){ + # Do not re-generate Nbase gap file! + if(-e $filename_bed){ + $nbase_bed = 0; + } + print $SUMMARY("BED file:\t", File::Spec -> rel2abs($filename_bed), "\n"); +} +print $SUMMARY("Minimum sites filter:\t$min_labels\n"); +print $SUMMARY("Minimum size filter (kbp):\t$min_length\n"); +for(my $i = 0; $i < @enzymes; $i++){ + print $SUMMARY("Enzyme ", $i+1, " (Channel $color[$i]):\t$enzymes[$i]($enzyme_sequences[$i])\n"); +} +print $SUMMARY("\n"); + +print $SUMMARY("#RESULT\n"); +print $SUMMARY("CMapId\tChannel\tLength(Mb)\tDensity(sites/100kbp)\tGC%\tN%\n"); +#print $SUMMARY("------------------------------------------------------------------\n"); + +Print_cmap_header($filename); + +open($FASTA, $input) || die ("ERROR: Can't open $input: $!\n"); +while(my $line = <$FASTA>){ + chomp $line; + $line =~ s/\r//g; + + if($line =~ /^>/){ + $fastaHeader_previous = $fastaHeader; + $fastaHeader = substr($line, 1); + + if($count != 0){ + $seq_length = length($seq); + + # IF the sequence length is 0, ignore this sequence!!! + if(!$seq_length){ + $count++; + next; + } + + $A = ($seq =~ tr/A/A/); + $C = ($seq =~ tr/C/C/); + $G = ($seq =~ tr/G/G/); + $T = ($seq =~ tr/T/T/); + $N = ($seq =~ tr/N/N/); + $global_N += $N; + $global_GC += ($C+$G); + $global_ACGT += ($A+$C+$G+$T); + $global_ACGTN += ($A+$C+$G+$T+$N); + + $total_length_original += $seq_length; + + @loci_tmp = (); + %color = (); + for(my $i = 0; $i < @color_uniq; $i++){ + @num_nicks[$color_uniq[$i]] = 0; + } + for(my $i = 0; $i < @enzyme_sequences; $i++){ + my @nicks_tmp = Find_enzymes($seq, $enzyme_sequences[$i], $color[$i]); + push(@loci_tmp, @nicks_tmp); + } + + # Remove duplicated values! + @loci = Uniq(@loci_tmp); + + # Filter by $min_labels and $min_length + if(scalar(@loci) >= $min_labels && $seq_length >= $min_length * 1000){ + if(%table){ + Generate_cmap($filename, $table{$fastaHeader_previous}, \@loci, $seq_length); + print $KEY("$table{$fastaHeader_previous}\t$fastaHeader_previous\t", $seq_length, "\n"); + } + else{ + Generate_cmap($filename, $count, \@loci, $seq_length); + print $KEY("$count\t$fastaHeader_previous\t", $seq_length, "\n"); + } + + my $length_tmp = sprintf("%.3f", $seq_length/1000000); + + if($A+$C+$G+$T == 0){ + $GC_percentage = sprintf("%.1f", 0); + } + else{ + $GC_percentage = sprintf("%.1f", ($C+$G)/($A+$C+$G+$T)*100); + } + if($N == 0){ + $N_percentage = sprintf("%.1f", 0); + } + else{ + $N_percentage = sprintf("%.1f", $N/$seq_length*100); + } + + for(my $i = 0; $i < @color_uniq; $i++){ + $density[$count] = sprintf("%.1f", $num_nicks[$color_uniq[$i]]/$seq_length * 100000); + print $SUMMARY("$count\t$color_uniq[$i]\t$length_tmp\t$density[$count]\t$GC_percentage\t$N_percentage\n"); + } + + # NOTE: No duplicate sites!!! + $total_nicks += @loci; + $total_length_filtered += $seq_length; + push(@length_filtered, $seq_length); + } + # Count Ngaps for this chromosome (Zhanyang Zhu) + if($nbase_bed){ + $nGaps->{$count} = getNGaps($seq, $minNGapSize); + } + } + + # Generate the status bar + if($count % ceil($num_contigs/100) == 0){ + printf $STATUS("%d%% done\n", $count/$num_contigs*100); + } + + # Reset + $seq = ""; + $count++; + } + else{ + $seq .= uc($line); + } +} + +$seq_length = length($seq); + +# IF the sequence length is not 0!!! +if($seq_length){ + $A = ($seq =~ tr/A/A/); + $C = ($seq =~ tr/C/C/); + $G = ($seq =~ tr/G/G/); + $T = ($seq =~ tr/T/T/); + $N = ($seq =~ tr/N/N/); + $global_N += $N; + $global_GC += ($C+$G); + $global_ACGT += ($A+$C+$G+$T); + $global_ACGTN += ($A+$C+$G+$T+$N); + + $total_length_original += $seq_length; + + @loci_tmp = (); + %color = (); + for(my $i = 0; $i < @color_uniq; $i++){ + @num_nicks[$color_uniq[$i]] = 0; + } + for(my $i = 0; $i < @enzyme_sequences; $i++){ + my @nicks_tmp = Find_enzymes($seq, $enzyme_sequences[$i], $color[$i]); + push(@loci_tmp, @nicks_tmp); + } + + # Remove duplicated values! + @loci = Uniq(@loci_tmp); + + if(scalar(@loci) >= $min_labels && $seq_length >= $min_length * 1000){ + if(%table){ + Generate_cmap($filename, $table{$fastaHeader}, \@loci, $seq_length); + print $KEY("$table{$fastaHeader}\t$fastaHeader\t", $seq_length, "\n"); + } + else{ + Generate_cmap($filename, $count, \@loci, $seq_length); + print $KEY("$count\t$fastaHeader\t", $seq_length, "\n"); + } + + my $length_tmp = sprintf("%.3f", $seq_length/1000000); + + if($A+$C+$G+$T == 0){ + $GC_percentage = sprintf("%.1f", 0); + } + else{ + $GC_percentage = sprintf("%.1f", ($C+$G)/($A+$C+$G+$T)*100); + } + if($N == 0){ + $N_percentage = sprintf("%.1f", 0); + } + else{ + $N_percentage = sprintf("%.1f", $N/$seq_length*100); + } + + for(my $i = 0; $i < @color_uniq; $i++){ + $density[$count] = sprintf("%.1f", $num_nicks[$color_uniq[$i]]/$seq_length * 100000); + print $SUMMARY("$count\t$color_uniq[$i]\t$length_tmp\t$density[$count]\t$GC_percentage\t$N_percentage\n"); + } + + # NOTE: No duplicate sites!!! + $total_nicks += @loci; + $total_length_filtered += $seq_length; + push(@length_filtered, $seq_length); + } + + if($nbase_bed){ + # Count Ngaps for the last chromosome (Zhanyang Zhu) + $nGaps->{$count} = getNGaps($seq, $minNGapSize); + } +} +close($FASTA); +close($KEY); + +if($nbase_bed){ + printNGaps($nGaps, $filename_bed, $minNGapSize); +} + +#$command = "$^X -pi -e 's|N/A|$num_cmaps|' $filename"; +#print "Running command:\n$command\n\n"; +#system("$command"); +#edit_file_lines {s |N/A|$num_cmaps| } $filename; + +$command = "$^X -i.bak -p -e \"s/N\\/A/$num_cmaps/\" $filename"; +#print "Running command:\n$command\n\n"; +system("$command"); +unlink("$filename.bak"); + +#print $SUMMARY("\n================================Summary================================\n"); +print $SUMMARY("\n#SUMMARY\n"); +print $SUMMARY("Minimum sites filter:\t$min_labels\n"); +print $SUMMARY("Minimum size filter (kbp):\t$min_length\n"); +print $SUMMARY("Total sequence entries processed:\t$count\n"); +print $SUMMARY("Total maps generated:\t$num_cmaps\n"); + +print $SUMMARY("Total length of the original sequence entries (bp):\t$total_length_original\n"); +print $SUMMARY("Total length of the filtered maps (bp):\t$total_length_filtered\n"); +print $SUMMARY("Map N50 (bp):\t", Get_N50(\@length_filtered, $total_length_filtered), "\n"); +print $SUMMARY("Map N90 (bp):\t", Get_N90(\@length_filtered, $total_length_filtered), "\n"); +$global_GC_percentage = sprintf("%.1f", $global_GC/$global_ACGT*100); +$global_N_percentage = sprintf("%.1f", $global_N/$global_ACGTN*100); +print $SUMMARY("Global GC (%):\t$global_GC_percentage\n"); +print $SUMMARY("Global N (%):\t$global_N_percentage\n\n"); + +foreach my $channel ( sort {$a <=> $b} @color_uniq ){ + my $distance_tmp = sprintf("%.1f", Get_N50(\@{$label_distances_by_channel[$channel]}, $total_label_distance[$channel])); +# print $SUMMARY("Site to site distance N50 for channel $channel\t$distance_tmp\n"); + print $SUMMARY("Channel $channel site to site distance N50 (bp):\t$distance_tmp\n"); +} +my $label_distance_global = sprintf("%.1f", Get_N50(\@label_distance_filtered, $total_label_distance_filtered)); +#print $SUMMARY("Overall site to site distance N50\t$label_distance_global\n"); +print $SUMMARY("\n"); + +foreach my $channel ( sort {$a <=> $b} @color_uniq ){ + my $distance_stddev_tmp = sprintf("%.1f", StdDev(\@{$label_distances_by_channel[$channel]})); +# print $SUMMARY("Standard deviation of site to site distance for channel $channel\t$distance_stddev_tmp\n"); + print $SUMMARY("Channel $channel standard deviation of site to site distance (bp):\t$distance_stddev_tmp\n"); +} +my $distance_stddev_global = sprintf("%.1f", StdDev(\@label_distance_filtered)); +#print $SUMMARY("Standard deviation of overall site to site distance\t$distance_stddev_global\n"); +print $SUMMARY("\n"); + +foreach my $channel ( sort {$a <=> $b} @color_uniq ){ + my $density_tmp; + my @numLabel_filtered = GetNumLabelByDist(\@{$label_distances_by_channel[$channel]}); + my $density_saphyr; + my $density_irys; + + if($total_length_filtered){ + $density_tmp = sprintf("%.1f", $num_nicks_global[$channel]/$total_length_filtered * 100000); + $density_saphyr = sprintf("%.1f", $numLabel_filtered[1]/$total_length_filtered * 100000); + $density_irys = sprintf("%.1f", $numLabel_filtered[2]/$total_length_filtered * 100000); + } + else{ + $density_tmp = sprintf("%.1f", 0); + $density_saphyr = sprintf("%.1f", 0); + $density_irys = sprintf("%.1f", 0); + } + print $SUMMARY("Channel $channel site density (sites/100kbp):\t$density_tmp\n"); + print $SUMMARY("Channel $channel estimated label density (labels/100kbp) for Saphyr:\t$density_saphyr\n"); + print $SUMMARY("Channel $channel estimated label density (labels/100kbp) for Irys:\t$density_irys\n\n"); +} +if($total_length_filtered){ + $density_global = sprintf("%.1f", $total_nicks/$total_length_filtered * 100000); +} +else{ + $density_global = sprintf("%.1f", 0); +} +#print $SUMMARY("Global site frequency (sites/100kb)\t$density_global\n"); + +#print $SUMMARY("=======================================================================\n"); +close($SUMMARY); + +sleep(1); +printf $STATUS("%d%% done\n", $count/$num_contigs*100); +close($STATUS); +exit 0; +###################################################################### +# Subroutines # +###################################################################### +sub Init{ +=COMMENT + my $opt_string = 'hvBi:o:k:s:e:m:M:g:WS'; + if(!getopts("$opt_string", \%opts)){ + print("ERROR: Invalid parameter(s)!\n"); + Usage(); + } +=cut + my @tmp; + my $ret = GetOptions( + 'help|h|?' => \$help, + 'version|v' => \$version, + 'input|i=s' => \$input, + 'keyfile|k=s' => \$keyfile, + 'output|o=s' => \$output, + 'enzyme|e=s{1,18}' => \@tmp, + 'min_labels|m:i' => \$min_labels, + 'min_length|M:i' => \$min_length, + 'nbaseBED|B' => \$nbase_bed, + 'minSizeNGap|g:i' => \$minNGapSize, + 'Web|W' => \$web, + 'Strand|S' => \$strand, + ); + + if(!$ret){ + print("ERROR: Missing or invalid parameter(s)!\n"); + Usage(); + } + + Usage() if $help; + Version() if $version; + + if(!$input){ + print("ERROR: Missing parameter(s)!\n"); + Usage(); + } + + if(!@tmp){ + print("ERROR: Missing parameter(s)!\n"); + Usage(); + } + + # Total number of values must be even + if(@tmp%2 != 0){ + print("ERROR: There must be even numbers of -e parameters!\n"); + Usage(); + } + + for(my $i = 1; $i < @tmp; $i += 2){ + # The values at odd positions must be positive integers + if($tmp[$i] =~ /^\d+$/){ + $color[($i-1)/2] = $tmp[$i]; + } + else{ + print("ERROR: Invalid parameter(s)!\n"); + Usage(); + } + + # The values at even positions must be either name or sequence + if(is_enzyme_name_and_sequence($tmp[$i-1])){ + #ZZhu: when name:sequence is provided + my @name_seq = split(":", $tmp[$i-1]); + $enzyme_sequences[($i-1)/2] = uc($name_seq[1]); + $enzymes[($i-1)/2] = uc($name_seq[0]); + } + elsif(is_enzyme_name(\%enzyme, $tmp[$i-1])){ + $enzyme_sequences[($i-1)/2] = Get_and_set_enzyme_sequence(\%enzyme, \$tmp[$i-1]); + $enzymes[($i-1)/2] = uc($tmp[$i-1]); + } + elsif(is_nt_sequence($tmp[$i-1])){ + $enzyme_sequences[($i-1)/2] = uc($tmp[$i-1]); + $enzymes[($i-1)/2] = uc($tmp[$i-1]); + } + else{ + print("ERROR: Invalid parameter(s)!\n"); + Usage(); + } + + push( @{$color_to_enzyme_sequence{$tmp[$i]}}, $enzyme_sequences[($i-1)/2] ); + } + + @color_uniq = sort {$a <=> $b} (Uniq(@color)); + + if($minNGapSize < 1){ + $minNGapSize = 1; + } + + if($strand){ + ($strand_header, $strand_header_type) = ("\tStrand", "\tchar"); + } + + # @enzymes: enzyme names in the same order as the input + # @enzyme_sequences: enzyme sequences in the same order as the input + # @color: colors of each enzyme in the same order as the input + # @color_uniq: a unique set of colors of all enzymes in ascending order + + #print "[@enzymes]", "\n"; + #print "[@enzyme_sequences]", "\n"; + #print "[@color]", "\n"; + #print "[@color_uniq]", "\n"; +} + +sub Usage{ + if($web){ + exit 1; + } + + print << "EOF"; +Usage: $^X $0 [options] +Options: + -h : This help message + -v : Print program version information + -i : Input fasta file (Required) + -k : Input key file (If provided, use as contigIDs rather than sequentially) + -o : Output folder (Default: the same as the input file) + -e : Name or sequence of the enzyme (or a combination of name and sequence + in the format of name:sequence) followed by channel # (Can be multiple) + -m : Filter: Minimum sites (Integer, default: 0) + -M : Filter: Minimum size (kb) (Integer, default: 0) + -B : Output BED file of Nbase gaps (Default: OFF) + -g : Minimum N gap size (bp) when generating Nbase gap file (Default: 1000) + -W : For web use only, and must be the first option (Default: OFF) + -S : Add an additional column, Strand, to the cmap file (Default: OFF) +NOTE: CMAP index is 1-based, and is color-aware. +EOF + exit 1; +} + +sub Version{ + # $Id: fa2cmap_multi_color.pl 7821 2018-08-09 17:30:15Z twang $ + my $REV = '$Id: fa2cmap_multi_color.pl 7821 2018-08-09 17:30:15Z twang $'; + ($REV) = $REV =~ /\$Id: (.*)\$/; + if($REV){ + print $REV, "\n"; + } + else{ + print "No version # was found!", "\n"; + } + exit 0; +} + +sub Find_enzymes{ + my ($seq, $enzyme, $channel) = @_; + my @result; + + # HashTable: $color{ nicking_site }[0] = total_num_of_colors + # HashTable: $color{ nicking_site }[1 .. total_num_of_colors_at_this_location] = $channel + # HashTable: $strand{$nicking_site} = "+" or "-" + + # Find the enzymes in the forward strand, staring from the first nucleotide!!! + my $current_loc = index($seq, $enzyme, 0); + while ($current_loc != -1){ + # Add the current location into @result IFF + # 1) it is not in @result, or + # 2) it is in @result, and the current color is not in the color array. + if( !defined($color{$current_loc+1}[0]) || !($channel ~~ @{$color{$current_loc+1}}[1 .. $color{$current_loc+1}[0]]) ){ + # This is color-aware! + push(@result, $current_loc+1); + + # Increase the color count + if( !defined($color{$current_loc+1}) ){ + $color{$current_loc+1}[0] = 1; + } + else{ + $color{$current_loc+1}[0]++; + } + + # Store the current color on the current nicking site in the color array (unique, no order!): + # $color{ nicking_site }[1 .. total_num_of_colors_at_this_location] + $color{$current_loc+1}[ $color{$current_loc+1}[0] ] = $channel; + } + + $strand{$current_loc+1} = "+"; + + $current_loc = index($seq, $enzyme, $current_loc + 1); + } + + my $enzyme_rc = reverse($enzyme); + $enzyme_rc =~ tr/ACGTUN/TGCAAN/; + + # Find the rc(enzymes) in the forward strand, staring from the first nucleotide!!! + $current_loc = index($seq, $enzyme_rc, 0); + while ($current_loc != -1){ + # Add the current location into @result IFF + # 1) it is not in @result, or + # 2) it is in @result, and the current color is not in the color array. + if( !defined($color{$current_loc+1}[0]) || !($channel ~~ @{$color{$current_loc+1}}[1 .. $color{$current_loc+1}[0]]) ){ + # This is color-aware! + push(@result, $current_loc+1); + + if( !defined($color{$current_loc+1}) ){ + $color{$current_loc+1}[0] = 1; + } + else{ + $color{$current_loc+1}[0]++; + } + $color{$current_loc+1}[ $color{$current_loc+1}[0] ] = $channel; + } + $strand{$current_loc+1} = "-"; + + $current_loc = index($seq, $enzyme_rc, $current_loc + 1); + } + + # Remove duplicated values! + return Uniq(@result); +} + +sub Print_cmap_header{ + my ($filename) = @_; + my $OUT; + my $tmp = ""; + my $color_uniq = scalar(@color_uniq); + + open($OUT, ">$filename") || die ("ERROR: Can't open $filename: $!\n"); + + #for(my $i = 0; $i < @enzyme_sequences; $i++){ + # $tmp .= ("# Nickase Recognition Site " . eval($i+1) . ":\t$enzyme_sequences[$i]\n"); + #} + + foreach my $key (sort {$a <=> $b} keys %color_to_enzyme_sequence){ + $tmp .= ("# Nickase Recognition Site $key:\t" . $color_to_enzyme_sequence{$key}[0]); + + for(my $i = 1; $i < scalar(@{$color_to_enzyme_sequence{$key}}); $i++){ + $tmp .= ",$color_to_enzyme_sequence{$key}[$i]"; + } + + $tmp .= "\n"; + } + + chomp($tmp); + + my $str = << "EOF"; +# CMAP File Version: 0.1 +# Label Channels: $color_uniq +$tmp +# Number of Consensus Nanomaps: N/A +#h CMapId ContigLength NumSites SiteID LabelChannel Position StdDev Coverage Occurrence$strand_header +#f int float int int int float float int int$strand_header_type +EOF + print $OUT($str); + close($OUT); +} + +sub Generate_cmap{ + my ($filename, $ID, $loci_ref, $length) = @_; + my $i; + my $siteID = 1; + my $total_loci = 0; + my $OUT; + my $length_float = sprintf("%.1f", $length); + my @sorted_loci = sort {$a <=> $b} @$loci_ref; + my @positions; # Two-dimensional array containing label positions of each channel + + open($OUT, ">>$filename") || die ("ERROR: Can't open $filename: $!\n"); + + for($i = 0; $i < @sorted_loci; $i++){ + # "1" in most of the time, ">1" when there are multiple labels at the same position (the array is unique!) + $total_loci += $color{$sorted_loci[$i]}[0]; + } + + for($i = 0; $i < @sorted_loci; $i++){ + my $loci_float = sprintf("%.1f", $sorted_loci[$i]); + my @sorted_colors = sort {$a <=> $b} @{$color{$sorted_loci[$i]}}[1 .. $color{$sorted_loci[$i]}[0]]; + + for(my $j = 0; $j < $color{$sorted_loci[$i]}[0]; $j++){ + if($strand){ + print $OUT("$ID\t$length_float\t$total_loci\t$siteID\t", $sorted_colors[$j], "\t$loci_float\t1.0\t1\t1\t", $strand{$sorted_loci[$i]}, "\n"); + } + else{ + print $OUT("$ID\t$length_float\t$total_loci\t$siteID\t", $sorted_colors[$j], "\t$loci_float\t1.0\t1\t1\n"); + } + $num_nicks[$sorted_colors[$j]]++; + $num_nicks_global[$sorted_colors[$j]]++; + + $siteID++; + + # Storing label positions for calculating the label distances + push(@{$positions[$sorted_colors[$j]]}, $sorted_loci[$i]); + } + } + + # Calculating per channel label distances + foreach my $channel (@color_uniq){ + if(exists($positions[$channel][1])){ + push(@{$label_distances_by_channel[$channel]}, Get_distance(\@{$positions[$channel]})); + $total_label_distance[$channel] += ($positions[$channel][-1] - $positions[$channel][0]); + } + } + + # Calculating global label distances + if(@sorted_loci >= 2){ + push(@label_distance_filtered, Get_distance(\@sorted_loci)); + $total_label_distance_filtered += ($sorted_loci[-1] - $sorted_loci[0]); + } + + if($strand){ + print $OUT("$ID\t$length_float\t$total_loci\t$siteID\t0\t$length_float\t0.0\t1\t0\t.\n"); + } + else{ + print $OUT("$ID\t$length_float\t$total_loci\t$siteID\t0\t$length_float\t0.0\t1\t0\n"); + } + $num_cmaps++; + + close($OUT); +} + +sub Get_distance{ + my ($loci_ref) = @_; + my @dist; + for(my $i = 0; $i < @$loci_ref - 1; $i++){ + push(@dist, $loci_ref->[$i+1] - $loci_ref->[$i]); + } + return @dist; +} + +sub Get_and_set_enzyme_sequence{ + my ($hash_ref, $str_ref) = @_; + + foreach my $item (keys %$hash_ref){ + if(uc(substr($item, 0, 3)) eq uc(substr($$str_ref, 0, 3))){ + $$str_ref = $item; + return uc($hash_ref -> {$item}); + } + } + + print("ERROR: Invalid parameter(s)!\n"); + Usage(); +} + +sub is_enzyme_name{ + my ($hash_ref, $str) = @_; + + my @array = map { uc(substr($_, 0, 3)) } keys %$hash_ref; + + if(uc(substr($str, 0, 3)) ~~ @array){ + return 1; + } + else{ + return 0; + } +} + +sub is_nt_sequence{ + my ($str) = @_; + + for(my $i = 0; $i < length($str); $i++){ + if("ACGTacgt" !~ substr($str, $i, 1)){ + return 0; + } + } + return 1; +} + +sub is_enzyme_name_and_sequence{ + my ($str) = @_; + + if($str =~ ":"){ + my @name_seq = split(":", $str); + if(@name_seq == 2 && is_nt_sequence($name_seq[1])){ + return 1; + } + } + return 0; +} + +sub Uniq{ + my %seen; + grep {!$seen{$_}++} @_; +} + +sub Uniq_BAK{ + my %seen; + my @arr_uniq; + + foreach (@_){ + if(!exists($seen{$_})){ + $seen{$_} = undef; + push(@arr_uniq, $_); + } + } + + return @arr_uniq; +} + +sub Get_N50{ + my ($data, $total_len) = @_; + my @sorted = sort {$b <=> $a} @$data; + + my $total = 0; + my $i; + + for($i = 0; $i < @sorted; $i++){ + $total += $sorted[$i]; + if($total >= $total_len / 2){ + return $sorted[$i]; + } + } +} + +sub Get_N90{ + my ($data, $total_len) = @_; + my @sorted = sort {$b <=> $a} @$data; + + my $total = 0; + my $i; + + for($i = 0; $i < @sorted; $i++){ + $total += $sorted[$i]; + if($total >= $total_len * 0.9){ + return $sorted[$i]; + } + } +} + +sub StdDev{ + my ($array_ref) = @_; + my ($sum, $sum2) = (0, 0); + + if(!@$array_ref){ + return 0; + } + + foreach my $item (@$array_ref){ + $sum += $item; + } + my $mean = $sum / @$array_ref; + + foreach my $item (@$array_ref){ + $sum2 += ($item-$mean)**2; + } + + return sqrt($sum2/@$array_ref); +} + +# Created by Zhanyang Zhu +sub getNGaps{ + my ($seq, $minNGapSize) = @_; + my @gaps; + # Assert: $minNGapSize should not be less than 1 + while($seq =~ /((N|n){$minNGapSize,})/g){ + push @gaps, [$-[0] + 1, $+[0]]; + } + return (\@gaps); +} + +sub printNGaps{ + my ($ngap_ref, $ngapFileName, $minNGapSize) = @_; + open NG, ">$ngapFileName" || die ("ERROR: Can't open $ngapFileName for writing: $!\n"); + print NG "#min N gap size: $minNGapSize\n"; + my @chromosomes = sort {$a <=> $b} (keys %$ngap_ref); + foreach my $chromosome (@chromosomes){ + my $c_gaps_ref= $ngap_ref->{$chromosome}; + my $num_gaps = scalar @$c_gaps_ref; + for(my $i = 0; $i < $num_gaps; $i++){ + my $start = $ngap_ref->{$chromosome}->[$i]->[0] - 1; + my $end = $ngap_ref->{$chromosome}->[$i]->[1] - 1; + print NG "$chromosome\t$start\t$end\tgap\n"; + } + } + close(NG); +} + +sub GetNumLabelByDist{ + my ($distLabel) = @_; + my $saphyr = 1000; + my $irys = 1500; + + my $sumD = 0; ##sum of low dist + my $llc = 0; ##low dist label counts + my @numLabel = [1, 1]; + foreach my $d (@{$distLabel}) { + if( $d >= $irys) { + $numLabel[1]++; + $numLabel[2]++; + $sumD = 0; + $llc = 0; + } + elsif($d >= $saphyr && $d < $irys) { + $numLabel[1]++; + $sumD = 0; + $llc = 0; + } + else{ + $sumD += $d; + $llc++; + } + + if( $llc > 0 && ($sumD == 0 || $sumD > $saphyr) ){ ## add 1 for two consecutive close labels or more consecutive labels which combining distance bigger than resolution. + $numLabel[1]++; + $numLabel[2]++; + $sumD = 0; + $llc = 0; + } + } + + return @numLabel; +} + + +__END__ +/home/users/xzhou/PERL/fa2cmap_multi_color.pl -i XXX.fa -e bspq 2 CACTTAAA 1 -o ./ +svn propset svn:keywords "Id" fa2cmap_multi_color.pl +=COMMENT +use File::Spec; +use File::Spec::Functions; +File::Spec -> rel2abs($f) +use File::Basename; +my $dir = dirname($f_in_abs); +my $filename = basename($f_in_abs); +print "dir = $dir\n"; +print "filename = $filename\n"; +use File::Spec::Functions; +$f_log = catfile($dir, $filename); +=cut diff --git a/bin/findHalfcoverage.py b/bin/findHalfcoverage.py new file mode 100755 index 00000000..9a2f2340 --- /dev/null +++ b/bin/findHalfcoverage.py @@ -0,0 +1,175 @@ +#! /usr/bin/env python3 + +import re +import sys +from optparse import OptionParser + + +def load_scafsize(file): + # example is my.genome file, "scaffold\tsize" + + scafkey = {} + scaffile = open(file, "r") + for line in scaffile: + line = line.replace("\n", "") + name, size = re.split("\t", line) + scafkey[name] = size + + scaffile.close() + return scafkey + + +def getTotallength_undercov(file, cov, wiggleroom): + # example is bed file of coverage, + # scaffold_100_arrow 0 2 18 + + coverage_cutoff = cov + wiggleroom + + myfile = open(file, "r") + + lowcoverage_sum = 0 + prev_scaf = "" + scaf_lc = {} + + for line in myfile: + line = line.replace("\n", "") + objContents = re.split("\t", line) + + if prev_scaf != objContents[0]: + scaf_lc[prev_scaf] = lowcoverage_sum + lowcoverage_sum = 0 + + if float(objContents[3]) < coverage_cutoff: + length = float(objContents[2]) - float(objContents[1]) + lowcoverage_sum += length + + prev_scaf = objContents[0] + + scaf_lc[prev_scaf] = lowcoverage_sum + myfile.close() + + return scaf_lc + + +def get_cov_peaks(file): + # example is depthgraph.txt, "coverage\tbasepair count" + + myPeakFile = open(file, "r") + + rows = [] + for line in myPeakFile: + line = line.replace("\n", "") + items = re.split("\t", line) + rows.append(items) + + myPeakFile.close() + # print(rows[0]) + peakCov = sorted(rows, key=lambda cov: int(cov[1]), reverse=1)[0][0] + + if int(peakCov) == 0: + peakCov = sorted(rows, key=lambda cov: int(cov[1]), reverse=1)[1][0] + + halfPeak = int(peakCov) / 2 + qrtPeak = int(peakCov) / 4 + + # print("#Coverage Peak is %s, HalfPeak is %s, QuarterPeak is %s " % (peakCov, halfPeak, qrtPeak)) + + return (peakCov, halfPeak, qrtPeak) + + +def calc_coverage(scafsize, totallowcov): + # calculate the % for lowcov coverage over entire scaffold. + return totallowcov / scafsize * 100 + + +def getArguments(): + # get indivudual arguments from user + + parser = OptionParser(version="%prog 1.0") + parser.add_option( + "-c", "--coveragefile", action="store", type="string", dest="covfile", help="Scaffold Coverage filename" + ) + parser.add_option( + "-m", "--mygenome", action="store", type="string", dest="mygenome", help="mygenome file, scaffold - size file" + ) + parser.add_option( + "-d", + "--depthgraph", + action="store", + type="string", + dest="depth", + help="depthgraph file, bp count at each depth", + ) + parser.add_option( + "-w", + "--wiggle", + action="store", + type="float", + dest="wig", + default=5, + help="wiggle room to add to depth cutoff ie 30X + wiggleroom. Default is 5X", + ) + parser.add_option( + "--cut", + action="store", + type="float", + dest="covcut", + default=60, + help="%Number for coverage cutoff to include in results. ie 50% of scaffold needs to be under diploid peak etc. Default is 60%", + ) + parser.add_option( + "-t", + "--totalsize", + action="store", + type="int", + dest="totsize", + default=250000, + help="total size that determines max coverage boundary.", + ) + + (options, args) = parser.parse_args() + + if options.covfile == None or options.mygenome == None or options.depth == None: + print("Missing Options") + exit() + + return options + + +def main(): + # main program + + options = getArguments() + + scaffold_sizes = load_scafsize(options.mygenome) + (hapCov, dipCov, tetCov) = get_cov_peaks(options.depth) + scaffold_lowcovsum = getTotallength_undercov(options.covfile, dipCov, options.wig) + + for scaffoldName in scaffold_lowcovsum: + if scaffoldName == "": + continue + + # print("==" + scaffoldName) + totalSize = float(scaffold_sizes[scaffoldName]) + lowcovSize = float(scaffold_lowcovsum[scaffoldName]) + + coverage = calc_coverage(totalSize, lowcovSize) + + if coverage > options.covcut: + if totalSize > options.totsize: + print( + "\t".join( + [str(i) for i in [scaffoldName, int(totalSize), int(lowcovSize), "{:.1f}".format(coverage)]] + ) + ) + else: + print( + "\t".join( + [str(i) for i in [scaffoldName, int(totalSize), int(lowcovSize), "{:.1f}".format(coverage)]] + ) + ) + + +# -- script execuation -- # +if __name__ == "__main__": + main() diff --git a/bin/find_telomere b/bin/find_telomere new file mode 100755 index 00000000..b7d84a15 Binary files /dev/null and b/bin/find_telomere differ diff --git a/bin/generate_cram_csv.sh b/bin/generate_cram_csv.sh new file mode 100755 index 00000000..74490d9a --- /dev/null +++ b/bin/generate_cram_csv.sh @@ -0,0 +1,29 @@ +#!/bin/bash +cram_path=$1 +chunkn=0 +for cram in ${cram_path}/*.cram; do + rgline=$(samtools view -H $cram|grep "RG"|sed 's/\t/\\t/g'|sed "s/'//g") + + crampath=$(readlink -f ${cram}) + + ncontainers=$(zcat ${crampath}.crai|wc -l) + base=$(basename $cram .cram) + + from=0 + to=10000 + + + while [ $to -lt $ncontainers ] + do + echo $crampath,${crampath}.crai,${from},${to},${base},${chunkn},${rgline} + from=$((to+1)) + ((to+=10000)) + ((chunkn++)) + done + + if [ $from -le $ncontainers ] + then + echo $crampath,${crampath}.crai,${from},${ncontainers},${base},${chunkn},${rgline} + ((chunkn++)) + fi +done diff --git a/bin/get_busco_gene.sh b/bin/get_busco_gene.sh new file mode 100755 index 00000000..304b1e94 --- /dev/null +++ b/bin/get_busco_gene.sh @@ -0,0 +1,11 @@ +#!/bin/bash + +# get_busco_gene.sh +# ------------------- +# A shell script to convert busco full_table.tsv +# into bed format for use +# in JBrowse +# ------------------- +# Author = yy5 + +cat $1| grep -v '#'|awk '$2!="Missing"'| awk '{print $3"\t"$4"\t"$5"\t"$1"\t"$7"\t"$6"\t"$9}'| awk -F'\t' -v OFS='\t' '{if($7==""){$7="no_orthodb_link"};print $1,$2,$3,$4,$5,$6,$7}' diff --git a/bin/graph_overall_coverage.pl b/bin/graph_overall_coverage.pl new file mode 100755 index 00000000..174e61b7 --- /dev/null +++ b/bin/graph_overall_coverage.pl @@ -0,0 +1,34 @@ +#!/usr/bin/env perl + +# Script originally developed by Yumi Sims (yy5@sanger.ac.uk) + +use warnings; + +# my $file = shift; + +my ($file) = @ARGV; + +if (!@ARGV || ($ARGV[0] eq '--version')) { + print "1.0\n"; + exit 0; +} + +open (FILE, $file) || die "can't open file $file\n"; + +my %depthcount; +while (my $line = ) { + chomp $line; + my ($id, $start, $end, $depth) = split ("\t", $line); + my $length = $end - $start; + + if ($depthcount{$depth}){ + $depthcount{$depth} += $length; + } + else { + $depthcount{$depth} = $length; + } +} + +foreach my $depth (sort {$a<=>$b} keys %depthcount){ + print join("\t", $depth, $depthcount{$depth}) ."\n"; +} diff --git a/bin/juicer_tools.1.8.9_jcuda.0.8.jar b/bin/juicer_tools.1.8.9_jcuda.0.8.jar new file mode 100755 index 00000000..23e8968d Binary files /dev/null and b/bin/juicer_tools.1.8.9_jcuda.0.8.jar differ diff --git a/bin/mapids.py b/bin/mapids.py new file mode 100755 index 00000000..c2655aca --- /dev/null +++ b/bin/mapids.py @@ -0,0 +1,56 @@ +#!/usr/bin/env python + +# Script originally developed by Yumi Sims (yy5@sanger.ac.uk) + +from hashlib import new +import optparse + + +def read_agp(agpfile): + return {l.split("\t")[5]: l.split("\t")[0:3] for l in open(agpfile, "r")} + + +def get_pos(agp, mylist): + myid = mylist[0] + newpos = [agp[myid][0], int(mylist[1]) + int(agp[myid][1]) - 1, int(mylist[2]) + int(agp[myid][1]) - 1] + return newpos + + +def makestring(myitem): + return str(myitem) + + +def main(): + parser = optparse.OptionParser(version="%prog 1.0") + parser.add_option( + "-i", + "--bed", + dest="bed", + default="default.bed", + ) + parser.add_option( + "-r", + "--agp", + dest="agp", + default="default.agp", + ) + + options, remainder = parser.parse_args() + + agp = read_agp(options.agp) + + for line in open(options.bed, "r"): + linelist = line.strip().split("\t") + newreflist = get_pos(agp, [x for x in linelist[0:3]]) + newqlist = get_pos(agp, [linelist[3], linelist[6], linelist[7]]) + + linelist[0:3] = newreflist + linelist[3] = newqlist[0] + linelist[6:8] = newqlist[-2:] + + if newreflist != newqlist: + print("\t".join(map(makestring, linelist))) + + +if __name__ == "__main__": + main() diff --git a/bin/mummer2bed.py b/bin/mummer2bed.py new file mode 100755 index 00000000..3673e9bd --- /dev/null +++ b/bin/mummer2bed.py @@ -0,0 +1,99 @@ +#!/usr/bin/env python + +# Script originally developed by Yumi Sims (yy5@sanger.ac.uk) + +import itertools, datetime, os, re, sys, time +import optparse +import sys +import io +import string +import random + + +def deal_headline(headline): + direction = "+" + qchrom = "" + qlen = "" + hl_comp = headline.strip().split(" ") + if "Reverse" in headline: + direction = "-" + qchrom = hl_comp[1] + qlen = hl_comp[6] + else: + qchrom = hl_comp[1] + qlen = hl_comp[5] + return qchrom + "\t" + str(qlen) + "\t" + direction + + +def deal_line(line): + (refid, refpos, qpos, lmotif, qid, qlen, strand) = line.split("\t") + refend = str(int(refpos) + int(lmotif) - 1) + if strand == "+": + qend = str(int(qpos) + int(lmotif) - 1) + else: + qend = str(int(qpos) - int(lmotif) + 1) + return ( + refid + + "\t" + + refpos + + "\t" + + refend + + "\t" + + qid + + "\t" + + lmotif + + "\t" + + strand + + "\t" + + qpos + + "\t" + + qend + + "\t" + + qlen + ) + + +parser = optparse.OptionParser(version="%prog 1.0") +parser.add_option( + "-i", + "--input", + dest="input_mummerfile", + default="default.input", +) +parser.add_option( + "-l", + "--motiflen", + dest="motiflen", + default="default.motiflen", +) + +options, remainder = parser.parse_args() + +motiflen = options.motiflen + +inFile = open(options.input_mummerfile, "r") + +keepCurrentSet = False +headline = "" +bedlist = [] +for line in inFile: + if line.startswith(">"): + keepCurrentSet = False + if keepCurrentSet: + mypattern = re.compile("(\S+)\s+(\d+)\s+(\d+)\s+(\d+)$") + num = mypattern.findall(line.strip()) + refid = num[0][0] + refpos = num[0][1] + qpos = num[0][2] + mlen = num[0][3] + if int(mlen) > int(motiflen): + bedline = refid + "\t" + refpos + "\t" + qpos + "\t" + mlen + "\t" + deal_headline(headline) + bedlist.append(bedline) + if line.startswith(">"): + keepCurrentSet = True + headline = line + +inFile.close() + +for line in bedlist: + print(deal_line(line)) diff --git a/bin/paf_to_bed.sh b/bin/paf_to_bed.sh new file mode 100755 index 00000000..7de63334 --- /dev/null +++ b/bin/paf_to_bed.sh @@ -0,0 +1,18 @@ +#!/bin/bash + +# paf_to_bed12.sh +# ------------------- +# A shell script to convert a +# paf into bed format for use +# in JBrowse +# ------------------- +# Author = yy5 + +version='1.0.0' + +if [ $1 == '-v']; +then + echo "$version" +else + cat $1 | awk 'BEGIN{FS="\t";}{a[$1]++;if(a[$1]==2)print v[$1] ORS $0;if(a[$1]>2)print;v[$1]=$0;}' | awk '$(NF+1) = ($10/$11)*100' | awk '$(NF+1) = ($10/$2)*100' | awk -vOFS='\t' '{print $6,$8,$9,$1,$2,$10,$(NF-1),$NF}' > $2 +fi diff --git a/bin/rename_cmapids.pl b/bin/rename_cmapids.pl new file mode 100755 index 00000000..b6107dae --- /dev/null +++ b/bin/rename_cmapids.pl @@ -0,0 +1,215 @@ +#! /usr/local/bin/perl + +# Script originally developed by Yumi Sims (yy5@sanger.ac.uk) + +use warnings; +use strict; + +use Getopt::Long; + +my ($cmapfile, $xmapfile, $smapfile, $indelfile, $namefile, $bedfile, $idx_key, $agp, $multi, $version); + +GetOptions ('cmapfile:s' => \ $cmapfile, + 'xmapfile:s' => \ $xmapfile, + 'smapfile:s' => \ $smapfile, + 'indelfile:s' => \ $indelfile, + 'namefile:s' => \ $namefile, + 'bedfile:s' => \ $bedfile, + 'idx_key:s' => \ $idx_key, + 'agprev:s' => \ $agp, + 'multi!' => \ $multi, # rename xmap genome map ids for multiple mappings + 'version' => \ $version + ); + +if ($version) { + print "1.0\n"; + exit 0; +} + +my $namedata; +if ($idx_key){ + if ($agp){ + $namedata = readfiles($idx_key, "agp"); + } + else { + $namedata = readfiles($idx_key, "idx"); + } +} +else { + $namedata = ($cmapfile) ? readfiles($namefile, "cmap") : readfiles($namefile, "xmap"); +} + +if ($cmapfile) { + open (CMAP, $cmapfile); + + my %idx; + foreach my $line (){ + chomp $line; + + if ($line =~ /#/){ + print $line."\n"; + next; + } + + my @F = split (/\t/, $line); + + my $key; + if ($idx_key){ + $key = $F[0]; + } + else { + ($key = $F[1]) =~ s/\.0//; + } + + die "misssing name at $key\n" if !($$namedata{$key}); + #print $$namedata{$key}."-$key\n"; + + print join ("\t", $$namedata{$key}, $F[1], $F[2], $F[3], $F[4], $F[5], $F[6], $F[7], $F[8])."\n"; + + # -if no original key file avaialble) + $idx{$F[0]} = { name => $$namedata{$key}, + length => $key, + } if (!$idx{$F[0]} && !$idx_key); + } + close CMAP; + + # -if no original key file avaialble) + if (!$idx_key){ + open (KEY, ">>key.out"); + + foreach my $index (sort {$a <=> $b} keys %idx){ + print KEY join ("\t", $index, $idx{$index}{name}, $idx{$index}{length}) ."\n"; + } + close KEY; + } +} +elsif ($xmapfile){ + + open (XMAP, $xmapfile); + + my %idx; + foreach my $line (){ + chomp $line; + + if ($line =~ /#/){ + print $line."\n"; + next; + } + my @F = split (/\t/, $line); + + print join ("\t", $F[0], $F[1], $$namedata{$F[2]}, $F[3], $F[4], $F[5], $F[6], $F[7], $F[8], $F[9], $F[10], $F[11], $F[12], $F[13])."\n"; + + } + close (XMAP); +} +elsif ($indelfile){ + + open (INDEL, $indelfile); + foreach my $line (){ + chomp $line; + + if ($line =~ /#/){ + print $line."\n"; + next; + } + my @F = split (/\t/, $line); + print join ("\t", $F[0], $F[1], $$namedata{$F[2]}, $$namedata{$F[3]}, $F[4], $F[5], $F[6], $F[7], $F[8], $F[9], $F[10], $F[11], $F[12])."\n"; + + } + close INDEL; +} +elsif ($smapfile){ + # PLACEHOLDER +} +elsif ($bedfile){ + + open (BED, $bedfile); + foreach my $line (){ + chomp $line; + + if ($line =~ /#/){ + print $line."\n"; + next; + } + my @F = split (/\t/, $line); + my $featcount = @F-1; + die "Something wrong, missing ID to key for $F[0]\n" if (!$$namedata{$F[0]}); + + print join ("\t", $$namedata{$F[0]}, @F[1..$featcount])."\n"; + + } + close BED + +} +elsif ($agp) { + &AGPrev($agp, $namedata); +} +else { + die "missing parameter\n"; +} + +#=====================# +# SUBROUTINES # +#=====================# + +# Read standard files +sub readfiles { + my ($file, $type ) = @_; + + open (FILE, $file) || die "can't open file\n"; + + my %data; + foreach (){ + chomp $_; + next if ($_ =~ /#/); + my @entries = split (/\t/, $_); + + if ($type eq "cmap"){ + $data{$entries[1]} = $entries[0]; + } + elsif ($type =~ /xmap|idx/){ + $data{$entries[0]} = $entries[1]; + } + elsif ($type =~ /agp/){ + $data{$entries[1]} = $entries[0]; + } + else { + die "Missing type at readfiles\n"; + } + } + close FILE; + return \%data; +} + + +# Add Bionano idx to header whilst reading file +sub AGPrev { + + my ($file, $nkey ) = @_; + + open (FILE, $file) || die "can't open file\n"; + + my %data; + foreach (){ + chomp $_; + + if ($_ =~ /#/){ + print "$_\n"; + next; + } + + my @F = split (/\t/, $_); + + if ($F[4] eq "N"){ + print "$_\n"; + } + else { + my $idx_num = $$nkey{$F[5]}; + my $newID = $F[5]. ":IDX.$idx_num"; + + $newID =~ s/(scaffold|chromosome)\:CURRENT\://; + print join ("\t", @F[0..4], $newID, @F[6..8])."\n"; + } + } + close(FILE); +} diff --git a/bin/split_genomes_for_ensembl.pl b/bin/split_genomes_for_ensembl.pl new file mode 100755 index 00000000..5840b833 --- /dev/null +++ b/bin/split_genomes_for_ensembl.pl @@ -0,0 +1,74 @@ +#!/usr/bin/env perl + +# Script originally developed by Yumi Sims (yy5@sanger.ac.uk) + +# +# Take a genome fasta file, and creates a fasta file and agp +# that is suitable for loading into Ensembl +# +# If the genome is already suitable for loading (i.e. all of the +# sequences are small enough for direct loading), then the script +# says so and does nothing +# + +use strict; + +use Bio::SeqIO; +use Getopt::Long; + +my $MAX_CONTIG_LEN = 500000; + +my ($genome_fa, + $contig_fa_file, + $agp_file) = @ARGV; + +if (!@ARGV || ($ARGV[0] eq '--version')) { + print "1.0\n"; + exit 0; +} + +my $seqio = Bio::SeqIO->new(-format => 'fasta', + -file => ($genome_fa =~ /\.gz$/) ? "gunzip -c $genome_fa |" : $genome_fa, +); + +my (@toplevels, $need_agp, $count); + +while (my $seq = $seqio->next_seq) { + if ($seq->length > $MAX_CONTIG_LEN) { + $need_agp = 1; + } + push @toplevels, $seq; +} + +if (not $need_agp) { + print "All sequences are small enough for direct loading. Did not create AGP\n"; +} else { + my $outseqio = Bio::SeqIO->new(-format => 'fasta', + -file => ">$contig_fa_file"); + open(my $agp_fh, ">$agp_file") or die "Could not open $agp_file for writing\n"; + + foreach my $seq (@toplevels) { + if ($seq->length < $MAX_CONTIG_LEN) { + $outseqio->write_seq($seq); + printf($agp_fh "%s\t%d\t%d\t%d\tW\t%s\t%d\t%d\t+\n", $seq->id, 1, $seq->length, ++$count, $seq->id, 1, $seq->length); + } else { + print STDERR "GOT ONE\n"; + my $seg_count = 1; + for(my $i = 0; $i < $seq->length; $i += $MAX_CONTIG_LEN) { + my $start = $i + 1; + my $end = $start + $MAX_CONTIG_LEN - 1; + $end = $seq->length if $end > $seq->length; + + my $new_id = sprintf("%s.%d", $seq->id, $seg_count++); + + my $seq_seg = Bio::PrimarySeq->new( -id => $new_id, + -seq => substr($seq->seq, $start - 1, $end - $start + 1)); + $outseqio->write_seq($seq_seg); + + printf($agp_fh "%s\t%d\t%d\t%d\tW\t%s\t%d\t%d\t+\n", $seq->id, $start, $end, ++$count, $seq_seg->id, 1, $seq_seg->length); + } + } + } +} + +exit(0); diff --git a/bin/telomere.jar b/bin/telomere.jar new file mode 100755 index 00000000..9d986797 Binary files /dev/null and b/bin/telomere.jar differ diff --git a/bin/treeval-dataprep/GA_csv_gen.py b/bin/treeval-dataprep/GA_csv_gen.py new file mode 100644 index 00000000..adb3eaa5 --- /dev/null +++ b/bin/treeval-dataprep/GA_csv_gen.py @@ -0,0 +1,77 @@ +""" +---- Gene Alignment CSV Generator ---- + By Damon-Lee Pointon (dp24) + +This script generates the csv files + required by TreeVal (the gene alignment + sub-workflows). + +Script generates a csv per organism.assembly + in their respective classT folder + +USAGE: + python3 GA_data_sorting.py + +TODO: ADD argparse + version data +""" + +import argparse +import sys +import os +from os import path + + +def list_dir(dir_loc: str): + return [os.path.join(dir_loc, i) for i in os.listdir(dir_loc) if path.isdir(os.path.join(dir_loc, i))] + + +def get_file_list(root: str): + return [os.path.join(path, name) for path, subdirs, files in os.walk(root) for name in files] + + +def list_2_dict(file_list: list): + file_dict = {} + path_list = [] + for i in file_list: + path_list = i.split("/") + if path_list[-1].lower() in ["readme.txt", "readme"]: + pass + else: + file_dict[path_list[-1]] = [path_list[-3], path_list[-2], i] + return file_dict, path_list[-3] + + +def save_data(dict_of_data: dict, save_loc: str, org_accession: str): + save_path = f"{save_loc}/csv_data/{org_accession}-data.csv" + if os.path.exists(save_path): + os.remove(save_path) + else: + pass + print(f"Generating CSV for:\t{org_accession}\nSave Path:\t\t{save_path}") + with open(save_path, "w+") as new_csv: + new_csv.write("org,type,data_file") + for x, y in dict_of_data.items(): + new_csv.write(f"\n{y[0]},{y[1]},{y[2]}") + + +def main(): + gene_alignment_dir = sys.argv[1] + clade_list = list_dir(gene_alignment_dir) + master_list = [] + + for i in clade_list: + org_list = list_dir(i) + for ii in org_list: + accession_list = list_dir(ii) + for iii in accession_list: + print(f'============> {iii.split("/")[-1]} -- {i.split("/")[-1]}') + data_list = list_dir(iii) + master_list = [] + master_list += [get_file_list(j) for j in data_list] + file_dict, org = list_2_dict([item for sublist in master_list for item in sublist]) + save_data(file_dict, i, org) + print("GA_csv_gen: Complete") + + +if __name__ == "__main__": + main() diff --git a/bin/treeval-dataprep/GA_data_prep.py b/bin/treeval-dataprep/GA_data_prep.py new file mode 100644 index 00000000..0c72db09 --- /dev/null +++ b/bin/treeval-dataprep/GA_data_prep.py @@ -0,0 +1,231 @@ +#!/usr/local/bin/python + +PRINT_ERROR = """Does not exist\n + Get module installed before import attempt\n + If running server side then contact your admin""" + +try: + import sys + + if sys.version_info[0] < 3 and sys.version_info[1] < 6: + raise Exception( + """Must be using Python 3.6 for the full + functionality of this script""" + ) + if sys.version_info[0] >= 3 and sys.version_info[1] >= 6: + print("Your using at least Version 3.6, You are good to go...") +except ImportError: + print(f"sys not imported \n {PRINT_ERROR}") + sys.exit(0) + +try: + import os + + print("os imported") +except ImportError: + print(f"os not imported \n {PRINT_ERROR}") + sys.exit(0) + +try: + import argparse + + print("argparse imported") +except ImportError: + print(f"argparse not imported \n {PRINT_ERROR}") + sys.exit(0) + +try: + import re + + print("regex imported") +except ImportError: + print(f"re not imported \n {PRINT_ERROR}") + sys.exit(0) + +DOCSTRING = """ +---------------------------------------------------------------- + Gene Alignment Data Prep + By Damon-Lee Pointon (dp24) +---------------------------------------------------------------- +This script takes an input file and chunks it into 1000 sequence +files for cds and rna files or a user defined number (default 100) +for pep and cdna sequences. + +---------------------------------------------------------------- +Usage: + +GA_data_prep.py {name}-{accession}.{datatype}.fasta {ncbi|ens} {chunk} + +File name example is: ThalassiosiraPseudonana-ASM14940v2.rna.fasta +---------------------------------------------------------------- +""" + + +def get_command_args(args=None): + parser = argparse.ArgumentParser( + prog="GA_data_prep.py (Python 3)", description=DOCSTRING, formatter_class=argparse.RawDescriptionHelpFormatter + ) + + parser.add_argument("FASTA", action="store", help="Input unzipped fasta file", type=str) + + parser.add_argument("DB", action="store", help="database of origin", choices=["ncbi", "ens"], type=str) + + parser.add_argument("CHUNK", action="store", help="Chunk size for pep and cdna", default=100, type=int) + + parser.add_argument("-v", "--version", action="version", version="v7.0.0") + + options = parser.parse_args(args) + return options + + +def entryfunction(file, dtype, org, entryper, filesavedto, options): + """ + The entryfunction function splits a FASTA file into a defined + number of entries per file, pep == 2000 enteries and everything + else is split into 5000 enteries. + :param seq_file: + :param org: + :param directory: + :param entryper: + :param option: + """ + print("Entryfunction called") + count = 0 + filecounter = 0 + entry = [] + print(file) + if os.path.exists(file): + print("File found at %s", file) + with open(file, "r") as filetoparse: + print("Renaming headers") + for name, seq in read_fasta(filetoparse): + new_name = massage(name, options) + # print(new_name) # Here as a manual check of headers + nameseq = new_name, seq + entry.append(nameseq) + count += 1 + + if count == entryper: + filecounter += 1 + with open(f"{filesavedto}/{org}{filecounter}{dtype}.MOD.fa", "w") as done: + for head, body in entry: + done.write(f"{head}\n{body}\n") + count = 0 + entry = [] + print(f"File saved: -- {filesavedto}/{org}{filecounter}{dtype}.MOD.fa") + + filecounter += 1 + + with open(f"{filesavedto}/{org}{filecounter}{dtype}.MOD.fa", "w") as done: + for head, body in entry: + done.write(f"{head}\n{body}\n") + entry = [] + + print(f"File saved: -- {filesavedto}/{org}{filecounter}{dtype}.MOD.fa") + + +def massage(name, options): + """ + A function to 'massage' the sequence headers into a more human + readable style + :param option: + :param name: + :return name: + """ + + if name.startswith(">"): + if options.DB == "ncbi": + gene_symbol = re.search(r"gene=([A-Z]\w+)", name) + ens_code = re.search(r"GeneID:([1-9])\w+", name) + else: + gene_symbol = re.search(r"symbol:(\S+)", name) + ens_code = re.search(r"ENS(\w+)T(\w+.\d+)", name) + + if gene_symbol: + gene_symbol = gene_symbol.group(1) + elif gene_symbol is None: + gene_symbol = re.search(r"gene:(\S+)", name) + + if gene_symbol: + gene_symbol = gene_symbol.group(1) + + elif gene_symbol is None: + gene_symbol = re.search(r"PREDICTED: (.+) \[", name) + if gene_symbol: + gene_symbol = gene_symbol.group(1) + gene_symbol = gene_symbol.split() + gene_symbol = "_".join(gene_symbol) + else: + gene_symbol = "MissingInfo" + + if ens_code: + ens_code = ens_code.group(0) + + elif ens_code is None: + ens_code = re.search(r">(\S+)", name) + if ens_code: + ens_code = ens_code.group(1) + elif ens_code is None: + ens_code = "NoEnsCode" + + # print('Gene Symbol found as: %s', gene_symbol) + # print('Ens Code found as: %s', ens_code) + if gene_symbol == "MissingInfo": + # print('MissingInfo replaced with %s', ens_code) + gene_symbol = ens_code + name = f">{gene_symbol}({ens_code})" + + else: + print("Somethings gone wrongs, headers are wrong") + sys.exit(0) + + return name + + +def read_fasta(filetoparse): + """ + A function which opens and splits a fasta into name and seq. + :param filetoparse: + """ + print("Read_fasta called") + counter = 0 + name, seq = None, [] + + for line in filetoparse: + line = line.rstrip() + + if line.startswith(">"): + if name: + yield name, "".join(seq) + name, seq = line, [] + else: + seq.append(line) + + if name: + yield name, "".join(seq) + counter += 1 + + +def main(): + options = get_command_args() + file = options.FASTA + dtype = file.split(".")[1] + org = file.split(".")[0] + + print(f"WORKING ON:\t\t{dtype}--{org}") + + directory = f"./{org.split('-')[0]}/{org.split('-')[0]}.{org.split('-')[1]}/{dtype}" + + try: + os.makedirs(directory, mode=0o777) + except: + print("probably already exists") + + entryper = [1000 if dtype in ["cds", "rna"] else options.CHUNK] + + print(f"Records per file:\t{int(entryper[0])}") + entryfunction(file, dtype, org.split("-")[0], int(entryper[0]), directory, options) + + +if __name__ == "__main__": + main() diff --git a/conf/base.config b/conf/base.config old mode 100644 new mode 100755 index d89a01e2..55b5c5ec --- a/conf/base.config +++ b/conf/base.config @@ -1,6 +1,6 @@ /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - nf-core/treeval Nextflow base config file + sanger-tol/treeval Nextflow base config file ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ A 'blank slate' config file, appropriate for general use on most high performance compute environments. Assumes that all software is installed and available on @@ -9,60 +9,173 @@ */ process { + cpus = { check_max( 1 * task.attempt, 'cpus' ) } + memory = { check_max( 6.GB * task.attempt, 'memory' ) } + time = { check_max( 4.h * task.attempt, 'time' ) } - cpus = { check_max( 1 * task.attempt, 'cpus' ) } - memory = { check_max( 6.GB * task.attempt, 'memory' ) } - time = { check_max( 4.h * task.attempt, 'time' ) } - - errorStrategy = { task.exitStatus in [143,137,104,134,139] ? 'retry' : 'finish' } + errorStrategy = { task.exitStatus in ((130..145) + 104) ? 'retry' : 'finish' } maxRetries = 1 maxErrors = '-1' - withName:SAMTOOLS_MERGE { - memory = { check_max( 50.GB * task.attempt, 'memory') } - } - - // 20GB * (task attempt * 2) = 40GB, 80GB, 120GB - withName:MUMMER { - cpus = { check_max( 12 * task.attempt, 'cpus' ) } - memory = { check_max( 20.GB * Math.ceil( task.attempt * 2 ), 'memory' ) } - time = { check_max( 2.h * task.attempt, 'time' ) } - } - // Process-specific resource requirements // NOTE - Please try and re-use the labels below as much as possible. // These labels are used and recognised by default in DSL2 files hosted on nf-core/modules. // If possible, it would be nice to keep the same label naming convention when // adding in your local modules too. - // TODO nf-core: Customise requirements for specific processes. // See https://www.nextflow.io/docs/latest/config.html#config-process-selectors + withLabel:process_single { + cpus = { check_max( 1 , 'cpus' ) } + memory = { check_max( 6.GB * task.attempt, 'memory' ) } + time = { check_max( 4.h * task.attempt, 'time' ) } + } + withLabel:process_low { cpus = { check_max( 2 * task.attempt, 'cpus' ) } memory = { check_max( 12.GB * task.attempt, 'memory' ) } time = { check_max( 4.h * task.attempt, 'time' ) } } + withLabel:process_medium { cpus = { check_max( 6 * task.attempt, 'cpus' ) } memory = { check_max( 36.GB * task.attempt, 'memory' ) } time = { check_max( 8.h * task.attempt, 'time' ) } } + withLabel:process_high { cpus = { check_max( 12 * task.attempt, 'cpus' ) } memory = { check_max( 72.GB * task.attempt, 'memory' ) } time = { check_max( 16.h * task.attempt, 'time' ) } } + withLabel:process_long { time = { check_max( 20.h * task.attempt, 'time' ) } } + withLabel:process_high_memory { memory = { check_max( 200.GB * task.attempt, 'memory' ) } } + withLabel:error_ignore { errorStrategy = 'ignore' } + withLabel:error_retry { errorStrategy = 'retry' maxRetries = 2 } + + // CUSTOM CONFIGS + // TODO: add process.tiny + + withName:CUSTOM_DUMPSOFTWAREVERSIONS { + cache = false + } + + withName:SAMTOOLS_MERGE { + cpus = { check_max( 16 * 1, 'cpus' ) } + memory = { check_max( 150.GB * task.attempt, 'memory') } + } + + // RESOURCES: MEMORY INTENSIVE STEPS, SOFTWARE TO BE UPDATED TO COMBAT THIS + withName: '.*:.*:SELFCOMP:(SELFCOMP_MAPIDS|SELFCOMP_MUMMER2BED|SELFCOMP_SPLITFASTA|BEDTOOLS_MERGE)' { + cpus = { check_max( 10 * task.attempt, 'cpus' ) } + memory = { check_max( 120.GB * task.attempt, 'memory' ) } + time = { check_max( 12.h * task.attempt, 'time' ) } + } + + withName: SELFCOMP_ALIGNMENTBLOCKS { + cpus = { check_max( 20 * task.attempt, 'cpus' ) } + memory = { check_max( 120.GB * task.attempt, 'memory' ) } + time = { check_max( 18.h * task.attempt, 'time' ) } + } + + + // RESOURCES: CHANGES TO FREQUENT FAILURES BELOW THIS MEM POINT + withName: '.*:.*:GENE_ALIGNMENT:.*:(MINIPROT_ALIGN|MINIMAP2_ALIGN)' { + memory = { check_max( 50.GB * Math.ceil( task.attempt * 1.5 ) , 'memory' ) } + time = { check_max( 10.h * task.attempt, 'time' ) } + } + + // Standard parameters, covers most insecta + withName: '.*:.*:LONGREAD_COVERAGE:(MINIMAP2_ALIGN|MINIMAP2_ALIGN_SPLIT)' { + cpus = { check_max( 16 * 1, 'cpus' ) } + memory = { check_max( 100.GB * task.attempt, 'memory' ) } + time = { check_max( 18.h * task.attempt, 'time' ) } + } + + // For Large complex genomes > 4Gb + // withName: '.*:.*:LONGREAD_COVERAGE:(MINIMAP2_ALIGN|MINIMAP2_ALIGN_SPLIT)' { + //cpus = { check_max( 20 * 1, 'cpus' ) } + //memory = { check_max( 400.GB * task.attempt, 'memory' ) } + // time = { check_max( 300.h * task.attempt, 'time' ) } + //} + + withName: '.*:.*:LONGREAD_COVERAGE:SAMTOOLS_SORT' { + cpus = { check_max( 8 * 1, 'cpus' ) } + } + + // 25GB * (task attempt * 2) = 50GB, 100GB, 150GB + withName:MUMMER { + cpus = { check_max( 12 * task.attempt, 'cpus' ) } + memory = { check_max( 25.GB * Math.ceil( task.attempt * 2 ), 'memory' ) } + } + + withName:UCSC_BEDGRAPHTOBIGWIG { + cpus = { check_max( 2 * task.attempt, 'cpus' ) } + memory = { check_max( 20.GB * task.attempt, 'memory' ) } + } + + withName: CRAM_FILTER_ALIGN_BWAMEM2_FIXMATE_SORT { + cpus = { check_max( 16 * 1, 'cpus' ) } + memory = { check_max( 130.GB * task.attempt, 'memory' ) } + } + + withName: PRETEXTMAP_STANDRD{ + cpus = { check_max( 16 * 1, 'cpus' ) } + memory = { check_max( 3.GB * task.attempt, 'memory' ) } + } + + withName: PRETEXTMAP_HIGHRES { + cpus = { check_max( 20 * task.attempt, 'cpus' ) } + memory = { check_max( 16.GB * task.attempt, 'memory' ) } + } + + withName: SNAPSHOT_HRES { + cpus = { check_max( 1 * task.attempt, 'cpus' ) } + memory = { check_max( 50.GB * task.attempt, 'memory' ) } + } + + withName: JUICER_TOOLS_PRE { + cpus = { check_max( 20 * task.attempt, 'cpus' ) } + memory = { check_max( 100.GB * task.attempt, 'memory' ) } + } + + withName: BWAMEM2_INDEX { + memory = { check_max( 50.GB * task.attempt, 'memory' ) } + } + + // add a cpus 16 if bam.size() >= 50GB + withName: '(SAMTOOLS_MARKDUP|BAMTOBED_SORT)' { + cpus = { check_max( 12 * 1, 'cpus' ) } + memory = { check_max( 100.GB * task.attempt, 'memory' ) } + } + + withName: COOLER_CLOAD { + cpus = { check_max( 16 * 1, 'cpus' ) } + memory = { check_max( 100.GB * task.attempt, 'memory' ) } + } + + withName: BUSCO { + cpus = { check_max( 16 * task.attempt, 'cpus' ) } + memory = { check_max( 50.GB * task.attempt, 'memory' ) } + time = { check_max( 20.h * task.attempt, 'time' ) } + } + + // Large Genomes > 4Gb + //withName: BUSCO { + //cpus = { check_max( 30 * task.attempt, 'cpus' ) } + //memory = { check_max( 120.GB * task.attempt, 'memory' ) } + //time = { check_max( 300.h * task.attempt, 'time' ) } + //} } diff --git a/conf/digest.config b/conf/digest.config deleted file mode 100644 index 5712d223..00000000 --- a/conf/digest.config +++ /dev/null @@ -1,33 +0,0 @@ -params { - outdir = "output/" - publish_dir_mode = "copy" - enable_conda = false - singularity_pull_docker_container = false -} - -process { - cpus = 2 - memory = 3.GB - time = 2.h -} - -if ("$PROFILE" == "singularity") { - singularity.enabled = true - singularity.autoMounts = true -} else if ("$PROFILE" == "conda") { - params.enable_conda = true -} else { - docker.enabled = true - docker.userEmulation = true - docker.runOptions = "--platform linux/x86_64" -} - -// Increase time available to build Conda environment -conda { createTimeout = "120 min" } - -// Load test_data.config containing paths to test data -//includeConfig 'test_data.config' - -manifest { - nextflowVersion = '!>=21.10.0' -} diff --git a/conf/igenomes.config b/conf/igenomes.config deleted file mode 100644 index 7a1b3ac6..00000000 --- a/conf/igenomes.config +++ /dev/null @@ -1,432 +0,0 @@ -/* -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - Nextflow config file for iGenomes paths -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - Defines reference genomes using iGenome paths. - Can be used by any config that customises the base path using: - $params.igenomes_base / --igenomes_base ----------------------------------------------------------------------------------------- -*/ - -params { - // illumina iGenomes reference file paths - genomes { - 'GRCh37' { - fasta = "${params.igenomes_base}/Homo_sapiens/Ensembl/GRCh37/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Homo_sapiens/Ensembl/GRCh37/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Homo_sapiens/Ensembl/GRCh37/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Homo_sapiens/Ensembl/GRCh37/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Homo_sapiens/Ensembl/GRCh37/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Homo_sapiens/Ensembl/GRCh37/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Homo_sapiens/Ensembl/GRCh37/Annotation/Genes/genes.bed" - readme = "${params.igenomes_base}/Homo_sapiens/Ensembl/GRCh37/Annotation/README.txt" - mito_name = "MT" - macs_gsize = "2.7e9" - blacklist = "${projectDir}/assets/blacklists/GRCh37-blacklist.bed" - } - 'GRCh38' { - fasta = "${params.igenomes_base}/Homo_sapiens/NCBI/GRCh38/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Homo_sapiens/NCBI/GRCh38/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Homo_sapiens/NCBI/GRCh38/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Homo_sapiens/NCBI/GRCh38/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Homo_sapiens/NCBI/GRCh38/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Homo_sapiens/NCBI/GRCh38/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Homo_sapiens/NCBI/GRCh38/Annotation/Genes/genes.bed" - mito_name = "chrM" - macs_gsize = "2.7e9" - blacklist = "${projectDir}/assets/blacklists/hg38-blacklist.bed" - } - 'GRCm38' { - fasta = "${params.igenomes_base}/Mus_musculus/Ensembl/GRCm38/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Mus_musculus/Ensembl/GRCm38/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Mus_musculus/Ensembl/GRCm38/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Mus_musculus/Ensembl/GRCm38/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Mus_musculus/Ensembl/GRCm38/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Mus_musculus/Ensembl/GRCm38/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Mus_musculus/Ensembl/GRCm38/Annotation/Genes/genes.bed" - readme = "${params.igenomes_base}/Mus_musculus/Ensembl/GRCm38/Annotation/README.txt" - mito_name = "MT" - macs_gsize = "1.87e9" - blacklist = "${projectDir}/assets/blacklists/GRCm38-blacklist.bed" - } - 'TAIR10' { - fasta = "${params.igenomes_base}/Arabidopsis_thaliana/Ensembl/TAIR10/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Arabidopsis_thaliana/Ensembl/TAIR10/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Arabidopsis_thaliana/Ensembl/TAIR10/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Arabidopsis_thaliana/Ensembl/TAIR10/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Arabidopsis_thaliana/Ensembl/TAIR10/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Arabidopsis_thaliana/Ensembl/TAIR10/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Arabidopsis_thaliana/Ensembl/TAIR10/Annotation/Genes/genes.bed" - readme = "${params.igenomes_base}/Arabidopsis_thaliana/Ensembl/TAIR10/Annotation/README.txt" - mito_name = "Mt" - } - 'EB2' { - fasta = "${params.igenomes_base}/Bacillus_subtilis_168/Ensembl/EB2/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Bacillus_subtilis_168/Ensembl/EB2/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Bacillus_subtilis_168/Ensembl/EB2/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Bacillus_subtilis_168/Ensembl/EB2/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Bacillus_subtilis_168/Ensembl/EB2/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Bacillus_subtilis_168/Ensembl/EB2/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Bacillus_subtilis_168/Ensembl/EB2/Annotation/Genes/genes.bed" - readme = "${params.igenomes_base}/Bacillus_subtilis_168/Ensembl/EB2/Annotation/README.txt" - } - 'UMD3.1' { - fasta = "${params.igenomes_base}/Bos_taurus/Ensembl/UMD3.1/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Bos_taurus/Ensembl/UMD3.1/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Bos_taurus/Ensembl/UMD3.1/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Bos_taurus/Ensembl/UMD3.1/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Bos_taurus/Ensembl/UMD3.1/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Bos_taurus/Ensembl/UMD3.1/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Bos_taurus/Ensembl/UMD3.1/Annotation/Genes/genes.bed" - readme = "${params.igenomes_base}/Bos_taurus/Ensembl/UMD3.1/Annotation/README.txt" - mito_name = "MT" - } - 'WBcel235' { - fasta = "${params.igenomes_base}/Caenorhabditis_elegans/Ensembl/WBcel235/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Caenorhabditis_elegans/Ensembl/WBcel235/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Caenorhabditis_elegans/Ensembl/WBcel235/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Caenorhabditis_elegans/Ensembl/WBcel235/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Caenorhabditis_elegans/Ensembl/WBcel235/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Caenorhabditis_elegans/Ensembl/WBcel235/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Caenorhabditis_elegans/Ensembl/WBcel235/Annotation/Genes/genes.bed" - mito_name = "MtDNA" - macs_gsize = "9e7" - } - 'CanFam3.1' { - fasta = "${params.igenomes_base}/Canis_familiaris/Ensembl/CanFam3.1/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Canis_familiaris/Ensembl/CanFam3.1/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Canis_familiaris/Ensembl/CanFam3.1/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Canis_familiaris/Ensembl/CanFam3.1/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Canis_familiaris/Ensembl/CanFam3.1/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Canis_familiaris/Ensembl/CanFam3.1/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Canis_familiaris/Ensembl/CanFam3.1/Annotation/Genes/genes.bed" - readme = "${params.igenomes_base}/Canis_familiaris/Ensembl/CanFam3.1/Annotation/README.txt" - mito_name = "MT" - } - 'GRCz10' { - fasta = "${params.igenomes_base}/Danio_rerio/Ensembl/GRCz10/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Danio_rerio/Ensembl/GRCz10/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Danio_rerio/Ensembl/GRCz10/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Danio_rerio/Ensembl/GRCz10/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Danio_rerio/Ensembl/GRCz10/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Danio_rerio/Ensembl/GRCz10/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Danio_rerio/Ensembl/GRCz10/Annotation/Genes/genes.bed" - mito_name = "MT" - } - 'BDGP6' { - fasta = "${params.igenomes_base}/Drosophila_melanogaster/Ensembl/BDGP6/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Drosophila_melanogaster/Ensembl/BDGP6/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Drosophila_melanogaster/Ensembl/BDGP6/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Drosophila_melanogaster/Ensembl/BDGP6/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Drosophila_melanogaster/Ensembl/BDGP6/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Drosophila_melanogaster/Ensembl/BDGP6/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Drosophila_melanogaster/Ensembl/BDGP6/Annotation/Genes/genes.bed" - mito_name = "M" - macs_gsize = "1.2e8" - } - 'EquCab2' { - fasta = "${params.igenomes_base}/Equus_caballus/Ensembl/EquCab2/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Equus_caballus/Ensembl/EquCab2/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Equus_caballus/Ensembl/EquCab2/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Equus_caballus/Ensembl/EquCab2/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Equus_caballus/Ensembl/EquCab2/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Equus_caballus/Ensembl/EquCab2/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Equus_caballus/Ensembl/EquCab2/Annotation/Genes/genes.bed" - readme = "${params.igenomes_base}/Equus_caballus/Ensembl/EquCab2/Annotation/README.txt" - mito_name = "MT" - } - 'EB1' { - fasta = "${params.igenomes_base}/Escherichia_coli_K_12_DH10B/Ensembl/EB1/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Escherichia_coli_K_12_DH10B/Ensembl/EB1/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Escherichia_coli_K_12_DH10B/Ensembl/EB1/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Escherichia_coli_K_12_DH10B/Ensembl/EB1/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Escherichia_coli_K_12_DH10B/Ensembl/EB1/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Escherichia_coli_K_12_DH10B/Ensembl/EB1/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Escherichia_coli_K_12_DH10B/Ensembl/EB1/Annotation/Genes/genes.bed" - readme = "${params.igenomes_base}/Escherichia_coli_K_12_DH10B/Ensembl/EB1/Annotation/README.txt" - } - 'Galgal4' { - fasta = "${params.igenomes_base}/Gallus_gallus/Ensembl/Galgal4/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Gallus_gallus/Ensembl/Galgal4/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Gallus_gallus/Ensembl/Galgal4/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Gallus_gallus/Ensembl/Galgal4/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Gallus_gallus/Ensembl/Galgal4/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Gallus_gallus/Ensembl/Galgal4/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Gallus_gallus/Ensembl/Galgal4/Annotation/Genes/genes.bed" - mito_name = "MT" - } - 'Gm01' { - fasta = "${params.igenomes_base}/Glycine_max/Ensembl/Gm01/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Glycine_max/Ensembl/Gm01/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Glycine_max/Ensembl/Gm01/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Glycine_max/Ensembl/Gm01/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Glycine_max/Ensembl/Gm01/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Glycine_max/Ensembl/Gm01/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Glycine_max/Ensembl/Gm01/Annotation/Genes/genes.bed" - readme = "${params.igenomes_base}/Glycine_max/Ensembl/Gm01/Annotation/README.txt" - } - 'Mmul_1' { - fasta = "${params.igenomes_base}/Macaca_mulatta/Ensembl/Mmul_1/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Macaca_mulatta/Ensembl/Mmul_1/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Macaca_mulatta/Ensembl/Mmul_1/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Macaca_mulatta/Ensembl/Mmul_1/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Macaca_mulatta/Ensembl/Mmul_1/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Macaca_mulatta/Ensembl/Mmul_1/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Macaca_mulatta/Ensembl/Mmul_1/Annotation/Genes/genes.bed" - readme = "${params.igenomes_base}/Macaca_mulatta/Ensembl/Mmul_1/Annotation/README.txt" - mito_name = "MT" - } - 'IRGSP-1.0' { - fasta = "${params.igenomes_base}/Oryza_sativa_japonica/Ensembl/IRGSP-1.0/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Oryza_sativa_japonica/Ensembl/IRGSP-1.0/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Oryza_sativa_japonica/Ensembl/IRGSP-1.0/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Oryza_sativa_japonica/Ensembl/IRGSP-1.0/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Oryza_sativa_japonica/Ensembl/IRGSP-1.0/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Oryza_sativa_japonica/Ensembl/IRGSP-1.0/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Oryza_sativa_japonica/Ensembl/IRGSP-1.0/Annotation/Genes/genes.bed" - mito_name = "Mt" - } - 'CHIMP2.1.4' { - fasta = "${params.igenomes_base}/Pan_troglodytes/Ensembl/CHIMP2.1.4/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Pan_troglodytes/Ensembl/CHIMP2.1.4/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Pan_troglodytes/Ensembl/CHIMP2.1.4/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Pan_troglodytes/Ensembl/CHIMP2.1.4/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Pan_troglodytes/Ensembl/CHIMP2.1.4/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Pan_troglodytes/Ensembl/CHIMP2.1.4/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Pan_troglodytes/Ensembl/CHIMP2.1.4/Annotation/Genes/genes.bed" - readme = "${params.igenomes_base}/Pan_troglodytes/Ensembl/CHIMP2.1.4/Annotation/README.txt" - mito_name = "MT" - } - 'Rnor_5.0' { - fasta = "${params.igenomes_base}/Rattus_norvegicus/Ensembl/Rnor_5.0/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Rattus_norvegicus/Ensembl/Rnor_5.0/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Rattus_norvegicus/Ensembl/Rnor_5.0/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Rattus_norvegicus/Ensembl/Rnor_5.0/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Rattus_norvegicus/Ensembl/Rnor_5.0/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Rattus_norvegicus/Ensembl/Rnor_5.0/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Rattus_norvegicus/Ensembl/Rnor_5.0/Annotation/Genes/genes.bed" - mito_name = "MT" - } - 'Rnor_6.0' { - fasta = "${params.igenomes_base}/Rattus_norvegicus/Ensembl/Rnor_6.0/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Rattus_norvegicus/Ensembl/Rnor_6.0/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Rattus_norvegicus/Ensembl/Rnor_6.0/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Rattus_norvegicus/Ensembl/Rnor_6.0/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Rattus_norvegicus/Ensembl/Rnor_6.0/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Rattus_norvegicus/Ensembl/Rnor_6.0/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Rattus_norvegicus/Ensembl/Rnor_6.0/Annotation/Genes/genes.bed" - mito_name = "MT" - } - 'R64-1-1' { - fasta = "${params.igenomes_base}/Saccharomyces_cerevisiae/Ensembl/R64-1-1/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Saccharomyces_cerevisiae/Ensembl/R64-1-1/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Saccharomyces_cerevisiae/Ensembl/R64-1-1/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Saccharomyces_cerevisiae/Ensembl/R64-1-1/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Saccharomyces_cerevisiae/Ensembl/R64-1-1/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Saccharomyces_cerevisiae/Ensembl/R64-1-1/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Saccharomyces_cerevisiae/Ensembl/R64-1-1/Annotation/Genes/genes.bed" - mito_name = "MT" - macs_gsize = "1.2e7" - } - 'EF2' { - fasta = "${params.igenomes_base}/Schizosaccharomyces_pombe/Ensembl/EF2/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Schizosaccharomyces_pombe/Ensembl/EF2/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Schizosaccharomyces_pombe/Ensembl/EF2/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Schizosaccharomyces_pombe/Ensembl/EF2/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Schizosaccharomyces_pombe/Ensembl/EF2/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Schizosaccharomyces_pombe/Ensembl/EF2/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Schizosaccharomyces_pombe/Ensembl/EF2/Annotation/Genes/genes.bed" - readme = "${params.igenomes_base}/Schizosaccharomyces_pombe/Ensembl/EF2/Annotation/README.txt" - mito_name = "MT" - macs_gsize = "1.21e7" - } - 'Sbi1' { - fasta = "${params.igenomes_base}/Sorghum_bicolor/Ensembl/Sbi1/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Sorghum_bicolor/Ensembl/Sbi1/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Sorghum_bicolor/Ensembl/Sbi1/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Sorghum_bicolor/Ensembl/Sbi1/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Sorghum_bicolor/Ensembl/Sbi1/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Sorghum_bicolor/Ensembl/Sbi1/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Sorghum_bicolor/Ensembl/Sbi1/Annotation/Genes/genes.bed" - readme = "${params.igenomes_base}/Sorghum_bicolor/Ensembl/Sbi1/Annotation/README.txt" - } - 'Sscrofa10.2' { - fasta = "${params.igenomes_base}/Sus_scrofa/Ensembl/Sscrofa10.2/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Sus_scrofa/Ensembl/Sscrofa10.2/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Sus_scrofa/Ensembl/Sscrofa10.2/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Sus_scrofa/Ensembl/Sscrofa10.2/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Sus_scrofa/Ensembl/Sscrofa10.2/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Sus_scrofa/Ensembl/Sscrofa10.2/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Sus_scrofa/Ensembl/Sscrofa10.2/Annotation/Genes/genes.bed" - readme = "${params.igenomes_base}/Sus_scrofa/Ensembl/Sscrofa10.2/Annotation/README.txt" - mito_name = "MT" - } - 'AGPv3' { - fasta = "${params.igenomes_base}/Zea_mays/Ensembl/AGPv3/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Zea_mays/Ensembl/AGPv3/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Zea_mays/Ensembl/AGPv3/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Zea_mays/Ensembl/AGPv3/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Zea_mays/Ensembl/AGPv3/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Zea_mays/Ensembl/AGPv3/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Zea_mays/Ensembl/AGPv3/Annotation/Genes/genes.bed" - mito_name = "Mt" - } - 'hg38' { - fasta = "${params.igenomes_base}/Homo_sapiens/UCSC/hg38/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Homo_sapiens/UCSC/hg38/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Homo_sapiens/UCSC/hg38/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Homo_sapiens/UCSC/hg38/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Homo_sapiens/UCSC/hg38/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Homo_sapiens/UCSC/hg38/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Homo_sapiens/UCSC/hg38/Annotation/Genes/genes.bed" - mito_name = "chrM" - macs_gsize = "2.7e9" - blacklist = "${projectDir}/assets/blacklists/hg38-blacklist.bed" - } - 'hg19' { - fasta = "${params.igenomes_base}/Homo_sapiens/UCSC/hg19/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Homo_sapiens/UCSC/hg19/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Homo_sapiens/UCSC/hg19/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Homo_sapiens/UCSC/hg19/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Homo_sapiens/UCSC/hg19/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Homo_sapiens/UCSC/hg19/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Homo_sapiens/UCSC/hg19/Annotation/Genes/genes.bed" - readme = "${params.igenomes_base}/Homo_sapiens/UCSC/hg19/Annotation/README.txt" - mito_name = "chrM" - macs_gsize = "2.7e9" - blacklist = "${projectDir}/assets/blacklists/hg19-blacklist.bed" - } - 'mm10' { - fasta = "${params.igenomes_base}/Mus_musculus/UCSC/mm10/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Mus_musculus/UCSC/mm10/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Mus_musculus/UCSC/mm10/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Mus_musculus/UCSC/mm10/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Mus_musculus/UCSC/mm10/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Mus_musculus/UCSC/mm10/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Mus_musculus/UCSC/mm10/Annotation/Genes/genes.bed" - readme = "${params.igenomes_base}/Mus_musculus/UCSC/mm10/Annotation/README.txt" - mito_name = "chrM" - macs_gsize = "1.87e9" - blacklist = "${projectDir}/assets/blacklists/mm10-blacklist.bed" - } - 'bosTau8' { - fasta = "${params.igenomes_base}/Bos_taurus/UCSC/bosTau8/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Bos_taurus/UCSC/bosTau8/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Bos_taurus/UCSC/bosTau8/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Bos_taurus/UCSC/bosTau8/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Bos_taurus/UCSC/bosTau8/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Bos_taurus/UCSC/bosTau8/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Bos_taurus/UCSC/bosTau8/Annotation/Genes/genes.bed" - mito_name = "chrM" - } - 'ce10' { - fasta = "${params.igenomes_base}/Caenorhabditis_elegans/UCSC/ce10/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Caenorhabditis_elegans/UCSC/ce10/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Caenorhabditis_elegans/UCSC/ce10/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Caenorhabditis_elegans/UCSC/ce10/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Caenorhabditis_elegans/UCSC/ce10/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Caenorhabditis_elegans/UCSC/ce10/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Caenorhabditis_elegans/UCSC/ce10/Annotation/Genes/genes.bed" - readme = "${params.igenomes_base}/Caenorhabditis_elegans/UCSC/ce10/Annotation/README.txt" - mito_name = "chrM" - macs_gsize = "9e7" - } - 'canFam3' { - fasta = "${params.igenomes_base}/Canis_familiaris/UCSC/canFam3/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Canis_familiaris/UCSC/canFam3/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Canis_familiaris/UCSC/canFam3/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Canis_familiaris/UCSC/canFam3/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Canis_familiaris/UCSC/canFam3/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Canis_familiaris/UCSC/canFam3/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Canis_familiaris/UCSC/canFam3/Annotation/Genes/genes.bed" - readme = "${params.igenomes_base}/Canis_familiaris/UCSC/canFam3/Annotation/README.txt" - mito_name = "chrM" - } - 'danRer10' { - fasta = "${params.igenomes_base}/Danio_rerio/UCSC/danRer10/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Danio_rerio/UCSC/danRer10/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Danio_rerio/UCSC/danRer10/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Danio_rerio/UCSC/danRer10/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Danio_rerio/UCSC/danRer10/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Danio_rerio/UCSC/danRer10/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Danio_rerio/UCSC/danRer10/Annotation/Genes/genes.bed" - mito_name = "chrM" - macs_gsize = "1.37e9" - } - 'dm6' { - fasta = "${params.igenomes_base}/Drosophila_melanogaster/UCSC/dm6/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Drosophila_melanogaster/UCSC/dm6/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Drosophila_melanogaster/UCSC/dm6/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Drosophila_melanogaster/UCSC/dm6/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Drosophila_melanogaster/UCSC/dm6/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Drosophila_melanogaster/UCSC/dm6/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Drosophila_melanogaster/UCSC/dm6/Annotation/Genes/genes.bed" - mito_name = "chrM" - macs_gsize = "1.2e8" - } - 'equCab2' { - fasta = "${params.igenomes_base}/Equus_caballus/UCSC/equCab2/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Equus_caballus/UCSC/equCab2/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Equus_caballus/UCSC/equCab2/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Equus_caballus/UCSC/equCab2/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Equus_caballus/UCSC/equCab2/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Equus_caballus/UCSC/equCab2/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Equus_caballus/UCSC/equCab2/Annotation/Genes/genes.bed" - readme = "${params.igenomes_base}/Equus_caballus/UCSC/equCab2/Annotation/README.txt" - mito_name = "chrM" - } - 'galGal4' { - fasta = "${params.igenomes_base}/Gallus_gallus/UCSC/galGal4/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Gallus_gallus/UCSC/galGal4/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Gallus_gallus/UCSC/galGal4/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Gallus_gallus/UCSC/galGal4/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Gallus_gallus/UCSC/galGal4/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Gallus_gallus/UCSC/galGal4/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Gallus_gallus/UCSC/galGal4/Annotation/Genes/genes.bed" - readme = "${params.igenomes_base}/Gallus_gallus/UCSC/galGal4/Annotation/README.txt" - mito_name = "chrM" - } - 'panTro4' { - fasta = "${params.igenomes_base}/Pan_troglodytes/UCSC/panTro4/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Pan_troglodytes/UCSC/panTro4/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Pan_troglodytes/UCSC/panTro4/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Pan_troglodytes/UCSC/panTro4/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Pan_troglodytes/UCSC/panTro4/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Pan_troglodytes/UCSC/panTro4/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Pan_troglodytes/UCSC/panTro4/Annotation/Genes/genes.bed" - readme = "${params.igenomes_base}/Pan_troglodytes/UCSC/panTro4/Annotation/README.txt" - mito_name = "chrM" - } - 'rn6' { - fasta = "${params.igenomes_base}/Rattus_norvegicus/UCSC/rn6/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Rattus_norvegicus/UCSC/rn6/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Rattus_norvegicus/UCSC/rn6/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Rattus_norvegicus/UCSC/rn6/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Rattus_norvegicus/UCSC/rn6/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Rattus_norvegicus/UCSC/rn6/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Rattus_norvegicus/UCSC/rn6/Annotation/Genes/genes.bed" - mito_name = "chrM" - } - 'sacCer3' { - fasta = "${params.igenomes_base}/Saccharomyces_cerevisiae/UCSC/sacCer3/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Saccharomyces_cerevisiae/UCSC/sacCer3/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Saccharomyces_cerevisiae/UCSC/sacCer3/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Saccharomyces_cerevisiae/UCSC/sacCer3/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Saccharomyces_cerevisiae/UCSC/sacCer3/Sequence/BismarkIndex/" - readme = "${params.igenomes_base}/Saccharomyces_cerevisiae/UCSC/sacCer3/Annotation/README.txt" - mito_name = "chrM" - macs_gsize = "1.2e7" - } - 'susScr3' { - fasta = "${params.igenomes_base}/Sus_scrofa/UCSC/susScr3/Sequence/WholeGenomeFasta/genome.fa" - bwa = "${params.igenomes_base}/Sus_scrofa/UCSC/susScr3/Sequence/BWAIndex/version0.6.0/" - bowtie2 = "${params.igenomes_base}/Sus_scrofa/UCSC/susScr3/Sequence/Bowtie2Index/" - star = "${params.igenomes_base}/Sus_scrofa/UCSC/susScr3/Sequence/STARIndex/" - bismark = "${params.igenomes_base}/Sus_scrofa/UCSC/susScr3/Sequence/BismarkIndex/" - gtf = "${params.igenomes_base}/Sus_scrofa/UCSC/susScr3/Annotation/Genes/genes.gtf" - bed12 = "${params.igenomes_base}/Sus_scrofa/UCSC/susScr3/Annotation/Genes/genes.bed" - readme = "${params.igenomes_base}/Sus_scrofa/UCSC/susScr3/Annotation/README.txt" - mito_name = "chrM" - } - } -} diff --git a/conf/modules.config b/conf/modules.config old mode 100644 new mode 100755 index db11e87a..4a34280d --- a/conf/modules.config +++ b/conf/modules.config @@ -11,13 +11,6 @@ */ process { - - publishDir = [ - path: { "${params.outdir}/${task.process.tokenize(':')[-1].tokenize('_')[0].toLowerCase()}" }, - mode: params.publish_dir_mode, - saveAs: { filename -> filename.equals('versions.yml') ? null : filename } - ] - withName: CUSTOM_DUMPSOFTWAREVERSIONS { publishDir = [ path: { "${params.outdir}/${task.process.tokenize(':')[-1].tokenize('_')[0].toLowerCase()}" }, @@ -26,27 +19,110 @@ process { ] } + // Files to be uploaded to the TreeVal JBrowse2 instance + // .genome, .gz.{tbi|csi}, .bigBed, .bigWig, .paf + withName: 'GENERATE_GENOME_FILE|TABIX_BGZIPTABIX|UCSC_BEDTOBIGBED|UCSC_BEDGRAPHTOBIGWIG|.*:.*:SYNTENY:MINIMAP2_ALIGN|.*:.*:GENERATE_GENOME:GNU_SORT' { + publishDir = [ + path: { "${params.outdir}/treeval_upload" }, + mode: params.publish_dir_mode, + saveAs: { filename -> filename.equals('versions.yml') ? null : filename } + ] + } + + // Files to be stored along side the TreeVal files for access by curators + // all are .bed + withName: 'PAF2BED|EXTRACT_COV_IDEN|FINDHALFCOVERAGE|BEDTOOLS_MERGE_MAX|BEDTOOLS_MERGE_MIN' { + publishDir = [ + path: { "${params.outdir}/treeval_upload/punchlists" }, + mode: params.publish_dir_mode, + saveAs: { filename -> filename.equals('versions.yml') ? null : filename } + ] + } + + // Files to be used for pretext, likely to be deleted once the hic workflow is complete. + // .bed, .hr.pretext, .lr.pretext, needs centromere} + withName: 'SEQTK_CUTN|GAP_LENGTH|PRETEXTMAP_HIGHRES|PRETEXTMAP_STANDRD|COOLER_ZOOMIFY|COV_FOLDER|UCSC_BEDGRAPHTOBIGWIG|EXTRACT_TELO|JUICER_TOOLS_PRE|SNAPSHOT_SRES|SNAPSHOT_HRES|GET_PAIRED_CONTACT_BED' { + publishDir = [ + path: { "${params.outdir}/hic_files" }, + mode: params.publish_dir_mode, + saveAs: { filename -> filename.equals('versions.yml') ? null : filename } + ] + } + + withName: BEDTOOLS_SORT { + ext.prefix = { "${meta.id}.sorted" } + } + + withName: GNU_SORT_A { + ext.args = { "-k1,1 -k2,2n" } + ext.suffix = { "intersect" } + } + + withName: GNU_SORT_B { + ext.args = { "-k1,1 -k2,2n" } + ext.suffix = { "sorted.genome" } + } + + withName: GNU_SORT_C { + ext.args = { "-k1,1 -k2,2n" } + ext.suffix = { "bins" } + } + + withName: BEDTOOLS_MAKEWINDOWS { + ext.args = { "-w 10000" } + } + + withName: BEDTOOLS_INTERSECT { + ext.prefix = { "${meta.id}_INTERSECT" } + } + + withName: BEDTOOLS_MAP { + ext.prefix = { "${meta.id}_MAPPED" } + ext.args = { "-c 4 -o sum" } + } + + withName: SEQTK_CUTN { + ext.args = "-n 1" + ext.prefix = { "${meta.id}_gap" } + } + withName: MINIPROT_ALIGN { - ext.args = "-u --gff -j 1" + ext.args = " --gff -j1 -ut16 --gff-delim='#' " } - withName: '.*:.*:.*:NUC_ALIGNMENTS:BEDTOOLS_BAMTOBED' { + withName: '.*:.*:.*:(GEN_ALIGNMENTS|RNA_ALIGNMENTS|CDS_ALIGNMENTS):MINIMAP2_ALIGN' { + ext.args = {"-ax splice ${meta.intron_size ? "-G ${meta.intron_size}" : ""} --split-prefix ${meta.split_prefix}"} + ext.prefix = { "${meta.id}_alignment_${reference.getName().tokenize('.')[0]}" } + } + + withName: '.*:.*:.*:(GEN_ALIGNMENTS|RNA_ALIGNMENTS|CDS_ALIGNMENTS):BEDTOOLS_BAMTOBED' { ext.args = "-bed12" } + withName: '.*:.*:.*:(GEN_ALIGNMENTS|RNA_ALIGNMENTS|CDS_ALIGNMENTS):UCSC_BEDTOBIGBED' { + ext.prefix = { "${meta.id}_${meta.type}" } + } + + withName: '.*:.*:.*:PEP_ALIGNMENTS:BEDTOOLS_SORT' { + ext.prefix = { "${meta.id}_prot" } + } + withName: '.*:.*:INSILICO_DIGEST:UCSC_BEDTOBIGBED' { ext.args = { "-type=bed4+1 -extraIndex=length" } ext.prefix = { "${meta.id}" } } - withName: '.*:.*:GENE_ALIGNMENT:UCSC_BEDTOBIGBED' { - ext.args = { " -type=bed6+2 -extraIndex=name,geneSymbol" } - ext.prefix = { "${meta.id}-${meta.type}"} + withName: '.*:.*:SELFCOMP:UCSC_BEDTOBIGBED' { + ext.args = { " -type=bed3+3 -extraIndex=qName,qStart,qEnd" } + ext.prefix = { "${meta.id}_selfcomp" } } - withName: '.*:.*:SELFCOMP:UCSC_BEDTOBIGBED' { - ext.args = { " -type=bed3+6 -extraIndex=name,qStart,qEnd" } - ext.prefix = { "${meta.id}" } + withName: '.*:.*:REPEAT_DENSITY:UCSC_BEDGRAPHTOBIGWIG' { + ext.prefix = { "${meta.id}_repeat_density" } + } + + withName: '.*:.*:GAP_FINDER:TABIX_BGZIPTABIX' { + ext.prefix = { "gap_${meta.id}" } } withName: '.*:.*:SYNTENY:MINIMAP2_ALIGN' { @@ -54,12 +130,152 @@ process { ext.prefix = { "${meta.id}_synteny_${reference.getName().tokenize('.')[0]}" } } - withName: '.*:.*:.*:NUC_ALIGNMENTS:MINIMAP2_ALIGN' { - ext.args = "-ax splice" - ext.prefix = { "${meta.id}_alignment_${reference.getName().tokenize('.')[0]}" } - } - withName : MUMMER { ext.args = "-n -b -c -L -l 400" } -} \ No newline at end of file + + // + // LONGREAD BLOCK + // + withName: '.*:.*:LONGREAD_COVERAGE:MINIMAP2_ALIGN' { + ext.args = "--MD -t 8" + ext.prefix = { "${meta.id}_alignment_${reference.getName().tokenize('.')[0]}" } + } + + withName: '.*:.*:LONGREAD_COVERAGE:MINIMAP2_ALIGN_SPLIT' { + ext.args = { "-t 20 --split-prefix ${meta.split_prefix}" } + ext.prefix = { "${meta.id}_alignment_${reference.getName().tokenize('.')[0]}" } + } + + withName: '.*:.*:LONGREAD_COVERAGE:SAMTOOLS_MERGE' { + ext.prefix = { "${meta.id}_merge" } + } + + withName: '.*:.*:LONGREAD_COVERAGE:SAMTOOLS_SORT' { + ext.prefix = { "${meta.id}_sorted" } + } + + withName: '.*:.*:LONGREAD_COVERAGE:SAMTOOLS_VIEW' { + ext.args = "-b -hF 256" + ext.prefix = { "${meta.id}_view" } + } + + withName: '.*:.*:LONGREAD_COVERAGE:BEDTOOLS_GENOMECOV' { + ext.args = "-bga -split" + ext.prefix = { "${meta.id}_genome2cov" } + } + + withName: '.*:.*:LONGREAD_COVERAGE:BEDTOOLS_MERGE_MAX' { + ext.args = "-d 50" + ext.prefix = { "maxdepth" } + } + + withName: '.*:.*:LONGREAD_COVERAGE:BEDTOOLS_MERGE_MIN' { + ext.args = "-d 50" + ext.prefix = { "zerodepth" } + } + + withName: '.*:.*:LONGREAD_COVERAGE:GNU_SORT' { + ext.args = "-k1,1 -k2,2n" + ext.prefix = { "${meta.id}_sorted" } + } + + withName: '.*:.*:LONGREAD_COVERAGE:UCSC_BEDGRAPHTOBIGWIG' { + ext.prefix = { "${meta.id}_coverage" } + } + + // + // TELOMERE BLOCK + // + withName: 'FIND_TELOMERE_REGIONS' { + ext.find_telomere = 'find_telomere' + } + + withName: 'FIND_TELOMERE_WINDOWS' { + ext.telomere_jar = 'telomere.jar' + ext.telomere_jvm_params = '-Xms1g -Xmx1g' + } + + withName: '.*:.*:TELO_FINDER:TABIX_BGZIPTABIX' { + ext.prefix = { "telo_${meta.id}" } + } + + // + // BUSCO BLOCK + // + withName: '.*:.*:BUSCO_ANNOTATION:UCSC_BEDTOBIGBED' { + ext.args = { "-type=bed3+4 -extraIndex=name,OrthoDBurl" } + ext.prefix = { "${meta.id}_buscogene" } + } + + withName: '.*:.*:.*:ANCESTRAL_GENE:UCSC_BEDTOBIGBED' { + ext.args = { "-type=bed3+4 -extraIndex=name,OrthoDBurl" } + ext.prefix = { "${meta.id}_ancestral" } + } + + withName: '.*:.*:BUSCO_ANNOTATION:BEDTOOLS_SORT' { + ext.prefix = { "${meta.id}_busco.sorted" } + } + + withName: '.*:.*:.*:ANCESTRAL_GENE:BEDTOOLS_SORT' { + ext.prefix = { "${meta.id}_ancestral.sorted" } + } + + withName: 'BUSCO' { + ext.args = "--mode genome" + } + + // + // HIC MAPPING BLOCK + // + withName: PRETEXTMAP_STANDRD { + ext.args = "--sortby length --mapq 0" + ext.prefix = { "${meta.id}_normal" } + } + + withName: PRETEXTMAP_HIGHRES { + ext.args = "--sortby length --highRes --mapq 0" + ext.prefix = { "${meta.id}_hr" } + } + + withName: 'SNAPSHOT_SRES' { + ext.args = "--sequences '=full' --resolution 1440" + ext.prefix = { "${meta.id}_normal" } + } + + withName: 'SNAPSHOT_HRES' { + ext.args = "--sequences '=full' --resolution 1440" + ext.prefix = { "${meta.id}_hr" } + } + + withName: JUICER_TOOLS_PRE { + ext.juicer_tools_jar = 'juicer_tools.1.8.9_jcuda.0.8.jar' + ext.juicer_jvm_params = '-Xms36g -Xmx36g' + } + + withName: COOLER_CLOAD { + ext.args = 'pairs -0 -c1 3 -p1 4 -c2 7 -p2 8' + } + + withName: '.*:.*:HIC_MAPPING:SAMTOOLS_MARKDUP' { + ext.prefix = { "${meta.id}_mkdup" } + } + + withName: '.*:.*:HIC_MAPPING:SAMTOOLS_MERGE' { + ext.prefix = { "${meta.id}_merged" } + } + + withName: CRAM_FILTER_ALIGN_BWAMEM2_FIXMATE_SORT { + ext.args = '' + ext.args1 = '-F0xB00 -nt' + ext.args2 = { "-5SPCp -H'${rglines}'" } + ext.args3 = '-mpu' + ext.args4 = { '--write-index -l1' } + } + + withName: '.*:.*:GENERATE_GENOME:GNU_SORT' { + ext.prefix = { "${meta.id}_sorted"} + ext.args = { '-k2,2 -nr' } + } + +} diff --git a/conf/selfcomp.config b/conf/selfcomp.config deleted file mode 100644 index 5712d223..00000000 --- a/conf/selfcomp.config +++ /dev/null @@ -1,33 +0,0 @@ -params { - outdir = "output/" - publish_dir_mode = "copy" - enable_conda = false - singularity_pull_docker_container = false -} - -process { - cpus = 2 - memory = 3.GB - time = 2.h -} - -if ("$PROFILE" == "singularity") { - singularity.enabled = true - singularity.autoMounts = true -} else if ("$PROFILE" == "conda") { - params.enable_conda = true -} else { - docker.enabled = true - docker.userEmulation = true - docker.runOptions = "--platform linux/x86_64" -} - -// Increase time available to build Conda environment -conda { createTimeout = "120 min" } - -// Load test_data.config containing paths to test data -//includeConfig 'test_data.config' - -manifest { - nextflowVersion = '!>=21.10.0' -} diff --git a/conf/test.config b/conf/test.config old mode 100644 new mode 100755 index a8739c8b..ebe8c6bc --- a/conf/test.config +++ b/conf/test.config @@ -5,25 +5,19 @@ Defines input files and everything required to run a fast and simple pipeline test. Use as follows: - nextflow run nf-core/treeval -profile test, --outdir + nextflow run sanger-tol/treeval -profile test,singularity -entry FULL + + On LSF / tol farm: + bsub -Is -tty -e error -o out -n 2 -q oversubscribed -M4000 -R'select[mem>4000] rusage[mem=4000] span[hosts=1]' 'nextflow run main.nf -profile test,singularity,sanger' ---------------------------------------------------------------------------------------- */ params { - config_profile_name = 'Test profile' - config_profile_description = 'Minimal test dataset to check pipeline function' - - // Limit resources so that this can run on GitHub Actions - max_cpus = 2 - max_memory = '6.GB' - max_time = '6.h' + config_profile_name = "Test profile" + config_profile_description = "Minimal test dataset to check pipeline function" // Input data - // TODO nf-core: Specify the paths to your test data on nf-core/test-datasets - // TODO nf-core: Give any required params for the test so that command line flags are not needed - input = 'https://raw.githubusercontent.com/nf-core/test-datasets/viralrecon/samplesheet/samplesheet_test_illumina_amplicon.csv' - - // Genome references - genome = 'R64-1-1' + input = "${projectDir}/assets/local_testing/nxOscSUBSET.yaml" + outdir = "TinyTest" } diff --git a/conf/test_full.config b/conf/test_full.config old mode 100644 new mode 100755 index dc6fd774..8356bbbe --- a/conf/test_full.config +++ b/conf/test_full.config @@ -5,20 +5,21 @@ Defines input files and everything required to run a full size pipeline test. Use as follows: - nextflow run nf-core/treeval -profile test_full, --outdir + nextflow run sanger-tol/treeval -profile farm_full,singularity,sanger + + On LSF / tol farm: + bsub -Is -tty -e error -o out -n 2 -q oversubscribed -M4000 -R'select[mem>4000] rusage[mem=4000] span[hosts=1]' 'nextflow run main.nf -profile test_full,singularity,sanger' ---------------------------------------------------------------------------------------- */ -params { - config_profile_name = 'Full test profile' - config_profile_description = 'Full test dataset to check pipeline function' +cleanup = true - // Input data for full size test - // TODO nf-core: Specify the paths to your full test data ( on nf-core/test-datasets or directly in repositories, e.g. SRA) - // TODO nf-core: Give any required params for the test so that command line flags are not needed - input = 'https://raw.githubusercontent.com/nf-core/test-datasets/viralrecon/samplesheet/samplesheet_full_illumina_amplicon.csv' +params { + config_profile_name = "FULL local test profile" + config_profile_description = "FULL test dataset to check pipeline function, using a current full local dataset" - // Genome references - genome = 'R64-1-1' + // Input data + input = "${projectDir}/assets/local_testing/nxOscDF5033.yaml" + outdir = "SmallTest" } diff --git a/conf/test_genealignment.config b/conf/test_genealignment.config deleted file mode 100644 index af2e9557..00000000 --- a/conf/test_genealignment.config +++ /dev/null @@ -1,19 +0,0 @@ -/* -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - Nextflow config file for running minimal tests -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - Defines input files and everything required to run a fast and simple pipeline test. - - Use as follows: - nextflow run nf-core/treeval -profile test, --outdir - ----------------------------------------------------------------------------------------- -*/ - -params { - config_profile_name = 'test_genealignment' - config_profile_description = 'Minimal data set for gene alignments to input fasta' - - input = './assets/treeval_test.yaml' - outdir = './testing/' -} diff --git a/conf/test_github.config b/conf/test_github.config new file mode 100755 index 00000000..36e4791b --- /dev/null +++ b/conf/test_github.config @@ -0,0 +1,34 @@ +/* +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + Nextflow config file for running minimal tests +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + Defines input files and everything required to run a fast and simple pipeline test. + + First download the test databases and edit the yaml file to match the download path. + + Use as follows: + nextflow run sanger-tol/treeval -profile test_github,singularity + + On LSF / tol farm: + bsub -Is -tty -e error -o out -n 2 -q oversubscribed -M4000 -R'select[mem>4000] rusage[mem=4000] span[hosts=1]' 'nextflow run main.nf -profile test,singularity,sanger' + +---------------------------------------------------------------------------------------- +*/ + +process { + maxForks = 1 +} + +params { + config_profile_name = "GitHub Test profile" + config_profile_description = "Minimal test dataset to check pipeline function on GitHub" + + // Limit resources so that this can run on GitHub Actions + max_cpus = 2 + max_memory = '6.GB' + max_time = '6.h' + + // Input data + input = "${projectDir}/assets/github_testing/TreeValTinyTest.yaml" + outdir = "TinyTest" +} diff --git a/conf/test_selfcomp.config b/conf/test_selfcomp.config deleted file mode 100755 index a8ccc808..00000000 --- a/conf/test_selfcomp.config +++ /dev/null @@ -1,17 +0,0 @@ -/* -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - Nextflow config file for running minimal tests -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - Defines input files and everything required to run a fast and simple pipeline test. - Use as follows: - nextflow run nf-core/treeval -profile test_selfcomp, --outdir ----------------------------------------------------------------------------------------- -*/ - -params { - config_profile_name = 'test_selfcomp' - config_profile_description = 'Minimal test dataset to check selfcomp pipeline function' - - input = './assets/treeval_test.yaml' - outdir = './testing/' -} diff --git a/conf/test_synteny.config b/conf/test_synteny.config deleted file mode 100755 index 460f6d92..00000000 --- a/conf/test_synteny.config +++ /dev/null @@ -1,19 +0,0 @@ -/* -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - Nextflow config file for running minimal tests -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - Defines input files and everything required to run a fast and simple pipeline test. - - Use as follows: - nextflow run nf-core/treeval -profile test_synteny, --outdir - ----------------------------------------------------------------------------------------- -*/ - -params { - config_profile_name = 'test_synteny' - config_profile_description = 'Minimal test dataset to check syntenypipeline function' - - input = "./assets/treeval_test.yaml" - outdir = './testing/' -} diff --git a/docs/README.md b/docs/README.md old mode 100644 new mode 100755 index 40370f17..c54904e5 --- a/docs/README.md +++ b/docs/README.md @@ -1,10 +1,8 @@ -# nf-core/treeval: Documentation +# sanger-tol/treeval: Documentation -The nf-core/treeval documentation is split into the following pages: +The sanger-tol/treeval documentation is split into the following pages: - [Usage](usage.md) - An overview of how the pipeline works, how to run it and a description of all of the different command-line flags. - [Output](output.md) - An overview of the different results produced by the pipeline and how to interpret them. - -You can find a lot more documentation about installing, configuring and running nf-core pipelines on the website: [https://nf-co.re](https://nf-co.re) diff --git a/docs/images/Sanger-classT.png b/docs/images/Sanger-classT.png new file mode 100644 index 00000000..0a531928 Binary files /dev/null and b/docs/images/Sanger-classT.png differ diff --git a/docs/images/mqc_fastqc_adapter.png b/docs/images/mqc_fastqc_adapter.png deleted file mode 100755 index 361d0e47..00000000 Binary files a/docs/images/mqc_fastqc_adapter.png and /dev/null differ diff --git a/docs/images/mqc_fastqc_counts.png b/docs/images/mqc_fastqc_counts.png deleted file mode 100755 index cb39ebb8..00000000 Binary files a/docs/images/mqc_fastqc_counts.png and /dev/null differ diff --git a/docs/images/mqc_fastqc_quality.png b/docs/images/mqc_fastqc_quality.png deleted file mode 100755 index a4b89bf5..00000000 Binary files a/docs/images/mqc_fastqc_quality.png and /dev/null differ diff --git a/docs/images/nf-core-treeval_logo_dark.png b/docs/images/nf-core-treeval_logo_dark.png deleted file mode 100644 index 9d2e6bb9..00000000 Binary files a/docs/images/nf-core-treeval_logo_dark.png and /dev/null differ diff --git a/docs/images/nf-core-treeval_logo_light.png b/docs/images/nf-core-treeval_logo_light.png deleted file mode 100644 index 4bd3b871..00000000 Binary files a/docs/images/nf-core-treeval_logo_light.png and /dev/null differ diff --git a/docs/images/treeval_1_0_busco_analysis.jpeg b/docs/images/treeval_1_0_busco_analysis.jpeg new file mode 100755 index 00000000..5f8cc4c7 Binary files /dev/null and b/docs/images/treeval_1_0_busco_analysis.jpeg differ diff --git a/docs/images/treeval_1_0_gap_finder.jpeg b/docs/images/treeval_1_0_gap_finder.jpeg new file mode 100755 index 00000000..b621bf64 Binary files /dev/null and b/docs/images/treeval_1_0_gap_finder.jpeg differ diff --git a/docs/images/treeval_1_0_gene_alignment.jpeg b/docs/images/treeval_1_0_gene_alignment.jpeg new file mode 100755 index 00000000..d66b8a4c Binary files /dev/null and b/docs/images/treeval_1_0_gene_alignment.jpeg differ diff --git a/docs/images/treeval_1_0_generate_genome.jpeg b/docs/images/treeval_1_0_generate_genome.jpeg new file mode 100755 index 00000000..dd0c69b8 Binary files /dev/null and b/docs/images/treeval_1_0_generate_genome.jpeg differ diff --git a/docs/images/treeval_1_0_hic_mapping.jpeg b/docs/images/treeval_1_0_hic_mapping.jpeg new file mode 100755 index 00000000..406441ea Binary files /dev/null and b/docs/images/treeval_1_0_hic_mapping.jpeg differ diff --git a/docs/images/treeval_1_0_insilico_digest.jpeg b/docs/images/treeval_1_0_insilico_digest.jpeg new file mode 100755 index 00000000..310bd860 Binary files /dev/null and b/docs/images/treeval_1_0_insilico_digest.jpeg differ diff --git a/docs/images/treeval_1_0_legend.jpeg b/docs/images/treeval_1_0_legend.jpeg new file mode 100755 index 00000000..20973dc2 Binary files /dev/null and b/docs/images/treeval_1_0_legend.jpeg differ diff --git a/docs/images/treeval_1_0_longread_coverage.jpeg b/docs/images/treeval_1_0_longread_coverage.jpeg new file mode 100755 index 00000000..20ab1d2d Binary files /dev/null and b/docs/images/treeval_1_0_longread_coverage.jpeg differ diff --git a/docs/images/treeval_1_0_repeat_density.jpeg b/docs/images/treeval_1_0_repeat_density.jpeg new file mode 100755 index 00000000..e784cc8e Binary files /dev/null and b/docs/images/treeval_1_0_repeat_density.jpeg differ diff --git a/docs/images/treeval_1_0_selfcomp.jpeg b/docs/images/treeval_1_0_selfcomp.jpeg new file mode 100755 index 00000000..31086625 Binary files /dev/null and b/docs/images/treeval_1_0_selfcomp.jpeg differ diff --git a/docs/images/treeval_1_0_synteny.jpeg b/docs/images/treeval_1_0_synteny.jpeg new file mode 100755 index 00000000..616a539d Binary files /dev/null and b/docs/images/treeval_1_0_synteny.jpeg differ diff --git a/docs/images/treeval_1_0_telo_finder.jpeg b/docs/images/treeval_1_0_telo_finder.jpeg new file mode 100755 index 00000000..8e064a65 Binary files /dev/null and b/docs/images/treeval_1_0_telo_finder.jpeg differ diff --git a/docs/output.md b/docs/output.md old mode 100644 new mode 100755 index e759ba01..e760d706 --- a/docs/output.md +++ b/docs/output.md @@ -1,68 +1,234 @@ -# nf-core/treeval: Output +# sanger-tol/treeval: Output -## Introduction +# Introduction -This document describes the output produced by the pipeline. Most of the plots are taken from the MultiQC report, which summarises results at the end of the pipeline. +This document describes the output produced by the pipeline. The directories listed below will be created in the results directory after the pipeline has finished. All paths are relative to the top-level results directory. - +# Pipeline overview -## Pipeline overview +The pipeline is built using [Nextflow](https://www.nextflow.io/) and processes data using the following workflows: -The pipeline is built using [Nextflow](https://www.nextflow.io/) and processes data using the following steps: +- [generate-genome](#generate-genome) - Builds genome description file of the reference genome. +- [longread-coverage](#longread-coverage) - Produces read coverage based on pacbio long read fasta file. +- [gap-finder](#gap-finder) - Identifies contig gaps in the input genome. +- [repeat-density](#repeat-density) - Reports the intensity of regional repeats within an input assembly. +- [hic-mapping](#hic-mapping) - Aligns illumina HiC short reads to the input genome, generates mapping file in three format for visualisation: .pretext, .hic and .mcool +- [telo-finder](#telo-finder) - Identifies regions of a user given telomeric sequence. +- [gene-alignment](#gene-alignment) - Aligns the peptide and nuclear data from assemblies of related species to the input genome. +- [insilico-digest](#insilico-digest) - Generates a map of enzymatic digests using 3 Bionano enzymes. +- [selfcomp](#selfcomp) - Identifies regions of self-complementary sequence. +- [synteny](#synteny) - Generates syntenic alignments between other high quality genomes. +- [busco-analysis](#busco-analysis) - Uses BUSCO to identify ancestral elements. Also use to identify ancestral Lepidopteran genes (merian units). -- [FastQC](#fastqc) - Raw read QC -- [MultiQC](#multiqc) - Aggregate report describing results and QC from the whole pipeline -- [Pipeline information](#pipeline-information) - Report metrics generated during the workflow execution +- [pipeline-information](#pipeline-information) - Report metrics generated during the workflow execution -### FastQC +## generate-genome + +This workflow generates a .genome file which describes the base pair length of each scaffold in the reference genome. This file is then recycled into the workflow to be used by a number of other subworkflows. + +
+Output files + +- `treeval_upload/` + - `my.genome`: Genome description file of the reference genome. + +
+ +![Generate genome workflow](https://raw.githubusercontent.com/sanger-tol/treeval/dev/docs/images/treeval_1_0_generate_genome.jpeg) + +![Workflow Legend](https://raw.githubusercontent.com/sanger-tol/treeval/dev/docs/images/treeval_1_0_legend.jpeg) + +## longread-coverage + +Longread Coverage uses Pacbio HiC reads to generage a coverage bigWig as well as a trio of depth.bigbed files. + +
+Output files + +- `treeval_upload/` + - `coverage.bw`: Coverage of aligned reads across the reference genome in bigwig format. +- `treeval_upload/punchlists/` + - `maxdepth.bigbed`: Max read depth punchlist in bigBed format. + - `zerodepth.bigbed`: Zero read depth punchlist in bigBed format. + - `halfcoverage.bigbed`: Half read depth punchlist in bigBed format. + +
+ +## gap-finder + +The gap-finder subworkflow generates a bed file containing the genomic locations of the gaps in the sequence. This file is injected into the hic_maps at a later stage. The output bed file is then BGzipped and indexed for display on JBrowse. + +
+Output files + +- `treeval_upload/` + - `*.bed.gz`: A bgzipped file containing gap locations + - `*.bed.gz.tbi`: A tabix index file for the above file. +- `hic_files/` + - `*.bed`: The raw bed file needed for ingestion into Pretext + +
+ +![Gap Finder workflow](https://raw.githubusercontent.com/sanger-tol/treeval/dev/docs/images/treeval_1_0_gap_finder.jpeg) + +![Workflow Legend](https://raw.githubusercontent.com/sanger-tol/treeval/dev/docs/images/treeval_1_0_legend.jpeg) + +## repeat-density + +This uses [WindowMasker](https://github.com/goeckslab/WindowMasker) to mark potential repeats on the genome. The genome is chunked into 10kb bins which move along the entire genome as sliding windows in order to profile the repeat intensity. These fragments are then mapped back to the original assembly for visualization purposes.
Output files -- `fastqc/` - - `*_fastqc.html`: FastQC report containing quality metrics. - - `*_fastqc.zip`: Zip archive containing the FastQC report, tab-delimited data file and plot images. +- `hic_files/` + - `*_repeat_density.bw`: Intersected read windows aligned to the reference genome in bigwig format.
-[FastQC](http://www.bioinformatics.babraham.ac.uk/projects/fastqc/) gives general quality metrics about your sequenced reads. It provides information about the quality score distribution across your reads, per base sequence content (%A/T/G/C), adapter contamination and overrepresented sequences. For further reading and documentation see the [FastQC help pages](http://www.bioinformatics.babraham.ac.uk/projects/fastqc/Help/). +![Repeat Density workflow](https://raw.githubusercontent.com/sanger-tol/treeval/dev/docs/images/treeval_1_0_repeat_density.jpeg) -![MultiQC - FastQC sequence counts plot](images/mqc_fastqc_counts.png) +![Workflow Legend](https://raw.githubusercontent.com/sanger-tol/treeval/dev/docs/images/treeval_1_0_legend.jpeg) -![MultiQC - FastQC mean quality scores plot](images/mqc_fastqc_quality.png) +## hic-mapping -![MultiQC - FastQC adapter content plot](images/mqc_fastqc_adapter.png) +The hic-mapping subworkflow takes a set of HiC read files in .cram format as input and derives HiC mapping outputs in .pretext, .hic, and .mcool formats. These outputs are used for visualization on [PretextView](https://github.com/wtsi-hpag/PretextView), [Juicebox](https://github.com/aidenlab/Juicebox), and [Higlass](https://github.com/higlass/higlass) respectively. + +
+Output files + +- `hic_files/` + - `*_pretext_hr.pretext`: High resolution pretext map. + - `*_pretext_normal.pretext`: Low resolution pretext map. + - `*.mcool`: HiC map required for HiGlass + +
-> **NB:** The FastQC plots displayed in the MultiQC report shows _untrimmed_ reads. They may contain adapter sequence and potentially regions with low quality. +![Hic Mapping workflow](https://raw.githubusercontent.com/sanger-tol/treeval/dev/docs/images/treeval_1_0_hic_mapping.jpeg) -### MultiQC +![Workflow Legend](https://raw.githubusercontent.com/sanger-tol/treeval/dev/docs/images/treeval_1_0_legend.jpeg) + +## telo-finder + +The telo-finder subworkflow uses a supplied (by the .yaml) telomeric sequence to identify putative telomeric regions in the input genome. The BGZipped and indexed file is used in JBrowse and as supplementary data for HiGlass and PreText.
Output files -- `multiqc/` - - `multiqc_report.html`: a standalone HTML file that can be viewed in your web browser. - - `multiqc_data/`: directory containing parsed statistics from the different tools used in the pipeline. - - `multiqc_plots/`: directory containing static images from the report in various formats. +- `treeval_upload/` + - `*.bed.gz`: A bgzipped file containing telomere sequence locations + - `*.bed.gz.tbi`: A tabix index file for the above file. +- `hic_files/` + - `*.bed`: The raw .bed file needed for ingestion into Pretext
-[MultiQC](http://multiqc.info) is a visualization tool that generates a single HTML report summarising all samples in your project. Most of the pipeline QC results are visualised in the report and further statistics are available in the report data directory. +![Telomere Finder workflow](https://raw.githubusercontent.com/sanger-tol/treeval/dev/docs/images/treeval_1_0_telo_finder.jpeg) + +![Workflow Legend](https://raw.githubusercontent.com/sanger-tol/treeval/dev/docs/images/treeval_1_0_legend.jpeg) -Results generated by MultiQC collate pipeline QC from supported tools e.g. FastQC. The pipeline has special steps which also allow the software versions to be reported in the MultiQC output for future traceability. For more information about how to use MultiQC reports, see . +## busco-analysis -### Pipeline information +The BUSCO annotation subworkflow takes an assembly genome as input and extracts a list of [BUSCO](https://gitlab.com/ezlab/busco) genes based on the BUSCO results obtained from BUSCO. Additionally, it provides an overlap BUSCO gene set based on a list of lepidoptera ancestral genes (Wright et al., 2023), which has been investigated by Charlotte Wright from Mark Blaxter's lab at the Sanger Institute.
Output files -- `pipeline_info/` +- `treeval_upload/` + - `*_buscogene.bigbed`: BigBed file for BUSCO genes track. + - `*_ancestral.bigbed`: BigBed file for ancestral elements track. + +
+ +![Busco analysis workflow](https://raw.githubusercontent.com/sanger-tol/treeval/dev/docs/images/treeval_1_0_busco_analysis.jpeg) + +![Workflow Legend](https://raw.githubusercontent.com/sanger-tol/treeval/dev/docs/images/treeval_1_0_legend.jpeg) + +## gene-alignment + +The gene alignment subworkflows load genesets (cdna, cds, rna, pep) data from a given list of genomes detailed, in the input .yaml, and aligns these to the reference genome. It contains two subworkflows, one of which handles peptide data and the other of which handles RNA, nuclear and complementary DNA data. These produce files that can be displayed by JBrowse as tracks. + +
+Output files + +- `treeval_upload/` + - `*.gff.gz`: Zipped .gff for each species with peptide data. + - `*.gff.gz.tbi`: TBI index file of each zipped .gff. + - `*_cdna.bigBed`: BigBed file for each species with complementary DNA data. + - `*_cds.bigBed`: BigBed file for each species with nuclear DNA data. + - `*_rna.bigBed`: BigBed file for each species with nRNAdata. +- `treeval_upload/punchlists/` + - `*_pep_punchlist.bed`: Punchlist for peptide track. + - `*_cdna_punchlist.bed`: Punchlist for cdna track. + - `*_cds_punchlist.bed`: Punchlist for cds track. + - `*_rna_punchlist.bed`: Punchlist for rna track. + +
+ +![Gene alignment workflow](https://raw.githubusercontent.com/sanger-tol/treeval/dev/docs/images/treeval_1_0_gene_alignment.jpeg) + +![Workflow Legend](https://raw.githubusercontent.com/sanger-tol/treeval/dev/docs/images/treeval_1_0_legend.jpeg) + +## insilico-digest + +The insilico-digest workflow is used to visualize the Bionano enzyme cutting sites for a genomic FASTA file. This procedure generates data tracks based on three digestion enzymes: BSPQ1, BSSS1, and DLE1. + +
+Output files + +- `treeval_upload/` + - `{BSPQI|BSSSI|DLE1}.bigBed`: Bionano insilico digest cut sites track in the bigBed format for each of the set digestion enzymes. + +
+ +![Insilico digest workflow](https://raw.githubusercontent.com/sanger-tol/treeval/dev/docs/images/treeval_1_0_insilico_digest.jpeg) + +![Workflow Legend](https://raw.githubusercontent.com/sanger-tol/treeval/dev/docs/images/treeval_1_0_legend.jpeg) + +## selfcomp + +The selfcomp subworkflow is a comparative genomics analysis originally performed by the Ensembl project. It involves comparing the genes and genomic sequences within a single species. The goal of the analysis is mainly to identify haplotypic duplications in a particular genome assembly. + +
+Output files + +- `treeval_upload/` + - `*_selfcomp.bigBed`: BigBed file containing selfcomp track data. + +
+ +![Selfcomp workflow](https://raw.githubusercontent.com/sanger-tol/treeval/dev/docs/images/treeval_1_0_selfcomp.jpeg) + +![Workflow Legend](https://raw.githubusercontent.com/sanger-tol/treeval/dev/docs/images/treeval_1_0_legend.jpeg) + +## synteny + +This worflows searches along predetermined path for syntenic genome files based on clade and then aligns with [MINIMAP2_ALIGN](https://nf-co.re/modules/minimap2_align) each to the reference genome, emitting an aligned .paf file for each. + +
+Output files + +- `treeval_upload/` + - `*.paf`: .paf file for each syntenic genomic aligned to reference. + +
+ +![Synteny workflow](https://raw.githubusercontent.com/sanger-tol/treeval/dev/docs/images/treeval_1_0_synteny.jpeg) + +![Workflow Legend](https://raw.githubusercontent.com/sanger-tol/treeval/dev/docs/images/treeval_1_0_legend.jpeg) + +## pipeline-information + +[Nextflow](https://www.nextflow.io/docs/latest/tracing.html) provides excellent functionality for generating various reports relevant to the running and execution of the pipeline. This will allow you to troubleshoot errors with the running of the pipeline, and also provide you with other information such as launch commands, run times and resource usage. + +
+Output files + +- `treeval_info/` + - Report generated by TreeValProject. - Reports generated by Nextflow: `execution_report.html`, `execution_timeline.html`, `execution_trace.txt` and `pipeline_dag.dot`/`pipeline_dag.svg`. - Reports generated by the pipeline: `pipeline_report.html`, `pipeline_report.txt` and `software_versions.yml`. The `pipeline_report*` files will only be present if the `--email` / `--email_on_fail` parameter's are used when running the pipeline. - Reformatted samplesheet files used as input to the pipeline: `samplesheet.valid.csv`.
- -[Nextflow](https://www.nextflow.io/docs/latest/tracing.html) provides excellent functionality for generating various reports relevant to the running and execution of the pipeline. This will allow you to troubleshoot errors with the running of the pipeline, and also provide you with other information such as launch commands, run times and resource usage. diff --git a/docs/usage.md b/docs/usage.md old mode 100644 new mode 100755 index fba87c34..5c0e969d --- a/docs/usage.md +++ b/docs/usage.md @@ -1,89 +1,547 @@ -# nf-core/treeval: Usage +# sanger-tol/treeval: Usage -## :warning: Please read this documentation on the nf-core website: [https://nf-co.re/treeval/usage](https://nf-co.re/treeval/usage) +## :warning: Please read this documentation on the sanger-tol website: [https://pipelines.tol.sanger.ac.uk/treeval/](https://pipelines.tol.sanger.ac.uk/treeval/) > _Documentation of pipeline parameters is generated automatically from the pipeline schema and can no longer be found in markdown files._ ## Introduction - +The TreeVal pipeline has a few requirements before being able to run: -## Samplesheet input +- The `gene_alignment_data` (where this refers to the alignment.data_dir and alignment.geneset data noted in the yaml, which we will explain later) and synteny data much follow a particular directory structure -You will need to create a samplesheet with information about the samples you would like to analyse before running the pipeline. Use this parameter to specify its location. It has to be a comma-separated file with 3 columns, and a header row as shown in the examples below. +- HiC CRAM files much already be pre-indexed in the same location as the CRAM file, e.g., `samtools index {cram file}`. If this would be more helpful to the community as an automated process then please submit an issue. -```console ---input '[path to samplesheet file]' +- Finally, the yaml file which is described below in Full Samplesheet. This needs to contain all of the information related to the assembly for the pipeline to run. + +## Prior to running TreeVal + +:warning: Please ensure you read the following sections on Directory Structure (`gene_alignment_data`, `synteny`, scripts), HiC data prep and Pacbio data prep. Without these you may not be able to successfully run the TreeVal pipeline. If nothing is clear then leave an issue report. + +### Local testing + +
+ Details + +We provide a complete set of test databases that can be used to test the pipeline locally. + +First, choose a download location `${TREEVAL_TEST_DATA}` and run this command: + +``` +cd ${TREEVAL_TEST_DATA} +curl https://tolit.cog.sanger.ac.uk/test-data/resources/treeval/TreeValTinyData.tar.gz | tar xzf - +sed -i "s|/home/runner/work/treeval/treeval|${TREEVAL_TEST_DATA}|" TreeValTinyData/gene_alignment_data/fungi/csv_data/LaetiporusSulphureus.gfLaeSulp1-data.csv ``` -### Multiple runs of the same sample +Then, modify the configuration file to point at that download location and off you go: + +``` +sed -i "s|/home/runner/work/treeval/treeval|${TREEVAL_TEST_DATA}|" assets/github_testing/TreeValTinyTest.yaml +nextflow run . -profile test_github,singularity +``` -The `sample` identifiers have to be the same when you have re-sequenced the same sample more than once e.g. to increase sequencing depth. The pipeline will concatenate the raw reads before performing any downstream analysis. Below is an example for the same sample sequenced across 3 lanes: +
-```console -sample,fastq_1,fastq_2 -CONTROL_REP1,AEG588A1_S1_L002_R1_001.fastq.gz,AEG588A1_S1_L002_R2_001.fastq.gz -CONTROL_REP1,AEG588A1_S1_L003_R1_001.fastq.gz,AEG588A1_S1_L003_R2_001.fastq.gz -CONTROL_REP1,AEG588A1_S1_L004_R1_001.fastq.gz,AEG588A1_S1_L004_R2_001.fastq.gz +### Directory Structure + +
+ Details + +Working example found below in the Gene alignment and synteny section (below), this will cover setting up `synteny` and `gene_alignment_data` directories as well as downloading some example data. + +These two sub-workflows, for now, need the use of the variables `classT`, `synteny_genome_path`, `data_dir` and `geneset`. These variables are found inside the yaml ( this is the file that will tell TreeVal what and where everything is ). Currently, we don't use `common_name`, e.g., `bee`, `wasp`, `moth`, etc. However, we hope to make use of it in the future as our `gene_alignment_data` "database" grows. + +First, you should set up a directory in our recommended structure: + +``` +treeval-resources +│ +├─ gene_alignment_data/ +│ ├─ { classT } +│ ├─ csv_data +│ │ └─ { Name.Assession }-data.csv # Generated by our scripts +│ ├─ { Name } # Here and below is generated by our scripts +│ ├─ { Name.Assession } +│ ├─ cdna +│ │ └─ { Chunked fasta files } +│ ├─ rna +│ │ └─ { Chunked fasta files } +│ ├─ cds +│ │ └─ { Chunked fasta files } +│ ├─ peps +│ └─ { Chunked fasta files } +│ +├─ gene_alignment_prep/ +│ ├─ scripts/ # We supply these in this repo +│ ├─ raw_fasta/ # Storing your fasta downloaded from NCBI or Ensembl +│ └─ treeval-datasets.tsv # Organism, common_name, clade, family, group, link_to_data, notes +│ +├─ synteny/ +│ └─ {classT} +│ +├─ treeval_yaml/ # Storage folder for you yaml files, it's useful to keep them +│ +└─ treeval_stats/ # Storage for you treeval output stats file whether for upload to our repo ``` -### Full samplesheet +`classT` can be your own system of classification, as long as it is consistent. At Sanger we use the below, we advise you do too. Again, this value, that is entered into the yaml (the file we will use to tell TreeVal where everything is), is used to find `gene_alignment_data` as well as syntenic genomes. -The pipeline will auto-detect whether a sample is single- or paired-end using the information provided in the samplesheet. The samplesheet can have as many columns as you desire, however, there is a strict requirement for the first 3 columns to match those defined in the table below. +![ClassT](../docs/images/Sanger-classT.png) -A final samplesheet file consisting of both single- and paired-end data may look something like the one below. This is for 6 samples, where `TREATMENT_REP3` has been sequenced twice. +
+ +### Synteny + +
+ Details + +For synteny, below the `classT` variable you should store the full genomic fasta file of any high quality genome you want to be compared against. + +For bird we recommend the Golden Eagle ( _Aquila chrysaetos_ ) and the Zebrafinch (_Taeniopygia guttata_), which can be downloaded from NCBI. Rename, these files to something more human readable, and drop them into the `synteny/bird/` folder. Any TreeVal run you now perform where the `classT` is bird will run a syntenic alignment against all genomes in that folder. It would be best to keep this to around three. Again, this is something we could expand on with the `common_name` field if people want in the future, submit a feature request. + +
+ +### Gene Alignment and Synteny Data and Directories + +
+ Details + +Seeing as this can be quite a complicated to set up here's a walk through. + +#### Step 1 - Set up the directories + +Lets set up the system as if we want to run it on a bird genome. -```console -sample,fastq_1,fastq_2 -CONTROL_REP1,AEG588A1_S1_L002_R1_001.fastq.gz,AEG588A1_S1_L002_R2_001.fastq.gz -CONTROL_REP2,AEG588A2_S2_L002_R1_001.fastq.gz,AEG588A2_S2_L002_R2_001.fastq.gz -CONTROL_REP3,AEG588A3_S3_L002_R1_001.fastq.gz,AEG588A3_S3_L002_R2_001.fastq.gz -TREATMENT_REP1,AEG588A4_S4_L003_R1_001.fastq.gz, -TREATMENT_REP2,AEG588A5_S5_L003_R1_001.fastq.gz, -TREATMENT_REP3,AEG588A6_S6_L003_R1_001.fastq.gz, -TREATMENT_REP3,AEG588A6_S6_L004_R1_001.fastq.gz, ``` +mkdir -p gene_alignment_prep/scripts/ -| Column | Description | -| --------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `sample` | Custom sample name. This entry will be identical for multiple sequencing libraries/runs from the same sample. Spaces in sample names are automatically converted to underscores (`_`). | -| `fastq_1` | Full path to FastQ file for Illumina short reads 1. File has to be gzipped and have the extension ".fastq.gz" or ".fq.gz". | -| `fastq_2` | Full path to FastQ file for Illumina short reads 2. File has to be gzipped and have the extension ".fastq.gz" or ".fq.gz". | +cp treeval/bin/treeval-dataprep/* gene_alignment_prep/scripts/ -An [example samplesheet](../assets/samplesheet.csv) has been provided with the pipeline. +mkdir -p gene_alignment_prep/raw_fasta/ -## Running the pipeline +mkdir -p gene_alignment_data/bird/csv_data/ -The typical command for running the pipeline is as follows: +mkdir -p synteny/bird/ +``` -```console -nextflow run nf-core/treeval --input samplesheet.csv --outdir --genome GRCh37 -profile docker +The naming of the bird folder here is important, keep this in mind. + +So now we have this structure: + +``` +~/treeval-resources + │ + ├─ synteny/ + │ └─ bird/ + │ + ├─ gene_alignment_data/ + │ └─ bird/ + │ └─ csv_data/ + │ + └─ gene_alignment_prep/ + ├─ scripts/ + └─ raw_fasta/ ``` -This will launch the pipeline with the `docker` configuration profile. See below for more information about profiles. +#### Step 2 - Download some data -Note that the pipeline will create the following files in your working directory: +First, let's download out sytenic alignment data. I think the Zebrafinch (_Taeniopygia guttata_) would be good against the Chicken (_Gallus gallus_). + +``` +cd synteny/bird/ + +curl https://ftp.ncbi.nlm.nih.gov/genomes/all/GCA/003/957/565/GCA_003957565.4_bTaeGut1.4.pri/GCA_003957565.4_bTaeGut1.4.pri_genomic.fna.gz -o bTaeGut1_4.fasta.gz + +gunzip bTaeGut1_4.fasta.gz +``` + +This leaves us with a file called `bTaeGut1_4.fasta` the genomic assembly of `bTaeGut1_4` (the [Tree of Life ID](https://id.tol.sanger.ac.uk)) for this species) also known as _Taeniopygia guttata_, the Australian Zebrafinch. + +Now lets move into the `raw_data` folder and download some data, this may take some time. + +``` +cd ../../gene_alignment_prep/raw_data/ + +curl https://ftp.ncbi.nlm.nih.gov/genomes/all/GCF/016/699/485/GCF_016699485.2_bGalGal1.mat.broiler.GRCg7b/GCF_016699485.2_bGalGal1.mat.broiler.GRCg7b_cds_from_genomic.fna.gz -o GallusGallus-GRCg7b.cds.fasta.gz + +curl https://ftp.ncbi.nlm.nih.gov/genomes/all/GCF/016/699/485/GCF_016699485.2_bGalGal1.mat.broiler.GRCg7b/GCF_016699485.2_bGalGal1.mat.broiler.GRCg7b_genomic.fna.gz -o GallusGallus-GRCg7b.cdna.fasta.gz + +curl https://ftp.ncbi.nlm.nih.gov/genomes/all/GCF/016/699/485/GCF_016699485.2_bGalGal1.mat.broiler.GRCg7b/GCF_016699485.2_bGalGal1.mat.broiler.GRCg7b_protein.faa.gz -o GallusGallus-GRCg7b.pep.fasta.gz + +curl https://ftp.ncbi.nlm.nih.gov/genomes/all/GCF/016/699/485/GCF_016699485.2_bGalGal1.mat.broiler.GRCg7b/GCF_016699485.2_bGalGal1.mat.broiler.GRCg7b_rna.fna.gz -o GallusGallus-GRCg7b.rna.fasta.gz +``` + +Now that's all downloaded we need to prep it. At this point it is all still gzipped (the `.gz` on the end denotes that the file is compressed) in this format we can't use it. So lets use some bash magic. + +This is a for loop written in bash, this will look through the current folder we are in for files ending with `.fasta.gz` and then gunzip them. This unzips the file, uncompresses it so it is usable, and then runs our python script, `GA_data_prep.py`. + +``` +for i in *.fasta.gz; do +gunzip $i; +python3 GA_data_prep.py ${i/.gz} ncbi 10; +done + +

+ This python script command here, in English, means. Take the file, uncompressed, that I downloaded from NCBI and cut it into pieces. A Fasta file looks something like this, with headers (lines starting with `>`) and sequence (the usual ATGC's): +

+

+> SCAFFOLD_1_DATA_ON_METHODS
+> ATGCGCATGCATGCATCGACTTCGAGCATCGTAG
+> SCAFFOLD_2_DATA_ON_METHODS
+> ACCAGTGCTAGCTAGCTACGTGTGGGTTTGCCCCGTTT
+```
+
+The headers here will be trimmed, to only essential data that you need in order to fine the sequence in your database of choice.
+
+Fasta file may be made up of anywhere between 10's to many thousands of these. So in the case of our `cdna` and `pep` files they need to be cut up to let TreeVal have a chance in reading them all in a small time frame. `cds` and `rna` files will be cut up into 1,000 header-sequence pairs per file. The number given on the command-line is ignored. `pep` and `cdna` will be cut up by a number you give or by 100. This is because the size of `pep` and `cdna` files are so much larger.
+
+The smaller the number you chunk a file, the smaller the files you produce which means you will also make many more files so there is a trade off.
+
+So the following script will produce a large amount of output in your terminal. Looking like:
+
+```
+python3 ../scripts/GA_data_prep.py GallusGallus-GRCg7b.cds.fasta ncbi 100
+
+Your using at least Version 3.6, You are good to go...
+os imported
+argparse imported
+regex imported
+WORKING ON: cds--GallusGallus-GRCg7b
+Records per file: 1000
+Entryfunction called
+GallusGallus-GRCg7b.cds.fasta
+File found at %s GallusGallus-GRCg7b.cds.fasta
+Renaming headers
+Read_fasta called
+File saved: -- ./GallusGallus/GallusGallus.GRCg7b/cds/GallusGallus1000cds.MOD.fa
+File saved: -- ./GallusGallus/GallusGallus.GRCg7b/cds/GallusGallus2001cds.MOD.fa
+File saved: -- ./GallusGallus/GallusGallus.GRCg7b/cds/GallusGallus3002cds.MOD.fa
+File saved: -- ./GallusGallus/GallusGallus.GRCg7b/cds/GallusGallus4003cds.MOD.fa
+File saved: -- ./GallusGallus/GallusGallus.GRCg7b/cds/GallusGallus5004cds.MOD.fa
+File saved: -- ./GallusGallus/GallusGallus.GRCg7b/cds/GallusGallus6005cds.MOD.fa
+File saved: -- ./GallusGallus/GallusGallus.GRCg7b/cds/GallusGallus7006cds.MOD.fa
+File saved: -- ./GallusGallus/GallusGallus.GRCg7b/cds/GallusGallus8007cds.MOD.fa
+File saved: -- ./GallusGallus/GallusGallus.GRCg7b/cds/GallusGallus9008cds.MOD.fa
+```
+
+This is pretty much telling us that, yes you have given me a file and for every 1000 (i'm ignoring the number you gave me because this isn't a `pep` or `cdna` file) header, sequence pairs I have come across I have made a new file found here. You'll notice that it has also generated a new set of folders. This is based off of how we have named the file.
+
+If you now type `ls` you should see the files we have downloaded (`GallusGallus-GRCg7b.cds.fasta`) and the folder `GallusGallus`. This folder we can now move to its permanent home.
+
+```
+mv GallusGallus/ ../../gene_alignment_data/bird/
+```
+
+#### Step 3 -- Generate the CSV
+
+This file will act as an index of all files we have produced in the `gene_alignment_data` folder, and thankfully is a very simple step.
+
+```
+cd ../
+python3 scripts/GA_csv_gen.py /path/to/gene_alignment_data/
+```
+
+Running this will look like:
+
+```
+============> CorvusMon1.bCorMon1 -- bird
+Generating CSV for:     CorvusMon1.bCorMon1
+Save Path:              /gene_alignment_data/bird/csv_data/CorvusMon1.bCorMon1-data.csv
+============> CorvusMoneduloides.bCorMon1 -- bird
+Generating CSV for:     CorvusMoneduloides.bCorMon1
+Save Path:              /gene_alignment_data/bird/csv_data/CorvusMoneduloides.bCorMon1-data.csv
+============> Gallus_gallus.UW_022020 -- bird
+Generating CSV for:     Gallus_gallus.UW_022020
+Save Path:              /gene_alignment_data/bird/csv_data/Gallus_gallus.UW_022020-data.csv
+============> Gallus_gallus.GRCg6a -- bird
+Generating CSV for:     Gallus_gallus.GRCg6a
+Save Path:              /gene_alignment_data/bird/csv_data/Gallus_gallus.GRCg6a-data.csv
+============> GallusGallus.GRCg7b -- bird
+Generating CSV for:     GallusGallus.GRCg7b
+Save Path:              /gene_alignment_data/bird/csv_data/GallusGallus.GRCg7b-data.csv
+```
+
+So what is happening is that it is moving through the directory, identifying each unique folder and generating a CSV summarising the data found in those directories into a csv with the following information, this looks like:
+
+```
+head -n 5 /gene_alignment_data/bird/csv_data/Gallus_gallus.GRCg6a-data.csv
+
+org,type,data_file
+Gallus_gallus.GRCg6a,cds,/gene_alignment_data/bird/Gallus_gallus/Gallus_gallus.GRCg6a/cds/Gallus_gallus9002cds.MOD.fa
+Gallus_gallus.GRCg6a,cds,/gene_alignment_data/bird/Gallus_gallus/Gallus_gallus.GRCg6a/cds/Gallus_gallus28453cds.MOD.fa
+Gallus_gallus.GRCg6a,cds,/gene_alignment_data/bird/Gallus_gallus/Gallus_gallus.GRCg6a/cds/Gallus_gallus18005cds.MOD.fa
+Gallus_gallus.GRCg6a,cds,/gene_alignment_data/bird/Gallus_gallus/Gallus_gallus.GRCg6a/cds/Gallus_gallus6001cds.MOD.fa
+```
+
+This is all useful for the pipeline which generates job ids based on the org column, groups files by org and type columns and then pulls data from the data file.
+
+#### Step 4 -- Understand where we are at
+
+So we have now generated the directory structure for `gene_alignment_data`. So now lets use what we know to fill out the yaml.
+
+The yaml is a file that we need in order to tell the pipeline where everything is, an example can be found [here](https://raw.githubusercontent.com/sanger-tol/treeval/dev/assets/local_testing/nxOscDF5033.yaml).
+
+Here we can see a number of fields that need to be filled out, the easiest being `synteny_genome_path` and `data_dir`. These refer to the directories we made earlier so we can replace them as such:
+
+```
+alignment:
+  data_dir: /FULL/PATH/TO/treeval-resources/gene_alignment_data/
+
+synteny_genome_path: /FULL/PATH/TO/treeval-resources/synteny
+```
+
+I said earlier that the the fact we called a folder `bird` was important, this is because it now becomes our `classT`:
+
+```
+classT: bird
+```
+
+During the running of the pipeline, this is appended onto the end of `data_dir` and `synteny_genome_path` in order to find the correct files to use. So now all of the files inside `/FULL/PATH/TO/treeval-resources/synteny/bird/ ` will be used for syntenic alignments. Likewise with our `alignment.data_dir`, TreeVal will turn this into `/FULL/PATH/TO/treeval-resources/gene_alignment_data/bird/` and then appends `csv_data`.
+
+In Step 3, we generated some files which will be living in our `/FULL/PATH/TO/treeval-resources/gene_alignment_data/bird/csv_data/` folder and look like `GallusGallus.GRCg7b-data.csv`. These (minus the `-data.csv`) will be what we enter into the `geneset` field in the yaml. The `common_name` is a field we don't currently use.
+
+```
+alignment:
+  data_dir: /FULL/PATH/TO/treeval-resources/gene_alignment_data/
+  common_name: "" # For future implementation (adding bee, wasp, ant etc)
+  geneset: "GallusGallus.GRCg7b"
+```
+
+However, what is cool about this field is that you can add as many as you want. So say you have the `alignment.data_dir` for the Finch saved as `TaeniopygiaGuttata.bTaeGut1_4`. The geneset field becomes: `geneset: "GallusGallus.GRCg7b,TaeniopygiaGuttata.bTaeGut1_4"`
+
+Hopefully this explains things a bit better and you understand how this sticks together!
+
+
+ +### HiC data Preparation + +
+ Details + +Illumina HiC read files should be presented in an unmapped CRAM format, each must be accompanied by an index file (.crai) generated by samtools index. If your unmapped HiC reads are in FASTQ format, you should first convert them to CRAM format by using samtools import methods. Examples are below: + +#### Conversion of FASTQ to CRAM + +``` +samtools import -@8 -r ID:{prefix} -r CN:{hic-kit} -r PU:{prefix} -r SM:{sample_name} {prefix}_R1.fastq.gz {prefix}_R2.fastq.gz -o {prefix}.cram +``` + +#### Indexing of CRAM + +``` +samtools index {prefix}.cram +``` + +
+ +### PacBio Data Preparation + +
+ Details + +Before running the pipeline data has to be in the `fasta.gz` format. Because of the software we use this data with it must also be long-read data as well as single stranded. This means you could use ONT too (except duplex reads). + +The below commands should help you convert from mapped bam to fasta.gz, or from fastq to fasta. + +If your data isn't already in these formats, then let us know and we'll see how we can help. + +#### BAM -> FASTQ + +This command iterates through your bam files and converts them to fastq via samtools. + +``` +cd { TO FOLDER OF BAM FILES } +mkdir fastq +for i in *bam +do + echo $i + j=${i%.bam} + echo $j + samtools bam2fq ${i} > fastq/${j}.fq +done +``` + +#### FASTQ -> FASTA + +This command creates a `fasta` folder (to store our fasta files), moves into the `fastq` folder and then converts `fastq` to `fasta` using seqtk seq. + +``` +mkdir fasta +cd fastq +for i in *fq; do + echo $i + j=${i%.fq} + echo $j + seqtk seq -a $i > ../fasta/${j}.fasta +done +``` + +#### FASTA -> FASTA.GZ + +This simply gzips the fasta files. + +``` +for i in .fasta; do + echo $i + gzip $i +done +``` + +#### Or if you're a command line ninja + +``` +samtools bam2fq {prefix}.bam| seqtk seq -a - | gzip - > {prefix}.fasta.gz +``` + +
+ +### Pretext Accessory File Ingestion + +
+ Details + +Note: This will require you to install bigwigToBedGraph from the ucsc package. Instructions on downloading this can be found at [EXAMPLE #3](https://genome.ucsc.edu/goldenPath/help/bigWig.html#:~:text=Alternatively%2C%20bigWig%20files%20can%20be,to%20the%20Genome%20Browser%20server.) + +The PreText files generated by the pipeline are not automatically ingested into the pretext files. For this you must use the following code: + +``` +cd {outdir}/hic_files + +bigWigToBedGraph {coverage.bigWig} /dev/stdout | PretextGraph -i { your.pretext } -n "coverage" + +bigWigToBedGraph {repeat_density.bigWig} /dev/stdout | PretextGraph -i { your.pretext } -n "repeat_density" + +cat {telomere.bedgraph} | awk -v OFS="\t" '{$4 = 1000; print}'|PretextGraph -i { your.pretext } -n "telomere" + +cat {gap.bedgraph} | awk -v OFS="\t" '{$4= 1000; print}'| PretextGraph -i { your.pretext } -n "gap" +``` + +
+ +## Full samplesheet + +YAML is "Yet Another Markdown Language", it is a human-readable format that we use to tell TreeVal a number of things. This includes; assembly location, telomere motif, pacbio data files (in fasta.gz format) and HiC cram files. The full Yaml is detailed below. + +### YAML contents + +The following is an example YAML file we have used during production: [nxOscDF5033.yaml](../assets/local_testing/nxOscDF5033.yaml) and is shown below. This contains some annotations we believe to be helpful, information on the alignment, synteny, pacbio and hic are explained here: [pacbio](pacbio.md), [genealignment and synteny](genealignmentsynteny.md). [nxOscDF5033.yaml](../assets/local_testing/nxOscDF5033.yaml) + +- `assembly` + - `sample_id`: ToLID of the sample. + - `latin_name`: Latin identification of species + - `classT`: Clade name (as used to group synteny sequences and to complete alignment/data_dir). + - `TicketType`: +- `reference_file`: Sample .fa file +- `assem_reads` + - `pacbio`: path to folder containing fasta.gz files. + - `hic`: path to folder containing cram files + - `supplementary`: #Will be required in future development. +- `alignment` + - `data_dir`: Gene alignment data path + - `common_name`: # For future implementation (adding bee, wasp, ant etc) + - `geneset`: a csv list of geneset data to be used +- `self_comp` + - `motif_len`: Length of motif to be used in self complementary sequence finding + - `mummer_chunk`: Size of chunks used by MUMMER module. +- `synteny` + - `synteny_genome_path`: Path to syntenic genomes grouped by clade. +- `outdir`: Will be required in future development. +- `intron:` + - `size`: base pair size of introns default is 50k +- `telomere`: + - `teloseq`: Telomeric motif +- `busco` + - `lineages_path`: path to folder above lineages folder + - `lineage`: Example is `nematode_odb10` + +
+ Notes on using BUSCO + +The pipeline requires the use of the BUSCO subworkflows. +Create the database directory and move into the directory: + +``` +DATE=2023_03 +BUSCO=/path/to/databases/busco_${DATE} +mkdir -p $BUSCO +cd $BUSCO +``` + +Download BUSCO data and lineages to allow BUSCO to run in offline mode. + +``` +wget -r -nH https://busco-data.ezlab.org/v5/data/ +``` + +The trailing slash after data is important. Otherwise wget doesn't download the subdirectories, which make up the database. + +Tar gunzip all folders that have been stored as tar.gz, in the same parent directories as where they were stored: + +``` +find v5/data -name "*.tar.gz" | while read -r TAR; do tar -C `dirname $TAR` -xzf $TAR; done +``` + +If you have [GNU parallel](https://www.gnu.org/software/parallel/) installed, you can also use the command below which will run faster as it will run the decompression commands in parallel: + +``` +find v5/data -name "*.tar.gz" | parallel "cd {//}; tar -xzf {/}" +``` + +
+ +
+ Sub-workflows + +- `YAML_INPUT` + - Reads the input yaml and generates parameters used by other workflows. +- `GENERATE_GENOME` + - Builds genome description file of the reference genome. +- `LONGREAD_COVERAGE` + - Produces read coverage based on pacbio long read fasta file. +- `GAP_FINDER` + - Identifies contig gaps in the input genome. +- `REPEAT_DENSITY` + - Reports the intensity of regional repeats within an input assembly. +- `HIC_MAPPING` + - Aligns illumina HiC short reads to the input genome, generates mapping file in three format for visualisation: .pretext, .hic and .mcool +- `TELO_FINDER` + - Find a user given motif in the input genome. +- `GENE_ALIGNMENT` + - Aligns the peptide and nuclear data from assemblies of related species to the input genome. +- `INSILICO_DIGEST` + - Generates a map of enzymatic digests using 3 Bionano enzymes. +- `SELFCOMP` + - Identifies regions of self-complementary sequence. +- `SYNTENY` + - Generates syntenic alignments between other high quality genomes. +- `BUSCO_ANALYSIS` + - Uses BUSCO to identify ancestral elements. Also use to identify ancestral Lepidopteran genes (merian units). + +
+ +## Running the pipeline + +The typical command for running the pipeline is as follows: ```console -work # Directory containing the nextflow working files - # Finished results in specified location (defined with --outdir) -.nextflow_log # Log file from Nextflow -# Other nextflow hidden files, eg. history of pipeline runs and old logs. +nextflow run sanger-tol/treeval --input assets/treeval.yaml --outdir -profile singularity, sanger ``` +With the `treeval.yaml` containing the information from the above YAML Contents section + ### Updating the pipeline When you run the above command, Nextflow automatically pulls the pipeline code from GitHub and stores it as a cached version. When running the pipeline after this, it will always use the cached version if available - even if the pipeline has been updated since. To make sure that you're running the latest version of the pipeline, make sure that you regularly update the cached version of the pipeline: ```console -nextflow pull nf-core/treeval +nextflow pull sanger-tol/treeval ``` ### Reproducibility It is a good idea to specify a pipeline version when running the pipeline on your data. This ensures that a specific version of the pipeline code and software are used when you run your pipeline. If you keep using the same tag, you'll be running the same version of the pipeline, even if there have been changes to the code since. -First, go to the [nf-core/treeval releases page](https://github.com/nf-core/treeval/releases) and find the latest version number - numeric only (eg. `1.3.1`). Then specify this when running the pipeline with `-r` (one hyphen) - eg. `-r 1.3.1`. +First, go to the [sanger-tol/treeval releases page](https://github.com/sanger-tol/treeval/releases) and find the latest version number - numeric only (eg. `1.3.1`). Then specify this when running the pipeline with `-r` (one hyphen) - eg. `-r 1.3.1`. This version number will be logged in reports when you run the pipeline, so that you'll know what you used when you look back in the future. @@ -136,98 +594,9 @@ Specify the path to a specific config file (this is a core Nextflow command). Se ### Resource requests -Whilst the default requirements set within the pipeline will hopefully work for most people and with most input data, you may find that you want to customise the compute resources that the pipeline requests. Each step in the pipeline has a default set of requirements for number of CPUs, memory and time. For most of the steps in the pipeline, if the job exits with any of the error codes specified [here](https://github.com/nf-core/rnaseq/blob/4c27ef5610c87db00c3c5a3eed10b1d161abf575/conf/base.config#L18) it will automatically be resubmitted with higher requests (2 x original, then 3 x original). If it still fails after the third attempt then the pipeline execution is stopped. - -For example, if the nf-core/rnaseq pipeline is failing after multiple re-submissions of the `STAR_ALIGN` process due to an exit code of `137` this would indicate that there is an out of memory issue: - -```console -[62/149eb0] NOTE: Process `NFCORE_RNASEQ:RNASEQ:ALIGN_STAR:STAR_ALIGN (WT_REP1)` terminated with an error exit status (137) -- Execution is retried (1) -Error executing process > 'NFCORE_RNASEQ:RNASEQ:ALIGN_STAR:STAR_ALIGN (WT_REP1)' - -Caused by: - Process `NFCORE_RNASEQ:RNASEQ:ALIGN_STAR:STAR_ALIGN (WT_REP1)` terminated with an error exit status (137) - -Command executed: - STAR \ - --genomeDir star \ - --readFilesIn WT_REP1_trimmed.fq.gz \ - --runThreadN 2 \ - --outFileNamePrefix WT_REP1. \ - - -Command exit status: - 137 - -Command output: - (empty) - -Command error: - .command.sh: line 9: 30 Killed STAR --genomeDir star --readFilesIn WT_REP1_trimmed.fq.gz --runThreadN 2 --outFileNamePrefix WT_REP1. -Work dir: - /home/pipelinetest/work/9d/172ca5881234073e8d76f2a19c88fb - -Tip: you can replicate the issue by changing to the process work dir and entering the command `bash .command.run` -``` - -To bypass this error you would need to find exactly which resources are set by the `STAR_ALIGN` process. The quickest way is to search for `process STAR_ALIGN` in the [nf-core/rnaseq Github repo](https://github.com/nf-core/rnaseq/search?q=process+STAR_ALIGN). -We have standardised the structure of Nextflow DSL2 pipelines such that all module files will be present in the `modules/` directory and so, based on the search results, the file we want is `modules/nf-core/software/star/align/main.nf`. -If you click on the link to that file you will notice that there is a `label` directive at the top of the module that is set to [`label process_high`](https://github.com/nf-core/rnaseq/blob/4c27ef5610c87db00c3c5a3eed10b1d161abf575/modules/nf-core/software/star/align/main.nf#L9). -The [Nextflow `label`](https://www.nextflow.io/docs/latest/process.html#label) directive allows us to organise workflow processes in separate groups which can be referenced in a configuration file to select and configure subset of processes having similar computing requirements. -The default values for the `process_high` label are set in the pipeline's [`base.config`](https://github.com/nf-core/rnaseq/blob/4c27ef5610c87db00c3c5a3eed10b1d161abf575/conf/base.config#L33-L37) which in this case is defined as 72GB. -Providing you haven't set any other standard nf-core parameters to **cap** the [maximum resources](https://nf-co.re/usage/configuration#max-resources) used by the pipeline then we can try and bypass the `STAR_ALIGN` process failure by creating a custom config file that sets at least 72GB of memory, in this case increased to 100GB. -The custom config below can then be provided to the pipeline via the [`-c`](#-c) parameter as highlighted in previous sections. - -```nextflow -process { - withName: 'NFCORE_RNASEQ:RNASEQ:ALIGN_STAR:STAR_ALIGN' { - memory = 100.GB - } -} -``` - -> **NB:** We specify the full process name i.e. `NFCORE_RNASEQ:RNASEQ:ALIGN_STAR:STAR_ALIGN` in the config file because this takes priority over the short name (`STAR_ALIGN`) and allows existing configuration using the full process name to be correctly overridden. -> -> If you get a warning suggesting that the process selector isn't recognised check that the process name has been specified correctly. - -### Updating containers - -The [Nextflow DSL2](https://www.nextflow.io/docs/latest/dsl2.html) implementation of this pipeline uses one container per process which makes it much easier to maintain and update software dependencies. If for some reason you need to use a different version of a particular tool with the pipeline then you just need to identify the `process` name and override the Nextflow `container` definition for that process using the `withName` declaration. For example, in the [nf-core/viralrecon](https://nf-co.re/viralrecon) pipeline a tool called [Pangolin](https://github.com/cov-lineages/pangolin) has been used during the COVID-19 pandemic to assign lineages to SARS-CoV-2 genome sequenced samples. Given that the lineage assignments change quite frequently it doesn't make sense to re-release the nf-core/viralrecon everytime a new version of Pangolin has been released. However, you can override the default container used by the pipeline by creating a custom config file and passing it as a command-line argument via `-c custom.config`. - -1. Check the default version used by the pipeline in the module file for [Pangolin](https://github.com/nf-core/viralrecon/blob/a85d5969f9025409e3618d6c280ef15ce417df65/modules/nf-core/software/pangolin/main.nf#L14-L19) -2. Find the latest version of the Biocontainer available on [Quay.io](https://quay.io/repository/biocontainers/pangolin?tag=latest&tab=tags) -3. Create the custom config accordingly: - - - For Docker: - - ```nextflow - process { - withName: PANGOLIN { - container = 'quay.io/biocontainers/pangolin:3.0.5--pyhdfd78af_0' - } - } - ``` - - - For Singularity: - - ```nextflow - process { - withName: PANGOLIN { - container = 'https://depot.galaxyproject.org/singularity/pangolin:3.0.5--pyhdfd78af_0' - } - } - ``` - - - For Conda: - - ```nextflow - process { - withName: PANGOLIN { - conda = 'bioconda::pangolin=3.0.5' - } - } - ``` +Whilst the default requirements set within the pipeline will hopefully work for most people and with most input data, you may find that you want to customise the compute resources that the pipeline requests. Each step in the pipeline has a default set of requirements for number of CPUs, memory and time. For most of the steps in the pipeline, if the job exits with any of the error codes specified [here](https://github.com/sanger-tol/blobtoolkit/blob/56906ffb5737e4b985797bb5fb4b9c94cfe69600/conf/base.config#L18) it will automatically be resubmitted with higher requests (2 x original, then 3 x original). If it still fails after the third attempt then the pipeline execution is stopped. -> **NB:** If you wish to periodically update individual tool-specific results (e.g. Pangolin) generated by the pipeline then you must ensure to keep the `work/` directory otherwise the `-resume` ability of the pipeline will be compromised and it will restart from scratch. +To change the resource requests, please see the [max resources](https://nf-co.re/docs/usage/configuration#max-resources) and [tuning workflow resources](https://nf-co.re/docs/usage/configuration#tuning-workflow-resources) section of the nf-core website. ### nf-core/configs diff --git a/lib/NfcoreSchema.groovy b/lib/NfcoreSchema.groovy index b3d092f8..9b34804d 100755 --- a/lib/NfcoreSchema.groovy +++ b/lib/NfcoreSchema.groovy @@ -2,6 +2,7 @@ // This file holds several functions used to perform JSON parameter validation, help and summary rendering for the nf-core pipeline template. // +import nextflow.Nextflow import org.everit.json.schema.Schema import org.everit.json.schema.loader.SchemaLoader import org.everit.json.schema.ValidationException @@ -46,7 +47,6 @@ class NfcoreSchema { 'quiet', 'syslog', 'v', - 'version', // Options for `nextflow run` command 'ansi', @@ -84,6 +84,7 @@ class NfcoreSchema { 'stub-run', 'test', 'w', + 'with-apptainer', 'with-charliecloud', 'with-conda', 'with-dag', @@ -178,7 +179,7 @@ class NfcoreSchema { } if (has_error) { - System.exit(1) + Nextflow.error('Exiting!') } } diff --git a/lib/NfcoreTemplate.groovy b/lib/NfcoreTemplate.groovy index 2fc0a9b9..b499f275 100755 --- a/lib/NfcoreTemplate.groovy +++ b/lib/NfcoreTemplate.groovy @@ -32,6 +32,25 @@ class NfcoreTemplate { } } + // + // Generate version string + // + public static String version(workflow) { + String version_string = "" + + if (workflow.manifest.version) { + def prefix_v = workflow.manifest.version[0] != 'v' ? 'v' : '' + version_string += "${prefix_v}${workflow.manifest.version}" + } + + if (workflow.commitId) { + def git_shortsha = workflow.commitId.substring(0, 7) + version_string += "-g${git_shortsha}" + } + + return version_string + } + // // Construct and send completion email // @@ -61,7 +80,7 @@ class NfcoreTemplate { misc_fields['Nextflow Compile Timestamp'] = workflow.nextflow.timestamp def email_fields = [:] - email_fields['version'] = workflow.manifest.version + email_fields['version'] = NfcoreTemplate.version(workflow) email_fields['runName'] = workflow.runName email_fields['success'] = workflow.success email_fields['dateComplete'] = workflow.complete @@ -145,6 +164,64 @@ class NfcoreTemplate { output_tf.withWriter { w -> w << email_txt } } + // + // Construct and send a notification to a web server as JSON + // e.g. Microsoft Teams and Slack + // + public static void IM_notification(workflow, params, summary_params, projectDir, log) { + def hook_url = params.hook_url + + def summary = [:] + for (group in summary_params.keySet()) { + summary << summary_params[group] + } + + def misc_fields = [:] + misc_fields['start'] = workflow.start + misc_fields['complete'] = workflow.complete + misc_fields['scriptfile'] = workflow.scriptFile + misc_fields['scriptid'] = workflow.scriptId + if (workflow.repository) misc_fields['repository'] = workflow.repository + if (workflow.commitId) misc_fields['commitid'] = workflow.commitId + if (workflow.revision) misc_fields['revision'] = workflow.revision + misc_fields['nxf_version'] = workflow.nextflow.version + misc_fields['nxf_build'] = workflow.nextflow.build + misc_fields['nxf_timestamp'] = workflow.nextflow.timestamp + + def msg_fields = [:] + msg_fields['version'] = NfcoreTemplate.version(workflow) + msg_fields['runName'] = workflow.runName + msg_fields['success'] = workflow.success + msg_fields['dateComplete'] = workflow.complete + msg_fields['duration'] = workflow.duration + msg_fields['exitStatus'] = workflow.exitStatus + msg_fields['errorMessage'] = (workflow.errorMessage ?: 'None') + msg_fields['errorReport'] = (workflow.errorReport ?: 'None') + msg_fields['commandLine'] = workflow.commandLine.replaceFirst(/ +--hook_url +[^ ]+/, "") + msg_fields['projectDir'] = workflow.projectDir + msg_fields['summary'] = summary << misc_fields + + // Render the JSON template + def engine = new groovy.text.GStringTemplateEngine() + // Different JSON depending on the service provider + // Defaults to "Adaptive Cards" (https://adaptivecards.io), except Slack which has its own format + def json_path = hook_url.contains("hooks.slack.com") ? "slackreport.json" : "adaptivecard.json" + def hf = new File("$projectDir/assets/${json_path}") + def json_template = engine.createTemplate(hf).make(msg_fields) + def json_message = json_template.toString() + + // POST + def post = new URL(hook_url).openConnection(); + post.setRequestMethod("POST") + post.setDoOutput(true) + post.setRequestProperty("Content-Type", "application/json") + post.getOutputStream().write(json_message.getBytes("UTF-8")); + def postRC = post.getResponseCode(); + if (! postRC.equals(200)) { + log.warn(post.getErrorStream().getText()); + } + } + // // Print pipeline summary on completion // @@ -154,7 +231,7 @@ class NfcoreTemplate { if (workflow.stats.ignoredCount == 0) { log.info "-${colors.purple}[$workflow.manifest.name]${colors.green} Pipeline completed successfully${colors.reset}-" } else { - log.info "-${colors.purple}[$workflow.manifest.name]${colors.red} Pipeline completed successfully, but with errored process(es) ${colors.reset}-" + log.info "-${colors.purple}[$workflow.manifest.name]${colors.yellow} Pipeline completed successfully, but with errored process(es) ${colors.reset}-" } } else { log.info "-${colors.purple}[$workflow.manifest.name]${colors.red} Pipeline completed with errors${colors.reset}-" @@ -242,15 +319,19 @@ class NfcoreTemplate { // public static String logo(workflow, monochrome_logs) { Map colors = logColours(monochrome_logs) + String workflow_version = NfcoreTemplate.version(workflow) String.format( """\n ${dashedLine(monochrome_logs)} - ${colors.green},--.${colors.black}/${colors.green},-.${colors.reset} - ${colors.blue} ___ __ __ __ ___ ${colors.green}/,-._.--~\'${colors.reset} - ${colors.blue} |\\ | |__ __ / ` / \\ |__) |__ ${colors.yellow}} {${colors.reset} - ${colors.blue} | \\| | \\__, \\__/ | \\ |___ ${colors.green}\\`-._,-`-,${colors.reset} - ${colors.green}`._,._,\'${colors.reset} - ${colors.purple} ${workflow.manifest.name} v${workflow.manifest.version}${colors.reset} + ${colors.blue} _____ ${colors.green} _______ ${colors.red} _${colors.reset} + ${colors.blue} / ____| ${colors.green}|__ __| ${colors.red}| |${colors.reset} + ${colors.blue} | (___ __ _ _ __ __ _ ___ _ __ ${colors.reset} ___ ${colors.green}| |${colors.yellow} ___ ${colors.red}| |${colors.reset} + ${colors.blue} \\___ \\ / _` | '_ \\ / _` |/ _ \\ '__|${colors.reset}|___|${colors.green}| |${colors.yellow}/ _ \\${colors.red}| |${colors.reset} + ${colors.blue} ____) | (_| | | | | (_| | __/ | ${colors.green}| |${colors.yellow} (_) ${colors.red}| |____${colors.reset} + ${colors.blue} |_____/ \\__,_|_| |_|\\__, |\\___|_| ${colors.green}|_|${colors.yellow}\\___/${colors.red}|______|${colors.reset} + ${colors.blue} __/ |${colors.reset} + ${colors.blue} |___/${colors.reset} + ${colors.purple} ${workflow.manifest.name} ${workflow_version}${colors.reset} ${dashedLine(monochrome_logs)} """.stripIndent() ) diff --git a/lib/TreeValProject.groovy b/lib/TreeValProject.groovy new file mode 100755 index 00000000..3c13c231 --- /dev/null +++ b/lib/TreeValProject.groovy @@ -0,0 +1,60 @@ +import java.time.OffsetDateTime; +import java.time.Duration; + +class TreeValProject { + // + // Generates a small summary containing context for the input files + // Creates a new file containing this context + pipeline_execution data + // Will be used for graph generation. + // + + public static void summary(workflow, params, metrics, log) { + + def date_completed = OffsetDateTime.now() + + def input_data = [:] + input_data['version'] = NfcoreTemplate.version( workflow ) + input_data['runName'] = workflow.runName + input_data['session_id'] = workflow.sessionId + input_data['duration'] = Duration.between( workflow.start, date_completed ).toSeconds() + input_data['DateStarted'] = workflow.start + input_data['DateCompleted'] = date_completed + input_data['entry'] = params.entry + + input_data['input_yaml'] = params.input + input_data['sample_name'] = metrics.sample_id + input_data['rf_data'] = metrics.rf_data + input_data['pb_data'] = metrics.pb_data + input_data['cm_data'] = metrics.cm_data + + def output_directory = new File("${params.tracedir}/") + if (!output_directory.exists()) { + output_directory.mkdirs() + } + + def output_hf = new File( output_directory, "input_data_${input_data.sample_name}_${input_data.entry}_${params.trace_timestamp}.txt" ) + output_hf.write """\ + ---RUN_DATA--- + Pipeline_version: ${input_data.version} + Pipeline_runname: ${input_data.runName} + Pipeline_session: ${input_data.session_id} + Pipeline_duration: ${input_data.duration} + Pipeline_datastrt: ${input_data.DateStarted} + Pipeline_datecomp: ${input_data.DateCompleted} + Pipeline_entrypnt: ${input_data.entry} + ---INPUT_DATA--- + InputSampleID: ${input_data.sample_name} + InputYamlFile: ${input_data.input_yaml} + InputAssemblyData: ${input_data.rf_data} + Input_PacBio_Files: ${input_data.pb_data} + Input_Cram_Files: ${input_data.cm_data} + ---RESOURCES--- + """.stripIndent() + + def full_file = new File( output_directory, "TreeVal_run_${input_data.sample_name}_${input_data.entry}_${params.trace_timestamp}.txt" ) + def file_locs = ["${params.tracedir}/input_data_${input_data.sample_name}_${input_data.entry}_${params.trace_timestamp}.txt", + "${params.tracedir}/pipeline_execution_${params.trace_timestamp}.txt"] + file_locs.each{ full_file.append( new File( it ).getText() ) } + + } +} diff --git a/lib/Utils.groovy b/lib/Utils.groovy index 28567bd7..8d030f4e 100755 --- a/lib/Utils.groovy +++ b/lib/Utils.groovy @@ -21,19 +21,26 @@ class Utils { } // Check that all channels are present - def required_channels = ['conda-forge', 'bioconda', 'defaults'] - def conda_check_failed = !required_channels.every { ch -> ch in channels } + // This channel list is ordered by required channel priority. + def required_channels_in_order = ['conda-forge', 'bioconda', 'defaults'] + def channels_missing = ((required_channels_in_order as Set) - (channels as Set)) as Boolean // Check that they are in the right order - conda_check_failed |= !(channels.indexOf('conda-forge') < channels.indexOf('bioconda')) - conda_check_failed |= !(channels.indexOf('bioconda') < channels.indexOf('defaults')) + def channel_priority_violation = false + def n = required_channels_in_order.size() + for (int i = 0; i < n - 1; i++) { + channel_priority_violation |= !(channels.indexOf(required_channels_in_order[i]) < channels.indexOf(required_channels_in_order[i+1])) + } - if (conda_check_failed) { + if (channels_missing | channel_priority_violation) { log.warn "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n" + " There is a problem with your Conda configuration!\n\n" + " You will need to set-up the conda-forge and bioconda channels correctly.\n" + - " Please refer to https://bioconda.github.io/user/install.html#set-up-channels\n" + - " NB: The order of the channels matters!\n" + + " Please refer to https://bioconda.github.io/\n" + + " The observed channel order is \n" + + " ${channels}\n" + + " but the following channel order is required:\n" + + " ${required_channels_in_order}\n" + "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~" } } diff --git a/lib/WorkflowMain.groovy b/lib/WorkflowMain.groovy index ab6b7c7f..1d20cf70 100755 --- a/lib/WorkflowMain.groovy +++ b/lib/WorkflowMain.groovy @@ -1,7 +1,9 @@ // -// This file holds several functions specific to the main.nf workflow in the nf-core/treeval pipeline +// This file holds several functions specific to the main.nf workflow in the sanger-tol/treeval pipeline // +import nextflow.Nextflow + class WorkflowMain { // @@ -19,10 +21,10 @@ class WorkflowMain { } // - // Print help to screen if required + // Generate help string // - public static String help(workflow, params, log) { - def command = "nextflow run ${workflow.manifest.name} --input samplesheet.csv --genome GRCh37 -profile docker" + public static String help(workflow, params) { + def command = "nextflow run ${workflow.manifest.name} --input treeval.yaml -profile singularity" def help_string = '' help_string += NfcoreTemplate.logo(workflow, params.monochrome_logs) help_string += NfcoreSchema.paramsHelp(workflow, params, command) @@ -32,9 +34,9 @@ class WorkflowMain { } // - // Print parameter summary log to screen + // Generate parameter summary log string // - public static String paramsSummaryLog(workflow, params, log) { + public static String paramsSummaryLog(workflow, params) { def summary_log = '' summary_log += NfcoreTemplate.logo(workflow, params.monochrome_logs) summary_log += NfcoreSchema.paramsSummaryLog(workflow, params) @@ -49,23 +51,30 @@ class WorkflowMain { public static void initialise(workflow, params, log) { // Print help to screen if required if (params.help) { - log.info help(workflow, params, log) + log.info help(workflow, params) + System.exit(0) + } + + // Print workflow version and exit on --version + if (params.version) { + String workflow_version = NfcoreTemplate.version(workflow) + log.info "${workflow.manifest.name} ${workflow_version}" System.exit(0) } + // Print parameter summary log to screen + log.info paramsSummaryLog(workflow, params) + // Validate workflow parameters via the JSON schema if (params.validate_params) { NfcoreSchema.validateParameters(workflow, params, log) } - // Print parameter summary log to screen - log.info paramsSummaryLog(workflow, params, log) - // Check that a -profile or Nextflow config has been provided to run the pipeline NfcoreTemplate.checkConfigProvided(workflow, log) // Check that conda channels are set-up correctly - if (params.enable_conda) { + if (workflow.profile.tokenize(',').intersect(['conda', 'mamba']).size() >= 1) { Utils.checkCondaChannels(log) } @@ -74,21 +83,7 @@ class WorkflowMain { // Check input has been provided if (!params.input) { - log.error "Please provide an input samplesheet to the pipeline e.g. '--input samplesheet.csv'" - System.exit(1) + Nextflow.error("Please provide an input samplesheet to the pipeline e.g. '--input samplesheet.csv'") } } - - // - // Get attribute from genome config file e.g. fasta - // - public static String getGenomeAttribute(params, attribute) { - def val = '' - if (params.genomes && params.genome && params.genomes.containsKey(params.genome)) { - if (params.genomes[ params.genome ].containsKey(attribute)) { - val = params.genomes[ params.genome ][ attribute ] - } - } - return val } -} diff --git a/lib/WorkflowTreeval.groovy b/lib/WorkflowTreeval.groovy index 573c1cb7..ff5cbd5b 100755 --- a/lib/WorkflowTreeval.groovy +++ b/lib/WorkflowTreeval.groovy @@ -1,31 +1,63 @@ // -// This file holds several functions specific to the workflow/treeval.nf in the nf-core/treeval pipeline +// This file holds several functions specific to the workflow/treeval.nf in the sanger-tol/treeval pipeline // +import nextflow.Nextflow +import groovy.text.SimpleTemplateEngine + class WorkflowTreeval { // // Check and validate parameters // public static void initialise(params, log) { - genomeExistsError(params, log) - //if (!params.fasta) { - // log.error "Genome fasta file not specified with e.g. '--fasta genome.fa' or via a detectable config file." - // System.exit(1) - //} + // Removed check for fasta flag, replaces with a check on the input yaml. + if (!params.input) { + log.error "Make sure your --input is a yaml file, following the standard set in the assets directory." + System.exit(1) + } } // - // Exit pipeline if incorrect --genome key provided + // Get workflow summary for MultiQC // - private static void genomeExistsError(params, log) { - //if (params.genomes && params.genome && !params.genomes.containsKey(params.genome)) { - // log.error "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n" + - // " Genome '${params.genome}' not found in any config files provided to the pipeline.\n" + - // " Currently, the available genome keys are:\n" + - // " ${params.genomes.keySet().join(", ")}\n" + - // "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~" - // System.exit(1) - //} + public static String paramsSummaryMultiqc(workflow, summary) { + String summary_section = '' + for (group in summary.keySet()) { + def group_params = summary.get(group) // This gets the parameters of that particular group + if (group_params) { + summary_section += "

$group

\n" + summary_section += "
\n" + for (param in group_params.keySet()) { + summary_section += "
$param
${group_params.get(param) ?: 'N/A'}
\n" + } + summary_section += "
\n" + } + } + + String yaml_file_text = "id: '${workflow.manifest.name.replace('/','-')}-summary'\n" + yaml_file_text += "description: ' - this information is collected when the pipeline is started.'\n" + yaml_file_text += "section_name: '${workflow.manifest.name} Workflow Summary'\n" + yaml_file_text += "section_href: 'https://github.com/${workflow.manifest.name}'\n" + yaml_file_text += "plot_type: 'html'\n" + yaml_file_text += "data: |\n" + yaml_file_text += "${summary_section}" + return yaml_file_text } -} + + public static String methodsDescriptionText(run_workflow, mqc_methods_yaml) { + // Convert to a named map so can be used as with familar NXF ${workflow} variable syntax in the MultiQC YML file + def meta = [:] + meta.workflow = run_workflow.toMap() + meta["manifest_map"] = run_workflow.manifest.toMap() + + meta["doi_text"] = meta.manifest_map.doi ? "(doi: ${meta.manifest_map.doi})" : "" + meta["nodoi_text"] = meta.manifest_map.doi ? "": "
  • If available, make sure to update the text to include the Zenodo DOI of version of the pipeline used.
  • " + + def methods_text = mqc_methods_yaml.text + + def engine = new SimpleTemplateEngine() + def description_html = engine.createTemplate(methods_text).make(meta) + + return description_html + }} diff --git a/lib/nfcore_external_java_deps.jar b/lib/nfcore_external_java_deps.jar old mode 100644 new mode 100755 diff --git a/main.nf b/main.nf old mode 100644 new mode 100755 index 2d7581e0..9a7b3fba --- a/main.nf +++ b/main.nf @@ -1,30 +1,20 @@ #!/usr/bin/env nextflow /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - nf-core/treeval + sanger-tol/treeval ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - Github : https://github.com/nf-core/treeval - Website: https://nf-co.re/treeval - Slack : https://nfcore.slack.com/channels/treeval ----------------------------------------------------------------------------------------- + Github : https://github.com/sanger-tol/treeval */ nextflow.enable.dsl = 2 -/* -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - GENOME PARAMETER VALUES -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -*/ - - /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ VALIDATE & PRINT PARAMETER SUMMARY ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */ -WorkflowMain.initialise(workflow, params, log) +WorkflowMain.initialise( workflow, params, log ) /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -32,11 +22,21 @@ WorkflowMain.initialise(workflow, params, log) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */ -include { TREEVAL } from './workflows/treeval' +include { TREEVAL } from './workflows/treeval' +include { TREEVAL_RAPID } from './workflows/treeval_rapid' + +// +// WORKFLOW: RUN MAIN PIPELINE GENERATING ALL OUTPUT +// +workflow SANGERTOL_TREEVAL { + TREEVAL () +} -// WORKFLOW: Run main nf-core/treeval analysis pipeline -workflow NFCORE_TREEVAL { - TREEVAL () +// +// WORKFLOW: RUN TRUNCATED PIPELINE TO PRODUCE CONTACT MAPS AND PRETEXT ACCESSORIES +// +workflow SANGERTOL_TREEVAL_RAPID { + TREEVAL_RAPID () } /* @@ -46,11 +46,14 @@ workflow NFCORE_TREEVAL { */ // -// WORKFLOW: Execute a single named workflow for the pipeline -// See: https://github.com/nf-core/rnaseq/issues/619 +// WORKFLOWS: Execute named workflow for the pipeline // workflow { - NFCORE_TREEVAL () + SANGERTOL_TREEVAL () +} + +workflow RAPID { + SANGERTOL_TREEVAL_RAPID () } /* diff --git a/modules.json b/modules.json old mode 100644 new mode 100755 index 6cd19367..b3f7eb35 --- a/modules.json +++ b/modules.json @@ -1,75 +1,185 @@ { - "name": "nf-core/treeval", - "homePage": "https://github.com/nf-core/treeval", + "name": "sanger-tol/treeval", + "homePage": "https://github.com/sanger-tol/treeval", "repos": { - "nf-core/modules": { - "bedtools/sort": { - "git_sha": "90aef30f432332bdf0ce9f4b9004aa5d5c4960bb" - }, - "blast/blastn": { - "git_sha": "e745e167c1020928ef20ea1397b6b4d230681b4d" - }, - "blast/makeblastdb": { - "git_sha": "e745e167c1020928ef20ea1397b6b4d230681b4d" - }, - "custom/dumpsoftwareversions": { - "git_sha": "5e7b1ef9a5a2d9258635bcbf70fcf37dacd1b247" - }, - "minimap2/align": { - "git_sha": "1a5a9e7b4009dcf34e6867dd1a5a1d9a718b027b" - }, - "mummer": { - "git_sha": "233fa70811a03a4cecb2ece483b5c8396e2cee1d" - }, - "nf-core/bedtools/sort": { - "git_sha": "4bb1d4e362a38642e877afe41aaf58ded9e56c86" - }, - "nf-core/samtools/merge": { - "git_sha": "5e34754d42cd2d5d248ca8673c0a53cdf5624905" - }, - "nf-core/tabix/bgziptabix": { - "git_sha": "5e34754d42cd2d5d248ca8673c0a53cdf5624905" - }, - "samtools/faidx": { - "git_sha": "3eb99152cedbb7280258858e5df08478a4670696" - }, - "ucsc/bedtobigbed": { - "git_sha": "90aef30f432332bdf0ce9f4b9004aa5d5c4960bb" - } - }, - "sanger-tol/nf-core-modules": { - "": { - "git_sha": "5f56c87e361ae0a90b1e54f574ab48c58988f5f7" - }, - "bedtools/bamtobed": { - "git_sha": "90aef30f432332bdf0ce9f4b9004aa5d5c4960bb" - }, - "blast/tblastn": { - "git_sha": "a6effa038df6248bad2329c6ab104c5ae9d556c5" - }, - "makecmap/cmap2bed": { - "git_sha": "8324137e04de193c0679570cd083ab4b0c4aabc2" - }, - "makecmap/fa2cmapmulticolor": { - "git_sha": "51d42ee53a0e317e0e7a02b6bf918a388c4661f9" - }, - "makecmap/renamecmapids": { - "git_sha": "461204ac9e8bae621a24a493db3ec9f8274b7757" - }, - "miniprot/align": { - "git_sha": "f7c0161a1375840fca96f1bab27d3e9a8d423b06" - }, - "miniprot/index": { - "git_sha": "5f56c87e361ae0a90b1e54f574ab48c58988f5f7" - }, - "selfcomp/mapids": { - "git_sha": "6f5a750a30268d30ab55ad2ae6e8af48b0d29d1b" - }, - "selfcomp/mummer2bed": { - "git_sha": "4a24b1eb1d2668c74de57d731c63749a7c8b6689" - }, - "selfcomp/splitfasta": { - "git_sha": "43e34c7c045533382f74dbde0157d407797c2918" + "https://github.com/nf-core/modules.git": { + "modules": { + "nf-core": { + "bedtools/bamtobed": { + "branch": "master", + "git_sha": "9e51255c4f8ec69fb6ccf68593392835f14fecb8", + "installed_by": ["modules"] + }, + "bedtools/genomecov": { + "branch": "master", + "git_sha": "9e51255c4f8ec69fb6ccf68593392835f14fecb8", + "installed_by": ["modules"] + }, + "bedtools/intersect": { + "branch": "master", + "git_sha": "c1532c77717ad7c64752b26b0fd9b4556bdef272", + "installed_by": ["modules"] + }, + "bedtools/makewindows": { + "branch": "master", + "git_sha": "911696ea0b62df80e900ef244d7867d177971f73", + "installed_by": ["modules"] + }, + "bedtools/map": { + "branch": "master", + "git_sha": "726ee59cd9360a965d96ea9ea8770f16b8ddd6cc", + "installed_by": ["modules"] + }, + "bedtools/merge": { + "branch": "master", + "git_sha": "9e51255c4f8ec69fb6ccf68593392835f14fecb8", + "installed_by": ["modules"] + }, + "bedtools/sort": { + "branch": "master", + "git_sha": "9e51255c4f8ec69fb6ccf68593392835f14fecb8", + "installed_by": ["modules"] + }, + "busco": { + "branch": "master", + "git_sha": "726ee59cd9360a965d96ea9ea8770f16b8ddd6cc", + "installed_by": ["modules"] + }, + "bwamem2/index": { + "branch": "master", + "git_sha": "911696ea0b62df80e900ef244d7867d177971f73", + "installed_by": ["modules"] + }, + "cat/cat": { + "branch": "master", + "git_sha": "911696ea0b62df80e900ef244d7867d177971f73", + "installed_by": ["modules"] + }, + "cooler/cload": { + "branch": "master", + "git_sha": "9e51255c4f8ec69fb6ccf68593392835f14fecb8", + "installed_by": ["modules"] + }, + "cooler/zoomify": { + "branch": "master", + "git_sha": "9e51255c4f8ec69fb6ccf68593392835f14fecb8", + "installed_by": ["modules"] + }, + "custom/dumpsoftwareversions": { + "branch": "master", + "git_sha": "911696ea0b62df80e900ef244d7867d177971f73", + "installed_by": ["modules"] + }, + "custom/getchromsizes": { + "branch": "master", + "git_sha": "911696ea0b62df80e900ef244d7867d177971f73", + "installed_by": ["modules"], + "patch": "modules/nf-core/custom/getchromsizes/custom-getchromsizes.diff" + }, + "gnu/sort": { + "branch": "master", + "git_sha": "88f6e982fb8bd40488d837b3b08a65008e602840", + "installed_by": ["modules"] + }, + "minimap2/align": { + "branch": "master", + "git_sha": "603ecbd9f45300c9788f197d2a15a005685b4220", + "installed_by": ["modules"] + }, + "minimap2/index": { + "branch": "master", + "git_sha": "911696ea0b62df80e900ef244d7867d177971f73", + "installed_by": ["modules"] + }, + "miniprot/align": { + "branch": "master", + "git_sha": "8d737766e8f3c1417212b4b56acb959f3c356d26", + "installed_by": ["modules"] + }, + "miniprot/index": { + "branch": "master", + "git_sha": "8d737766e8f3c1417212b4b56acb959f3c356d26", + "installed_by": ["modules"] + }, + "mummer": { + "branch": "master", + "git_sha": "9e51255c4f8ec69fb6ccf68593392835f14fecb8", + "installed_by": ["modules"] + }, + "paftools/sam2paf": { + "branch": "master", + "git_sha": "603ecbd9f45300c9788f197d2a15a005685b4220", + "installed_by": ["modules"] + }, + "pretextmap": { + "branch": "master", + "git_sha": "decfb802f2e573efb7b44ff06b11ecf16853054d", + "installed_by": ["modules"] + }, + "pretextsnapshot": { + "branch": "master", + "git_sha": "911696ea0b62df80e900ef244d7867d177971f73", + "installed_by": ["modules"] + }, + "samtools/faidx": { + "branch": "master", + "git_sha": "fd742419940e01ba1c5ecb172c3e32ec840662fe", + "installed_by": ["modules"] + }, + "samtools/markdup": { + "branch": "master", + "git_sha": "9e51255c4f8ec69fb6ccf68593392835f14fecb8", + "installed_by": ["modules"] + }, + "samtools/merge": { + "branch": "master", + "git_sha": "0460d316170f75f323111b4a2c0a2989f0c32013", + "installed_by": ["modules"] + }, + "samtools/sort": { + "branch": "master", + "git_sha": "a0f7be95788366c1923171e358da7d049eb440f9", + "installed_by": ["modules"] + }, + "samtools/view": { + "branch": "master", + "git_sha": "3ffae3598260a99e8db3207dead9f73f87f90d1f", + "installed_by": ["modules"] + }, + "seqtk/cutn": { + "branch": "master", + "git_sha": "726ee59cd9360a965d96ea9ea8770f16b8ddd6cc", + "installed_by": ["modules"] + }, + "tabix/bgziptabix": { + "branch": "master", + "git_sha": "5e7b1ef9a5a2d9258635bcbf70fcf37dacd1b247", + "installed_by": ["modules"] + }, + "ucsc/bedgraphtobigwig": { + "branch": "master", + "git_sha": "9e51255c4f8ec69fb6ccf68593392835f14fecb8", + "installed_by": ["modules"] + }, + "ucsc/bedtobigbed": { + "branch": "master", + "git_sha": "9e51255c4f8ec69fb6ccf68593392835f14fecb8", + "installed_by": ["modules"] + }, + "windowmasker/mk_counts": { + "branch": "master", + "git_sha": "30c3ed32e8bd5ddaf349ba2f4f99d38182fdc08c", + "installed_by": ["modules"] + }, + "windowmasker/ustat": { + "branch": "master", + "git_sha": "726ee59cd9360a965d96ea9ea8770f16b8ddd6cc", + "installed_by": ["modules"] + } + } + }, + "subworkflows": { + "nf-core": {} } } } diff --git a/modules/local/assign_ancestral.nf b/modules/local/assign_ancestral.nf new file mode 100755 index 00000000..5b94e625 --- /dev/null +++ b/modules/local/assign_ancestral.nf @@ -0,0 +1,35 @@ +process ASSIGN_ANCESTRAL { + tag "$meta.id" + label 'process_low' + + conda "conda-forge::python=3.9" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/pandas:1.5.2' : + 'biocontainers/pandas:1.5.2' }" + + input: + tuple val(meta), path(comp_location) + path(fulltable) + + output: + tuple val(meta), path("*bed") , emit: assigned_bed + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + + """ + assign_anc.py -l $comp_location -f $fulltable -c ${prefix}_assigned.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + python: \$(echo \$(python --version 2>&1) | sed 's/^.*python //; s/Using.*\$//') + pandas: \$(echo \$(pandas: python -c "import pandas as pd; print(pd.__version__)")) + assign_ancestral.py: \$(assign_ancestral.py --version | cut -d' ' -f2) + END_VERSIONS + """ +} diff --git a/modules/local/bamtobed_sort.nf b/modules/local/bamtobed_sort.nf new file mode 100755 index 00000000..87c20951 --- /dev/null +++ b/modules/local/bamtobed_sort.nf @@ -0,0 +1,41 @@ +process BAMTOBED_SORT { + tag "$meta.id" + label "process_high" + + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/mulled-v2-9d3a458f6420e5712103ae2af82c94d26d63f059:60b54b43045e8cf39ba307fd683c69d4c57240ce-0' : + 'biocontainers/mulled-v2-9d3a458f6420e5712103ae2af82c94d26d63f059:60b54b43045e8cf39ba307fd683c69d4c57240ce-0' }" + + input: + tuple val(meta), path(bam) + + output: + tuple val(meta), path("*.bed"), emit: sorted_bed + path "versions.yml" , emit: versions + + script: + def prefix = args.ext.prefix ?: "${meta.id}" + def st_cores = task.cpus > 4 ? 4 : "${task.cpus}" + def buffer_mem = task.memory.toGiga() / 2 + """ + samtools view -@${st_cores} -u -F0x400 ${bam} | bamToBed | sort -k4 --parallel=${task.cpus} -S ${buffer_mem}G > ${prefix}_merged_sorted.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + samtools: \$(echo \$(samtools --version 2>&1) | sed 's/^.*samtools //; s/Using.*\$//') + bedtools: \$(bedtools --version | sed -e "s/bedtools v//g") + END_VERSIONS + """ + + stub: + def prefix = args.ext.prefix ?: "${meta.id}" + """ + touch ${prefix}_merged_sorted.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + samtools: \$(echo \$(samtools --version 2>&1) | sed 's/^.*samtools //; s/Using.*\$//') + bedtools: \$(bedtools --version | sed -e "s/bedtools v//g") + END_VERSIONS + """ +} diff --git a/modules/local/bb_generator.nf b/modules/local/bb_generator.nf deleted file mode 100644 index 79304f9d..00000000 --- a/modules/local/bb_generator.nf +++ /dev/null @@ -1,22 +0,0 @@ -// Software does not generate version data - -process BB_GENERATOR { - tag "${meta.id}-${meta.type}" - label "process_medium" - - input: - tuple val( meta ), path( blast_out ), path( dotas ), path( genome ) - - output: - tuple val( meta ), path( "$meta.id-$meta.type-BB.bb" ), emit: bb_out - - script: - """ - $projectDir/bin/bedToBigBed -as=$dotas -type=bed6+2 -extraIndex=name,geneSymbol $blast_out $genome $meta.id-$meta.type-BB.bb - - cat <<-END_VERSIONS > versions.yml - "${task.process}": - bedToBigBed: SOMETHING - UPDATE - END_VERSIONS - """ -} diff --git a/modules/local/bedtools_bed_sort.nf b/modules/local/bedtools_bed_sort.nf deleted file mode 100644 index ed8e24f8..00000000 --- a/modules/local/bedtools_bed_sort.nf +++ /dev/null @@ -1,32 +0,0 @@ -process BEDTOOLS_BED_SORT { - tag "${meta.id}" - label "process_medium" - - def version = '2.30.0--hc088bd4_0' - - if (params.enable_conda) { - exit 1, "Conda environments cannot be used when using the chunkfasta process. Please use docker or singularity containers." - } - container "quay.io/repository/biocontainers/bedtools:${version}" - - input: - tuple val( meta ), path( merged_bam ) - - output: - tuple val( meta ), file( "*.bed" ), emit: sorted_bed - path "versions.yml", emit: versions - - script: - """ - bamToBed \\ - -i $merged_bam \\ - -bed12 | \\ - bedtools sort \\ - -i > $meta.id/.sorted.bed - - cat <<-END_VERSIONS > versions.yml - "${task.process}": - BEDTOOLS_BED_SORT: $version - END_VERSIONS - """ -} \ No newline at end of file diff --git a/modules/local/cat_blast.nf b/modules/local/cat_blast.nf deleted file mode 100644 index 9746ad6d..00000000 --- a/modules/local/cat_blast.nf +++ /dev/null @@ -1,15 +0,0 @@ -process CAT_BLAST { - tag "${meta.id} - ${meta.type}" - label "process_medium" - - input: - tuple val(meta), file(input_files) - - output: - tuple val(meta), file ("${meta.id}-${meta.type}-final_blast.tsv"), emit: concat_blast - - script: - """ - cat $input_files > $meta.id-$meta.type-final_blast.tsv - """ -} diff --git a/modules/local/chunkfasta.nf b/modules/local/chunkfasta.nf index 66304249..3c9113c4 100755 --- a/modules/local/chunkfasta.nf +++ b/modules/local/chunkfasta.nf @@ -1,19 +1,19 @@ process CHUNKFASTA { tag "${meta.id}" - label "process_medium" + label 'process_low' - if (params.enable_conda) { - exit 1, "Conda environments cannot be used when using the chunkfasta process. Please use docker or singularity containers." - } - container "quay.io/biocontainers/pyfasta:0.5.2--py_1" + conda "conda-forge::pyfasta=0.5.2-1" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/pyfasta:0.5.2--py_1' : + 'biocontainers/pyfasta:0.5.2--py_1' }" input: tuple val(meta), path(fasta) val(number_of_chunks) output: - tuple val(meta), path('*.fa'), emit: fas - path "versions.yml", emit: versions + tuple val(meta), path('*.fa') , emit: fas + path "versions.yml" , emit: versions script: """ @@ -24,4 +24,14 @@ process CHUNKFASTA { python: \$(python --version | sed 's/Python //g') END_VERSIONS """ + + stub: + """ + touch ${meta.id}.fa + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + python: \$(python --version | sed 's/Python //g') + END_VERSIONS + """ } diff --git a/modules/local/concat_gff.nf b/modules/local/concat_gff.nf deleted file mode 100644 index c06980e3..00000000 --- a/modules/local/concat_gff.nf +++ /dev/null @@ -1,15 +0,0 @@ -process CONCAT_GFF { - tag "${meta.id} - ${meta.type}" - label "process_medium" - - input: - tuple val(meta), file(input_files) - - output: - tuple val(meta), file ("${meta.id}-${meta.type}-all.gff"), emit: concat_gff - - script: - """ - cat $input_files > $meta.id-$meta.type-all.gff - """ -} \ No newline at end of file diff --git a/modules/local/concatblocks.nf b/modules/local/concatblocks.nf new file mode 100755 index 00000000..5c01459d --- /dev/null +++ b/modules/local/concatblocks.nf @@ -0,0 +1,47 @@ +process CONCATBLOCKS { + tag "${meta.id}.bed" + label "process_single" + + conda "conda-forge::coreutils=9.1" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/ubuntu:20.04' : + 'docker.io/ubuntu:20.04' }" + + input: + tuple val(meta), path(mergeblocks) + + output: + tuple val(meta), path("*.bed"), emit: chainfile + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + shell: + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = "9.1" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + $/ + cat "${mergeblocks}" \ + |awk '{split($4,a,":");print $1"\t"$2"\t"$3"\t"a[1]"\t"$5"\t"$6}'\ + |awk 'sqrt(($3-$2)*($3-$2)) > 5000'\ + |sort -k 1,1 -k2,2n \ + > ${prefix}_chain.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + coreutils: $VERSION + END_VERSIONS + /$ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = "9.1" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + """ + touch ${prefix}_chain.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + coreutils: $VERSION + END_VERSIONS + """ +} diff --git a/modules/local/concatmummer.nf b/modules/local/concatmummer.nf index 94217341..da38c968 100755 --- a/modules/local/concatmummer.nf +++ b/modules/local/concatmummer.nf @@ -2,27 +2,41 @@ process CONCATMUMMER { tag "${meta.id}.mummer" label "process_medium" - if (params.enable_conda) { - exit 1, "Conda environments cannot be used when using the mummer2bed process. Please use docker or singularity containers." - } + conda "conda-forge::coreutils=9.1" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? 'https://depot.galaxyproject.org/singularity/ubuntu:20.04' : - 'ubuntu:20.04' }" + 'docker.io/ubuntu:20.04' }" input: tuple val(meta), path(coords) output: - tuple val(meta), path("*.mummer"), emit: mummer - path "versions.yml", emit: versions + tuple val(meta), path("*.mummer") , emit: mummer + path "versions.yml" , emit: versions script: + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = "9.1" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. """ - cat $coords > ${meta.id}.mummer + cat $coords > ${prefix}.mummer cat <<-END_VERSIONS > versions.yml "${task.process}": ubuntu: \$(ubuntu --version | sed 's/Ubuntu //g') + coreutils: $VERSION + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = "9.1" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + """ + touch ${prefix}.mummer + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + ubuntu: \$(ubuntu --version | sed 's/Ubuntu //g') + coreutils: $VERSION END_VERSIONS """ } diff --git a/modules/local/cram_filter_align_bwamem2_fixmate_sort.nf b/modules/local/cram_filter_align_bwamem2_fixmate_sort.nf new file mode 100755 index 00000000..3c639b5b --- /dev/null +++ b/modules/local/cram_filter_align_bwamem2_fixmate_sort.nf @@ -0,0 +1,55 @@ +process CRAM_FILTER_ALIGN_BWAMEM2_FIXMATE_SORT { + tag "$meta.id" + label "process_high" + + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/mulled-v2-50d89b457e04ed90fa0cbf8ebc3ae1b9ffbc836b:caf993da1689e8d42f5e4c113ffc9ef81d26df96-0' : + 'biocontainers/mulled-v2-50d89b457e04ed90fa0cbf8ebc3ae1b9ffbc836b:caf993da1689e8d42f5e4c113ffc9ef81d26df96-0' }" + + input: + tuple val(meta), path(cramfile), path(cramindex), val(from), val(to), val(base), val(chunkid), val(rglines), val(bwaprefix) + + output: + tuple val(meta), path("*.bam"), emit: mappedbam + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def args1 = task.ext.args1 ?: '' + def args2 = task.ext.args2 ?: '' + def args3 = task.ext.args3 ?: '' + def args4 = task.ext.args4 ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + // Please be aware one of the tools here required mem = 28 * reference size!!! + """ + cram_filter -n ${from}-${to} ${cramfile} - | \\ + samtools fastq ${args1} | \\ + bwa-mem2 mem -p ${bwaprefix} -t${task.cpus} -5SPCp -H'${rglines}' - | \\ + samtools fixmate ${args3} - - | \\ + samtools sort ${args4} -@${task.cpus} -T ${base}_${chunkid}_sort_tmp -o ${prefix}_${base}_${chunkid}_mem.bam - + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + samtools: \$(echo \$(samtools --version 2>&1) | sed 's/^.*samtools //; s/Using.*\$//' ) + bwa-mem2: \$(bwa-mem2 --version | sed 's/bwa-mem2 //g') + END_VERSIONS + """ + // temp removal staden_io_lib: \$(echo \$(staden_io_lib --version 2>&1) | sed 's/^.*staden_io_lib //; s/Using.*\$//') CAUSES ERROR + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + def base = "45022_3#2" + def chunkid = "1" + """ + touch ${prefix}_${base}_${chunkid}_mem.bam + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + samtools: \$(echo \$(samtools --version 2>&1) | sed 's/^.*samtools //; s/Using.*\$//' ) + bwamem2: \$(echo \$(bwa-mem2 version 2>&1) | sed 's/.* //') + END_VERSIONS + """ +} diff --git a/modules/local/csv_generator.nf b/modules/local/csv_generator.nf deleted file mode 100644 index b54cedb9..00000000 --- a/modules/local/csv_generator.nf +++ /dev/null @@ -1,23 +0,0 @@ -process CSV_GENERATOR { - tag "${ch_org}" - label 'process_low' - - input: - val ch_org - val data_dir - val classT - - output: - path "${ch_org}-data.csv", emit: csv_path - - script: - def csv_loc = "/csv_data/" - """ - cp "${data_dir}${classT}${csv_loc}${ch_org}-data.csv" "${ch_org}-data.csv" - - cat <<-END_VERSIONS > versions.yml - "${task.process}": - csvgenerator: BASH - END_VERSIONS - """ -} diff --git a/modules/local/extract_ancestral.nf b/modules/local/extract_ancestral.nf new file mode 100755 index 00000000..265f9f2e --- /dev/null +++ b/modules/local/extract_ancestral.nf @@ -0,0 +1,50 @@ +process EXTRACT_ANCESTRAL { + tag "$meta.id" + label 'process_low' + + conda "conda-forge::python=3.9" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/python:3.9' : + 'biocontainers/python:3.9' }" + + input: + tuple val(meta), path(fulltable) + path(ancestraltable) + + output: + tuple val(meta), path("*buscopainter_complete_location.tsv") , emit: comp_location + path("*buscopainter_duplicated_location.tsv") , emit: dup_location + path("*summary.tsv") , emit: summary + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + + """ + buscopainter.py -r $ancestraltable -q $fulltable + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + python: \$(echo \$(python --version 2>&1) | sed 's/^.*python //; s/Using.*\$//') + buscopainter.py: \$(buscopainter.py -v) + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + """ + touch ${prefix}_buscopainter_complete_location.tsv + touch ${prefox}_buscopainter_duplicated_location.tsv + touch ${prefix}_summary.tsv + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + python: \$(echo \$(python --version 2>&1) | sed 's/^.*python //; s/Using.*\$//') + buscopainter.py: \$(buscopainter.py -v) + END_VERSIONS + """ +} diff --git a/modules/local/extract_buscogene.nf b/modules/local/extract_buscogene.nf new file mode 100755 index 00000000..44149d74 --- /dev/null +++ b/modules/local/extract_buscogene.nf @@ -0,0 +1,43 @@ +process EXTRACT_BUSCOGENE { + tag "$meta.id" + label 'process_low' + + conda "conda-forge::coreutils=9.1" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/ubuntu:20.04' : + 'docker.io/ubuntu:20.04' }" + + + input: + tuple val(meta), path(fulltable) + + output: + tuple val(meta), path("*.csv") , emit: genefile + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + """ + get_busco_gene.sh $fulltable > ${prefix}_buscogene.csv + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + get_busco_gene: \$(get_busco_gene.sh -v) + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + """ + touch ${prefix}_buscogene.csv + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + get_busco_gene: \$(get_busco_gene.sh -v) + END_VERSIONS + """ +} diff --git a/modules/local/extract_cov_iden.nf b/modules/local/extract_cov_iden.nf new file mode 100755 index 00000000..d50fd39c --- /dev/null +++ b/modules/local/extract_cov_iden.nf @@ -0,0 +1,42 @@ +process EXTRACT_COV_IDEN { + tag "${meta.id}" + label 'process_low' + + conda "conda-forge::coreutils=9.1" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/ubuntu:20.04' : + 'docker.io/ubuntu:20.04' }" + + input: + tuple val( meta ), path( file ) + + output: + tuple val( meta ), file( "*.bed" ) , emit: punchlist + path "versions.yml" , emit: versions + + script: + def prefix = task.ext.prefix ?: "${meta.id}_${meta.type}_punchlist" + def VERSION = "9.1" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + """ + extract_cov_iden.sh ${file} ${prefix}.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + extract_cov_iden: \$(extract_cov_iden.sh -v) + coreutils: $VERSION + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}_${meta.type}_punchlist" + def VERSION = "9.1" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + """ + touch ${prefix}.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + extract_cov_iden: \$(extract_cov_iden.sh -v) + coreutils: $VERSION + END_VERSIONS + """ +} diff --git a/modules/local/extract_repeat.nf b/modules/local/extract_repeat.nf new file mode 100755 index 00000000..85fe9c93 --- /dev/null +++ b/modules/local/extract_repeat.nf @@ -0,0 +1,45 @@ +process EXTRACT_REPEAT { + tag "$meta.id" + label 'process_low' + + conda "conda-forge::perl=5.26.2" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/perl:5.26.2' : + 'biocontainers/perl:5.26.2' }" + + input: + tuple val( meta ), path( file ) + + output: + tuple val( meta ), path( "*.bed" ) , emit: bed + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = "1.0" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + """ + extract_repeat.pl $file > ${prefix}_repeats.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + perl: \$(echo \$(perl --version 2>&1) | sed 's/^.*perl //; s/Using.*\$//') + extract_repeat.pl: $VERSION + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = "1.0" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + """ + touch ${prefix}_repeats.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + perl: \$(echo \$(perl --version 2>&1) | sed 's/^.*perl //; s/Using.*\$//') + extract_repeat.pl: $VERSION + END_VERSIONS + """ +} diff --git a/modules/local/extract_telo.nf b/modules/local/extract_telo.nf new file mode 100755 index 00000000..cad234fc --- /dev/null +++ b/modules/local/extract_telo.nf @@ -0,0 +1,43 @@ +process EXTRACT_TELO { + tag "${meta.id}" + label 'process_low' + + conda "conda-forge::coreutils=9.1" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/ubuntu:20.04' : + 'docker.io/ubuntu:20.04' }" + + input: + tuple val( meta ), path( file ) + + output: + tuple val( meta ), file( "*bed" ) , emit: bed + path("*bedgraph") , emit: bedgraph + path "versions.yml" , emit: versions + + shell: + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = "9.1" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + $/ + cat "${file}" |awk '{print $2"\t"$4"\t"$5}'|sed 's/>//g' > ${prefix}_telomere.bed + cat "${file}" |awk '{print $2"\t"$4"\t"$5"\t"$6}'|sed 's/>//g' > ${prefix}_telomere.bedgraph + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + coreutils: $VERSION + END_VERSIONS + /$ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = "9.1" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + """ + touch ${prefix}_telomere.bed + touch ${prefix}_telomere.bedgraph + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + coreutils: $VERSION + END_VERSIONS + """ +} diff --git a/modules/local/filter_blast.nf b/modules/local/filter_blast.nf deleted file mode 100644 index 95e07ec9..00000000 --- a/modules/local/filter_blast.nf +++ /dev/null @@ -1,31 +0,0 @@ -process FILTER_BLAST { - tag "${meta.id} - ${meta.type}" - label "process_low" - - def version = '0.004-c1' - - container "quay.io/sanger-tol/genealignment:${version}" - - input: - tuple val( meta ), file( concat_blast_out ) - - output: - tuple val( meta ), file( "${meta.id}-${meta.type}-*.tsv") , emit: final_tsv - path "versions.yml" , emit: versions - path "*log" - - script: - def filt_percent = task.ext.args ?: 90.00 - """ - filter_blast.py \\ - $meta.id \\ - $meta.type \\ - $concat_blast_out \\ - $filt_percent - - cat <<-END_VERSIONS > versions.yml - "${task.process}": - filter_blast: $version - END_VERSIONS - """ -} diff --git a/modules/local/find_telomere_regions.nf b/modules/local/find_telomere_regions.nf new file mode 100755 index 00000000..6f0d56c7 --- /dev/null +++ b/modules/local/find_telomere_regions.nf @@ -0,0 +1,41 @@ +process FIND_TELOMERE_REGIONS { + tag "${meta.id}" + label 'process_low' + + container 'docker.io/library/gcc:7.1.0' + + input: + tuple val( meta ), path( file ) + val (telomereseq) + + output: + tuple val( meta ), file( "*.telomere" ) , emit: telomere + path "versions.yml" , emit: versions + + script: + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = "1.0" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + def find_telomere = task.ext.find_telomere ?: '' + """ + find_telomere ${file} $telomereseq > ${prefix}.telomere + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + find_telomere: \$(find_telomere -v) + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = "1.0" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + def find_telomere = task.ext.find_telomere ?: '' + """ + touch ${prefix}.telomere + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + find_telomere: \$(find_telomere -v) + END_VERSIONS + """ + +} diff --git a/modules/local/find_telomere_windows.nf b/modules/local/find_telomere_windows.nf new file mode 100755 index 00000000..2fcd0022 --- /dev/null +++ b/modules/local/find_telomere_windows.nf @@ -0,0 +1,46 @@ +process FIND_TELOMERE_WINDOWS { + tag "${meta.id}" + label 'process_low' + + conda "bioconda::java-jdk=8.0.112" + container "${ workflow.containerEngine == 'singularity' && + !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/java-jdk:8.0.112--1' : + 'biocontainers/java-jdk:8.0.112--1' }" + + input: + tuple val( meta ), path( file ) + + output: + tuple val( meta ), file( "*.windows" ) , emit: windows + path "versions.yml" , emit: versions + + script: + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = "1.0" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + def telomere_jar = task.ext.telomere_jar ?: '' + def telomere_jvm_params = task.ext.telomere_jvm_params ?: '' + def telomere_window_cut = task.ext.telomere_window_cut ?: 99.9 + """ + java ${telomere_jvm_params} -cp ${projectDir}/bin/${telomere_jar} FindTelomereWindows $file $telomere_window_cut > ${prefix}.windows + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + telomere: $VERSION + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = "1.0" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + def telomere = task.ext.telomere ?: '' + """ + touch ${prefix}.windows + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + telomere: $VERSION + END_VERSIONS + """ + +} diff --git a/modules/local/findhalfcoverage.nf b/modules/local/findhalfcoverage.nf new file mode 100755 index 00000000..068ed6c4 --- /dev/null +++ b/modules/local/findhalfcoverage.nf @@ -0,0 +1,46 @@ +process FINDHALFCOVERAGE { + tag "${meta.id}" + label "process_single" + + conda "conda-forge::python=3.9" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/python:3.9' : + 'biocontainers/python:3.9' }" + + input: + tuple val(meta), path(bedfile) + path(my_genome) + path(depthgraph) + + output: + tuple val(meta), path("*.bed") , emit: bed + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "halfcoverage" + """ + findHalfcoverage.py -c $bedfile -m $my_genome -d $depthgraph > ${prefix}.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + python: \$(echo \$(python --version 2>&1) | sed 's/^.*python //; s/Using.*\$//') + findHalfcoverage.py: \$(findHalfcoverage.py --version | cut -d' ' -f2) + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "halfcoverage" + """ + touch ${prefix}.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + python: \$(echo \$(python --version 2>&1) | sed 's/^.*python //; s/Using.*\$//') + findHalfcoverage.py: \$(findHalfcoverage.py --version | cut -d' ' -f2) + END_VERSIONS + """ +} diff --git a/modules/local/gap_length.nf b/modules/local/gap_length.nf new file mode 100755 index 00000000..8dc384a9 --- /dev/null +++ b/modules/local/gap_length.nf @@ -0,0 +1,41 @@ +process GAP_LENGTH { + tag "$meta.id" + label 'process_low' + + conda "conda-forge::coreutils=9.1" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/ubuntu:20.04' : + 'docker.io/ubuntu:20.04' }" + + input: + tuple val( meta ), path( file ) + + output: + tuple val( meta ), file( "*bedgraph" ) , emit: bedgraph + path "versions.yml" , emit: versions + + shell: + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = "9.1" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + $/ + cat "${file}" \ + | awk '{print $0"\t"sqrt(($3-$2)*($3-$2))}' > ${prefix}_gap.bedgraph + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + coreutils: $VERSION + END_VERSIONS + /$ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = "9.1" + """ + touch ${prefix}_gap.bedgraph + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + coreutils: $VERSION + END_VERSIONS + """ +} diff --git a/modules/local/generate_cram_csv.nf b/modules/local/generate_cram_csv.nf new file mode 100755 index 00000000..6b6fe62c --- /dev/null +++ b/modules/local/generate_cram_csv.nf @@ -0,0 +1,40 @@ +process GENERATE_CRAM_CSV { + tag "${meta.id}" + label 'process_low' + + conda "bioconda::samtools=1.17" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/samtools:1.17--h00cdaf9_0' : + 'biocontainers/samtools:1.17--h00cdaf9_0' }" + + input: + tuple val(meta), path(crampath) + + + output: + tuple val(meta), path('*.csv'), emit: csv + path "versions.yml", emit: versions + + script: + def prefix = task.ext.prefix ?: "${meta.id}" + """ + generate_cram_csv.sh $crampath >> ${prefix}_cram.csv + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + samtools: \$(echo \$(samtools --version 2>&1) | sed 's/^.*samtools //; s/Using.*\$//' ) + bwa-mem2: \$(bwa-mem2 --version | sed 's/bwa-mem2 //g') + END_VERSIONS + """ + + stub: + """ + touch ${meta.id}.csv + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + samtools: \$(echo \$(samtools --version 2>&1) | sed 's/^.*samtools //; s/Using.*\$//' ) + bwa-mem2: \$(bwa-mem2 --version | sed 's/bwa-mem2 //g') + END_VERSIONS + """ +} diff --git a/modules/local/generate_genome_file.nf b/modules/local/generate_genome_file.nf deleted file mode 100644 index 86662b86..00000000 --- a/modules/local/generate_genome_file.nf +++ /dev/null @@ -1,15 +0,0 @@ -process GENERATE_GENOME_FILE { - tag "${meta.id}" - label "process_low" - - input: - tuple val( meta ), path( fai ) - - output: - tuple val( meta ), file( "my.genome" ), emit: dotgenome - - script: - """ - cut -f1,2 $fai | sort -k2,2 -nr > my.genome - """ -} \ No newline at end of file diff --git a/modules/local/get_largest_scaff.nf b/modules/local/get_largest_scaff.nf new file mode 100755 index 00000000..2296958c --- /dev/null +++ b/modules/local/get_largest_scaff.nf @@ -0,0 +1,40 @@ +process GET_LARGEST_SCAFF { + + tag "$meta.id" + label 'process_low' + + conda "conda-forge::coreutils=9.1" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/ubuntu:20.04' : + 'docker.io/ubuntu:20.04' }" + + input: + tuple val( meta ), path( file ) + + output: + env largest_scaff , emit: scaff_size + path "versions.yml" , emit: versions + + shell: + def VERSION = "9.1" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + $/ + largest_scaff=`head -n 1 "${file}" | cut -d$'\t' -f2` + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + coreutils: $VERSION + END_VERSIONS + /$ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = "9.1" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + """ + largest_scaff=1000000 + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + coreutils: $VERSION + END_VERSIONS + """ +} diff --git a/modules/local/get_paired_contact_bed.nf b/modules/local/get_paired_contact_bed.nf new file mode 100755 index 00000000..e6d3a135 --- /dev/null +++ b/modules/local/get_paired_contact_bed.nf @@ -0,0 +1,37 @@ +process GET_PAIRED_CONTACT_BED { + tag "$meta.id" + label 'process_low' + + conda "conda-forge::coreutils=9.1" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/ubuntu:20.04' : + 'docker.io/ubuntu:20.04' }" + + input: + tuple val( meta ), path( file ) + + output: + tuple val( meta ), file( "*bed" ) , emit: bed + path "versions.yml" , emit: versions + + script: + def pulled = '-T sort_tmp' + """ + bed_to_contacts.sh $file > pre.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + bed_to_contacts: \$(bed_to_contacts.sh -v) + END_VERSIONS + """ + + stub: + """ + touch ${meta.id}_paired.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + bed_to_contacts: \$(bed_to_contacts.sh -v) + END_VERSIONS + """ +} diff --git a/modules/local/get_synteny_genomes.nf b/modules/local/get_synteny_genomes.nf old mode 100644 new mode 100755 index 0cc797fb..506fbf5a --- a/modules/local/get_synteny_genomes.nf +++ b/modules/local/get_synteny_genomes.nf @@ -1,30 +1,47 @@ - process GET_SYNTENY_GENOMES { - tag "${assembly_classT}" - label "process_low" +process GET_SYNTENY_GENOMES { + tag "${assembly_classT}" + label "process_single" - input: - val ( synteny_path ) - val ( assembly_classT ) - - output: - path ( '*fasta' ), emit: genome_path - - script: - """ - if [ ! -d ${synteny_path}/${assembly_classT}/ ] || [ -z "\$(ls -A ${synteny_path}/${assembly_classT}/)" ] - then - echo "Directory is empty or doesn't exist" - touch empty.fasta - else - for i in "${synteny_path}/${assembly_classT}/*.fasta" - do - cp \$i . - done - fi - - cat <<-END_VERSIONS > versions.yml - "${task.process}": - GET_SYNTENY_GENOMES: BASH - END_VERSIONS - """ - } \ No newline at end of file + conda "conda-forge::coreutils=9.1" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/ubuntu:20.04' : + 'docker.io/ubuntu:20.04' }" + + input: + val ( synteny_path ) + val ( assembly_classT ) + + output: + path ( '*fasta' ) , emit: genome_path + path "versions.yml" , emit: versions + + script: + def VERSION = "9.1" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + """ + if [ ! -d ${synteny_path}${assembly_classT}/ ] || [ -z "\$(ls -A ${synteny_path}${assembly_classT}/)" ] + then + echo "Directory is empty or doesn't exist" + touch empty.fasta + else + cp ${synteny_path}${assembly_classT}/*.fasta . + fi + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + bash: \$(echo \$(bash --version | grep -Eo 'version [[:alnum:].]+' | sed 's/version //')) + coreutils: $VERSION + END_VERSIONS + """ + + stub: + def VERSION = "9.1" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + """ + touch empty.fasta + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + bash: \$(echo \$(bash --version | grep -Eo 'version [[:alnum:].]+' | sed 's/version //')) + coreutils: $VERSION + END_VERSIONS + """ +} diff --git a/modules/local/getminmaxpunches.nf b/modules/local/getminmaxpunches.nf new file mode 100755 index 00000000..6e828bb5 --- /dev/null +++ b/modules/local/getminmaxpunches.nf @@ -0,0 +1,41 @@ +process GETMINMAXPUNCHES{ + tag "${meta.id}" + label "process_single" + + conda "conda-forge::coreutils=9.1" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/ubuntu:20.04' : + 'docker.io/ubuntu:20.04' }" + + input: + tuple val(meta), path(bedfile) + + output: + tuple val(meta), path ( '*zero.bed' ) , optional: true , emit: min + tuple val(meta), path ( '*max.bed' ) , optional: true , emit: max + path "versions.yml" , emit: versions + + shell: + def VERSION = "9.1" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + $/ + cat "${bedfile}" \ + | awk '{ if ($4 == 0) {print $0 >> "zero.bed" } else if ($4 > 1000) {print $0 >> "max.bed"}}' + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + coreutils: $VERSION + END_VERSIONS + /$ + + stub: + def VERSION = "9.1" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + """ + touch max.bed + touch min.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + coreutils: $VERSION + END_VERSIONS + """ +} diff --git a/modules/local/graphoverallcoverage.nf b/modules/local/graphoverallcoverage.nf new file mode 100755 index 00000000..10c0a112 --- /dev/null +++ b/modules/local/graphoverallcoverage.nf @@ -0,0 +1,44 @@ +process GRAPHOVERALLCOVERAGE { + tag "$meta.id" + label "process_single" + + conda "conda-forge::perl=5.26.2" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/perl:5.26.2' : + 'biocontainers/perl:5.26.2' }" + + input: + tuple val(meta), path(bed) + + output: + tuple val(meta), path("*.part") , emit: part + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + """ + graph_overall_coverage.pl $bed > ${prefix}.part + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + perl: \$(echo \$(perl --version 2>&1) | sed 's/^.*perl //; s/Using.*\$//') + graph_overall_coverage.pl: \$(graph_overall_coverage.pl --version) + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + """ + touch ${prefix}.part + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + perl: \$(echo \$(perl --version 2>&1) | sed 's/^.*perl //; s/Using.*\$//') + graph_overall_coverage.pl: \$(graph_overall_coverage.pl --version) + END_VERSIONS + """ +} diff --git a/modules/local/juicer_tools_pre.nf b/modules/local/juicer_tools_pre.nf new file mode 100755 index 00000000..12b46ce8 --- /dev/null +++ b/modules/local/juicer_tools_pre.nf @@ -0,0 +1,40 @@ +// Branched from https://github.com/sanger-tol/genomeassembly/blob/dev/modules/local/juicer_tools_pre.nf + +process JUICER_TOOLS_PRE { + tag "$meta.id" + label 'process_medium' + + conda "bioconda::java-jdk=8.0.112" + container "${ workflow.containerEngine == 'singularity' && + !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/java-jdk:8.0.112--1' : + 'biocontainers/java-jdk:8.0.112--1' }" + + input: + tuple val(meta), path(pairs) + path sizes + val prefix + + output: + tuple val(meta), path("*hic"), emit: hic + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def juicer_tools_jar = task.ext.juicer_tools_jar ?: '' + def juicer_jvm_params = task.ext.juicer_jvm_params ?: '' + """ + java ${juicer_jvm_params} \\ + -jar ${projectDir}/bin/${juicer_tools_jar} pre \\ + ${pairs} \\ + ${prefix}.hic \\ + ${sizes} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + juicer tools: \$(java ${juicer_jvm_params} -jar ${projectDir}/bin/${juicer_tools_jar} -V | grep "Juicer Tools Version" | sed 's/Juicer Tools Version //') + END_VERSIONS + """ +} diff --git a/modules/local/makecmap_cmap2bed.nf b/modules/local/makecmap_cmap2bed.nf new file mode 100755 index 00000000..8d7914db --- /dev/null +++ b/modules/local/makecmap_cmap2bed.nf @@ -0,0 +1,46 @@ +process MAKECMAP_CMAP2BED { + tag "$meta.id" + label 'process_single' + + conda "conda-forge::python=3.9" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/python:3.9' : + 'biocontainers/python:3.9' }" + + input: + tuple val(meta), path(cmap) + val enzyme + + output: + tuple val(meta), path("*.bed"), emit: bedfile + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + """ + grep -v '#' $cmap > ${prefix}_${enzyme}_edited.cmap + cmap2bed.py -t ${prefix}_${enzyme}_edited.cmap -z $enzyme | sort -k1,1 -k2,2n > ${enzyme}.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + python: \$(echo \$(python --version 2>&1) | sed 's/^.*python //; s/Using.*\$//') + cmap2bed.py: \$(cmap2bed.py --version | cut -d' ' -f2) + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + """ + touch ${prefix}_${enzyme}.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + python: \$(echo \$(python --version 2>&1) | sed 's/^.*python //; s/Using.*\$//') + cmap2bed.py: \$(cmap2bed.py --version | cut -d' ' -f2) + END_VERSIONS + """ +} diff --git a/modules/local/makecmap_fa2cmapmulticolor.nf b/modules/local/makecmap_fa2cmapmulticolor.nf new file mode 100755 index 00000000..ef641ef4 --- /dev/null +++ b/modules/local/makecmap_fa2cmapmulticolor.nf @@ -0,0 +1,44 @@ +process MAKECMAP_FA2CMAPMULTICOLOR { + tag "$meta.id" + label 'process_low' + + conda "conda-forge::perl=5.26.2" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/perl:5.26.2' : + 'biocontainers/perl:5.26.2' }" + + input: + tuple val(meta), path(fasta) + val enzyme + + output: + tuple val(meta), path("*.cmap"), emit: cmap + path("*key.txt") , emit: cmapkey + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + """ + fa2cmap_multi_color.pl -i $fasta -e $enzyme 1 $args + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + perl: \$(echo \$(perl --version 2>&1) | sed 's/^.*perl //; s/Using.*\$//') + fa2cmap_multi_color.pl: \$(fa2cmap_multi_color.pl -v) + END_VERSIONS + """ + + stub: + """ + touch ${enzyme}_key.cmap + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + perl: \$(echo \$(perl --version 2>&1) | sed 's/^.*perl //; s/Using.*\$//') + fa2cmap_multi_color.pl: \$(fa2cmap_multi_color.pl -v) + END_VERSIONS + """ +} diff --git a/modules/local/makecmap_renamecmapids.nf b/modules/local/makecmap_renamecmapids.nf new file mode 100755 index 00000000..ce398b2e --- /dev/null +++ b/modules/local/makecmap_renamecmapids.nf @@ -0,0 +1,46 @@ +process MAKECMAP_RENAMECMAPIDS { + tag "$meta.id" + label 'process_low' + + conda "conda-forge::perl=5.26.2" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/perl:5.26.2' : + 'biocontainers/perl:5.26.2' }" + + input: + tuple val(meta), path(cmap) + path keys + + output: + tuple val(meta), path("*.cmap"), emit: renamedcmap + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + + """ + rename_cmapids.pl -cmapfile $cmap -idx_key $keys $args > ${prefix}_EDITED.cmap + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + perl: \$(echo \$(perl --version 2>&1) | sed 's/^.*perl //; s/Using.*\$//') + rename_cmapids.pl: \$(rename_cmapids.pl -version) + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + """ + touch ${prefix}_EDITED.cmap + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + perl: \$(echo \$(perl --version 2>&1) | sed 's/^.*perl //; s/Using.*\$//') + rename_cmapids.pl: \$(rename_cmapids.pl -version) + END_VERSIONS + """ +} diff --git a/modules/local/merge_bam.nf b/modules/local/merge_bam.nf deleted file mode 100644 index 5c03839b..00000000 --- a/modules/local/merge_bam.nf +++ /dev/null @@ -1,17 +0,0 @@ -process MERGE_BAM { - tag " ${meta.id} " - label "process_medium" - - container "" - - script: - """ - samtools merge merged.bam *.bam - - cat <<-END_VERSIONS > versions.yml - "${task.process}": - MERGE_BAM: $version - END_VERSIONS - """ - -} \ No newline at end of file diff --git a/modules/local/minimap_samtools.nf b/modules/local/minimap_samtools.nf deleted file mode 100644 index e6e0cdc4..00000000 --- a/modules/local/minimap_samtools.nf +++ /dev/null @@ -1,29 +0,0 @@ -process MINIMAP_SAMTOOLS { - tag "${meta.id}" - label "process_medium" - - def version = '2.22_1.12' - - container "niemasd/minimap2_samtools:${version}" - - input: - tuple val( ref_meta ), file( ref ) - tuple val( meta ), file( nuc_file ) - - output: - tuple val( meta ), file( "${nuc_file}.bam" ), emit: partial_alignment - path "versions.yml", emit: versions - - script: - def intron_size = task.ext.args ?: '50k' - """ - minimap2 -ax splice $ref $nuc_file -G $intron_size | samtools view -Sb -T $ref - > ${nuc_file}.bam - - cat <<-END_VERSIONS > versions.yml - "${task.process}": - MINIMAP_SAMTOOLS: $version - END_VERSIONS - """ -} - -//USE THE OFFICIAL MINIMAP MODULE \ No newline at end of file diff --git a/modules/local/paf_to_bed.nf b/modules/local/paf_to_bed.nf new file mode 100755 index 00000000..c50f0373 --- /dev/null +++ b/modules/local/paf_to_bed.nf @@ -0,0 +1,42 @@ +process PAF2BED { + tag "${meta.id}" + label 'process_low' + + conda "conda-forge::coreutils=9.1" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/ubuntu:20.04' : + 'docker.io/ubuntu:20.04' }" + + input: + tuple val( meta ), path( file ) + + output: + tuple val( meta ), file( "*_punchlist.bed" ), emit: punchlist + path "versions.yml" , emit: versions + + script: + def prefix = task.ext.prefix ?: "${meta.id}_${meta.type}_punchlist" + def VERSION = "9.1" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + """ + paf_to_bed.sh ${file} ${prefix}.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + paf_to_bed: \$(paf_to_bed.sh -v) + coreutils: $VERSION + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}_${meta.type}_punchlist" + def VERSION = "9.1" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + """ + touch ${prefix}.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + paf_to_bed: \$(paf_to_bed.sh -v) + coreutils: $VERSION + END_VERSIONS + """ +} diff --git a/modules/local/reformat_intersect.nf b/modules/local/reformat_intersect.nf new file mode 100755 index 00000000..1d1930ce --- /dev/null +++ b/modules/local/reformat_intersect.nf @@ -0,0 +1,42 @@ +process REFORMAT_INTERSECT { + tag "${meta.id}" + label 'process_low' + + conda "conda-forge::coreutils=9.1" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/ubuntu:20.04' : + 'docker.io/ubuntu:20.04' }" + + input: + tuple val( meta ), path( file ) + + output: + tuple val( meta ), file( "*.bed" ), emit: bed + + shell: + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = "9.1" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + + $/ + cat "${file}" \ + | awk '{print $0"\t"sqrt(($3-$2)*($3-$2))}'\ + | sed 's/\./0/g' > ${prefix}_fmt_INTERSECT.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + coreutils: $VERSION + END_VERSIONS + /$ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = "9.1" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + """ + touch ${prefix}_fmt_INTERSECT.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + coreutils: $VERSION + END_VERSIONS + """ +} diff --git a/modules/local/rename_ids.nf b/modules/local/rename_ids.nf new file mode 100755 index 00000000..f69f518d --- /dev/null +++ b/modules/local/rename_ids.nf @@ -0,0 +1,44 @@ +process RENAME_IDS { + tag "${meta.id}" + label 'process_low' + + conda "conda-forge::coreutils=9.1" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/ubuntu:20.04' : + 'docker.io/ubuntu:20.04' }" + + input: + tuple val( meta ), path( file ) + + output: + tuple val( meta ), file( "*bed" ) , emit: bed + path "versions.yml" , emit: versions + + shell: + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = "9.1" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + + $/ + cat "${file}" \ + | sed 's/\./0/g' > ${prefix}_renamed.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + coreutils: $VERSION + END_VERSIONS + /$ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = "9.1" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + """ + touch ${prefix}_renamed.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + rename_ids: \$(rename_ids.sh -v) + coreutils: $VERSION + END_VERSIONS + """ + +} diff --git a/modules/local/replace_dots.nf b/modules/local/replace_dots.nf new file mode 100755 index 00000000..4d12f5cd --- /dev/null +++ b/modules/local/replace_dots.nf @@ -0,0 +1,40 @@ +process REPLACE_DOTS { + tag "${meta.id}" + label 'process_low' + + conda "conda-forge::coreutils=9.1" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/ubuntu:20.04' : + 'docker.io/ubuntu:20.04' }" + + input: + tuple val( meta ), path( file ) + + output: + tuple val( meta ), file( "*bed" ), emit: bed + path "versions.yml" , emit: versions + + shell: + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = "9.1" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + $/ + cat "${file}" | sed 's/\./0/g' > "${prefix}_nodot.bed" + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + coreutils: $VERSION + END_VERSIONS + /$ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = "9.1" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + """ + touch ${prefix}_nodot.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + coreutils: $VERSION + END_VERSIONS + """ +} diff --git a/modules/local/selfcomp_alignmentblocks.nf b/modules/local/selfcomp_alignmentblocks.nf new file mode 100755 index 00000000..419a7b42 --- /dev/null +++ b/modules/local/selfcomp_alignmentblocks.nf @@ -0,0 +1,48 @@ +process SELFCOMP_ALIGNMENTBLOCKS { + tag "$meta.id" + label "process_medium" + + conda "conda-forge::python=3.9" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/mulled-v2-548f120dc8914d802c46e110ec27751bc1c5a414:8770fa59aa0ae8b50cbf444255b91c201c883685-0' : + 'biocontainers/mulled-v2-548f120dc8914d802c46e110ec27751bc1c5a414:8770fa59aa0ae8b50cbf444255b91c201c883685-0' }" + + input: + tuple val(meta), path(bedfile) + + output: + tuple val(meta), path("*.block"), emit: blockfile + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + """ + build_alignment_block.py $args -i $bedfile -o ${prefix}_chained.block + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + python: \$(echo \$(python --version 2>&1) | sed 's/^.*python //; s/Using.*\$//') + pandas: \$(echo \$(pandas: python -c "import pandas as pd; print(pd.__version__)")) + pybedtools: \$(echo \$(pybedtools: python -c "import pybedtools as pb; print(pb.__version__)")) + build_alignment_block.py: \$(build_alignment_block.py --version | cut -d' ' -f2) + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + """ + touch ${prefix}_chained.block + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + python: \$(echo \$(python --version 2>&1) | sed 's/^.*python //; s/Using.*\$//') + pandas: \$(echo \$(pandas: python -c "import pandas as pd; print(pd.__version__)")) + pybedtools: \$(echo \$(pybedtools: python -c "import pybedtools as pb; print(pb.__version__)")) + build_alignment_block.py: \$(build_alignment_block.py --version | cut -d' ' -f2) + END_VERSIONS + """ +} diff --git a/modules/local/selfcomp_mapids.nf b/modules/local/selfcomp_mapids.nf new file mode 100755 index 00000000..be40c76e --- /dev/null +++ b/modules/local/selfcomp_mapids.nf @@ -0,0 +1,46 @@ +process SELFCOMP_MAPIDS { + tag "$meta.id" + label "process_medium" + + conda "conda-forge::python=3.9" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/python:3.9' : + 'biocontainers/python:3.9' }" + + input: + tuple val(meta), path(bed) + path(agp) + + output: + tuple val(meta), path("*.bed"), emit: bedfile + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + """ + mapids.py -i $bed -r $agp > ${prefix}_mapped.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + python: \$(echo \$(python --version 2>&1) | sed 's/^.*python //; s/Using.*\$//') + mapids.py: \$(mapids.py --version | cut -d' ' -f2) + END_VERSIONS + """ + + stub: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + """ + touch ${prefix}_mapped.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + python: \$(echo \$(python --version 2>&1) | sed 's/^.*python //; s/Using.*\$//') + mapids.py: \$(mapids.py --version | cut -d' ' -f2) + END_VERSIONS + """ +} diff --git a/modules/local/selfcomp_mummer2bed.nf b/modules/local/selfcomp_mummer2bed.nf new file mode 100755 index 00000000..02a215cb --- /dev/null +++ b/modules/local/selfcomp_mummer2bed.nf @@ -0,0 +1,47 @@ +process SELFCOMP_MUMMER2BED { + tag "$meta.id" + label "process_medium" + + conda "conda-forge::python=3.9" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/python:3.9' : + 'biocontainers/python:3.9' }" + + input: + tuple val(meta), path(mummerfile) + val (motiflen) + + output: + tuple val(meta), path("*.bed"), emit: bedfile + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + + """ + mummer2bed.py $args -i $mummerfile -l $motiflen > ${prefix}.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + python: \$(echo \$(python --version 2>&1) | sed 's/^.*python //; s/Using.*\$//') + mummer2bed.py: \$(mummer2bed.py --version | cut -d' ' -f2) + END_VERSIONS + """ + + stub: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + """ + touch ${prefix}.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + python: \$(echo \$(python --version 2>&1) | sed 's/^.*python //; s/Using.*\$//') + mummer2bed.py: \$(mapids.py --version | cut -d' ' -f2) + END_VERSIONS + """ +} diff --git a/modules/local/selfcomp_splitfasta.nf b/modules/local/selfcomp_splitfasta.nf new file mode 100755 index 00000000..510febe8 --- /dev/null +++ b/modules/local/selfcomp_splitfasta.nf @@ -0,0 +1,52 @@ +process SELFCOMP_SPLITFASTA { + tag "$meta.id" + label "process_medium" + + conda "conda-forge::perl-bioperl=1.7.8-1" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/perl-bioperl:1.7.8--hdfd78af_1' : + 'biocontainers/perl-bioperl:1.7.8--hdfd78af_1' }" + + input: + tuple val(meta), path(fasta) + + output: + tuple val(meta), path("*.fa"), emit: fa + path("*.agp") , emit: agp + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = "1.7.8-1" + """ + split_genomes_for_ensembl.pl $fasta ${prefix}_split.fa ${prefix}_split.agp + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + perl: \$(echo \$(perl --version 2>&1) | sed 's/^.*perl //; s/Using.*\$//') + perl-bioperl: $VERSION + split_genomes_for_ensembl.pl: \$(split_genomes_for_ensembl.pl --version) + END_VERSIONS + """ + + stub: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = "1.7.8-1" + """ + touch ${prefix}_split.agp + touch ${prefix}_split.fa + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + perl: \$(echo \$(perl --version 2>&1) | sed 's/^.*perl //; s/Using.*\$//') + perl-bioperl: $VERSION + split_genomes_for_ensembl.pl: \$(split_genomes_for_ensembl.pl --version) + END_VERSIONS + """ +} + diff --git a/modules/sanger-tol/nf-core-modules/bedtools/bamtobed/main.nf b/modules/nf-core/bedtools/bamtobed/main.nf old mode 100644 new mode 100755 similarity index 64% rename from modules/sanger-tol/nf-core-modules/bedtools/bamtobed/main.nf rename to modules/nf-core/bedtools/bamtobed/main.nf index e3d3ee21..ab8a6ffb --- a/modules/sanger-tol/nf-core-modules/bedtools/bamtobed/main.nf +++ b/modules/nf-core/bedtools/bamtobed/main.nf @@ -1,11 +1,11 @@ process BEDTOOLS_BAMTOBED { tag "$meta.id" - label 'process_single' + label 'process_medium' - conda (params.enable_conda ? "bioconda::bedtools=2.30.0" : null) + conda "bioconda::bedtools=2.31.0" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/bedtools:2.30.0--hc088bd4_0' : - 'quay.io/biocontainers/bedtools:2.30.0--hc088bd4_0' }" + 'https://depot.galaxyproject.org/singularity/bedtools:2.31.0--hf5e1c6e_2' : + 'biocontainers/bedtools:2.31.0--hf5e1c6e_2' }" input: tuple val(meta), path(bam) @@ -25,7 +25,18 @@ process BEDTOOLS_BAMTOBED { bamtobed \\ $args \\ -i $bam \\ - | bedtools sort > ${prefix}.bed + > ${prefix}.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + bedtools: \$(bedtools --version | sed -e "s/bedtools v//g") + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + """ + touch ${prefix}.bed cat <<-END_VERSIONS > versions.yml "${task.process}": diff --git a/modules/sanger-tol/nf-core-modules/bedtools/bamtobed/meta.yml b/modules/nf-core/bedtools/bamtobed/meta.yml old mode 100644 new mode 100755 similarity index 96% rename from modules/sanger-tol/nf-core-modules/bedtools/bamtobed/meta.yml rename to modules/nf-core/bedtools/bamtobed/meta.yml index 5a4ff73a..49cc83d9 --- a/modules/sanger-tol/nf-core-modules/bedtools/bamtobed/meta.yml +++ b/modules/nf-core/bedtools/bamtobed/meta.yml @@ -3,6 +3,9 @@ description: Converts a bam file to a bed12 file. keywords: - bam - bed + - bedtools + - bamtobed + - converter tools: - bedtools: description: | diff --git a/modules/nf-core/bedtools/genomecov/main.nf b/modules/nf-core/bedtools/genomecov/main.nf new file mode 100755 index 00000000..d2a2f206 --- /dev/null +++ b/modules/nf-core/bedtools/genomecov/main.nf @@ -0,0 +1,70 @@ +process BEDTOOLS_GENOMECOV { + tag "$meta.id" + label 'process_single' + + conda "bioconda::bedtools=2.31.0" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/bedtools:2.31.0--hf5e1c6e_2' : + 'biocontainers/bedtools:2.31.0--hf5e1c6e_2' }" + + input: + tuple val(meta), path(intervals), val(scale) + path sizes + val extension + + output: + tuple val(meta), path("*.${extension}"), emit: genomecov + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def args_list = args.tokenize() + args += (scale > 0 && scale != 1) ? " -scale $scale" : "" + if (!args_list.contains('-bg') && (scale > 0 && scale != 1)) { + args += " -bg" + } + + def prefix = task.ext.prefix ?: "${meta.id}" + if (intervals.name =~ /\.bam/) { + """ + bedtools \\ + genomecov \\ + -ibam $intervals \\ + $args \\ + > ${prefix}.${extension} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + bedtools: \$(bedtools --version | sed -e "s/bedtools v//g") + END_VERSIONS + """ + } else { + """ + bedtools \\ + genomecov \\ + -i $intervals \\ + -g $sizes \\ + $args \\ + > ${prefix}.${extension} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + bedtools: \$(bedtools --version | sed -e "s/bedtools v//g") + END_VERSIONS + """ + } + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + """ + touch ${prefix}.${extension} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + bedtools: \$(bedtools --version | sed -e "s/bedtools v//g") + END_VERSIONS + """ +} diff --git a/modules/nf-core/bedtools/genomecov/meta.yml b/modules/nf-core/bedtools/genomecov/meta.yml new file mode 100755 index 00000000..efd6e129 --- /dev/null +++ b/modules/nf-core/bedtools/genomecov/meta.yml @@ -0,0 +1,53 @@ +name: bedtools_genomecov +description: Computes histograms (default), per-base reports (-d) and BEDGRAPH (-bg) summaries of feature coverage (e.g., aligned sequences) for a given genome. +keywords: + - bed + - bam + - genomecov + - bedtools + - histogram +tools: + - bedtools: + description: | + A set of tools for genomic analysis tasks, specifically enabling genome arithmetic (merge, count, complement) on various file types. + documentation: https://bedtools.readthedocs.io/en/latest/content/tools/genomecov.html + licence: ["MIT"] +input: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - intervals: + type: file + description: BAM/BED/GFF/VCF + pattern: "*.{bam|bed|gff|vcf}" + - scale: + type: integer + description: Number containing the scale factor for the output. Set to 1 to disable. Setting to a value other than 1 will also get the -bg bedgraph output format as this is required for this command switch + - sizes: + type: file + description: Tab-delimited table of chromosome names in the first column and chromosome sizes in the second column + - extension: + type: string + description: Extension of the output file (e. g., ".bg", ".bedgraph", ".txt", ".tab", etc.) It is set arbitrarily by the user and corresponds to the file format which depends on arguments. +output: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - genomecov: + type: file + description: Computed genome coverage file + pattern: "*.${extension}" + - versions: + type: file + description: File containing software versions + pattern: "versions.yml" +authors: + - "@Emiller88" + - "@sruthipsuresh" + - "@drpatelh" + - "@sidorov-si" + - "@chris-cheshire" diff --git a/modules/nf-core/bedtools/intersect/main.nf b/modules/nf-core/bedtools/intersect/main.nf new file mode 100755 index 00000000..6805582e --- /dev/null +++ b/modules/nf-core/bedtools/intersect/main.nf @@ -0,0 +1,59 @@ +process BEDTOOLS_INTERSECT { + tag "$meta.id" + label 'process_single' + + conda "bioconda::bedtools=2.30.0" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/bedtools:2.30.0--hc088bd4_0' : + 'biocontainers/bedtools:2.30.0--hc088bd4_0' }" + + input: + tuple val(meta), path(intervals1), path(intervals2) + tuple val(meta2), path(chrom_sizes) + + output: + tuple val(meta), path("*.${extension}"), emit: intersect + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + //Extension of the output file. It is set by the user via "ext.suffix" in the config. Corresponds to the file format which depends on arguments (e. g., ".bed", ".bam", ".txt", etc.). + extension = task.ext.suffix ?: "${intervals1.extension}" + def sizes = chrom_sizes ? "-g ${chrom_sizes}" : '' + if ("$intervals1" == "${prefix}.${extension}" || + "$intervals2" == "${prefix}.${extension}") + error "Input and output names are the same, use \"task.ext.prefix\" to disambiguate!" + """ + bedtools \\ + intersect \\ + -a $intervals1 \\ + -b $intervals2 \\ + $args \\ + $sizes \\ + > ${prefix}.${extension} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + bedtools: \$(bedtools --version | sed -e "s/bedtools v//g") + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + extension = task.ext.suffix ?: "bed" + if ("$intervals1" == "${prefix}.${extension}" || + "$intervals2" == "${prefix}.${extension}") + error "Input and output names are the same, use \"task.ext.prefix\" to disambiguate!" + """ + touch ${prefix}.${extension} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + bedtools: \$(bedtools --version | sed -e "s/bedtools v//g") + END_VERSIONS + """ +} diff --git a/modules/nf-core/bedtools/intersect/meta.yml b/modules/nf-core/bedtools/intersect/meta.yml new file mode 100755 index 00000000..f2848967 --- /dev/null +++ b/modules/nf-core/bedtools/intersect/meta.yml @@ -0,0 +1,54 @@ +name: bedtools_intersect +description: Allows one to screen for overlaps between two sets of genomic features. +keywords: + - bed + - intersect + - overlap +tools: + - bedtools: + description: | + A set of tools for genomic analysis tasks, specifically enabling genome arithmetic (merge, count, complement) on various file types. + documentation: https://bedtools.readthedocs.io/en/latest/content/tools/intersect.html + licence: ["MIT"] +input: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - intervals1: + type: file + description: BAM/BED/GFF/VCF + pattern: "*.{bam|bed|gff|vcf}" + - intervals2: + type: file + description: BAM/BED/GFF/VCF + pattern: "*.{bam|bed|gff|vcf}" + - meta2: + type: map + description: | + Groovy Map containing reference chromosome sizes + e.g. [ id:'test' ] + - chrom_sizes: + type: file + description: Chromosome sizes file + pattern: "*{.sizes,.txt}" +output: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - intersect: + type: file + description: File containing the description of overlaps found between the two features + pattern: "*.${extension}" + - versions: + type: file + description: File containing software versions + pattern: "versions.yml" +authors: + - "@Emiller88" + - "@sruthipsuresh" + - "@drpatelh" + - "@sidorov-si" diff --git a/modules/nf-core/bedtools/makewindows/main.nf b/modules/nf-core/bedtools/makewindows/main.nf new file mode 100755 index 00000000..96dcff15 --- /dev/null +++ b/modules/nf-core/bedtools/makewindows/main.nf @@ -0,0 +1,49 @@ +process BEDTOOLS_MAKEWINDOWS { + tag "$meta.id" + label 'process_single' + + conda "bioconda::bedtools=2.30.0" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/bedtools:2.30.0--h7d7f7ad_1' : + 'biocontainers/bedtools:2.30.0--h7d7f7ad_1' }" + + input: + tuple val(meta), path(regions) + + output: + tuple val(meta), path("*.bed"), emit: bed + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + def arg_input = regions.extension in ["bed", "tab"] ? "-b ${regions}" : "-g ${regions}" + if ("${regions}" == "${prefix}.bed") error "Input and output names are the same, set prefix in module configuration to disambiguate!" + """ + bedtools \\ + makewindows \\ + ${arg_input} \\ + ${args} \\ + > ${prefix}.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + bedtools: \$(bedtools --version | sed -e "s/bedtools v//g") + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + if ("${regions}" == "${prefix}.bed") error "Input and output names are the same, set prefix in module configuration to disambiguate!" + """ + touch ${prefix}.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + bedtools: \$(bedtools --version | sed -e "s/bedtools v//g") + END_VERSIONS + """ +} diff --git a/modules/nf-core/bedtools/makewindows/meta.yml b/modules/nf-core/bedtools/makewindows/meta.yml new file mode 100755 index 00000000..f543da69 --- /dev/null +++ b/modules/nf-core/bedtools/makewindows/meta.yml @@ -0,0 +1,41 @@ +name: bedtools_makewindows +description: Makes adjacent or sliding windows across a genome or BED file. +keywords: + - bed + - windows + - fai + - chunking +tools: + - bedtools: + description: A set of tools for genomic analysis tasks, specifically enabling genome arithmetic (merge, count, complement) on various file types. + homepage: https://bedtools.readthedocs.io + documentation: https://bedtools.readthedocs.io/en/latest/content/tools/makewindows.html + doi: "10.1093/bioinformatics/btq033" + licence: ["MIT"] +input: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - regions: + type: file + description: BED file OR Genome details file () + pattern: "*.{bed,tab,fai}" +output: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - versions: + type: file + description: File containing software versions + pattern: "versions.yml" + - bed: + type: file + description: BED file containing the windows + pattern: "*.bed" +authors: + - "@kevbrick" + - "@nvnieuwk" diff --git a/modules/nf-core/bedtools/map/main.nf b/modules/nf-core/bedtools/map/main.nf new file mode 100755 index 00000000..846d5ba2 --- /dev/null +++ b/modules/nf-core/bedtools/map/main.nf @@ -0,0 +1,58 @@ +process BEDTOOLS_MAP { + tag "$meta.id" + label 'process_single' + + conda "bioconda::bedtools=2.31.0" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/bedtools:2.31.0--hf5e1c6e_2' : + 'biocontainers/bedtools:2.31.0--hf5e1c6e_2' }" + + input: + tuple val(meta), path(intervals1), path(intervals2) + tuple val(meta2), path(chrom_sizes) + + output: + tuple val(meta), path("*.${extension}"), emit: map + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + extension = intervals1.getExtension() + def sizes = chrom_sizes ? "-g ${chrom_sizes}" : '' + if ("$intervals1" == "${prefix}.${extension}" || + "$intervals2" == "${prefix}.${extension}") + error "Input and output names are the same, use \"task.ext.prefix\" to disambiguate!" + """ + bedtools \\ + map \\ + -a $intervals1 \\ + -b $intervals2 \\ + $args \\ + $sizes \\ + > ${prefix}.${extension} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + bedtools: \$(bedtools --version | sed -e "s/bedtools v//g") + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + extension = intervals1.getExtension() + if ("$intervals1" == "${prefix}.${extension}" || + "$intervals2" == "${prefix}.${extension}") + error "Input and output names are the same, use \"task.ext.prefix\" to disambiguate!" + """ + touch ${prefix}.${extension} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + bedtools: \$(bedtools --version | sed -e "s/bedtools v//g") + END_VERSIONS + """ +} diff --git a/modules/nf-core/bedtools/map/meta.yml b/modules/nf-core/bedtools/map/meta.yml new file mode 100755 index 00000000..b0ce79d2 --- /dev/null +++ b/modules/nf-core/bedtools/map/meta.yml @@ -0,0 +1,53 @@ +name: bedtools_map +description: Allows one to screen for overlaps between two sets of genomic features. +keywords: + - bed + - vcf + - gff + - map + - bedtools +tools: + - bedtools: + description: | + A set of tools for genomic analysis tasks, specifically enabling genome arithmetic (merge, count, complement) on various file types. + documentation: https://bedtools.readthedocs.io/en/latest/content/tools/map.html + licence: ["MIT"] +input: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - intervals1: + type: file + description: BAM/BED/GFF/VCF + pattern: "*.{bed|gff|vcf}" + - intervals2: + type: file + description: BAM/BED/GFF/VCF + pattern: "*.{bed|gff|vcf}" + - meta2: + type: map + description: | + Groovy Map containing reference chromosome sizes + e.g. [ id:'test' ] + - chrom_sizes: + type: file + description: Chromosome sizes file + pattern: "*{.sizes,.txt}" +output: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - map: + type: file + description: File containing the description of overlaps found between the features in A and the features in B, with statistics + pattern: "*.${extension}" + - versions: + type: file + description: File containing software versions + pattern: "versions.yml" +authors: + - "@ekushele" diff --git a/modules/nf-core/bedtools/merge/main.nf b/modules/nf-core/bedtools/merge/main.nf new file mode 100755 index 00000000..6868d39f --- /dev/null +++ b/modules/nf-core/bedtools/merge/main.nf @@ -0,0 +1,47 @@ +process BEDTOOLS_MERGE { + tag "$meta.id" + label 'process_single' + + conda "bioconda::bedtools=2.31.0" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/bedtools:2.31.0--hf5e1c6e_2' : + 'biocontainers/bedtools:2.31.0--hf5e1c6e_2' }" + + input: + tuple val(meta), path(bed) + + output: + tuple val(meta), path('*.bed'), emit: bed + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + if ("$bed" == "${prefix}.bed") error "Input and output names are the same, use \"task.ext.prefix\" to disambiguate!" + """ + bedtools \\ + merge \\ + -i $bed \\ + $args \\ + > ${prefix}.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + bedtools: \$(bedtools --version | sed -e "s/bedtools v//g") + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + """ + touch ${prefix}.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + bedtools: \$(bedtools --version | sed -e "s/bedtools v//g") + END_VERSIONS + """ +} diff --git a/modules/nf-core/modules/nf-core/bedtools/sort/meta.yml b/modules/nf-core/bedtools/merge/meta.yml old mode 100644 new mode 100755 similarity index 59% rename from modules/nf-core/modules/nf-core/bedtools/sort/meta.yml rename to modules/nf-core/bedtools/merge/meta.yml index 369e51ff..82248afe --- a/modules/nf-core/modules/nf-core/bedtools/sort/meta.yml +++ b/modules/nf-core/bedtools/merge/meta.yml @@ -1,13 +1,15 @@ -name: bedtools_sort -description: Sorts a feature file by chromosome and other criteria. +name: bedtools_merge +description: combines overlapping or “book-ended” features in an interval file into a single feature which spans all of the combined features. keywords: - bed - - sort + - merge + - bedtools + - overlapped bed tools: - bedtools: description: | A set of tools for genomic analysis tasks, specifically enabling genome arithmetic (merge, count, complement) on various file types. - documentation: https://bedtools.readthedocs.io/en/latest/content/tools/sort.html + documentation: https://bedtools.readthedocs.io/en/latest/content/tools/merge.html licence: ["MIT"] input: - meta: @@ -15,26 +17,20 @@ input: description: | Groovy Map containing sample information e.g. [ id:'test', single_end:false ] - - intervals: + - bed: type: file - description: BED/BEDGRAPH - pattern: "*.{bed|bedGraph}" - - - extension: - type: string - description: Extension of the output file (e. g., ".bg", ".bedgraph", ".txt", ".tab", etc.) It is set arbitrarily by the user and corresponds to the file format which depends on arguments. + description: Input BED file + pattern: "*.{bed}" output: - meta: type: map description: | Groovy Map containing sample information e.g. [ id:'test', single_end:false ] - - - sorted: + - bed: type: file - description: Sorted output file - pattern: "*.${extension}" - + description: Overlapped bed file with combined features + pattern: "*.{bed}" - versions: type: file description: File containing software versions @@ -43,4 +39,3 @@ authors: - "@Emiller88" - "@sruthipsuresh" - "@drpatelh" - - "@chris-cheshire" diff --git a/modules/nf-core/modules/nf-core/bedtools/sort/main.nf b/modules/nf-core/bedtools/sort/main.nf old mode 100644 new mode 100755 similarity index 50% rename from modules/nf-core/modules/nf-core/bedtools/sort/main.nf rename to modules/nf-core/bedtools/sort/main.nf index 331c129a..df372bc5 --- a/modules/nf-core/modules/nf-core/bedtools/sort/main.nf +++ b/modules/nf-core/bedtools/sort/main.nf @@ -2,14 +2,14 @@ process BEDTOOLS_SORT { tag "$meta.id" label 'process_single' - conda (params.enable_conda ? "bioconda::bedtools=2.30.0" : null) + conda "bioconda::bedtools=2.31.0" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/bedtools:2.30.0--hc088bd4_0' : - 'quay.io/biocontainers/bedtools:2.30.0--hc088bd4_0' }" + 'https://depot.galaxyproject.org/singularity/bedtools:2.31.0--hf5e1c6e_2' : + 'biocontainers/bedtools:2.31.0--hf5e1c6e_2' }" input: tuple val(meta), path(intervals) - val extension + path genome_file output: tuple val(meta), path("*.${extension}"), emit: sorted @@ -19,13 +19,18 @@ process BEDTOOLS_SORT { task.ext.when == null || task.ext.when script: - def args = task.ext.args ?: '' - def prefix = task.ext.prefix ?: "${meta.id}" - if ("$intervals" == "${prefix}.${extension}") error "Input and output names are the same, use \"task.ext.prefix\" to disambiguate!" + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + def genome_cmd = genome_file ? "-g $genome_file" : "" + extension = task.ext.suffix ?: intervals.extension + if ("$intervals" == "${prefix}.${extension}") { + error "Input and output names are the same, use \"task.ext.prefix\" to disambiguate!" + } """ bedtools \\ sort \\ -i $intervals \\ + $genome_cmd \\ $args \\ > ${prefix}.${extension} @@ -34,4 +39,16 @@ process BEDTOOLS_SORT { bedtools: \$(bedtools --version | sed -e "s/bedtools v//g") END_VERSIONS """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + extension = task.ext.suffix ?: intervals.extension + """ + touch ${prefix}.${extension} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + bedtools: \$(bedtools --version | sed -e "s/bedtools v//g") + END_VERSIONS + """ } diff --git a/modules/nf-core/modules/bedtools/sort/meta.yml b/modules/nf-core/bedtools/sort/meta.yml old mode 100644 new mode 100755 similarity index 82% rename from modules/nf-core/modules/bedtools/sort/meta.yml rename to modules/nf-core/bedtools/sort/meta.yml index 369e51ff..3a3b4e4d --- a/modules/nf-core/modules/bedtools/sort/meta.yml +++ b/modules/nf-core/bedtools/sort/meta.yml @@ -3,6 +3,8 @@ description: Sorts a feature file by chromosome and other criteria. keywords: - bed - sort + - bedtools + - chromosome tools: - bedtools: description: | @@ -19,10 +21,11 @@ input: type: file description: BED/BEDGRAPH pattern: "*.{bed|bedGraph}" - - - extension: - type: string - description: Extension of the output file (e. g., ".bg", ".bedgraph", ".txt", ".tab", etc.) It is set arbitrarily by the user and corresponds to the file format which depends on arguments. + - genome_file: + type: file + description: | + Optional reference genome 2 column file that defines the expected chromosome order. + pattern: "*.{fai,txt,chromsizes}" output: - meta: type: map @@ -44,3 +47,4 @@ authors: - "@sruthipsuresh" - "@drpatelh" - "@chris-cheshire" + - "@adamrtalbot" diff --git a/modules/nf-core/busco/main.nf b/modules/nf-core/busco/main.nf new file mode 100755 index 00000000..b40014eb --- /dev/null +++ b/modules/nf-core/busco/main.nf @@ -0,0 +1,84 @@ +process BUSCO { + tag "$meta.id" + label 'process_medium' + + conda "bioconda::busco=5.4.3" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/busco:5.4.3--pyhdfd78af_0': + 'biocontainers/busco:5.4.3--pyhdfd78af_0' }" + + input: + tuple val(meta), path('tmp_input/*') + val lineage // Required: lineage to check against, "auto" enables --auto-lineage instead + path busco_lineages_path // Recommended: path to busco lineages - downloads if not set + path config_file // Optional: busco configuration file + + output: + tuple val(meta), path("*-busco.batch_summary.txt"), emit: batch_summary + tuple val(meta), path("short_summary.*.txt") , emit: short_summaries_txt, optional: true + tuple val(meta), path("short_summary.*.json") , emit: short_summaries_json, optional: true + tuple val(meta), path("*-busco") , emit: busco_dir + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}-${lineage}" + def busco_config = config_file ? "--config $config_file" : '' + def busco_lineage = lineage.equals('auto') ? '--auto-lineage' : "--lineage_dataset ${lineage}" + def busco_lineage_dir = busco_lineages_path ? "--offline --download_path ${busco_lineages_path}" : '' + """ + # Nextflow changes the container --entrypoint to /bin/bash (container default entrypoint: /usr/local/env-execute) + # Check for container variable initialisation script and source it. + if [ -f "/usr/local/env-activate.sh" ]; then + set +u # Otherwise, errors out because of various unbound variables + . "/usr/local/env-activate.sh" + set -u + fi + + # If the augustus config directory is not writable, then copy to writeable area + if [ ! -w "\${AUGUSTUS_CONFIG_PATH}" ]; then + # Create writable tmp directory for augustus + AUG_CONF_DIR=\$( mktemp -d -p \$PWD ) + cp -r \$AUGUSTUS_CONFIG_PATH/* \$AUG_CONF_DIR + export AUGUSTUS_CONFIG_PATH=\$AUG_CONF_DIR + echo "New AUGUSTUS_CONFIG_PATH=\${AUGUSTUS_CONFIG_PATH}" + fi + + # Ensure the input is uncompressed + INPUT_SEQS=input_seqs + mkdir "\$INPUT_SEQS" + cd "\$INPUT_SEQS" + for FASTA in ../tmp_input/*; do + if [ "\${FASTA##*.}" == 'gz' ]; then + gzip -cdf "\$FASTA" > \$( basename "\$FASTA" .gz ) + else + ln -s "\$FASTA" . + fi + done + cd .. + + busco \\ + --cpu $task.cpus \\ + --in "\$INPUT_SEQS" \\ + --out ${prefix}-busco \\ + $busco_lineage \\ + $busco_lineage_dir \\ + $busco_config \\ + $args + + # clean up + rm -rf "\$INPUT_SEQS" + + # Move files to avoid staging/publishing issues + mv ${prefix}-busco/batch_summary.txt ${prefix}-busco.batch_summary.txt + mv ${prefix}-busco/*/short_summary.*.{json,txt} . || echo "Short summaries were not available: No genes were found." + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + busco: \$( busco --version 2>&1 | sed 's/^BUSCO //' ) + END_VERSIONS + """ +} diff --git a/modules/nf-core/busco/meta.yml b/modules/nf-core/busco/meta.yml new file mode 100755 index 00000000..cdc9dd46 --- /dev/null +++ b/modules/nf-core/busco/meta.yml @@ -0,0 +1,69 @@ +name: busco +description: Benchmarking Universal Single Copy Orthologs +keywords: + - quality control + - genome + - transcriptome + - proteome +tools: + - busco: + description: BUSCO provides measures for quantitative assessment of genome assembly, gene set, and transcriptome completeness based on evolutionarily informed expectations of gene content from near-universal single-copy orthologs selected from OrthoDB. + homepage: https://busco.ezlab.org/ + documentation: https://busco.ezlab.org/busco_userguide.html + tool_dev_url: https://gitlab.com/ezlab/busco + doi: "10.1007/978-1-4939-9173-0_14" + licence: ["MIT"] + +input: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - fasta: + type: file + description: Nucleic or amino acid sequence file in FASTA format. + pattern: "*.{fasta,fna,fa,fasta.gz,fna.gz,fa.gz}" + - lineage: + type: string + description: The BUSCO lineage to use, or "auto" to automatically select lineage + - busco_lineages_path: + type: directory + description: Path to local BUSCO lineages directory. + - config_file: + type: file + description: Path to BUSCO config file. + +output: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - batch_summary: + type: file + description: Summary of all sequence files analyzed + pattern: "*-busco.batch_summary.txt" + - short_summaries_txt: + type: file + description: Short Busco summary in plain text format + pattern: "short_summary.*.txt" + - short_summaries_json: + type: file + description: Short Busco summary in JSON format + pattern: "short_summary.*.json" + - busco_dir: + type: directory + description: BUSCO lineage specific output + pattern: "*-busco" + - versions: + type: file + description: File containing software versions + pattern: "versions.yml" + +authors: + - "@priyanka-surana" + - "@charles-plessy" + - "@mahesh-panchal" + - "@muffato" + - "@jvhagey" diff --git a/modules/nf-core/bwamem2/index/main.nf b/modules/nf-core/bwamem2/index/main.nf new file mode 100755 index 00000000..30940852 --- /dev/null +++ b/modules/nf-core/bwamem2/index/main.nf @@ -0,0 +1,49 @@ +process BWAMEM2_INDEX { + tag "$fasta" + label 'process_single' + + conda "bioconda::bwa-mem2=2.2.1" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/bwa-mem2:2.2.1--he513fc3_0' : + 'biocontainers/bwa-mem2:2.2.1--he513fc3_0' }" + + input: + tuple val(meta), path(fasta) + + output: + tuple val(meta), path("bwamem2"), emit: index + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + """ + mkdir bwamem2 + bwa-mem2 \\ + index \\ + $args \\ + $fasta -p bwamem2/${fasta} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + bwamem2: \$(echo \$(bwa-mem2 version 2>&1) | sed 's/.* //') + END_VERSIONS + """ + + stub: + """ + mkdir bwamem2 + touch bwamem2/${fasta}.0123 + touch bwamem2/${fasta}.ann + touch bwamem2/${fasta}.pac + touch bwamem2/${fasta}.amb + touch bwamem2/${fasta}.bwt.2bit.64 + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + bwamem2: \$(echo \$(bwa-mem2 version 2>&1) | sed 's/.* //') + END_VERSIONS + """ +} diff --git a/modules/nf-core/bwamem2/index/meta.yml b/modules/nf-core/bwamem2/index/meta.yml new file mode 100755 index 00000000..40c26c38 --- /dev/null +++ b/modules/nf-core/bwamem2/index/meta.yml @@ -0,0 +1,40 @@ +name: bwamem2_index +description: Create BWA-mem2 index for reference genome +keywords: + - index + - fasta + - genome + - reference +tools: + - bwamem2: + description: | + BWA-mem2 is a software package for mapping DNA sequences against + a large reference genome, such as the human genome. + homepage: https://github.com/bwa-mem2/bwa-mem2 + documentation: https://github.com/bwa-mem2/bwa-mem2#usage + licence: ["MIT"] +input: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - fasta: + type: file + description: Input genome fasta file +output: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - index: + type: file + description: BWA genome index files + pattern: "*.{0123,amb,ann,bwt.2bit.64,pac}" + - versions: + type: file + description: File containing software versions + pattern: "versions.yml" +authors: + - "@maxulysse" diff --git a/modules/nf-core/cat/cat/main.nf b/modules/nf-core/cat/cat/main.nf new file mode 100755 index 00000000..9f062219 --- /dev/null +++ b/modules/nf-core/cat/cat/main.nf @@ -0,0 +1,62 @@ +process CAT_CAT { + tag "$meta.id" + label 'process_low' + + conda "conda-forge::pigz=2.3.4" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/pigz:2.3.4' : + 'biocontainers/pigz:2.3.4' }" + + input: + tuple val(meta), path(files_in) + + output: + tuple val(meta), path("${prefix}"), emit: file_out + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def args2 = task.ext.args2 ?: '' + def file_list = files_in.collect { it.toString() } + + // | input | output | command1 | command2 | + // |-----------|------------|----------|----------| + // | gzipped | gzipped | cat | | + // | ungzipped | ungzipped | cat | | + // | gzipped | ungzipped | zcat | | + // | ungzipped | gzipped | cat | pigz | + + // Use input file ending as default + prefix = task.ext.prefix ?: "${meta.id}${file_list[0].substring(file_list[0].lastIndexOf('.'))}" + out_zip = prefix.endsWith('.gz') + in_zip = file_list[0].endsWith('.gz') + command1 = (in_zip && !out_zip) ? 'zcat' : 'cat' + command2 = (!in_zip && out_zip) ? "| pigz -c -p $task.cpus $args2" : '' + """ + $command1 \\ + $args \\ + ${file_list.join(' ')} \\ + $command2 \\ + > ${prefix} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + pigz: \$( pigz --version 2>&1 | sed 's/pigz //g' ) + END_VERSIONS + """ + + stub: + def file_list = files_in.collect { it.toString() } + prefix = task.ext.prefix ?: "${meta.id}${file_list[0].substring(file_list[0].lastIndexOf('.'))}" + """ + touch $prefix + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + pigz: \$( pigz --version 2>&1 | sed 's/pigz //g' ) + END_VERSIONS + """ +} diff --git a/modules/nf-core/cat/cat/meta.yml b/modules/nf-core/cat/cat/meta.yml new file mode 100755 index 00000000..8acc0bfa --- /dev/null +++ b/modules/nf-core/cat/cat/meta.yml @@ -0,0 +1,37 @@ +name: cat_cat +description: A module for concatenation of gzipped or uncompressed files +keywords: + - concatenate + - gzip + - cat +tools: + - cat: + description: Just concatenation + + documentation: https://man7.org/linux/man-pages/man1/cat.1.html + + licence: ["GPL-3.0-or-later"] +input: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - files_in: + type: file + description: List of compressed / uncompressed files + pattern: "*" + +output: + - versions: + type: file + description: File containing software versions + pattern: "versions.yml" + - file_out: + type: file + description: Concatenated file. Will be gzipped if file_out ends with ".gz" + pattern: "${file_out}" + +authors: + - "@erikrikarddaniel" + - "@FriederikeHanssen" diff --git a/modules/nf-core/cooler/cload/main.nf b/modules/nf-core/cooler/cload/main.nf new file mode 100755 index 00000000..4863cc63 --- /dev/null +++ b/modules/nf-core/cooler/cload/main.nf @@ -0,0 +1,50 @@ +process COOLER_CLOAD { + tag "$meta.id" + label 'process_high' + + conda "bioconda::cooler=0.9.2" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/cooler:0.9.2--pyh7cba7a3_0' : + 'biocontainers/cooler:0.9.2--pyh7cba7a3_0' }" + + input: + tuple val(meta), path(pairs), path(index), val(cool_bin) + path chromsizes + + output: + tuple val(meta), path("*.cool"), val(cool_bin), emit: cool + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + def nproc = args.contains('pairix') || args.contains('tabix')? "--nproc $task.cpus" : '' + + """ + cooler cload \\ + $args \\ + $nproc \\ + ${chromsizes}:${cool_bin} \\ + $pairs \\ + ${prefix}.cool + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + cooler: \$(cooler --version 2>&1 | sed 's/cooler, version //') + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + """ + touch ${prefix}.cool + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + cooler: \$(cooler --version 2>&1 | sed 's/cooler, version //') + END_VERSIONS + """ +} diff --git a/modules/nf-core/cooler/cload/meta.yml b/modules/nf-core/cooler/cload/meta.yml new file mode 100755 index 00000000..953c8337 --- /dev/null +++ b/modules/nf-core/cooler/cload/meta.yml @@ -0,0 +1,56 @@ +name: cooler_cload +description: Create a cooler from genomic pairs and bins +keywords: + - cool + - cooler + - cload + - hic +tools: + - cooler: + description: Sparse binary format for genomic interaction matrices + homepage: https://open2c.github.io/cooler/ + documentation: https://cooler.readthedocs.io/en/latest/index.html + tool_dev_url: https://github.com/open2c/cooler + doi: "10.1093/bioinformatics/btz540" + licence: ["BSD-3-clause"] + +input: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - pairs: + type: file + description: Path to contacts (i.e. read pairs) file. + - index: + type: file + description: Path to index file of the contacts. + - cool_bin: + type: integer + description: Bins size in bp + - chromsizes: + type: file + description: Path to a chromsizes file. + +output: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - version: + type: file + description: File containing software version + pattern: "versions.yml" + - cool: + type: file + description: Output COOL file path + pattern: "*.cool" + - cool_bin: + type: integer + description: Bins size in bp + +authors: + - "@jianhong" + - "@muffato" diff --git a/modules/nf-core/cooler/zoomify/main.nf b/modules/nf-core/cooler/zoomify/main.nf new file mode 100755 index 00000000..cd210cf7 --- /dev/null +++ b/modules/nf-core/cooler/zoomify/main.nf @@ -0,0 +1,46 @@ +process COOLER_ZOOMIFY { + tag "$meta.id" + label 'process_high' + + conda "bioconda::cooler=0.9.2" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/cooler:0.9.2--pyh7cba7a3_0' : + 'biocontainers/cooler:0.9.2--pyh7cba7a3_0' }" + + input: + tuple val(meta), path(cool) + + output: + tuple val(meta), path("*.mcool"), emit: mcool + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + """ + cooler zoomify \\ + $args \\ + -n $task.cpus \\ + -o ${prefix}.mcool \\ + $cool + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + cooler: \$(cooler --version 2>&1 | sed 's/cooler, version //') + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + """ + touch ${prefix}.mcool + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + cooler: \$(cooler --version 2>&1 | sed 's/cooler, version //') + END_VERSIONS + """ +} diff --git a/modules/nf-core/cooler/zoomify/meta.yml b/modules/nf-core/cooler/zoomify/meta.yml new file mode 100755 index 00000000..27dfe46a --- /dev/null +++ b/modules/nf-core/cooler/zoomify/meta.yml @@ -0,0 +1,43 @@ +name: cooler_zoomify +description: Generate a multi-resolution cooler file by coarsening +keywords: + - mcool + - cool + - cooler +tools: + - cooler: + description: Sparse binary format for genomic interaction matrices + homepage: https://open2c.github.io/cooler/ + documentation: https://cooler.readthedocs.io/en/latest/index.html + tool_dev_url: https://github.com/open2c/cooler + doi: "10.1093/bioinformatics/btz540" + licence: ["BSD-3-clause"] + +input: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - cool: + type: file + description: Path to COOL file + pattern: "*.{cool,mcool}" + +output: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - versions: + type: file + description: File containing software versions + pattern: "versions.yml" + - mcool: + type: file + description: Output mcool file + pattern: "*.mcool" + +authors: + - "@jianhong" diff --git a/modules/nf-core/modules/custom/dumpsoftwareversions/main.nf b/modules/nf-core/custom/dumpsoftwareversions/main.nf old mode 100644 new mode 100755 similarity index 81% rename from modules/nf-core/modules/custom/dumpsoftwareversions/main.nf rename to modules/nf-core/custom/dumpsoftwareversions/main.nf index 34b50b9f..ebc87273 --- a/modules/nf-core/modules/custom/dumpsoftwareversions/main.nf +++ b/modules/nf-core/custom/dumpsoftwareversions/main.nf @@ -2,10 +2,10 @@ process CUSTOM_DUMPSOFTWAREVERSIONS { label 'process_single' // Requires `pyyaml` which does not have a dedicated container but is in the MultiQC container - conda (params.enable_conda ? 'bioconda::multiqc=1.13a' : null) + conda "bioconda::multiqc=1.14" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/multiqc:1.13a--pyhdfd78af_1' : - 'quay.io/biocontainers/multiqc:1.13a--pyhdfd78af_1' }" + 'https://depot.galaxyproject.org/singularity/multiqc:1.14--pyhdfd78af_0' : + 'biocontainers/multiqc:1.14--pyhdfd78af_0' }" input: path versions diff --git a/modules/nf-core/modules/custom/dumpsoftwareversions/meta.yml b/modules/nf-core/custom/dumpsoftwareversions/meta.yml old mode 100644 new mode 100755 similarity index 88% rename from modules/nf-core/modules/custom/dumpsoftwareversions/meta.yml rename to modules/nf-core/custom/dumpsoftwareversions/meta.yml index 60b546a0..c32657de --- a/modules/nf-core/modules/custom/dumpsoftwareversions/meta.yml +++ b/modules/nf-core/custom/dumpsoftwareversions/meta.yml @@ -1,7 +1,9 @@ +# yaml-language-server: $schema=https://raw.githubusercontent.com/nf-core/modules/master/modules/yaml-schema.json name: custom_dumpsoftwareversions description: Custom module used to dump software versions within the nf-core pipeline template keywords: - custom + - dump - version tools: - custom: diff --git a/modules/nf-core/custom/dumpsoftwareversions/templates/dumpsoftwareversions.py b/modules/nf-core/custom/dumpsoftwareversions/templates/dumpsoftwareversions.py new file mode 100755 index 00000000..da033408 --- /dev/null +++ b/modules/nf-core/custom/dumpsoftwareversions/templates/dumpsoftwareversions.py @@ -0,0 +1,101 @@ +#!/usr/bin/env python + + +"""Provide functions to merge multiple versions.yml files.""" + + +import yaml +import platform +from textwrap import dedent + + +def _make_versions_html(versions): + """Generate a tabular HTML output of all versions for MultiQC.""" + html = [ + dedent( + """\\ + + + + + + + + + + """ + ) + ] + for process, tmp_versions in sorted(versions.items()): + html.append("") + for i, (tool, version) in enumerate(sorted(tmp_versions.items())): + html.append( + dedent( + f"""\\ + + + + + + """ + ) + ) + html.append("") + html.append("
    Process Name Software Version
    {process if (i == 0) else ''}{tool}{version}
    ") + return "\\n".join(html) + + +def main(): + """Load all version files and generate merged output.""" + versions_this_module = {} + versions_this_module["${task.process}"] = { + "python": platform.python_version(), + "yaml": yaml.__version__, + } + + with open("$versions") as f: + versions_by_process = yaml.load(f, Loader=yaml.BaseLoader) | versions_this_module + + # aggregate versions by the module name (derived from fully-qualified process name) + versions_by_module = {} + for process, process_versions in versions_by_process.items(): + module = process.split(":")[-1] + try: + if versions_by_module[module] != process_versions: + raise AssertionError( + "We assume that software versions are the same between all modules. " + "If you see this error-message it means you discovered an edge-case " + "and should open an issue in nf-core/tools. " + ) + except KeyError: + versions_by_module[module] = process_versions + + versions_by_module["Workflow"] = { + "Nextflow": "$workflow.nextflow.version", + "$workflow.manifest.name": "$workflow.manifest.version", + } + + versions_mqc = { + "id": "software_versions", + "section_name": "${workflow.manifest.name} Software Versions", + "section_href": "https://github.com/${workflow.manifest.name}", + "plot_type": "html", + "description": "are collected at run time from the software output.", + "data": _make_versions_html(versions_by_module), + } + + with open("software_versions.yml", "w") as f: + yaml.dump(versions_by_module, f, default_flow_style=False) + with open("software_versions_mqc.yml", "w") as f: + yaml.dump(versions_mqc, f, default_flow_style=False) + + with open("versions.yml", "w") as f: + yaml.dump(versions_this_module, f, default_flow_style=False) + + +if __name__ == "__main__": + main() diff --git a/modules/nf-core/custom/getchromsizes/custom-getchromsizes.diff b/modules/nf-core/custom/getchromsizes/custom-getchromsizes.diff new file mode 100644 index 00000000..6d72652e --- /dev/null +++ b/modules/nf-core/custom/getchromsizes/custom-getchromsizes.diff @@ -0,0 +1,63 @@ +Changes in module 'nf-core/custom/getchromsizes' +--- modules/nf-core/custom/getchromsizes/main.nf ++++ modules/nf-core/custom/getchromsizes/main.nf +@@ -1,5 +1,9 @@ ++// Forked from the nf-core module to: ++// 1. allow selecting a different extension for the `sizes` channel ++// 2. force all output files to be named according to the prefix ++// 3. rename the input fasta file too and output it so that it can be "published" + process CUSTOM_GETCHROMSIZES { +- tag "$fasta" ++ tag "$meta.id" + label 'process_single' + + conda "bioconda::samtools=1.16.1" +@@ -8,22 +12,26 @@ + 'biocontainers/samtools:1.16.1--h6899075_1' }" + + input: +- tuple val(meta), path(fasta) ++ tuple val(meta), path(fasta, stageAs: 'input/*') ++ val suffix + + output: +- tuple val(meta), path ("*.sizes"), emit: sizes +- tuple val(meta), path ("*.fai") , emit: fai +- tuple val(meta), path ("*.gzi") , emit: gzi, optional: true +- path "versions.yml" , emit: versions ++ tuple val(meta), path ("*.${suffix}") , emit: sizes ++ tuple val(meta), path ("*.fa") , emit: fasta ++ tuple val(meta), path ("*.fai") , emit: fai ++ tuple val(meta), path ("*.gzi") , emit: gzi, optional: true ++ path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: +- def args = task.ext.args ?: '' ++ def args = task.ext.args ?: '' ++ def prefix = task.ext.prefix ?: "${meta.id}" + """ +- samtools faidx $fasta +- cut -f 1,2 ${fasta}.fai > ${fasta}.sizes ++ ln -s ${fasta} ${prefix}.fa ++ samtools faidx ${prefix}.fa -o ${prefix}.fa.fai ++ cut -f 1,2 ${prefix}.fa.fai > ${prefix}.${suffix} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": +@@ -33,8 +41,9 @@ + + stub: + """ +- touch ${fasta}.fai +- touch ${fasta}.sizes ++ ln -s ${fasta} ${prefix}.fa ++ touch ${prefix}.fa.fai ++ touch ${prefix}.${suffix} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + +************************************************************ diff --git a/modules/nf-core/custom/getchromsizes/main.nf b/modules/nf-core/custom/getchromsizes/main.nf new file mode 100644 index 00000000..b6387e00 --- /dev/null +++ b/modules/nf-core/custom/getchromsizes/main.nf @@ -0,0 +1,53 @@ +// Forked from the nf-core module to: +// 1. allow selecting a different extension for the `sizes` channel +// 2. force all output files to be named according to the prefix +// 3. rename the input fasta file too and output it so that it can be "published" +process CUSTOM_GETCHROMSIZES { + tag "$meta.id" + label 'process_single' + + conda "bioconda::samtools=1.16.1" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/samtools:1.16.1--h6899075_1' : + 'biocontainers/samtools:1.16.1--h6899075_1' }" + + input: + tuple val(meta), path(fasta, stageAs: 'input/*') + val suffix + + output: + tuple val(meta), path ("*.${suffix}") , emit: sizes + tuple val(meta), path ("*.fa") , emit: fasta + tuple val(meta), path ("*.fai") , emit: fai + tuple val(meta), path ("*.gzi") , emit: gzi, optional: true + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + """ + ln -s ${fasta} ${prefix}.fa + samtools faidx ${prefix}.fa -o ${prefix}.fa.fai + cut -f 1,2 ${prefix}.fa.fai > ${prefix}.${suffix} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + getchromsizes: \$(echo \$(samtools --version 2>&1) | sed 's/^.*samtools //; s/Using.*\$//') + END_VERSIONS + """ + + stub: + """ + ln -s ${fasta} ${prefix}.fa + touch ${prefix}.fa.fai + touch ${prefix}.${suffix} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + getchromsizes: \$(echo \$(samtools --version 2>&1) | sed 's/^.*samtools //; s/Using.*\$//') + END_VERSIONS + """ +} diff --git a/modules/nf-core/custom/getchromsizes/meta.yml b/modules/nf-core/custom/getchromsizes/meta.yml new file mode 100644 index 00000000..219ca1d8 --- /dev/null +++ b/modules/nf-core/custom/getchromsizes/meta.yml @@ -0,0 +1,53 @@ +name: custom_getchromsizes +description: Generates a FASTA file of chromosome sizes and a fasta index file +keywords: + - fasta + - chromosome + - indexing +tools: + - samtools: + description: Tools for dealing with SAM, BAM and CRAM files + homepage: http://www.htslib.org/ + documentation: http://www.htslib.org/doc/samtools.html + tool_dev_url: https://github.com/samtools/samtools + doi: 10.1093/bioinformatics/btp352 + licence: ["MIT"] + +input: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - fasta: + type: file + description: FASTA file + pattern: "*.{fa,fasta,fna,fas}" + +output: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - sizes: + type: file + description: File containing chromosome lengths + pattern: "*.{sizes}" + - fai: + type: file + description: FASTA index file + pattern: "*.{fai}" + - gzi: + type: file + description: Optional gzip index file for compressed inputs + pattern: "*.gzi" + - versions: + type: file + description: File containing software versions + pattern: "versions.yml" + +authors: + - "@tamara-hodgetts" + - "@chris-cheshire" + - "@muffato" diff --git a/modules/nf-core/gnu/sort/main.nf b/modules/nf-core/gnu/sort/main.nf new file mode 100755 index 00000000..b0a57fbb --- /dev/null +++ b/modules/nf-core/gnu/sort/main.nf @@ -0,0 +1,52 @@ +process GNU_SORT { + tag "${meta.id}" + label "process_low" + + conda "bioconda::coreutils=8.25" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/coreutils:8.25--1' : + 'biocontainers/coreutils:8.25--1' }" + + input: + tuple val(meta), path(input) + + output: + tuple val(meta), file( "${output_file}" ) , emit: sorted + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + suffix = task.ext.suffix ?: "${input.extension}" + output_file = "${prefix}.${suffix}" + def VERSION = "9.1" // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + if ("$input" == "$output_file") error "Input and output names are the same, use \"task.ext.prefix\" to disambiguate!" + """ + sort ${args} ${input} > ${output_file} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + coreutils: $VERSION + END_VERSIONS + """ + + stub: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + suffix = task.ext.suffix ?: "${input.extension}" + output_file = "${prefix}.${suffix}" + def VERSION = "9.1" + + if ("$input" == "$output_file") error "Input and output names are the same, use \"task.ext.prefix\" to disambiguate!" + """ + sort ${args} ${input} > ${output_file} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + coreutils: $VERSION + END_VERSIONS + """ +} diff --git a/modules/nf-core/gnu/sort/meta.yml b/modules/nf-core/gnu/sort/meta.yml new file mode 100755 index 00000000..e7fb0284 --- /dev/null +++ b/modules/nf-core/gnu/sort/meta.yml @@ -0,0 +1,42 @@ +name: "GNU_SORT" +description: | + Writes a sorted concatenation of file/s +keywords: + - GNU + - sort + - merge compare +tools: + - sort: + description: "Writes a sorted concatenation of file/s" + homepage: "https://github.com/vgl-hub/gfastats" + documentation: "https://www.gnu.org/software/coreutils/manual/html_node/sort-invocation.html" + licence: ["GPL"] + +input: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - input: + type: file + description: Draft assembly file + pattern: "*.{txt,bed,interval,genome,bins}" + +output: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - sorted: + type: file + description: The sorted txt file generated by sort + pattern: "*.{txt,bed,interval,genome,bins}" + - versions: + type: file + description: File containing software versions + pattern: "versions.yml" + +authors: + - "@DLBPointon" diff --git a/modules/nf-core/modules/minimap2/align/main.nf b/modules/nf-core/minimap2/align/main.nf old mode 100644 new mode 100755 similarity index 75% rename from modules/nf-core/modules/minimap2/align/main.nf rename to modules/nf-core/minimap2/align/main.nf index 3016f931..4da47c18 --- a/modules/nf-core/modules/minimap2/align/main.nf +++ b/modules/nf-core/minimap2/align/main.nf @@ -2,10 +2,11 @@ process MINIMAP2_ALIGN { tag "$meta.id" label 'process_medium' - conda (params.enable_conda ? 'bioconda::minimap2=2.21 bioconda::samtools=1.12' : null) + // Note: the versions here need to match the versions used in the mulled container below and minimap2/index + conda "bioconda::minimap2=2.24 bioconda::samtools=1.14" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? 'https://depot.galaxyproject.org/singularity/mulled-v2-66534bcbb7031a148b13e2ad42583020b9cd25c4:1679e915ddb9d6b4abda91880c4b48857d471bd8-0' : - 'quay.io/biocontainers/mulled-v2-66534bcbb7031a148b13e2ad42583020b9cd25c4:1679e915ddb9d6b4abda91880c4b48857d471bd8-0' }" + 'biocontainers/mulled-v2-66534bcbb7031a148b13e2ad42583020b9cd25c4:1679e915ddb9d6b4abda91880c4b48857d471bd8-0' }" input: tuple val(meta), path(reads) @@ -13,7 +14,6 @@ process MINIMAP2_ALIGN { val bam_format val cigar_paf_format val cigar_bam - val intron output: tuple val(meta), path("*.paf"), optional: true, emit: paf @@ -26,18 +26,15 @@ process MINIMAP2_ALIGN { script: def args = task.ext.args ?: '' def prefix = task.ext.prefix ?: "${meta.id}" - def input_reads = meta.single_end ? "$reads" : "${reads[0]} ${reads[1]}" def bam_output = bam_format ? "-a | samtools sort | samtools view -@ ${task.cpus} -b -h -o ${prefix}.bam" : "-o ${prefix}.paf" def cigar_paf = cigar_paf_format && !bam_format ? "-c" : '' def set_cigar_bam = cigar_bam && bam_format ? "-L" : '' - def intron_size = intron ? "-G ${intron}" : "" """ minimap2 \\ $args \\ - $intron_size \\ -t $task.cpus \\ - $reference \\ - $input_reads \\ + "${reference ?: reads}" \\ + "$reads" \\ $cigar_paf \\ $set_cigar_bam \\ $bam_output diff --git a/modules/nf-core/modules/minimap2/align/meta.yml b/modules/nf-core/minimap2/align/meta.yml old mode 100644 new mode 100755 similarity index 100% rename from modules/nf-core/modules/minimap2/align/meta.yml rename to modules/nf-core/minimap2/align/meta.yml diff --git a/modules/nf-core/minimap2/index/main.nf b/modules/nf-core/minimap2/index/main.nf new file mode 100755 index 00000000..7a1bb227 --- /dev/null +++ b/modules/nf-core/minimap2/index/main.nf @@ -0,0 +1,34 @@ +process MINIMAP2_INDEX { + label 'process_medium' + + // Note: the versions here need to match the versions used in minimap2/align + conda "bioconda::minimap2=2.24" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/minimap2:2.24--h7132678_1' : + 'biocontainers/minimap2:2.24--h7132678_1' }" + + input: + tuple val(meta), path(fasta) + + output: + tuple val(meta), path("*.mmi"), emit: index + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + """ + minimap2 \\ + -t $task.cpus \\ + -d ${fasta.baseName}.mmi \\ + $args \\ + $fasta + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + minimap2: \$(minimap2 --version 2>&1) + END_VERSIONS + """ +} diff --git a/modules/nf-core/minimap2/index/meta.yml b/modules/nf-core/minimap2/index/meta.yml new file mode 100755 index 00000000..b58f35c6 --- /dev/null +++ b/modules/nf-core/minimap2/index/meta.yml @@ -0,0 +1,40 @@ +name: minimap2_index +description: Provides fasta index required by minimap2 alignment. +keywords: + - index + - fasta + - reference +tools: + - minimap2: + description: | + A versatile pairwise aligner for genomic and spliced nucleotide sequences. + homepage: https://github.com/lh3/minimap2 + documentation: https://github.com/lh3/minimap2#uguide + licence: ["MIT"] +input: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - fasta: + type: file + description: | + Reference database in FASTA format. +output: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - index: + type: file + description: Minimap2 fasta index. + pattern: "*.mmi" + - versions: + type: file + description: File containing software versions + pattern: "versions.yml" +authors: + - "@yuukiiwa" + - "@drpatelh" diff --git a/modules/sanger-tol/nf-core-modules/miniprot/align/main.nf b/modules/nf-core/miniprot/align/main.nf old mode 100644 new mode 100755 similarity index 53% rename from modules/sanger-tol/nf-core-modules/miniprot/align/main.nf rename to modules/nf-core/miniprot/align/main.nf index 43300ecc..9a1f1184 --- a/modules/sanger-tol/nf-core-modules/miniprot/align/main.nf +++ b/modules/nf-core/miniprot/align/main.nf @@ -1,19 +1,15 @@ - process MINIPROT_ALIGN { - tag "$meta.id" label 'process_medium' - def version = '0.5-c2' - if (params.enable_conda) { - exit 1, "Conda environments cannot be used when using the miniprot process. Please use docker or singularity containers." - } - container "quay.io/sanger-tol/miniprot:${version}" + conda "bioconda::miniprot=0.11=he4a0461_2" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/miniprot:0.11--he4a0461_2': + 'biocontainers/miniprot:0.11--he4a0461_2' }" input: tuple val(meta), path(pep) - path ref - + tuple val(meta2), path(ref) output: tuple val(meta), path("*.paf"), optional: true, emit: paf @@ -37,8 +33,19 @@ process MINIPROT_ALIGN { cat <<-END_VERSIONS > versions.yml "${task.process}": - miniprot: $version + miniprot: \$(miniprot --version 2>&1) END_VERSIONS """ -} + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + def extension = args.contains("--gff") ? "gff" : "paf" + """ + touch ${prefix}.${extension} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + miniprot: \$(miniprot --version 2>&1) + END_VERSIONS + """ +} diff --git a/modules/sanger-tol/nf-core-modules/miniprot/align/meta.yml b/modules/nf-core/miniprot/align/meta.yml old mode 100644 new mode 100755 similarity index 91% rename from modules/sanger-tol/nf-core-modules/miniprot/align/meta.yml rename to modules/nf-core/miniprot/align/meta.yml index ef7f7e53..503579e5 --- a/modules/sanger-tol/nf-core-modules/miniprot/align/meta.yml +++ b/modules/nf-core/miniprot/align/meta.yml @@ -23,6 +23,10 @@ input: - pep: type: file description: a fasta file contains one or multiple protein sequences + - meta2: + type: map + description: | + Groovy Map containing reference information - ref: type: file description: Reference database in FASTA format or miniprot index format. @@ -46,3 +50,4 @@ output: pattern: "versions.yml" authors: - "@yumisims" + - "@muffato" diff --git a/modules/sanger-tol/nf-core-modules/miniprot/index/main.nf b/modules/nf-core/miniprot/index/main.nf old mode 100644 new mode 100755 similarity index 50% rename from modules/sanger-tol/nf-core-modules/miniprot/index/main.nf rename to modules/nf-core/miniprot/index/main.nf index 1e6437bf..ee3757b6 --- a/modules/sanger-tol/nf-core-modules/miniprot/index/main.nf +++ b/modules/nf-core/miniprot/index/main.nf @@ -1,11 +1,11 @@ process MINIPROT_INDEX { tag "$meta.id" label 'process_medium' - def version = '0.5-c2' - if (params.enable_conda) { - exit 1, "Conda environments cannot be used when using the miniprot process. Please use docker or singularity containers." - } - container "quay.io/sanger-tol/miniprot:${version}" + + conda "bioconda::miniprot=0.11=he4a0461_2" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/miniprot:0.11--he4a0461_2': + 'biocontainers/miniprot:0.11--he4a0461_2' }" input: tuple val(meta), path(fasta) @@ -19,7 +19,6 @@ process MINIPROT_INDEX { script: def args = task.ext.args ?: '' - """ miniprot \\ -t $task.cpus \\ @@ -29,7 +28,17 @@ process MINIPROT_INDEX { cat <<-END_VERSIONS > versions.yml "${task.process}": - miniprot: $version + miniprot: \$(miniprot --version 2>&1) + END_VERSIONS + """ + + stub: + """ + touch ${fasta.baseName}.mpi + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + miniprot: \$(miniprot --version 2>&1) END_VERSIONS """ } diff --git a/modules/sanger-tol/nf-core-modules/miniprot/index/meta.yml b/modules/nf-core/miniprot/index/meta.yml old mode 100644 new mode 100755 similarity index 97% rename from modules/sanger-tol/nf-core-modules/miniprot/index/meta.yml rename to modules/nf-core/miniprot/index/meta.yml index 9329aa3f..3a098802 --- a/modules/sanger-tol/nf-core-modules/miniprot/index/meta.yml +++ b/modules/nf-core/miniprot/index/meta.yml @@ -3,6 +3,7 @@ description: Provides fasta index required by miniprot alignment. keywords: - index - fasta + - genome - reference tools: - miniprot: @@ -37,3 +38,4 @@ output: pattern: "versions.yml" authors: - "@yumisims" + - "@muffato" diff --git a/modules/nf-core/modules/bedtools/sort/main.nf b/modules/nf-core/modules/bedtools/sort/main.nf deleted file mode 100644 index 17b224d5..00000000 --- a/modules/nf-core/modules/bedtools/sort/main.nf +++ /dev/null @@ -1,36 +0,0 @@ -process BEDTOOLS_SORT { - tag "$meta.id" - label 'process_single' - - conda (params.enable_conda ? "bioconda::bedtools=2.30.0" : null) - container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/bedtools:2.30.0--hc088bd4_0' : - 'quay.io/biocontainers/bedtools:2.30.0--hc088bd4_0' }" - - input: - tuple val(meta), path(intervals) - val extension - - output: - tuple val(meta), path("*.${extension}"), emit: sorted - path "versions.yml" , emit: versions - - when: - task.ext.when == null || task.ext.when - - script: - def args = task.ext.args ?: '' - def prefix = task.ext.prefix ?: "${meta.id}" - """ - bedtools \\ - sort \\ - -i $intervals \\ - $args \\ - > ${prefix}.${extension} - - cat <<-END_VERSIONS > versions.yml - "${task.process}": - bedtools: \$(bedtools --version | sed -e "s/bedtools v//g") - END_VERSIONS - """ -} diff --git a/modules/nf-core/modules/blast/blastn/main.nf b/modules/nf-core/modules/blast/blastn/main.nf deleted file mode 100644 index b85f6c8e..00000000 --- a/modules/nf-core/modules/blast/blastn/main.nf +++ /dev/null @@ -1,37 +0,0 @@ -process BLAST_BLASTN { - tag "$meta.id" - label 'process_medium' - - conda (params.enable_conda ? 'bioconda::blast=2.12.0' : null) - container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/blast:2.12.0--pl5262h3289130_0' : - 'quay.io/biocontainers/blast:2.12.0--pl5262h3289130_0' }" - - input: - tuple val(meta), path(fasta) - path db - - output: - tuple val(meta), path('*.blastn.txt'), emit: txt - path "versions.yml" , emit: versions - - when: - task.ext.when == null || task.ext.when - - script: - def args = task.ext.args ?: '' - def prefix = task.ext.prefix ?: "${meta.id}" - """ - DB=`find -L ./ -name "*.ndb" | sed 's/.ndb//'` - blastn \\ - -num_threads $task.cpus \\ - -db \$DB \\ - -query $fasta \\ - $args \\ - -out ${prefix}.blastn.txt - cat <<-END_VERSIONS > versions.yml - "${task.process}": - blast: \$(blastn -version 2>&1 | sed 's/^.*blastn: //; s/ .*\$//') - END_VERSIONS - """ -} diff --git a/modules/nf-core/modules/blast/blastn/meta.yml b/modules/nf-core/modules/blast/blastn/meta.yml deleted file mode 100644 index 2742278d..00000000 --- a/modules/nf-core/modules/blast/blastn/meta.yml +++ /dev/null @@ -1,41 +0,0 @@ -name: blast_blastn -description: Queries a BLAST DNA database -keywords: - - fasta - - blast - - blastn - - DNA sequence -tools: - - blast: - description: | - BLAST finds regions of similarity between biological sequences. - homepage: https://blast.ncbi.nlm.nih.gov/Blast.cgi - documentation: https://blast.ncbi.nlm.nih.gov/Blast.cgi?CMD=Web&PAGE_TYPE=Blastdocs - doi: 10.1016/S0022-2836(05)80360-2 - licence: ["US-Government-Work"] -input: - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - fasta: - type: file - description: Input fasta file containing queries sequences - pattern: "*.{fa,fasta}" - - db: - type: directory - description: Directory containing blast database - pattern: "*" -output: - - txt: - type: file - description: File containing blastn hits - pattern: "*.{blastn.txt}" - - versions: - type: file - description: File containing software versions - pattern: "versions.yml" -authors: - - "@joseespinosa" - - "@drpatelh" diff --git a/modules/nf-core/modules/blast/makeblastdb/main.nf b/modules/nf-core/modules/blast/makeblastdb/main.nf deleted file mode 100644 index 12208ea8..00000000 --- a/modules/nf-core/modules/blast/makeblastdb/main.nf +++ /dev/null @@ -1,33 +0,0 @@ -process BLAST_MAKEBLASTDB { - tag "$fasta" - label 'process_medium' - - conda (params.enable_conda ? 'bioconda::blast=2.12.0' : null) - container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/blast:2.12.0--pl5262h3289130_0' : - 'quay.io/biocontainers/blast:2.12.0--pl5262h3289130_0' }" - - input: - path fasta - - output: - path 'blast_db' , emit: db - path "versions.yml" , emit: versions - - when: - task.ext.when == null || task.ext.when - - script: - def args = task.ext.args ?: '' - """ - makeblastdb \\ - -in $fasta \\ - $args - mkdir blast_db - mv ${fasta}* blast_db - cat <<-END_VERSIONS > versions.yml - "${task.process}": - blast: \$(blastn -version 2>&1 | sed 's/^.*blastn: //; s/ .*\$//') - END_VERSIONS - """ -} diff --git a/modules/nf-core/modules/blast/makeblastdb/meta.yml b/modules/nf-core/modules/blast/makeblastdb/meta.yml deleted file mode 100644 index 83c4b292..00000000 --- a/modules/nf-core/modules/blast/makeblastdb/meta.yml +++ /dev/null @@ -1,31 +0,0 @@ -name: blast_makeblastdb -description: Builds a BLAST database -keywords: - - fasta - - blast - - database -tools: - - blast: - description: | - BLAST finds regions of similarity between biological sequences. - homepage: https://blast.ncbi.nlm.nih.gov/Blast.cgi - documentation: https://blast.ncbi.nlm.nih.gov/Blast.cgi?CMD=Web&PAGE_TYPE=Blastdocs - doi: 10.1016/S0022-2836(05)80360-2 - licence: ["US-Government-Work"] -input: - - fasta: - type: file - description: Input fasta file - pattern: "*.{fa,fasta}" -output: - - db: - type: directory - description: Output directory containing blast database files - pattern: "*" - - versions: - type: file - description: File containing software versions - pattern: "versions.yml" -authors: - - "@joseespinosa" - - "@drpatelh" diff --git a/modules/nf-core/modules/custom/dumpsoftwareversions/templates/dumpsoftwareversions.py b/modules/nf-core/modules/custom/dumpsoftwareversions/templates/dumpsoftwareversions.py deleted file mode 100644 index d1390392..00000000 --- a/modules/nf-core/modules/custom/dumpsoftwareversions/templates/dumpsoftwareversions.py +++ /dev/null @@ -1,89 +0,0 @@ -#!/usr/bin/env python - -import yaml -import platform -from textwrap import dedent - - -def _make_versions_html(versions): - html = [ - dedent( - """\\ - - - - - - - - - - """ - ) - ] - for process, tmp_versions in sorted(versions.items()): - html.append("") - for i, (tool, version) in enumerate(sorted(tmp_versions.items())): - html.append( - dedent( - f"""\\ - - - - - - """ - ) - ) - html.append("") - html.append("
    Process Name Software Version
    {process if (i == 0) else ''}{tool}{version}
    ") - return "\\n".join(html) - - -versions_this_module = {} -versions_this_module["${task.process}"] = { - "python": platform.python_version(), - "yaml": yaml.__version__, -} - -with open("$versions") as f: - versions_by_process = yaml.load(f, Loader=yaml.BaseLoader) | versions_this_module - -# aggregate versions by the module name (derived from fully-qualified process name) -versions_by_module = {} -for process, process_versions in versions_by_process.items(): - module = process.split(":")[-1] - try: - assert versions_by_module[module] == process_versions, ( - "We assume that software versions are the same between all modules. " - "If you see this error-message it means you discovered an edge-case " - "and should open an issue in nf-core/tools. " - ) - except KeyError: - versions_by_module[module] = process_versions - -versions_by_module["Workflow"] = { - "Nextflow": "$workflow.nextflow.version", - "$workflow.manifest.name": "$workflow.manifest.version", -} - -versions_mqc = { - "id": "software_versions", - "section_name": "${workflow.manifest.name} Software Versions", - "section_href": "https://github.com/${workflow.manifest.name}", - "plot_type": "html", - "description": "are collected at run time from the software output.", - "data": _make_versions_html(versions_by_module), -} - -with open("software_versions.yml", "w") as f: - yaml.dump(versions_by_module, f, default_flow_style=False) -with open("software_versions_mqc.yml", "w") as f: - yaml.dump(versions_mqc, f, default_flow_style=False) - -with open("versions.yml", "w") as f: - yaml.dump(versions_this_module, f, default_flow_style=False) diff --git a/modules/nf-core/modules/mummer/main.nf b/modules/nf-core/mummer/main.nf old mode 100644 new mode 100755 similarity index 78% rename from modules/nf-core/modules/mummer/main.nf rename to modules/nf-core/mummer/main.nf index 746abbb1..16387d1d --- a/modules/nf-core/modules/mummer/main.nf +++ b/modules/nf-core/mummer/main.nf @@ -3,10 +3,10 @@ process MUMMER { label 'process_low' // WARN: Version information not provided by tool on CLI. Please update version string below when bumping container versions. - conda (params.enable_conda ? "bioconda::mummer=3.23" : null) + conda "bioconda::mummer=3.23" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? 'https://depot.galaxyproject.org/singularity/mummer:3.23--pl5262h1b792b2_12' : - 'quay.io/biocontainers/mummer:3.23--pl5262h1b792b2_12' }" + 'biocontainers/mummer:3.23--pl5262h1b792b2_12' }" input: tuple val(meta), path(ref), path(query) @@ -45,4 +45,16 @@ process MUMMER { mummer: $VERSION END_VERSIONS """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = '3.23' // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + """ + touch ${prefx}.coords + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + mummer: $VERSION + END_VERSIONS + """ } diff --git a/modules/nf-core/modules/mummer/meta.yml b/modules/nf-core/mummer/meta.yml old mode 100644 new mode 100755 similarity index 96% rename from modules/nf-core/modules/mummer/meta.yml rename to modules/nf-core/mummer/meta.yml index ec4f0c86..f03d483c --- a/modules/nf-core/modules/mummer/meta.yml +++ b/modules/nf-core/mummer/meta.yml @@ -10,7 +10,7 @@ tools: homepage: http://mummer.sourceforge.net/ documentation: http://mummer.sourceforge.net/ tool_dev_url: http://mummer.sourceforge.net/ - doi: https://doi.org/10.1186/gb-2004-5-2-r12 + doi: 10.1186/gb-2004-5-2-r12 licence: ["The Artistic License"] input: diff --git a/modules/nf-core/paftools/sam2paf/main.nf b/modules/nf-core/paftools/sam2paf/main.nf new file mode 100755 index 00000000..ae9c0ff1 --- /dev/null +++ b/modules/nf-core/paftools/sam2paf/main.nf @@ -0,0 +1,45 @@ +process PAFTOOLS_SAM2PAF { + tag "$meta.id" + label 'process_low' + + // Note: the versions here need to match the versions used in the mulled container below and minimap2/index + conda "bioconda::minimap2=2.24 bioconda::samtools=1.14" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/mulled-v2-66534bcbb7031a148b13e2ad42583020b9cd25c4:1679e915ddb9d6b4abda91880c4b48857d471bd8-0' : + 'biocontainers/mulled-v2-66534bcbb7031a148b13e2ad42583020b9cd25c4:1679e915ddb9d6b4abda91880c4b48857d471bd8-0' }" + + input: + tuple val(meta), path(bam) + + output: + tuple val(meta), file("*.paf") , emit: paf + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: "" + def prefix = task.ext.prefix ?: "${meta.id}" + + """ + samtools view -h ${bam} | paftools.js sam2paf - > ${prefix}.paf + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + paftools.js: \$(paftools.js --version) + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + + """ + touch ${prefix}.paf + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + paftools.js: \$(paftools.js --version) + END VERSIONS + """ +} diff --git a/modules/nf-core/paftools/sam2paf/meta.yml b/modules/nf-core/paftools/sam2paf/meta.yml new file mode 100755 index 00000000..bc08f9a9 --- /dev/null +++ b/modules/nf-core/paftools/sam2paf/meta.yml @@ -0,0 +1,39 @@ +name: paftools_sam2paf +description: A program to convert bam into paf. +keywords: + - paf + - bam + - conversion +tools: + - paftools: + description: | + A program to manipulate paf files / convert to and from paf. + homepage: https://github.com/lh3/minimap2 + documentation: https://github.com/lh3/minimap2/blob/master/README.md + licence: ["MIT"] +input: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - bam: + type: file + description: An input bam file to be converted into paf. +output: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - paf: + type: file + description: | + An output paf containing detailed data about the sample + pattern: "${prefix}.paf" + - versions: + type: file + description: File containing software versions + pattern: "versions.yml" +authors: + - "@DLBPointon" diff --git a/modules/nf-core/pretextmap/main.nf b/modules/nf-core/pretextmap/main.nf new file mode 100755 index 00000000..f7a5313d --- /dev/null +++ b/modules/nf-core/pretextmap/main.nf @@ -0,0 +1,60 @@ + +process PRETEXTMAP { + tag "$meta.id" + label 'process_single' + + conda "bioconda::pretextmap=0.1.9 bioconda::samtools=1.17" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/mulled-v2-f3591ce8609c7b3b33e5715333200aa5c163aa61%3A44321ab4d64f0b6d0c93abbd1406369d1b3da684-0': + 'biocontainers/mulled-v2-f3591ce8609c7b3b33e5715333200aa5c163aa61:44321ab4d64f0b6d0c93abbd1406369d1b3da684-0' }" + + input: + tuple val(meta), path(input) + path fasta + + output: + tuple val(meta), path("*.pretext"), emit: pretext + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + def reference = fasta ? "--reference ${fasta}" : "" + + """ + if [[ $input == *.pairs.gz ]]; then + zcat $input | PretextMap \\ + $args \\ + -o ${prefix}.pretext + else + samtools \\ + view \\ + $reference \\ + -h \\ + $input | PretextMap \\ + $args \\ + -o ${prefix}.pretext + fi + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + pretextmap: \$(PretextMap | grep "Version" | sed 's/PretextMap Version //g') + samtools: \$(echo \$(samtools --version 2>&1) | sed 's/^.*samtools //; s/Using.*\$//' ) + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + """ + touch ${prefix}.pretext + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + pretextmap: \$(PretextMap | grep "Version" | sed 's/PretextMap Version //g') + samtools: \$(echo \$(samtools --version 2>&1) | sed 's/^.*samtools //; s/Using.*\$//' )) + END_VERSIONS + """ +} diff --git a/modules/nf-core/pretextmap/meta.yml b/modules/nf-core/pretextmap/meta.yml new file mode 100755 index 00000000..47811974 --- /dev/null +++ b/modules/nf-core/pretextmap/meta.yml @@ -0,0 +1,43 @@ +name: "pretextmap" +description: converts sam/bam/cram/pairs into genome contact map +keywords: + - contact + - bam + - map +tools: + - "pretextmap": + description: "Paired REad TEXTure Mapper. Converts SAM formatted read pairs into genome contact maps." + homepage: "https://github.com/wtsi-hpag/PretextMap" + documentation: "https://github.com/wtsi-hpag/PretextMap/blob/master/README.md" + + licence: "['MIT']" + +input: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - input: + type: file + description: BAM/CRAM/SAM file or pairs formatted reads file + pattern: "*.{bam,cram,sam,pairs.gz}" + +output: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - versions: + type: file + description: File containing software versions + pattern: "versions.yml" + - pretext: + type: file + description: pretext map + pattern: "*.pretext" + +authors: + - "@marrip" + - "@getrudeln" diff --git a/modules/nf-core/pretextsnapshot/main.nf b/modules/nf-core/pretextsnapshot/main.nf new file mode 100755 index 00000000..10425446 --- /dev/null +++ b/modules/nf-core/pretextsnapshot/main.nf @@ -0,0 +1,35 @@ +process PRETEXTSNAPSHOT { + tag "$meta.id" + label 'process_single' + + conda "bioconda::pretextsnapshot=0.0.4" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/pretextsnapshot:0.0.4--h7d875b9_0': + 'biocontainers/pretextsnapshot:0.0.4--h7d875b9_0' }" + + input: + tuple val(meta), path(pretext_map) + + output: + tuple val(meta), path('*.{jpeg,png,bmp}'), emit: image + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + """ + PretextSnapshot \\ + $args \\ + --map $pretext_map \\ + --prefix $prefix \\ + --folder . + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + pretextsnapshot: \$(echo \$(PretextSnapshot --version 2>&1) | sed 's/^.*PretextSnapshot Version //' ) + END_VERSIONS + """ +} diff --git a/modules/nf-core/pretextsnapshot/meta.yml b/modules/nf-core/pretextsnapshot/meta.yml new file mode 100755 index 00000000..fe9cb17a --- /dev/null +++ b/modules/nf-core/pretextsnapshot/meta.yml @@ -0,0 +1,45 @@ +name: "pretextsnapshot" +description: a module to generate images from Pretext contact maps. +keywords: + - pretext + - image + - hic + - png + - jpg + - bmp + - contact maps +tools: + - "pretextsnapshot": + description: "Commandline image generator for Pretext Hi-C genome contact maps." + homepage: "https://github.com/wtsi-hpag/PretextSnapshot" + tool_dev_url: "https://github.com/wtsi-hpag/PretextSnapshot" + licence: "['https://github.com/wtsi-hpag/PretextSnapshot/blob/master/LICENSE']" + +input: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - pretext_map: + type: file + description: pretext hic map + pattern: "*.pretext" + +output: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - versions: + type: file + description: File containing software versions + pattern: "versions.yml" + - image: + type: file + description: image of a hic contact map + pattern: "*.{png,jpg,bmp}" + +authors: + - "@epaule" diff --git a/modules/nf-core/modules/samtools/faidx/main.nf b/modules/nf-core/samtools/faidx/main.nf old mode 100644 new mode 100755 similarity index 59% rename from modules/nf-core/modules/samtools/faidx/main.nf rename to modules/nf-core/samtools/faidx/main.nf index ef940db2..59ed3088 --- a/modules/nf-core/modules/samtools/faidx/main.nf +++ b/modules/nf-core/samtools/faidx/main.nf @@ -2,18 +2,20 @@ process SAMTOOLS_FAIDX { tag "$fasta" label 'process_single' - conda (params.enable_conda ? "bioconda::samtools=1.15.1" : null) + conda "bioconda::samtools=1.17" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/samtools:1.15.1--h1170115_0' : - 'quay.io/biocontainers/samtools:1.15.1--h1170115_0' }" + 'https://depot.galaxyproject.org/singularity/samtools:1.17--h00cdaf9_0' : + 'biocontainers/samtools:1.17--h00cdaf9_0' }" input: tuple val(meta), path(fasta) + tuple val(meta2), path(fai) output: - tuple val(meta), path ("*.fai"), emit: fai - tuple val(meta), path ("*.gzi"), emit: gzi, optional: true - path "versions.yml" , emit: versions + tuple val(meta), path ("*.{fa,fasta}") , emit: fa , optional: true + tuple val(meta), path ("*.fai") , emit: fai, optional: true + tuple val(meta), path ("*.gzi") , emit: gzi, optional: true + path "versions.yml" , emit: versions when: task.ext.when == null || task.ext.when @@ -23,8 +25,8 @@ process SAMTOOLS_FAIDX { """ samtools \\ faidx \\ - $args \\ - $fasta + $fasta \\ + $args cat <<-END_VERSIONS > versions.yml "${task.process}": @@ -33,8 +35,12 @@ process SAMTOOLS_FAIDX { """ stub: + def match = (task.ext.args =~ /-o(?:utput)?\s(.*)\s?/).findAll() + def fastacmd = match[0] ? "touch ${match[0][1]}" : '' """ + ${fastacmd} touch ${fasta}.fai + cat <<-END_VERSIONS > versions.yml "${task.process}": diff --git a/modules/nf-core/modules/samtools/faidx/meta.yml b/modules/nf-core/samtools/faidx/meta.yml old mode 100644 new mode 100755 similarity index 79% rename from modules/nf-core/modules/samtools/faidx/meta.yml rename to modules/nf-core/samtools/faidx/meta.yml index fe2fe9a1..957b25e5 --- a/modules/nf-core/modules/samtools/faidx/meta.yml +++ b/modules/nf-core/samtools/faidx/meta.yml @@ -3,6 +3,7 @@ description: Index FASTA file keywords: - index - fasta + - faidx tools: - samtools: description: | @@ -17,12 +18,21 @@ input: - meta: type: map description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] + Groovy Map containing reference information + e.g. [ id:'test' ] - fasta: type: file description: FASTA file pattern: "*.{fa,fasta}" + - meta2: + type: map + description: | + Groovy Map containing reference information + e.g. [ id:'test' ] + - fai: + type: file + description: FASTA index file + pattern: "*.{fai}" output: - meta: type: map diff --git a/modules/nf-core/samtools/markdup/main.nf b/modules/nf-core/samtools/markdup/main.nf new file mode 100755 index 00000000..218cf97b --- /dev/null +++ b/modules/nf-core/samtools/markdup/main.nf @@ -0,0 +1,63 @@ +process SAMTOOLS_MARKDUP { + tag "$meta.id" + label 'process_medium' + + conda "bioconda::samtools=1.17" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/samtools:1.17--h00cdaf9_0' : + 'biocontainers/samtools:1.17--h00cdaf9_0' }" + + input: + tuple val(meta), path(input) + path fasta + + output: + tuple val(meta), path("*.bam"), emit: bam, optional: true + tuple val(meta), path("*.cram"), emit: cram, optional: true + tuple val(meta), path("*.sam"), emit: sam, optional: true + path "versions.yml", emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + def reference = fasta ? "--reference ${fasta}" : "" + def extension = args.contains("--output-fmt sam") ? "sam" : + args.contains("--output-fmt bam") ? "bam" : + args.contains("--output-fmt cram") ? "cram" : + "bam" + if ("$input" == "${prefix}.${extension}") error "Input and output names are the same, use \"task.ext.prefix\" to disambiguate!" + """ + samtools \\ + markdup \\ + $args \\ + ${reference} \\ + -@ $task.cpus \\ + -T $prefix \\ + $input \\ + ${prefix}.${extension} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + samtools: \$(echo \$(samtools --version 2>&1) | sed 's/^.*samtools //; s/Using.*\$//' )) + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + def extension = args.contains("--output-fmt sam") ? "sam" : + args.contains("--output-fmt bam") ? "bam" : + args.contains("--output-fmt cram") ? "cram" : + "bam" + if ("$input" == "${prefix}.${extension}") error "Input and output names are the same, use \"task.ext.prefix\" to disambiguate!" + """ + touch ${prefix}.${extension} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + samtools: \$(echo \$(samtools --version 2>&1) | sed 's/^.*samtools //; s/Using.*\$//' )) + END_VERSIONS + """ +} diff --git a/modules/nf-core/samtools/markdup/meta.yml b/modules/nf-core/samtools/markdup/meta.yml new file mode 100755 index 00000000..4207c93a --- /dev/null +++ b/modules/nf-core/samtools/markdup/meta.yml @@ -0,0 +1,44 @@ +name: "samtools_markdup" +description: mark duplicate alignments in a coordinate sorted file +keywords: + - bam + - duplicates + - markduplicates + - samtools +tools: + - "samtools": + description: "Tools for dealing with SAM, BAM and CRAM files" + homepage: "http://www.htslib.org" + documentation: "https://www.htslib.org/doc/samtools-markdup.html" + tool_dev_url: "https://github.com/samtools/samtools" + doi: "10.1093/bioinformatics/btp352" + licence: "['MIT']" + +input: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - input: + type: file + description: BAM/CRAM/SAM file + pattern: "*.{bam,cram,sam}" + +output: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - versions: + type: file + description: File containing software versions + pattern: "versions.yml" + - output: + type: file + description: Sorted BAM/CRAM/SAM file + pattern: "*.{bam,cram,sam}" + +authors: + - "@priyanka-surana" diff --git a/modules/nf-core/modules/nf-core/samtools/merge/main.nf b/modules/nf-core/samtools/merge/main.nf old mode 100644 new mode 100755 similarity index 90% rename from modules/nf-core/modules/nf-core/samtools/merge/main.nf rename to modules/nf-core/samtools/merge/main.nf index 91f14116..b73b7cb2 --- a/modules/nf-core/modules/nf-core/samtools/merge/main.nf +++ b/modules/nf-core/samtools/merge/main.nf @@ -2,15 +2,15 @@ process SAMTOOLS_MERGE { tag "$meta.id" label 'process_low' - conda (params.enable_conda ? "bioconda::samtools=1.15.1" : null) + conda "bioconda::samtools=1.17" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/samtools:1.15.1--h1170115_0' : - 'quay.io/biocontainers/samtools:1.15.1--h1170115_0' }" + 'https://depot.galaxyproject.org/singularity/samtools:1.17--h00cdaf9_0' : + 'biocontainers/samtools:1.17--h00cdaf9_0' }" input: tuple val(meta), path(input_files, stageAs: "?/*") - path fasta - path fai + tuple val(meta2), path(fasta) + tuple val(meta3), path(fai) output: tuple val(meta), path("${prefix}.bam") , optional:true, emit: bam diff --git a/modules/nf-core/modules/nf-core/samtools/merge/meta.yml b/modules/nf-core/samtools/merge/meta.yml old mode 100644 new mode 100755 similarity index 76% rename from modules/nf-core/modules/nf-core/samtools/merge/meta.yml rename to modules/nf-core/samtools/merge/meta.yml index 5bd84bc5..3a815f74 --- a/modules/nf-core/modules/nf-core/samtools/merge/meta.yml +++ b/modules/nf-core/samtools/merge/meta.yml @@ -12,7 +12,7 @@ tools: short DNA sequence read alignments in the SAM, BAM and CRAM formats, written by Heng Li. These files are generated as output by short read aligners like BWA. homepage: http://www.htslib.org/ - documentation: hhttp://www.htslib.org/doc/samtools.html + documentation: http://www.htslib.org/doc/samtools.html doi: 10.1093/bioinformatics/btp352 licence: ["MIT"] input: @@ -25,13 +25,23 @@ input: type: file description: BAM/CRAM file pattern: "*.{bam,cram,sam}" + - meta2: + type: map + description: | + Groovy Map containing reference information + e.g. [ id:'genome' ] - fasta: - type: optional file - description: Reference file the CRAM was created with + type: file + description: Reference file the CRAM was created with (optional) pattern: "*.{fasta,fa}" + - meta3: + type: map + description: | + Groovy Map containing reference information + e.g. [ id:'genome' ] - fai: - type: optional file - description: Index of the reference file the CRAM was created with + type: file + description: Index of the reference file the CRAM was created with (optional) pattern: "*.fai" output: - meta: @@ -60,3 +70,4 @@ authors: - "@yuukiiwa " - "@maxulysse" - "@FriederikeHanssen" + - "@ramprasadn" diff --git a/modules/nf-core/samtools/sort/main.nf b/modules/nf-core/samtools/sort/main.nf new file mode 100755 index 00000000..2b7753fd --- /dev/null +++ b/modules/nf-core/samtools/sort/main.nf @@ -0,0 +1,49 @@ +process SAMTOOLS_SORT { + tag "$meta.id" + label 'process_medium' + + conda "bioconda::samtools=1.17" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/samtools:1.17--h00cdaf9_0' : + 'biocontainers/samtools:1.17--h00cdaf9_0' }" + + input: + tuple val(meta), path(bam) + + output: + tuple val(meta), path("*.bam"), emit: bam + tuple val(meta), path("*.csi"), emit: csi, optional: true + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + if ("$bam" == "${prefix}.bam") error "Input and output names are the same, use \"task.ext.prefix\" to disambiguate!" + """ + samtools sort \\ + $args \\ + -@ $task.cpus \\ + -o ${prefix}.bam \\ + -T $prefix \\ + $bam + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + samtools: \$(echo \$(samtools --version 2>&1) | sed 's/^.*samtools //; s/Using.*\$//') + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + """ + touch ${prefix}.bam + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + samtools: \$(echo \$(samtools --version 2>&1) | sed 's/^.*samtools //; s/Using.*\$//') + END_VERSIONS + """ +} diff --git a/modules/nf-core/samtools/sort/meta.yml b/modules/nf-core/samtools/sort/meta.yml new file mode 100755 index 00000000..07328431 --- /dev/null +++ b/modules/nf-core/samtools/sort/meta.yml @@ -0,0 +1,48 @@ +name: samtools_sort +description: Sort SAM/BAM/CRAM file +keywords: + - sort + - bam + - sam + - cram +tools: + - samtools: + description: | + SAMtools is a set of utilities for interacting with and post-processing + short DNA sequence read alignments in the SAM, BAM and CRAM formats, written by Heng Li. + These files are generated as output by short read aligners like BWA. + homepage: http://www.htslib.org/ + documentation: http://www.htslib.org/doc/samtools.html + doi: 10.1093/bioinformatics/btp352 + licence: ["MIT"] +input: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - bam: + type: file + description: BAM/CRAM/SAM file + pattern: "*.{bam,cram,sam}" +output: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - bam: + type: file + description: Sorted BAM/CRAM/SAM file + pattern: "*.{bam,cram,sam}" + - versions: + type: file + description: File containing software versions + pattern: "versions.yml" + - csi: + type: file + description: BAM index file (optional) + pattern: "*.csi" +authors: + - "@drpatelh" + - "@ewels" diff --git a/modules/nf-core/samtools/view/main.nf b/modules/nf-core/samtools/view/main.nf new file mode 100755 index 00000000..cb91facf --- /dev/null +++ b/modules/nf-core/samtools/view/main.nf @@ -0,0 +1,66 @@ +process SAMTOOLS_VIEW { + tag "$meta.id" + label 'process_low' + + conda "bioconda::samtools=1.17" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/samtools:1.17--h00cdaf9_0' : + 'biocontainers/samtools:1.17--h00cdaf9_0' }" + + input: + tuple val(meta), path(input), path(index) + tuple val(meta2), path(fasta) + path qname + + output: + tuple val(meta), path("*.bam"), emit: bam, optional: true + tuple val(meta), path("*.cram"), emit: cram, optional: true + tuple val(meta), path("*.sam"), emit: sam, optional: true + tuple val(meta), path("*.bai"), emit: bai, optional: true + tuple val(meta), path("*.csi"), emit: csi, optional: true + tuple val(meta), path("*.crai"), emit: crai, optional: true + path "versions.yml", emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def args2 = task.ext.args2 ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + def reference = fasta ? "--reference ${fasta}" : "" + def readnames = qname ? "--qname-file ${qname}": "" + def file_type = args.contains("--output-fmt sam") ? "sam" : + args.contains("--output-fmt bam") ? "bam" : + args.contains("--output-fmt cram") ? "cram" : + input.getExtension() + if ("$input" == "${prefix}.${file_type}") error "Input and output names are the same, use \"task.ext.prefix\" to disambiguate!" + """ + samtools \\ + view \\ + --threads ${task.cpus-1} \\ + ${reference} \\ + ${readnames} \\ + $args \\ + -o ${prefix}.${file_type} \\ + $input \\ + $args2 + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + samtools: \$(echo \$(samtools --version 2>&1) | sed 's/^.*samtools //; s/Using.*\$//') + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + """ + touch ${prefix}.bam + touch ${prefix}.cram + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + samtools: \$(echo \$(samtools --version 2>&1) | sed 's/^.*samtools //; s/Using.*\$//') + END_VERSIONS + """ +} diff --git a/modules/nf-core/samtools/view/meta.yml b/modules/nf-core/samtools/view/meta.yml new file mode 100755 index 00000000..3b05450b --- /dev/null +++ b/modules/nf-core/samtools/view/meta.yml @@ -0,0 +1,84 @@ +name: samtools_view +description: filter/convert SAM/BAM/CRAM file +keywords: + - view + - bam + - sam + - cram +tools: + - samtools: + description: | + SAMtools is a set of utilities for interacting with and post-processing + short DNA sequence read alignments in the SAM, BAM and CRAM formats, written by Heng Li. + These files are generated as output by short read aligners like BWA. + homepage: http://www.htslib.org/ + documentation: http://www.htslib.org/doc/samtools.html + doi: 10.1093/bioinformatics/btp352 + licence: ["MIT"] +input: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - input: + type: file + description: BAM/CRAM/SAM file + pattern: "*.{bam,cram,sam}" + - index: + type: file + description: BAM.BAI/BAM.CSI/CRAM.CRAI file (optional) + pattern: "*.{.bai,.csi,.crai}" + - meta2: + type: map + description: | + Groovy Map containing reference information + e.g. [ id:'test' ] + - fasta: + type: file + description: Reference file the CRAM was created with (optional) + pattern: "*.{fasta,fa}" + - qname: + type: file + description: Optional file with read names to output only select alignments + pattern: "*.{txt,list}" +output: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - bam: + type: file + description: optional filtered/converted BAM file + pattern: "*.{bam}" + - cram: + type: file + description: optional filtered/converted CRAM file + pattern: "*.{cram}" + - sam: + type: file + description: optional filtered/converted SAM file + pattern: "*.{sam}" + # bai, csi, and crai are created with `--write-index` + - bai: + type: file + description: optional BAM file index + pattern: "*.{bai}" + - csi: + type: file + description: optional tabix BAM file index + pattern: "*.{csi}" + - crai: + type: file + description: optional CRAM file index + pattern: "*.{crai}" + - versions: + type: file + description: File containing software versions + pattern: "versions.yml" +authors: + - "@drpatelh" + - "@joseespinosa" + - "@FriederikeHanssen" + - "@priyanka-surana" diff --git a/modules/nf-core/seqtk/cutn/main.nf b/modules/nf-core/seqtk/cutn/main.nf new file mode 100755 index 00000000..e2b90cf1 --- /dev/null +++ b/modules/nf-core/seqtk/cutn/main.nf @@ -0,0 +1,49 @@ +process SEQTK_CUTN { + tag "$meta.id" + label 'process_low' + + conda "bioconda::seqtk=1.4" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/seqtk:1.4--he4a0461_1' : + 'biocontainers/seqtk:1.4--he4a0461_1' }" + + input: + tuple val(meta), path(fasta) + + output: + tuple val(meta), path("*.bed") , emit: bed + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + + """ + seqtk \\ + cutN \\ + $args \\ + -g $fasta \\ + > ${prefix}.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + seqtk: \$(echo \$(seqtk 2>&1) | sed 's/^.*Version: //; s/ .*\$//') + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + + """ + touch ${prefix}.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + seqtk: \$(echo \$(seqtk 2>&1) | sed 's/^.*Version: //; s/ .*\$//') + END_VERSIONS + """ + +} diff --git a/modules/nf-core/seqtk/cutn/meta.yml b/modules/nf-core/seqtk/cutn/meta.yml new file mode 100755 index 00000000..4850df9d --- /dev/null +++ b/modules/nf-core/seqtk/cutn/meta.yml @@ -0,0 +1,42 @@ +name: seqtk_cutn +description: Generates a BED file containing genomic locations of lengths of N. +keywords: + - cut + - fasta + - seqtk +tools: + - seqtk: + description: Seqtk is a fast and lightweight tool for processing sequences in the FASTA or FASTQ format. Seqtk mergepe command merges pair-end reads into one interleaved file. + homepage: https://github.com/lh3/seqtk + documentation: https://docs.csc.fi/apps/seqtk/ + tool_dev_url: https://github.com/lh3/seqtk + licence: ["MIT"] + +input: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - fasta: + type: file + description: A single fasta file to be split. + pattern: "*.{fasta}" + +output: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - bed: + type: file + description: The output bed which summarised locations of cuts + pattern: "*.{bed}" + - versions: + type: file + description: File containing software versions + pattern: "versions.yml" + +authors: + - "@DLBPointon" diff --git a/modules/nf-core/modules/nf-core/tabix/bgziptabix/main.nf b/modules/nf-core/tabix/bgziptabix/main.nf old mode 100644 new mode 100755 similarity index 65% rename from modules/nf-core/modules/nf-core/tabix/bgziptabix/main.nf rename to modules/nf-core/tabix/bgziptabix/main.nf index 0d05984a..b73ee0c9 --- a/modules/nf-core/modules/nf-core/tabix/bgziptabix/main.nf +++ b/modules/nf-core/tabix/bgziptabix/main.nf @@ -2,25 +2,26 @@ process TABIX_BGZIPTABIX { tag "$meta.id" label 'process_single' - conda (params.enable_conda ? 'bioconda::tabix=1.11' : null) + conda "bioconda::tabix=1.11" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? 'https://depot.galaxyproject.org/singularity/tabix:1.11--hdfd78af_0' : - 'quay.io/biocontainers/tabix:1.11--hdfd78af_0' }" + 'biocontainers/tabix:1.11--hdfd78af_0' }" input: tuple val(meta), path(input) output: - tuple val(meta), path("*.gz"), path("*.tbi"), emit: gz_tbi + tuple val(meta), path("*.gz"), path("*.tbi"), optional: true, emit: gz_tbi + tuple val(meta), path("*.gz"), path("*.csi"), optional: true, emit: gz_csi path "versions.yml" , emit: versions when: task.ext.when == null || task.ext.when script: - def args = task.ext.args ?: '' - def args2 = task.ext.args2 ?: '' - def prefix = task.ext.prefix ?: "${meta.id}" + def args = task.ext.args ?: '' + def args2 = meta.max_scaff == 'csi' ? "--csi" : '' + def prefix = task.ext.prefix ?: "${meta.id}" """ bgzip --threads ${task.cpus} -c $args $input > ${prefix}.${input.getExtension()}.gz tabix $args2 ${prefix}.${input.getExtension()}.gz @@ -34,8 +35,9 @@ process TABIX_BGZIPTABIX { stub: def prefix = task.ext.prefix ?: "${meta.id}" """ - touch ${prefix}.gz - touch ${prefix}.gz.tbi + touch ${prefix}.${input.getExtension()}.gz + touch ${prefix}.${input.getExtension()}.gz.tbi + touch ${prefix}.${input.getExtension()}.gz.csi cat <<-END_VERSIONS > versions.yml "${task.process}": diff --git a/modules/nf-core/modules/nf-core/tabix/bgziptabix/meta.yml b/modules/nf-core/tabix/bgziptabix/meta.yml old mode 100644 new mode 100755 similarity index 90% rename from modules/nf-core/modules/nf-core/tabix/bgziptabix/meta.yml rename to modules/nf-core/tabix/bgziptabix/meta.yml index 49c03289..2761e271 --- a/modules/nf-core/modules/nf-core/tabix/bgziptabix/meta.yml +++ b/modules/nf-core/tabix/bgziptabix/meta.yml @@ -37,9 +37,14 @@ output: type: file description: tabix index file pattern: "*.{gz.tbi}" + - csi: + type: file + description: tabix alternate index file + pattern: "*.{gz.csi}" - versions: type: file description: File containing software versions pattern: "versions.yml" authors: - "@maxulysse" + - "@DLBPointon" diff --git a/modules/nf-core/tabix/bgziptabix/tabix-bgziptabix.diff b/modules/nf-core/tabix/bgziptabix/tabix-bgziptabix.diff new file mode 100755 index 00000000..90e3d55b --- /dev/null +++ b/modules/nf-core/tabix/bgziptabix/tabix-bgziptabix.diff @@ -0,0 +1,18 @@ +Changes in module 'nf-core/tabix/bgziptabix' +--- modules/nf-core/tabix/bgziptabix/main.nf ++++ modules/nf-core/tabix/bgziptabix/main.nf +@@ -19,9 +19,9 @@ + task.ext.when == null || task.ext.when + + script: +- def args = task.ext.args ?: '' +- def args2 = task.ext.args2 ?: '' +- def prefix = task.ext.prefix ?: "${meta.id}" ++ def args = task.ext.args ?: '' ++ def args2 = meta.max_scaff == 'csi' ? "--csi" : '' ++ def prefix = task.ext.prefix ?: "${meta.id}" + """ + bgzip --threads ${task.cpus} -c $args $input > ${prefix}.${input.getExtension()}.gz + tabix $args2 ${prefix}.${input.getExtension()}.gz + +************************************************************ diff --git a/modules/nf-core/ucsc/bedgraphtobigwig/main.nf b/modules/nf-core/ucsc/bedgraphtobigwig/main.nf new file mode 100755 index 00000000..b4719dee --- /dev/null +++ b/modules/nf-core/ucsc/bedgraphtobigwig/main.nf @@ -0,0 +1,49 @@ +process UCSC_BEDGRAPHTOBIGWIG { + tag "$meta.id" + label 'process_single' + + // WARN: Version information not provided by tool on CLI. Please update version string below when bumping container versions. + conda "bioconda::ucsc-bedgraphtobigwig=377" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/ucsc-bedgraphtobigwig:377--h446ed27_1' : + 'biocontainers/ucsc-bedgraphtobigwig:377--h446ed27_1' }" + + input: + tuple val(meta), path(bedgraph) + path sizes + + output: + tuple val(meta), path("*.bigWig"), emit: bigwig + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = '377' // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + """ + bedGraphToBigWig \\ + $bedgraph \\ + $sizes \\ + ${prefix}.bigWig + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + ucsc: $VERSION + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = '377' // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + """ + touch ${prefix}.bigWig + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + ucsc: $VERSION + END_VERSIONS + """ +} diff --git a/modules/nf-core/ucsc/bedgraphtobigwig/meta.yml b/modules/nf-core/ucsc/bedgraphtobigwig/meta.yml new file mode 100755 index 00000000..416c91e0 --- /dev/null +++ b/modules/nf-core/ucsc/bedgraphtobigwig/meta.yml @@ -0,0 +1,47 @@ +name: ucsc_bedgraphtobigwig +description: Convert a bedGraph file to bigWig format. +keywords: + - bedgraph + - bigwig + - ucsc + - bedgraphtobigwig + - converter +tools: + - ucsc: + description: Convert a bedGraph file to bigWig format. + homepage: http://hgdownload.cse.ucsc.edu/admin/exe/ + documentation: https://genome.ucsc.edu/goldenPath/help/bigWig.html + licence: ["varies; see http://genome.ucsc.edu/license"] + +input: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - bedgraph: + type: file + description: bedGraph file + pattern: "*.{bedGraph}" + - sizes: + type: file + description: chromosome sizes file + pattern: "*.{sizes}" + +output: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - versions: + type: file + description: File containing software versions + pattern: "versions.yml" + - bigwig: + type: file + description: bigWig file + pattern: "*.{bigWig}" + +authors: + - "@drpatelh" diff --git a/modules/nf-core/modules/ucsc/bedtobigbed/main.nf b/modules/nf-core/ucsc/bedtobigbed/main.nf old mode 100644 new mode 100755 similarity index 72% rename from modules/nf-core/modules/ucsc/bedtobigbed/main.nf rename to modules/nf-core/ucsc/bedtobigbed/main.nf index 3acc8f36..1e40375d --- a/modules/nf-core/modules/ucsc/bedtobigbed/main.nf +++ b/modules/nf-core/ucsc/bedtobigbed/main.nf @@ -3,10 +3,10 @@ process UCSC_BEDTOBIGBED { label 'process_single' // WARN: Version information not provided by tool on CLI. Please update version string below when bumping container versions. - conda (params.enable_conda ? "bioconda::ucsc-bedtobigbed=377" : null) + conda "bioconda::ucsc-bedtobigbed=377" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? 'https://depot.galaxyproject.org/singularity/ucsc-bedtobigbed:377--ha8a8165_3' : - 'quay.io/biocontainers/ucsc-bedtobigbed:377--ha8a8165_3' }" + 'biocontainers/ucsc-bedtobigbed:377--ha8a8165_3' }" input: tuple val(meta), path(bed) @@ -38,4 +38,16 @@ process UCSC_BEDTOBIGBED { ucsc: $VERSION END_VERSIONS """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + def VERSION = '377' // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions. + """ + touch ${prefix}.bigBed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + ucsc: $VERSION + END_VERSIONS + """ } diff --git a/modules/nf-core/modules/ucsc/bedtobigbed/meta.yml b/modules/nf-core/ucsc/bedtobigbed/meta.yml old mode 100644 new mode 100755 similarity index 86% rename from modules/nf-core/modules/ucsc/bedtobigbed/meta.yml rename to modules/nf-core/ucsc/bedtobigbed/meta.yml index e8e08fa7..8e9e5291 --- a/modules/nf-core/modules/ucsc/bedtobigbed/meta.yml +++ b/modules/nf-core/ucsc/bedtobigbed/meta.yml @@ -3,13 +3,14 @@ description: Convert file from bed to bigBed format keywords: - bed - bigbed + - ucsc + - bedtobigbed + - converter tools: - ucsc: description: Convert file from bed to bigBed format - homepage: None - documentation: None - tool_dev_url: None - doi: "" + homepage: http://hgdownload.cse.ucsc.edu/admin/exe/ + documentation: https://genome.ucsc.edu/goldenPath/help/bigBed.html licence: ["varies; see http://genome.ucsc.edu/license"] input: diff --git a/modules/nf-core/windowmasker/mk_counts/main.nf b/modules/nf-core/windowmasker/mk_counts/main.nf new file mode 100755 index 00000000..bfa66f35 --- /dev/null +++ b/modules/nf-core/windowmasker/mk_counts/main.nf @@ -0,0 +1,55 @@ +process WINDOWMASKER_MKCOUNTS { + tag "$meta.id" + label 'process_low' + + conda "bioconda::blast=2.14.0" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/blast:2.14.0--h7d5a4b4_1': + 'biocontainers/blast:2.14.0--h7d5a4b4_1' }" + + input: + tuple val(meta), path(ref) + + output: + tuple val(meta), path("*.txt") , emit: counts + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: "" + def prefix = task.ext.prefix ?: "${meta.id}" + + def memory = 3072 + if (!task.memory) { + log.info '[WINDOWMASKER: MK_COUNTS] Available memory not known - defaulting to 3GB. Specify process memory requirements to change this.' + } else { + memory = (task.memory.toMega()).intValue() + } + + """ + windowmasker -mk_counts \\ + $args \\ + -mem ${memory} \\ + -in ${ref} \\ + -out ${prefix}.txt + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + windowmasker: \$(windowmasker -version-full | head -n 1 | sed 's/^.*windowmasker: //; s/ .*\$//') + END_VERSIONS + """ + + stub: + def prefix = task.ext.prefix ?: "${meta.id}" + + """ + touch ${prefix}.txt + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + windowmasker: \$(windowmasker -version-full | head -n 1 | sed 's/^.*windowmasker: //; s/ .*\$//') + END_VERSIONS + """ +} diff --git a/modules/nf-core/windowmasker/mk_counts/meta.yml b/modules/nf-core/windowmasker/mk_counts/meta.yml new file mode 100755 index 00000000..788dc96c --- /dev/null +++ b/modules/nf-core/windowmasker/mk_counts/meta.yml @@ -0,0 +1,40 @@ +name: windowmasker_mkcounts +description: A program to generate frequency counts of repetitive units. +keywords: + - fasta + - interval + - windowmasker +tools: + - windowmasker: + description: | + A program to mask highly repetitive and low complexity DNA sequences within a genome. + homepage: https://github.com/ncbi/ncbi-cxx-toolkit-public + documentation: https://ncbi.github.io/cxx-toolkit/ + licence: ["MIT"] +input: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - ref: + type: file + description: An input nucleotide fasta file. +output: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - intervals: + type: file + description: | + An output file containing genomic locations of low + complexity and highly repetitive regions + pattern: "${prefix}.txt" + - versions: + type: file + description: File containing software versions + pattern: "versions.yml" +authors: + - "@DLBPointon" diff --git a/modules/nf-core/windowmasker/ustat/main.nf b/modules/nf-core/windowmasker/ustat/main.nf new file mode 100755 index 00000000..72a19dbf --- /dev/null +++ b/modules/nf-core/windowmasker/ustat/main.nf @@ -0,0 +1,69 @@ +process WINDOWMASKER_USTAT { + tag "$meta.id" + label 'process_low' + + conda "bioconda::blast=2.14.0" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/blast:2.14.0--h7d5a4b4_1': + 'biocontainers/blast:2.14.0--h7d5a4b4_1' }" + + input: + tuple val(meta) , path(counts) + tuple val(meta2), path(ref) + + output: + tuple val(meta), path("${output}") , emit: intervals + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: "" + def prefix = task.ext.prefix ?: "${meta.id}" + def outfmt = args.contains('-outfmt fasta') ? 'fasta' : + args.contains('-outfmt maskinfo_asn1_bin') ? 'maskinfo_asn1_bin' : + args.contains('-outfmt maskinfo_asn1_text') ? 'maskinfo_asn1_text' : + args.contains('-outfmt maskinfo_xml') ? 'maskinfo_xml' : + args.contains('-outfmt seqloc_asn1_bin') ? 'seqloc_asn1_bin' : + args.contains('-outfmt seqloc_asn1_text') ? 'seqloc_asn1_text' : + args.contains('-outfmt seqloc_xml') ? 'seqloc_xml' : + 'interval' + + output = "${prefix}.${outfmt}" + + """ + windowmasker -ustat \\ + ${counts} \\ + $args \\ + -in ${ref} \\ + -out ${output} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + windowmasker: \$(windowmasker -version-full | head -n 1 | sed 's/^.*windowmasker: //; s/ .*\$//') + END_VERSIONS + """ + + stub: + def args = task.ext.args ?: "" + def prefix = task.ext.prefix ?: "${meta.id}" + def outfmt = args.contains('-outfmt fasta') ? 'fasta' : + args.contains('-outfmt maskinfo_asn1_bin') ? 'maskinfo_asn1_bin' : + args.contains('-outfmt maskinfo_asn1_text') ? 'maskinfo_asn1_text' : + args.contains('-outfmt maskinfo_xml') ? 'maskinfo_xml' : + args.contains('-outfmt seqloc_asn1_bin') ? 'seqloc_asn1_bin' : + args.contains('-outfmt seqloc_asn1_text') ? 'seqloc_asn1_text' : + args.contains('-outfmt seqloc_xml') ? 'seqloc_xml' : + 'interval' + + output = "${prefix}.${outfmt}" + """ + touch ${output} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + windowmasker: \$(windowmasker -version-full | head -n 1 | sed 's/^.*windowmasker: //; s/ .*\$//') + END_VERSIONS + """ +} diff --git a/modules/nf-core/windowmasker/ustat/meta.yml b/modules/nf-core/windowmasker/ustat/meta.yml new file mode 100755 index 00000000..6acf2e50 --- /dev/null +++ b/modules/nf-core/windowmasker/ustat/meta.yml @@ -0,0 +1,48 @@ +name: windowmasker_ustat +description: A program to take a counts file and creates a file of genomic co-ordinates to be masked. +keywords: + - fasta + - interval + - windowmasker +tools: + - windowmasker: + description: | + A program to mask highly repetitive and low complexity DNA sequences within a genome. + homepage: https://github.com/ncbi/ncbi-cxx-toolkit-public + documentation: https://ncbi.github.io/cxx-toolkit/ + licence: ["MIT"] +input: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test' ] + - counts: + type: file + description: Contains count data of repetitive regions. + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - ref: + type: file + description: An input nucleotide fasta file. +output: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - wm_intervals: + type: file + description: | + An output file containing genomic locations of low + complexity and highly repetitive regions + pattern: "${output}" + - versions: + type: file + description: File containing software versions + pattern: "versions.yml" +authors: + - "@DLBPointon" diff --git a/modules/sanger-tol/nf-core-modules/blast/tblastn/main.nf b/modules/sanger-tol/nf-core-modules/blast/tblastn/main.nf deleted file mode 100644 index d94593f7..00000000 --- a/modules/sanger-tol/nf-core-modules/blast/tblastn/main.nf +++ /dev/null @@ -1,37 +0,0 @@ -process BLAST_TBLASTN { - tag "$meta.id" - label 'process_medium' - - conda (params.enable_conda ? 'bioconda::blast=2.12.0' : null) - container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/blast:2.12.0--pl5262h3289130_0' : - 'quay.io/biocontainers/blast:2.12.0--pl5262h3289130_0' }" - - input: - tuple val(meta), path(fasta) - path db - - output: - tuple val(meta), path('*.tblastn.txt'), emit: txt - path "versions.yml" , emit: versions - - when: - task.ext.when == null || task.ext.when - - script: - def args = task.ext.args ?: '' - def prefix = task.ext.prefix ?: "${meta.id}" - """ - DB=`find -L ./ -name "*.nsq" | sed 's/.nsq//'` - tblastn \\ - -num_threads $task.cpus \\ - -db \$DB \\ - -query $fasta \\ - $args \\ - -out ${prefix}.tblastn.txt - cat <<-END_VERSIONS > versions.yml - "${task.process}": - blast: \$(tblastn -version 2>&1 | sed 's/^.*tblastn: //; s/ .*\$//') - END_VERSIONS - """ -} diff --git a/modules/sanger-tol/nf-core-modules/blast/tblastn/meta.yml b/modules/sanger-tol/nf-core-modules/blast/tblastn/meta.yml deleted file mode 100644 index 04c4194a..00000000 --- a/modules/sanger-tol/nf-core-modules/blast/tblastn/meta.yml +++ /dev/null @@ -1,40 +0,0 @@ -name: blast_tblastn -description: Queries a BLAST DNA database -keywords: - - fasta - - blast - - tblastn - - DNA sequence -tools: - - blast: - description: | - Protein to Translated Nucleotide BLAST. - homepage: https://blast.ncbi.nlm.nih.gov/Blast.cgi - documentation: https://blast.ncbi.nlm.nih.gov/Blast.cgi?CMD=Web&PAGE_TYPE=Blastdocs - doi: 10.1016/S0022-2836(05)80360-2 - licence: ["US-Government-Work"] -input: - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - fasta: - type: file - description: Input fasta file containing queries sequences - pattern: "*.{fa,fasta}" - - db: - type: directory - description: Directory containing blast database - pattern: "*" -output: - - txt: - type: file - description: File containing blastn hits - pattern: "*.{tblastn.txt}" - - versions: - type: file - description: File containing software versions - pattern: "versions.yml" -authors: - - "@yumisims" diff --git a/modules/sanger-tol/nf-core-modules/makecmap/cmap2bed/main.nf b/modules/sanger-tol/nf-core-modules/makecmap/cmap2bed/main.nf deleted file mode 100644 index b92c3070..00000000 --- a/modules/sanger-tol/nf-core-modules/makecmap/cmap2bed/main.nf +++ /dev/null @@ -1,36 +0,0 @@ -process MAKECMAP_CMAP2BED { - tag "$meta.id" - label 'process_medium' - - def version = '0.001-c1' - - if (params.enable_conda) { - exit 1, "Conda environments cannot be used when using the makecmap process. Please use docker or singularity containers." - } - container "quay.io/sanger-tol/cmap2bed:${version}" - - - input: - tuple val(meta), path(cmap) - val enzyme - - output: - tuple val(meta), path("*.bed"), emit: bedfile - path "versions.yml" , emit: versions - - when: - task.ext.when == null || task.ext.when - - script: - def args = task.ext.args ?: '' - def prefix = task.ext.prefix ?: "${meta.id}" - """ - grep -v '#' $cmap > ${prefix}_${enzyme}_edited.cmap - /scripts/wrapper.sh -t ${prefix}_${enzyme}_edited.cmap -z $enzyme | sort -k1,1 -k2,2n > ${prefix}_${enzyme}.bed - - cat <<-END_VERSIONS > versions.yml - "${task.process}": - cmap2bed: $version - END_VERSIONS - """ -} diff --git a/modules/sanger-tol/nf-core-modules/makecmap/cmap2bed/meta.yml b/modules/sanger-tol/nf-core-modules/makecmap/cmap2bed/meta.yml deleted file mode 100644 index eef5d5eb..00000000 --- a/modules/sanger-tol/nf-core-modules/makecmap/cmap2bed/meta.yml +++ /dev/null @@ -1,39 +0,0 @@ -name: "makecmap_cmap2bed" -description: converted a id converted bionano cmap to a bed file -keywords: - - cmap -tools: - - "cmap2bed": - description: "converted a id converted bionano cmap to a bed file and sort it in numerial order" - -input: - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - cmap: - type: file - description: cmap file - pattern: "*.{cmap}" - - enzyme: - type: value - description: bionnano restriction enzyme name - -output: - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - bedfile: - type: file - description: converted bed file - pattern: "*.bed" - - versions: - type: file - description: File containing software versions - pattern: "versions.yml" - -authors: - - "@yumisims" diff --git a/modules/sanger-tol/nf-core-modules/makecmap/fa2cmapmulticolor/main.nf b/modules/sanger-tol/nf-core-modules/makecmap/fa2cmapmulticolor/main.nf deleted file mode 100644 index b9d75c13..00000000 --- a/modules/sanger-tol/nf-core-modules/makecmap/fa2cmapmulticolor/main.nf +++ /dev/null @@ -1,34 +0,0 @@ -process MAKECMAP_FA2CMAPMULTICOLOR { - tag "$meta.id" - label 'process_medium' - - def version = '0.001-c2' - - if (params.enable_conda) { - exit 1, "Conda environments cannot be used when using the makecmap process. Please use docker or singularity containers." - } - container "quay.io/sanger-tol/makecmap:${version}" - - input: - tuple val(meta), path(fasta) - val enzyme - - output: - tuple val(meta), path("*.cmap"), emit: cmap - path("*key.txt") , emit: cmapkey - path "versions.yml" , emit: versions - - when: - task.ext.when == null || task.ext.when - - script: - def args = task.ext.args ?: '' - """ - fa2cmap_multi_color.pl -i $fasta -e $enzyme 1 $args - - cat <<-END_VERSIONS > versions.yml - "${task.process}": - makecmap: $version - END_VERSIONS - """ -} diff --git a/modules/sanger-tol/nf-core-modules/makecmap/fa2cmapmulticolor/meta.yml b/modules/sanger-tol/nf-core-modules/makecmap/fa2cmapmulticolor/meta.yml deleted file mode 100644 index 2d84593b..00000000 --- a/modules/sanger-tol/nf-core-modules/makecmap/fa2cmapmulticolor/meta.yml +++ /dev/null @@ -1,50 +0,0 @@ -name: "makecmap_fa2cmapmulticolor" - -description: Transform fasta file to BioNano cmap file format (Color-aware) - -keywords: - - BioNano - -tools: - - "fa2cmapmulticolor": - description: Scripts for repairing (stitching) across fragile sites breaks in BioNano genome maps - homepage: https://github.com/ekfchan/BNG-FragileSiteRepair/blob/master/fa2cmap_multi_color.pl - documentation: https://github.com/ekfchan/BNG-FragileSiteRepair - tool_dev_url: https://github.com/ekfchan/BNG-FragileSiteRepair/blob/master/fa2cmap_multi_color.pl - licence: MIT - -input: - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - fasta: - type: file - description: fasta file - pattern: "*.{fa,fasta}" - - enzyme: - type: value - description: bionnano restriction enzyme name - -output: - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - versions: - type: file - description: File containing software versions - pattern: "versions.yml" - - cmapkey: - type: file - description: bionano cmap key file - pattern: "*_key.txt" - - cmap: - type: file - description: bionano cmap key file - pattern: "*.cmap" - -authors: - - "@yumisims" diff --git a/modules/sanger-tol/nf-core-modules/makecmap/renamecmapids/main.nf b/modules/sanger-tol/nf-core-modules/makecmap/renamecmapids/main.nf deleted file mode 100644 index 09d943f5..00000000 --- a/modules/sanger-tol/nf-core-modules/makecmap/renamecmapids/main.nf +++ /dev/null @@ -1,35 +0,0 @@ -process MAKECMAP_RENAMECMAPIDS { - tag "$meta.id" - label 'process_medium' - - def version = '0.001-c2' - - if (params.enable_conda) { - exit 1, "Conda environments cannot be used when using the makecmap process. Please use docker or singularity containers." - } - container "quay.io/sanger-tol/makecmap:${version}" - - input: - tuple val(meta), path(cmap) - path keys - - output: - tuple val(meta), path("*.cmap"), emit: renamedcmap - path "versions.yml" , emit: versions - - when: - task.ext.when == null || task.ext.when - - script: - def args = task.ext.args ?: '' - def prefix = task.ext.prefix ?: "${meta.id}" - - """ - rename_cmapids.pl -cmapfile $cmap -idx_key $keys $args > ${prefix}_EDITED.cmap - - cat <<-END_VERSIONS > versions.yml - "${task.process}": - makecmap: $version - END_VERSIONS - """ -} diff --git a/modules/sanger-tol/nf-core-modules/makecmap/renamecmapids/meta.yml b/modules/sanger-tol/nf-core-modules/makecmap/renamecmapids/meta.yml deleted file mode 100644 index d03e791a..00000000 --- a/modules/sanger-tol/nf-core-modules/makecmap/renamecmapids/meta.yml +++ /dev/null @@ -1,42 +0,0 @@ -name: "makecmap_renamecmapids" - -description: Retrieve original coordinates in a genome assembly for BioNano cmap and output a new edited cmap - -keywords: - - BioNano - -tools: - - "renamecmapids": - description: Scripts to convert BioNano genome maps ids to orginal ids in a genome assembly - licence: Sanger - -input: - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - cmap: - type: file - description: cmap file - pattern: "*.{cmap}" - - keys: - type: file - description: bionnano cmaps ids look up table - -output: - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - versions: - type: file - description: File containing software versions - pattern: "versions.yml" - - renamedcmap: - type: file - description: bionano edited cmap with original ids - pattern: "cmap" -authors: - - "@yumisims" diff --git a/modules/sanger-tol/nf-core-modules/selfcomp/mapids/main.nf b/modules/sanger-tol/nf-core-modules/selfcomp/mapids/main.nf deleted file mode 100644 index 658ce56a..00000000 --- a/modules/sanger-tol/nf-core-modules/selfcomp/mapids/main.nf +++ /dev/null @@ -1,27 +0,0 @@ -process SELFCOMP_MAPIDS { - tag "$meta.id" - label 'process_medium' - def version = '0.001-c1' - if (params.enable_conda) { - exit 1, "Conda environments cannot be used when using the makecmap process. Please use docker or singularity containers." - } - container "quay.io/sanger-tol/selfcomp:${version}" - input: - tuple val(meta), path(bed) - path(agp) - output: - tuple val(meta), path("*.bed"), emit: bedfile - path "versions.yml" , emit: versions - when: - task.ext.when == null || task.ext.when - script: - def args = task.ext.args ?: '' - def prefix = task.ext.prefix ?: "${meta.id}" - """ - mapids.py -i $bed -r $agp > ${prefix}_mapped.bed - cat <<-END_VERSIONS > versions.yml - "${task.process}": - selfcomp_mapids: ${version} - END_VERSIONS - """ -} diff --git a/modules/sanger-tol/nf-core-modules/selfcomp/mapids/meta.yml b/modules/sanger-tol/nf-core-modules/selfcomp/mapids/meta.yml deleted file mode 100644 index 5876019f..00000000 --- a/modules/sanger-tol/nf-core-modules/selfcomp/mapids/meta.yml +++ /dev/null @@ -1,39 +0,0 @@ -name: "selfcomp_mapids" -description: Script to map ids in .bed file using .agp file. -keywords: - - map - - bed - - agp -tools: - - "selfcomp": - licence: "sanger" -input: - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - bed: - type: file - description: BED file - pattern: "*.{bed}" - - agp: - type: file - description: AGP file - pattern: "*.{agp}" -output: - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - versions: - type: file - description: File containing software versions - pattern: "versions.yml" - - bed: - type: file - description: Mapped BED file - pattern: "*.{bed}" -authors: - - "@weaglesBio" diff --git a/modules/sanger-tol/nf-core-modules/selfcomp/mummer2bed/main.nf b/modules/sanger-tol/nf-core-modules/selfcomp/mummer2bed/main.nf deleted file mode 100644 index a6bbcffb..00000000 --- a/modules/sanger-tol/nf-core-modules/selfcomp/mummer2bed/main.nf +++ /dev/null @@ -1,32 +0,0 @@ -process SELFCOMP_MUMMER2BED { - tag "$meta.id" - label 'process_medium' - def version = '0.001-c1' - if (params.enable_conda) { - exit 1, "Conda environments cannot be used when using the mummer2bed process. Please use docker or singularity containers." - } - container "quay.io/sanger-tol/selfcomp:${version}" - - input: - tuple val(meta), path(mummerfile) - val (motiflen) - - output: - tuple val(meta), path("*.bed"), emit: bedfile - path "versions.yml" , emit: versions - - when: - task.ext.when == null || task.ext.when - - script: - def args = task.ext.args ?: '' - def prefix = task.ext.prefix ?: "${meta.id}" - - """ - mummer2bed.py $args -i $mummerfile -l $motiflen > ${prefix}.bed - cat <<-END_VERSIONS > versions.yml - "${task.process}": - selfcomp: $version - END_VERSIONS - """ -} diff --git a/modules/sanger-tol/nf-core-modules/selfcomp/mummer2bed/meta.yml b/modules/sanger-tol/nf-core-modules/selfcomp/mummer2bed/meta.yml deleted file mode 100644 index 4585a491..00000000 --- a/modules/sanger-tol/nf-core-modules/selfcomp/mummer2bed/meta.yml +++ /dev/null @@ -1,39 +0,0 @@ -name: "selfcomp_mummer2bed" -description: module to convert standard 4 columns output to bed file format and filtered by given motif length -keywords: - - mummer2bed -tools: - - "selfcomp": - description: | - module to convert standard 4 columns output to bed file format and filtered by given motif length. - output bed file is in tab separated format - reference_id ref_start ref_end query_id matching_length forward/reverse query_start query_end sizeof_query - -input: - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - mummerfile: - type: file - description: mummerfile file - pattern: "*.*" - -output: - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - bedfile: - type: file - description: bed file output of mummer2bed - pattern: "*.bed" - - versions: - type: file - description: File containing software versions - pattern: "versions.yml" - -authors: - - "@yumisims" diff --git a/modules/sanger-tol/nf-core-modules/selfcomp/splitfasta/main.nf b/modules/sanger-tol/nf-core-modules/selfcomp/splitfasta/main.nf deleted file mode 100644 index 8c0761a1..00000000 --- a/modules/sanger-tol/nf-core-modules/selfcomp/splitfasta/main.nf +++ /dev/null @@ -1,35 +0,0 @@ -process SELFCOMP_SPLITFASTA { - tag "$meta.id" - label 'process_medium' - - def version = '0.001-c3' - - if (params.enable_conda) { - exit 1, "Conda environments cannot be used when using the splitfasta process. Please use docker or singularity containers." - } - container "quay.io/sanger-tol/splitfasta:${version}" - - input: - tuple val(meta), path(fasta) - - output: - tuple val(meta), path("*.fa"), emit: fa - path("*.agp") , emit: agp - path "versions.yml" , emit: versions - - when: - task.ext.when == null || task.ext.when - - script: - def args = task.ext.args ?: '' - def prefix = task.ext.prefix ?: "${meta.id}" - """ - split_genomes_for_ensembl.pl $fasta ${prefix}_split.fa ${prefix}_split.agp - - cat <<-END_VERSIONS > versions.yml - "${task.process}": - selfcomp_splitfasta: ${version} - END_VERSIONS - """ -} - diff --git a/modules/sanger-tol/nf-core-modules/selfcomp/splitfasta/meta.yml b/modules/sanger-tol/nf-core-modules/selfcomp/splitfasta/meta.yml deleted file mode 100644 index b3832eba..00000000 --- a/modules/sanger-tol/nf-core-modules/selfcomp/splitfasta/meta.yml +++ /dev/null @@ -1,38 +0,0 @@ -name: "selfcomp_splitfasta" -description: Script to split fasta into 500kb -keywords: - - fasta - - split -tools: - - "selfcomp": - licence: "sanger" -input: - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - fasta: - type: file - description: FASTA assembly file - pattern: "*.{fasta,fasta.gz,fa,fa.gz,fna,fna.gz}" -output: - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - versions: - type: file - description: File containing software versions - pattern: "versions.yml" - - split_fasta: - type: file - description: FASTA assembly file - pattern: "*.{fasta,fasta.gz,fa,fa.gz,fna,fna.gz}" - - split_agp: - type: file - description: File describing assembly of a larger sequence object from smaller ones. - pattern: "*.{agp}" -authors: - - "@weaglesBio" diff --git a/nextflow.config b/nextflow.config old mode 100644 new mode 100755 index 3bc5c861..d8756676 --- a/nextflow.config +++ b/nextflow.config @@ -1,6 +1,6 @@ /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - nf-core/treeval Nextflow config file + sanger-tol/treeval Nextflow config file ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Default config options for all compute environments ---------------------------------------------------------------------------------------- @@ -11,25 +11,23 @@ params { // Boilerplate options input = null - genome = null - igenomes_base = null - igenomes_ignore = null - outdir = "./gene_alignment_results" + outdir = "./results" tracedir = "${params.outdir}/pipeline_info" publish_dir_mode = 'copy' email = null email_on_fail = null plaintext_email = false monochrome_logs = false + hook_url = null help = false + version = false validate_params = true show_hidden_params = false - schema_ignore_params = 'genomes,genome,igenomes_base,igenomes_ignore' - enable_conda = true + schema_ignore_params = 'genomes' // Config options custom_config_version = 'master' - custom_config_base = "https://raw.githubusercontent.com/nf-core/configs/${custom_config_version}" + custom_config_base = "https://raw.githubusercontent.com/nf-core/configs/${params.custom_config_version}" config_profile_description = null config_profile_contact = null config_profile_url = null @@ -45,13 +43,6 @@ params { // Load base.config by default for all pipelines includeConfig 'conf/base.config' -// Load nf-core custom profiles from different Institutions -try { - includeConfig "${params.custom_config_base}/conf/sanger.config" -} catch (Exception e) { - System.err.println("WARNING: Could not load nf-core/config profiles: ${params.custom_config_base}/nfcore_custom.config") -} - // Load nf-core custom profiles from different Institutions try { includeConfig "${params.custom_config_base}/nfcore_custom.config" @@ -59,7 +50,7 @@ try { System.err.println("WARNING: Could not load nf-core/config profiles: ${params.custom_config_base}/nfcore_custom.config") } -// Load nf-core/treeval custom profiles from different institutions. +// Load sanger-tol/treeval custom profiles from different institutions. // Warning: Uncomment only if a pipeline-specific instititutional config already exists on nf-core/configs! // try { // includeConfig "${params.custom_config_base}/pipeline/treeval.config" @@ -69,59 +60,104 @@ try { profiles { - debug { process.beforeScript = 'echo $HOSTNAME' } + cleanup { cleanup = true } + debug { + dumpHashes = true + process.beforeScript = 'echo $HOSTNAME' + cleanup = false + } conda { - params.enable_conda = true + conda.enabled = true docker.enabled = false - singularity.enabled = true + singularity.enabled = false podman.enabled = false shifter.enabled = false charliecloud.enabled = false + apptainer.enabled = false + } + mamba { + conda.enabled = true + conda.useMamba = true + docker.enabled = false + singularity.enabled = false + podman.enabled = false + shifter.enabled = false + charliecloud.enabled = false + apptainer.enabled = false } docker { docker.enabled = true + docker.registry = 'quay.io' docker.userEmulation = true + conda.enabled = false singularity.enabled = false podman.enabled = false shifter.enabled = false charliecloud.enabled = false + apptainer.enabled = false + } + arm { + docker.runOptions = '-u $(id -u):$(id -g) --platform=linux/amd64' } singularity { - params.enable_conda = false singularity.enabled = true singularity.autoMounts = true + conda.enabled = false docker.enabled = false podman.enabled = false shifter.enabled = false charliecloud.enabled = false + apptainer.enabled = false } podman { podman.enabled = true + podman.registry = 'quay.io' + conda.enabled = false docker.enabled = false singularity.enabled = false shifter.enabled = false charliecloud.enabled = false + apptainer.enabled = false } shifter { shifter.enabled = true + conda.enabled = false docker.enabled = false singularity.enabled = false podman.enabled = false charliecloud.enabled = false + apptainer.enabled = false } charliecloud { charliecloud.enabled = true + conda.enabled = false + docker.enabled = false + singularity.enabled = false + podman.enabled = false + shifter.enabled = false + apptainer.enabled = false + } + apptainer { + apptainer.enabled = true + conda.enabled = false docker.enabled = false singularity.enabled = false podman.enabled = false shifter.enabled = false + charliecloud.enabled = false } - test { includeConfig 'conf/test.config' } - test_full { includeConfig 'conf/test_full.config' } - test_genealignment { includeConfig 'conf/test_genealignment.config'} - test_selfcomp { includeConfig 'conf/test_selfcomp.config'} + gitpod { + executor.name = 'local' + executor.cpus = 16 + executor.memory = 60.GB + } + + test { includeConfig 'conf/test.config' } + test_github { includeConfig 'conf/test_github.config' } + test_full { includeConfig 'conf/test_full.config' } } + // Export these variables to prevent local Python/R libraries from conflicting with those in the container // The JULIA depot path has been adjusted to a fixed path `/usr/local/share/julia` that needs to be used for packages in the container. // See https://apeltzer.github.io/post/03-julia-lang-nextflow/ for details on that. Once we have a common agreement on where to keep Julia packages, this is adjustable. @@ -137,6 +173,7 @@ env { process.shell = ['/bin/bash', '-euo', 'pipefail'] def trace_timestamp = new java.util.Date().format( 'yyyy-MM-dd_HH-mm-ss') +params.trace_timestamp = trace_timestamp timeline { enabled = true file = "${params.tracedir}/execution_timeline_${trace_timestamp}.html" @@ -147,7 +184,8 @@ report { } trace { enabled = true - file = "${params.tracedir}/execution_trace_${trace_timestamp}.txt" + file = "${params.tracedir}/pipeline_execution_${trace_timestamp}.txt" + fields = 'name,status,module,cpus,memory,attempt,realtime,%cpu,%mem,peak_rss' } dag { enabled = true @@ -155,13 +193,14 @@ dag { } manifest { - name = 'nf-core/treeval' - author = 'Yumi Sims, Damon-Lee Pointon, William Eagles' - homePage = 'https://github.com/nf-core/treeval' - description = 'A pipeline to generate jBrowse compatible datafiles for genome curation' + name = 'sanger-tol/treeval' + author = """@DLBPointon, @yumisims, @weaglesBio, @priyanka-surana, @muffato, @mcshane""" + homePage = 'https://github.com/sanger-tol/treeval' + description = """A pipeline to generate supplemental data for genome curation""" mainScript = 'main.nf' - nextflowVersion = '!>=21.10.3' - version = '1.0dev' + nextflowVersion = '!>=22.10.1' + version = '1.0.0' + doi = '' } // Load modules.config for DSL2 module specific options diff --git a/nextflow_schema.json b/nextflow_schema.json old mode 100644 new mode 100755 index 8c2528d9..f98570a5 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -1,8 +1,8 @@ { "$schema": "http://json-schema.org/draft-07/schema", - "$id": "https://raw.githubusercontent.com/nf-core/treeval/master/nextflow_schema.json", - "title": "nf-core/treeval pipeline parameters", - "description": "A pipeline to generate jBrowse compatible datafiles for genome curation", + "$id": "https://raw.githubusercontent.com/sanger-tol/treeval/master/nextflow_schema.json", + "title": "sanger-tol/treeval pipeline parameters", + "description": "A pipeline to generate supplemental data for genome curation", "type": "object", "definitions": { "input_output_options": { @@ -34,35 +34,12 @@ "fa_icon": "fas fa-envelope", "help_text": "Set this parameter to your e-mail address to get a summary e-mail with details of the run sent to you when the workflow exits. If set in your user config file (`~/.nextflow/config`) then you don't need to specify this on the command line for every run.", "pattern": "^([a-zA-Z0-9_\\-\\.]+)@([a-zA-Z0-9_\\-\\.]+)\\.([a-zA-Z]{2,5})$" - } - } - }, - "reference_genome_options": { - "title": "Reference genome options", - "type": "object", - "fa_icon": "fas fa-dna", - "description": "Reference genome related files and options required for the workflow.", - "properties": { - "genome": { - "type": "string", - "description": "Name of iGenomes reference.", - "fa_icon": "fas fa-book", - "help_text": "If using a reference genome configured in the pipeline using iGenomes, use this parameter to give the ID for the reference. This is then used to build the full paths for all required reference genome files e.g. `--genome GRCh38`. \n\nSee the [nf-core website docs](https://nf-co.re/usage/reference_genomes) for more details." }, - "igenomes_base": { + "trace_timestamp": { "type": "string", - "format": "directory-path", - "description": "Directory / URL base for iGenomes references.", - "default": "s3://ngi-igenomes/igenomes", - "fa_icon": "fas fa-cloud-download-alt", - "hidden": true - }, - "igenomes_ignore": { - "type": "boolean", - "description": "Do not load the iGenomes reference config.", - "fa_icon": "fas fa-ban", - "hidden": true, - "help_text": "Do not load `igenomes.config` when running the pipeline. You may choose this option if you observe clashes between custom parameters and those supplied in `igenomes.config`." + "description": "Not to be used, this passes data from the config into the pipeline", + "fa_icon": "fas fa-lock", + "help_text": "Don't use this param, required for TreeValProjects Summary functions" } } }, @@ -162,6 +139,12 @@ "fa_icon": "fas fa-question-circle", "hidden": true }, + "version": { + "type": "boolean", + "description": "Display version and exit.", + "fa_icon": "fas fa-question-circle", + "hidden": true + }, "publish_dir_mode": { "type": "string", "default": "copy", @@ -191,10 +174,17 @@ "fa_icon": "fas fa-palette", "hidden": true }, + "hook_url": { + "type": "string", + "description": "Incoming hook URL for messaging service", + "fa_icon": "fas fa-people-group", + "help_text": "Incoming hook URL for messaging service. Currently, MS Teams and Slack are supported.", + "hidden": true + }, "tracedir": { "type": "string", "description": "Directory to keep pipeline Nextflow logs and reports.", - "default": "${params.outdir}/pipeline_info", + "default": "${params.outdir}/treeval_info", "fa_icon": "fas fa-cogs", "hidden": true }, @@ -211,12 +201,6 @@ "description": "Show all params when using `--help`", "hidden": true, "help_text": "By default, parameters set as _hidden_ in the schema are not shown on the command line when a user runs with `--help`. Specifying this option will tell the pipeline to show all parameters." - }, - "enable_conda": { - "type": "boolean", - "description": "Run this workflow with Conda. You can also use '-profile conda' instead of providing this parameter.", - "hidden": true, - "fa_icon": "fas fa-bacon" } } } @@ -225,9 +209,6 @@ { "$ref": "#/definitions/input_output_options" }, - { - "$ref": "#/definitions/reference_genome_options" - }, { "$ref": "#/definitions/institutional_config_options" }, diff --git a/pipeline_template.yml b/pipeline_template.yml new file mode 100755 index 00000000..0aa7398f --- /dev/null +++ b/pipeline_template.yml @@ -0,0 +1,3 @@ +prefix: sanger-tol +skip: + - igenomes diff --git a/pyproject.toml b/pyproject.toml new file mode 100755 index 00000000..6102010c --- /dev/null +++ b/pyproject.toml @@ -0,0 +1,10 @@ +# Config file for Python. Mostly used to configure linting of bin/check_samplesheet.py with Black. +# Should be kept the same as nf-core/tools to avoid fighting with template synchronisation. +[tool.black] +line-length = 120 +target_version = ["py37", "py38", "py39", "py310" ] + +[tool.isort] +profile = "black" +known_first_party = ["nf_core"] +multi_line_output = 3 diff --git a/subworkflows/local/ancestral_gene.nf b/subworkflows/local/ancestral_gene.nf new file mode 100755 index 00000000..2bb6dd5d --- /dev/null +++ b/subworkflows/local/ancestral_gene.nf @@ -0,0 +1,85 @@ +#!/usr/bin/env nextflow + +// +// MODULE IMPORT BLOCK +// +include { EXTRACT_ANCESTRAL } from '../../modules/local/extract_ancestral' +include { ASSIGN_ANCESTRAL } from '../../modules/local/assign_ancestral' +include { BEDTOOLS_SORT } from '../../modules/nf-core/bedtools/sort/main' +include { UCSC_BEDTOBIGBED } from '../../modules/nf-core/ucsc/bedtobigbed/main' + +workflow ANCESTRAL_GENE { + take: + busco_dir // Channel: [val(meta),/path/to/busco/output/dir] + dot_genome // Channel: [val(meta), [ datafile ]] + buscogene_as // Channel val(dot_as location) + ancestral_table // Channel val(ancestral_table location) + + main: + ch_versions = Channel.empty() + + ch_grab = GrabFiles(busco_dir) + + // + // MODULE: EXTRACTS ANCESTRALLY LINKED BUSCO GENES FROM FULL TABLE + // + EXTRACT_ANCESTRAL( + ch_grab, + ancestral_table + ) + ch_versions = ch_versions.mix(EXTRACT_ANCESTRAL.out.versions) + + // + // LOGIC: STRIP OUT METADATA + // + ch_grab + .map { meta, fulltable + -> fulltable + } + .set { assignanc_input } + + // + // MODULE: ASSIGN EXTRACTED GENES TO ANCESTRAL GROUPS + // + ASSIGN_ANCESTRAL( + EXTRACT_ANCESTRAL.out.comp_location, + assignanc_input + ) + ch_versions = ch_versions.mix(EXTRACT_ANCESTRAL.out.versions) + + // + // MODULES: SORT THE BED FILE + // + BEDTOOLS_SORT( + ASSIGN_ANCESTRAL.out.assigned_bed, + [] + ) + ch_versions = ch_versions.mix(BEDTOOLS_SORT.out.versions) + + // + // MODULES: CONVERT BED TO INDEXED BIGBED + // + UCSC_BEDTOBIGBED( + BEDTOOLS_SORT.out.sorted, + dot_genome.map{ it[1] }, // Pull file from tuple(meta, file) + buscogene_as + ) + ch_versions = ch_versions.mix(UCSC_BEDTOBIGBED.out.versions) + + emit: + ch_ancestral_bigbed = UCSC_BEDTOBIGBED.out.bigbed + versions = ch_versions.ifEmpty(null) +} +process GrabFiles { + + tag "${meta.id}" + executor 'local' + + input: + tuple val(meta), path("in") + + output: + tuple val(meta), path("in/*/*/full_table.tsv") + + "true" +} diff --git a/subworkflows/local/busco_annotation.nf b/subworkflows/local/busco_annotation.nf new file mode 100755 index 00000000..e527f741 --- /dev/null +++ b/subworkflows/local/busco_annotation.nf @@ -0,0 +1,128 @@ +#!/usr/bin/env nextflow + +// This subworkflow takes an input fasta sequence and csv style list of organisms to return +// bigbed files containing alignment data between the input fasta and csv style organism names. +// Input - Assembled genomic fasta file +// Output - A BigBed file per datatype per organism entered via csv style in the yaml. + +// +// MODULE IMPORT BLOCK +// +include { BUSCO } from '../../modules/nf-core/busco/main' +include { SAMTOOLS_FAIDX } from '../../modules/nf-core/samtools/faidx/main' +include { UCSC_BEDTOBIGBED } from '../../modules/nf-core/ucsc/bedtobigbed/main' +include { BEDTOOLS_SORT } from '../../modules/nf-core/bedtools/sort/main' +include { EXTRACT_BUSCOGENE } from '../../modules/local/extract_buscogene' + +// +// SUBWORKFLOW IMPORT +// +include { ANCESTRAL_GENE } from './ancestral_gene' + +workflow BUSCO_ANNOTATION { + take: + dot_genome // channel: [val(meta), [ datafile ]] + reference_tuple // channel: [val(meta), [ datafile ]] + assembly_classT // channel: val(class) + lineageinfo // channel: val(lineage_db) + lineagespath // channel: val(/path/to/buscoDB) + buscogene_as // channel: val(dot_as location) + ancestral_table // channel: val(ancestral_table location) + + main: + ch_versions = Channel.empty() + + // + // MODULE: RUN BUSCO TO OBTAIN FULL_TABLE.CSV + // EMITS FULL_TABLE.CSV + // + BUSCO ( + reference_tuple, + lineageinfo, + lineagespath, + [] + ) + ch_versions = ch_versions.mix( BUSCO.out.versions.first() ) + + ch_grab = GrabFiles( BUSCO.out.busco_dir ) + + // + // MODULE: EXTRACT THE BUSCO GENES FOUND IN REFERENCE + // + EXTRACT_BUSCOGENE ( + ch_grab + ) + ch_versions = ch_versions.mix( EXTRACT_BUSCOGENE.out.versions ) + + // + // MODULE: SORT THE EXTRACTED BUSCO GENE + // + BEDTOOLS_SORT( + EXTRACT_BUSCOGENE.out.genefile, + [] + ) + ch_versions = ch_versions.mix( BEDTOOLS_SORT.out.versions ) + + // + // MODULE: CONVERT THE BED TO BIGBED + // + UCSC_BEDTOBIGBED( + BEDTOOLS_SORT.out.sorted, + dot_genome.map{it[1]}, // Gets file from tuple (meta, file) + buscogene_as + ) + ch_versions = ch_versions.mix( UCSC_BEDTOBIGBED.out.versions ) + + // + // LOGIC: AGGREGATE DATA AND SORT BRANCH ON CLASS + // + lineageinfo + .combine( BUSCO.out.busco_dir ) + .combine( ancestral_table ) + .branch { + lep: it[0].split('_')[0] == "lepidoptera" + general: it[0].split('_')[0] != "lepidoptera" + } + .set{ ch_busco_data } + + // + // LOGIC: BUILD NEW INPUT CHANNEL FOR ANCESTRAL ID + // + ch_busco_data + .lep + .multiMap { lineage, meta, busco_dir, ancestral_table -> + busco_dir: tuple( meta, busco_dir ) + atable: ancestral_table + } + .set{ ch_busco_lep_data } + + // + // SUBWORKFLOW: RUN ANCESTRAL BUSCO ID (ONLY AVAILABLE FOR LEPIDOPTERA) + // + ANCESTRAL_GENE ( + ch_busco_lep_data.busco_dir, + dot_genome, + buscogene_as, + ch_busco_lep_data.atable + ) + ch_versions = ch_versions.mix( ANCESTRAL_GENE.out.versions ) + + emit: + ch_buscogene_bigbed = UCSC_BEDTOBIGBED.out.bigbed + ch_ancestral_bigbed = ANCESTRAL_GENE.out.ch_ancestral_bigbed + versions = ch_versions + +} +process GrabFiles { + + tag "${meta.id}" + executor 'local' + + input: + tuple val(meta), path("in") + + output: + tuple val(meta), path("in/*/*/full_table.tsv") + + "true" +} diff --git a/subworkflows/local/gap_finder.nf b/subworkflows/local/gap_finder.nf new file mode 100755 index 00000000..3c51e530 --- /dev/null +++ b/subworkflows/local/gap_finder.nf @@ -0,0 +1,59 @@ +#!/usr/bin/env nextflow + +// +// MODULE IMPORT BLOCK +// +include { SEQTK_CUTN } from '../../modules/nf-core/seqtk/cutn/main' +include { GAP_LENGTH } from '../../modules/local/gap_length' +include { TABIX_BGZIPTABIX } from '../../modules/nf-core/tabix/bgziptabix/main' + +workflow GAP_FINDER { + take: + reference_tuple // Channel [ val(meta), path(fasta) ] + max_scaff_size // val(size of largest scaffold in bp) + + main: + ch_versions = Channel.empty() + + // + // MODULE: GENERATES A GAP SUMMARY FILE + // + SEQTK_CUTN ( + reference_tuple + ) + ch_versions = ch_versions.mix( SEQTK_CUTN.out.versions ) + + // + // MODULE: ADD THE LENGTH OF GAP TO BED FILE - INPUT FOR PRETEXT MODULE + // + GAP_LENGTH ( + SEQTK_CUTN.out.bed + ) + ch_versions = ch_versions.mix( GAP_LENGTH.out.versions ) + + // + // LOGIC: Adding the largest scaffold size to the meta data so it can be used in the modules.config + // + SEQTK_CUTN.out.bed + .combine(max_scaff_size) + .map {meta, row, scaff -> + tuple([ id : meta.id, + max_scaff : scaff >= 500000000 ? 'csi': '' + ], + file(row) + )} + .set { modified_bed_ch } + + // + // MODULE: BGZIP AND TABIX THE GAP FILE + // + TABIX_BGZIPTABIX ( + modified_bed_ch + ) + ch_versions = ch_versions.mix( TABIX_BGZIPTABIX.out.versions ) + + emit: + gap_file = GAP_LENGTH.out.bedgraph + gap_tabix = TABIX_BGZIPTABIX.out.gz_csi + versions = ch_versions.ifEmpty(null) +} diff --git a/subworkflows/local/gene_alignment.nf b/subworkflows/local/gene_alignment.nf old mode 100644 new mode 100755 index e805b984..cec8f2b9 --- a/subworkflows/local/gene_alignment.nf +++ b/subworkflows/local/gene_alignment.nf @@ -5,43 +5,52 @@ // Input - Assembled genomic fasta file // Output - A BigBed file per datatype per organism entered via csv style in the yaml. -nextflow.enable.dsl=2 - -// MODULE IMPORT -include { CSV_GENERATOR } from '../../modules/local/csv_generator' -include { PEP_ALIGNMENTS } from './pep_alignments' -include { NUC_ALIGNMENTS } from './nuc_alignments' +// +// SUBWORKFLOW IMPORT BLOCK +// +include { PEP_ALIGNMENTS } from './pep_alignments' +include { NUC_ALIGNMENTS as GEN_ALIGNMENTS } from './nuc_alignments' +include { NUC_ALIGNMENTS as RNA_ALIGNMENTS } from './nuc_alignments' +include { NUC_ALIGNMENTS as CDS_ALIGNMENTS } from './nuc_alignments' workflow GENE_ALIGNMENT { - take: - dot_genome // Channel: [val(meta), [ datafile ]] - reference_tuple - assembly_classT - alignment_datadir - alignment_genesets - alignment_common - intron_size - as_files + dot_genome // Channel [ val(meta), path(file) ] + reference_tuple // Channel [ val(meta), path(file) ] + reference_index // Channel [ val(meta), path(file) ] + max_scaff_size // Channel val(size of largest scaffold in bp) + assembly_classT // Channel val(clade_id) + alignment_datadir // Channel val(geneset_dir) + alignment_genesets // Channel val(geneset_id) + alignment_common // Channel val(common_name) // Not yet in use + intron_size // Channel val(50k) + as_files // Channel [ val(meta), path(file) ] main: ch_versions = Channel.empty() + // + // LOGIC: TAKES A SINGLE LIKE CSV STRING AND CONVERTS TO LIST OF VALUES + // LIST IS MERGED WITH DATA_DIRECTORY AND ORGANISM_CLASS + // ch_data = alignment_genesets .splitCsv() .flatten() + // + // LOGIC: COMBINE CH_DATA WITH ALIGNMENT_DIR AND ASSEMBLY_CLASS + // CONVERTS THESE VALUES INTO A PATH AND DOWNLOADS IT, THEN TURNS IT TO A TUPLE OF + // [ [ META.ID, META.TYPE, META.ORG ], GENE_ALIGNMENT_FILE ] + // DATA IS THEN BRANCHED BASED ON META.TYPE TO THE APPROPRIATE + // SUBWORKFLOW + // ch_data .combine( alignment_datadir ) .combine( assembly_classT ) - .set { csv_input } - - CSV_GENERATOR ( csv_input.map { it[0] }, - csv_input.map { it[1] }, - csv_input.map { it[2] } ) - - // Unique ID will be the org+chunk (size of the fasta for a dtype). - CSV_GENERATOR.out.csv_path + .map { + ch_org, data_dir, classT -> + file("${data_dir}${classT}/csv_data/${ch_org}-data.csv") + } .splitCsv( header: true, sep:',') .map( row -> tuple([ org: row.org, @@ -52,23 +61,59 @@ workflow GENE_ALIGNMENT { )) .branch { pep: it[0].type == 'pep' - nuc: it[0].type != 'pep' + gen: it[0].type == 'cdna' + rna: it[0].type == 'rna' + cds: it[0].type == 'cds' } .set {ch_alignment_data} pep_files = ch_alignment_data.pep.collect() - nuc_files = ch_alignment_data.nuc.collect() + gen_files = ch_alignment_data.gen.collect() + rna_files = ch_alignment_data.rna.collect() + cds_files = ch_alignment_data.cds.collect() + // + // SUBWORKFLOW: GENERATES GENE ALIGNMENTS FOR PEPTIDE DATA, EMITS GFF AND TBI + // PEP_ALIGNMENTS ( reference_tuple, - pep_files ) - - NUC_ALIGNMENTS ( reference_tuple, - nuc_files, + pep_files, + max_scaff_size + ) + ch_versions = ch_versions.mix(PEP_ALIGNMENTS.out.versions) + + + // + // SUBWORKFLOW: GENERATES GENE ALIGNMENTS FOR RNA, NUCLEAR AND COMPLEMENT_DNA DATA, EMITS BIGBED + // + GEN_ALIGNMENTS ( reference_tuple, + reference_index, + gen_files, + dot_genome, + intron_size + ) + ch_versions = ch_versions.mix(GEN_ALIGNMENTS.out.versions) + + CDS_ALIGNMENTS ( reference_tuple, + reference_index, + cds_files, + dot_genome, + intron_size + ) + ch_versions = ch_versions.mix(CDS_ALIGNMENTS.out.versions) + + RNA_ALIGNMENTS ( reference_tuple, + reference_index, + rna_files, dot_genome, - intron_size ) + intron_size + ) + ch_versions = ch_versions.mix(RNA_ALIGNMENTS.out.versions) emit: - pep_gff = PEP_ALIGNMENTS.out.tbi_gff - gff_file = PEP_ALIGNMENTS.out.gff_file - nuc_bb_files = NUC_ALIGNMENTS.out.nuc_alignment -} \ No newline at end of file + pep_gff = PEP_ALIGNMENTS.out.tbi_gff + gff_file = PEP_ALIGNMENTS.out.gff_file + gen_bb_files = GEN_ALIGNMENTS.out.nuc_alignment + rna_bb_files = RNA_ALIGNMENTS.out.nuc_alignment + cds_bb_files = CDS_ALIGNMENTS.out.nuc_alignment + versions = ch_versions.ifEmpty(null) +} diff --git a/subworkflows/local/generate_genome.nf b/subworkflows/local/generate_genome.nf old mode 100644 new mode 100755 index 68667fb2..7cb0065a --- a/subworkflows/local/generate_genome.nf +++ b/subworkflows/local/generate_genome.nf @@ -1,30 +1,62 @@ -include { SAMTOOLS_FAIDX } from '../../modules/nf-core/modules/samtools/faidx/main' -include { GENERATE_GENOME_FILE } from '../../modules/local/generate_genome_file' +#!/usr/bin/env nextflow + +// +// MODULE IMPORT BLOCK +// +include { SAMTOOLS_FAIDX } from '../../modules/nf-core/samtools/faidx/main' +include { CUSTOM_GETCHROMSIZES } from '../../modules/nf-core/custom/getchromsizes/main' +include { GNU_SORT } from '../../modules/nf-core/gnu/sort' +include { GET_LARGEST_SCAFF } from '../../modules/local/get_largest_scaff' workflow GENERATE_GENOME { take: - assembly_id - reference_file + assembly_id // Channel val(assembly_id) + reference_file // Channel path(file) main: ch_versions = Channel.empty() + // + // LOGIC: GENERATES A REFERENCE DATA TUPLE + // reference_file .combine( assembly_id ) - .map { it -> - tuple ([id: it[1]], - it[0]) + .map { file, sample_id -> + tuple ([id: sample_id], + file) } - .set { to_samtools } + .set { to_chromsize } - SAMTOOLS_FAIDX ( to_samtools ) - ch_versions = ch_versions.mix(SAMTOOLS_FAIDX.out.versions) + // + // MODULE: GENERATE INDEX OF REFERENCE + // EMITS REFERENCE INDEX FILE MODIFIED FOR SCAFF SIZES + // + CUSTOM_GETCHROMSIZES ( + to_chromsize, + "genome" + ) + ch_versions = ch_versions.mix( CUSTOM_GETCHROMSIZES.out.versions ) - GENERATE_GENOME_FILE ( SAMTOOLS_FAIDX.out.fai ) - - emit: - dot_genome = GENERATE_GENOME_FILE.out.dotgenome - reference_tuple = to_samtools + // + // MODULE: SORT CHROM SIZES BY CHOM SIZE NOT NAME + // + GNU_SORT ( + CUSTOM_GETCHROMSIZES.out.sizes + ) + // + // MODULE: Cut out the largest scaffold size and use as comparator against 512MB + // This is the cut off for TABIX using tbi indexes + // + GET_LARGEST_SCAFF ( + CUSTOM_GETCHROMSIZES.out.sizes + ) + ch_versions = ch_versions.mix( GET_LARGEST_SCAFF.out.versions ) + + emit: + max_scaff_size = GET_LARGEST_SCAFF.out.scaff_size.toInteger() + dot_genome = GNU_SORT.out.sorted + ref_index = CUSTOM_GETCHROMSIZES.out.fai + reference_tuple = to_chromsize versions = ch_versions.ifEmpty(null) } diff --git a/subworkflows/local/hic_mapping.nf b/subworkflows/local/hic_mapping.nf new file mode 100755 index 00000000..0f73ee5b --- /dev/null +++ b/subworkflows/local/hic_mapping.nf @@ -0,0 +1,319 @@ +#!/usr/bin/env nextflow + +// This subworkflow takes an input fasta sequence and csv style list of hic cram file to return +// alignment files including .mcool, pretext and .hic. +// Input - Assembled genomic fasta file, cram file directory +// Output - .mcool, .pretext, .hic + +// +// MODULE IMPORT BLOCK +// +include { BWAMEM2_INDEX } from '../../modules/nf-core/bwamem2/index/main' +include { COOLER_CLOAD } from '../../modules/nf-core/cooler/cload/main' +include { COOLER_ZOOMIFY } from '../../modules/nf-core/cooler/zoomify/main' +include { PRETEXTMAP as PRETEXTMAP_STANDRD } from '../../modules/nf-core/pretextmap/main' +include { PRETEXTMAP as PRETEXTMAP_HIGHRES } from '../../modules/nf-core/pretextmap/main' +include { PRETEXTSNAPSHOT as SNAPSHOT_SRES } from '../../modules/nf-core/pretextsnapshot/main' +include { PRETEXTSNAPSHOT as SNAPSHOT_HRES } from '../../modules/nf-core/pretextsnapshot/main' +include { SAMTOOLS_MARKDUP } from '../../modules/nf-core/samtools/markdup/main' +include { SAMTOOLS_MERGE } from '../../modules/nf-core/samtools/merge/main' +include { BAMTOBED_SORT } from '../../modules/local/bamtobed_sort.nf' +include { GENERATE_CRAM_CSV } from '../../modules/local/generate_cram_csv' +include { CRAM_FILTER_ALIGN_BWAMEM2_FIXMATE_SORT } from '../../modules/local/cram_filter_align_bwamem2_fixmate_sort' +include { JUICER_TOOLS_PRE } from '../../modules/local/juicer_tools_pre' +include { GET_PAIRED_CONTACT_BED } from '../../modules/local/get_paired_contact_bed' + + +workflow HIC_MAPPING { + take: + reference_tuple // Channel [ val(meta), path(file) ] + reference_index // Channel [ val(meta), path(file) ] + dot_genome // Channel [ val(meta), [ datafile ]] + hic_reads_path // Channel [ val(meta), path(directory) ] + assembly_id // Channel val( id ) + workflow_setting // val( {RAPID | FULL } ) + + main: + ch_versions = Channel.empty() + + // COMMENT: 1000bp BIN SIZE INTERVALS FOR CLOAD + ch_cool_bin = Channel.of( 1000 ) + + // + // MODULE: Indexing on reference output the folder of indexing files + // + BWAMEM2_INDEX ( + reference_tuple + ) + ch_versions = ch_versions.mix( BWAMEM2_INDEX.out.versions ) + + // + // LOGIC: make channel of hic reads as input for GENERATE_CRAM_CSV + // + reference_tuple + .combine( hic_reads_path ) + .map { meta, ref, hic_reads_path -> + tuple( + [ id: meta.id, single_end: true], + hic_reads_path + ) + } + .set { get_reads_input } + + // + // MODULE: generate a cram csv file containing the required parametres for CRAM_FILTER_ALIGN_BWAMEM2_FIXMATE_SORT + // + GENERATE_CRAM_CSV ( + get_reads_input + ) + ch_versions = ch_versions.mix( GENERATE_CRAM_CSV.out.versions ) + + // + // LOGIC: organise all parametres into a channel for CRAM_FILTER_ALIGN_BWAMEM2_FIXMATE_SORT + // + GENERATE_CRAM_CSV.out.csv + .splitCsv() + .combine (reference_tuple) + .combine (BWAMEM2_INDEX.out.index) + .map{ cram_id, cram_info, ref_id, ref_dir, bwa_id, bwa_path -> + tuple([ + id: cram_id.id + ], + file(cram_info[0]), + cram_info[1], + cram_info[2], + cram_info[3], + cram_info[4], + cram_info[5], + cram_info[6], + bwa_path.toString() + '/' + ref_dir.toString().split('/')[-1] + ) + } + .set { ch_filtering_input } + + // + // MODULE: parallel proccessing bwa-mem2 alignment by given interval of containers from cram files + // + CRAM_FILTER_ALIGN_BWAMEM2_FIXMATE_SORT ( + ch_filtering_input + ) + ch_versions = ch_versions.mix( CRAM_FILTER_ALIGN_BWAMEM2_FIXMATE_SORT.out.versions ) + + // + // LOGIC: PREPARING BAMS FOR MERGE + // + CRAM_FILTER_ALIGN_BWAMEM2_FIXMATE_SORT.out.mappedbam + .map{ meta, file -> + tuple( file ) + } + .collect() + .map { file -> + tuple ( + [ + id: file[0].toString().split('/')[-1].split('_')[0] + '_' + file[0].toString().split('/')[-1].split('_')[1] + ], + file + ) + } + .set { collected_files_for_merge } + + // + // MODULE: MERGE POSITION SORTED BAM FILES AND MARK DUPLICATES + // + SAMTOOLS_MERGE ( + collected_files_for_merge, + reference_tuple, + reference_index + ) + ch_versions = ch_versions.mix ( SAMTOOLS_MERGE.out.versions.first() ) + + // + // LOGIC: PREPARING PRETEXT MAP INPUT + // + SAMTOOLS_MERGE.out.bam + .combine( reference_tuple ) + .multiMap { bam_meta, bam, ref_meta, ref_fa -> + input_bam: tuple( [ id: bam_meta.id, + sz: file( bam ).size() ], + bam + ) + reference: ref_fa + } + .set { pretext_input } + + // + // MODULE: GENERATE PRETEXT MAP FROM MAPPED BAM FOR LOW RES + // + PRETEXTMAP_STANDRD ( + pretext_input.input_bam, + pretext_input.reference + ) + ch_versions = ch_versions.mix( PRETEXTMAP_STANDRD.out.versions ) + + // + // LOGIC: HIRES IS TOO INTENSIVE FOR RUNNING IN GITHUB CI SO THIS STOPS IT RUNNING + // + if ( params.config_profile_name ) { + config_profile_name = params.config_profile_name + } else { + config_profile_name = 'Local' + } + + if ( !config_profile_name.contains('GitHub') ) { + // + // MODULE: GENERATE PRETEXT MAP FROM MAPPED BAM FOR HIGH RES + // + PRETEXTMAP_HIGHRES ( + pretext_input.input_bam, + pretext_input.reference + ) + ch_versions = ch_versions.mix( PRETEXTMAP_HIGHRES.out.versions ) + } + + // + // MODULE: GENERATE PNG FROM STANDARD PRETEXT + // + SNAPSHOT_SRES ( + PRETEXTMAP_STANDRD.out.pretext + ) + ch_versions = ch_versions.mix ( SNAPSHOT_SRES.out.versions ) + + // NOTE: CURRENTLY UNDER INVESTIGATION + // + // MODULE: GENERATE PNG FROM HIGHRES PRETEXT + // + // SNAPSHOT_HRES ( PRETEXTMAP_HIGHRES.out.pretext ) + // ch_versions = ch_versions.mix ( SNAPSHOT_HRES.out.versions ) + + // + // MODULE: MERGE POSITION SORTED BAM FILES AND MARK DUPLICATES + // + SAMTOOLS_MARKDUP ( + pretext_input.input_bam, + pretext_input.reference + ) + ch_versions = ch_versions.mix ( SAMTOOLS_MARKDUP.out.versions ) + + // + // MODULE: SAMTOOLS FILTER OUT DUPLICATE READS | BAMTOBED | SORT BED FILE + // + BAMTOBED_SORT( + SAMTOOLS_MARKDUP.out.bam + ) + ch_versions = ch_versions.mix( BAMTOBED_SORT.out.versions ) + + // + // MODULE: GENERATE CONTACT PAIRS + // + GET_PAIRED_CONTACT_BED( BAMTOBED_SORT.out.sorted_bed ) + ch_versions = ch_versions.mix( GET_PAIRED_CONTACT_BED.out.versions ) + + // + // LOGIC: SECTION ONLY NEEDED FOR TREEVAL VISUALISATION, NOT RAPID ANALYSIS + // + if (workflow_setting == 'FULL' && !config_profile_name.contains('GitHub')) { + // + // LOGIC: PREPARE JUICER TOOLS INPUT + // + GET_PAIRED_CONTACT_BED.out.bed + .combine( dot_genome ) + .multiMap { meta, paired_contacts, meta_my_genome, my_genome -> + paired : tuple([ id: meta.id, single_end: true], paired_contacts ) + genome : my_genome + id : meta.id + } + .set { ch_juicer_input } + + // + // MODULE: GENERATE HIC MAP, ONLY IS PIPELINE IS RUNNING ON ENTRY FULL + // + + JUICER_TOOLS_PRE( + ch_juicer_input.paired, + ch_juicer_input.genome, + ch_juicer_input.id + ) + ch_versions = ch_versions.mix( JUICER_TOOLS_PRE.out.versions ) + } + + // + // LOGIC: BIN CONTACT PAIRS + // + GET_PAIRED_CONTACT_BED.out.bed + .join( BAMTOBED_SORT.out.sorted_bed ) + .combine( ch_cool_bin ) + .set { ch_binned_pairs } + + // + // LOGIC: PREPARE COOLER INPUT + // + ch_binned_pairs + .combine(dot_genome) + .multiMap { meta, pairs, bed, cool_bin, meta_my_genome, my_genome -> + cooler_in : tuple ( meta, pairs, bed, cool_bin ) + genome_file : my_genome + } + .set { ch_cooler } + + // + // MODULE: GENERATE A MULTI-RESOLUTION COOLER FILE BY COARSENING + // + COOLER_CLOAD( + ch_cooler.cooler_in, + ch_cooler.genome_file + ) + ch_versions = ch_versions.mix(COOLER_CLOAD.out.versions) + + // + // LOGIC: REFACTOR CHANNEL FOR ZOOMIFY + // + COOLER_CLOAD.out.cool + .map{ meta, cools, cool_bin -> + [meta, cools] + } + .set{ch_cool} + + // + // MODULE: ZOOM COOL TO MCOOL + // + COOLER_ZOOMIFY(ch_cool) + ch_versions = ch_versions.mix(COOLER_ZOOMIFY.out.versions) + + // + // LOGIC: FOR REPORTING + // + + ch_cram_files = GrabFiles( get_reads_input ) + + ch_cram_files + .collect() + .map { meta, cram -> + tuple( [ id: 'cram', + sz: cram instanceof ArrayList ? cram.collect { it.size()} : cram.size() ], + cram + ) + } + .set { ch_reporting_cram } + + emit: + standrd_pretext = PRETEXTMAP_STANDRD.out.pretext + standrd_snpshot = SNAPSHOT_SRES.out.image + //highres_pretext = PRETEXTMAP_HIGHRES.out.pretext + //highres_snpshot = SNAPSHOT_HRES.out.image + mcool = COOLER_ZOOMIFY.out.mcool + ch_reporting = ch_reporting_cram.collect() + versions = ch_versions.ifEmpty(null) +} + +process GrabFiles { + tag "${meta.id}" + executor 'local' + + input: + tuple val(meta), path("in") + + output: + tuple val(meta), path("in/*.cram") + + "true" +} diff --git a/subworkflows/local/insilico_digest.nf b/subworkflows/local/insilico_digest.nf index 2c300e64..2e2989dc 100755 --- a/subworkflows/local/insilico_digest.nf +++ b/subworkflows/local/insilico_digest.nf @@ -4,86 +4,139 @@ // Input - genome fasta // Output - bigbed -include { MAKECMAP_FA2CMAPMULTICOLOR } from '../../modules/sanger-tol/nf-core-modules/makecmap/fa2cmapmulticolor/main' -include { MAKECMAP_RENAMECMAPIDS } from '../../modules/sanger-tol/nf-core-modules/makecmap/renamecmapids/main' -include { MAKECMAP_CMAP2BED } from '../../modules/sanger-tol/nf-core-modules/makecmap/cmap2bed/main' -include { UCSC_BEDTOBIGBED } from '../../modules/nf-core/modules/ucsc/bedtobigbed/main' +// +// MODULE IMPORT BLOCK +// +include { MAKECMAP_FA2CMAPMULTICOLOR } from '../../modules/local/makecmap_fa2cmapmulticolor' +include { MAKECMAP_RENAMECMAPIDS } from '../../modules/local/makecmap_renamecmapids' +include { MAKECMAP_CMAP2BED } from '../../modules/local/makecmap_cmap2bed' +include { UCSC_BEDTOBIGBED } from '../../modules/nf-core/ucsc/bedtobigbed/main' workflow INSILICO_DIGEST { take: - myid // channel val(sample_id) - sizefile // channel [id: sample_id], my.genome_file - sample // channel [id: sample_id], reference_file - ch_enzyme // channel val( "bspq1","bsss1","DLE1" ) - dot_as // channel val(dot_as location) + myid // Channel val(sample_id) + sizefile // Channel [ val(meta), path(my.genome_file) ] + sample // Channel [ val(meta), path(reference_file) ] + ch_enzyme // Channel val( "bspq1","bsss1","DLE1" ) + dot_as // Channel val(dot_as location) main: - ch_versions = Channel.empty() - - input_fasta = sample.map { data -> - tuple([ - id : data[0].id, - single_end : false - ], - file(data[1]) - )} + ch_versions = Channel.empty() + + // + // LOGIC: COMBINES REFERENCE TUPLE WITH ENZYME CHANNEL + // MULTIMAP INTO TWO CHANNELS SO THERE IS REFERENCE * ENZYME CHANNELS + // + sample + .map { meta, data -> + tuple( + [ id : meta.id, + single_end : false ], + file( data ) + ) + } + .set { input_fasta } input_fasta .combine(ch_enzyme) - .multiMap { data -> - fasta: tuple( data[0], - data[1] + .multiMap { meta, reference, enzyme_id -> + fasta : tuple( meta, + reference ) - enzyme: data[2] + enzyme : enzyme_id } - .set { fa2c_input } - - MAKECMAP_FA2CMAPMULTICOLOR ( fa2c_input.fasta, fa2c_input.enzyme ) - - ch_cmap = MAKECMAP_FA2CMAPMULTICOLOR.out.cmap - ch_cmapkey = MAKECMAP_FA2CMAPMULTICOLOR.out.cmapkey - ch_version = ch_versions.mix(MAKECMAP_FA2CMAPMULTICOLOR.out.versions) - - - ch_cmap_new = ch_cmap - .map{ meta, cfile -> tuple([ - id : cfile.toString().split('_')[-3] - ], cfile)} - - ch_cmapkey_new = ch_cmapkey - .map{ kfile -> tuple([ - id : kfile.toString().split('_')[-4] - ], kfile)} - - - ch_join = ch_cmap_new.join(ch_cmapkey_new) - .map { meta, cfile, kfile -> tuple ([ - meta, - cfile - ] , - kfile)} - - MAKECMAP_RENAMECMAPIDS ( ch_join.map { it[0] }, ch_join.map { it[1] } ) - ch_version = ch_versions.mix(MAKECMAP_RENAMECMAPIDS.out.versions) - - ch_renamedcmap = MAKECMAP_RENAMECMAPIDS.out.renamedcmap - - MAKECMAP_CMAP2BED ( ch_renamedcmap, ch_renamedcmap.map { it[0].id } ) - ch_version = ch_versions.mix(MAKECMAP_CMAP2BED.out.versions) - - ch_bedfile = MAKECMAP_CMAP2BED.out.bedfile - - combined_ch = ch_bedfile - .combine(sizefile) - .combine(dot_as) - - UCSC_BEDTOBIGBED ( combined_ch.map { [it[0], it[1]] }, - combined_ch.map { it[3] }, - combined_ch.map { it[4] }) - ch_version = ch_versions.mix(UCSC_BEDTOBIGBED.out.versions) + .set { fa2c_input } + + // + // MODULE: CONVERTS FASTA INTO A COLOUR-AWARE BIONANO CMAP FORMAT + // EMITS FILES CONTAINING INDEX_IDs AND ORIGINAL_GENOMIC_LOCATIONS + // + MAKECMAP_FA2CMAPMULTICOLOR ( + fa2c_input.fasta, + fa2c_input.enzyme + ) + ch_versions = ch_versions.mix(MAKECMAP_FA2CMAPMULTICOLOR.out.versions) + + // + // LOGIC: CREATES A TUPLE CONTAINING THE CMAP AND ORIGINAL GENOMIC LOCATIONS + // + MAKECMAP_FA2CMAPMULTICOLOR.out.cmap + .map{ meta, cfile -> + tuple( + [ id : cfile.toString().split('_')[-3] ], + cfile + ) + } + .set { ch_cmap_new } + + MAKECMAP_FA2CMAPMULTICOLOR.out.cmapkey + .map{ kfile -> + tuple( + [ id : kfile.toString().split('_')[-4] ], + kfile + ) + } + .set { ch_cmapkey_new } + + + ch_cmap_new + .join(ch_cmapkey_new) + .multiMap { meta, cfile, kfile -> + cmap : tuple( meta, cfile) + key_file : kfile + } + + .set { ch_join } + + // + // MODULE: RENAME CMAP IDs FROM BIONANO IDX TO ORIGINAL GENOMIC LOCATIONS + // EMITS RENAMED CMAP + // + MAKECMAP_RENAMECMAPIDS ( + ch_join.cmap, + ch_join.key_file + ) + ch_versions = ch_versions.mix(MAKECMAP_RENAMECMAPIDS.out.versions) + + MAKECMAP_RENAMECMAPIDS.out.renamedcmap + .multiMap { meta, file -> + full : tuple ( meta, file ) + sample : meta.id + } + .set { ch_renamedcmap } + + // + // MODULE: CONVERT CMAP FILE INTO BED FILE + // EMITS BED FILE + // + MAKECMAP_CMAP2BED ( + ch_renamedcmap.full, + ch_renamedcmap.sample + ) + ch_versions = ch_versions.mix(MAKECMAP_CMAP2BED.out.versions) + + MAKECMAP_CMAP2BED.out.bedfile + .combine(sizefile) + .combine(dot_as) + .multiMap { meta, bed, meta_2, dot_genome, as_file -> + bed_tuple : tuple( meta, bed ) + genome_file : dot_genome + autosql : as_file + } + .set { combined_ch } + + // + // MODULE: CONVERT ABOVE BED INTO BIGBED WITH ADDITIONAL AS FILE + // EMITS BIGBED FILE + // + UCSC_BEDTOBIGBED ( + combined_ch.bed_tuple, + combined_ch.genome_file, + combined_ch.autosql + ) + ch_versions = ch_versions.mix(UCSC_BEDTOBIGBED.out.versions) emit: - insilico_digest_bb = UCSC_BEDTOBIGBED.out.bigbed - - versions = ch_version + insilico_digest_bb = UCSC_BEDTOBIGBED.out.bigbed + versions = ch_versions.ifEmpty(null) } diff --git a/subworkflows/local/longread_coverage.nf b/subworkflows/local/longread_coverage.nf new file mode 100755 index 00000000..f1ca457c --- /dev/null +++ b/subworkflows/local/longread_coverage.nf @@ -0,0 +1,367 @@ +#!/usr/bin/env nextflow + +// +// MODULE IMPORT BLOCK +// +include { BEDTOOLS_BAMTOBED } from '../../modules/nf-core/bedtools/bamtobed/main' +include { BEDTOOLS_GENOMECOV } from '../../modules/nf-core/bedtools/genomecov/main' +include { BEDTOOLS_MERGE as BEDTOOLS_MERGE_MAX } from '../../modules/nf-core/bedtools/merge/main' +include { BEDTOOLS_MERGE as BEDTOOLS_MERGE_MIN } from '../../modules/nf-core/bedtools/merge/main' +include { GNU_SORT } from '../../modules/nf-core/gnu/sort/main' +include { MINIMAP2_INDEX } from '../../modules/nf-core/minimap2/index/main' +include { MINIMAP2_ALIGN as MINIMAP2_ALIGN_SPLIT } from '../../modules/nf-core/minimap2/align/main' +include { MINIMAP2_ALIGN } from '../../modules/nf-core/minimap2/align/main' +include { SAMTOOLS_MERGE } from '../../modules/nf-core/samtools/merge/main' +include { SAMTOOLS_SORT } from '../../modules/nf-core/samtools/sort/main' +include { SAMTOOLS_VIEW } from '../../modules/nf-core/samtools/view/main' +include { UCSC_BEDGRAPHTOBIGWIG } from '../../modules/nf-core/ucsc/bedgraphtobigwig/main' +include { GRAPHOVERALLCOVERAGE } from '../../modules/local/graphoverallcoverage' +include { GETMINMAXPUNCHES } from '../../modules/local/getminmaxpunches' +include { FINDHALFCOVERAGE } from '../../modules/local/findhalfcoverage' + +// less /nfs/team135/yy5/docker_cov/run-coverage + +workflow LONGREAD_COVERAGE { + + take: + reference_tuple // Channel: [ val(meta), file( reference_file ) ] + dot_genome // Channel: [ val(meta), [ file( datafile ) ] ] + reads_path // Channel: [ val(meta), val( str ) ] + + main: + ch_versions = Channel.empty() + + // + // MODULE: CREATES INDEX OF REFERENCE FILE + // + MINIMAP2_INDEX( + reference_tuple + ) + ch_versions = ch_versions.mix( MINIMAP2_INDEX.out.versions ) + + // + // LOGIC: PREPARE GET_READS_FROM_DIRECTORY INPUT + // + reference_tuple + .combine( reads_path ) + .map { meta, ref, reads_path -> + tuple( + [ id : meta.id, + single_end : true ], + reads_path + ) + } + .set { get_reads_input } + + // + // MODULE: GETS PACBIO READ PATHS FROM READS_PATH + // + ch_grabbed_read_paths = GrabFiles( get_reads_input ) + + // + // LOGIC: PACBIO READS FILES TO CHANNEL + // + ch_grabbed_read_paths + .map { meta, files -> + tuple( files ) + } + .flatten() + .set { ch_read_paths } + + // + // LOGIC: COMBINE PACBIO READ PATHS WITH MINIMAP2_INDEX OUTPUT + // + MINIMAP2_INDEX.out.index + .combine( ch_read_paths ) + .combine( reference_tuple ) + .map { meta, ref_mmi, read_path, ref_meta, reference -> + tuple( + [ id : meta.id, + single_end : true, + split_prefix: read_path.toString().split('/')[-1].split('.fasta.gz')[0] + ], + read_path, + ref_mmi, + true, + false, + false, + file( reference ).size() + ) + } + .branch { + large : it[6] > 3000000000 + small : it[6] < 3000000000 + } + .set { mma_input } + + mma_input.large + .multiMap { meta, read_path, ref_mmi, bam_output, cigar_paf, cigar_bam, file_size -> + read_tuple : tuple( meta, read_path) + mmi_index : ref_mmi + bool_bam_ouput : bam_output + bool_cigar_paf : cigar_paf + bool_cigar_bam : cigar_bam + } + .set { large } + + mma_input.small + .multiMap { meta, read_path, ref_mmi, bam_output, cigar_paf, cigar_bam, file_size -> + read_tuple : tuple( meta, read_path) + mmi_index : ref_mmi + bool_bam_ouput : bam_output + bool_cigar_paf : cigar_paf + bool_cigar_bam : cigar_bam + } + .set { small } + + // + // MODULE: ALIGN READS TO REFERENCE WHEN REFERENCE <5GB PER SCAFFOLD + // + MINIMAP2_ALIGN ( + small.read_tuple, + small.mmi_index, + small.bool_bam_ouput, + small.bool_cigar_paf, + small.bool_cigar_bam + ) + ch_versions = ch_versions.mix(MINIMAP2_ALIGN.out.versions) + ch_align_bams = MINIMAP2_ALIGN.out.bam + + // + // MODULE: ALIGN READS TO REFERENCE WHEN REFERENCE >5GB PER SCAFFOLD + // + MINIMAP2_ALIGN_SPLIT ( + large.read_tuple, + large.mmi_index, + large.bool_bam_ouput, + large.bool_cigar_paf, + large.bool_cigar_bam + ) + ch_versions = ch_versions.mix(MINIMAP2_ALIGN_SPLIT.out.versions) + + // + // LOGIC: COLLECT OUTPUTTED BAM FILES FROM BOTH PROCESSES + // + ch_align_bams + .mix( MINIMAP2_ALIGN_SPLIT.out.bam ) + .set { ch_bams } + + // + // LOGIC: PREPARING MERGE INPUT WITH REFERENCE GENOME AND REFERENCE INDEX + // + ch_bams + .map { meta, file -> + tuple( file ) + } + .collect() + .map { file -> + tuple ( + [ id : file[0].toString().split('/')[-1].split('_')[0] ], // Change sample ID + file + ) + } + .set { collected_files_for_merge } + + // + // MODULE: MERGES THE BAM FILES IN REGARDS TO THE REFERENCE + // EMITS A MERGED BAM + SAMTOOLS_MERGE( + collected_files_for_merge, + reference_tuple, + [[],[]] + ) + ch_versions = ch_versions.mix(SAMTOOLS_MERGE.out.versions) + + // + // MODULE: SORT THE MERGED BAM BEFORE CONVERSION + // + SAMTOOLS_SORT ( + SAMTOOLS_MERGE.out.bam + ) + ch_versions = ch_versions.mix( SAMTOOLS_MERGE.out.versions ) + + // + // LOGIC: PREPARING MERGE INPUT WITH REFERENCE GENOME AND REFERENCE INDEX + // + SAMTOOLS_SORT.out.bam + .combine( reference_tuple ) + .multiMap { meta, bam, ref_meta, ref -> + bam_input : tuple( + [ id : meta.id, + sz : bam.size(), + single_end : true ], + bam, + [] // As we aren't using an index file here + ) + ref_input : tuple( + ref_meta, + ref + ) + } + .set { view_input } + // + // MODULE: EXTRACT READS FOR PRIMARY ASSEMBLY + // + SAMTOOLS_VIEW( + view_input.bam_input, + view_input.ref_input, + [] + ) + ch_versions = ch_versions.mix(SAMTOOLS_VIEW.out.versions) + + // + // MODULE: BAM TO PRIMARY BED + // + BEDTOOLS_BAMTOBED( + SAMTOOLS_VIEW.out.bam + ) + ch_versions = ch_versions.mix(BEDTOOLS_BAMTOBED.out.versions) + + // + // LOGIC: PREPARING Genome2Cov INPUT + // + BEDTOOLS_BAMTOBED.out.bed + .combine( dot_genome ) + .multiMap { meta, file, my_genome_meta, my_genome -> + input_tuple : tuple ( + [ id : meta.id, + single_end : true ], + file, + 1 + ) + dot_genome : my_genome + file_suffix : 'bed' + } + .set { genomecov_input } + + // + // MODULE: Genome2Cov + // + BEDTOOLS_GENOMECOV( + genomecov_input.input_tuple, + genomecov_input.dot_genome, + genomecov_input.file_suffix + ) + ch_versions = ch_versions.mix(BEDTOOLS_GENOMECOV.out.versions) + + // + // MODULE: SORT THE PRIMARY BED FILE + // + GNU_SORT( + BEDTOOLS_GENOMECOV.out.genomecov + ) + ch_versions = ch_versions.mix(GNU_SORT.out.versions) + + // + // MODULE: get_minmax_punches + // + GETMINMAXPUNCHES( + GNU_SORT.out.sorted + ) + ch_versions = ch_versions.mix(GETMINMAXPUNCHES.out.versions) + + // + // MODULE: get_minmax_punches + // + BEDTOOLS_MERGE_MAX( + GETMINMAXPUNCHES.out.max + ) + ch_versions = ch_versions.mix(BEDTOOLS_MERGE_MAX.out.versions) + + // + // MODULE: get_minmax_punches + // + BEDTOOLS_MERGE_MIN( + GETMINMAXPUNCHES.out.min + ) + ch_versions = ch_versions.mix(BEDTOOLS_MERGE_MIN.out.versions) + + // + // MODULE: GENERATE DEPTHGRAPH + // + GRAPHOVERALLCOVERAGE( + GNU_SORT.out.sorted + ) + ch_versions = ch_versions.mix(GRAPHOVERALLCOVERAGE.out.versions) + ch_depthgraph = GRAPHOVERALLCOVERAGE.out.part + + // + // LOGIC: PREPARING FINDHALFCOVERAGE INPUT + // + GNU_SORT.out.sorted + .combine( GRAPHOVERALLCOVERAGE.out.part ) + .combine( dot_genome ) + .multiMap { meta, file, meta_depthgraph, depthgraph, meta_my_genome, my_genome -> + halfcov_bed : tuple( [ id : meta.id, single_end : true ], file ) + genome_file : my_genome + depthgraph_file : depthgraph + } + .set { halfcov_input } + + // + // MODULE: FIND REGIONS OF HALF COVERAGE + // + FINDHALFCOVERAGE( + halfcov_input.halfcov_bed, + halfcov_input.genome_file, + halfcov_input.depthgraph_file + ) + ch_versions = ch_versions.mix(FINDHALFCOVERAGE.out.versions) + + // + // LOGIC: PREPARING COVERAGE INPUT + // + GNU_SORT.out.sorted + .combine( dot_genome ) + .combine(reference_tuple) + .multiMap { meta, file, meta_my_genome, my_genome, ref_meta, ref -> + ch_coverage_bed : tuple ([ id: ref_meta.id, single_end: true], file) + genome_file : my_genome + } + .set { bed2bw_input } + + // + // MODULE: CONVERT BEDGRAPH TO BIGWIG + // + UCSC_BEDGRAPHTOBIGWIG( + bed2bw_input.ch_coverage_bed, + bed2bw_input.genome_file + ) + ch_versions = ch_versions.mix(UCSC_BEDGRAPHTOBIGWIG.out.versions) + + // + // LOGIC: GENERATE A SUMMARY TUPLE FOR OUTPUT + // + ch_grabbed_read_paths.map{ it } + + ch_grabbed_read_paths + .collect() + .map { meta, fasta -> + tuple( [ id: 'pacbio', + sz: fasta instanceof ArrayList ? fasta.collect { it.size()} : fasta.size() ], + fasta + ) + } + .set { ch_reporting_pacbio } + + emit: + ch_minbed = BEDTOOLS_MERGE_MIN.out.bed + ch_halfbed = FINDHALFCOVERAGE.out.bed + ch_maxbed = BEDTOOLS_MERGE_MAX.out.bed + ch_bigwig = UCSC_BEDGRAPHTOBIGWIG.out.bigwig + ch_reporting = ch_reporting_pacbio.collect() + versions = ch_versions +} + +process GrabFiles { + tag "${meta.id}" + executor 'local' + + input: + tuple val(meta), path("in") + + output: + tuple val(meta), path("in/*.fasta.gz") + + "true" +} diff --git a/subworkflows/local/nuc_alignments.nf b/subworkflows/local/nuc_alignments.nf old mode 100644 new mode 100755 index e23ba9ef..8d13b8f1 --- a/subworkflows/local/nuc_alignments.nf +++ b/subworkflows/local/nuc_alignments.nf @@ -1,102 +1,162 @@ -include { MINIMAP2_ALIGN } from '../../modules/nf-core/modules/minimap2/align/main.nf' -include { SAMTOOLS_MERGE } from '../../modules/nf-core/modules/nf-core/samtools/merge/main' -include { SAMTOOLS_FAIDX } from '../../modules/nf-core/modules/samtools/faidx/main' -include { BEDTOOLS_SORT } from '../../modules/nf-core/modules/bedtools/sort/main' -include { BEDTOOLS_BAMTOBED } from '../../modules/sanger-tol/nf-core-modules/bedtools/bamtobed/main' -include { UCSC_BEDTOBIGBED } from '../../modules/nf-core/modules/ucsc/bedtobigbed/main' +#!/usr/bin/env nextflow +// +// MODULE IMPORT BLOCK +// +include { MINIMAP2_ALIGN } from '../../modules/nf-core/minimap2/align/main' +include { SAMTOOLS_MERGE } from '../../modules/nf-core/samtools/merge/main' +include { SAMTOOLS_FAIDX } from '../../modules/nf-core/samtools/faidx/main' +include { BEDTOOLS_SORT } from '../../modules/nf-core/bedtools/sort/main' +include { BEDTOOLS_BAMTOBED } from '../../modules/nf-core/bedtools/bamtobed/main' +include { UCSC_BEDTOBIGBED } from '../../modules/nf-core/ucsc/bedtobigbed/main' +include { PAFTOOLS_SAM2PAF } from '../../modules/nf-core/paftools/sam2paf/main' +include { PAF2BED } from '../../modules/local/paf_to_bed' + +// +// SUBWORKFLOW IMPORTS +// +include { PUNCHLIST } from './punchlist' workflow NUC_ALIGNMENTS { take: - reference_tuple - nuc_files - dot_genome - intron_size + reference_tuple // Channel [ val(meta), path(file) ] + reference_index // Channel [ val(meta), path(file) ] + nuc_files // Channel [ val(meta), path(file) ] + dot_genome // Channel [ val(meta), path(file) ] + intron_size // Channel val(50k) main: ch_versions = Channel.empty() + // + // LOGIC: COLLECTION FROM GENE_ALIGNMENT IS A LIST OF ALL META AND ALL FILES + // BELOW CONVERTS INTO TUPLE FORMAT AND ADDS BOOLEANS FOR MINIMAP2_ALIGN + // nuc_files .flatten() .buffer( size: 2 ) .combine ( reference_tuple ) .combine( intron_size ) - .map ( it -> - tuple( [id: it[0].id, - type: it[0].type, - org: it[0].org, - single_end: true + .map { meta, nuc_file, ref_meta, ref, intron -> + tuple( [id: meta.id, + type: meta.type, + org: meta.org, + intron_size: intron, + split_prefix: nuc_file.toString().split('/')[-1].split('.fasta')[0], + single_end: true ], - it[1], - it[3], + nuc_file, + ref, true, false, - false, - it[4] + false ) - ) + } + .multiMap { meta, nuc_file, reference, bool_1, bool_2, bool_3 -> + nuc : tuple( meta, nuc_file) + ref : reference + bool_bam_output : bool_1 + bool_cigar_paf : bool_2 + bool_cigar_bam : bool_3 + } .set { formatted_input } - SAMTOOLS_FAIDX ( reference_tuple ) - ch_versions = ch_versions.mix(SAMTOOLS_FAIDX.out.versions) - + // + // MODULE: ALIGNS REFERENCE FAIDX TO THE GENE_ALIGNMENT QUERY FILE FROM NUC_FILES + // EMITS ALIGNED BAM FILE + // MINIMAP2_ALIGN ( - formatted_input.map { [it[0], it[1]] }, - formatted_input.map { it[2] }, - formatted_input.map { it[3] }, - formatted_input.map { it[4] }, - formatted_input.map { it[5] }, - formatted_input.map { it[6] } + formatted_input.nuc, + formatted_input.ref, + formatted_input.bool_bam_output, + formatted_input.bool_cigar_paf, + formatted_input.bool_cigar_bam ) ch_versions = ch_versions.mix(MINIMAP2_ALIGN.out.versions) + // + // LOGIC: CONVERTS THE MINIMAP OUTPUT TUPLE INTO A GROUPED TUPLE PER INPUT QUERY ORGANISM + // AND DATA TYPE (RNA, CDS, DNA). + // MINIMAP2_ALIGN.out.bam .map { meta, file -> - tuple([id: meta.org, type: meta.type], file) } - .groupTuple( by: [0] ) - .combine( reference_tuple ) - .combine( SAMTOOLS_FAIDX.out.fai ) - .multiMap { it -> - nuc_grouped: tuple( it[0], it[1] ) - reference: it[-3] - ref_index: it[-1] - } + tuple( + [ id: meta.org, + type: meta.type ], + file) } + .groupTuple( by: [0] ) // group by meta list .set { merge_input } + // + // MODULE: MERGES THE BAM FILES FOUND IN THE GROUPED TUPLE IN REGARDS TO THE REFERENCE + // EMITS A MERGED BAM SAMTOOLS_MERGE ( - merge_input.nuc_grouped, - merge_input.reference, - merge_input.ref_index + merge_input, + reference_tuple, + reference_index ) ch_versions = ch_versions.mix(SAMTOOLS_MERGE.out.versions) - BEDTOOLS_BAMTOBED { SAMTOOLS_MERGE.out.bam } + // + // SUBWORKFLOW: GENERATES A PUNCHLIST FROM MERGED BAM FILE + // + PUNCHLIST ( + reference_tuple, + SAMTOOLS_MERGE.out.bam + ) + ch_versions = ch_versions.mix(PUNCHLIST.out.versions) - BEDTOOLS_SORT ( BEDTOOLS_BAMTOBED.out.bed, 'sorted.bed' ) + // + // MODULE: CONVERTS THE ABOVE MERGED BAM INTO BED FORMAT + // + BEDTOOLS_BAMTOBED ( SAMTOOLS_MERGE.out.bam ) + ch_versions = ch_versions.mix(BEDTOOLS_BAMTOBED.out.versions) + + // TODO: try filtering out here too + + // + // MODULE: SORTS THE ABOVE BED FILE + // + BEDTOOLS_SORT ( + BEDTOOLS_BAMTOBED.out.bed, + [] + ) ch_versions = ch_versions.mix(BEDTOOLS_SORT.out.versions) + // + // LOGIC: COMBINES GENOME_FILE CHANNEL AND ABOVE OUTPUT, SPLITS INTO TWO CHANNELS + // ALSO FILTERS OUT EMPTY MERGED.BED BASED ON WHETHER FILE IS >141 BYTES + // BEDTOOLS_SORT.out.sorted + .map { meta, file -> + tuple( [ id: meta.id, + type: meta.type, + file_size: file.size() + ], + file ) } + .filter { it[0].file_size >= 141 } // Take the first item in input (meta) and check if size is more than a symlink .combine( dot_genome ) - .multiMap { it -> - bed_file: tuple( [ id: it[0].id, - type: it[0].type + .multiMap { meta, ref, genome_meta, genome -> + bed_file: tuple( [ id: meta.id, + type: meta.type, ], - it[1] ) - dot_genome: it[3] + ref ) + dot_genome: genome } .set { ucsc_input } - ucsc_input.bed_file.view() - + // + // MODULE: CONVERTS GENOME FILE AND BED INTO A BIGBED FILE + // UCSC_BEDTOBIGBED ( ucsc_input.bed_file, ucsc_input.dot_genome, [] ) - ch_versions = ch_versions.mix( UCSC_BEDTOBIGBED.out.versions ) emit: nuc_alignment = UCSC_BEDTOBIGBED.out.bigbed.collect() + punchlist = PUNCHLIST.out.punchlist.collect() versions = ch_versions.ifEmpty(null) -} \ No newline at end of file +} diff --git a/subworkflows/local/pep_alignments.nf b/subworkflows/local/pep_alignments.nf old mode 100644 new mode 100755 index 2072d078..8f12e91e --- a/subworkflows/local/pep_alignments.nf +++ b/subworkflows/local/pep_alignments.nf @@ -1,56 +1,124 @@ #!/usr/bin/env nextflow -include { CONCAT_GFF } from '../../modules/local/concat_gff' -include { BEDTOOLS_SORT } from '../../modules/nf-core/modules/nf-core/bedtools/sort/main' -include { TABIX_BGZIPTABIX } from '../../modules/nf-core/modules/nf-core/tabix/bgziptabix/main' -include { MINIPROT_INDEX } from '../../modules/sanger-tol/nf-core-modules/miniprot/index/main' -include { MINIPROT_ALIGN } from '../../modules/sanger-tol/nf-core-modules/miniprot/align/main' +// +// MODULE IMPORT BLOCK +// +include { CAT_CAT } from '../../modules/nf-core/cat/cat/main' +include { BEDTOOLS_SORT } from '../../modules/nf-core/bedtools/sort/main' +include { TABIX_BGZIPTABIX } from '../../modules/nf-core/tabix/bgziptabix/main' +include { MINIPROT_INDEX } from '../../modules/nf-core/miniprot/index/main' +include { MINIPROT_ALIGN } from '../../modules/nf-core/miniprot/align/main' +include { EXTRACT_COV_IDEN } from '../../modules/local/extract_cov_iden' workflow PEP_ALIGNMENTS { take: - reference_tuple - pep_files + reference_tuple // Channel [ val(meta), path(file) ] + pep_files // Channel [ val(meta), path(file) ] + max_scaff_size // Channel val(size of largest scaffold in bp) main: + ch_versions = Channel.empty() + // + // MODULE: CREATES INDEX OF REFERENCE FILE + // MINIPROT_INDEX ( reference_tuple ) + ch_versions = ch_versions.mix( MINIPROT_INDEX.out.versions ) + // + // LOGIC: GETS LIST OF META AND PEP FILES FROM GENE_ALIGNMENT + // COMBINES WITH MINIPROT_INDEX OUTPUT + // CONVERTS TO TWO TUPLES FOR PEP DATA AND REFERENCE + // pep_files .flatten() .buffer( size: 2 ) .combine ( MINIPROT_INDEX.out.index ) - .multiMap { data -> - pep_tuple : tuple( [ id: data[0].id, - type: data[0].type, - org: data[0].org + .multiMap { pep_meta, pep_file, miniprot_meta, miniprot_index -> + pep_tuple : tuple( [ id: pep_meta.id, + type: pep_meta.type, + org: pep_meta.org + ], + pep_file ) + index_file : tuple( [ id: "Reference", ], - data[1] ) - index_file : data[3] + miniprot_index ) } .set { formatted_input } - MINIPROT_ALIGN ( + // + // MODULE: ALIGNS PEP DATA WITH REFERENCE INDEX + // EMITS GFF FILE + // + MINIPROT_ALIGN ( formatted_input.pep_tuple, formatted_input.index_file ) + ch_versions = ch_versions.mix( MINIPROT_ALIGN.out.versions ) + // + // LOGIC: GROUPS OUTPUT GFFS BASED ON QUERY ORGANISMS AND DATA TYPE (PEP) + // MINIPROT_ALIGN.out.gff - .map { it -> - tuple([ id: it[0].org, - type: it[0].type - ], - it[1] ) + .map { meta, file -> + tuple( + [ id : meta.org + '_pep', + type : meta.type ], + file + ) } .groupTuple( by: [0] ) .set { grouped_tuple } - CONCAT_GFF ( grouped_tuple ) + // + // MODULE: AS ABOVE OUTPUT IS BED FORMAT, IT IS MERGED PER ORGANISM + TYPE + // + CAT_CAT ( + grouped_tuple + ) + ch_versions = ch_versions.mix( CAT_CAT.out.versions ) - BEDTOOLS_SORT ( CONCAT_GFF.out.concat_gff , 'gff') + // + // MODULE: SORTS ABOVE OUTPUT AND RETAINS GFF SUFFIX + // EMITS A MERGED GFF FILE + // + BEDTOOLS_SORT ( + CAT_CAT.out.file_out , + [] + ) + ch_versions = ch_versions.mix( BEDTOOLS_SORT.out.versions ) - TABIX_BGZIPTABIX ( BEDTOOLS_SORT.out.sorted ) + // + // MODULE: CUTS GFF INTO PUNCHLIST + // + EXTRACT_COV_IDEN ( + CAT_CAT.out.file_out + ) + ch_versions = ch_versions.mix( EXTRACT_COV_IDEN.out.versions ) + + BEDTOOLS_SORT.out.sorted + .combine( max_scaff_size ) + .map {meta, row, scaff -> + tuple( + [ id : meta.id, + max_scaff : scaff >= 500000000 ? 'csi': '' ], + file( row ) + ) + } + .set { modified_bed_ch } + + // + // MODULE: COMPRESS AND INDEX MERGED.GFF + // EMITS A TBI FILE + // + TABIX_BGZIPTABIX ( + modified_bed_ch + ) + ch_versions = ch_versions.mix( TABIX_BGZIPTABIX.out.versions ) emit: - gff_file = BEDTOOLS_SORT.out.sorted - tbi_gff = TABIX_BGZIPTABIX.out.gz_tbi -} \ No newline at end of file + gff_file = BEDTOOLS_SORT.out.sorted + tbi_gff = TABIX_BGZIPTABIX.out.gz_tbi + pep_punch = EXTRACT_COV_IDEN.out.punchlist + versions = ch_versions.ifEmpty(null) +} diff --git a/subworkflows/local/punchlist.nf b/subworkflows/local/punchlist.nf new file mode 100755 index 00000000..1db01a6e --- /dev/null +++ b/subworkflows/local/punchlist.nf @@ -0,0 +1,36 @@ +#!/usr/bin/env nextflow + +// +// MODULE IMPORT BLOCK +// +include { PAFTOOLS_SAM2PAF } from '../../modules/nf-core/paftools/sam2paf/main' +include { PAF2BED } from '../../modules/local/paf_to_bed' + +workflow PUNCHLIST { + take: + reference_tuple // Channel [ val(meta), path(reference)] + merged_bam // Channel [ val(meta), path(bam_file)] + + main: + ch_versions = Channel.empty() + + // + // MODULE: CONVERTS BAM INTO PAF FOR THE PUNCHLIST GENERATION + // + PAFTOOLS_SAM2PAF ( + merged_bam + ) + ch_versions = ch_versions.mix( PAFTOOLS_SAM2PAF.out.versions ) + + // + // MODULE: GENERATES PUNCHLIST FROM PAF FILE + // + PAF2BED ( + PAFTOOLS_SAM2PAF.out.paf + ) + ch_versions = ch_versions.mix( PAF2BED.out.versions ) + + emit: + punchlist = PAF2BED.out.punchlist + versions = ch_versions.ifEmpty(null) +} diff --git a/subworkflows/local/repeat_density.nf b/subworkflows/local/repeat_density.nf new file mode 100755 index 00000000..2445c89a --- /dev/null +++ b/subworkflows/local/repeat_density.nf @@ -0,0 +1,161 @@ +#!/usr/bin/env nextflow + +// +// MODULE IMPORT BLOCK +// +include { WINDOWMASKER_USTAT } from '../../modules/nf-core/windowmasker/ustat/main' +include { WINDOWMASKER_MKCOUNTS } from '../../modules/nf-core/windowmasker/mk_counts/main' +include { EXTRACT_REPEAT } from '../../modules/local/extract_repeat' +include { BEDTOOLS_INTERSECT } from '../../modules/nf-core/bedtools/intersect/main' +include { BEDTOOLS_MAKEWINDOWS } from '../../modules/nf-core/bedtools/makewindows/main' +include { BEDTOOLS_MAP } from '../../modules/nf-core/bedtools/map/main' +include { RENAME_IDS } from '../../modules/local/rename_ids' +include { UCSC_BEDGRAPHTOBIGWIG } from '../../modules/nf-core/ucsc/bedgraphtobigwig/main' +include { GNU_SORT as GNU_SORT_A } from '../../modules/nf-core/gnu/sort/main' +include { GNU_SORT as GNU_SORT_B } from '../../modules/nf-core/gnu/sort/main' +include { GNU_SORT as GNU_SORT_C } from '../../modules/nf-core/gnu/sort/main' +include { REFORMAT_INTERSECT } from '../../modules/local/reformat_intersect' +include { REPLACE_DOTS } from '../../modules/local/replace_dots' + +workflow REPEAT_DENSITY { + take: + reference_tuple // Channel [ val(meta), path(file) ] + dot_genome + + main: + ch_versions = Channel.empty() + // + // MODULE: MARK UP THE REPEAT REGIONS OF THE REFERENCE GENOME + // + WINDOWMASKER_MKCOUNTS ( + reference_tuple + ) + ch_versions = ch_versions.mix( WINDOWMASKER_MKCOUNTS.out.versions ) + + // + // MODULE: CALCULATE THE STATISTICS OF THE MARKED UP REGIONS + // + WINDOWMASKER_USTAT( + WINDOWMASKER_MKCOUNTS.out.counts, + reference_tuple + ) + ch_versions = ch_versions.mix( WINDOWMASKER_USTAT.out.versions ) + + // + // MODULE: USE USTAT OUTPUT TO EXTRACT REPEATS FROM FASTA + // + EXTRACT_REPEAT( + WINDOWMASKER_USTAT.out.intervals + ) + ch_versions = ch_versions.mix( EXTRACT_REPEAT.out.versions ) + + // + // MODULE: CREATE WINDOWS FROM .GENOME FILE + // + BEDTOOLS_MAKEWINDOWS( + dot_genome + ) + ch_versions = ch_versions.mix( BEDTOOLS_MAKEWINDOWS.out.versions ) + + // + // LOGIC: COMBINE TWO CHANNELS AND OUTPUT tuple(meta, windows_file, repeat_file) + // + BEDTOOLS_MAKEWINDOWS.out.bed + .combine( EXTRACT_REPEAT.out.bed ) + .map{ meta, windows_file, repeat_meta, repeat_file -> + tuple ( + meta, + windows_file, + repeat_file + ) + } + .set { intervals } + + // + // MODULE: GENERATES THE REPEAT FILE FROM THE WINDOW FILE AND GENOME FILE + // + BEDTOOLS_INTERSECT( + intervals, + dot_genome + ) + ch_versions = ch_versions.mix( BEDTOOLS_INTERSECT.out.versions ) + + // + // MODULE: FIXES IDS FOR REPEATS + // + RENAME_IDS( + BEDTOOLS_INTERSECT.out.intersect + ) + ch_versions = ch_versions.mix( RENAME_IDS.out.versions ) + + // + // MODULE: SORTS THE ABOVE BED FILES + // + GNU_SORT_A ( + RENAME_IDS.out.bed // Intersect file + ) + ch_versions = ch_versions.mix( GNU_SORT_A.out.versions ) + + GNU_SORT_B ( + dot_genome // Genome file - Will not run unless genome file is sorted to + ) + ch_versions = ch_versions.mix( GNU_SORT_B.out.versions ) + + GNU_SORT_C ( + BEDTOOLS_MAKEWINDOWS.out.bed // Windows file + ) + ch_versions = ch_versions.mix( GNU_SORT_C.out.versions ) + + // + // MODULE: ADDS 4TH COLUMN TO BED FILE USED IN THE REPEAT DENSITY GRAPH + // + REFORMAT_INTERSECT ( + GNU_SORT_A.out.sorted + ) + ch_versions = ch_versions.mix( GNU_SORT_C.out.versions ) + + // + // LOGIC: COMBINES THE REFORMATTED INTERSECT FILE AND WINDOWS FILE CHANNELS AND SORTS INTO + // tuple(intersect_meta, windows file, intersect file) + // + REFORMAT_INTERSECT.out.bed + .combine( GNU_SORT_C.out.sorted ) + .map{ intersect_meta, bed, sorted_meta, windows_file -> + tuple ( + intersect_meta, + windows_file, + bed + ) + } + .set { for_mapping } + + // + // MODULE: MAPS THE REPEATS AGAINST THE REFERENCE GENOME + // + BEDTOOLS_MAP( + for_mapping, + GNU_SORT_B.out.sorted + ) + ch_versions = ch_versions.mix( BEDTOOLS_MAP.out.versions ) + + // + // MODULE: REPLACES . WITH 0 IN MAPPED FILE + // + REPLACE_DOTS ( + BEDTOOLS_MAP.out.map + ) + ch_versions = ch_versions.mix( REPLACE_DOTS.out.versions ) + + // + // MODULE: CONVERTS GENOME FILE AND BED INTO A BIGWIG FILE + // + UCSC_BEDGRAPHTOBIGWIG( + REPLACE_DOTS.out.bed, + GNU_SORT_B.out.sorted.map { it[1] } // Pulls file from tuple of meta and file + ) + ch_versions = ch_versions.mix( UCSC_BEDGRAPHTOBIGWIG.out.versions ) + + emit: + repeat_density = UCSC_BEDGRAPHTOBIGWIG.out.bigwig + versions = ch_versions.ifEmpty(null) +} diff --git a/subworkflows/local/selfcomp.nf b/subworkflows/local/selfcomp.nf index b6c4261e..985d9c6c 100755 --- a/subworkflows/local/selfcomp.nf +++ b/subworkflows/local/selfcomp.nf @@ -1,82 +1,160 @@ #!/usr/bin/env nextflow -nextflow.enable.dsl=2 - -// MODULE IMPORT -include { MUMMER } from '../../modules/nf-core/modules/mummer/main' -include { SAMTOOLS_FAIDX } from '../../modules/nf-core/modules/samtools/faidx/main' -include { SELFCOMP_SPLITFASTA } from '../../modules/sanger-tol/nf-core-modules/selfcomp/splitfasta/main' -include { SELFCOMP_MUMMER2BED } from '../../modules/sanger-tol/nf-core-modules/selfcomp/mummer2bed/main' -include { SELFCOMP_MAPIDS } from '../../modules/sanger-tol/nf-core-modules/selfcomp/mapids/main' -include { CHUNKFASTA } from '../../modules/local/chunkfasta' -include { CONCATMUMMER } from '../../modules/local/concatmummer' -include { UCSC_BEDTOBIGBED } from '../../modules/nf-core/modules/ucsc/bedtobigbed/main' -include { BEDTOOLS_SORT } from '../../modules/nf-core/modules/bedtools/sort/main' +// +// MODULE IMPORT BLOCK +// +include { MUMMER } from '../../modules/nf-core/mummer/main' +include { SAMTOOLS_FAIDX } from '../../modules/nf-core/samtools/faidx/main' +include { UCSC_BEDTOBIGBED } from '../../modules/nf-core/ucsc/bedtobigbed/main' +include { BEDTOOLS_SORT } from '../../modules/nf-core/bedtools/sort/main' +include { SELFCOMP_SPLITFASTA } from '../../modules/local/selfcomp_splitfasta' +include { SELFCOMP_MUMMER2BED } from '../../modules/local/selfcomp_mummer2bed' +include { SELFCOMP_MAPIDS } from '../../modules/local/selfcomp_mapids' +include { CHUNKFASTA } from '../../modules/local/chunkfasta' +include { CONCATMUMMER } from '../../modules/local/concatmummer' +include { SELFCOMP_ALIGNMENTBLOCKS } from '../../modules/local/selfcomp_alignmentblocks' +include { CONCATBLOCKS } from '../../modules/local/concatblocks' +include { BEDTOOLS_MERGE } from '../../modules/nf-core/bedtools/merge/main' workflow SELFCOMP { take: - reference_tuple // channel [id: sample_id], reference_file - dot_genome // Channel: [val(meta), [ datafile ]] - mummer_chunk // channel val( int ) - motif_len // channel val( int ) - selfcomp_as // channel val(dot_as location) + reference_tuple // Channel [ val(meta), path(reference_file) ] + dot_genome // Channel [ val(meta), [ path(datafile) ] ] + mummer_chunk // Channel val( int ) + motif_len // Channel val( int ) + selfcomp_as // Channel val( dot_as location ) main: - ch_versions = Channel.empty() - - // Split fasta sequences into 500kb length fasta sequences - SELFCOMP_SPLITFASTA(reference_tuple) - ch_versions = ch_versions.mix(SELFCOMP_SPLITFASTA.out.versions) - - // Chunk the fasta file for processing (1Gb chunks) - CHUNKFASTA(SELFCOMP_SPLITFASTA.out.fa, mummer_chunk) - ch_versions = ch_versions.mix(CHUNKFASTA.out.versions) - - // Run mummer on each chunk, generating .coords files for each. + ch_versions = Channel.empty() + + // + // MODULE: SPLITS INPUT FASTA INTO 500KB CHUNKS + // EMITS CHUNKED FASTA + // + SELFCOMP_SPLITFASTA( + reference_tuple + ) + ch_versions = ch_versions.mix( SELFCOMP_SPLITFASTA.out.versions ) + + // + // MODULE: SPLIT INPUT FASTA INTO 1GB CHUNKS + // EMITS CHUNKED FASTA + // + CHUNKFASTA( + SELFCOMP_SPLITFASTA.out.fa, + mummer_chunk + ) + ch_versions = ch_versions.mix( CHUNKFASTA.out.versions ) + + // + // LOGIC: CONVERTS ABOVE OUTPUTS INTO A SINGLE TUPLE + // ch_query_tup = CHUNKFASTA.out.fas - .map{ - meta, query -> [query] + .map{ meta, query -> + [query] } .flatten() ch_ref = SELFCOMP_SPLITFASTA.out.fa - .map{ - meta, ref -> ref + .map{ meta, ref -> + ref } ch_mummer_input = ch_query_tup .combine(ch_ref) - .map{ - query, ref -> tuple([id: query.toString().split('/')[-1] ], ref, query) + .map{ query, ref -> + tuple([ id: query.toString().split('/')[-1] ], + ref, + query + ) } - MUMMER( ch_mummer_input ) - ch_versions = ch_versions.mix(MUMMER.out.versions) - - // Concatenate mummer files. + // + // MODULE: ALIGNS 1GB CHUNKS TO 500KB CHUNKS + // EMITS MUMMER ALIGNMENT FILE + // + MUMMER( + ch_mummer_input + ) + ch_versions = ch_versions.mix( MUMMER.out.versions ) + + // + // LOGIC: GROUPS OUTPUT INTO SINGLE TUPLE BASED ON REFERENCE META + // MUMMER.out.coords - .combine(reference_tuple) - .map { coords_meta, coords, ref_meta, ref -> tuple(ref_meta, coords) } - .groupTuple(by:[0]) + .combine( reference_tuple ) + .map { coords_meta, coords, ref_meta, ref -> + tuple( ref_meta, + coords + ) + } + .groupTuple( by:[0] ) .set{ ch_mummer_files } - CONCATMUMMER(ch_mummer_files) - ch_versions = ch_versions.mix(CONCATMUMMER.out.versions) - - SELFCOMP_MUMMER2BED(CONCATMUMMER.out.mummer, motif_len) - ch_versions = ch_versions.mix(SELFCOMP_MUMMER2BED.out.versions) - - SELFCOMP_MAPIDS(SELFCOMP_MUMMER2BED.out.bedfile, SELFCOMP_SPLITFASTA.out.agp) - ch_versions = ch_versions.mix(SELFCOMP_MAPIDS.out.versions) - - BEDTOOLS_SORT(SELFCOMP_MAPIDS.out.bedfile, "bed") - ch_versions = ch_versions.mix(BEDTOOLS_SORT.out.versions) - UCSC_BEDTOBIGBED(BEDTOOLS_SORT.out.sorted, dot_genome.map{it[1]}, selfcomp_as) - ch_bigbed = UCSC_BEDTOBIGBED.out.bigbed - ch_versions = ch_versions.mix(UCSC_BEDTOBIGBED.out.versions) + // + // MODULE: MERGES MUMMER ALIGNMENT FILES + // + CONCATMUMMER( + ch_mummer_files + ) + ch_versions = ch_versions.mix( CONCATMUMMER.out.versions ) + + // + // MODULE: CONVERT THE MUMMER ALIGNMENTS INTO BED FORMAT + // + SELFCOMP_MUMMER2BED( + CONCATMUMMER.out.mummer, + motif_len + ) + ch_versions = ch_versions.mix( SELFCOMP_MUMMER2BED.out.versions ) + + // + // MODULE: GENERATE A LIST OF IDs AND GENOMIC POSITIONS OF SELFCOMPLEMENTARY REGIONS + // EMITS BED FILE + // + SELFCOMP_MAPIDS( + SELFCOMP_MUMMER2BED.out.bedfile, + SELFCOMP_SPLITFASTA.out.agp + ) + ch_versions = ch_versions.mix( SELFCOMP_MAPIDS.out.versions ) + + // + // MODULE: SORTS ABOVE OUTPUT BED FILE AND RETAINS BED SUFFIX + // + BEDTOOLS_SORT( + SELFCOMP_MAPIDS.out.bedfile, + [] + ) + ch_versions = ch_versions.mix( BEDTOOLS_SORT.out.versions ) + + // + // MODULE: BUILD ALIGNMENT BLOCKS + // + SELFCOMP_ALIGNMENTBLOCKS( + BEDTOOLS_SORT.out.sorted + ) + ch_versions = ch_versions.mix( SELFCOMP_ALIGNMENTBLOCKS.out.versions ) + + // + // MODULE: SORT BLOCKS FILES AND FILTER BY MOTIF LENGTH + // + CONCATBLOCKS( + SELFCOMP_ALIGNMENTBLOCKS.out.blockfile + ) + ch_versions = ch_versions.mix( CONCATBLOCKS.out.versions ) + + // + // MODULE: CONVERTS ABOVE OUTPUT INTO BIGBED FORMAT + // + UCSC_BEDTOBIGBED( + CONCATBLOCKS.out.chainfile, + dot_genome.map{it[1]}, // Pulls file from tuple ( meta and file ) + selfcomp_as + ) + ch_versions = ch_versions.mix( UCSC_BEDTOBIGBED.out.versions ) emit: - ch_bigbed - versions = ch_versions -} \ No newline at end of file + ch_bigbed = UCSC_BEDTOBIGBED.out.bigbed + versions = ch_versions.ifEmpty(null) +} diff --git a/subworkflows/local/synteny.nf b/subworkflows/local/synteny.nf index 8df351d4..3c631887 100755 --- a/subworkflows/local/synteny.nf +++ b/subworkflows/local/synteny.nf @@ -1,49 +1,69 @@ +#!/usr/bin/env nextflow + // -// Check for synteny by aligning to fasta to reference genomes. +// MODULE IMPORT BLOCK // -include { MINIMAP2_ALIGN } from '../../modules/nf-core/modules/minimap2/align/main' +include { MINIMAP2_ALIGN } from '../../modules/nf-core/minimap2/align/main' include { GET_SYNTENY_GENOMES } from '../../modules/local/get_synteny_genomes' workflow SYNTENY { take: - reference_tuple - synteny_path - assembly_classT + reference_tuple // Channel [ val(meta), path(file) ] + synteny_path // Channel val(meta) + assembly_classT // Channel val(meta) main: - ch_versions = Channel.empty() + ch_versions = Channel.empty() - GET_SYNTENY_GENOMES(synteny_path, assembly_classT) + // + // MODULE: SEARCHES PREDETERMINED PATH FOR SYNTENIC GENOME FILES BASED ON CLASS + // EMITS PATH LIST + // + GET_SYNTENY_GENOMES( + synteny_path, + assembly_classT + ) + ch_versions = ch_versions.mix( GET_SYNTENY_GENOMES.out.versions ) + // + // LOGIC: GENERATES LIST OF GENOMES IN PATH AND BRANCHES ON WHETHER THERE IS DATA + // GET_SYNTENY_GENOMES.out.genome_path .flatten() - .branch { data -> - run: !data.toString().contains("empty") - skip: data.toString().contains("empty") + .branch { data -> + run : !data.toString().contains("empty") + skip : data.toString().contains("empty") } .set { mm_intermediary } + // + // LOGIC: COMBINE WITH ABOVE .RUN CHANNEL ADD BOOLEANS FOR MINIMAP + // reference_tuple - .combine(mm_intermediary.run) - .map { meta, fa, ref -> - tuple([ id: meta.id, - single_end: true], - fa, ref, false, true, false, false) - } - .set { mm_input } - - MINIMAP2_ALIGN( mm_input.map { [it[0], it[1]] }, - mm_input.map { it[2] }, - mm_input.map { it[3] }, - mm_input.map { it[4] }, - mm_input.map { it[5] }, - mm_input.map { it[6] } + .combine( mm_intermediary.run ) + .multiMap { meta, syntenic_ref, ref -> + syntenic_tuple : tuple( meta, syntenic_ref ) + reference_fa : ref + bool_bam_output : false + bool_cigar_paf : true + bool_cigar_bam : false + } + .set { mm_input } + + // + // MODULE: ALIGNS THE SUNTENIC GENOMES TO THE REFERENCE GENOME + // EMITS ALIGNED PAF FILE + // + MINIMAP2_ALIGN( + mm_input.syntenic_tuple, + mm_input.reference_fa, + mm_input.bool_bam_output, + mm_input.bool_cigar_paf, + mm_input.bool_cigar_bam ) + ch_versions = ch_versions.mix( MINIMAP2_ALIGN.out.versions ) - ch_paf = MINIMAP2_ALIGN.out.paf - ch_versions = MINIMAP2_ALIGN.out.versions - emit: - ch_paf - versions = ch_versions -} \ No newline at end of file + ch_paf = MINIMAP2_ALIGN.out.paf + versions = ch_versions.ifEmpty(null) +} diff --git a/subworkflows/local/telo_finder.nf b/subworkflows/local/telo_finder.nf new file mode 100755 index 00000000..3ecd3048 --- /dev/null +++ b/subworkflows/local/telo_finder.nf @@ -0,0 +1,73 @@ +#!/usr/bin/env nextflow + +// +// MODULE IMPORT BLOCK +// +include { FIND_TELOMERE_REGIONS } from '../../modules/local/find_telomere_regions' +include { FIND_TELOMERE_WINDOWS } from '../../modules/local/find_telomere_windows' +include { EXTRACT_TELO } from '../../modules/local/extract_telo' +include { TABIX_BGZIPTABIX } from '../../modules/nf-core/tabix/bgziptabix' + +workflow TELO_FINDER { + + take: + max_scaff_size // val(size of largest scaffold in bp) + reference_tuple // Channel [ val(meta), path(fasta) ] + teloseq + + main: + ch_versions = Channel.empty() + + // + // MODULE: FINDS THE TELOMERIC SEQEUNCE IN REFERENCE + // + FIND_TELOMERE_REGIONS ( + reference_tuple, + teloseq + ) + ch_versions = ch_versions.mix( FIND_TELOMERE_REGIONS.out.versions ) + + // + // MODULE: GENERATES A WINDOWS FILE FROM THE ABOVE + // + FIND_TELOMERE_WINDOWS ( + FIND_TELOMERE_REGIONS.out.telomere + ) + ch_versions = ch_versions.mix( FIND_TELOMERE_WINDOWS.out.versions ) + + // + // MODULE: EXTRACTS THE LOCATION OF TELOMERIC SEQUENCE BASED ON THE WINDOWS + // + EXTRACT_TELO ( + FIND_TELOMERE_WINDOWS.out.windows + ) + ch_versions = ch_versions.mix( EXTRACT_TELO.out.versions ) + + // + // LOGIC: Adding the largest scaffold size to the meta data so it can be used in the modules.config + // + EXTRACT_TELO.out.bed + .combine(max_scaff_size) + .map {meta, row, scaff -> + tuple( + [ id : meta.id, + max_scaff : scaff >= 500000000 ? 'csi': '' ], + file( row ) + ) + } + .set { modified_bed_ch } + + // + // MODULE: BGZIP AND TABIX THE OUTPUT FILE + // + TABIX_BGZIPTABIX ( + modified_bed_ch + ) + ch_versions = ch_versions.mix( TABIX_BGZIPTABIX.out.versions ) + + emit: + bedgraph_file = EXTRACT_TELO.out.bed + bed_gz_tbi = TABIX_BGZIPTABIX.out.gz_tbi + bedgraph_file = EXTRACT_TELO.out.bedgraph + versions = ch_versions.ifEmpty(null) +} diff --git a/subworkflows/local/yaml_input.nf b/subworkflows/local/yaml_input.nf old mode 100644 new mode 100755 index 64ab06c4..ffe02e71 --- a/subworkflows/local/yaml_input.nf +++ b/subworkflows/local/yaml_input.nf @@ -1,8 +1,10 @@ +#!/usr/bin/env nextflow + import org.yaml.snakeyaml.Yaml -workflow INPUT_READ { +workflow YAML_INPUT { take: - input_file + input_file // input_yaml_from_commandline main: ch_versions = Channel.empty() @@ -11,26 +13,31 @@ workflow INPUT_READ { .map { file -> readYAML(file) } .set { yamlfile } - // Parse top layer of yaml + // + // LOGIC: PARSES THE TOP LEVEL OF YAML VALUES + // yamlfile .flatten() - .multiMap { data -> + .multiMap { data -> assembly: ( data.assembly ) assembly_reads: ( data.assem_reads ) reference: ( file(data.reference_file) ) alignment: ( data.alignment ) self_comp: ( data.self_comp ) synteny: ( data.synteny ) - intron: data.intron_size + intron: ( data.intron ) + busco_gene: ( data.busco ) + teloseq: ( data.telomere ) } .set{ group } - // Parse 2nd layer + // + // LOGIC: PARSES THE SECOND LEVEL OF YAML VALUES PER ABOVE OUTPUT CHANNEL + // group .assembly .multiMap { data -> level: data.level - size_c: data.sizeClass sample_id: data.sample_id classT: data.classT asmVersion: data.asmVersion @@ -40,18 +47,18 @@ workflow INPUT_READ { .set { assembly_data } group - .assem_reads - .multiMap { data -> - pacbio: data.pacbio - hic: data.hic - supplement: data.supplementary + .assembly_reads + .multiMap { data -> + pacbio: data.pacbio + hic: data.hic + supplement: data.supplementary } - .set { assembly_reads } + .set { assem_reads } group .alignment .multiMap { data -> - data_dir: data.data_dir + data_dir: data.data_dir common_name: data.common_name geneset: data.geneset } @@ -60,30 +67,57 @@ workflow INPUT_READ { group .self_comp .multiMap { data -> - motif_len: data.motif_len - mummer_chunk: data.mummer_chunk + motif_len: data.motif_len + mummer_chunk: data.mummer_chunk } .set{ selfcomp_data } group .synteny - .multiMap { data -> - synteny_genome: data.synteny_genome_path + .multiMap { data -> + synteny_genome: data.synteny_genome_path } .set{ synteny_data } + group + .intron + .multiMap { data -> + size: data.size + } + .set { intron_size } + + group + .teloseq + .multiMap { data -> + teloseq: data.teloseq + } + .set { teloseq } + + group + .busco_gene + .multiMap { data -> + lineage: data.lineage + lineages_path: data.lineages_path + } + .set { busco_lineage } + + assembly_data.sample_id + .combine( assembly_data.asmVersion ) + .map { it1, it2 -> + ("${it1}_${it2}")} + .set { tolid_version} + emit: - assembly_id = assembly_data.sample_id - assembly_sizeClass = assembly_data.size_c + assembly_id = tolid_version assembly_classT = assembly_data.classT assembly_level = assembly_data.level assembly_asmVer = assembly_data.asmVersion assembly_dbVer = assembly_data.dbVersion - assembly_gtype = assembly_data.gevalType + assembly_ttype = assembly_data.gevalType - pacbio_reads = assembly_reads.pacbio - hic_reads = assembly_reads.hic - supp_reads = assembly_reads.supplement + pacbio_reads = assem_reads.pacbio + hic_reads = assem_reads.hic + supp_reads = assem_reads.supplement reference = group.reference @@ -96,11 +130,16 @@ workflow INPUT_READ { synteny_path = synteny_data.synteny_genome - intron_size = group.intron + intron_size = intron_size.size + + teloseq = teloseq.teloseq + + lineageinfo = busco_lineage.lineage + lineagespath = busco_lineage.lineages_path versions = ch_versions.ifEmpty(null) } def readYAML( yamlfile ) { return new Yaml().load( new FileReader( yamlfile.toString() ) ) -} \ No newline at end of file +} diff --git a/tower.yml b/tower.yml new file mode 100755 index 00000000..787aedfe --- /dev/null +++ b/tower.yml @@ -0,0 +1,5 @@ +reports: + multiqc_report.html: + display: "MultiQC HTML report" + samplesheet.csv: + display: "Auto-created samplesheet with collated metadata and FASTQ paths" diff --git a/workflows/treeval.nf b/workflows/treeval.nf old mode 100644 new mode 100755 index bdeca5d1..fc3901d3 --- a/workflows/treeval.nf +++ b/workflows/treeval.nf @@ -10,7 +10,8 @@ def summary_params = NfcoreSchema.paramsSummaryMap(workflow, params) WorkflowTreeval.initialise(params, log) // Check input path parameters to see if they exist -def checkPathParamList = [ params.input, params.multiqc_config, params.fasta ] +// params.input is the treeval yaml +def checkPathParamList = [ params.input ] for (param in checkPathParamList) { if (param) { file(param, checkIfExists: true) } } /* @@ -20,15 +21,20 @@ for (param in checkPathParamList) { if (param) { file(param, checkIfExists: true */ // -// SUBWORKFLOW: Consisting of a mix of local and nf-core/modules +// IMPORT: SUBWORKFLOWS CALLED BY THE MAIN // -include { INPUT_READ } from '../subworkflows/local/yaml_input' +include { YAML_INPUT } from '../subworkflows/local/yaml_input' include { GENERATE_GENOME } from '../subworkflows/local/generate_genome' include { INSILICO_DIGEST } from '../subworkflows/local/insilico_digest' include { GENE_ALIGNMENT } from '../subworkflows/local/gene_alignment' include { SELFCOMP } from '../subworkflows/local/selfcomp' include { SYNTENY } from '../subworkflows/local/synteny' -// include { LONGREAD_COVERAGE } from '../subworkflows/local/longread_coverage' +include { LONGREAD_COVERAGE } from '../subworkflows/local/longread_coverage' +include { REPEAT_DENSITY } from '../subworkflows/local/repeat_density' +include { GAP_FINDER } from '../subworkflows/local/gap_finder' +include { TELO_FINDER } from '../subworkflows/local/telo_finder' +include { BUSCO_ANNOTATION } from '../subworkflows/local/busco_annotation' +include { HIC_MAPPING } from '../subworkflows/local/hic_mapping' /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -37,9 +43,9 @@ include { SYNTENY } from '../subworkflows/local/synteny' */ // -// MODULE: Installed directly from nf-core/modules +// IMPORT: Installed directly from nf-core/modules // -include { CUSTOM_DUMPSOFTWAREVERSIONS } from '../modules/nf-core/modules/custom/dumpsoftwareversions/main' +include { CUSTOM_DUMPSOFTWAREVERSIONS } from '../modules/nf-core/custom/dumpsoftwareversions/main' /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -48,93 +54,185 @@ include { CUSTOM_DUMPSOFTWAREVERSIONS } from '../modules/nf-core/modules/custom/ */ workflow TREEVAL { - + main: // // PRE-PIPELINE CHANNEL SETTING - channel setting for required files // - ch_versions = Channel.empty() + ch_versions = Channel.empty() - input_ch = Channel.fromPath(params.input, checkIfExists: true) + params.entry = 'FULL' + input_ch = Channel.fromPath(params.input, checkIfExists: true) Channel - .fromPath( 'assets/gene_alignment/assm_*.as', checkIfExists: true) - .map { it -> + .fromPath( "${projectDir}/assets/gene_alignment/assm_*.as", checkIfExists: true) + .map { it -> tuple ([ type : it.toString().split('/')[-1].split('_')[-1].split('.as')[0] ], file(it) )} .set { gene_alignment_asfiles } - + Channel - .fromPath( 'assets/digest/digest.as', checkIfExists: true ) + .fromPath( "${projectDir}/assets/digest/digest.as", checkIfExists: true ) .set { digest_asfile } Channel - .fromPath( 'assets/self_comp/selfcomp.as', checkIfExists: true ) + .fromPath( "${projectDir}/assets/self_comp/selfcomp.as", checkIfExists: true ) .set { selfcomp_asfile } + Channel + .fromPath( "${projectDir}/assets/busco_gene/busco.as", checkIfExists: true ) + .set { buscogene_asfile } + + Channel + .fromPath( "${projectDir}/assets/busco_gene/lep_ancestral.tsv", checkIfExists: true ) + .set { ancestral_table } + // // SUBWORKFLOW: reads the yaml and pushing out into a channel per yaml field // - INPUT_READ ( input_ch ) + YAML_INPUT ( + input_ch + ) // // SUBWORKFLOW: Takes input fasta file and sample ID to generate a my.genome file - // - GENERATE_GENOME ( INPUT_READ.out.assembly_id, INPUT_READ.out.reference ) - ch_versions = ch_versions.mix(GENERATE_GENOME.out.versions) + // + GENERATE_GENOME ( + YAML_INPUT.out.assembly_id, + YAML_INPUT.out.reference + ) + ch_versions = ch_versions.mix( GENERATE_GENOME.out.versions ) + // + // SUBWORKFLOW: Takes reference, channel of enzymes, my.genome, assembly_id and as file to generate + // file with enzymatic digest sites. + // + ch_enzyme = Channel.of( "bspq1","bsss1","DLE1" ) + + INSILICO_DIGEST ( + YAML_INPUT.out.assembly_id, + GENERATE_GENOME.out.dot_genome, + GENERATE_GENOME.out.reference_tuple, + ch_enzyme, + digest_asfile + ) + ch_versions = ch_versions.mix( INSILICO_DIGEST.out.versions ) // - // SUBWORKFLOW: + // SUBWORKFLOW: FOR SPLITTING THE REF GENOME INTO SCAFFOLD CHUNKS AND RUNNING SOME SUBWORKFLOWS + // ON THOSE CHUNKS + // THIS WILL BE REQUIRED FOR LARGER GENOMES EST > 6GB // - ch_enzyme = Channel.of( "bspq1","bsss1","DLE1" ) - INSILICO_DIGEST ( INPUT_READ.out.assembly_id, - GENERATE_GENOME.out.dot_genome, - GENERATE_GENOME.out.reference_tuple, - ch_enzyme, - digest_asfile ) - ch_versions = ch_versions.mix(INSILICO_DIGEST.out.versions) - + // REFERENCE_GENOME_SPLIT --> SELFCOMP + // --> GENE_ALIGNMENT + // BOTH WOULD REQUIRE A POST SUBWORKFLOW MERGE STEP TO MERGE TOGETHER THE SCAFFOLD + // BASED ALIGNMENTS/SELFCOMPS INTO A GENOME REPRESENTATIVE ONE. + // FOR GENE ALIGNMENT WOULD THIS REQUIRE A .GENOME FILE AND INDEX PER SCAFFOLD? + // // SUBWORKFLOW: Takes input fasta to generate BB files containing alignment data // - INPUT_READ.out.intron_size.view() + GENE_ALIGNMENT ( + GENERATE_GENOME.out.dot_genome, + GENERATE_GENOME.out.reference_tuple, + GENERATE_GENOME.out.ref_index, + GENERATE_GENOME.out.max_scaff_size, + YAML_INPUT.out.assembly_classT, + YAML_INPUT.out.align_data_dir, + YAML_INPUT.out.align_geneset, + YAML_INPUT.out.align_common, + YAML_INPUT.out.intron_size, + gene_alignment_asfiles + ) + ch_versions = ch_versions.mix(GENERATE_GENOME.out.versions) + + // + // SUBWORKFLOW: GENERATES A BIGWIG FOR A REPEAT DENSITY TRACK + // + REPEAT_DENSITY ( + GENERATE_GENOME.out.reference_tuple, + GENERATE_GENOME.out.dot_genome + ) + ch_versions = ch_versions.mix(REPEAT_DENSITY.out.versions) + + // + // SUBWORKFLOW: GENERATES A GAP.BED FILE TO ID THE LOCATIONS OF GAPS + // + GAP_FINDER ( + GENERATE_GENOME.out.reference_tuple, + GENERATE_GENOME.out.max_scaff_size + ) + ch_versions = ch_versions.mix(GAP_FINDER.out.versions) + + // + // SUBWORKFLOW: Takes reference file, .genome file, mummer variables, motif length variable and as + // file to generate a file containing sites of self-complementary sequnce. + // + SELFCOMP ( + GENERATE_GENOME.out.reference_tuple, + GENERATE_GENOME.out.dot_genome, + YAML_INPUT.out.mummer_chunk, + YAML_INPUT.out.motif_len, + selfcomp_asfile + ) + ch_versions = ch_versions.mix(SELFCOMP.out.versions) - GENE_ALIGNMENT ( GENERATE_GENOME.out.dot_genome, - GENERATE_GENOME.out.reference_tuple, - INPUT_READ.out.assembly_classT, - INPUT_READ.out.align_data_dir, - INPUT_READ.out.align_geneset, - INPUT_READ.out.align_common, - INPUT_READ.out.intron_size, - gene_alignment_asfiles ) - - ch_versions = ch_versions.mix(GENERATE_GENOME.out.versions) + // + // SUBWORKFLOW: Takes reference, the directory of syntenic genomes and order/clade of sequence + // and generated a file of syntenic blocks. + // + SYNTENY ( + GENERATE_GENOME.out.reference_tuple, + YAML_INPUT.out.synteny_path, + YAML_INPUT.out.assembly_classT + ) + ch_versions = ch_versions.mix(SYNTENY.out.versions) // - // SUBWORKFLOW: + // SUBWORKFLOW: Takes reference, pacbio reads // - SELFCOMP ( GENERATE_GENOME.out.reference_tuple, - GENERATE_GENOME.out.dot_genome, - INPUT_READ.out.mummer_chunk, - INPUT_READ.out.motif_len, - selfcomp_asfile ) - ch_versions = ch_versions.mix(SELFCOMP.out.versions) - + LONGREAD_COVERAGE ( + GENERATE_GENOME.out.reference_tuple, + GENERATE_GENOME.out.dot_genome, + YAML_INPUT.out.pacbio_reads + ) + ch_versions = ch_versions.mix(LONGREAD_COVERAGE.out.versions) + // - // SUBWORKFLOW: + // SUBWORKFLOW: GENERATE HIC MAPPING TO GENERATE PRETEXT FILES AND JUICEBOX // - SYNTENY ( GENERATE_GENOME.out.reference_tuple, - INPUT_READ.out.synteny_path, - INPUT_READ.out.assembly_classT) - ch_versions = ch_versions.mix(SYNTENY.out.versions) + HIC_MAPPING ( + GENERATE_GENOME.out.reference_tuple, + GENERATE_GENOME.out.ref_index, + GENERATE_GENOME.out.dot_genome, + YAML_INPUT.out.hic_reads, + YAML_INPUT.out.assembly_id, + params.entry + ) + ch_versions = ch_versions.mix(HIC_MAPPING.out.versions) // - // SUBWORKFLOW: + // SUBWORKFLOW: GENERATE TELOMERE WINDOW FILES WITH PACBIO READS AND REFERENCE // - // LONGREAD_COVERAGE ( GENERATE_GENOME.out.reference_tuple, - // PACBIO.READ.DIRECTORY, - // INPUT_READ.out.sizeClass ) + TELO_FINDER ( GENERATE_GENOME.out.max_scaff_size, + GENERATE_GENOME.out.reference_tuple, + YAML_INPUT.out.teloseq + ) + ch_versions = ch_versions.mix(TELO_FINDER.out.versions) + + // + // SUBWORKFLOW: GENERATE BUSCO ANNOTATION FOR ANCESTRAL UNITS + // + BUSCO_ANNOTATION ( + GENERATE_GENOME.out.dot_genome, + GENERATE_GENOME.out.reference_tuple, + YAML_INPUT.out.assembly_classT, + YAML_INPUT.out.lineageinfo, + YAML_INPUT.out.lineagespath, + buscogene_asfile, + ancestral_table + ) + ch_versions = ch_versions.mix(BUSCO_ANNOTATION.out.versions) // // SUBWORKFLOW: Collates version data from prior subworflows @@ -142,6 +240,40 @@ workflow TREEVAL { CUSTOM_DUMPSOFTWAREVERSIONS ( ch_versions.unique().collectFile(name: 'collated_versions.yml') ) + + // + // LOGIC: GENERATE SOME CHANNELS FOR REPORTING + // + GENERATE_GENOME.out.reference_tuple + .combine( YAML_INPUT.out.assembly_classT ) + .combine( YAML_INPUT.out.assembly_ttype ) + .combine( YAML_INPUT.out.assembly_id ) + .combine( LONGREAD_COVERAGE.out.ch_reporting ) + .combine( HIC_MAPPING.out.ch_reporting ) + .combine( CUSTOM_DUMPSOFTWAREVERSIONS.out.versions ) + .map { meta, reference, lineage, ticket, sample_id, longread_meta, longread_files, hic_meta, hic_files, custom_file -> [ + rf_data: tuple( + [ id: meta.id, + sz: file(reference).size(), + ln: lineage, + tk: ticket ], + reference + ), + sample_id: sample_id, + pb_data: tuple(longread_meta, longread_files), + cm_data: tuple(hic_meta, hic_files), + custom: custom_file, + ] + } + .set { collected_metrics_ch } + + collected_metrics_ch.map { metrics -> + TreeValProject.summary(workflow, params, metrics, log) + } + + emit: + software_ch = CUSTOM_DUMPSOFTWAREVERSIONS.out.yml + versions_ch = CUSTOM_DUMPSOFTWAREVERSIONS.out.versions } /* @@ -152,9 +284,13 @@ workflow TREEVAL { workflow.onComplete { if (params.email || params.email_on_fail) { - NfcoreTemplate.email(workflow, params, summary_params, projectDir, log) + NfcoreTemplate.email(workflow, params, summary_params, projectDir, log, multiqc_report) } + NfcoreTemplate.summary(workflow, params, log) + if (params.hook_url) { + NfcoreTemplate.IM_notification(workflow, params, summary_params, projectDir, log) + } } /* diff --git a/workflows/treeval_rapid.nf b/workflows/treeval_rapid.nf new file mode 100755 index 00000000..ed3497c4 --- /dev/null +++ b/workflows/treeval_rapid.nf @@ -0,0 +1,185 @@ +/* +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + VALIDATE INPUTS +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +*/ + +def summary_params = NfcoreSchema.paramsSummaryMap(workflow, params) + +// Validate input parameters +WorkflowTreeval.initialise(params, log) + +// Check input path parameters to see if they exist +def checkPathParamList = [ params.input ] +for (param in checkPathParamList) { if (param) { file(param, checkIfExists: true) } } + +/* +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + IMPORT LOCAL MODULES/SUBWORKFLOWS +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +*/ + +// +// IMPORT: SUBWORKFLOWS CALLED BY THE MAIN +// +include { YAML_INPUT } from '../subworkflows/local/yaml_input' +include { GENERATE_GENOME } from '../subworkflows/local/generate_genome' +include { REPEAT_DENSITY } from '../subworkflows/local/repeat_density' +include { GAP_FINDER } from '../subworkflows/local/gap_finder' +include { LONGREAD_COVERAGE } from '../subworkflows/local/longread_coverage' +include { TELO_FINDER } from '../subworkflows/local/telo_finder' +include { HIC_MAPPING } from '../subworkflows/local/hic_mapping' + +/* +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + IMPORT NF-CORE MODULES/SUBWORKFLOWS +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +*/ + +// +// IMPORT: Installed directly from nf-core/modules +// +include { CUSTOM_DUMPSOFTWAREVERSIONS } from '../modules/nf-core/custom/dumpsoftwareversions/main' + +/* +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + RUN MAIN WORKFLOW +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +*/ + +workflow TREEVAL_RAPID { + + main: + ch_versions = Channel.empty() + + params.entry = 'RAPID' + input_ch = Channel.fromPath(params.input, checkIfExists: true) + // + // SUBWORKFLOW: reads the yaml and pushing out into a channel per yaml field + // + YAML_INPUT ( input_ch ) + + // + // SUBWORKFLOW: Takes input fasta file and sample ID to generate a my.genome file + // + GENERATE_GENOME ( + YAML_INPUT.out.assembly_id, + YAML_INPUT.out.reference + ) + ch_versions = ch_versions.mix(GENERATE_GENOME.out.versions) + + // + // SUBWORKFLOW: GENERATES A BIGWIG FOR A REPEAT DENSITY TRACK + // + REPEAT_DENSITY ( + GENERATE_GENOME.out.reference_tuple, + GENERATE_GENOME.out.dot_genome + ) + ch_versions = ch_versions.mix(REPEAT_DENSITY.out.versions) + + // + // SUBWORKFLOW: GENERATES A GAP.BED FILE TO ID THE LOCATIONS OF GAPS + // + GAP_FINDER ( + GENERATE_GENOME.out.reference_tuple, + GENERATE_GENOME.out.max_scaff_size + ) + ch_versions = ch_versions.mix(GAP_FINDER.out.versions) + + // + // SUBWORKFLOW: GENERATE TELOMERE WINDOW FILES WITH PACBIO READS AND REFERENCE + // + TELO_FINDER ( + GENERATE_GENOME.out.max_scaff_size, + GENERATE_GENOME.out.reference_tuple, + YAML_INPUT.out.teloseq + ) + ch_versions = ch_versions.mix(TELO_FINDER.out.versions) + + // + // SUBWORKFLOW: GENERATE HIC MAPPING TO GENERATE PRETEXT FILES AND JUICEBOX + // + HIC_MAPPING ( + GENERATE_GENOME.out.reference_tuple, + GENERATE_GENOME.out.ref_index, + GENERATE_GENOME.out.dot_genome, + YAML_INPUT.out.hic_reads, + YAML_INPUT.out.assembly_id, + params.entry + ) + ch_versions = ch_versions.mix(HIC_MAPPING.out.versions) + + // + // SUBWORKFLOW: Takes reference, pacbio reads + // + LONGREAD_COVERAGE ( + GENERATE_GENOME.out.reference_tuple, + GENERATE_GENOME.out.dot_genome, + YAML_INPUT.out.pacbio_reads + ) + ch_versions = ch_versions.mix(LONGREAD_COVERAGE.out.versions) + + // + // SUBWORKFLOW: Collates version data from prior subworflows + // + CUSTOM_DUMPSOFTWAREVERSIONS ( + ch_versions.unique().collectFile(name: 'collated_versions.yml') + ) + + // + // LOGIC: GENERATE SOME CHANNELS FOR REPORTING + // + GENERATE_GENOME.out.reference_tuple + .combine( YAML_INPUT.out.assembly_classT ) + .combine( YAML_INPUT.out.assembly_ttype ) + .combine( YAML_INPUT.out.assembly_id ) + .combine( LONGREAD_COVERAGE.out.ch_reporting ) + .combine( HIC_MAPPING.out.ch_reporting ) + .combine( CUSTOM_DUMPSOFTWAREVERSIONS.out.versions ) + .map { meta, reference, lineage, ticket, sample_id, longread_meta, longread_files, hic_meta, hic_files, custom_file -> [ + rf_data: tuple( + [ id: meta.id, + sz: file(reference).size(), + ln: lineage, + tk: ticket ], + reference + ), + sample_id: sample_id, + pb_data: tuple(longread_meta, longread_files), + cm_data: tuple(hic_meta, hic_files), + custom: custom_file, + ] + } + .set { collected_metrics_ch } + + collected_metrics_ch.map { metrics -> + TreeValProject.summary(workflow, params, metrics, log) + } + + emit: + software_ch = CUSTOM_DUMPSOFTWAREVERSIONS.out.yml + versions_ch = CUSTOM_DUMPSOFTWAREVERSIONS.out.versions +} + +/* +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + COMPLETION EMAIL AND SUMMARY +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +*/ + +workflow.onComplete { + if (params.email || params.email_on_fail) { + NfcoreTemplate.email(workflow, params, summary_params, projectDir, log) + } + + NfcoreTemplate.summary(workflow, params, log) + if (params.hook_url) { + NfcoreTemplate.IM_notification(workflow, params, summary_params, projectDir, log) + } +} + +/* +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + THE END +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +*/