Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PLINK changed to Plink #169

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
55 changes: 2 additions & 53 deletions admin/submit_csg.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -65,12 +65,6 @@
"sos run submit_csg.ipynb submit_csg \\\n",
" --cmd_file analysis_commands_20200825.txt \\\n",
" --dryrun\n",
"```\n",
"\n",
"```\n",
"sos run submit_csg.ipynb submit_csg2 \\\n",
" --cmd_file analysis_commands_20200825.txt \\\n",
" --dryrun\n",
"```"
]
},
Expand Down Expand Up @@ -103,52 +97,7 @@
" #$ -S /bin/bash\n",
" module load Singularity\n",
" module load VCFTOOLS/0.1.17\n",
" module load PLINK/1.9.10 \n",
" export PATH=$HOME/miniconda3/bin:$PATH\n",
" set -e\n",
" '''\n",
" script = tpl.lstrip() + ''.join(open($[_input:r]).readlines())\n",
" exe = 'cat' if $[dryrun] else 'qsub'\n",
" from subprocess import Popen, PIPE\n",
" import sys\n",
" p = Popen(exe, shell = False, stdin = PIPE, stdout = PIPE, stderr = PIPE, close_fds = True)\n",
" for item in p.communicate(script.encode(sys.getdefaultencoding())):\n",
" output = item.decode(sys.getdefaultencoding()).rstrip()\n",
" if output:\n",
" print(output)"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"kernel": "SoS"
},
"outputs": [],
"source": [
"# Job submission on CSG cluster\n",
"[submit_csg2]\n",
"# Path to job file\n",
"parameter: cmd_file=path\n",
"# Total run time allocated to the script\n",
"parameter: time='36:00:00'\n",
"# Memory allocated to a job, in terms of Gigabyte\n",
"parameter: mem=12\n",
"parameter: dryrun = False\n",
"input: cmd_file\n",
"python3: expand = '$[ ]'\n",
" tpl = '''\n",
" #!/bin/sh\n",
" #$ -l h_rt=$[time]\n",
" #$ -l h_vmem=$[mem+6]G\n",
" #$ -N gatk_joint_call\n",
" #$ -cwd\n",
" #$ -j y\n",
" #$ -q csg2.q -l t_pri\n",
" #$ -S /bin/bash\n",
" module load Singularity\n",
" module load VCFTOOLS/0.1.17\n",
" module load PLINK/1.9.10 \n",
" module load Plink/1.9.10 \n",
" export PATH=$HOME/miniconda3/bin:$PATH\n",
" set -e\n",
" '''\n",
Expand Down Expand Up @@ -201,7 +150,7 @@
"height": 0,
"style": "side"
},
"version": "0.22.9"
"version": "0.24.1"
}
},
"nbformat": 4,
Expand Down