text
stringlengths
0
1.05M
meta
dict
__author__ = 'Guo' from flask_wtf import FlaskForm, RecaptchaField from wtforms import StringField, PasswordField, SubmitField, BooleanField from wtforms.validators import DataRequired, Length, EqualTo from movieapp.models.models import User class LoginForm(FlaskForm): username = StringField('用户名', [DataRequired...
{ "repo_name": "Justlzp/project_team", "path": "webDemo/movieapp/models/forms.py", "copies": "1", "size": "1941", "license": "mit", "hash": -2853584820175747000, "line_mean": 26.9402985075, "line_max": 77, "alpha_frac": 0.6231961518, "autogenerated": false, "ratio": 4.023655913978494, "config_te...
__author__ = 'Guorong Xu<g1xu@ucsd.edu>' def configure_star(option_list): output_file_name = "/Users/guorongxu/Desktop/JupyterPythonNotebook/alignment.sh" filewriter = open(output_file_name, "w") filewriter.write("#!/bin/bash\n") filewriter.write("\n") filewriter.write("samtools=/shared/workspace/...
{ "repo_name": "ucsd-ccbb/jupyter-genomics", "path": "src/awsCluster/rnaSeq/ConfigureBuilder.py", "copies": "1", "size": "1140", "license": "mit", "hash": -4839223957919241000, "line_mean": 44.6, "line_max": 96, "alpha_frac": 0.648245614, "autogenerated": false, "ratio": 2.9381443298969074, "con...
__author__ = 'Guorong Xu<g1xu@ucsd.edu>' import os import re import sys def parse(count_file_dir): mirna_count_list = {} count_file_list = [] file_name_list = [] for root, dirs, files in os.walk(count_file_dir): for file in files: if file.endswith(".counts.txt"): c...
{ "repo_name": "ucsd-ccbb/jupyter-genomics", "path": "src/awsCluster/miRNASeq/MergeCountFile.py", "copies": "1", "size": "1989", "license": "mit", "hash": 363366553473949900, "line_mean": 33.2931034483, "line_max": 73, "alpha_frac": 0.5238813474, "autogenerated": false, "ratio": 3.4591304347826086...
__author__ = 'Guorong Xu<g1xu@ucsd.edu>' import os import YamlFileMaker from cfnCluster import ConnectionManager from util import DesignFileLoader workspace = "/shared/workspace/RNASeqPipeline" data_dir = "/shared/workspace/data_archive/RNASeq" ## run all analysis from download, alignment, counting and differential ...
{ "repo_name": "ucsd-ccbb/jupyter-genomics", "path": "src/awsCluster/rnaSeq/RNAPipelineManager.py", "copies": "1", "size": "2438", "license": "mit", "hash": -3024206598635398, "line_mean": 40.3389830508, "line_max": 132, "alpha_frac": 0.706316653, "autogenerated": false, "ratio": 3.463068181818181...
__author__ = 'Guorong Xu<g1xu@ucsd.edu>' import os import YamlFileMaker from util import DesignFileLoader from cfnCluster import ConnectionManager workspace = "/shared/workspace/ChiPSeqPipeline" data_dir = "/shared/workspace/data_archive/ChiPSeq" ## run all analysis from download, alignment, counting and differenti...
{ "repo_name": "ucsd-ccbb/jupyter-genomics", "path": "src/awsCluster/chipSeq/ChipPipelineManager.py", "copies": "1", "size": "2548", "license": "mit", "hash": -6075687644240717000, "line_mean": 40.7868852459, "line_max": 133, "alpha_frac": 0.7029042386, "autogenerated": false, "ratio": 3.466666666...
__author__ = 'Guorong Xu<g1xu@ucsd.edu>' import paramiko from scp import SCPClient ## connecting the master instance of a CFNCluster by the hostname, username and private key file ## return a ssh client def connect_master(hostname, username, private_key_file): private_key = paramiko.RSAKey.from_private_key_file(p...
{ "repo_name": "ucsd-ccbb/jupyter-genomics", "path": "src/awsCluster/cfnCluster/ConnectionManager.py", "copies": "1", "size": "1464", "license": "mit", "hash": -6044269899717011000, "line_mean": 33.8571428571, "line_max": 96, "alpha_frac": 0.7295081967, "autogenerated": false, "ratio": 3.494033412...
__author__ = 'Guorong Xu<g1xu@ucsd.edu>' import re import os import math ## Parsing the raw expression file and return the average expression value for each gene. def parse_geo_expression(raw_expression_file): gene_expression_list = {} with open(raw_expression_file) as fp: lines = fp.readlines() ...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/Utils/RawFileParser.py", "copies": "1", "size": "2717", "license": "mit", "hash": 665955991386952100, "line_mean": 35.7162162162, "line_max": 165, "alpha_frac": 0.5506072874, "autogenerated": false, "ratio": 4.26530612244898, "config_test"...
__author__ = 'Guorong Xu<g1xu@ucsd.edu>' import re ## load design file def load_design_file(design_file): sample_list = [] group_list = [] with open(design_file, 'r+') as f: lines = f.readlines() for line in lines: if line.startswith("##"): continue ...
{ "repo_name": "ucsd-ccbb/jupyter-genomics", "path": "src/awsCluster/util/DesignFileLoader.py", "copies": "1", "size": "2267", "license": "mit", "hash": -4499095020400070700, "line_mean": 35.5806451613, "line_max": 85, "alpha_frac": 0.5024261138, "autogenerated": false, "ratio": 3.956369982547993,...
__author__ = 'Guorong Xu<g1xu@ucsd.edu>' import sys import subprocess import PBSTracker import GroupFileMaker import YamlFileReader root_dir = "/shared/workspace/RNASeqPipeline" data_dir = "/shared/workspace/data_archive/RNASeq" ## run all analysis from download, alignment, counting and differential calculation. def...
{ "repo_name": "ucsd-ccbb/jupyter-genomics", "path": "src/awsCluster/server/RNASeqPipeline/RNASeqPipeline.py", "copies": "1", "size": "10590", "license": "mit", "hash": -4395263804792189400, "line_mean": 44.2564102564, "line_max": 129, "alpha_frac": 0.6072710104, "autogenerated": false, "ratio": 3...
__author__ = 'Guorong Xu<g1xu@ucsd.edu>' import sys import subprocess import PBSTracker import YamlFileReader root_dir = "/shared/workspace/ChiPSeqPipeline" data_dir = "/shared/workspace/data_archive/ChiPSeq" ## run all analysis from download, alignment, counting and differential calculation. def run_analysis(yaml_f...
{ "repo_name": "ucsd-ccbb/jupyter-genomics", "path": "src/awsCluster/server/ChipSeqPipeline/homer_workflow/ChipSeqPipeline.py", "copies": "1", "size": "15575", "license": "mit", "hash": 7320295316328330000, "line_mean": 50.0655737705, "line_max": 129, "alpha_frac": 0.5791332263, "autogenerated": fal...
__author__ = 'Guorong Xu<g1xu@ucsd.edu>' import time ## make a yaml file for analysis of WGSPipeline def make_yaml_file(yaml_file, project_name, analysis_steps, s3_input_files_address, sample_list, group_list, s3_output_files_address, genome, style): filewriter = open(yaml_file, "w") filewr...
{ "repo_name": "ucsd-ccbb/jupyter-genomics", "path": "src/awsCluster/util/YamlFileMaker.py", "copies": "1", "size": "1729", "license": "mit", "hash": 2974946542827189000, "line_mean": 39.2093023256, "line_max": 89, "alpha_frac": 0.5801041064, "autogenerated": false, "ratio": 3.4305555555555554, ...
__author__ = 'Guorong Xu<g1xu@ucsd.edu>' import time ## make a yaml file for analysis of WGSPipeline def make_yaml_file(yaml_file, workflow, project_name, analysis_steps, s3_input_files_address, sample_list, group_list, s3_output_files_address, genome, style): filewriter = open(yaml_file, "w") ...
{ "repo_name": "ucsd-ccbb/jupyter-genomics", "path": "src/awsCluster/chipSeq/YamlFileMaker.py", "copies": "1", "size": "1754", "license": "mit", "hash": -2548215372770545700, "line_mean": 38.8636363636, "line_max": 93, "alpha_frac": 0.5798175599, "autogenerated": false, "ratio": 3.432485322896282,...
__author__ = 'Guorong Xu<g1xu@ucsd.edu>' import zipfile import re import os def read_data_file(workspace, file_name): archive = zipfile.ZipFile(workspace + "/" + file_name, 'r') data_file = archive.read(file_name[:-4] + "/fastqc_data.txt") percentages = 0.0 lines = re.split(r'\n+', data_file) p...
{ "repo_name": "ucsd-ccbb/jupyter-genomics", "path": "src/awsCluster/util/FastqcParser.py", "copies": "1", "size": "1155", "license": "mit", "hash": -5409344797158501000, "line_mean": 27.875, "line_max": 103, "alpha_frac": 0.5636363636, "autogenerated": false, "ratio": 3.5981308411214954, "confi...
__author__ = 'guorongxu' import csv import re import os import sys VALID_COLUMN_NO = 27 # split id lists into dictionary def other_id(other_ids): p = other_ids.strip(";").replace(";", ",").split(",") other_id = {} for id in p: try: ind = id.index(":") key, value = id[:ind]...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/Clinvar/ClinvarParser.py", "copies": "1", "size": "5363", "license": "mit", "hash": -8342121511572582000, "line_mean": 32.9430379747, "line_max": 149, "alpha_frac": 0.492075331, "autogenerated": false, "ratio": 3.1941631923764144, "config_...
__author__ = 'guorongxu' import logging def get_abbreviation_tumor_name(short_name): if short_name == "AcuteMyeloidLeukemia": return "Leukemia" elif short_name == "AdrenocorticalCancer": return "Adrenal" elif short_name == "BladderCancer": return "Bladder" elif short_name == "B...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/GEO/Helper.py", "copies": "1", "size": "4775", "license": "mit", "hash": 3476424788206095400, "line_mean": 35.4503816794, "line_max": 69, "alpha_frac": 0.6433507853, "autogenerated": false, "ratio": 3.153896961690885, "config_test": false,...
__author__ = 'guorongxu' import logging def get_abbreviation_tumor_name(short_name): if short_name == "LAML": return "Leukemia" elif short_name == "ACC": return "Adrenal" elif short_name == "BLCA": return "Bladder" elif short_name == "LGG": return "Brain" elif short...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/TCGA/Helper.py", "copies": "1", "size": "5354", "license": "mit", "hash": 1900844647774057500, "line_mean": 31.6463414634, "line_max": 115, "alpha_frac": 0.5956294359, "autogenerated": false, "ratio": 3.140175953079179, "config_test": fals...
__author__ = 'guorongxu' import os import re import itertools ## Parsing the go term file and return GO ID list with descriptions. def parse_correlation_file(workspace, data_set, tumor_type): node_hash = {} root_correlation_dir = workspace + "/" + data_set + "/correlation_files" ## Iterate all combinati...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/TCGA/CorrelationParser.py", "copies": "1", "size": "2288", "license": "mit", "hash": 3728031388382309000, "line_mean": 35.3333333333, "line_max": 118, "alpha_frac": 0.5240384615, "autogenerated": false, "ratio": 3.6608, "config_test": fals...
__author__ = 'guorongxu' import os import re import sys import math import logging import Helper from GO import GOLocusParser from Utils import HypergeomCalculator, RawFileParser ## To print JSON file for each cluster. def print_json(prefix, output_file, network_type, cluster_list, GO_ID_list, total_...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/GEO/ClusterJSONBuilder.py", "copies": "1", "size": "12613", "license": "mit", "hash": 8534852984964604000, "line_mean": 44.0464285714, "line_max": 205, "alpha_frac": 0.5963688258, "autogenerated": false, "ratio": 3.2283081648323524, "confi...
__author__ = 'guorongxu' import os import re import sys ## deduplicate the cluster files. def deduplicate_cluster(cluster_file_dir, combination): clusters = {} for gamma in [1, 4, 7, 11, 14, 17, 20]: cluster_folder = cluster_file_dir + "/" + combination + "_gamma_" + str(gamma) cluster_file = ...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/TCGA/ClusterFilter.py", "copies": "1", "size": "4464", "license": "mit", "hash": 4661355096053464000, "line_mean": 39.9541284404, "line_max": 120, "alpha_frac": 0.5665322581, "autogenerated": false, "ratio": 3.795918367346939, "config_test...
__author__ = 'guorongxu' import os import re import sys ## deduplicate the cluster files. def deduplicate_cluster(cluster_file_dir, project_name): clusters = {} print "cluster_file_dir: " + cluster_file_dir print "project_name: " + project_name for gamma in [1, 4, 7, 11, 14, 17, 20]: cluster_...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/GEO/ClusterFilter.py", "copies": "1", "size": "4867", "license": "mit", "hash": -3823716067158384000, "line_mean": 39.8991596639, "line_max": 117, "alpha_frac": 0.5759194576, "autogenerated": false, "ratio": 3.62397617274758, "config_test"...
__author__ = 'guorongxu' import os import re import sys ## deduplicate the cluster files. def modify_cluster(cluster_file): print "cluster_file: " + cluster_file modified_cluster_file = cluster_file + ".mod" filewriter = open(modified_cluster_file, "a") with open(cluster_file) as fp: lines =...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/GEO/ClusterModifier.py", "copies": "1", "size": "1139", "license": "mit", "hash": 3215216074903704000, "line_mean": 27.475, "line_max": 112, "alpha_frac": 0.6057945566, "autogenerated": false, "ratio": 3.5372670807453415, "config_test": fa...
__author__ = 'guorongxu' import os import re import sys #Parsing the expression files under the folder def preprocess(root_raw_dir): for root, directories, filenames in os.walk(root_raw_dir): for filename in filenames: if filename.endswith(".txt"): inputfile = os.path.join(root...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/GEO/Preprocess.py", "copies": "1", "size": "2928", "license": "mit", "hash": 577144463609934000, "line_mean": 50.3859649123, "line_max": 106, "alpha_frac": 0.3920765027, "autogenerated": false, "ratio": 5.545454545454546, "config_test": fa...
__author__ = 'guorongxu' import os import re ## Parsing the go term file and return GO ID list with descriptions. def parse_correlation_file(input_file): node_hash = {} if os.path.exists(input_file): with open(input_file) as fp: lines = fp.readlines() for line in lines: ...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/GEO/CorrelationParser.py", "copies": "1", "size": "1437", "license": "mit", "hash": -4790052131590076000, "line_mean": 30.9555555556, "line_max": 81, "alpha_frac": 0.4892136395, "autogenerated": false, "ratio": 3.5481481481481483, "config_...
__author__ = 'guorongxu' import os import subprocess import itertools from datetime import datetime tumor_types = ["PRAD", "STES"] #tumor_types = ["ACC", "BLCA", "BRCA", "CESC", "CHOL", "COAD", "COADREAD", "DLBC", # "ESCA", "GBM", "GBMLGG", "HNSC", "KICH", "KIPAN", "KIRC", "KIRP", # "LAML"...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/TCGA/TCGACaller.py", "copies": "1", "size": "19352", "license": "mit", "hash": -5937595383814409000, "line_mean": 58.9133126935, "line_max": 149, "alpha_frac": 0.5606655643, "autogenerated": false, "ratio": 3.4064425277239923, "config_test...
__author__ = 'guorongxu' import os import subprocess import logging from datetime import datetime ## To download the raw files. def download(workspace, data_set, s3_input_files_address, disease_name): root_raw_dir = workspace + "/" + data_set + "/raw_files" print datetime.now().strftime('%Y-%m-%d %H:%M:%S') ...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/GEO/GEOCaller.py", "copies": "1", "size": "10331", "license": "mit", "hash": -8322975703120247000, "line_mean": 53.0890052356, "line_max": 153, "alpha_frac": 0.5936501791, "autogenerated": false, "ratio": 3.593391304347826, "config_test": ...
__author__ = 'guorongxu' import os import sys import logging from Louvain import cluster_analysis_module def calculate_louvain_c_plus(input_file, code_path, temp_path, output_file, gamma, algorithm): cluster_analysis_module.results_TCGA_cluster(input_file, code_path, temp_path, algorithm, edge_thresh=0.0, ...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/GEO/ClusterBuilder.py", "copies": "1", "size": "1856", "license": "mit", "hash": 1597099762434160000, "line_mean": 50.5555555556, "line_max": 126, "alpha_frac": 0.6950431034, "autogenerated": false, "ratio": 3.1726495726495725, "config_tes...
__author__ = 'guorongxu' import os import sys import logging import pandas as pd def parse(root_raw_dir, root_expression_dir, tumor_type, release_year, release_month, release_day): mirna_file = root_raw_dir + "/" + tumor_type + "/gdac.broadinstitute.org_" + tumor_type \ + ".Merge_mirnaseq__illumi...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/TCGA/MicroRNAParser.py", "copies": "1", "size": "2720", "license": "mit", "hash": -3734555932356713000, "line_mean": 33.8846153846, "line_max": 116, "alpha_frac": 0.6084558824, "autogenerated": false, "ratio": 3.188745603751465, "config_te...
__author__ = 'guorongxu' import os import sys import logging import pandas as pd def parse(root_raw_dir, root_expression_dir, tumor_type, release_year, release_month, release_day): rnaseq_file = root_raw_dir + "/" + tumor_type + "/gdac.broadinstitute.org_" + tumor_type \ + ".Merge_rnaseqv2__ill...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/TCGA/RNASeqParser.py", "copies": "1", "size": "3441", "license": "mit", "hash": -5952194709790103000, "line_mean": 34.8541666667, "line_max": 118, "alpha_frac": 0.5852949724, "autogenerated": false, "ratio": 3.21588785046729, "config_test"...
__author__ = 'guorongxu' import os import sys ## To process JSON files and append an id for each document. def process_json(workspace, data_set): root_json_dir = workspace + "/" + data_set + "/json_files" ##id number rule: # the first digital "3" is the Clinvar index id; # the first two digital "01" i...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/Clinvar/IDAppender.py", "copies": "1", "size": "1583", "license": "mit", "hash": -9179481092629147000, "line_mean": 35, "line_max": 96, "alpha_frac": 0.5243209097, "autogenerated": false, "ratio": 4.017766497461929, "config_test": false, ...
__author__ = 'guorongxu' import os import sys ## To process JSON files and append an id for each document. def process_louvain_cluster_json(workspace, data_set): root_json_dir = workspace + "/" + data_set + "/louvain_json_files" ##id number rule: # the first digital "2" is the cluster index id; # the ...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/GEO/IDAppender.py", "copies": "1", "size": "4250", "license": "mit", "hash": -2800434129813718000, "line_mean": 40.6764705882, "line_max": 96, "alpha_frac": 0.5188235294, "autogenerated": false, "ratio": 4.199604743083004, "config_test": f...
__author__ = 'guorongxu' import paramiko from scp import SCPClient ## connecting the master instance of a cfncluster by the hostname, username and private key file ## return a ssh client def connect_master(hostname, username, private_key_file): private_key = paramiko.RSAKey.from_private_key_file(private_key_file)...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "cfncluster/ConnectionManager.py", "copies": "1", "size": "1118", "license": "mit", "hash": -2266354778082478800, "line_mean": 31.8823529412, "line_max": 96, "alpha_frac": 0.7262969589, "autogenerated": false, "ratio": 3.6298701298701297, "config_test...
__author__ = 'guorongxu' import re import logging ## Parsing the go gene file and return GO ID list with all gene lists. def parse_gene_info_file(gene_info_file): entrez_id_list = {} with open(gene_info_file) as fp: lines = fp.readlines() for line in lines: if line.startswith("#F...
{ "repo_name": "ucsd-ccbb/jupyter-genomics", "path": "src/networkAnalysis/go_annotation/GOLocusParser.py", "copies": "1", "size": "3530", "license": "mit", "hash": -5838396791826173000, "line_mean": 32, "line_max": 94, "alpha_frac": 0.5609065156, "autogenerated": false, "ratio": 3.374760994263862,...
__author__ = 'guorongxu' import re import os import sys import logging import MatrixPrinter ## Parsing mutation files and return a dictionary of ID and name. def parse(root_raw_dir, root_expression_dir, tumor_type, release_year, release_month, release_day): mutation_file_folder = root_raw_dir + "/" + tumor_type +...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/TCGA/MutationParser.py", "copies": "1", "size": "6634", "license": "mit", "hash": 6289188456409618000, "line_mean": 38.2603550296, "line_max": 105, "alpha_frac": 0.6097377148, "autogenerated": false, "ratio": 4.102659245516389, "config_tes...
__author__ = 'guorongxu' import re import os import sys ## To parse Drugbank JSON files and extract the gene list. def process_drugbank_json(workspace, data_set): root_json_dir = workspace + "/" + data_set + "/json_files" gene_hash = {} for dirpath, directories, filenames in os.walk(root_json_dir): ...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/ClusterDrug/ClusterDrugJSONBuilder.py", "copies": "1", "size": "6200", "license": "mit", "hash": 7217857791134903000, "line_mean": 41.4657534247, "line_max": 113, "alpha_frac": 0.475483871, "autogenerated": false, "ratio": 3.855721393034826,...
__author__ = 'guorongxu' import re import os import sys ## To parse JSON files and extract the gene list. def process_json(workspace, data_set): root_json_dir = workspace + "/" + data_set + "/json_files" output_file = root_json_dir + "/druggable_gene_name.txt" filewriter = open(output_file, "a") for ...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/Drugbank/GeneExtractor.py", "copies": "1", "size": "1800", "license": "mit", "hash": 8189850695554725000, "line_mean": 34.3137254902, "line_max": 102, "alpha_frac": 0.4555555556, "autogenerated": false, "ratio": 3.8626609442060085, "config...
__author__ = 'guorongxu' import re import sys import GencodeGTFParser def merge_all_sample_count(workflow, project_name, sample_list): gencode_gtf_file = "/shared/workspace/software/gencode/gencode.v19.annotation.gtf" localpath = "/shared/workspace/data_archive/RNASeq/" + project_name + "/" + workflow + "/" ...
{ "repo_name": "ucsd-ccbb/jupyter-genomics", "path": "src/awsCluster/server/RNASeqPipeline/star_htseq_workflow/MergeCountFile.py", "copies": "2", "size": "2854", "license": "mit", "hash": -6151434176638072000, "line_mean": 33.8048780488, "line_max": 109, "alpha_frac": 0.5350385424, "autogenerated": ...
__author__ = 'guorongxu' import re import sys import logging ## Parsing the go gene file and return GO ID list with all gene lists. def parse_go_gene_file(go_gene_file): GO_ID_list = {} GO_unique_gene_list = {} with open(go_gene_file) as fp: lines = fp.readlines() for line in lines: ...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/GO/GOParser.py", "copies": "2", "size": "2872", "license": "mit", "hash": -5872259307306380000, "line_mean": 31.2696629213, "line_max": 88, "alpha_frac": 0.561281337, "autogenerated": false, "ratio": 3.2822857142857145, "config_test": fals...
__author__ = 'guorongxu' import sys from datetime import datetime from GEO import GEOCaller from TCGA import TCGACaller from Pubmed import PubmedCaller from Cosmic import CosmicCaller from Clinvar import ClinvarCaller from Drugbank import DrugbankCaller from ClusterDrug import ClusterDrugCaller from Utils import PBSTr...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/MainEntry.py", "copies": "1", "size": "17167", "license": "mit", "hash": -3153042629916394500, "line_mean": 59.2350877193, "line_max": 126, "alpha_frac": 0.6097745675, "autogenerated": false, "ratio": 3.4736948603804128, "config_test": fal...
__author__ = 'guorongxu' import sys import os import CorrelationParser ## To print JSON file for each cluster. def print_json(tumor_type, output_file, node_hash): if os.path.exists(output_file): return if not os.path.exists(os.path.dirname(output_file)): os.makedirs(os.path.dirname(output_fi...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/GEO/StarJSONBuilder.py", "copies": "1", "size": "3439", "license": "mit", "hash": -2436221988831930400, "line_mean": 42.5316455696, "line_max": 107, "alpha_frac": 0.5591741785, "autogenerated": false, "ratio": 3.0760286225402504, "config_t...
__author__ = 'guorongxu' import sys import os import Helper import CorrelationParser ## To print JSON file for each cluster. def print_json(workspace, data_set, tumor_type, node_hash): root_json_dir = workspace + "/" + data_set + "/json_files" output_file = root_json_dir + "/" + tumor_type + "/genes_tcga.jso...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/TCGA/StarJSONBuilder.py", "copies": "1", "size": "2712", "license": "mit", "hash": 4644712772703038000, "line_mean": 38.8823529412, "line_max": 106, "alpha_frac": 0.5254424779, "autogenerated": false, "ratio": 3.1868390129259696, "config_t...
__author__ = 'guorongxu' import sys import os import json import ImpactFactorParser ## To build the edge file between author and gene. def output(output_file, author_list, journal_list): # Open a file filewriter = open(output_file, "a") for author in author_list: gene_list = author_list.get(auth...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/Pubmed/EdgeBuilder.py", "copies": "1", "size": "3132", "license": "mit", "hash": -18998545766018604, "line_mean": 35.8588235294, "line_max": 115, "alpha_frac": 0.525862069, "autogenerated": false, "ratio": 4.261224489795918, "config_test":...
__author__ = 'guorongxu' import sys import os import json import ImpactFactorParser #To build the JSON file for author and gene. def output_json(output_file, author_list, journal_list): prefix = "authors_pubmed" # Open a file filewriter = open(output_file, "a") for author in author_list: fi...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/Pubmed/JSONBuilder.py", "copies": "1", "size": "5518", "license": "mit", "hash": 643186263524236500, "line_mean": 39.8740740741, "line_max": 117, "alpha_frac": 0.5076114534, "autogenerated": false, "ratio": 4.063328424153166, "config_test"...
__author__ = 'guorongxu' import sys import os import json #To build the JSON file for author and gene. def output(output_file, author_list): # Open a file filewriter = open(output_file, "a") for author in author_list: filewriter.write(author + "\tAuthor\n") filewriter.close() ## To def prin...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/Pubmed/AuthorPrinter.py", "copies": "1", "size": "1946", "license": "mit", "hash": 6097991063735031000, "line_mean": 31.45, "line_max": 69, "alpha_frac": 0.5282631038, "autogenerated": false, "ratio": 4.286343612334802, "config_test": fals...
__author__ = 'guorongxu' import sys import os import re ## To print JSON file for each cluster. def print_label(workspace, data_set, tumor_type, data_type): input_file = workspace + "/" + data_set + "/expression_files/" + tumor_type + "/" + data_type + "_matrix.txt" root_label_dir = workspace + "/" + data_set...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/TCGA/LabelPrinter.py", "copies": "1", "size": "1573", "license": "mit", "hash": 4490273601287149600, "line_mean": 29.8431372549, "line_max": 113, "alpha_frac": 0.5810553083, "autogenerated": false, "ratio": 3.121031746031746, "config_test"...
__author__ = 'guorongxu' import sys import re import math import logging def parse_correlation(correlation_file): correlation_list = {} with open(correlation_file) as fp: lines = fp.readlines() for line in lines: fields = re.split(r'\t+', line) correlation_list.update({...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/TCGA/ClusterReplacer.py", "copies": "1", "size": "1594", "license": "mit", "hash": 2328796387691531000, "line_mean": 29.6538461538, "line_max": 115, "alpha_frac": 0.5690087829, "autogenerated": false, "ratio": 3.457700650759219, "config_te...
__author__ = 'guorongxu' import sys import re import math import os import logging import IDMapParser ## To print JSON file for each cluster. def printJSON(outputFileName, project_info, networkType, clusterID, clusterSize, nodeList, nodeNames): index_type = "geo_cluster" if not os.path.exists(os.path.dirname...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/GEO/JSONBuilder.py", "copies": "1", "size": "6523", "license": "mit", "hash": -5654064237164112000, "line_mean": 42.2052980132, "line_max": 137, "alpha_frac": 0.5264448873, "autogenerated": false, "ratio": 3.7946480511925538, "config_test"...
__author__ = 'guorongxu' import sys import re import os import math import logging import Helper from GO import GOLocusParser from Utils import HypergeomCalculator ## To print JSON file for each cluster. def print_json(output_file, tumor_type, network_type, gamma, cluster_list, prefix): for cluster_ID in cluster...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/TCGA/IvanovskaJSONBuilder.py", "copies": "1", "size": "8425", "license": "mit", "hash": -202114967673218140, "line_mean": 43.8191489362, "line_max": 126, "alpha_frac": 0.5010089021, "autogenerated": false, "ratio": 3.404040404040404, "conf...
__author__ = 'guorongxu' import sys import re import os import math import logging import Helper from GO import GOLocusParser from Utils import HypergeomCalculator, RawFileParser ## To print JSON file for each cluster. def print_json(output_file, tumor_type, network_type, gamma, cluster_list, GO_ID_lis...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/TCGA/ClusterJSONBuilder.py", "copies": "1", "size": "12212", "license": "mit", "hash": 6158178745336371000, "line_mean": 44.0627306273, "line_max": 169, "alpha_frac": 0.5845889289, "autogenerated": false, "ratio": 3.2136842105263157, "conf...
__author__ = 'guorongxu' import sys def build_schema(output_file, prefix): filewriter = open(output_file, "a") filewriter.write("curl -XDELETE \'http://localhost:9200/authors/" + prefix + "\'\n") filewriter.write("curl -XPUT \'http://localhost:9200/authors/" + prefix + "/_mapping\' -d \'\n") filewrit...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/Schema/AuthorsSchemaBuilder.py", "copies": "1", "size": "2748", "license": "mit", "hash": -896331236537340700, "line_mean": 52.8823529412, "line_max": 108, "alpha_frac": 0.5345705968, "autogenerated": false, "ratio": 2.629665071770335, "co...
__author__ = 'guorongxu' import sys def build_schema(output_file, prefix): filewriter = open(output_file, "a") filewriter.write("curl -XDELETE \'http://localhost:9200/clusters/" + prefix + "\'\n") filewriter.write("curl -XPUT \'http://localhost:9200/clusters/" + prefix + "/_mapping\' -d \'\n") filewr...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/Schema/ClustersSchemaBuilder.py", "copies": "1", "size": "4488", "license": "mit", "hash": -5375628725189079000, "line_mean": 56.5384615385, "line_max": 104, "alpha_frac": 0.5360962567, "autogenerated": false, "ratio": 2.632258064516129, "...
__author__ = 'guorongxu' import sys def build_schema(output_file, prefix): filewriter = open(output_file, "a") filewriter.write("curl -XDELETE \'http://localhost:9200/conditions/" + prefix + "\'\n") filewriter.write("curl -XPUT \'http://localhost:9200/conditions/" + prefix + "/_mapping\' -d \'\n") fi...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/Schema/ConditionsSchemaBuilder.py", "copies": "1", "size": "2360", "license": "mit", "hash": 4583196242450873000, "line_mean": 49.2127659574, "line_max": 104, "alpha_frac": 0.5453389831, "autogenerated": false, "ratio": 2.6909920182440135, ...
__author__ = 'guorongxu' import sys def build_schema(output_file, prefix): filewriter = open(output_file, "a") filewriter.write("curl -XDELETE \'http://localhost:9200/drugs/" + prefix + "\'\n") filewriter.write("curl -XPUT \'http://localhost:9200/drugs/" + prefix + "/_mapping\' -d \'\n") filewriter.w...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/Schema/DrugsSchemaBuilder.py", "copies": "1", "size": "1857", "license": "mit", "hash": -2766666029948322000, "line_mean": 45.425, "line_max": 104, "alpha_frac": 0.5514270328, "autogenerated": false, "ratio": 2.747041420118343, "config_tes...
__author__ = 'guorongxu' import sys def build_schema(output_file, prefix): filewriter = open(output_file, "a") filewriter.write("curl -XDELETE \'http://localhost:9200/genes/" + prefix + "\'\n") filewriter.write("curl -XPUT \'http://localhost:9200/genes/" + prefix + "/_mapping\' -d \'\n") filewriter.w...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/Schema/GenesSchemaBuilder.py", "copies": "1", "size": "1922", "license": "mit", "hash": 2089707802289539800, "line_mean": 47.075, "line_max": 104, "alpha_frac": 0.5494276795, "autogenerated": false, "ratio": 2.7417974322396574, "config_tes...
__author__ = 'guorongxu' import sys def build_schema(output_file, prefix): filewriter = open(output_file, "a") filewriter.write("curl -XDELETE \'http://localhost:9200/groups/" + prefix + "\'\n") filewriter.write("curl -XPUT \'http://localhost:9200/groups/" + prefix + "/_mapping\' -d \'\n") filewriter...
{ "repo_name": "ucsd-ccbb/Oncolist", "path": "src/server/Schema/ClusterDrugSchemaBuilder.py", "copies": "1", "size": "1923", "license": "mit", "hash": -4140863123445168600, "line_mean": 47.075, "line_max": 104, "alpha_frac": 0.5486219449, "autogenerated": false, "ratio": 2.71994342291372, "confi...
__author__ = 'guru' import binascii dataSting = '0005010203041122334400b9' def checkSum(dataString,write): totalSum = 0 for i in range(0,22): if( i%2 == 0): totalSum += int(dataString[i:i+2],16) checkSum = dataString[22:24] tempString = hex(totalSum)[::-1] #[::-1] reverses the st...
{ "repo_name": "karthikeyan5/hexa", "path": "newjunk.py", "copies": "1", "size": "3088", "license": "mit", "hash": -6120561353378329000, "line_mean": 33.6966292135, "line_max": 136, "alpha_frac": 0.6651554404, "autogenerated": false, "ratio": 2.8021778584392014, "config_test": false, "has_no_k...
__author__ = 'guru' import RPi.GPIO as GPIO from time import sleep #define ConfigureLCDPINsDirection(Value) (TRISD = Value, \ # TRISCbits.TRISC3 = Value, \ # TRISCbits.TRISC4 = Value, \ # ...
{ "repo_name": "karthikeyan5/hexa", "path": "hexa-beta/glcdtest.py", "copies": "1", "size": "3956", "license": "mit", "hash": -6602461136981673000, "line_mean": 21.7413793103, "line_max": 94, "alpha_frac": 0.6099595551, "autogenerated": false, "ratio": 3.142176330420969, "config_test": false, ...
__author__ = 'guru' #state 40 = enter the phone number #state 61 = phone number already exist try new number #state 100 = Ask's user to place their 1st finger on FPS #state 101 = Ask's user to place their 2st finger on FPS #state 20 = Scanning ur finger now #state 30 = remove ur finger and place it again #state 41 = ...
{ "repo_name": "karthikeyan5/hexa", "path": "hexa-beta/userRegistrationScreen.py", "copies": "1", "size": "7575", "license": "mit", "hash": 722466755553882100, "line_mean": 30.0450819672, "line_max": 69, "alpha_frac": 0.617029703, "autogenerated": false, "ratio": 3.0071456927352123, "config_test...
__author__ = 'guru' import serial import binascii serialport = serial.Serial("/dev/ttyAMA0", timeout=10) serialport.baudrate = 9600 serialport.flush() autoid = 0 def fpsTransmitter(data): question = binascii.unhexlify(data) print("string trans >",data) serialport.flush() se...
{ "repo_name": "karthikeyan5/hexa", "path": "hexa-beta/fpsDriver.py", "copies": "1", "size": "7966", "license": "mit", "hash": 1032470945624009900, "line_mean": 28.1742424242, "line_max": 118, "alpha_frac": 0.5222194326, "autogenerated": false, "ratio": 3.1991967871485945, "config_test": false, ...
__author__ = 'guru' import sqlite3 import os.path import sys conn = sqlite3.connect('hexabeta.db') print("Opened database successfully") def createtables(): conn.execute('''CREATE TABLE IF NOT EXISTS CustomerDetails (MobileNumber CHAR(10) PRIMARY KEY NOT NULL UNIQUE, AccountBalance RE...
{ "repo_name": "karthikeyan5/hexa", "path": "hexa-beta/database.py", "copies": "1", "size": "8478", "license": "mit", "hash": 4549566417479037000, "line_mean": 37.069124424, "line_max": 137, "alpha_frac": 0.627388535, "autogenerated": false, "ratio": 3.957983193277311, "config_test": false, "h...
__author__ = 'guru' #state 10 = Ask's user to place their finger on FPS #state 20 = Scanning ur finger now #state 21 = Acccount not found #state 30 = Mini Statement(last 3 transcations) #screen = 0 vendor,screen = 1 customer. import GLCD as g currentState = 0 fontWidth = 6 lineLength = 21 def ...
{ "repo_name": "karthikeyan5/hexa", "path": "hexa-beta/miniStatementScreen.py", "copies": "1", "size": "3677", "license": "mit", "hash": 9066885971695240000, "line_mean": 27.9105691057, "line_max": 75, "alpha_frac": 0.6040250204, "autogenerated": false, "ratio": 3.033828382838284, "config_test":...
__author__ = 'guru' #state 10 = payment amount #state 20 = Ask's user to place their finger on FPS #state 30 = Scanning ur finger now #state 31 = account not found #state 32 = no enough balance #state 40 = payment successful #screen = 0 vendor,screen = 1 customer. import GLCD as g currentState = 0 fontW...
{ "repo_name": "karthikeyan5/hexa", "path": "hexa-beta/paymentScreen.py", "copies": "1", "size": "5382", "license": "mit", "hash": -3797837099417367000, "line_mean": 29.8461538462, "line_max": 71, "alpha_frac": 0.5930880713, "autogenerated": false, "ratio": 3.0596930073905626, "config_test": fal...
__author__ = 'guru' #state 10 = recharge amount #state 20 = Ask's user to place their finger on FPS #state 30 = Scanning ur finger now #state 31 = account not found #state 40 = recharge successful #screen = 0 vendor,screen = 1 customer. import GLCD as g currentState = 0 fontWidth = 6 lineLength = 21 ...
{ "repo_name": "karthikeyan5/hexa", "path": "hexa-beta/rechargeScreen.py", "copies": "1", "size": "5372", "license": "mit", "hash": 900697511472219900, "line_mean": 31.575, "line_max": 67, "alpha_frac": 0.5925167535, "autogenerated": false, "ratio": 2.992757660167131, "config_test": false, "ha...
__author__ = 'Guy Hawkins' import urllib import urlparse import pickle import os import json from BeautifulSoup import BeautifulSoup from time import sleep, strftime, localtime from pyvirtualdisplay import Display from selenium import webdriver ############## ## Database ## ############## ''' A Pickle database to...
{ "repo_name": "GHawk1ns/Flipboard_AutoFlip", "path": "autoFlip/autoFlip.py", "copies": "1", "size": "13881", "license": "mit", "hash": 4793402676190638000, "line_mean": 34.053030303, "line_max": 361, "alpha_frac": 0.585188387, "autogenerated": false, "ratio": 4.1263376932223546, "config_test": ...
__author__ = 'Guy' def block_website(): import re website = raw_input("Please enter the base url of the website you would like to block: ") url_regex = r'[-a-zA-Z0-9@:%_\+.~#?&//=]{2,256}\.[a-z]{2,4}\b(\/[-a-zA-Z0-9@:%_\+.~#?&//=]*)?(\?([-a-zA-Z0-9@:%_\+.~#?&//=]+)|)' while not re.search(url_re...
{ "repo_name": "HackinGuy/proxparent", "path": "control.py", "copies": "1", "size": "2256", "license": "mit", "hash": 1881588902114704600, "line_mean": 39.7777777778, "line_max": 132, "alpha_frac": 0.5181737589, "autogenerated": false, "ratio": 3.8564102564102565, "config_test": false, "has_no...
__author__ = "Gyrodrill恋恋" langversion = 1 langname = "Chinese" ##updater # text construct: "Version "+version+available+changelog #example: Version 3 available, click here to download, or for changelog click here available = " 更新了,单击此处下载。" changelog = " 单击此处查看更新内容。" ##world gen worldify = "读取图片" planetoids = "小圆点" ...
{ "repo_name": "Berserker66/omnitool", "path": "omnitool/Language/chinese.py", "copies": "1", "size": "3233", "license": "mit", "hash": -2575618950381189000, "line_mean": 14.5095541401, "line_max": 83, "alpha_frac": 0.6229979466, "autogenerated": false, "ratio": 1.5114835505896957, "config_test"...
__author__ = 'hadhya' from abc import ABCMeta from string import Template import urllib2 import json import sleekxmpp import logging from copy import deepcopy from config import CONFIG # HTTP message standard header HTTPS_HEADER = { 'Content-Type': 'application/json', 'Authorization': Template('key=$api_key')...
{ "repo_name": "Hindol/python-gcm-server", "path": "gcm/__init__.py", "copies": "1", "size": "2363", "license": "mit", "hash": -6984282996597877000, "line_mean": 27.8170731707, "line_max": 115, "alpha_frac": 0.6432501058, "autogenerated": false, "ratio": 3.8112903225806454, "config_test": true, ...
__author__ = 'hadhya' from gcm import GcmClient from config import CONFIG from optparse import OptionParser import logging def start_xmpp_server(): client = GcmClient(CONFIG['GCM_API_KEY']) client.listen(CONFIG['GCM_SENDER_ID'], on_message) def on_message(message): print message if __name__ == '__main__...
{ "repo_name": "Hindol/python-gcm-server", "path": "serve.py", "copies": "1", "size": "1164", "license": "mit", "hash": -1440602402619433700, "line_mean": 31.3611111111, "line_max": 66, "alpha_frac": 0.6005154639, "autogenerated": false, "ratio": 3.9726962457337884, "config_test": false, "has_...
__author__ = 'had' # The MIT License (MIT) # Copyright (c) [2015] [Houtmann Hadrien] # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the Aidez-moi), to deal # in the Software without restriction, including without limitation the righ...
{ "repo_name": "hadmagic/Aidez-moi", "path": "ticket/views/home.py", "copies": "1", "size": "2583", "license": "mit", "hash": -6793701383850937000, "line_mean": 42.7966101695, "line_max": 80, "alpha_frac": 0.7015098722, "autogenerated": false, "ratio": 4.370558375634518, "config_test": false, ...
__author__ = 'HagRead-Only' from tkinter import * root = Tk() root.title("PlotterGraphicFont") cnv = Canvas(root, width=260, height=280) cnv.pack() cnv.create_text(75, 15, text="Enter real number or axis.") cnv.create_text(70, 35, text="Type 'exit' to close app.") line = Text(root, height=1, width=11, font="Calibri...
{ "repo_name": "Alexponomarev7/plotter", "path": "cgi-bin/lib/graph/PlotterGraphicFont.py", "copies": "1", "size": "3421", "license": "mit", "hash": -5467993128823254000, "line_mean": 23.2624113475, "line_max": 79, "alpha_frac": 0.4931306635, "autogenerated": false, "ratio": 2.156998738965952, "...
__author__ = 'haho0032' import base64 import datetime import dateutil.parser import pytz from OpenSSL import crypto from os.path import join from os import remove from Crypto.Util import asn1 class WrongInput(Exception): pass class CertificateError(Exception): pass class PayloadError(Exception): pass ...
{ "repo_name": "rohe/pysaml2-3", "path": "src/saml2/cert.py", "copies": "1", "size": "15164", "license": "bsd-2-clause", "hash": 2945293735093234000, "line_mean": 41.2395543175, "line_max": 80, "alpha_frac": 0.4843049327, "autogenerated": false, "ratio": 5.081769436997319, "config_test": false, ...
__author__ = 'haho0032' import base64 import datetime import dateutil.parser import pytz import six from OpenSSL import crypto from os.path import join from os import remove import saml2.cryptography.pki class WrongInput(Exception): pass class CertificateError(Exception): pass class PayloadError(Excepti...
{ "repo_name": "kawamon/hue", "path": "desktop/core/ext-py/pysaml2-4.9.0/src/saml2/cert.py", "copies": "2", "size": "15186", "license": "apache-2.0", "hash": -155556161336166430, "line_mean": 44.0623145401, "line_max": 98, "alpha_frac": 0.4770841565, "autogenerated": false, "ratio": 5.204249485949...
__author__ = 'haibo' #encoding:utf8 def cookie2scrapy(cookies): """ the function is used to covert the cookies that gotten from response using requests module to the style which can be used in scrapy. the style of original cookie: f=dwd;dsd=gdfg;g_d=1334 In scrapy,the cookie must ex...
{ "repo_name": "haipersist/webspider", "path": "utils/cookie2scrapy.py", "copies": "1", "size": "1709", "license": "mit", "hash": 1121762356194884600, "line_mean": 36.9777777778, "line_max": 141, "alpha_frac": 0.7290813341, "autogenerated": false, "ratio": 2.386871508379888, "config_test": false...
__author__ = 'Haim' import os import threading import importlib import inspect import IChatTask import event_aggregator import hermes.backend.dict import datetime last_clear_date = None cache = hermes.Hermes(hermes.backend.dict.Backend) @cache def get_last_clear_date(): return last_clear_date class PluginTask...
{ "repo_name": "haimroizman/chat", "path": "plugin_tasks_server.py", "copies": "1", "size": "2270", "license": "mit", "hash": -7331931696062261000, "line_mean": 36.8333333333, "line_max": 104, "alpha_frac": 0.5651982379, "autogenerated": false, "ratio": 4.274952919020715, "config_test": false, ...
__author__ = 'Haim' from socket import * import Queue import concurrent.futures from log_manager import LogManager import multiprocessing from threading import Thread from user_service import UserService max_conn_pool = multiprocessing.cpu_count() logger = LogManager("chatApp") class EventHandler: def fileno(s...
{ "repo_name": "haimroizman/chat", "path": "messages_producer_consumer.py", "copies": "1", "size": "6891", "license": "mit", "hash": 7405690167460652000, "line_mean": 34.8958333333, "line_max": 120, "alpha_frac": 0.6029603831, "autogenerated": false, "ratio": 4.104228707564026, "config_test": fa...
__author__ = 'Haim' import re from DB.chat_repository import ChatUserRepository, ChatMessageRepository from time import gmtime, strftime class UserService: def __init__(self, user_name, user_socket): self.user_name = user_name self.user_id = None self.chat_user_repository = ChatUserReposi...
{ "repo_name": "haimroizman/chat", "path": "user_service.py", "copies": "1", "size": "1738", "license": "mit", "hash": -6371183570558440000, "line_mean": 33.76, "line_max": 86, "alpha_frac": 0.6265822785, "autogenerated": false, "ratio": 3.4969818913480886, "config_test": false, "has_no_keywor...
__author__ = 'haitham' import sklearn class UDLModel(sklearn.base.BaseEstimator): # self.estimator =None # self.configs= {} def __init__(self): # a dictionary of all configurable parameters. This dictionary will be used in get_params. see the note in get_params function self.configs = {} ...
{ "repo_name": "marakeby/udl", "path": "udl/model.py", "copies": "1", "size": "1310", "license": "bsd-2-clause", "hash": -1978776956172742000, "line_mean": 33.4736842105, "line_max": 164, "alpha_frac": 0.6427480916, "autogenerated": false, "ratio": 4.1455696202531644, "config_test": false, "ha...
__author__ = 'haitham' import udl.caffei.models.caffe_pb2 as pb2 from udl.caffei.models.layers.layer import Layer, set class Filler(object): def __init__(self, type="constant", value=0, min=0, max=1, mean=0, std=1, sparse=-1): self._filler = pb2.FillerParameter() self.type = type self.valu...
{ "repo_name": "marakeby/udl", "path": "udl/caffei/models/layers/innerproduct_pb2.py", "copies": "1", "size": "3760", "license": "bsd-2-clause", "hash": 7808916365989383000, "line_mean": 26.2463768116, "line_max": 116, "alpha_frac": 0.6154255319, "autogenerated": false, "ratio": 3.424408014571949,...
__author__ = 'haitham' from udl.caffei.models.layers.layer import Layer, set import udl.caffei.models.caffe_pb2 as pb2 class LossType(): HINGE_LOSS = "HINGE_LOSS" CONTRASTIVE_LOSS = "CONTRASTIVE_LOSS" EUCLIDEAN_LOSS = "EUCLIDEAN_LOSS" MULTINOMIAL_LOGISTIC_LOSS = "MULTINOMIAL_LOGISTIC_LOSS" Softma...
{ "repo_name": "marakeby/udl", "path": "udl/caffei/models/layers/loss_layers.py", "copies": "1", "size": "2057", "license": "bsd-2-clause", "hash": 8739351396093571000, "line_mean": 24.3950617284, "line_max": 104, "alpha_frac": 0.6446280992, "autogenerated": false, "ratio": 3.3501628664495113, "...
__author__ = 'Hakim' """ Convert tsv file in format: gene_name_1,gene_name_2,sign to: gene_number_1,gene_number_2,sign Save the gene_name -> gene_id correspondence to file """ def convert_name_to_number(input_tsv,output_tsv,name_id): """ Convert tsv_file gene1_name,gene2_name,interaction to gene1_id,gen...
{ "repo_name": "rohanramanath/gene-regulatory-network", "path": "final_presentation/data_processing/convert_tsv_names_numbers.py", "copies": "1", "size": "1439", "license": "apache-2.0", "hash": -3969419051107107000, "line_mean": 29.6170212766, "line_max": 101, "alpha_frac": 0.575399583, "autogenera...
__author__ = 'halfcrazy' from PIL import Image import StringIO #------------------------------------------------------------------------------ # binaryzation def binary(data): data.seek(0) img = Image.open(data) pixdata = img.load() for y in xrange(img.size[1]): for x in xrange(img.size[0]):...
{ "repo_name": "halfcrazy/DecodeValidateCode", "path": "Recognize.py", "copies": "1", "size": "1714", "license": "mit", "hash": -709251530488092400, "line_mean": 26.6451612903, "line_max": 79, "alpha_frac": 0.4206534422, "autogenerated": false, "ratio": 3.7342047930283226, "config_test": false, ...
__author__ = 'halley' from chunk import * import scale as sc import harmony as hm import gencell as gc import pitchhelpers as pth import random def genHalfNotes(main_passage): half_notes = [] for cell in main_passage: if cell.chord == []: half_notes.append(Chunk(pits=[cell.pits[0]],durs=[2...
{ "repo_name": "caromedellin/tweets-sounds", "path": "accompaniment.py", "copies": "1", "size": "7112", "license": "mit", "hash": -7125273180602660000, "line_mean": 44.8903225806, "line_max": 132, "alpha_frac": 0.5109673791, "autogenerated": false, "ratio": 3.238615664845173, "config_test": fals...
__author__ = 'halley' from constants import * from chunk import * import copy import probabilityhelpers as ph def inChord(note, chord): if chord == []: return True if note == None: return True else: return (note % 7) in [i%7 for i in chord] #check if an entire chunk matches def ch...
{ "repo_name": "caromedellin/tweets-sounds", "path": "harmony.py", "copies": "1", "size": "5426", "license": "mit", "hash": 3186281305187231000, "line_mean": 34.2337662338, "line_max": 137, "alpha_frac": 0.6052340582, "autogenerated": false, "ratio": 2.963407973784817, "config_test": false, "h...
__author__ = 'halley' from inspect import getmembers, isfunction import celltransforms as ct import random import preferences as pref import harmony as hm import functionalhelpers as fh import gencell as gc import rhythmhelpers as rhy from chunk import * #the list of functions transform_cell_functions = dict([(o[0], ...
{ "repo_name": "caromedellin/tweets-sounds", "path": "transformcell.py", "copies": "1", "size": "2018", "license": "mit", "hash": -7468196621551227000, "line_mean": 52.1052631579, "line_max": 224, "alpha_frac": 0.6942517344, "autogenerated": false, "ratio": 3.4733218588640273, "config_test": fal...
__author__ = 'halley' from music21 import * import scale as sc import functionalhelpers as fh from constants import * def cellsToPart(cells, octave = 5): notes = [] for cell in cells: degrees = cell.pits pits = sc.degreesToNotes(degrees, octave = octave, scale = cell.scale) durs = cell...
{ "repo_name": "caromedellin/tweets-sounds", "path": "music21helpers.py", "copies": "1", "size": "1718", "license": "mit", "hash": 3137835133695274500, "line_mean": 27.1639344262, "line_max": 78, "alpha_frac": 0.5133876601, "autogenerated": false, "ratio": 3.5791666666666666, "config_test": fals...
__author__ = 'halley' import functionalhelpers as fh import harmony as hm #test if a single cell = good def goodCell(cell): if len(cell.durs) != len(cell.pits): return False if len(cell.durs) == 1: return True pits = cell.pits durs = cell.durs pit_diffs = [abs(pits[i] - pits[i - 1])...
{ "repo_name": "caromedellin/tweets-sounds", "path": "preferences.py", "copies": "1", "size": "4309", "license": "mit", "hash": -1035774368116931500, "line_mean": 37.4732142857, "line_max": 207, "alpha_frac": 0.5175214667, "autogenerated": false, "ratio": 2.673076923076923, "config_test": false,...
__author__ = 'halley' import probabilityhelpers as ph import random #for checking whether two numbers are roughly the same def almostEquals(x,y): if abs(x - y) < 0.001: return True return False def strToRhy(rstr): return [float(i) for i in rstr.split()] def rhyToStr(rhy): return ' '.join([str...
{ "repo_name": "caromedellin/tweets-sounds", "path": "rhythmhelpers.py", "copies": "1", "size": "4629", "license": "mit", "hash": -2257983832558361600, "line_mean": 37.575, "line_max": 194, "alpha_frac": 0.5331605098, "autogenerated": false, "ratio": 2.658816771970132, "config_test": false, "h...
__author__ = 'halley' import random import music21helpers as mh import transformcell as tf import gencell as gc import accompaniment as acc from music21 import * import copy import json import sys def getLoudness(loudness): if i < 0.1: return 'p' elif i < 0.25: return 'mp' elif i < 0.5: ...
{ "repo_name": "caromedellin/tweets-sounds", "path": "twitter.py", "copies": "1", "size": "2877", "license": "mit", "hash": 7926733083774239000, "line_mean": 29.9462365591, "line_max": 101, "alpha_frac": 0.6301703163, "autogenerated": false, "ratio": 2.5895589558955896, "config_test": false, "...
__author__ = 'halley' import scale as sc from chunk import * import gencell as gc import random def getFirstNotes(prev_cell, old_cell): ppit = prev_cell.pits[-1] if (ppit % 7) in (i % 7 for i in prev_cell.chord): return [ppit - 1, ppit + 1, ppit] else: if prev_cell.pits < 14 and random.unif...
{ "repo_name": "caromedellin/tweets-sounds", "path": "celltransforms.py", "copies": "1", "size": "7037", "license": "mit", "hash": 5636847742254536000, "line_mean": 37.4590163934, "line_max": 139, "alpha_frac": 0.5917294302, "autogenerated": false, "ratio": 2.8091816367265467, "config_test": fal...
import bcbp_func import sys import gc import probstat import random from utils import PriorityQueue from sets import Set def whole(n): return n == int(n) and n != 1 def groupnums(numpieces): r = [] numcoms = len(probstat.Combination(range(numpieces), 3)) numofeachletter = float(numcoms * 3) / numpiec...
{ "repo_name": "nicofarr/bcbp", "path": "bcbp.py", "copies": "1", "size": "6186", "license": "mit", "hash": -2767644668829683700, "line_mean": 34.1477272727, "line_max": 96, "alpha_frac": 0.5218234724, "autogenerated": false, "ratio": 3.823238566131026, "config_test": false, "has_no_keywords":...
import sys import gc import probstat import random from utils import PriorityQueue from sets import Set import numpy as np def triad_perms(triad): return [''.join(x) for x in probstat.Permutation([c for c in triad])] def group_distrib(group): distrib = [] for triad in group: for i in range(3): ...
{ "repo_name": "nicofarr/bcbp", "path": "bcbp_func.py", "copies": "1", "size": "4348", "license": "mit", "hash": 334380331708679000, "line_mean": 28.9862068966, "line_max": 96, "alpha_frac": 0.516099356, "autogenerated": false, "ratio": 3.611295681063123, "config_test": false, "has_no_keywords...
from __future__ import division import numpy as np import scipy.sparse as sp import array from sklearn.utils import check_random_state from ._random import sample_without_replacement from .deprecation import deprecated __all__ = ['sample_without_replacement', 'choice'] # This is a backport of np.random.choice from ...
{ "repo_name": "clemkoa/scikit-learn", "path": "sklearn/utils/random.py", "copies": "29", "size": "7445", "license": "bsd-3-clause", "hash": 8418767482602748000, "line_mean": 36.4120603015, "line_max": 79, "alpha_frac": 0.5974479516, "autogenerated": false, "ratio": 3.941238750661726, "config_te...
from __future__ import division import numpy as np import scipy.sparse as sp import operator import array from sklearn.utils import check_random_state from sklearn.utils.fixes import astype from ._random import sample_without_replacement __all__ = ['sample_without_replacement', 'choice'] # This is a backport of np....
{ "repo_name": "appapantula/scikit-learn", "path": "sklearn/utils/random.py", "copies": "234", "size": "10510", "license": "bsd-3-clause", "hash": -5137917352955574000, "line_mean": 35.4930555556, "line_max": 79, "alpha_frac": 0.5726926736, "autogenerated": false, "ratio": 3.952613764573148, "co...
from __future__ import division import numpy as np import scipy.sparse as sp import operator import array from sklearn.utils import check_random_state from ._random import sample_without_replacement __all__ = ['sample_without_replacement', 'choice'] # This is a backport of np.random.choice from numpy 1.7 # The fun...
{ "repo_name": "mblondel/scikit-learn", "path": "sklearn/utils/random.py", "copies": "19", "size": "10413", "license": "bsd-3-clause", "hash": 1769974513246895900, "line_mean": 35.2822299652, "line_max": 79, "alpha_frac": 0.5712090656, "autogenerated": false, "ratio": 3.9578107183580387, "config...
from __future__ import division import array import operator import numpy as np import scipy.sparse as sp from sklearn.utils import check_random_state from sklearn.utils.fixes import astype from ._random import sample_without_replacement __all__ = ['sample_without_replacement', 'choice'] # This is a backport of np...
{ "repo_name": "DailyActie/Surrogate-Model", "path": "01-codes/scikit-learn-master/sklearn/utils/random.py", "copies": "1", "size": "10512", "license": "mit", "hash": -3643198201720285000, "line_mean": 35.3737024221, "line_max": 79, "alpha_frac": 0.5726788432, "autogenerated": false, "ratio": 3.95...
import numpy as np import scipy.sparse as sp import array from . import check_random_state from ._random import sample_without_replacement __all__ = ['sample_without_replacement'] def _random_choice_csc(n_samples, classes, class_probability=None, random_state=None): """Generate a sparse r...
{ "repo_name": "bnaul/scikit-learn", "path": "sklearn/utils/random.py", "copies": "3", "size": "3827", "license": "bsd-3-clause", "hash": -2404099131155802000, "line_mean": 38.8645833333, "line_max": 79, "alpha_frac": 0.5516070029, "autogenerated": false, "ratio": 4.150759219088937, "config_test...
import numpy as np import scipy.sparse as sp import array from . import check_random_state from ._random import sample_without_replacement __all__ = ['sample_without_replacement'] def random_choice_csc(n_samples, classes, class_probability=None, random_state=None): """Generate a sparse ran...
{ "repo_name": "chrsrds/scikit-learn", "path": "sklearn/utils/random.py", "copies": "4", "size": "4004", "license": "bsd-3-clause", "hash": -9133626360367019000, "line_mean": 40.2783505155, "line_max": 79, "alpha_frac": 0.5619380619, "autogenerated": false, "ratio": 4.192670157068063, "config_te...
__author__ = 'HANEL' import os import glob import tensorflow as tf from PIL import Image import numpy as np import imageflow imageflow.read_images() ''' Simple library to read all PNG and JPG/JPEG images in a directory with TensorFlow buil-in functions to boost speed. Hamed MP Github: @hamedmp Twitter: @...
{ "repo_name": "HamedMP/ImageFlow", "path": "imageflow/playground.py", "copies": "1", "size": "4811", "license": "apache-2.0", "hash": 5536865671274447000, "line_mean": 23.6717948718, "line_max": 121, "alpha_frac": 0.6377052588, "autogenerated": false, "ratio": 2.922843256379101, "config_test": ...
__author__ = 'Hans Burbano<hburbano@bbox.co>' from datetime import datetime, timedelta import math import csv class GPXDProcessor(object): """docstring for GPXDProcessor""" # Index of START_LAT, START_LON, END_LAT, END_LON, START_TIME, END_TIME, DISTANCE, LAPSE, SPEED, ISIDDLE = [ 0, 1, 2, 3, 4, ...
{ "repo_name": "Nslaver/GPXIddleTime", "path": "GPXIddleTime/GPXDProcessor.py", "copies": "1", "size": "4603", "license": "mit", "hash": 3058019157687113700, "line_mean": 33.3507462687, "line_max": 133, "alpha_frac": 0.5174885944, "autogenerated": false, "ratio": 3.5030441400304415, "config_test...
__author__ = 'Hans Burbano<hburbano@bbox.co>' import xml.sax.saxutils import xml.sax class GPXLoader(xml.sax.handler.ContentHandler): """ This class loads in to memory the GPX [lat, lon, time] data generated from a Garmin GPS device, uses """ def __init__(self): super(GPXLoader, self)._...
{ "repo_name": "Nslaver/GPXIddleTime", "path": "GPXIddleTime/GPXLoader.py", "copies": "1", "size": "1358", "license": "mit", "hash": 8757623781875446000, "line_mean": 27.2916666667, "line_max": 73, "alpha_frac": 0.5618556701, "autogenerated": false, "ratio": 3.5736842105263156, "config_test": fa...
__author__ = 'Hans Burbano<hburbano@bbox.co>' #!/usr/bin/python """ This script gives basic tools to calculate iddle time on a GPX data file. Iddle time defined as the time in which the speed is below a determinated limit Tested with GPX from Garmin Astro 320 device. """ import xml.sax.saxutils import xml.sax import os...
{ "repo_name": "Nslaver/GPXIddleTime", "path": "test.py", "copies": "1", "size": "1395", "license": "mit", "hash": -7894880551847059000, "line_mean": 30, "line_max": 98, "alpha_frac": 0.6322580645, "autogenerated": false, "ratio": 3.3214285714285716, "config_test": false, "has_no_keywords": fa...