Skip to content

Commit eb1fe7a

Browse files
committed
added schema check
1 parent 094da18 commit eb1fe7a

10 files changed

Lines changed: 399 additions & 62 deletions

payload-gen-seq-experiment/main.py

Lines changed: 209 additions & 58 deletions
Large diffs are not rendered by default.
Lines changed: 88 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,88 @@
1+
{
2+
"analysisType": {
3+
"name": "sequencing_experiment"
4+
},
5+
"studyId": "TEST-PRO",
6+
"experiment": {
7+
"submitter_sequencing_experiment_id": "TEST_EXP",
8+
"sequencing_center": "EXT",
9+
"platform": "ILLUMINA",
10+
"platform_model": "HiSeq 2000",
11+
"experimental_strategy": "RNA-Seq",
12+
"sequencing_date": "2014-12-12",
13+
"library_strandedness": "FIRST_READ_ANTISENSE_STRAND"
14+
},
15+
"read_group_count": 3,
16+
"read_groups": [
17+
{
18+
"submitter_read_group_id": "C0HVY.2",
19+
"read_group_id_in_bam": null,
20+
"platform_unit": "74_8a",
21+
"is_paired_end": true,
22+
"file_r1": "test_rg_3.bam",
23+
"file_r2": "test_rg_3.bam",
24+
"read_length_r1": 150,
25+
"read_length_r2": 150,
26+
"insert_size": 298,
27+
"sample_barcode": null,
28+
"library_name": "Pond-147580"
29+
},
30+
{
31+
"submitter_read_group_id": "D0RE2.1",
32+
"read_group_id_in_bam": null,
33+
"platform_unit": "74_8b",
34+
"is_paired_end": true,
35+
"file_r1": "test_rg_3.bam",
36+
"file_r2": "test_rg_3.bam",
37+
"read_length_r1": 150,
38+
"read_length_r2": 150,
39+
"insert_size": 298,
40+
"sample_barcode": null,
41+
"library_name": "Pond-147580"
42+
},
43+
{
44+
"submitter_read_group_id": "D0RH0.2",
45+
"read_group_id_in_bam": null,
46+
"platform_unit": "74_8c",
47+
"is_paired_end": true,
48+
"file_r1": "test_rg_3.bam",
49+
"file_r2": "test_rg_3.bam",
50+
"read_length_r1": 150,
51+
"read_length_r2": 150,
52+
"insert_size": 298,
53+
"sample_barcode": null,
54+
"library_name": "Pond-147580"
55+
}
56+
],
57+
"samples": [
58+
{
59+
"submitterSampleId": "HCC1143_BAM_INPUT",
60+
"matchedNormalSubmitterSampleId": null,
61+
"sampleType": "RNA",
62+
"specimen": {
63+
"submitterSpecimenId": "HCC1143_BAM_INPUT",
64+
"tumourNormalDesignation": "Normal",
65+
"specimenTissueSource": "Blood derived",
66+
"specimenType": "Cell line - derived from normal"
67+
},
68+
"donor": {
69+
"submitterDonorId": "HCC1143",
70+
"gender": "Female"
71+
}
72+
}
73+
],
74+
"files": [
75+
{
76+
"fileName": "test_rg_3.bam",
77+
"fileSize": 14911,
78+
"fileMd5sum": "178f97f7b1ca8bfc28fd5586bdd56799",
79+
"fileType": "BAM",
80+
"fileAccess": "controlled",
81+
"dataType": "Submitted Reads",
82+
"info": {
83+
"data_category": "Sequencing Reads"
84+
},
85+
"EGAF": "EGAF000001"
86+
}
87+
]
88+
}
Lines changed: 86 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,86 @@
1+
{
2+
"analysisType": {
3+
"name": "sequencing_experiment"
4+
},
5+
"studyId": "TEST-PRO",
6+
"experiment": {
7+
"submitter_sequencing_experiment_id": "TEST_EXP",
8+
"sequencing_center": "EXT",
9+
"platform": "ILLUMINA",
10+
"platform_model": "HiSeq 2000",
11+
"experimental_strategy": "WGS",
12+
"sequencing_date": "2014-12-12"
13+
},
14+
"read_group_count": 3,
15+
"read_groups": [
16+
{
17+
"submitter_read_group_id": "C0HVY.2",
18+
"read_group_id_in_bam": null,
19+
"platform_unit": "74_8a",
20+
"is_paired_end": true,
21+
"file_r1": "test_rg_3.bam",
22+
"file_r2": "test_rg_3.bam",
23+
"read_length_r1": 150,
24+
"read_length_r2": 150,
25+
"insert_size": 298,
26+
"sample_barcode": null,
27+
"library_name": "Pond-147580"
28+
},
29+
{
30+
"submitter_read_group_id": "D0RE2.1",
31+
"read_group_id_in_bam": null,
32+
"platform_unit": "74_8b",
33+
"is_paired_end": true,
34+
"file_r1": "test_rg_3.bam",
35+
"file_r2": "test_rg_3.bam",
36+
"read_length_r1": 150,
37+
"read_length_r2": 150,
38+
"insert_size": 298,
39+
"sample_barcode": null,
40+
"library_name": "Pond-147580"
41+
},
42+
{
43+
"submitter_read_group_id": "D0RH0.2",
44+
"read_group_id_in_bam": null,
45+
"platform_unit": "74_8c",
46+
"is_paired_end": true,
47+
"file_r1": "test_rg_3.bam",
48+
"file_r2": "test_rg_3.bam",
49+
"read_length_r1": 150,
50+
"read_length_r2": 150,
51+
"insert_size": 298,
52+
"sample_barcode": null,
53+
"library_name": "Pond-147580"
54+
}
55+
],
56+
"samples": [
57+
{
58+
"submitterSampleId": "HCC1143_BAM_INPUT",
59+
"matchedNormalSubmitterSampleId": null,
60+
"sampleType": "DNA",
61+
"specimen": {
62+
"submitterSpecimenId": "HCC1143_BAM_INPUT",
63+
"tumourNormalDesignation": "Normal",
64+
"specimenTissueSource": "Blood derived",
65+
"specimenType": "Cell line - derived from normal"
66+
},
67+
"donor": {
68+
"submitterDonorId": "HCC1143",
69+
"gender": "Female"
70+
}
71+
}
72+
],
73+
"files": [
74+
{
75+
"fileName": "test_rg_3.bam",
76+
"fileSize": 14911,
77+
"fileMd5sum": "178f97f7b1ca8bfc28fd5586bdd56799",
78+
"fileType": "BAM",
79+
"fileAccess": "controlled",
80+
"dataType": "Submitted Reads",
81+
"info": {
82+
"data_category": "Sequencing Reads"
83+
}
84+
}
85+
]
86+
}
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
type study_id submitter_sequencing_experiment_id submitter_donor_id gender submitter_specimen_id tumour_normal_designation specimen_type specimen_tissue_source submitter_sample_id sample_type submitter_matched_normal_sample_id sequencing_center platform platform_model experimental_strategy sequencing_date read_group_count library_strandedness
2+
sequencing_experiment TEST-PRO TEST_EXP HCC1143 Female HCC1143_BAM_INPUT Normal Cell line - derived from normal Blood derived HCC1143_BAM_INPUT RNA EXT ILLUMINA HiSeq 2000 RNA-Seq 2014-12-12 3 FIRST_READ_ANTISENSE_STRAND
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
type study_id submitter_sequencing_experiment_id submitter_donor_id gender submitter_specimen_id tumour_normal_designation specimen_type specimen_tissue_source submitter_sample_id sample_type submitter_matched_normal_sample_id sequencing_center platform platform_model experimental_strategy sequencing_date read_group_count
2+
sequencing_experiment TEST-PRO TEST_EXP HCC1143 Female HCC1143_BAM_INPUT Normal Cell line - derived from normal Blood derived HCC1143_BAM_INPUT RNA EXT ILLUMINA HiSeq 2000 RNA-Seq 2014-12-12 3
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
type name format size md5sum path EGAF
2+
file test_rg_3.bam BAM 14911 178f97f7b1ca8bfc28fd5586bdd56799 test_rg_3.bam EGAF000001

