Gscripts
General Use Scripts and Helper functions
Install / Use
/learn @YeoLab/GscriptsREADME
The code provided herein is without any warranty.
It is mostly development code, bugs and inefficiencies are likely, please report any problems to the gscripts issues page.
How to install gscripts
cd path/to/gscripts; easy_install .
(NOT pip)
How to import qtools
from gscripts.qtools import Submitter
For example, to submit a single line of code to a compute job, you can do:
from gscripts.qtools import Submitter
exon_seqs = '/projects/ps-yeolab/obotvinnik/miso_helpers/hg19/se_exon2.fasta'
mirna_seqs = '/projects/ps-yeolab/genomes/mirbase/release_21/human_mature_17bp.fa'
rnahybrid_results = '/projects/ps-yeolab/obotvinnik/miso_helpers/hg19/se_exon2_RNAhybrid_mirbase_human_mature_17bp.txt'
command = 'RNAhybrid -c -s 3utr_human -q {} -t {} > {}'.format(mirna_seqs, exon_seqs, rnahybrid_results)
sub = Submitter([command], 'RNAhybrid', walltime='120:00:00', write_and_submit=True, nodes=1, ppn=1)
Which will write a file called RNAhybrid.sh which has these contents:
#!/bin/bash
#PBS -N RNAhybrid
#PBS -o RNAhybrid.sh.out
#PBS -e RNAhybrid.sh.err
#PBS -V
#PBS -l walltime=120:00:00
#PBS -l nodes=1:ppn=1
#PBS -A yeo-group
#PBS -q home
# Go to the directory from which the script was called
cd $PBS_O_WORKDIR
RNAhybrid -c -s 3utr_human -q /projects/ps-yeolab/genomes/mirbase/release_21/human_mature_17bp.fa -t /projects/ps-yeolab/obotvinnik/miso_helpers/hg19/se_exon2.fasta > /projects/ps-yeolab/obotvinnik/miso_helpers/hg19/se_exon2_RNAhybrid_mirbase_human_mature_17bp.txt
How to import Python version of which
from gscripts import which
Related Skills
node-connect
349.0kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
109.4kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
349.0kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
qqbot-media
349.0kQQBot 富媒体收发能力。使用 <qqmedia> 标签,系统根据文件扩展名自动识别类型(图片/语音/视频/文件)。

