eva-sub-cli 0.4.9__tar.gz → 0.4.11__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- eva_sub_cli-0.4.11/.github/workflows/publish_docs.yml +50 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/.github/workflows/trigger-eva-sub-cli-integration-tests.yml +2 -2
- eva_sub_cli-0.4.11/PKG-INFO +35 -0
- eva_sub_cli-0.4.11/README.md +3 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/docker/Dockerfile +1 -1
- eva_sub_cli-0.4.11/docs/README.md +10 -0
- eva_sub_cli-0.4.11/docs/_config.yml +1 -0
- eva_sub_cli-0.4.11/docs/how_to_submit.md +89 -0
- eva_sub_cli-0.4.11/docs/input_file_overview.md +45 -0
- eva_sub_cli-0.4.11/docs/installation.md +49 -0
- eva_sub_cli-0.4.11/docs/using_nextflow.md +48 -0
- eva_sub_cli-0.4.9/docs/Getting_Started_with_eva_sub_cli.md → eva_sub_cli-0.4.11/docs/validation_overview.md +5 -54
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/_version.py +2 -2
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/etc/eva_schema.json +9 -1
- eva_sub_cli-0.4.11/eva_sub_cli/executables/evidence_type_checker.py +51 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/executables/samples_checker.py +33 -12
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/file_utils.py +80 -2
- eva_sub_cli-0.4.11/eva_sub_cli/jinja_templates/html/project_details.html +65 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/jinja_templates/html/report.html +1 -1
- eva_sub_cli-0.4.11/eva_sub_cli/jinja_templates/text/project_details.txt +37 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/jinja_templates/text/report.txt +1 -1
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/metadata.py +4 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/nextflow/validation.nf +21 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/report.py +15 -11
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/semantic_metadata.py +26 -3
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/validators/docker_validator.py +1 -1
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/validators/validator.py +67 -9
- eva_sub_cli-0.4.11/eva_sub_cli.egg-info/PKG-INFO +35 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli.egg-info/SOURCES.txt +11 -1
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli.egg-info/entry_points.txt +1 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli.egg-info/requires.txt +1 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/pyproject.toml +1 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/requirements.txt +2 -1
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/validation_reports/expected_report_metadata_json.html +19 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/validation_reports/expected_report_metadata_json.txt +6 -0
- eva_sub_cli-0.4.9/tests/resources/validation_reports/expected_shallow_metadata_xlsx_report.html → eva_sub_cli-0.4.11/tests/resources/validation_reports/expected_report_metadata_xlsx.html +19 -24
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/validation_reports/expected_report_metadata_xlsx.txt +6 -0
- eva_sub_cli-0.4.9/tests/resources/validation_reports/expected_report_metadata_xlsx.html → eva_sub_cli-0.4.11/tests/resources/validation_reports/expected_shallow_metadata_xlsx_report.html +43 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/validation_reports/expected_shallow_metadata_xlsx_report.txt +6 -0
- eva_sub_cli-0.4.11/tests/resources/validation_reports/validation_output/other_validations/evidence_type_checker.yml +3 -0
- eva_sub_cli-0.4.11/tests/test_evidence_type_checker.py +66 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/test_report.py +28 -2
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/test_semantic_metadata.py +79 -4
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/test_validator.py +29 -11
- eva_sub_cli-0.4.9/PKG-INFO +0 -215
- eva_sub_cli-0.4.9/README.md +0 -184
- eva_sub_cli-0.4.9/eva_sub_cli/jinja_templates/html/project_details.html +0 -37
- eva_sub_cli-0.4.9/eva_sub_cli/jinja_templates/text/project_details.txt +0 -21
- eva_sub_cli-0.4.9/eva_sub_cli.egg-info/PKG-INFO +0 -215
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/.github/workflows/publish.yml +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/.github/workflows/publish_packages.yml +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/.github/workflows/tests.yml +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/.gitignore +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/LICENSE +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/conda/build.sh +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/conda/meta.yaml +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/__init__.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/auth.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/date_utils.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/etc/EVA_Submission_Example.xlsx +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/etc/EVA_Submission_template.xlsx +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/etc/eva-biosamples.json +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/etc/eva_logo.png +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/etc/spreadsheet2json_conf.yaml +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/exceptions/__init__.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/exceptions/invalid_file_type_exception.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/exceptions/metadata_template_version_exception.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/exceptions/submission_not_found_exception.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/exceptions/submission_status_exception.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/executables/__init__.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/executables/check_fasta_insdc.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/executables/check_metadata_semantics.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/executables/cli.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/executables/trim_down.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/executables/xlsx2json.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/jinja_templates/html/fasta_check.html +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/jinja_templates/html/file_validation.html +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/jinja_templates/html/metadata_validation.html +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/jinja_templates/html/sample_name_check.html +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/jinja_templates/html/shallow_validation.html +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/jinja_templates/text/fasta_check.txt +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/jinja_templates/text/file_validation.txt +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/jinja_templates/text/metadata_validation.txt +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/jinja_templates/text/sample_name_check.txt +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/jinja_templates/text/shallow_validation.txt +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/orchestrator.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/submission_ws.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/submit.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/validators/__init__.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/validators/native_validator.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli/validators/validation_results_parsers.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli.egg-info/dependency_links.txt +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/eva_sub_cli.egg-info/top_level.txt +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/pytest.ini +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/setup.cfg +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/setup.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/build_and_test_docker_locally.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/ignore_test_nextflow_validation.yml +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/EVA_Submission_Docker_Test.xlsx +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/EVA_Submission_test.json +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/EVA_Submission_test.xlsx +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/EVA_Submission_test_fails.xlsx +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/EVA_Submission_test_version_missing.xlsx +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/EVA_Submission_test_with_asm_report.json +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/assembly_check/invalid.vcf.assembly_check.log +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/assembly_check/invalid.vcf.text_assembly_report.txt +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/assembly_reports/input_passed.txt +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/fasta_files/Saccharomyces_cerevisiae_I.fa +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/fasta_files/input_passed.fa +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/fasta_files/multi_seq.fa +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/metadata_with_filename.json +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/sample_checker/example1.vcf.gz +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/sample_checker/example2.vcf +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/sample_checker/example3.vcf +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/sample_checker/metadata.json +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/validation_reports/validation_output/assembly_check/input_passed.vcf.assembly_check.log +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/validation_reports/validation_output/assembly_check/input_passed.vcf.text_assembly_report.1680102476700.txt +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/validation_reports/validation_output/assembly_check/input_passed.vcf.valid_assembly_report.1680102476700.txt +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/validation_reports/validation_output/other_validations/input_passed.fa_check.yml +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/validation_reports/validation_output/other_validations/metadata_conversion_errors.yml +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/validation_reports/validation_output/other_validations/metadata_semantic_check.yml +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/validation_reports/validation_output/other_validations/metadata_validation.txt +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/validation_reports/validation_output/other_validations/sample_checker.yml +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/validation_reports/validation_output/vcf_format/input_passed.vcf.errors.1680102476854.db +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/validation_reports/validation_output/vcf_format/input_passed.vcf.errors.1680102476854.txt +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/validation_reports/validation_output/vcf_format/input_passed.vcf.vcf_format.log +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/vcf_files/example2.vcf.gz +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/resources/vcf_files/input_passed.vcf +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/test_auth.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/test_check_fasta_insdc.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/test_cli.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/test_docker_validator.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/test_file_utils.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/test_metadata.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/test_orchestrator.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/test_samples_checker.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/test_submit.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/test_trim_down.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/test_utils.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/test_validaton_results_parsers.py +0 -0
- {eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/tests/test_xlsx2json.py +0 -0
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
name: Deploy documentation with Jekyll / GitHub Pages
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
tags:
|
|
6
|
+
- '**'
|
|
7
|
+
|
|
8
|
+
# Allows you to run this workflow manually from the Actions tab
|
|
9
|
+
workflow_dispatch:
|
|
10
|
+
|
|
11
|
+
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
|
|
12
|
+
permissions:
|
|
13
|
+
contents: read
|
|
14
|
+
pages: write
|
|
15
|
+
id-token: write
|
|
16
|
+
|
|
17
|
+
# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
|
|
18
|
+
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
|
|
19
|
+
concurrency:
|
|
20
|
+
group: "pages"
|
|
21
|
+
cancel-in-progress: false
|
|
22
|
+
|
|
23
|
+
jobs:
|
|
24
|
+
# Build job
|
|
25
|
+
build:
|
|
26
|
+
runs-on: ubuntu-latest
|
|
27
|
+
steps:
|
|
28
|
+
- name: Checkout
|
|
29
|
+
uses: actions/checkout@v4
|
|
30
|
+
- name: Setup Pages
|
|
31
|
+
uses: actions/configure-pages@v5
|
|
32
|
+
- name: Build with Jekyll
|
|
33
|
+
uses: actions/jekyll-build-pages@v1
|
|
34
|
+
with:
|
|
35
|
+
source: ./docs
|
|
36
|
+
destination: ./_site
|
|
37
|
+
- name: Upload artifact
|
|
38
|
+
uses: actions/upload-pages-artifact@v3
|
|
39
|
+
|
|
40
|
+
# Deployment job
|
|
41
|
+
deploy:
|
|
42
|
+
environment:
|
|
43
|
+
name: github-pages
|
|
44
|
+
url: ${{ steps.deployment.outputs.page_url }}
|
|
45
|
+
runs-on: ubuntu-latest
|
|
46
|
+
needs: build
|
|
47
|
+
steps:
|
|
48
|
+
- name: Deploy to GitHub Pages
|
|
49
|
+
id: deployment
|
|
50
|
+
uses: actions/deploy-pages@v4
|
{eva_sub_cli-0.4.9 → eva_sub_cli-0.4.11}/.github/workflows/trigger-eva-sub-cli-integration-tests.yml
RENAMED
|
@@ -2,7 +2,7 @@ name: Trigger Eva Sub Cli Integration Tests
|
|
|
2
2
|
|
|
3
3
|
on:
|
|
4
4
|
push:
|
|
5
|
-
branches: [main
|
|
5
|
+
branches: [main]
|
|
6
6
|
|
|
7
7
|
jobs:
|
|
8
8
|
trigger-integration-tests:
|
|
@@ -11,6 +11,6 @@ jobs:
|
|
|
11
11
|
- name: Trigger eva sub cli integration tests
|
|
12
12
|
uses: peter-evans/repository-dispatch@v2
|
|
13
13
|
with:
|
|
14
|
-
token: ${{ secrets.
|
|
14
|
+
token: ${{ secrets.WORKFLOW_ACCESS_TOKEN }}
|
|
15
15
|
repository: EBIvariation/eva-integration-tests
|
|
16
16
|
event-type: trigger-eva-sub-cli-tests
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: eva_sub_cli
|
|
3
|
+
Version: 0.4.11
|
|
4
|
+
Summary: EBI EVA - validation and submission command line tool
|
|
5
|
+
Classifier: Development Status :: 5 - Production/Stable
|
|
6
|
+
Classifier: Environment :: Console
|
|
7
|
+
Classifier: Intended Audience :: Science/Research
|
|
8
|
+
Classifier: Natural Language :: English
|
|
9
|
+
Classifier: Operating System :: POSIX :: Linux
|
|
10
|
+
Classifier: Operating System :: MacOS :: MacOS X
|
|
11
|
+
Classifier: Programming Language :: Python :: 3.6
|
|
12
|
+
Classifier: Programming Language :: Python :: 3.7
|
|
13
|
+
Classifier: Programming Language :: Python :: 3.8
|
|
14
|
+
Classifier: Programming Language :: Python :: 3.9
|
|
15
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
16
|
+
Classifier: Topic :: Scientific/Engineering :: Bio-Informatics
|
|
17
|
+
Classifier: Topic :: Communications :: File Sharing
|
|
18
|
+
Classifier: License :: OSI Approved :: Apache Software License
|
|
19
|
+
Requires-Python: >=3.6
|
|
20
|
+
Description-Content-Type: text/markdown
|
|
21
|
+
License-File: LICENSE
|
|
22
|
+
Requires-Dist: ebi_eva_common_pyutils==0.*,>=0.7.3
|
|
23
|
+
Requires-Dist: jinja2==3.*,>=3.0.0
|
|
24
|
+
Requires-Dist: jsonschema==4.*
|
|
25
|
+
Requires-Dist: openpyxl==3.*
|
|
26
|
+
Requires-Dist: pyyaml==6.*
|
|
27
|
+
Requires-Dist: pysam==0.*,>=0.23.3
|
|
28
|
+
Requires-Dist: requests==2.*
|
|
29
|
+
Requires-Dist: packaging==24.*
|
|
30
|
+
Requires-Dist: setuptools-scm
|
|
31
|
+
Dynamic: license-file
|
|
32
|
+
|
|
33
|
+
# eva-sub-cli
|
|
34
|
+
|
|
35
|
+
Please view our [documentation website](https://ebivariation.github.io/eva-sub-cli) for help installing and using eva-sub-cli.
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
# About eva-sub-cli
|
|
2
|
+
The eva-sub-cli tool is a command line interface tool for data validation and upload. The tool enables users to perform
|
|
3
|
+
validation and submission to the EVA directly, without requiring interaction with our helpdesk team.
|
|
4
|
+
|
|
5
|
+
For instructions on how to install eva-sub-cli, see [Installation](installation.md).
|
|
6
|
+
|
|
7
|
+
For instructions on how to use eva-sub-cli to submit data, see [How to Submit](how_to_submit.md).
|
|
8
|
+
|
|
9
|
+
## Contact us
|
|
10
|
+
For help or feedback, please get in touch with us at [eva-helpdesk@ebi.ac.uk](mailto:eva-helpdesk@ebi.ac.uk).
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
remote_theme: just-the-docs/just-the-docs
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
# How to Submit
|
|
2
|
+
|
|
3
|
+
## 1. File preparation
|
|
4
|
+
You should have **one or more VCF files** to submit, as well as a **completed metadata spreadsheet** following [our
|
|
5
|
+
template](https://raw.githubusercontent.com/EBIvariation/eva-sub-cli/main/eva_sub_cli/etc/EVA_Submission_template.xlsx).
|
|
6
|
+
More guidance on these files can be found in the [inputs overview](input_file_overview.md) as well as in the metadata
|
|
7
|
+
template itself.
|
|
8
|
+
|
|
9
|
+
You will also need the **reference sequences in FASTA format** that you used to generate the VCF files. This is required for
|
|
10
|
+
validation, though it will not be submitted.
|
|
11
|
+
|
|
12
|
+
## 2. Setting up
|
|
13
|
+
First [**install eva-sub-cli**](installation.md), or check that you have the latest version installed.
|
|
14
|
+
|
|
15
|
+
You will need an [**ENA Webin account**](https://www.ebi.ac.uk/ena/submit/webin/login) in order to submit, though you
|
|
16
|
+
can run validation without one.
|
|
17
|
+
|
|
18
|
+
Finally, you need to specify a **submission directory**, which is a specific directory associated with each submission.
|
|
19
|
+
This is where all processing will take place, and where configuration and reports will be saved.
|
|
20
|
+
|
|
21
|
+
Crucially, the eva-sub-cli tool requires that there be **only one submission per directory** and
|
|
22
|
+
that the submission directory not be reused. Running multiple submissions from a single directory can result in data
|
|
23
|
+
loss during validation and submission.
|
|
24
|
+
|
|
25
|
+
## 3. Running eva-sub-cli
|
|
26
|
+
The basic command to run validation and submission is as follows:
|
|
27
|
+
```shell
|
|
28
|
+
eva-sub-cli.py --metadata_xlsx <metadata file> --submission_dir <submission directory> --username <webin username> --password <webin password>
|
|
29
|
+
```
|
|
30
|
+
This will run validation and generate a report with the results. The report can be viewed as HTML or plain text. More
|
|
31
|
+
description of the validation checks being performed can be found in the [validation overview](validation_overview.md).
|
|
32
|
+
|
|
33
|
+
**NOTE:** If the validation is successful, this command will automatically submit your data and metadata to EVA. If you
|
|
34
|
+
don't want this, see [below](#running-only-validation-or-only-submission).
|
|
35
|
+
|
|
36
|
+
If your files are large, we also encourage you to use [shallow validation](#shallow-validation) before running full
|
|
37
|
+
validation and submission.
|
|
38
|
+
|
|
39
|
+
## 4. Post submission
|
|
40
|
+
Once you've successfully validated and submitted your data, you will receive an automatic email stating that your data
|
|
41
|
+
has been uploaded. If you don't get this email within a short time, we have very likely **not received your data**, so
|
|
42
|
+
you should get in touch with our [helpdesk](mailto:eva-helpdesk@ebi.ac.uk).
|
|
43
|
+
|
|
44
|
+
If your submission contains **human genotype data**, then you will also need to provide a signed copy of our
|
|
45
|
+
[consent statement](https://docs.google.com/document/d/1UaRmimAe919IZYIH55mDXMe-4sHsRVqaP4moqx2IYE4) via email.
|
|
46
|
+
For more information please see our [submission FAQs](https://www.ebi.ac.uk/eva/?Help#submissionPanel&link=consent-statement-for-human-genotype-data).
|
|
47
|
+
|
|
48
|
+
## Other options
|
|
49
|
+
The above steps are the most common, but there are some other options that you can use to tailor its functionality to
|
|
50
|
+
your needs. A full listing is available by running `eva-sub-cli.py -h`.
|
|
51
|
+
|
|
52
|
+
### Running only validation or only submission
|
|
53
|
+
If you want to run validation without submitting automatically once the validation passes, you can use the `--tasks`
|
|
54
|
+
option. To run only validation:
|
|
55
|
+
```shell
|
|
56
|
+
eva-sub-cli.py --metadata_xlsx <metadata file> --submission_dir <submission directory> --tasks VALIDATE
|
|
57
|
+
```
|
|
58
|
+
To run only submission - note this will **not submit** if you've not yet validated successfully:
|
|
59
|
+
```shell
|
|
60
|
+
eva-sub-cli.py --metadata_xlsx <metadata file> --submission_dir <submission directory> --tasks SUBMIT --username <webin username> --password <webin password>
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
### Shallow validation
|
|
64
|
+
If you are working with large VCF files and find that validation takes a very long time, you can add the
|
|
65
|
+
argument `--shallow` to the command, which will validate only the first 10,000 lines in each VCF. Note that running
|
|
66
|
+
shallow validation will **not** be sufficient for actual submission but will allow you to identify most validation concerns without long run time.
|
|
67
|
+
|
|
68
|
+
### VCF files and reference FASTA
|
|
69
|
+
These can be provided either in the metadata file directly, or on the command line using the `--vcf_files` and
|
|
70
|
+
`--reference_fasta` options. Note that if you are using more than one reference FASTA, you **cannot** use the command
|
|
71
|
+
line options; you must specify which VCF files use which FASTA files in the metadata.
|
|
72
|
+
|
|
73
|
+
VCF files can be either uncompressed or compressed using bgzip.
|
|
74
|
+
Other types of compression are not allowed and will result in errors during validation.
|
|
75
|
+
FASTA files must be uncompressed.
|
|
76
|
+
|
|
77
|
+
### Metadata JSON
|
|
78
|
+
Frequent submitters may be interested in using our [metadata JSON schema](https://github.com/EBIvariation/eva-sub-cli/blob/main/eva_sub_cli/etc/eva_schema.json)
|
|
79
|
+
instead of our spreadsheet template. The metadata requirements are the same regardless of which format you use, you will
|
|
80
|
+
just need to use the `--metadata_json` option instead of the `--metadata_xlsx` option.
|
|
81
|
+
|
|
82
|
+
### Running using Docker
|
|
83
|
+
If you've installed eva-sub-cli using Docker, make sure that Docker is running in the background before running
|
|
84
|
+
eva-sub-cli, e.g. by opening Docker Desktop. Additionally, for each eva-sub-cli command, add the command line option
|
|
85
|
+
`--executor docker`, which will fetch and manage the Docker container for you.
|
|
86
|
+
|
|
87
|
+
### Using Nextflow
|
|
88
|
+
Under the hood, eva-sub-cli uses Nextflow to run validation, which you can configure on the command line using the
|
|
89
|
+
`--nextflow_config` option. For more information, please see [here](using_nextflow.md).
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
# Overview of Input Files
|
|
2
|
+
|
|
3
|
+
The eva-sub-cli tool requires the following inputs:
|
|
4
|
+
|
|
5
|
+
- One or several valid VCF files
|
|
6
|
+
- Completed metadata spreadsheet
|
|
7
|
+
- Reference genome in fasta format
|
|
8
|
+
|
|
9
|
+
VCF files can be either uncompressed or compressed using bgzip.
|
|
10
|
+
Other types of compression are not allowed and will result in errors during validation.
|
|
11
|
+
FASTA files must be uncompressed.
|
|
12
|
+
|
|
13
|
+
The VCF file must adhere to official VCF specifications, and the metadata spreadsheet provides contextual information about the dataset. In the following sections, we will examine each of these inputs in detail.
|
|
14
|
+
|
|
15
|
+
# VCF File
|
|
16
|
+
|
|
17
|
+
A VCF (Variant Call Format) file is a type of file used in bioinformatics to store information about genetic variants. It includes data about the differences (or variants) between a sample's DNA and a reference genome. Typically, generating a VCF file involves several steps: preparing your sample, sequencing the DNA, aligning it to a reference genome, identifying variants, and finally, formatting this information into a VCF file. The overall goal is to systematically capture and record genetic differences in a standardised format. A VCF file consists of two main parts: the header and the body.
|
|
18
|
+
|
|
19
|
+
Header: The header contains metadata about the file, such as the format version, reference genome information, and descriptions of the data fields. Each line in the header starts with a double ##, except for the last header line which starts with a single #.
|
|
20
|
+
|
|
21
|
+
```
|
|
22
|
+
##fileformat=VCFv4.2
|
|
23
|
+
##INFO=<ID=DP,Number=1,Type=Integer,Description="Total Depth">
|
|
24
|
+
##FILTER=<ID=PASS,Description="All filters passed">
|
|
25
|
+
##FORMAT=<ID=GT,Number=1,Type=String,Description="Genotype">
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
Body: The body of the VCF file contains the actual variant data, with each row representing a single variant. The columns in the body are: CHROM, POS, ID, REF, ALT, QUAL, FILTER, INFO, FORMAT, Sample Columns
|
|
29
|
+
|
|
30
|
+
```
|
|
31
|
+
#CHROM POS ID REF ALT QUAL FILTER INFO FORMAT [SampleIDs...]
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
# Metadata Spreadsheet
|
|
35
|
+
|
|
36
|
+
The spreadsheet provides comprehensive contextual information about the dataset, ensuring that each submission is accompanied by detailed descriptions that facilitate proper understanding and use of the data. Key elements included in the metadata spreadsheet are analysis and project information, sample information, sequencing methodologies, experimental details.
|
|
37
|
+
The spreadsheet is composed of editable tabs that will receive the metadata and non-editable helper tabs that provide detailed description of each column.
|
|
38
|
+
|
|
39
|
+
| WORKSHEET | EXPLANATION |
|
|
40
|
+
|-------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
|
41
|
+
| Submitter Details | This sheet captures the details of the submitter |
|
|
42
|
+
| Project | The objective of this sheet is to gather general information about the Project including submitter, submitting centre, collaborators, project title, description and publications. |
|
|
43
|
+
| Sample | Projects consist of analyses that are run on samples. We accept sample information in the form of BioSample, ENA or EGA accession(s). We also accept BioSamples sampleset accessions. If your samples are not yet accessioned, and are therefore novel, please use the "Novel sample(s)" sections of the Sample(s) worksheet to have them registered at BioSample |
|
|
44
|
+
| Analysis | For EVA, each analysis is one vcf file, plus an unlimited number of ancillary files. This sheet allows EVA to link vcf files to a project and to other EVA analyses. Additionally, this worksheet contains experimental meta-data detailing the methodology of each analysis. Important to note; one project can have multiple associated analyses |
|
|
45
|
+
| Files | Filenames and associated checking data associated with this EVA submission should be entered into this worksheet. Each file should be linked to exactly one analysis. |
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
# Installation
|
|
2
|
+
|
|
3
|
+
There are currently three ways to install and run eva-sub-cli:
|
|
4
|
+
- Using conda
|
|
5
|
+
- From source using Docker
|
|
6
|
+
- From source natively (i.e. installing dependencies yourself)
|
|
7
|
+
|
|
8
|
+
We encourage users to install the most recent version, as we are constantly improving the tool. You can check that you
|
|
9
|
+
have the latest version installed by running `eva-sub-cli.py --version` and comparing against the
|
|
10
|
+
[release page](https://github.com/EBIvariation/eva-sub-cli/releases).
|
|
11
|
+
|
|
12
|
+
## 1. Conda
|
|
13
|
+
|
|
14
|
+
The most straightforward way to install eva-sub-cli and its dependencies is through conda.
|
|
15
|
+
For instance, the following commands install eva-sub-cli in a new environment called `eva`, activate the environment, and print
|
|
16
|
+
the help message:
|
|
17
|
+
```bash
|
|
18
|
+
conda create -n eva -c conda-forge -c bioconda eva-sub-cli
|
|
19
|
+
conda activate eva
|
|
20
|
+
eva-sub-cli.py --help
|
|
21
|
+
````
|
|
22
|
+
|
|
23
|
+
To upgrade to the newest version, run `conda update eva-sub-cli`.
|
|
24
|
+
|
|
25
|
+
## 2. From source using Docker
|
|
26
|
+
|
|
27
|
+
Docker provides an easy way to run eva-sub-cli without installing dependencies separately.
|
|
28
|
+
This method requires just Python 3.8+ and [Docker](https://docs.docker.com/engine/install/) to be installed.
|
|
29
|
+
Then you can install the most recent version from [PyPI](https://pypi.org/project/eva-sub-cli/) in a virtual environment:
|
|
30
|
+
```bash
|
|
31
|
+
pip install eva-sub-cli
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
To verify that the cli tool is installed correctly, run the following command, and you should see the help message displayed:
|
|
35
|
+
```bash
|
|
36
|
+
eva-sub-cli.py --help
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
To upgrade to the newest version, run `pip install --upgrade eva-sub-cli`.
|
|
40
|
+
|
|
41
|
+
## 3. From source natively
|
|
42
|
+
|
|
43
|
+
This installation method requires the following:
|
|
44
|
+
* Python 3.8+
|
|
45
|
+
* [Nextflow](https://www.nextflow.io/docs/latest/getstarted.html) 21.10+
|
|
46
|
+
* [biovalidator](https://github.com/elixir-europe/biovalidator) 2.1.0+
|
|
47
|
+
* [vcf-validator](https://github.com/EBIvariation/vcf-validator) 0.9.7+
|
|
48
|
+
|
|
49
|
+
Install each of these and ensure they are included in your PATH. Then install the latest eva-sub-cli release as previously described.
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
# Using Nextflow for Parallelization
|
|
2
|
+
|
|
3
|
+
Nextflow is a common workflow management system that helps orchestrate tasks and interface with the execution engine (like HPC or cloud). When running natively (i.e. not using Docker), eva-sub-cli will use Nextflow to run all the validation steps. In this section we'll see how it can be parameterised to work with your compute infrastructure.
|
|
4
|
+
|
|
5
|
+
When no options are provided, Nextflow will run as many tasks as there are available CPUs on the machine executing it. To modify how many tasks can start and how Nextflow will process each one, you can provide a Nextflow configuration file in several ways.
|
|
6
|
+
|
|
7
|
+
From the command line you can use `--nextflow_config <path>` to specify the Nextflow config file you want to apply. The configuration can also be picked up from other places directly by Nextflow. Please refer to [the Nextflow documentation](https://www.nextflow.io/docs/latest/config.html) for more details.
|
|
8
|
+
|
|
9
|
+
## Basic Nextflow configuration
|
|
10
|
+
|
|
11
|
+
There are many options to configure Nextflow so we will not provide them all. Please refer to [the documentation](https://www.nextflow.io/docs/latest/reference/config.html) for advanced features.
|
|
12
|
+
Below is a very basic Nextflow configuration file that will request 2 cpus for each process, essentially limiting the number of process to half the number of available CPUs
|
|
13
|
+
```
|
|
14
|
+
process {
|
|
15
|
+
executor="local"
|
|
16
|
+
cpus=2
|
|
17
|
+
}
|
|
18
|
+
```
|
|
19
|
+
In this configuration, all the process will be running on the same machine where eva-sub-cli was started as described in the schema below.
|
|
20
|
+
```
|
|
21
|
+
(Local machine)
|
|
22
|
+
eva-sub-cli
|
|
23
|
+
|_ nextflow
|
|
24
|
+
|_ task1
|
|
25
|
+
|_ task2
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
## Basic Nextflow configuration for HPC use
|
|
29
|
+
|
|
30
|
+
If you have access to High Performance Compute (HPC) environment, Nextflow supports the main resource managers such as [SLURM](https://www.nextflow.io/docs/latest/executor.html#slurm), [SGE](https://www.nextflow.io/docs/latest/executor.html#sge), [LSF](https://www.nextflow.io/docs/latest/executor.html#lsf) and others.
|
|
31
|
+
In the configuration below, we're assuming that you are using SLURM. It would work similarly with other resource managers.
|
|
32
|
+
```
|
|
33
|
+
process {
|
|
34
|
+
executor="slurm"
|
|
35
|
+
queue="my_production_queue"
|
|
36
|
+
}
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
In this configuration, the subtasks will be performed in other machines as specified by your SLURM resource manager as described in the schema below.
|
|
40
|
+
```
|
|
41
|
+
(Local machine)
|
|
42
|
+
eva-sub-cli
|
|
43
|
+
|_ nextflow
|
|
44
|
+
(Other compute node)
|
|
45
|
+
task1
|
|
46
|
+
(Other compute node)
|
|
47
|
+
task2
|
|
48
|
+
```
|
|
@@ -1,51 +1,4 @@
|
|
|
1
|
-
#
|
|
2
|
-
|
|
3
|
-
The eva-sub-cli tool requires the following inputs:
|
|
4
|
-
|
|
5
|
-
- One or several valid VCF files
|
|
6
|
-
- Completed metadata spreadsheet
|
|
7
|
-
- Reference genome in fasta format
|
|
8
|
-
|
|
9
|
-
The VCF file must adhere to official VCF specifications, and the metadata spreadsheet provides contextual information about the dataset. In the following sections, we will examine each of these inputs in detail.
|
|
10
|
-
|
|
11
|
-
# VCF File
|
|
12
|
-
|
|
13
|
-
A VCF (Variant Call Format) file is a type of file used in bioinformatics to store information about genetic variants. It includes data about the differences (or variants) between a sample's DNA and a reference genome. Typically, generating a VCF file involves several steps: preparing your sample, sequencing the DNA, aligning it to a reference genome, identifying variants, and finally, formatting this information into a VCF file. The overall goal is to systematically capture and record genetic differences in a standardised format. A VCF file consists of two main parts: the header and the body.
|
|
14
|
-
|
|
15
|
-
Header: The header contains metadata about the file, such as the format version, reference genome information, and descriptions of the data fields. Each line in the header starts with a double ##, except for the last header line which starts with a single #.
|
|
16
|
-
|
|
17
|
-
File format version
|
|
18
|
-
|
|
19
|
-
```
|
|
20
|
-
##fileformat=VCFv4.2
|
|
21
|
-
##INFO=<ID=DP,Number=1,Type=Integer,Description="Total Depth">
|
|
22
|
-
##FILTER=<ID=PASS,Description="All filters passed">
|
|
23
|
-
##FORMAT=<ID=GT,Number=1,Type=String,Description="Genotype">
|
|
24
|
-
|
|
25
|
-
```
|
|
26
|
-
|
|
27
|
-
Body: The body of the VCF file contains the actual variant data, with each row representing a single variant. The columns in the body are : CHROM, POS, ID, REF, ALT, QUAL, FILTER, INFO, FORMAT, Sample Columns
|
|
28
|
-
|
|
29
|
-
```
|
|
30
|
-
#CHROM POS ID REF ALT QUAL FILTER INFO FORMAT [SampleIDs...]
|
|
31
|
-
```
|
|
32
|
-
Here's a small example to illustrate the structure of a VCF file: Example VCF file archived at EVA to be inserted
|
|
33
|
-
|
|
34
|
-
# Metadata Spreadsheet
|
|
35
|
-
|
|
36
|
-
The spreadsheet provides comprehensive contextual information about the dataset, ensuring that each submission is accompanied by detailed descriptions that facilitate proper understanding and use of the data. Key elements included in the metadata spreadsheet are analysis and project information, sample information, sequencing methodologies, experimental details.
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
| WORKSHEET | EXPLANATION |
|
|
40
|
-
| ----------------- | -------------------- |
|
|
41
|
-
| Submitter Details | This sheet captures the details of the submitter|
|
|
42
|
-
| Project | The objective of this sheet is to gather general information about the Project including submitter, submitting centre, collaborators, project title, description and publications. |
|
|
43
|
-
| Sample | Projects consist of analyses that are run on samples. We accept sample information in the form of BioSample, ENA or EGA accession(s). We also accept BioSamples sampleset accessions. If your samples are not yet accessioned, and are therefore novel, please use the "Novel sample(s)" sections of the Sample(s) worksheet to have them registered at BioSample |
|
|
44
|
-
| Analysis | For EVA, each analysis is one vcf file, plus an unlimited number of ancillary files. This sheet allows EVA to link vcf files to a project and to other EVA analyses. Additionally, this worksheet contains experimental meta-data detailing the methodology of each analysis. Important to note; one project can have multiple associated analyses |
|
|
45
|
-
| Files | Filenames and associated checking data associated with this EVA submission should be entered into this worksheet. Each file should be linked to exactly one analysis. |
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
# Validation checks
|
|
1
|
+
# Overview of Validation Checks
|
|
49
2
|
|
|
50
3
|
The CLI tool performs the following validation checks and generates corresponding reports:
|
|
51
4
|
|
|
@@ -56,7 +9,7 @@ The CLI tool performs the following validation checks and generates correspondin
|
|
|
56
9
|
|
|
57
10
|
In the following sections, we will examine each of these checks in detail, starting with the Metadata check.
|
|
58
11
|
|
|
59
|
-
|
|
12
|
+
## Metadata check
|
|
60
13
|
|
|
61
14
|
Once the user passes the metadata spreadsheet for validation checks, the eva-sub-cli tool verifies that all mandatory columns, marked in bold in the spreadsheet, are filled in. This data is crucial for further validation processes, such as retrieving the INDSC accession of the reference genome used to call the variants, and for sample and project metadata. If any mandatory columns or sheets are missing, the CLI tool will raise errors.
|
|
62
15
|
|
|
@@ -75,7 +28,7 @@ Common Errors Seen with Metadata Checks:
|
|
|
75
28
|
- Tax ID and the scientific name of the organism do not match.
|
|
76
29
|
- Collection data and geographic location of the samples are not filled if the samples being submitted are novel.
|
|
77
30
|
|
|
78
|
-
|
|
31
|
+
## VCF Checks
|
|
79
32
|
|
|
80
33
|
Ensuring data consistency upon submission is crucial for interoperability and supporting cross-study comparative genomics. Before accepting a VCF submission, the cli tool verifies that the submitted information adheres to the official VCF specifications. Additionally, submitted variants must be supported by either experimentally determined sample genotypes or population allele frequencies.
|
|
81
34
|
|
|
@@ -95,7 +48,7 @@ Common Errors Seen with VCF Checks:
|
|
|
95
48
|
- VCF uses non-GCA contig alias
|
|
96
49
|
- The fields used do not conform to the official VCF specifications
|
|
97
50
|
|
|
98
|
-
|
|
51
|
+
## Assembly Check
|
|
99
52
|
|
|
100
53
|
The EVA requires that all variants be submitted with an asserted position on an INSDC sequence. This means that the reference allele for every variant must match a position in a sequence that has been accessioned in either the GenBank or ENA database. Aligning all submitted data with INSDC sequences enables integration with other EMBL-EBI resources, including Ensembl, and is crucial for maintaining standardisation at the EVA. Therefore, all sequence identifiers in your VCF must match those in the reference FASTA file.
|
|
101
54
|
|
|
@@ -110,7 +63,7 @@ Key points to note before validating your data with the eva-sub-cli Tool:
|
|
|
110
63
|
- Contigs used do not exist in the assembly report of the reference genome
|
|
111
64
|
- Major Allele Used as REF Allele: This typically occurs when a specific version of Plink or Tassel is used to create VCF files, causing the tool to use the major allele as the reference allele. In such cases, submitters should use the GCA FASTA sequence to create corrected files.
|
|
112
65
|
|
|
113
|
-
|
|
66
|
+
## Sample Name Concordance Check
|
|
114
67
|
|
|
115
68
|
The sample name concordance check ensures that the sample names in the metadata spreadsheet match those in the VCF file. This is achieved by cross-checking the 'Sample name in VCF' column in the spreadsheet with the sample names registered in the VCF file. Any discrepancies must be addressed by the submitter when the CLI tool generates a report of the mismatches found.
|
|
116
69
|
|
|
@@ -124,5 +77,3 @@ Common errors seen with sample concordance checks:
|
|
|
124
77
|
- Link between “Sample” and “File” provided via the Analysis alias is not correctly defined in the metadata which causes the sample name concordance check to fail.
|
|
125
78
|
- Extra white spaces in the sample names can lead to mismatches.
|
|
126
79
|
- Case sensitivity issues between the sample names in the VCF file and the metadata spreadsheet.
|
|
127
|
-
|
|
128
|
-
|
|
@@ -168,6 +168,14 @@
|
|
|
168
168
|
"type": "string",
|
|
169
169
|
"description": "Reference against which the analysis was performed. ENA or NCBI accession (starting with GCA) accepted."
|
|
170
170
|
},
|
|
171
|
+
"evidenceType": {
|
|
172
|
+
"type": "string",
|
|
173
|
+
"description": "The type of evidence (allele frequencies or genotypes) provided in the VCF files of the analysis",
|
|
174
|
+
"enum": [
|
|
175
|
+
"genotype",
|
|
176
|
+
"allele_frequency"
|
|
177
|
+
]
|
|
178
|
+
},
|
|
171
179
|
"referenceFasta": {
|
|
172
180
|
"type": "string",
|
|
173
181
|
"description": "The path to the reference in fasta format that was used to create the VCF. (This is a local path)"
|
|
@@ -366,7 +374,7 @@
|
|
|
366
374
|
"projectAccession": {
|
|
367
375
|
"type": "string",
|
|
368
376
|
"description": "ENA project accession",
|
|
369
|
-
"pattern": "^PRJ(
|
|
377
|
+
"pattern": "^PRJ(E|D|N)[A-Z][0-9]+$"
|
|
370
378
|
}
|
|
371
379
|
}
|
|
372
380
|
}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import argparse
|
|
2
|
+
|
|
3
|
+
import yaml
|
|
4
|
+
from ebi_eva_common_pyutils.logger import logging_config
|
|
5
|
+
|
|
6
|
+
from eva_sub_cli.file_utils import detect_vcf_evidence_type
|
|
7
|
+
from eva_sub_cli.metadata import EvaMetadataJson
|
|
8
|
+
|
|
9
|
+
logger = logging_config.get_logger(__name__)
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
def check_evidence_type(metadata_json, output_yaml):
|
|
13
|
+
metadata = EvaMetadataJson(metadata_json)
|
|
14
|
+
results_per_analysis_alias = {}
|
|
15
|
+
|
|
16
|
+
for analysis_alias, vcf_file_set in metadata.files_per_analysis.items():
|
|
17
|
+
results_per_analysis_alias[analysis_alias] = {
|
|
18
|
+
'evidence_type': None,
|
|
19
|
+
'errors': None
|
|
20
|
+
}
|
|
21
|
+
vcf_files = list(vcf_file_set)
|
|
22
|
+
evidence_types_for_vcf_files = [detect_vcf_evidence_type(vcf_file) for vcf_file in vcf_files]
|
|
23
|
+
|
|
24
|
+
if len(set(evidence_types_for_vcf_files)) == 1 and None not in evidence_types_for_vcf_files:
|
|
25
|
+
results_per_analysis_alias[analysis_alias]['evidence_type'] = set(evidence_types_for_vcf_files).pop()
|
|
26
|
+
elif None in evidence_types_for_vcf_files:
|
|
27
|
+
indices = [i for i, x in enumerate(evidence_types_for_vcf_files) if x is None]
|
|
28
|
+
results_per_analysis_alias[analysis_alias][
|
|
29
|
+
'errors'] = f'VCF file evidence type could not be determined: {", ".join([vcf_files[i] for i in indices])}'
|
|
30
|
+
else:
|
|
31
|
+
results_per_analysis_alias[analysis_alias][
|
|
32
|
+
'errors'] = f'Multiple evidence types found: {", ".join(set(evidence_types_for_vcf_files))}'
|
|
33
|
+
|
|
34
|
+
write_result_yaml(output_yaml, results_per_analysis_alias)
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
def write_result_yaml(output_yaml, results_per_analysis_alias):
|
|
38
|
+
with open(output_yaml, 'w') as open_yaml:
|
|
39
|
+
yaml.safe_dump(data=results_per_analysis_alias, stream=open_yaml, default_flow_style=False)
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
def main():
|
|
43
|
+
arg_parser = argparse.ArgumentParser(description='Check the evidence type in the VCF files for all analysis')
|
|
44
|
+
arg_parser.add_argument('--metadata_json', required=True, dest='metadata_json',
|
|
45
|
+
help='EVA metadata json file')
|
|
46
|
+
arg_parser.add_argument('--output_yaml', required=True, dest='output_yaml',
|
|
47
|
+
help='Path to the location of the results')
|
|
48
|
+
|
|
49
|
+
args = arg_parser.parse_args()
|
|
50
|
+
logging_config.add_stdout_handler()
|
|
51
|
+
check_evidence_type(args.metadata_json, args.output_yaml)
|
|
@@ -5,7 +5,7 @@ from ebi_eva_common_pyutils.logger import logging_config
|
|
|
5
5
|
|
|
6
6
|
import yaml
|
|
7
7
|
|
|
8
|
-
from eva_sub_cli.file_utils import open_gzip_if_required
|
|
8
|
+
from eva_sub_cli.file_utils import open_gzip_if_required, detect_vcf_evidence_type
|
|
9
9
|
from eva_sub_cli.metadata import EvaMetadataJson
|
|
10
10
|
|
|
11
11
|
logger = logging_config.get_logger(__name__)
|
|
@@ -64,20 +64,41 @@ def compare_all_analysis(metadata, files_per_analysis):
|
|
|
64
64
|
file_path: get_samples_from_vcf(file_path)
|
|
65
65
|
for file_path in files_per_analysis.get(analysis_alias, [])
|
|
66
66
|
}
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
67
|
+
|
|
68
|
+
if need_to_check_samples(sample_name_per_file):
|
|
69
|
+
(
|
|
70
|
+
has_difference, more_per_submitted_files_metadata,
|
|
71
|
+
more_submitted_files_metadata, more_metadata_submitted_files
|
|
72
|
+
) = compare_names_in_files_and_samples(sample_name_in_analysis, sample_name_per_file)
|
|
73
|
+
overall_differences = overall_differences or has_difference
|
|
74
|
+
results_per_analysis_alias[analysis_alias] = {
|
|
75
|
+
'difference': has_difference,
|
|
76
|
+
'more_per_submitted_files_metadata': more_per_submitted_files_metadata,
|
|
77
|
+
'more_submitted_files_metadata': more_submitted_files_metadata,
|
|
78
|
+
'more_metadata_submitted_files': more_metadata_submitted_files
|
|
79
|
+
}
|
|
80
|
+
else:
|
|
81
|
+
results_per_analysis_alias[analysis_alias] = {
|
|
82
|
+
'difference': False,
|
|
83
|
+
'more_per_submitted_files_metadata': [],
|
|
84
|
+
'more_submitted_files_metadata': [],
|
|
85
|
+
'more_metadata_submitted_files': []
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
|
|
78
89
|
return overall_differences, results_per_analysis_alias
|
|
79
90
|
|
|
80
91
|
|
|
92
|
+
def need_to_check_samples(sample_name_per_file):
|
|
93
|
+
no_samples_in_vcf = all(len(v) == 0 for v in sample_name_per_file.values())
|
|
94
|
+
if no_samples_in_vcf:
|
|
95
|
+
evidence_types_for_vcf_files = [detect_vcf_evidence_type(vcf_file) for vcf_file in sample_name_per_file.keys()]
|
|
96
|
+
if set(evidence_types_for_vcf_files) == {'allele_frequency'}:
|
|
97
|
+
return False
|
|
98
|
+
|
|
99
|
+
return True
|
|
100
|
+
|
|
101
|
+
|
|
81
102
|
def associate_vcf_path_with_analysis(metadata, vcf_files):
|
|
82
103
|
"""
|
|
83
104
|
Match the files names associated with analysis provided in the metadata with the file path given on the command
|