text
stringlengths
0
1.05M
meta
dict
#!/bin/env python """ Collection of GUI elements created by Pavlo Shchelokovskyy. This module cannot be used on it own. Provides following functions: rgba_wx2mplt - Convert wx.Colour to colour format used by matplotlib Provides following objects: OneParamFilePanel - simple panel for processing one file with one...
{ "repo_name": "pshchelo/vampy", "path": "wxgui/widgets.py", "copies": "1", "size": "11831", "license": "bsd-3-clause", "hash": 4744728747135631000, "line_mean": 32.2331460674, "line_max": 114, "alpha_frac": 0.5828754966, "autogenerated": false, "ratio": 3.9162528963919234, "config_test": false,...
#!/bin/env python # ColorImgSort # Sorts images based on color # by Ed Salisbury <ed@edsalisbury.net> # Written: 2013/12/24 import argparse import os import os.path import math from PIL import Image class ImgSort(): def __init__(self, **kwargs): """Class constructor - sets up the internal variables""" ...
{ "repo_name": "EdSalisbury/ColorImgSort", "path": "bin/colorimgsort.py", "copies": "1", "size": "7107", "license": "mit", "hash": 8242698501540074000, "line_mean": 32.3661971831, "line_max": 79, "alpha_frac": 0.5123118053, "autogenerated": false, "ratio": 4.038068181818182, "config_test": false...
#!/bin/env python # Command line script to get GB/day from manager, then save to google sheet. from som.api.google.sheets import Client from datetime import datetime, timedelta import subprocess import argparse import json import os import sys def get_parser(): parser = argparse.ArgumentParser( description="...
{ "repo_name": "pydicom/sendit", "path": "scripts/save_google_sheets.py", "copies": "1", "size": "3019", "license": "mit", "hash": 6287171366673321000, "line_mean": 28.3106796117, "line_max": 87, "alpha_frac": 0.5713812521, "autogenerated": false, "ratio": 3.865556978233035, "config_test": false...
# common qps statistics tool based on log __author__ = "unix1986@qq.com" import sys import platform # check python version if sys.version_info < (2, 7, 0): print ("Current python version %s, " "but require version %s or above") % \ (platform.python_version(), "2.7.0") sys.exit(1) import os i...
{ "repo_name": "unix1986/universe", "path": "script/qps.py", "copies": "1", "size": "2926", "license": "bsd-2-clause", "hash": -7476698761242815000, "line_mean": 29.8, "line_max": 99, "alpha_frac": 0.5758714969, "autogenerated": false, "ratio": 3.708491761723701, "config_test": false, "has_no_...
#/bin/env python # # compile and decompile Anyka/Chomptech firmware voice files # # (c) 2015 Ulrich Sibiller # use print a a function from __future__ import print_function import struct import mmap import argparse import sys import os def error(*objs): print("ERROR:", *objs, file=sys.stderr) def decompile(infi...
{ "repo_name": "entropia/tip-toi-reveng", "path": "voicetool/voicetool.py", "copies": "1", "size": "5182", "license": "mit", "hash": 6609529385660770000, "line_mean": 32.0063694268, "line_max": 149, "alpha_frac": 0.6215746816, "autogenerated": false, "ratio": 3.603616133518776, "config_test": fa...
#!/bin/env python """ Compute forces of the supercell system created by phonopy and create FORCE_SETS file, which includes forces on atoms. Usage: pmd2phonopy.py [options] PMDINI Options: -h, --help Show this help message and exit. -c, --cutoff=CUTOFF Cutoff radius of the interatomic pote...
{ "repo_name": "ryokbys/nap", "path": "nappy/pmd/pmd2phonopy.py", "copies": "1", "size": "4893", "license": "mit", "hash": -5679678827217339000, "line_mean": 30.1656050955, "line_max": 97, "alpha_frac": 0.5475168608, "autogenerated": false, "ratio": 2.804011461318052, "config_test": false, "ha...
#!/bin/env python ###################################################################### ''' COMPUTE_MASTER.py ========================= AIM: Cycle through the observability maps and execute stray light computations Temporal resolution is 60 seconds and orbit step size is given by the max. error INPUT: files: - obse...
{ "repo_name": "kuntzer/SALSA-public", "path": "1_compute_MASTER.py", "copies": "1", "size": "10206", "license": "bsd-3-clause", "hash": 7063881139960738000, "line_mean": 33.2483221477, "line_max": 140, "alpha_frac": 0.6496178718, "autogenerated": false, "ratio": 3.026690391459075, "config_test"...
#!/bin/env python #-------CONFIG-------- # Links to SVN will begin with this and end with path to repo. # You can find this url by navigating to your repo in a browser. # It may be helpful to create a validation branch instead of /head/ base_svn_url = "http://my-svn-repo.example.com/!/#RepoName/view/head/" # The URL ...
{ "repo_name": "JamaSoftware/Jama-SVN", "path": "jama-svn.py", "copies": "1", "size": "9202", "license": "mit", "hash": -274157682949095260, "line_mean": 39.1834061135, "line_max": 147, "alpha_frac": 0.6530102152, "autogenerated": false, "ratio": 3.4948727687048993, "config_test": false, "has_...
#!/bin/env python ''' Convert macOS keyboard layout files (.keylayout) to equivalent Windows files (.klc). ''' import os import re import sys import time import argparse import codecs import unicodedata import xml.etree.ElementTree as ET # local modules from data.klc_data import ( win_to_mac_keycodes, win_keyco...
{ "repo_name": "adobe-type-tools/keyboard-layouts", "path": "mac2winKeyboard.py", "copies": "1", "size": "24585", "license": "mit", "hash": -7522754512102678000, "line_mean": 33.4754558205, "line_max": 79, "alpha_frac": 0.554452626, "autogenerated": false, "ratio": 3.836584985172468, "config_tes...
#!/bin/env python """ Convert the given tab-delimited document into a VCF 4.1 document for annotation with Seattle Seq. """ import argparse import csv from fastahack import FastaHack import vcf from vcf.model import _Record TEMPLATE_VCF_FILE = "template-4.1.vcf" VCF_TO_FIELDS = ( ("#CHROM", "Chrom"), ("POS", ...
{ "repo_name": "huddlej/tab-to-vcf", "path": "tab_to_vcf.py", "copies": "1", "size": "4736", "license": "mit", "hash": 7440208426663567000, "line_mean": 37.1935483871, "line_max": 104, "alpha_frac": 0.5487753378, "autogenerated": false, "ratio": 3.3708185053380784, "config_test": false, "has_n...
# Copyright 2006 Stephen Duncan Jr # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writi...
{ "repo_name": "jrduncans/highcard", "path": "python/highcard.py", "copies": "1", "size": "1532", "license": "mit", "hash": 9065112468022161000, "line_mean": 22.5846153846, "line_max": 74, "alpha_frac": 0.6886422977, "autogenerated": false, "ratio": 3.3232104121475055, "config_test": false, "h...
""" Copyright 2010-2018 University Of Southern California Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to...
{ "repo_name": "SCECcode/BBP", "path": "bbp/comps/exsim.py", "copies": "1", "size": "21062", "license": "apache-2.0", "hash": 6948768163690833000, "line_mean": 43.1551362683, "line_max": 83, "alpha_frac": 0.5108251828, "autogenerated": false, "ratio": 3.786767349874146, "config_test": true, "h...
""" Copyright 2010-2019 University Of Southern California Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to...
{ "repo_name": "SCECcode/BBP", "path": "bbp/tests/gen_accept_tests.py", "copies": "1", "size": "12083", "license": "apache-2.0", "hash": 7584901641881103000, "line_mean": 36.4086687307, "line_max": 116, "alpha_frac": 0.5273524787, "autogenerated": false, "ratio": 3.7925298179535467, "config_test...
from errors import DataError from pool import ConnectionPools from cursor import Cursor from bson.son import SON from functools import partial class Client(object): """ Client connection to represent a remote database. Internally Client maintains a pool of connections that will live beyond the life o...
{ "repo_name": "bitly/asyncmongo", "path": "asyncmongo/client.py", "copies": "3", "size": "6619", "license": "apache-2.0", "hash": 3563276041818022000, "line_mean": 40.8924050633, "line_max": 116, "alpha_frac": 0.6210907992, "autogenerated": false, "ratio": 4.546016483516484, "config_test": fals...
from gi.repository import GObject class Glib3Stream(object): def __init__(self, socket, **kwargs): self.__socket = socket self.__close_id = None self.__read_id = None self.__read_queue = [] def write(self, data): self.__socket.send(data) def read(self, size, c...
{ "repo_name": "bitly/asyncmongo", "path": "asyncmongo/backends/glib3_backend.py", "copies": "3", "size": "2617", "license": "apache-2.0", "hash": 2586446405135929000, "line_mean": 29.7882352941, "line_max": 77, "alpha_frac": 0.5865494841, "autogenerated": false, "ratio": 3.9711684370257965, "co...
from threading import Condition import logging from errors import TooManyConnections, ProgrammingError from connection import Connection class ConnectionPools(object): """ singleton to keep track of named connection pools """ @classmethod def get_connection_pool(self, pool_id, *args, **kwargs): "...
{ "repo_name": "bitly/asyncmongo", "path": "asyncmongo/pool.py", "copies": "3", "size": "6509", "license": "apache-2.0", "hash": 3889270529190549000, "line_mean": 38.2108433735, "line_max": 139, "alpha_frac": 0.5951759103, "autogenerated": false, "ratio": 4.583802816901408, "config_test": false,...
import glib class Glib2Stream(object): def __init__(self, socket, **kwargs): self.__socket = socket self.__close_id = None self.__read_id = None self.__read_queue = [] def write(self, data): self.__socket.send(data) def read(self, size, callback): self...
{ "repo_name": "quakig/asyncmongo", "path": "asyncmongo/backends/glib2_backend.py", "copies": "3", "size": "2561", "license": "apache-2.0", "hash": 8018746467243457000, "line_mean": 29.1294117647, "line_max": 75, "alpha_frac": 0.5814135103, "autogenerated": false, "ratio": 3.8627450980392157, "c...
import logging from bson.son import SON import helpers import message import functools _QUERY_OPTIONS = { "tailable_cursor": 2, "slave_okay": 4, "oplog_replay": 8, "no_timeout": 16} class Cursor(object): """ Cursor is a class used to call oeprations on a given db/collection using a specific con...
{ "repo_name": "RealGeeks/asyncmongo", "path": "asyncmongo/cursor.py", "copies": "1", "size": "18720", "license": "apache-2.0", "hash": 709119962396632400, "line_mean": 40.0526315789, "line_max": 108, "alpha_frac": 0.572542735, "autogenerated": false, "ratio": 4.56140350877193, "config_test": tr...
import sys import socket import struct import logging from types import NoneType import functools from errors import ProgrammingError, IntegrityError, InterfaceError import helpers import asyncjobs class Connection(object): """ :Parameters: - `host`: hostname or ip of mongo host (not allowed when repl...
{ "repo_name": "quakig/asyncmongo", "path": "asyncmongo/connection.py", "copies": "3", "size": "9690", "license": "apache-2.0", "hash": 8471795443656535000, "line_mean": 36.8515625, "line_max": 121, "alpha_frac": 0.5772961816, "autogenerated": false, "ratio": 4.424657534246576, "config_test": fa...
import tornado.iostream class TornadoStream(object): def __init__(self, socket, **kwargs): """ :Parameters: - `socket`: TCP socket - `**kwargs`: passed to `tornado.iostream.IOStream` - `io_loop` (optional): Tornado IOLoop instance. - `max_buffer_size` (o...
{ "repo_name": "quakig/asyncmongo", "path": "asyncmongo/backends/tornado_backend.py", "copies": "3", "size": "2033", "license": "apache-2.0", "hash": -4988585324523647000, "line_mean": 32.3278688525, "line_max": 75, "alpha_frac": 0.6153467782, "autogenerated": false, "ratio": 3.9862745098039216, ...
""" AsyncMongo is an asynchronous library for accessing mongo http://github.com/bitly/asyncmongo """ try: import bson except ImportError: raise ImportError("bson library not installed. Install pymongo >= 1.9 https://github.com/mongodb/mongo-python-driver") # also update in setup.py version = "1.3" version_in...
{ "repo_name": "bitly/asyncmongo", "path": "asyncmongo/__init__.py", "copies": "2", "size": "1295", "license": "apache-2.0", "hash": -3507756684677352400, "line_mean": 31.375, "line_max": 122, "alpha_frac": 0.7413127413, "autogenerated": false, "ratio": 3.877245508982036, "config_test": false, ...
""" Created by Dan Frank on 2012-01-23. Copyright (c) 2012 bit.ly. All rights reserved. """ import sys assert sys.version_info >= (2, 7), "run this with python2.7" import simplejson as json from tornado.httpclient import HTTPRequest from tornado.httpclient import AsyncHTTPClient from tornado.ioloop import IOLoop impor...
{ "repo_name": "bitly/asyncdynamo", "path": "asyncdynamo/asyncdynamo.py", "copies": "1", "size": "17863", "license": "apache-2.0", "hash": 7334313306274478000, "line_mean": 45.6396866841, "line_max": 140, "alpha_frac": 0.630689134, "autogenerated": false, "ratio": 4.554563997960225, "config_test...
""" Created by Dan Frank on 2012-01-25. Copyright (c) 2012 bit.ly. All rights reserved. """ import functools from tornado.httpclient import HTTPRequest from tornado.httpclient import AsyncHTTPClient import xml.sax import boto from boto.sts.connection import STSConnection from boto.sts.credentials import Credentials f...
{ "repo_name": "0359xiaodong/viewfinder", "path": "backend/db/async_aws_sts.py", "copies": "13", "size": "4387", "license": "apache-2.0", "hash": 243707774335367740, "line_mean": 40, "line_max": 108, "alpha_frac": 0.6931844085, "autogenerated": false, "ratio": 4.032169117647059, "config_test": f...
""" This script updates the expected read depths of the input files for the Combined Haplotype Test. GC content biases and peakiness of the data (potentially caused by differences in ChIP efficiency or the expression of a few highly expressed genes) can vary greatly between individuals, sequencing libraries, and la...
{ "repo_name": "cdeboever3/WASP", "path": "CHT/update_total_depth.py", "copies": "1", "size": "11963", "license": "apache-2.0", "hash": 369453518178627000, "line_mean": 30.2349869452, "line_max": 117, "alpha_frac": 0.5404998746, "autogenerated": false, "ratio": 3.6273499090357793, "config_test":...
""" usage: update_total_depth.py input_file_list output_directory positional arguments: input_file_list name of the .txt file containing a list of files for input out_directory directory to output the updated files optional arguments: None This script is used to update the expected read depths o...
{ "repo_name": "PrincetonUniversity/WASP", "path": "CHT/update_total_depth.py", "copies": "1", "size": "10603", "license": "apache-2.0", "hash": 5975129530142270000, "line_mean": 35.1877133106, "line_max": 162, "alpha_frac": 0.5962463454, "autogenerated": false, "ratio": 3.316546762589928, "conf...
""" This program reads BAM files and counts the number of reads that match the alternate and reference allele at every SNP position in the provided SNP HDF5 data files. The read counts are stored in specified HDF5 output files. Additionally counts of all reads are stored in another track (at the left-most position of ...
{ "repo_name": "smozaffari/WASP", "path": "CHT/bam2h5.py", "copies": "1", "size": "25026", "license": "apache-2.0", "hash": -3937580985195634700, "line_mean": 34.8025751073, "line_max": 84, "alpha_frac": 0.5653720131, "autogenerated": false, "ratio": 3.7975720789074354, "config_test": false, "...
""" usage: import_bam_ref_nonref_counts.py [-h] [--assembly ASSEMBLY] [--snp_index_track SNP_INDEX_TRACK] [--snp_track SNP_TRACK] [--data_type {uint8,uint16}] [--ha...
{ "repo_name": "PrincetonUniversity/WASP", "path": "CHT/import_bam_ref_nonref_counts.py", "copies": "2", "size": "23722", "license": "apache-2.0", "hash": -6888522526849937000, "line_mean": 35.8354037267, "line_max": 88, "alpha_frac": 0.5509231937, "autogenerated": false, "ratio": 3.89459858808077...
"""Tools for creating `messages <http://www.mongodb.org/display/DOCS/Mongo+Wire+Protocol>`_ to be sent to MongoDB. .. note:: This module is for internal use and is generally not needed by application developers. """ import logging import random from bson import SON import message import helpers from errors impor...
{ "repo_name": "quakig/asyncmongo", "path": "asyncmongo/asyncjobs.py", "copies": "3", "size": "8618", "license": "apache-2.0", "hash": 3056566800768587300, "line_mean": 35.2100840336, "line_max": 119, "alpha_frac": 0.5323741007, "autogenerated": false, "ratio": 4.500261096605744, "config_test": ...
import argparse import numpy as np import sys import gzip import re import tables import chromosome import chromstat import coord import util SNP_UNDEF = -1 HAP_UNDEF = -1 class SNP(object): def __init__(self, chrom, pos, name, ref_allele, alt_allele): self.chrom = chrom self.pos = pos ...
{ "repo_name": "bmvdgeijn/WASP", "path": "CHT/extract_haplotype_read_counts.py", "copies": "2", "size": "22584", "license": "apache-2.0", "hash": -2196453217003797500, "line_mean": 35.3671497585, "line_max": 83, "alpha_frac": 0.5190843075, "autogenerated": false, "ratio": 3.843430905377808, "con...
import argparse import numpy as np import sys import gzip import tables import chromosome import chromstat import coord SNP_UNDEF = -1 HAP_UNDEF = -1 class SNP(object): def __init__(self, chrom, pos, name, ref_allele, alt_allele): self.chrom = chrom self.pos = pos self.name = name ...
{ "repo_name": "cdeboever3/WASP", "path": "CHT/extract_haplotype_read_counts.py", "copies": "1", "size": "21724", "license": "apache-2.0", "hash": 7719290764948390000, "line_mean": 35.2066666667, "line_max": 83, "alpha_frac": 0.5224176027, "autogenerated": false, "ratio": 3.8307176864750483, "co...
""" usage: extract_haplotype_read_counts.py [-h] [--assembly ASSEMBLY] [--target_region_size TARGET_REGION_SIZE] [--sample_file SAMPLE_FILE] [--homozygous_as_counts {zero,rand_hap,rand_allele}] ...
{ "repo_name": "gmcvicker/CHT", "path": "extract_haplotype_read_counts.py", "copies": "1", "size": "20257", "license": "apache-2.0", "hash": -995744447529148800, "line_mean": 33.8657487091, "line_max": 93, "alpha_frac": 0.5454410821, "autogenerated": false, "ratio": 3.6764065335753178, "config_t...
# Copyright 2013 Zynga Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to ...
{ "repo_name": "zbase/disk_mapper", "path": "dm_server/lib/flock.py", "copies": "1", "size": "3353", "license": "apache-2.0", "hash": 5300404385664783000, "line_mean": 31.8725490196, "line_max": 76, "alpha_frac": 0.5407098121, "autogenerated": false, "ratio": 4.079075425790754, "config_test": fa...
# $Build: OONP_H_R01_6$ # $Date: 05/06/2014 12:10:39$ # $Author: vapoonat$ # # import logging import os import sys import importlib import thread import threading import time from neutron.api.v2 import attributes from neutron.db import db_base_plugin_v2 from neutron.openstack.common import context #from neutron.o...
{ "repo_name": "Alcatel-LucentEnterpriseData/ALUe-OONP_H_R01", "path": "omniswitch/omniswitch_device_plugin.py", "copies": "1", "size": "25251", "license": "apache-2.0", "hash": -4967026871615442000, "line_mean": 43.0680628272, "line_max": 126, "alpha_frac": 0.588095521, "autogenerated": false, "r...
# $Build: OONP_H_R01_6$ # $Date: 05/06/2014 12:10:39$ # $Author: vapoonat$ # # import inspect import logging import os import sys import importlib from neutron.agent import securitygroups_rpc as sg_rpc from neutron.api.rpc.agentnotifiers import dhcp_rpc_agent_api from neutron.api.rpc.agentnotifiers import l3_rpc_...
{ "repo_name": "Alcatel-LucentEnterpriseData/ALUe-OONP_H_R01", "path": "omniswitch/omniswitch_network_plugin.py", "copies": "1", "size": "27140", "license": "apache-2.0", "hash": 3150799072500194000, "line_mean": 40.8827160494, "line_max": 126, "alpha_frac": 0.5806190125, "autogenerated": false, "...
# $Build: OONP_H_R01_6$ # $Date: 05/06/2014 12:10:39$ # $Author: vapoonat$ # # import logging from sqlalchemy.orm import exc from neutron.common import exceptions as q_exc from neutron.db import securitygroups_db as sg_db from neutron.extensions import securitygroup as ext_sg from neutron import manager from neu...
{ "repo_name": "Alcatel-LucentEnterpriseData/ALUe-OONP_H_R01", "path": "omniswitch/omniswitch_neutron_dbutils.py", "copies": "1", "size": "2674", "license": "apache-2.0", "hash": 9044317341636266000, "line_mean": 30.0930232558, "line_max": 100, "alpha_frac": 0.6761406133, "autogenerated": false, "...
# $Build: OONP_H_R01_6$ # $Date: 05/06/2014 12:10:39$ # $Author: vapoonat$ # # import logging import os import sys import importlib import traceback import urllib import urllib2 import time import thread import threading from neutron.plugins.omniswitch.consumer import AOSAPI, AOSConnection #from neutron.plugins....
{ "repo_name": "Alcatel-LucentEnterpriseData/ALUe-OONP_H_R01", "path": "omniswitch/omniswitch_restful_driver.py", "copies": "1", "size": "23098", "license": "apache-2.0", "hash": -6183768275189318000, "line_mean": 36.1948470209, "line_max": 117, "alpha_frac": 0.5599619015, "autogenerated": false, ...
# $Build: OONP_H_R01_6$ # $Date: 05/06/2014 12:10:39$ # $Author: vapoonat$ # # import logging import os import sys import traceback import telnetlib import time import re import thread import threading from neutron.plugins.omniswitch import omniswitch_constants as omni_const LOG = logging.getLogger(__name__) c...
{ "repo_name": "Alcatel-LucentEnterpriseData/ALUe-OONP_H_R01", "path": "omniswitch/omniswitch_telnet_driver.py", "copies": "1", "size": "13351", "license": "apache-2.0", "hash": -7785931653876283000, "line_mean": 36.0861111111, "line_max": 119, "alpha_frac": 0.5920904801, "autogenerated": false, "...
from __future__ import print_function import importlib #import pprint #from collections import Counter from collections import deque def moduleExists(moduleName): try: importlib.import_module(moduleName) except ImportError: return False else: return True consoleExists = moduleExists('console') ...
{ "repo_name": "kellymccauley/cavea-rules", "path": "bin/cavea_lp_progressions.py", "copies": "1", "size": "4634", "license": "apache-2.0", "hash": 4275046399202570000, "line_mean": 22.2864321608, "line_max": 83, "alpha_frac": 0.5640914976, "autogenerated": false, "ratio": 2.8238878732480197, "c...
from __future__ import print_function import importlib def moduleExists(moduleName): try: importlib.import_module(moduleName) except ImportError: return False else: return True consoleExists = moduleExists('console') if consoleExists: import console dieTypeDmg = (8, 4, 2, 1) def main()...
{ "repo_name": "kellymccauley/cavea-rules", "path": "bin/cavea_dmg_calc.py", "copies": "1", "size": "1410", "license": "apache-2.0", "hash": -6634687852275554000, "line_mean": 20.0447761194, "line_max": 74, "alpha_frac": 0.6035460993, "autogenerated": false, "ratio": 3.1125827814569536, "config_...
# Copyright 2015, Abel Lopez # All rights reserved # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by a...
{ "repo_name": "chrisplo/gleek", "path": "gleek.py", "copies": "2", "size": "7425", "license": "apache-2.0", "hash": -7097125786515799000, "line_mean": 35.9402985075, "line_max": 78, "alpha_frac": 0.5573063973, "autogenerated": false, "ratio": 4.221148379761228, "config_test": false, "has_no_k...
# Copyright 2015 Red Hat Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writin...
{ "repo_name": "joelsmith/openshift-tools", "path": "openshift_tools/reporting/zabbixplot.py", "copies": "13", "size": "13451", "license": "apache-2.0", "hash": 4201776017730459600, "line_mean": 45.7048611111, "line_max": 120, "alpha_frac": 0.6093227269, "autogenerated": false, "ratio": 3.95385067...
import os import restfuzz.health tracebacks_blacklist = set(( "IpAddressGenerationFailure: No more IP addresses available on network", "HTTPBadRequest: Cannot update read-only", "HTTPBadRequest: Unrecognized attribute(s)", "HTTPBadRequest: Unable to find", "HTTPForbidden: Tenant", "Invalid in...
{ "repo_name": "redhat-cip/restfuzz", "path": "tools/health_localhost.py", "copies": "1", "size": "2662", "license": "apache-2.0", "hash": 6028890136272695000, "line_mean": 33.5714285714, "line_max": 76, "alpha_frac": 0.5507137491, "autogenerated": false, "ratio": 3.914705882352941, "config_test...
""" Utility to generate Fermat headers and icons from SVG files """ import argparse import os import shutil import sys def create_headers_dirs(): os.makedirs('../high', exist_ok=True) os.makedirs('../medium', exist_ok=True) os.makedirs('../small', exist_ok=True) os.makedirs('../svg', exist_ok=True) ...
{ "repo_name": "simonorono/pyutils", "path": "fermat.py", "copies": "1", "size": "2648", "license": "apache-2.0", "hash": 6977704868728653000, "line_mean": 34.28, "line_max": 77, "alpha_frac": 0.6326530612, "autogenerated": false, "ratio": 3.375, "config_test": false, "has_no_keywords": false,...
""" Utility to rename files as a secuence of numbers with trailing zeros """ import argparse import os from random import shuffle def get_files(path): """Non-hidden files without directories""" file_list = [x for x in os.listdir(path) if not os.path.isdir(os.path.join(path, x)) and ...
{ "repo_name": "simonorono/pyutils", "path": "dirfix.py", "copies": "1", "size": "2811", "license": "apache-2.0", "hash": -5117099772039800000, "line_mean": 30.2111111111, "line_max": 82, "alpha_frac": 0.6116055536, "autogenerated": false, "ratio": 3.643320363164721, "config_test": false, "has...
# Copyright 2019 Arm Limited. # SPDX-License-Identifier: Apache-2.0 # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by ...
{ "repo_name": "ARM-software/bob-build", "path": "tests/implicit_outs/generate.py", "copies": "1", "size": "1573", "license": "apache-2.0", "hash": 7897699883625013000, "line_mean": 22.4776119403, "line_max": 74, "alpha_frac": 0.6630642085, "autogenerated": false, "ratio": 3.519015659955257, "co...
"""Manage shelves of pickled objects using bsddb database files for the storage. """ #------------------------------------------------------------------------ import cPickle import sys import sys absolute_import = (sys.version_info[0] >= 3) if absolute_import : # Because this syntaxis is not valid before Python...
{ "repo_name": "DecipherOne/Troglodyte", "path": "Trog Build Dependencies/Python26/Lib/bsddb/dbshelve.py", "copies": "1", "size": "10778", "license": "mit", "hash": -160505897045347840, "line_mean": 28.8559556787, "line_max": 110, "alpha_frac": 0.5435145667, "autogenerated": false, "ratio": 3.7950...
"""Manage shelves of pickled objects using bsddb database files for the storage. """ #------------------------------------------------------------------------ import cPickle try: from UserDict import DictMixin except ImportError: # DictMixin is new in Python 2.3 class DictMixin: pass try: # For Pytho...
{ "repo_name": "MalloyPower/parsing-python", "path": "front-end/testsuite-python-lib/Python-2.3/Lib/bsddb/dbshelve.py", "copies": "1", "size": "8793", "license": "mit", "hash": 6581846836921082000, "line_mean": 28.5067114094, "line_max": 101, "alpha_frac": 0.534061185, "autogenerated": false, "rat...
import os, sys, string, socket, errno from cStringIO import StringIO import cgi #--------------------------------------------------------------------------- # Set various FastCGI constants # Maximum number of requests that can be handled FCGI_MAX_REQS=1 FCGI_MAX_CONNS = 1 # Supported version of the FastCGI ...
{ "repo_name": "brayden2544/Mystuff-final", "path": "setup/fcgi.py", "copies": "1", "size": "14930", "license": "apache-2.0", "hash": -661565210181688600, "line_mean": 33.0091116173, "line_max": 91, "alpha_frac": 0.4791694575, "autogenerated": false, "ratio": 3.8096453176830822, "config_test": t...
# Copyright (c) 2001-2009 Rincon Research Corporation, Richard T. Saunders # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyri...
{ "repo_name": "henrysher/imagefactory", "path": "imgfac/picklingtools/xmldumper.py", "copies": "4", "size": "30755", "license": "apache-2.0", "hash": 4582395243585403400, "line_mean": 39.897606383, "line_max": 137, "alpha_frac": 0.6055925866, "autogenerated": false, "ratio": 3.7446730792645804, ...
import oml4py import time import math omlInst = oml4py.OMLBase("oml4PySimpleExample", "foo", "n1") omlInst.addmp("SinMP", "label:string angle:int32 value:double") omlInst.addmp("CosMP", "label:string value:double") omlInst.start() for i in range(5): time.sleep(0.5) angle = 15 * i omlInst.inject("SinMP",...
{ "repo_name": "mytestbed/oml4py", "path": "oml4py-simple-example.py", "copies": "1", "size": "1692", "license": "mit", "hash": -4689507396885699000, "line_mean": 35, "line_max": 79, "alpha_frac": 0.7405437352, "autogenerated": false, "ratio": 3.562105263157895, "config_test": false, "has_no_k...
import os, re, sys, peakparser, discordant, argparse, annotate class insertionSummary: def __init__(self): self.chr = '' self.start = '' self.end = '' self.strand = '' self.eltStart = '' self.eltEnd = '' self.eltFam = '' self.eltC...
{ "repo_name": "adamewing/discord-retro", "path": "lib/summarize.py", "copies": "1", "size": "7470", "license": "mit", "hash": 1324335911542686200, "line_mean": 37.90625, "line_max": 129, "alpha_frac": 0.5694779116, "autogenerated": false, "ratio": 3.6385776911836336, "config_test": true, "has...
import os, sys, glob JAVA_LICENSE = """\ /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * Copyright (c) 2012, Robin Jarry, ABlogiX. All rights reserved. * * * * This file is part of APIWATCH and published under the B...
{ "repo_name": "robin-jarry/apiwatch", "path": "check_licenses.py", "copies": "1", "size": "3872", "license": "bsd-2-clause", "hash": 1188230994421003500, "line_mean": 38.1111111111, "line_max": 78, "alpha_frac": 0.3695764463, "autogenerated": false, "ratio": 3.78494623655914, "config_test": fal...
''' Copyright (c) 2013 Potential Ventures Ltd Copyright (c) 2013 SolarFlare Communications Inc All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above ...
{ "repo_name": "stuarthodgson/cocotb", "path": "cocotb/drivers/__init__.py", "copies": "3", "size": "11380", "license": "bsd-3-clause", "hash": 5076118427944545000, "line_mean": 32.2748538012, "line_max": 79, "alpha_frac": 0.6061511424, "autogenerated": false, "ratio": 4.622258326563769, "config...
#Unless required by applicable law or agreed to in writing, software #distributed under the License is distributed on an "AS IS" BASIS, #WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #See the License for the specific language governing permissions and #limitations under the License. #*******...
{ "repo_name": "arashb/tbslas", "path": "scripts/vis_comp_advdiff.py", "copies": "1", "size": "1956", "license": "bsd-3-clause", "hash": -8549322518049284000, "line_mean": 39.75, "line_max": 84, "alpha_frac": 0.486196319, "autogenerated": false, "ratio": 4.356347438752784, "config_test": false, ...
""" Copyright (c) 2015 David Becvarik All rights reserved. This software may be modified and distributed under the terms of the BSD license. See the LICENSE file for details. """ import argparse import logging import sys from csk.container import Container from csk import setup_logging, version logger = logging.getL...
{ "repo_name": "containers-tools/container-swiss-knife", "path": "csk/cli/main.py", "copies": "2", "size": "2428", "license": "mit", "hash": 8896232807068855000, "line_mean": 31.3733333333, "line_max": 109, "alpha_frac": 0.6523887974, "autogenerated": false, "ratio": 3.93517017828201, "config_te...
# Copyright (c) 2015. Qubole Inc # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in...
{ "repo_name": "qubole/quboletsdb", "path": "qdstsdb/command_line.py", "copies": "1", "size": "2599", "license": "apache-2.0", "hash": 2701396384382624300, "line_mean": 29.9404761905, "line_max": 91, "alpha_frac": 0.6706425548, "autogenerated": false, "ratio": 3.85037037037037, "config_test": tr...
""" Happy Slot Machine This software is a python slot machine that cheats on the users. The numbers selection function is designed so it is very unlikely to get three identical numbers and increases the chances for the two firsts numbers to be the same. """ from collections import Counter from random import randint ...
{ "repo_name": "breard-r/happy_slot_machine", "path": "happy_slot_machine.py", "copies": "1", "size": "5402", "license": "isc", "hash": -4457193855025634000, "line_mean": 24.7238095238, "line_max": 76, "alpha_frac": 0.6306923362, "autogenerated": false, "ratio": 3.467265725288832, "config_test":...
# Copyright (c) 2016-present, Facebook, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agree...
{ "repo_name": "Yangqing/caffe2", "path": "caffe2/contrib/aten/gen_op.py", "copies": "2", "size": "10069", "license": "apache-2.0", "hash": 1085691763903032200, "line_mean": 35.7481751825, "line_max": 108, "alpha_frac": 0.5871486741, "autogenerated": false, "ratio": 3.793896006028636, "config_te...
from __future__ import print_function from __future__ import with_statement import subprocess import imp import os import sys import socket import re protocol = imp.load_source('protocol', '../protocol.py') nxDSCLog = imp.load_source('nxDSCLog', '../nxDSCLog.py') LG = nxDSCLog.DSCLog # [ClassVersion("1.0.0"), Friendl...
{ "repo_name": "MSFTOSSMgmt/WPSDSCLinux", "path": "Providers/Scripts/2.6x-2.7x/Scripts/nxFirewall.py", "copies": "2", "size": "28370", "license": "mit", "hash": -2429146672503430000, "line_mean": 39.878962536, "line_max": 290, "alpha_frac": 0.5762072612, "autogenerated": false, "ratio": 3.76709600...
import subprocess import imp import os import sys import socket import re from functools import reduce protocol = imp.load_source('protocol', '../protocol.py') nxDSCLog = imp.load_source('nxDSCLog', '../nxDSCLog.py') LG = nxDSCLog.DSCLog # [ClassVersion("1.0.0"), FriendlyName("nxFirewallResource")] # class MSFT_nxFir...
{ "repo_name": "MSFTOSSMgmt/WPSDSCLinux", "path": "Providers/Scripts/3.x/Scripts/nxFirewall.py", "copies": "2", "size": "28061", "license": "mit", "hash": -1947552659108030500, "line_mean": 39.3755395683, "line_max": 290, "alpha_frac": 0.5755675136, "autogenerated": false, "ratio": 3.7736686390532...
import subprocess import imp import os import sys import socket import re protocol = imp.load_source('protocol', '../protocol.py') nxDSCLog = imp.load_source('nxDSCLog', '../nxDSCLog.py') LG = nxDSCLog.DSCLog # [ClassVersion("1.0.0"), FriendlyName("nxFirewallResource")] # class MSFT_nxFirewallResource:OMI_BaseResourc...
{ "repo_name": "MSFTOSSMgmt/WPSDSCLinux", "path": "Providers/Scripts/2.4x-2.5x/Scripts/nxFirewall.py", "copies": "2", "size": "28388", "license": "mit", "hash": -5917735707757026000, "line_mean": 39.670487106, "line_max": 290, "alpha_frac": 0.5749612512, "autogenerated": false, "ratio": 3.76099629...
__copyright__ = """Copyright 2014 Adobe Systems Incorporated (http://www.adobe.com/). All Rights Reserved. """ __doc__ = """ kernCheck performs several (lengthy) checks on the GPOS table kern feature in an OpenType font. It first looks for glyph pairs that collide/overlap. It uses the 'tx' tool to rasterize glyphs a...
{ "repo_name": "shannpersand/cooper-type", "path": "_resources/FDK Adobe/Tools/SharedData/FDKScripts/kernCheck.py", "copies": "1", "size": "67788", "license": "cc0-1.0", "hash": 4329192162524047000, "line_mean": 33.0301204819, "line_max": 246, "alpha_frac": 0.6568714227, "autogenerated": false, "r...
__copyright__ = """Copyright 2015 Adobe Systems Incorporated (http://www.adobe.com/). All Rights Reserved. """ __doc__ = """ """ __usage__ = """ makeInstancesUFO program v1.2 Oct 7 2015 makeInstancesUFO -h makeInstancesUFO -u makeInstancesUFO [-d <design space file name>] [-a] [-c] [-n] [-dec] [-i 0,1,..n...
{ "repo_name": "shannpersand/cooper-type", "path": "_resources/FDK Adobe/Tools/SharedData/FDKScripts/makeInstancesUFO.py", "copies": "1", "size": "13032", "license": "cc0-1.0", "hash": -6498861482056044000, "line_mean": 28.2853932584, "line_max": 120, "alpha_frac": 0.7031921424, "autogenerated": fal...
__copyright__ = """Copyright 2016 Adobe Systems Incorporated (http://www.adobe.com/). All Rights Reserved. """ __doc__ = """ """ __usage__ = """ makeInstances program v1.33 April 12 2016 makeInstances -h makeInstances -u makeInstances [-a] [-f <instance file path>] [-m <MM font path>] [-...
{ "repo_name": "shannpersand/cooper-type", "path": "_resources/FDK Adobe/Tools/SharedData/FDKScripts/makeInstances.py", "copies": "1", "size": "54379", "license": "cc0-1.0", "hash": -4001447417870822400, "line_mean": 31.4650746269, "line_max": 179, "alpha_frac": 0.683830155, "autogenerated": false, ...
__copyright__ = """Copyright 2017 Adobe Systems Incorporated (http://www.adobe.com/). All Rights Reserved. """ __doc__ = """ kernCheck performs several (lengthy) checks on the GPOS table kern feature in an OpenType font. It first looks for glyph pairs that collide/overlap. It uses the 'tx' tool to rasterize glyphs a...
{ "repo_name": "adobe-type-tools/python-scripts", "path": "vintage/kernCheck.py", "copies": "1", "size": "67471", "license": "mit", "hash": 2687615735377442300, "line_mean": 32.9050251256, "line_max": 246, "alpha_frac": 0.6604022469, "autogenerated": false, "ratio": 3.0032493545802548, "config_t...
__copyright__ = """Copyright 2017 Adobe Systems Incorporated (http://www.adobe.com/). All Rights Reserved. """ __doc__ = """ """ __usage__ = """ makeinstances program v1.34 makeinstances -h makeinstances -u makeinstances [-a] [-f <instance file path>] [-m <MM font path>] [-o <instance par...
{ "repo_name": "adobe-type-tools/python-scripts", "path": "vintage/makeinstances.py", "copies": "1", "size": "54207", "license": "mit", "hash": 1880907888443735300, "line_mean": 31.2852888624, "line_max": 179, "alpha_frac": 0.6871621746, "autogenerated": false, "ratio": 3.043627175743964, "confi...
__copyright__ = """ Copyright 2015-2016 Adobe Systems Incorporated (http://www.adobe.com/). All Rights Reserved. This software is licensed as OpenSource, under the Apache License, Version 2.0. This license is available at: http://opensource.org/licenses/Apache-2.0. */ """ __doc__ = """ v 2.0 Apr 11 2016 Copies the ...
{ "repo_name": "shannpersand/cooper-type", "path": "_resources/FDK Adobe/Tools/FontLabMacros/installFontLabMacros.py", "copies": "2", "size": "2979", "license": "cc0-1.0", "hash": -5922754338313671000, "line_mean": 29.0909090909, "line_max": 155, "alpha_frac": 0.714333669, "autogenerated": false, ...
#!/bin/env python """ Create a whitelist for HGAP assembly based on vector screening blacklist. Based on code from: https://github.com/PacificBiosciences/Bioinformatics-Training/wiki/HGAP-Whitelisting-Tutorial """ import argparse import csv import h5py import os import re def get_hole_number_by_file(input_filename)...
{ "repo_name": "EichlerLab/pacbio-protocols", "path": "smrtanalysis-2.3.0/whitelist.py", "copies": "2", "size": "2971", "license": "mit", "hash": -34673337240525580, "line_mean": 35.2317073171, "line_max": 131, "alpha_frac": 0.6637495793, "autogenerated": false, "ratio": 3.4870892018779345, "con...
''' Created on Oct 28, 2012 @author: Shunping Huang ''' import csv import gc import argparse as ap import gzip import logging from time import localtime,strftime import dbutils as dbu from modtools.variants import parseVariant, INS, DEL from modtools.utils import readableFile, writableFile, validChromList from modto...
{ "repo_name": "andrewparkermorgan/lapels", "path": "modtools/db/db2mod.py", "copies": "1", "size": "5369", "license": "mit", "hash": 2480432795274336000, "line_mean": 34.0980392157, "line_max": 92, "alpha_frac": 0.4959955299, "autogenerated": false, "ratio": 3.930453879941435, "config_test": fa...
#!/bin/env python # # Create RPMs, move to dist area, regenerate repos. # Should be run from the svn checkout root. # User must have GPG keys and .rpmmacros for signing. # Platform must be specified. import subprocess import sys import logging import os import re import shutil PKGNAME="autopyfactory" REPOROOT...
{ "repo_name": "PanDAWMS/autopyfactory", "path": "misc/publish-rpms.py", "copies": "2", "size": "5020", "license": "apache-2.0", "hash": 3503455831696666000, "line_mean": 33.1496598639, "line_max": 113, "alpha_frac": 0.5141434263, "autogenerated": false, "ratio": 3.86748844375963, "config_test":...
#!/bin/env python """ dbview -- view an SQL DB thru RDF glasses. *** NOTE WELL *** As of May 2006, active development has moved to http://dig.csail.mit.edu/2006/dbview/dbview.py an implementation of... [SWDB] Relational Databases on the Semantic Web Id: RDB-RDF.html,v 1.17 2002/03/06 20:43:13 timbl http:/...
{ "repo_name": "vdimarco/Open-Data-Linker", "path": "ETL/rdb2rdf_http.py", "copies": "1", "size": "25742", "license": "apache-2.0", "hash": 4590000671532910000, "line_mean": 29.2136150235, "line_max": 499, "alpha_frac": 0.5568331909, "autogenerated": false, "ratio": 3.4281528832068187, "config_t...
#!/bin/env python """ Demonstrate gathering of interface stats and generation of plot """ import sys import time import snmp_helper import pygal def delta(intList): retList = [] for i in range(len(intList)-1): retList.append(intList[i+1]-intList[i]) return retList def addNone(alist, nmod): r...
{ "repo_name": "patrebert/pynet_cert", "path": "class3/ex2.py", "copies": "1", "size": "2903", "license": "apache-2.0", "hash": 4022673667167350300, "line_mean": 28.3232323232, "line_max": 86, "alpha_frac": 0.5725111953, "autogenerated": false, "ratio": 2.653564899451554, "config_test": false, ...
""" distances.py Functions for determining distances and overlaps: - closestDistanceToRegion: distance from a reference position to a coordinate or region - regions_overlap: determine if two regions have any overlap - GetNearestTranscriptToPeak: compare two transcripts agai...
{ "repo_name": "fls-bioinformatics-core/RnaChipIntegrator", "path": "rnachipintegrator/distances.py", "copies": "1", "size": "11560", "license": "artistic-2.0", "hash": -3563042945840763400, "line_mean": 32.3141210375, "line_max": 77, "alpha_frac": 0.6023356401, "autogenerated": false, "ratio": 4....
#!/bin/env python __doc__ = """ ConvertFontToCID.py. v 1.9 April 16 2016 Convert a Type 1 font to CID, given multiple hint dict defs in the "fontinfo" file. See AC.py help, with the "-hfd" option, or the MakeOTF user guide for details on this format. The output file produced by convertFontToCID() is a CID Type 1 font...
{ "repo_name": "shannpersand/cooper-type", "path": "_resources/FDK Adobe/Tools/SharedData/FDKScripts/ConvertFontToCID.py", "copies": "1", "size": "30370", "license": "cc0-1.0", "hash": -6484969093381529000, "line_mean": 32.7069922309, "line_max": 219, "alpha_frac": 0.6751070135, "autogenerated": fal...
#! /bin/env python #docs: #https://developers.google.com/transit/gtfs/examples/gtfs-feed #agency #agency_id, agency_name,agency_url,agency_timezone,agency_phone,agency_lang files = {} files["agency.txt"] = { "fields":['agency_id', 'agency_name','agency_url','agency_timezone','agency_phone','agency_lang'], "data":...
{ "repo_name": "sirmmo/TPER2GTFS", "path": "transform.py", "copies": "1", "size": "7947", "license": "apache-2.0", "hash": 2592642132867604500, "line_mean": 29.6833976834, "line_max": 156, "alpha_frac": 0.6276582358, "autogenerated": false, "ratio": 2.523658304223563, "config_test": false, "ha...
""" Download and pre-process the POS-tagged corpora that we will use. """ __author__ = 'rtownsend' import nltk import logging from argparse import ArgumentParser from tag import Tag import cPickle as pickle from util import download_file TWEEBO_OCT27_DL = "https://raw.githubusercontent.com/brendano/ark-tweet-nlp/mast...
{ "repo_name": "Sentimentron/Dracula", "path": "corpus.py", "copies": "1", "size": "5743", "license": "bsd-3-clause", "hash": 9038564811412729000, "line_mean": 26.3476190476, "line_max": 122, "alpha_frac": 0.4570781821, "autogenerated": false, "ratio": 3.49330900243309, "config_test": false, "...
# dtools: simple tools for manipulating and plotting data # # Copyright (c) 2011 Erik Erlandson # # Author: Erik Erlandson <erikerlandson@yahoo.com> # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the Lic...
{ "repo_name": "erikerlandson/dtools", "path": "bin/dtools.py", "copies": "1", "size": "4886", "license": "apache-2.0", "hash": 2413333617716583000, "line_mean": 26.7613636364, "line_max": 92, "alpha_frac": 0.5221039705, "autogenerated": false, "ratio": 2.984728161270617, "config_test": false, ...
#!/bin/env python """ Ensemble verification ===================== In this tutorial we perform a verification of a probabilistic extrapolation nowcast using MeteoSwiss radar data. """ from datetime import datetime import matplotlib.pyplot as plt import numpy as np from pprint import pprint from pysteps import io, no...
{ "repo_name": "pySTEPS/pysteps", "path": "examples/plot_ensemble_verification.py", "copies": "1", "size": "5819", "license": "bsd-3-clause", "hash": 3486388316642182700, "line_mean": 29.4659685864, "line_max": 86, "alpha_frac": 0.6312081114, "autogenerated": false, "ratio": 3.394982497082847, "...
#! /bin/env python """ Examples -------- Create a grid that consists of 2x3 nodes using 'xy' and 'ij' indexing. **ij-indexing** Create a grid of length 2 in the i direction, and 3 in the j direction. >>> g = UniformRectilinear ((2,3), (1,2), (.5, 0), indexing='ij', units=('m', 'km')) >>> g.get_x() array([ 0., 2., ...
{ "repo_name": "csdms/coupling", "path": "pymt/grids/raster.py", "copies": "2", "size": "4208", "license": "mit", "hash": 9085774348568679000, "line_mean": 27.2416107383, "line_max": 94, "alpha_frac": 0.5627376426, "autogenerated": false, "ratio": 2.8184862692565305, "config_test": false, "has...
#! /bin/env python """ Examples ======== Point-to-point Mapping ---------------------- >>> import numpy as np >>> from pymt.grids.map import RectilinearMap as Rectilinear >>> src = Rectilinear([0, 1, 2], [0, 2]) >>> dst = Rectilinear([.5, 1.5, 2.5], [.25, 1.25]) >>> src.get_x() array([ 0., 2., 0., 2., 0., 2.])...
{ "repo_name": "csdms/coupling", "path": "pymt/mappers/mapper.py", "copies": "2", "size": "4485", "license": "mit", "hash": -6161093386491784000, "line_mean": 25.0755813953, "line_max": 78, "alpha_frac": 0.5656633222, "autogenerated": false, "ratio": 2.6228070175438596, "config_test": false, "...
#! /bin/env python """ Examples ======== **Rectilinear** Create a rectilinear grid that is 2x3:: (0) --- (1) --- (2) | | | | | | | [0] | [1] | | | | | | | (3) --- (4) --- (5) Numbers in parens are node IDs, and numbers in square br...
{ "repo_name": "csdms/pymt", "path": "pymt/grids/map.py", "copies": "1", "size": "3707", "license": "mit", "hash": 4867117481051057000, "line_mean": 23.0714285714, "line_max": 84, "alpha_frac": 0.5338548692, "autogenerated": false, "ratio": 3.3669391462306995, "config_test": false, "has_no_key...
#!/bin/env python # # Example worker exec # # Usage: exp_worker_exec.py # # zlmb-worker -e tcp://127.0.0.1:5560 -c exp_worker_exec.py import sys import os import datetime # Init zlmb zlmb_frame = '' zlmb_frame_length = '' zlmb_length = '' zlmb_buffer = '' # Read STDIN (Get zlmb buffer) if sys.stdin.isatty() == False...
{ "repo_name": "kjdev/zlmb", "path": "src/exp_worker_exec.py", "copies": "1", "size": "1094", "license": "mit", "hash": -6612127428534998000, "line_mean": 21.3265306122, "line_max": 94, "alpha_frac": 0.6352833638, "autogenerated": false, "ratio": 2.497716894977169, "config_test": false, "has_n...
#!/bin/env python """ExtractCurvatures Create a training file from a csv database -d file.csv specifies the file -m (optional) mrn to process -o features.csv specifies the output file """ import sys import getopt import csv import os def process(db, mrn, study, series): if os.getenv("CTC_IMG_DIR") == None: ...
{ "repo_name": "clwyatt/CTC", "path": "Scripts/ExtractCurvatures.py", "copies": "1", "size": "2594", "license": "bsd-3-clause", "hash": -4581206440794761000, "line_mean": 25.4693877551, "line_max": 86, "alpha_frac": 0.4710871241, "autogenerated": false, "ratio": 3.190651906519065, "config_test":...
#!/bin/env python # # extract python code from <pre><code> block # from test.test_support import captured_stdout, captured_output, \ captured_stderr, captured_stdin import StringIO import sys import code import os.path import pytmlargs import hashlib from bs4 import BeautifulSoup import matplotlib matplot...
{ "repo_name": "barryrowlingson/pytml", "path": "pytml/extract_python.py", "copies": "1", "size": "8256", "license": "mit", "hash": -4641508865971829000, "line_mean": 28.6978417266, "line_max": 96, "alpha_frac": 0.5529312016, "autogenerated": false, "ratio": 3.9692307692307693, "config_test": fa...
#!/bin/env python # extracts information about omim inheritance modes from genemap2.txt import re from os.path import expanduser home = expanduser('~') inheritance = {} inheritance['Autosomal recessive']='AR' inheritance['Autosomal dominant'] = 'AD' inheritance['X-linked recessive'] = 'XLR' inheritance['X-linked do...
{ "repo_name": "naumenko-sa/cre", "path": "cre.omim.inheritance.py", "copies": "1", "size": "1353", "license": "mit", "hash": -175713666094144670, "line_mean": 24.0555555556, "line_max": 69, "alpha_frac": 0.674796748, "autogenerated": false, "ratio": 2.8484210526315787, "config_test": false, "...
#!/bin/env python """ Extrapolation nowcast ===================== This tutorial shows how to compute and plot an extrapolation nowcast using Finnish radar data. """ from datetime import datetime import matplotlib.pyplot as plt import numpy as np from pprint import pprint from pysteps import io, motion, nowcasts, rc...
{ "repo_name": "pySTEPS/pysteps", "path": "examples/plot_extrapolation_nowcast.py", "copies": "1", "size": "4378", "license": "bsd-3-clause", "hash": -3282765638188289500, "line_mean": 30.4964028777, "line_max": 86, "alpha_frac": 0.647099132, "autogenerated": false, "ratio": 3.3496557000765113, ...
#!/bin/env python # file color_cube_actor.py from textwrap import dedent from OpenGL.GL import * # @UnusedWildImport # this comment squelches an IDE warning from OpenGL.GL.shaders import compileShader, compileProgram from openvr.glframework import shader_string """ Color cube for use in "hello world" openvr apps ...
{ "repo_name": "cmbruns/pyopenvr", "path": "src/openvr/color_cube_actor.py", "copies": "1", "size": "3734", "license": "bsd-3-clause", "hash": 4252871402448756000, "line_mean": 30.9145299145, "line_max": 94, "alpha_frac": 0.459828602, "autogenerated": false, "ratio": 3.3102836879432624, "config_...
#!/bin/env python # file glfwapp.py from OpenGL.GL import * # @UnusedWildImport # this comment squelches an IDE warning from OpenGL.GLUT import * # @UnusedWildImport """ Toy glut application for use with "hello world" examples demonstrating pyopenvr """ class GlutApp(object): "GlutApp uses freeglut library to...
{ "repo_name": "cmbruns/pyopenvr", "path": "src/openvr/glframework/glut_app.py", "copies": "1", "size": "2508", "license": "bsd-3-clause", "hash": -5936293657740628000, "line_mean": 32, "line_max": 104, "alpha_frac": 0.6275917065, "autogenerated": false, "ratio": 3.8883720930232557, "config_test...
#!/bin/env python # file glfwapp.py import glfw from OpenGL.GL import glFlush """ Toy glfw application for use with "hello world" examples demonstrating pyopenvr """ class GlfwBaseApp(object): "Base version renders to desktop" def __init__(self, renderer, title="GlfwBaseApp"): "Creates an OpenGL ...
{ "repo_name": "cmbruns/pyopenvr", "path": "src/openvr/glframework/glfw_app.py", "copies": "1", "size": "3577", "license": "bsd-3-clause", "hash": 7486152900773194000, "line_mean": 33.3942307692, "line_max": 124, "alpha_frac": 0.640201286, "autogenerated": false, "ratio": 3.7377220480668756, "co...
#!/bin/env python # file hello_glfw.py import numpy import time import collections from numpy.linalg import inv, norm import itertools from textwrap import dedent from ctypes import cast, c_float, c_void_p, sizeof from OpenGL.GL import * # @UnusedWildImport # this comment squelches an IDE warning # from OpenGL.GL i...
{ "repo_name": "cmbruns/pyopenvr", "path": "src/samples/objmesh/test_obj.py", "copies": "1", "size": "32542", "license": "bsd-3-clause", "hash": -2843378174841196000, "line_mean": 39.0270602706, "line_max": 182, "alpha_frac": 0.4829451171, "autogenerated": false, "ratio": 3.7655635269613517, "co...
#!/bin/env python # file hello_wx.py import sys import wx from wx import glcanvas """ Minimal wxPython programming example which colored OpenGL cube scene that can be closed by pressing ESCAPE. """ class WxApp(wx.App): "HelloApp uses wxPython library to create an opengl context, listen to keyboard events, and cl...
{ "repo_name": "cmbruns/pyopenvr", "path": "src/openvr/glframework/wx_app.py", "copies": "1", "size": "3308", "license": "bsd-3-clause", "hash": 7989269919437959000, "line_mean": 26.3388429752, "line_max": 107, "alpha_frac": 0.6955864571, "autogenerated": false, "ratio": 3.097378277153558, "conf...
#!/bin/env python # file openvr_gl_renderer.py from OpenGL.GL import * # @UnusedWildImport # this comment squelches an IDE warning import numpy import openvr """ Renders OpenGL scenes to virtual reality headsets using OpenVR API """ # TODO: matrixForOpenVrMatrix() is not general, it is specific the perspective a...
{ "repo_name": "cmbruns/pyopenvr", "path": "src/openvr/gl_renderer.py", "copies": "1", "size": "10253", "license": "bsd-3-clause", "hash": 2415012723644777500, "line_mean": 45.3936651584, "line_max": 125, "alpha_frac": 0.6224519653, "autogenerated": false, "ratio": 3.3116925064599485, "config_te...
#!/bin/env python # file qt_pyside_app.py import sys from PyQt5.QtCore import Qt, QTimer from PyQt5.QtWidgets import QApplication, QMainWindow from PyQt5.QtOpenGL import QGLWidget, QGLFormat """ Toy PySide application for use with "hello world" examples demonstrating pyopenvr """ class MyGlWidget(QGLWidget): ...
{ "repo_name": "cmbruns/pyopenvr", "path": "src/openvr/glframework/qt5_app.py", "copies": "1", "size": "3157", "license": "bsd-3-clause", "hash": 7611893353986233000, "line_mean": 29.6504854369, "line_max": 100, "alpha_frac": 0.628444726, "autogenerated": false, "ratio": 3.776315789473684, "conf...
#!/bin/env python # file qt_pyside_app.py import sys from PySide2.QtCore import Qt, QTimer from PySide2.QtWidgets import QApplication, QMainWindow from PySide2.QtOpenGL import QGLWidget, QGLFormat """ Toy PySide application for use with "hello world" examples demonstrating pyopenvr """ class MyGlWidget(QGLWidget)...
{ "repo_name": "cmbruns/pyopenvr", "path": "src/openvr/glframework/qt_pyside_app.py", "copies": "1", "size": "3174", "license": "bsd-3-clause", "hash": 7662947890497135000, "line_mean": 29.8155339806, "line_max": 100, "alpha_frac": 0.6301197227, "autogenerated": false, "ratio": 3.7695961995249405,...
#!/bin/env python # file sdl_app.py import ctypes from OpenGL.GL import glFlush # @UnusedWildImport # this comment squelches an IDE warning from sdl2 import * # @UnusedWildImport """ Minimal sdl programming example which colored OpenGL cube scene that can be closed by pressing ESCAPE. """ class SdlAppQuit(Except...
{ "repo_name": "cmbruns/pyopenvr", "path": "src/openvr/glframework/sdl_app.py", "copies": "1", "size": "3794", "license": "bsd-3-clause", "hash": -5781614870791065000, "line_mean": 29.5967741935, "line_max": 102, "alpha_frac": 0.7034791776, "autogenerated": false, "ratio": 3.01829753381066, "con...
#!/bin/env python # file tracked_devices_actor.py import time from ctypes import cast, c_float, c_void_p, sizeof import numpy from OpenGL import GL from OpenGL.GL.shaders import compileShader, compileProgram from OpenGL.arrays import vbo from OpenGL.GL.EXT.texture_filter_anisotropic import GL_TEXTURE_MAX_ANISOTROPY_...
{ "repo_name": "cmbruns/pyopenvr", "path": "src/openvr/tracked_devices_actor.py", "copies": "1", "size": "9469", "license": "bsd-3-clause", "hash": 3587258364616792000, "line_mean": 41.2723214286, "line_max": 122, "alpha_frac": 0.6121026508, "autogenerated": false, "ratio": 3.563793752352277, "c...
#!/bin/env python """FilterFeatures filter a csv feature training file for features within a distance threshold to polyp -i specifies the file (default: features.csv) -o specifies the output file (default: filtered.csv) -t specifies the threshold """ import sys import getopt import csv import string def main(): ...
{ "repo_name": "clwyatt/CTC", "path": "Scripts/FilterFeatures.py", "copies": "1", "size": "1261", "license": "bsd-3-clause", "hash": -9139111535018446000, "line_mean": 22.7924528302, "line_max": 84, "alpha_frac": 0.5495638382, "autogenerated": false, "ratio": 3.7867867867867866, "config_test": f...
#! /bin/env python # # Finalize un-finalized biobank orders with an input file that gives finalized times # import argparse import csv import logging import sys from rdr_service.dao import database_factory from rdr_service.model.biobank_order import BiobankOrder, BiobankOrderHistory, BiobankOrderedSampleHistory from ...
{ "repo_name": "all-of-us/raw-data-repository", "path": "rdr_service/tools/tool_libs/finalize_orders.py", "copies": "1", "size": "6030", "license": "bsd-3-clause", "hash": 1165521412716833500, "line_mean": 43.3382352941, "line_max": 118, "alpha_frac": 0.6484245439, "autogenerated": false, "ratio":...
#! /bin/env python # # Find COPE survey response counts and breakdowns for each question # import json from rdr_service import config from rdr_service.tools.tool_libs.tool_base import cli_run, ToolBase # Tool_cmd and tool_desc name are required. # Remember to add/update bash completion in 'tool_lib/tools.bash' tool_...
{ "repo_name": "all-of-us/raw-data-repository", "path": "rdr_service/tools/tool_libs/cope_answers.py", "copies": "1", "size": "3779", "license": "bsd-3-clause", "hash": 2175280388233202400, "line_mean": 39.2021276596, "line_max": 117, "alpha_frac": 0.6448795978, "autogenerated": false, "ratio": 3....
#!/bin/env python """ For a given BED file of SUNs with the base change in the name column (e.g., "A>G") and the unique id of each mismatch in the score column, calculate the total number of each mismatch type including transitions, transversions, insertions, and deletions. """ from argparse import ArgumentParser from ...
{ "repo_name": "huddlej/suns", "path": "parse_mismatch_types.py", "copies": "1", "size": "1795", "license": "mit", "hash": 6012694088117234000, "line_mean": 32.2407407407, "line_max": 143, "alpha_frac": 0.6573816156, "autogenerated": false, "ratio": 3.81104033970276, "config_test": false, "has...