payload-gen-seq-experiment/tests/test-job-bam.tsv.nf.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
"experiment_info_tsv": "input/experiment.v2.tsv",
33
"read_group_info_tsv": "input/read_group.v2.tsv",
44
"file_info_tsv": "input/file.v2.tsv",
5-
"extra_info_tsv": "input/extra_info.v2.tsv",
6-
"expected_output": "input/98690064-627e-4a2b-a0c2-60fc9ca8433c.sequencing_experiment.payload.json",
5+
"expected_output": "input/d9c99af9-b97d-4481-9be8-f65e57d86673.sequencing_experiment.payload.json",
76
"publish_dir": "outdir"
87
}
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{
2+
"experiment_info_tsv": "input/experiment.correct.rnaseq.tsv",
3+
"read_group_info_tsv": "input/read_group.v2.tsv",
4+
"file_info_tsv": "input/file.v3.tsv",
5+
"expected_output": "input/208c5ea6-c17a-4a63-981e-4bb91d3119f2.sequencing_experiment.payload.json",
6+
"publish_dir": "outdir"
7+
}

tests/data/experiment-fq.v2.tsv

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
type program_id submitter_sequencing_experiment_id submitter_donor_id gender submitter_specimen_id tumour_normal_designation specimen_type specimen_tissue_source submitter_sample_id sample_type submitter_matched_normal_sample_id sequencing_center platform platform_model experimental_strategy sequencing_date read_group_count
1+
type study_id submitter_sequencing_experiment_id submitter_donor_id gender submitter_specimen_id tumour_normal_designation specimen_type specimen_tissue_source submitter_sample_id sample_type submitter_matched_normal_sample_id sequencing_center platform platform_model experimental_strategy sequencing_date read_group_count
22
sequencing_experiment TEST-PRO TEST_EXP HCC1143 Female HCC1143_FASTQ_INPUT Tumour Cell line - derived from tumour Blood derived HCC1143_FASTQ_INPUT DNA HCC1143_BAM_INPUT EXT ILLUMINA HiSeq 2000 WGS 2014-12-12 3

tests/data/experiment.v2.tsv

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
type program_id submitter_sequencing_experiment_id submitter_donor_id gender submitter_specimen_id tumour_normal_designation specimen_type specimen_tissue_source submitter_sample_id sample_type submitter_matched_normal_sample_id sequencing_center platform platform_model experimental_strategy sequencing_date read_group_count
1+
type study_id submitter_sequencing_experiment_id submitter_donor_id gender submitter_specimen_id tumour_normal_designation specimen_type specimen_tissue_source submitter_sample_id sample_type submitter_matched_normal_sample_id sequencing_center platform platform_model experimental_strategy sequencing_date read_group_count
22
sequencing_experiment TEST-PRO TEST_EXP HCC1143 Female HCC1143_BAM_INPUT Normal Cell line - derived from normal Blood derived HCC1143_BAM_INPUT DNA EXT ILLUMINA HiSeq 2000 WGS 2014-12-12 3

0 commit comments

Comments
 (0)