Skip to content

Commit

Permalink
[fix](Aggregation): Namespace error fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
tdayris committed Jul 11, 2019
1 parent da40422 commit 7b11e90
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 5 deletions.
10 changes: 7 additions & 3 deletions rules/common.smk
Original file line number Diff line number Diff line change
Expand Up @@ -180,9 +180,13 @@ def fq_pairs_w(wildcards) -> Dict[str, str]:
"""
Dynamic wildcards call for snakemake.
"""
return {"fastq": fq_pairs_dict[wildcards.sample],
"gtf": refs_pack_dict["gtf"],
"index": "kallisto_index/genome_index"}
try:
return {"fastq": fq_pairs_dict[wildcards.sample],
"gtf": refs_pack_dict["gtf"],
"index": "kallisto_index/genome_index"}
except KeyError:
return {"fastq": fq_pairs_dict[wildcards.sample],
"index": "kallisto_index/genome_index"}


def sample_id() -> List[str]:
Expand Down
2 changes: 1 addition & 1 deletion scripts/aggregate_samples.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ def extract_field(*paths: List[str],


if __name__ == '__main__':
makedirs(os.path.dirname(snakemake.output["est_counts"]))
makedirs(op.dirname(snakemake.output["est_counts"]))

for column in ["est_counts", "tpm"]:
data = extract_field(
Expand Down
2 changes: 1 addition & 1 deletion tests/config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ params:
kallisto_index_extra: \-\-kmer-size=5
kallisto_quant_extra: ''
ref:
fasta: genomes/transcriptome.fasta
fasta: genome/transcriptome.fasta
gtf: null
singularity_docker_image: docker://continuumio/miniconda3:4.4.10
threads: 1
Expand Down

0 comments on commit 7b11e90

Please sign in to comment.