Skip to content
Snippets Groups Projects
Verified Commit e2454d73 authored by Laurent Modolo's avatar Laurent Modolo
Browse files

Close merge request #27

parent b6110260
Branches
No related tags found
No related merge requests found
Showing
with 262 additions and 10 deletions
#!/bin/sh #!/bin/sh
docker pull lbmc/bedtools:2.30.0 docker pull lbmc/bedtools:2.30.0
# docker build src/.docker_modules/bedtools/2.30.0 -t 'lbmc/bedtools:2.30.0' docker build src/.docker_modules/bedtools/2.30.0 -t 'lbmc/bedtools:2.30.0'
# docker push lbmc/bedtools:2.30.0 docker push lbmc/bedtools:2.30.0
docker buildx build --platform linux/amd64,linux/arm64 -t "lbmc/bedtools:2.30.0" --push src/.docker_modules/bedtools/2.30.0
FROM python:3.7-slim
ENV RPY2_CFFI_MODE=ABI
RUN mkdir /app /docker
COPY requirements.txt /app
COPY requirements-web.txt /app
WORKDIR /app
RUN pip install -r requirements.txt
RUN pip install -r requirements-web.txt
RUN pip install cellphonedb==3.0.0
COPY . /app
COPY ./docker /docker
RUN mkdir -p /var/log/uwsgi
RUN touch /var/log/uwsgi/cellphonedb.log
RUN chmod +x /app
CMD ["/docker/run-system.sh"]
[uwsgi]
module = wsgi:app
master = true
processes = 4
socket = 0.0.0.0:5000
chmod-socket = 660
vacuum = true
die-on-term = true
stats = /tmp/stats.socket
\ No newline at end of file
FROM postgres:9.6
ENV POSTGRES_PASSWORD root
ENV POSTGRES_USER root
ENV POSTGRES_DB cellphonedb
\ No newline at end of file
#!/bin/bash
exec uwsgi --ini cellphonedb.ini --log-master
flask>=1.1,<1.1.99
Flask-RESTful>=0.3,<0.3.99
Flask-Testing>=0.8,<0.8.99
pika>=0.12,<0.12.99
boto3>=1.7,<1.7.99
uWSGI>=2.0,<2.0.99
click>=7.0,<8.0
pandas>=1.0.0,<=1.1.4
numpy>=1.16.5,<=1.19.5
numpy-groupies
scikit-learn==0.22
flask>=1.0,<2.0.0
Flask-RESTful>=0.3
Flask-Testing>=0.7
SQLAlchemy>=1.3,<1.4
PyYAML>=5.4,<6.0
requests>=2.25,<3.0
pika>=1.0.0,<2.0
boto3>=1.15,<2.0
geosketch==0.3
rpy2>=3.4.0,<4.0
tqdm>=4.3,<5.0
h5py<3.0.0
anndata>=0.7,<=0.75
#!/bin/sh #!/bin/sh
docker pull lbmc/htseq:0.13.5 docker pull lbmc/htseq:0.13.5
# docker build src/.docker_modules/htseq/0.13.5 -t 'lbmc/htseq:0.13.5' docker build src/.docker_modules/htseq/0.13.5 -t 'lbmc/htseq:0.13.5'
# docker push lbmc/htseq:0.13.5 docker push lbmc/htseq:0.13.5
docker buildx build --platform linux/amd64,linux/arm64 -t "lbmc/htseq:0.13.5" --push src/.docker_modules/htseq/0.13.5
#!/bin/sh #!/bin/sh
docker pull lbmc/kb:0.26.3 docker pull lbmc/kb:0.26.3
# docker build src/.docker_modules/kb/0.26.3 -t 'lbmc/kb:0.26.3' docker build src/.docker_modules/kb/0.26.3 -t 'lbmc/kb:0.26.3'
# docker push lbmc/kb:0.26.3 docker push lbmc/kb:0.26.3
docker buildx build --platform linux/amd64,linux/arm64 -t "lbmc/kb:0.26.3" --push src/.docker_modules/kb/0.26.3
##### BASE IMAGE #####
FROM ubuntu:18.04
##### METADATA #####
LABEL base.image="ubuntu:18.04"
LABEL version="1"
LABEL software="Sanity"
LABEL software.version="1.0"
LABEL software.description="Sanity"
LABEL software.website=""
LABEL software.documentation="https://github.com/jmbreda/Sanity"
##### VARIABLES #####
# Use variables for convenient updates/re-usability
ENV SOFTWARE_VERSION 1.0
RUN apt-get update \
&& apt-get install -y tzdata \
&& ln -fs /usr/share/zoneinfo/Europe/Berlin /etc/localtime \
&& dpkg-reconfigure --frontend noninteractive tzdata \
&& apt-get install --yes git make g++ libgomp1 \
&& git clone https://github.com/jmbreda/Sanity.git \
&& cd Sanity \
&& cd src \
&& make \
&& cp ../bin/Sanity /usr/bin \
&& cd ../../ \
&& rm -rf Sanity \
&& apt-get remove --purge --yes git make g++ \
#!/bin/sh
docker pull mlepetit/saanity
docker build src/.docker_modules/mlepetit/sanity -t 'lbmc/sanity'
docker push lbmc/sanity
version = "3.0.0"
container_url = "mlepetit/cellphonedb:latest"
params.cellphonedb = ""
params.cellphonedb_out = ""
params.pval=""
params.thres=""
params.iterations=""
params.gene_id=""
workflow cellphone_statistical_analysis {
take:
meta
counts
main:
cpdb_methods_stats(meta,counts)
cpdb_plot_dot_plot(cpdb_methods_stats.out.means,cpdb_methods_stats.out.pvalues)
cpdb_plot_heatmap(cpdb_methods_stats.out.pvalues)
emit:
means = cpdb_methods_stats.out.means
pvalues = cpdb_methods_stats.out.pvalues
deconvoluted = cpdb_methods_stats.out.deconvoluted
significant_means = cpdb_methods_stats.out.significant_means
dot_plot = cpdb_plot_dot_plot.out.dot_plot
heatmap = cpdb_plot_heatmap.out.heatmap
heatmap_log = cpdb_plot_heatmap.out.heatmap_log
count_network = cpdb_plot_heatmap.out.count_network
interactions_count = cpdb_plot_heatmap.out.interactions_count
}
process cpdb_methods_stats {
container = "${container_url}"
label "big_mem_multi_cpus"
if (params.cellphonedb_out != "") {
publishDir "results/${params.cellphonedb_out}", mode: 'copy'
}
input:
tuple val(id_mtx), path(meta)
tuple val(id_mtx), path(counts)
output:
tuple val(id_mtx), path("out/means.txt"), emit: means
tuple val(id_mtx), path("out/pvalues.txt"), emit: pvalues
tuple val(id_mtx), path("out/deconvoluted.txt"), emit: deconvoluted
tuple val(id_mtx), path("out/significant_means.txt"), emit: significant_means
script:
"""
cellphonedb method statistical_analysis ${params.meta} ${params.counts} --counts-data ${params.gene_id} --threads ${task.cpus} --iterations ${params.iterations} --pvalue ${params.pval} --threshold ${params.thres}
"""
}
process cpdb_plot_dot_plot {
container = "${container_url}"
label "big_mem_mono_cpus"
if (params.cellphonedb_out != "") {
publishDir "results/${params.cellphonedb_out}", mode: 'copy'
}
input:
tuple val(id_mtx), path(means)
tuple val(id_mtx), path(pvalues)
output:
tuple val(id_mtx), path("out/plot.pdf"), emit: dot_plot
script:
"""
mkdir ./out
cellphonedb plot dot_plot --means-path ${means} --pvalues-path ${pvalues}
"""
}
process cpdb_plot_heatmap {
container = "${container_url}"
label "big_mem_multi_cpus"
if (params.cellphonedb_out != "") {
publishDir "results/${params.cellphonedb_out}", mode: 'copy'
}
input:
tuple val(id_mtx), path(pvalues)
output:
tuple val(id_mtx), path("out/heatmap_count.pdf"), emit: heatmap
tuple val(id_mtx), path("out/heatmap_log_count.pdf"), emit: heatmap_log
tuple val(id_mtx), path("out/count_network.txt"), emit: count_network
tuple val(id_mtx), path("out/interaction_count.txt"), emit: interactions_count
script:
"""
mkdir ./out
cellphonedb plot heatmap_plot --pvalues-path ${pvalues} --pvalue ${params.pval} ${params.meta}
"""
}
...@@ -151,3 +151,4 @@ process fastp_accel_1splus { ...@@ -151,3 +151,4 @@ process fastp_accel_1splus {
--report_title ${file_prefix} --report_title ${file_prefix}
""" """
} }
...@@ -268,7 +268,7 @@ workflow index_fasta_velocity { ...@@ -268,7 +268,7 @@ workflow index_fasta_velocity {
process index_fasta_velocity_default { process index_fasta_velocity_default {
container = "${container_url}" container = "${container_url}"
label "big_mem_mono_cpus" label "big_mem_multi_cpus"
tag "$file_id" tag "$file_id"
if (params.index_fasta_out != "") { if (params.index_fasta_out != "") {
publishDir "results/${params.index_fasta_out}", mode: 'copy' publishDir "results/${params.index_fasta_out}", mode: 'copy'
......
container_url="mlepetit/sanity:latest"
params.sanity_out=""
params.sanity=""
process normalization_sanity
{
container="${container_url}"
label "big_mem_multi_cpus"
if (params.sanity_out != "") {
publishDir "results/${params.sanity_out}", mode: 'copy'
}
else {
publishDir "results/normalize_matrix/", mode: 'copy'
}
input:
tuple val(id_mtx), path(raw_filtered_mtx)
output:
tuple val(id_mtx),path("log_transcription_quotients.txt"), emit: normalize_filtered_mtx
tuple val(id_mtx), path("ltq_error_bars.txt") ,emit: ltq_error
script:
"""
Sanity -f ${raw_filtered_mtx} -n ${task.cpus} ${params.sanity}
"""
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment