Skip to content

Commit

Permalink
PIPE-53-psf-to-bedpe (#148)
Browse files Browse the repository at this point in the history
  • Loading branch information
paul-sud authored Mar 8, 2022
1 parent 787615b commit 83f4fbf
Show file tree
Hide file tree
Showing 5 changed files with 60 additions and 22 deletions.
12 changes: 8 additions & 4 deletions docker/hic-pipeline/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -102,10 +102,6 @@ RUN git clone https://github.com/ENCODE-DCC/kentUtils_bin_v381.git && \
cd ../../ && \
rm -rf kentUtils_bin_v381

RUN git clone --branch phasing https://github.com/aidenlab/3d-dna.git && \
cd 3d-dna && \
git checkout 634b49b9a93ac166914dc3baae586489bb793c92

# Install Juicer
RUN git clone --branch encode https://github.com/theaidenlab/juicer.git && \
cd juicer && \
Expand Down Expand Up @@ -150,6 +146,14 @@ RUN git clone https://github.com/aidenlab/hic2gatk.git && \
cd hic2gatk && \
git checkout dee2a9f6f2b0e95f0cb3e8d47eef9798cb8101aa

RUN git clone --branch phasing https://github.com/aidenlab/3d-dna.git && \
cd 3d-dna && \
git checkout 63029aa3bc5ba9bbdad9dd9771ace583cc95e273

RUN git clone https://github.com/sa501428/psf-to-bedpe.git && \
cd psf-to-bedpe && \
git checkout 0.1

# For sorting, LC_ALL is C
ENV LC_ALL C
ENV PATH=/opt:/opt/scripts:/opt/scripts/common:/opt/juicer/misc:/opt/gatk-4.2.2.0:/opt/hic2gatk:$PATH
Expand Down
44 changes: 39 additions & 5 deletions genophase.wdl
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ import "./hic.wdl"

workflow genophase {
meta {
version: "1.11.3"
caper_docker: "encodedcc/hic-pipeline:1.11.3"
caper_singularity: "docker://encodedcc/hic-pipeline:1.11.3"
version: "1.12.0"
caper_docker: "encodedcc/hic-pipeline:1.12.0"
caper_singularity: "docker://encodedcc/hic-pipeline:1.12.0"
croo_out_def: "https://raw.githubusercontent.com/ENCODE-DCC/hic-pipeline/dev/croo_out_def.json"
}

Expand All @@ -25,8 +25,8 @@ workflow genophase {
Int? run_3d_dna_ram_gb
Boolean no_phasing = false

String docker = "encodedcc/hic-pipeline:1.11.3"
String singularity = "docker://encodedcc/hic-pipeline:1.11.3"
String docker = "encodedcc/hic-pipeline:1.12.0"
String singularity = "docker://encodedcc/hic-pipeline:1.12.0"
}

RuntimeEnvironment runtime_environment = {
Expand Down Expand Up @@ -73,6 +73,11 @@ workflow genophase {
disk_size_gb = run_3d_dna_disk_size_gb,
runtime_environment = runtime_environment,
}
call convert_psf_to_bedpe { input:
psf = run_3d_dna.psf,
runtime_environment = runtime_environment,
}
}
}
Expand Down Expand Up @@ -228,6 +233,35 @@ task run_3d_dna {

File assembly_in = "snp.out.in.assembly.gz"
File assembly = "snp.out.out.assembly.gz"

File psf = "out.psf"
}

runtime {
cpu : "~{num_cpus}"
disks: "local-disk ~{disk_size_gb} HDD"
memory: "~{ram_gb} GB"
docker: runtime_environment.docker
singularity: runtime_environment.singularity
}
}
task convert_psf_to_bedpe {
input {
File psf
Int num_cpus = 1
Int disk_size_gb = 1000
Int ram_gb = 16
RuntimeEnvironment runtime_environment
}
command <<<
set -euo pipefail
awk -f /opt/psf-to-bedpe/psf-to-bedpe.awk ~{psf} > "psf.bedpe"
>>>
output {
File bedpe = "psf.bedpe"
}

runtime {
Expand Down
14 changes: 7 additions & 7 deletions hic.wdl
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@ struct RuntimeEnvironment {

workflow hic {
meta {
version: "1.11.3"
caper_docker: "encodedcc/hic-pipeline:1.11.3"
caper_singularity: "docker://encodedcc/hic-pipeline:1.11.3"
version: "1.12.0"
caper_docker: "encodedcc/hic-pipeline:1.12.0"
caper_singularity: "docker://encodedcc/hic-pipeline:1.12.0"
croo_out_def: "https://raw.githubusercontent.com/ENCODE-DCC/hic-pipeline/dev/croo_out_def.json"
description: "ENCODE Hi-C pipeline, see https://github.com/ENCODE-DCC/hic-pipeline for details."
}
Expand Down Expand Up @@ -65,10 +65,10 @@ workflow hic {
Int? create_accessibility_track_disk_size_gb
String assembly_name = "undefined"

String docker = "encodedcc/hic-pipeline:1.11.3"
String singularity = "docker://encodedcc/hic-pipeline:1.11.3"
String delta_docker = "encodedcc/hic-pipeline:1.11.3_delta"
String hiccups_docker = "encodedcc/hic-pipeline:1.11.3_hiccups"
String docker = "encodedcc/hic-pipeline:1.12.0"
String singularity = "docker://encodedcc/hic-pipeline:1.12.0"
String delta_docker = "encodedcc/hic-pipeline:1.12.0_delta"
String hiccups_docker = "encodedcc/hic-pipeline:1.12.0_hiccups"
}

RuntimeEnvironment runtime_environment = {
Expand Down
2 changes: 1 addition & 1 deletion hic_pipeline/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
__title__ = "hic-pipeline"
__version__ = "1.11.3"
__version__ = "1.12.0"
__description__ = "ENCODE Hi-C uniform processing pipeline."
__url__ = "https://github.com/ENCODE-DCC/hic-pipeline"
__uri__ = __url__
Expand Down
10 changes: 5 additions & 5 deletions make_restriction_site_locations.wdl
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ struct RuntimeEnvironment {

workflow make_restriction_site_locations {
meta {
version: "1.11.3"
caper_docker: "encodedcc/hic-pipeline:1.11.3"
caper_singularity: "docker://encodedcc/hic-pipeline:1.11.3"
version: "1.12.0"
caper_docker: "encodedcc/hic-pipeline:1.12.0"
caper_singularity: "docker://encodedcc/hic-pipeline:1.12.0"
}

parameter_meta {
Expand All @@ -22,8 +22,8 @@ workflow make_restriction_site_locations {
File reference_fasta
String assembly_name
String restriction_enzyme
String docker = "encodedcc/hic-pipeline:1.11.3"
String singularity = "docker://encodedcc/hic-pipeline:1.11.3"
String docker = "encodedcc/hic-pipeline:1.12.0"
String singularity = "docker://encodedcc/hic-pipeline:1.12.0"
}


Expand Down

0 comments on commit 83f4fbf

Please sign in to comment.