This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# [invalid-]evidence-data | |
evidences: | |
gs_output_dir: evidence-files | |
downloads: | |
- bucket: otar000-evidence_input/CRISPR/json | |
output_filename: crispr-{suffix}.json.gz | |
resource: input-file | |
subset_key: | |
- target | |
- id |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# relation-data | |
ddr: | |
evidence-count: 3 | |
score-threshold: 0.1 | |
# association-data | |
scoring_weights: | |
crisp: 1 | |
europepmc: 0.2 | |
expression_atlas: 0.2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM ubuntu:17.10 | |
ENV LANG C.UTF-8 | |
RUN apt-get update && \ | |
apt-get install -y python3 python3-pip libxml2-dev zlib1g-dev wget git cmake && \ | |
apt-get clean | |
RUN apt-get install -y python3-numpy # not necessary in scanpy 0.2.9.2/0.2.10 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# deconstructSigs signatures.cosmic | |
library("deconstructSigs") | |
library("tibble") | |
signatures.cosmic.tidy <- tibble::rownames_to_column(as.data.frame(t(signatures.cosmic))) | |
# COSMIC http://cancer.sanger.ac.uk/cancergenome/assets/signatures_probabilities.txt | |
cosmic.current <- read.delim("http://cancer.sanger.ac.uk/cancergenome/assets/signatures_probabilities.txt", check.names = F) | |
cosmic.current.clean <- cosmic.current[ , colnames(cosmic.current) != ""] | |
cosmic.current.tidy <- cosmic.current.clean[,names(cosmic.current.clean) not in c("Substitution Type","Trinucleotide")] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import h5py | |
# HDF5 file with two arrays: 'trainxdata' (samples) and 'traindata' (labels) | |
INFILE_SAMPLES = '' | |
INFILE_REFERENCE_FASTA = '' | |
OUTFILE_FASTA = 'deepsea_train10k.fa' | |
OUTFILE_BED = 'deepsea_train10k.bed' | |
def onehot2base(onehot): | |
if onehot == [1,0,0,0]: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
type sample = { | |
x : float; | |
y : float | |
} | |
type model = { | |
theta : float; | |
beta : float | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
pid=$1 | |
nsamples=$2 | |
sleeptime=$3 | |
for x in $(seq 1 $nsamples) | |
do | |
jstack $pid | |
sleep $sleeptime | |
done | \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import com.twitter.bijection.avro.{GenericAvroCodec, GenericAvroCodecs} | |
import com.twitter.bijection.Injection | |
import com.twitter.chill._ | |
import org.apache.avro.generic.{GenericRecord, GenericRecordBuilder} | |
import org.apache.avro.SchemaBuilder | |
import scala.util.{Failure, Success} | |
object HelloKryo { | |
def main(args: Array[String]) { | |
// Build a schema |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.io.{IOException, File, ByteArrayOutputStream} | |
import org.apache.avro.file.{DataFileReader, DataFileWriter} | |
import org.apache.avro.generic.{GenericDatumReader, GenericDatumWriter, GenericRecord, GenericRecordBuilder} | |
import org.apache.avro.io.EncoderFactory | |
import org.apache.avro.SchemaBuilder | |
import org.apache.hadoop.fs.Path | |
import parquet.avro.{AvroParquetReader, AvroParquetWriter} | |
import scala.util.control.Breaks.break | |
object HelloAvro { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from string import Template | |
from distutils.util import strtobool | |
from flask import Flask, request | |
from flask.ext.restful import Api, Resource | |
import psycopg2 | |
# Flask-RESTful Api object | |
app = Flask(__name__) |
NewerOlder