repo_name stringlengths 6 90 | path stringlengths 4 230 | copies stringlengths 1 4 | size stringlengths 4 7 | content stringlengths 734 985k | license stringclasses 15
values | hash int64 -9,223,303,126,770,100,000 9,223,233,360B | line_mean float64 3.79 99.6 | line_max int64 19 999 | alpha_frac float64 0.25 0.96 | autogenerated bool 1
class | ratio float64 1.5 8.06 | config_test bool 2
classes | has_no_keywords bool 2
classes | few_assignments bool 1
class |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
charlesvardeman/smartcontainers | sc/orcidprofilesearch.py | 3 | 2342 | """CLI program that allows the user to input keywords for a basic search of the
Orcid API. It uses the OrcidManager class to find the Orcid ID and data.
"""
from requests import RequestException
import orcid
import click
def orcid_search(sandbox):
"""Get the Orcid_id from the email search
Parameters
... | apache-2.0 | -9,133,415,471,882,415,000 | 31.985915 | 114 | 0.598634 | false | 4.08726 | false | false | false |
robocomp/robocomp | tools/robocompdsl/dsl_parsers/specific_parsers/smdsl_parser.py | 1 | 8778 | import copy
from pyparsing import CaselessKeyword, Suppress, Word, CaselessLiteral, alphas, alphanums, delimitedList, Group, \
OneOrMore, ZeroOrMore, Optional, cppStyleComment
from dsl_parsers.dsl_parser_abstract import DSLParserTemplate
# noinspection PyTypeChecker
class SMDSLParser(DSLParserTemplate):
def... | gpl-3.0 | -5,634,253,108,647,869,000 | 48.59322 | 128 | 0.52529 | false | 4.942568 | false | false | false |
icchy/tracecorn | unitracer/lib/windows/i386/shell32.py | 1 | 7867 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
# Copyright (c) 2009-2014, Mario Vilas
# 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 ... | mit | 6,405,478,079,188,939,000 | 35.461905 | 79 | 0.553197 | false | 3.427887 | false | false | false |
dallingham/regenerate | mk_regs/verilog_reg_def.py | 2 | 31916 | REG = {
"ro1s": """module %(MODULE)s_ro1s_reg
#(
parameter WIDTH = 1,
parameter [WIDTH-1:0] RVAL = {(WIDTH){1'b0}}
)
(
input CLK, // Clock
input RSTn, // Reset
input BE, // Byte Enable
input ... | gpl-2.0 | 2,025,582,359,272,983,300 | 26.232082 | 66 | 0.411173 | false | 3.410193 | false | true | false |
ddico/odoo | addons/account/tests/test_account_payment_register.py | 1 | 17824 | # -*- coding: utf-8 -*-
from odoo.addons.account.tests.common import AccountTestInvoicingCommon
from odoo.exceptions import UserError
from odoo.tests import tagged
@tagged('post_install', '-at_install')
class TestAccountPaymentRegister(AccountTestInvoicingCommon):
@classmethod
def setUpClass(cls, chart_templ... | agpl-3.0 | 1,382,560,109,590,884,900 | 41.037736 | 155 | 0.514699 | false | 3.875625 | true | false | false |
davy39/eric | Helpviewer/Ui_PageScreenDialog.py | 1 | 2557 | # -*- coding: utf-8 -*-
# Form implementation generated from reading ui file './Helpviewer/PageScreenDialog.ui'
#
# Created: Tue Nov 18 17:53:58 2014
# by: PyQt5 UI code generator 5.3.2
#
# WARNING! All changes made in this file will be lost!
from PyQt5 import QtCore, QtGui, QtWidgets
class Ui_PageScreenDialog(... | gpl-3.0 | -5,925,011,663,252,194,000 | 50.14 | 108 | 0.753618 | false | 4.13754 | false | false | false |
pombredanne/django-lb-attachments | attachments/models.py | 2 | 2691 | from time import time
from random import randint
import os
from django.db import models
from django.contrib.auth.models import User
from django.utils.translation import ugettext_lazy as _
from django.conf import settings
try:
AUTH_USER_MODEL = settings.AUTH_USER_MODEL
except:
AUTH_USER_MODEL = U... | bsd-3-clause | -8,966,570,553,115,880,000 | 29.290698 | 82 | 0.610554 | false | 3.472258 | false | false | false |
gyurisc/stackjobs | create_technology_data.py | 1 | 1842 | import pandas as pd
import numpy as np
import matplotlib.pyplot as plt
import time
jobs = pd.read_csv('data/stackoverflow_jobs_enhanced.csv', thousands=',')
# filtering out most important columns
tmp = jobs.loc[:,['jobid', 'city', 'state', 'country', 'tags', 'weeknum', 'salary', 'salary_low', 'salary_high', 'curren... | mit | -5,328,618,629,239,851,000 | 33.773585 | 135 | 0.619978 | false | 3.095798 | false | false | false |
COMBINE-lab/matryoshka_work | coredomains-import/python-src/CoreDomain.py | 1 | 10083 | import random
import math
import collections
import itertools
from collections import namedtuple
import numpy as np
from bx.intervals.intersection import IntervalTree
from bx.intervals.intersection import Interval as bxInterval
chroms_human = map(str, range(1, 23))
chroms_mouse = map(str, range(1, 20))
Domain = colle... | gpl-3.0 | -1,182,266,901,554,415,400 | 27.563739 | 86 | 0.560547 | false | 2.937937 | false | false | false |
kidscancode/gamedev | tutorials/1-2 sprite example.py | 1 | 1654 | # Pygame sprite Example
import pygame
import random
WIDTH = 800
HEIGHT = 600
FPS = 30
# define colors
WHITE = (255, 255, 255)
BLACK = (0, 0, 0)
RED = (255, 0, 0)
GREEN = (0, 255, 0)
BLUE = (0, 0, 255)
class Player(pygame.sprite.Sprite):
# sprite for the Player
def __init__(self):
# this line is requi... | mit | 3,698,172,895,298,531,300 | 24.446154 | 68 | 0.639661 | false | 3.587852 | false | false | false |
cgchemlab/chemlab | examples/hyperbranched/analyze_structure.py | 1 | 4257 | #! /usr/bin/env python
#
# Copyright (c) 2016 Jakub Krajniak <jkrajniak@gmail.com>
#
# Distributed under terms of the GNU GPLv3 license.
#
import argparse
import h5py
import numpy as np
import networkx as nx
parser = argparse.ArgumentParser('Analyze structures in hyperbranched network')
parser.add_argument('h5', help... | gpl-3.0 | -8,167,391,295,657,461,000 | 32 | 109 | 0.537468 | false | 2.713193 | false | false | false |
ptaq666/Mechatronika_2015-16_Proj_TN | Piatkowski/Update 3 _05.06.2016_program w pythonie.py | 1 | 2554 | from picamera.array import PiRGBArray
from picamera import PiCamera
import time
import cv2
import numpy as np
import cPickle as pickle
import sys
#import RPi.GPIO as GPIO
#GPIO.setmode(GPIO.BOARD) #uzycie numeracji pinow wg raspberry
def blob_coordinates(keypoints):
i = 0
temp_array = []
for point in key... | gpl-3.0 | -1,478,517,686,082,684,700 | 25.604167 | 122 | 0.659358 | false | 2.987135 | false | false | false |
sternoru/django-dynamic-settings | dynamicsettings/app_settings.py | 1 | 1535 | # -*- coding: utf-8 -*-
from django.conf import settings
#include which settings should be included for dynamicsettings
#a list or tuple of settings modules represented as string
"""Example:
``DYNAMICSETTINGS_INCLUDE_MODULES = ['myapp.app_settings', 'some_globals']``
*Notes*:
- ``myapp.app_settings`` should be an ... | mit | 904,964,396,154,437,400 | 35.547619 | 106 | 0.757655 | false | 3.925831 | false | false | false |
adamgreig/agg-kicad | scripts/build_mod_picoblade.py | 1 | 5959 | """
build_mod_picoblade.py
Copyright 2019 Adam Greig
Licensed under the MIT licence, see LICENSE file for details.
Generate foorprints for Molex Picoblade connectors.
"""
from __future__ import print_function, division
import os
import sys
import time
import math
import argparse
from sexp import parse as sexp_parse... | mit | 2,148,596,892,801,452,500 | 27.78744 | 79 | 0.519718 | false | 2.817494 | false | false | false |
lucventurini/mikado | util/getFastaFromIds.py | 1 | 1825 | #!/usr/bin/env python3
import sys, argparse, os
# from Bio import SeqIO
from io import IOBase
import pyfaidx
import textwrap
def main():
def check_type(string):
if os.path.exists(string) and not os.path.isdir(string): return open(string)
else: return set(string.split(','))
parser=argparse.Ar... | lgpl-3.0 | 6,887,286,104,584,532,000 | 38.673913 | 156 | 0.629041 | false | 3.621032 | false | false | false |
jaredlewis/django-entity-history | entity_history/tests/cascade_tests.py | 2 | 3548 | from datetime import datetime
from django.db import connection
from django.test import TransactionTestCase
from django_dynamic_fixture import G
from entity.models import Entity
from entity_history.models import EntityRelationshipActivationEvent, EntityActivationEvent
class CascadeDeleteTest(TransactionTestCase):
... | mit | 2,236,779,935,327,202,800 | 46.945946 | 109 | 0.658963 | false | 3.726891 | false | false | false |
ethronsoft/stor | core/dependencies/mingw/leveldb/build.py | 1 | 1261 | import argparse
import os
import subprocess
import sys
import shutil
def build(root):
os.chdir(os.path.join(root,"source"))
subprocess.check_call("mingw32-make.exe libleveldb.a")
def cleanup(root):
os.chdir(os.path.join(root,"source"))
subprocess.check_call("mingw32-make.exe clean",shell=True)
def finalize(root... | bsd-2-clause | 3,223,668,490,840,596,500 | 28.325581 | 82 | 0.708961 | false | 2.802222 | false | false | false |
EtiCui/Msc-UdeS | dataAnalysis/thermo_dataframe.py | 1 | 1452 | #!/usr/bin/python3
# -*- coding: utf-8 -*-
"""
Created on Tue Jan 10 09:55:40 2017
@author: etienne
This script will open a log.lammps output from LAMMPS and output a pandas dataframe
Usage:
# This script must be in PYTHONPATH or working directory
from thermo_dataframe import read_thermo
thermo_df = open_thermo(fname... | mit | -4,247,716,432,494,760,400 | 26.923077 | 84 | 0.666667 | false | 3.507246 | false | false | false |
kraemerd17/flu-propagation-models | simulation/Person.py | 2 | 7964 | from random import seed
import numpy as np
seed(1)
# status markers
SUSCEPTIBLE = 0
INFECTIVE = 1
REMOVE = 2
DEAD = 3
draw_one = np.random.rand
class Person:
"""
This class models the behavior of a person in a grid world with disease
propagation.
Location and Movement
---
A person spawns... | mit | 7,821,388,825,156,983,000 | 31.112903 | 96 | 0.582747 | false | 4.335329 | false | false | false |
binghongcha08/pyQMD | scitools/tight_binding.py | 1 | 7840 | import sys
import numpy as np
from scipy import linalg
from scipy.special import jv
class TightBinding:
def __init__(self, Norbs, a, r, onsite, hop_inter, hop_intra, D=1):
"""
"""
self.Norbs = Norbs # number of atomic orbitals per unit cell
self.a = a # lattice constant
self... | gpl-3.0 | 4,498,422,596,391,323,000 | 34.004464 | 102 | 0.50102 | false | 2.846768 | false | false | false |
cidadania/ecidadania-ng | src/apps/spaces/fields.py | 2 | 6726 | # -*- coding: utf-8 -*-
#
# Copyright (c) 2013 Clione Software
# Copyright (c) 2010-2013 Cidadania S. Coop. Galega
#
# 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.or... | apache-2.0 | -5,402,120,440,634,961,000 | 42.960784 | 89 | 0.620577 | false | 4.306018 | false | false | false |
combogenomics/DuctApe | ductape/common/colorlog.py | 1 | 1848 | #!/usr/bin/env python
"""
ColorLog
Common library
Colorize the StreamHandler log entries
Thanks to dh82 on Stackoverflow (http://stackoverflow.com/a/2532931/1237531)
"""
import logging
import sys
BLACK, RED, GREEN, YELLOW, BLUE, MAGENTA, CYAN, WHITE = list(range(8))
COLORS = {
'WARNING' : YELLOW,
'INFO' ... | bsd-2-clause | -6,236,823,139,140,439,000 | 28.806452 | 76 | 0.515693 | false | 3.447761 | false | false | false |
projectjamjar/masonjar | jamjar/jamjar/authentication/serializers.py | 1 | 3264 | from rest_framework import serializers
from django.contrib.auth import get_user_model, authenticate
from rest_framework.exceptions import ValidationError
from jamjar.users.models import User
class PasswordSerializer(serializers.Serializer):
password = serializers.CharField(max_length=128)
confirm = serializers... | mit | -4,770,349,772,337,960,000 | 35.674157 | 103 | 0.683824 | false | 4.477366 | false | false | false |
wabarr/physanth-phylogeny | ajax_select/views.py | 2 | 2848 |
from ajax_select import get_lookup
from django.contrib.admin import site
from django.db import models
from django.http import HttpResponse
try:
import json
except ImportError:
from django.utils import simplejson as json
from django.utils.encoding import force_text
def ajax_lookup(request, channel):
""" ... | mit | 8,629,837,834,372,508,000 | 34.6 | 90 | 0.643961 | false | 4.219259 | false | false | false |
alirizakeles/tendenci | tendenci/apps/sitemaps/views.py | 1 | 2888 | '''
Created on 28-02-2011
@author: hpolloni
'''
import subprocess
from django.contrib.sites.models import get_current_site
from django.core.paginator import EmptyPage, PageNotAnInteger
from django.http import Http404
from django.template.response import TemplateResponse
from django.utils.translation import ugettext_l... | gpl-3.0 | 7,149,608,198,120,534,000 | 32.976471 | 108 | 0.615997 | false | 4.044818 | false | false | false |
OpenKMIP/PyKMIP | kmip/tests/unit/core/messages/payloads/test_delete_attribute.py | 1 | 42832 | # Copyright (c) 2019 The Johns Hopkins University/Applied Physics Laboratory
# 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/LICEN... | apache-2.0 | 3,505,382,481,182,673,400 | 35.734134 | 79 | 0.595746 | false | 3.930262 | true | false | false |
sgagnon/lyman-tools | timeseries/extract_info/rm-rt.py | 1 | 1056 | import os.path as op
smoothing = 'smoothed'
regspace = 'epi'
project = 'RM'
design = 'rm_rt.csv'
func_exp = 'rm'
onset_exp = 'rm-rt'
smoothing_fwhm = 0
standardize = True
tr = float(2)
tr_shift = [0, 2, 4, 6, 8, 10, 12] # in seconds
tr_integrate = [0, 2, 4, 6, 8, 10] # in seconds
n_runs = 6
basedir = op.join('/share/... | bsd-2-clause | -5,865,716,851,446,720,000 | 34.2 | 80 | 0.611742 | false | 2.687023 | false | true | false |
noamelf/Open-Knesset | auxiliary/migrations/0004_auto__del_field_tidbit_active__add_field_tidbit_is_active.py | 14 | 1750 | # -*- coding: utf-8 -*-
import datetime
from south.db import db
from south.v2 import SchemaMigration
from django.db import models
class Migration(SchemaMigration):
def forwards(self, orm):
# Deleting field 'Tidbit.active'
db.delete_column('auxiliary_tidbit', 'active')
# Adding field 'Tid... | bsd-3-clause | 2,092,210,945,296,470,000 | 38.795455 | 116 | 0.565143 | false | 3.731343 | false | false | false |
anti-social/elasticmagic | tests/test_agg.py | 1 | 47881 | import math
from mock import Mock, patch
from elasticmagic import agg, Params, Term, Document, DynamicDocument
from elasticmagic.compiler import Compiler_2_0
from elasticmagic.compiler import Compiler_5_0
from elasticmagic.compiler import Compiler_6_0
from elasticmagic.compiler import Compiler_7_0
from elasticmagic.ex... | apache-2.0 | -6,556,013,448,507,907,000 | 35.246026 | 117 | 0.395334 | false | 4.269752 | false | false | false |
NitrousPG/forkbot | bot.py | 1 | 2866 | # LICENSE
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be us... | gpl-3.0 | -5,519,637,023,528,509,000 | 32.717647 | 88 | 0.587927 | false | 3.909959 | false | false | false |
Schallaven/ffeimg | bin/findfeatures.py | 1 | 16296 | #!/usr/bin/env python2.7
# -*- coding: utf-8 -*-
#
# Copyright (C) 2017 by Sven Kochmann
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (a... | gpl-3.0 | -1,567,302,204,791,600,000 | 38.362319 | 119 | 0.621564 | false | 3.664493 | false | false | false |
davidan42/pydyty | pydyty/loc.py | 1 | 1319 | class _SingleLocation(object):
""" Represents a single location. Do not use this directly outside of
this module. The purpose is to represent a single stack trace slice,
which consists of file, line, func, and code."""
def __init__(self, **kwargs):
self.file = kwargs.get('file')
self.li... | bsd-3-clause | 7,977,394,609,614,283,000 | 25.38 | 74 | 0.590599 | false | 3.913947 | false | false | false |
alsrgv/tensorflow | tensorflow/python/__init__.py | 2 | 7803 | # Copyright 2015 The TensorFlow Authors. 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 applica... | apache-2.0 | -4,661,556,362,856,286,000 | 38.409091 | 92 | 0.783929 | false | 3.823126 | false | false | false |
nimbis/django-shop | shop/views/order.py | 2 | 3235 | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.views.decorators.cache import never_cache
from rest_framework import generics, mixins
from rest_framework.exceptions import NotFound, PermissionDenied, MethodNotAllowed
from rest_framework.renderers import BrowsableAPIRenderer
from shop.rest... | bsd-3-clause | 5,445,239,957,949,557,000 | 37.975904 | 90 | 0.665224 | false | 4.250986 | false | false | false |
meco-group/omg-tools | examples/p2p_quadrotor.py | 1 | 1652 | # This file is part of OMG-tools.
#
# OMG-tools -- Optimal Motion Generation-tools
# Copyright (C) 2016 Ruben Van Parys & Tim Mercy, KU Leuven.
# All rights reserved.
#
# OMG-tools is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public
# License as published by the... | lgpl-3.0 | 572,507,921,458,735,900 | 36.545455 | 78 | 0.703995 | false | 3.630769 | false | false | false |
StuartLittlefair/astropy | astropy/modeling/tests/test_physical_models.py | 1 | 19702 | # Licensed under a 3-clause BSD style license - see LICENSE.rst
"""Tests for physical functions."""
# pylint: disable=no-member, invalid-name
import pytest
import numpy as np
from astropy.modeling.physical_models import BlackBody, NFW
from astropy.modeling.fitting import LevMarLSQFitter
from astropy.tests.helper impo... | bsd-3-clause | -7,037,271,549,525,914,000 | 41.923747 | 100 | 0.621561 | false | 2.796196 | true | false | false |
steffann/pylisp | pylisp/utils/auto_socket.py | 1 | 4707 | from ipaddress import IPv4Address, IPv6Address, ip_address
from pylisp.utils.auto_addresses import AutoAddress
import logging
import socket
# Get the logger
logger = logging.getLogger(__name__)
class AutoUDPSocket(object):
def __init__(self, address, port):
# Convert to IPv*Address if necessary
i... | bsd-3-clause | 5,563,104,363,241,039,000 | 36.062992 | 108 | 0.58976 | false | 4.150794 | false | false | false |
UrbanCCD-UChicago/plenario-lambdas | Resolve/resolve.py | 1 | 3430 | from database import postgres_session, redshift_session
from database import redshift_session_context
from models import SensorMeta, FeatureMeta
def resolve():
"""Run resolve sensor for every distinct sensor available in the unknown
feature table in redshift."""
rp = redshift_session.execute('select dist... | mit | 7,231,296,944,956,225,000 | 40.325301 | 87 | 0.597668 | false | 4.466146 | false | false | false |
Machyne/econ_comps | bls/ncs_api.py | 1 | 13264 | """
unused
"""
# http://www.bls.gov/help/hlpforma.htm#NB
# Series ID NBU10000000000000028007
# Positions Value Field Name
# 1-2 NB Prefix
# 3 U Seasonal Adjustment Code
# 4 1 Ownership Code
# 5-6 00 ... | bsd-3-clause | -1,779,484,764,351,462,400 | 33.273902 | 101 | 0.663752 | false | 3.073216 | false | false | false |
Emory-LCS/Alma-Public | DeleteOclcHoldings/get_alma_deleted_items.py | 1 | 13879 | #!/bin/python
# -*- coding: utf-8 -*-
r"""
Author: Alex Cooper
Date: August, 2016
Purpose: get oclc ids of deleted/withdrawn alma records
"""
import os
import sys
import random
import re
import requests
import xml.etree.ElementTree as elementTree
import datetime as dt
import signal
import hmac
import hashlib
i... | gpl-3.0 | 1,553,620,488,313,688,800 | 41.18541 | 139 | 0.436631 | false | 4.045176 | false | false | false |
census-instrumentation/opencensus-python | opencensus/common/backports/__init__.py | 1 | 2809 | # Copyright 2019, OpenCensus Authors
#
# 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 w... | apache-2.0 | -3,958,861,825,873,144,000 | 34.556962 | 106 | 0.594518 | false | 4.065123 | false | false | false |
sharma1nitish/phantomjs | src/qt/qtwebkit/Tools/QueueStatusServer/model/patchlog.py | 119 | 3107 | # Copyright (C) 2013 Google 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 copyright
# notice, this list of conditions and the ... | bsd-3-clause | 4,320,597,427,469,147,000 | 43.385714 | 104 | 0.732861 | false | 4.082786 | false | false | false |
sadig/DC2 | components/dc2-lib/dc2/lib/web/controllers/restctrl.py | 1 | 7560 | # -*- coding: utf-8 -*-
#
# (DC)² - DataCenter Deployment Control
# Copyright (C) 2010, 2011, 2012, 2013, 2014 Stephan Adig <sh@sourcecode.de>
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; eit... | gpl-2.0 | -2,657,933,973,063,999,500 | 36.984925 | 76 | 0.51184 | false | 4.063978 | false | false | false |
joedborg/ElePy | ohms.py | 1 | 1300 | #Joe Borg - Ohms - 05/03/2012
from decimal import Decimal
class Ohms(object):
"""
Written to be a very simple calculator;
construct Ohms with 2 of the 3 required
parameters to make the calculation, or
set afterwards using the `set` methods.
"""
def __init__(self, V=None, I=None, R=None):
try... | gpl-3.0 | 5,675,620,259,324,070,000 | 26.659574 | 55 | 0.567692 | false | 3.939394 | false | false | false |
ronrest/convenience_py | ml/img/image_processing.py | 1 | 30137 | import PIL
from PIL import ImageEnhance, Image, ImageFilter, ImageChops
import PIL.ImageOps
import numpy as np
randint = np.random.randint
__author__ = "Ronny Restrepo"
__copyright__ = "Copyright 2017, Ronny Restrepo"
__credits__ = ["Ronny Restrepo"]
__license__ = "Apache License"
__version__ = "2.0"
# TODO: Color Sh... | apache-2.0 | -1,563,976,809,915,813,600 | 40.45392 | 109 | 0.501808 | false | 4.256638 | false | false | false |
lookee/jaGOF | src/Grid/GridControl.py | 1 | 3185 |
#------------------------------------------------------------------------
# Copyright (C) 2011 Luca Amore <luca.amore at gmail.com>
#
# jaGof is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either... | gpl-3.0 | 5,095,695,212,611,151,000 | 25.991525 | 73 | 0.561068 | false | 3.85127 | false | false | false |
wsldankers/fruitbak | fruitbak/backup.py | 1 | 6411 | """Represent a backup"""
from fruitbak.share import Share
from fruitbak.util import (Initializer, initializer, lockingclass, unlocked, ensure_byteslike, time_ns,
day_interval, week_interval, month_interval, quarter_interval, year_interval)
from fruitbak.config import configurable_property
from hardhat import normali... | gpl-3.0 | -5,528,477,695,218,225,000 | 23.011236 | 106 | 0.704102 | false | 3.057225 | true | false | false |
yfu/tools | fasta-dinucleotide-shuffle.py | 1 | 5947 | #!/home/fuy2/bin/python
import sys, string, random
from Bio import SeqIO
# altschulEriksonDinuclShuffle.py
# P. Clote, Oct 2003
def computeCountAndLists(s):
#Initialize lists and mono- and dinucleotide dictionaries
List = {} #List is a dictionary of lists
List['A'] = []; List['C'] = [];
List['G'] = [... | gpl-3.0 | 2,299,818,121,868,358,100 | 28.735 | 99 | 0.528502 | false | 3.024924 | false | false | false |
lijiabogithub/QUANTAXIS | QUANTAXIS/QAARP/QARisk.py | 1 | 3986 | #coding:utf-8
from QUANTAXIS.QABacktest import QAAnalysis
from QUANTAXIS.QAUtil import QA_util_log_info,QA_util_log_expection
"""message['body']['account']
'account':{
'init_assest':self.total_assest[0],
'portfolio':self.portfolio,
'history':self.history_trade,
'assest_no... | mit | 591,695,818,194,375,600 | 38.095745 | 142 | 0.648884 | false | 2.618674 | false | false | false |
txomon/vdsm | lib/yajsonrpc/stomp.py | 1 | 13418 | # Copyright (C) 2014 Saggi Mizrahi, Red Hat Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY... | gpl-2.0 | 1,757,053,548,595,786,000 | 25.517787 | 79 | 0.588016 | false | 4.017365 | false | false | false |
pbugni/pheme.warehouse | pheme/warehouse/tables.py | 1 | 20770 | #!/usr/bin/env python
usage = """%prog [options] dbname
Script to generate the tables written to from mirth.
NB: If run as a stand-alone, this will wipe the contents of the named
database and rebuild the tables using the schema structure as defined
in this file, after making SURE that's what you want to do.
Try `%p... | bsd-3-clause | -3,897,207,985,080,827,400 | 35.059028 | 76 | 0.6078 | false | 3.538933 | true | false | false |
coderdojobelfast/pi | board/press.py | 1 | 1233 | #!/usr/bin/env python
# Copyright 2014 the original author or authors.
#
# 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... | apache-2.0 | 9,107,822,803,988,746,000 | 21.833333 | 74 | 0.696675 | false | 3.378082 | false | false | false |
google-research/federated | gans/experiments/emnist/classifier/measure_misclassification_of_users.py | 1 | 6228 | # Copyright 2019, Google LLC.
#
# 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 writing... | apache-2.0 | 7,300,505,364,197,953,000 | 37.925 | 80 | 0.723667 | false | 3.627257 | false | false | false |
proycon/foliatools | foliatools/folia2txt.py | 1 | 7310 | #!/usr/bin/env python
#-*- coding:utf-8 -*-
"""
This conversion script reads a FoLiA XML document and outputs the
document's text as plain text, *without* any annotations.
Use folia2annotatedtxt if you want limited support for inline annotations.
"""
from __future__ import print_function, unicode_literals, division, ... | gpl-3.0 | -8,774,095,833,019,102,000 | 37.272251 | 147 | 0.585363 | false | 4.10905 | false | false | false |
BenW0/Ctrl_Design_GUI | scripts.py | 1 | 15733 | ########################################################
# Control Design GUI: plotting.py
# Handles plotting tasks for the GUI.
#
# This set of routines is called from actions on the GUI;
# so the actual calling code is found in the machine.xml's
# <Command> field.
#
# Ben Weiss, University of Washington
# Spring 2014... | mit | 6,773,323,200,135,954,000 | 35.334873 | 181 | 0.566198 | false | 3.808521 | false | false | false |
explosiveduck/pyGameMath | gem/vector.py | 1 | 13607 | import math
import six.moves as sm
REFRENCE_VECTOR_2 = [0.0 for x in sm.range(2)]
REFRENCE_VECTOR_3 = [0.0 for x in sm.range(3)]
REFRENCE_VECTOR_4 = [0.0 for x in sm.range(4)]
def zero_vector(size):
''' Return a zero filled vector list of the requested size '''
# Return a copy of the reference vector, this is... | bsd-2-clause | 1,273,324,130,359,733,200 | 30.644186 | 118 | 0.582494 | false | 3.345709 | false | false | false |
FrodeSolheim/fs-uae-launcher | fsui/extra/iconheader.py | 1 | 2214 | from typing_extensions import Literal
import fsui
from fswidgets.panel import Panel
from fswidgets.widget import Widget
class IconHeader(Panel):
ICON_LEFT = 0
ICON_RIGHT = 1
def __init__(
self,
parent: Widget,
icon: fsui.Icon,
title: str,
subtitle: str = "",
... | gpl-2.0 | -6,240,839,123,284,374,000 | 29.75 | 78 | 0.590334 | false | 3.432558 | false | false | false |
omni-digital/omni-blocks | setup.py | 1 | 2448 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import os
import re
import sys
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
def get_version(*file_paths):
"""Retrieves the version from omni_blocks/__init__.py"""
filename = os.path.join(os.path.dirname(__file__),... | mit | -8,860,033,717,654,082,000 | 29.987342 | 88 | 0.596814 | false | 3.664671 | false | false | false |
ocampocj/cloud-custodian | tools/c7n_azure/c7n_azure/resources/network_security_group.py | 1 | 10481 | # Copyright 2018 Capital One Services, LLC
#
# 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... | apache-2.0 | -725,621,801,637,232,100 | 34.893836 | 99 | 0.602423 | false | 4.185703 | false | false | false |
treemo/circuits | tests/node/test_node.py | 3 | 1621 | #!/usr/bin/env python
from pytest import fixture, skip, PLATFORM
if PLATFORM == 'win32':
skip('Broken on Windows')
from circuits import Component, Event
from circuits.net.events import close
from circuits.node import Node, remote
from circuits.net.sockets import UDPServer
class App(Component):
ready = ... | mit | -730,975,597,659,499,400 | 19.012346 | 59 | 0.657002 | false | 3.692483 | false | false | false |
ChileanVirtualObservatory/pycupid | setup.py | 1 | 3854 | import os
import sys
import subprocess
import platform
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
from distutils.extension import Extension
from Cython.Distutils import build_ext
WRAPPER_DIR = 'pycupid'
CUPID_DIR = 'cupid'
wrapper_sources = [
'pycupid',
]
cupid... | gpl-3.0 | -7,829,399,350,168,127,000 | 22.216867 | 83 | 0.513233 | false | 2.897744 | false | false | false |
plazix/django-private-messages | private_messages/views.py | 1 | 2872 | # -*- coding: utf-8 -*-
from datetime import datetime
from django.contrib.auth.decorators import login_required
from django.core.urlresolvers import reverse
from django.http import HttpResponseRedirect
from django.shortcuts import get_object_or_404
from django.template.response import TemplateResponse
from models im... | bsd-3-clause | 4,964,557,263,115,975,000 | 28.905263 | 84 | 0.642731 | false | 3.956825 | false | false | false |
chenbillcat/AuthDog | authdog/model/sql.py | 1 | 15787 | import json
from sqlalchemy.exc import IntegrityError
from authdog.model.connection import get_engine, get_session_maker
from authdog.model.connection import get_session
from authdog.model.default import Domain, Project, User, Group, Role, \
UserGroupMembership, UserRoleMembership, GroupRoleMembership
from authdo... | apache-2.0 | -6,515,857,791,971,981,000 | 35.62877 | 106 | 0.551276 | false | 4.151196 | false | false | false |
davidhoksza/bayescreen | aggreagated_analysis.py | 1 | 5189 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
This script aggregates results of multiple model analyzes. This can be useful when having multiple splits
of train and test data and want to compare the models coming from different train splits, or when evaluating
multiple models of the same target based on differ... | mit | -320,099,909,522,065,800 | 37.930769 | 162 | 0.596839 | false | 4.076198 | false | false | false |
kkoksvik/FreeCAD | src/Mod/Fem/ccxFrdReader.py | 2 | 20539 | #***************************************************************************
#* *
#* Copyright (c) 2013 - Joachim Zettler *
#* Copyright (c) 2013 - Juergen Riegel <FreeCAD@juergen-riegel.net> *
#* ... | lgpl-2.1 | -687,466,832,076,727,800 | 44.140659 | 160 | 0.483178 | false | 3.251385 | false | false | false |
openstack/oslo.cache | oslo_cache/tests/functional/memcache_pool/test_cache_backend.py | 1 | 1296 | # Copyright 2020 OpenStack Foundation
#
# 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 l... | apache-2.0 | 5,111,459,616,946,418,000 | 39.5 | 78 | 0.695216 | false | 4.114286 | true | false | false |
InUrSys/PescArt2.0 | GeneratedFiles/ui_ViagemPesca_ToView.py | 1 | 1899 | # -*- coding: utf-8 -*-
# Form implementation generated from reading ui file '/Users/chernomirdinmacuvele/Documents/workspace/PescArt2.0/UserInt/ui_ViagemPesca_ToView.ui'
#
# Created by: PyQt5 UI code generator 5.8.2
#
# WARNING! All changes made in this file will be lost!
from PyQt5 import QtCore, QtGui, QtWidgets
... | gpl-3.0 | 4,483,848,311,810,789,000 | 42.159091 | 146 | 0.691943 | false | 3.391071 | false | false | false |
sdrogers/ms2ldaviz | ms2ldaviz/add_example_experiments.py | 1 | 1210 | import os,sys
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "ms2ldaviz.settings")
import django
django.setup()
from basicviz.models import *
from django.contrib.auth.models import User
if __name__ == '__main__':
username = sys.argv[1]
try:
user = User.objects.get(username = username)
except:
print("No such ... | mit | -76,859,468,578,864,590 | 30.025641 | 86 | 0.717355 | false | 2.972973 | false | false | false |
EPFLMachineLearningTeam01/Project1 | src/scripts/k_fold.py | 1 | 2511 | import numpy as np
from matplotlib import pyplot as plt
from scripts import plots
from tqdm import tqdm
def build_k_indices(num_row, k_fold, seed):
""" build and seperate k random indices for k-fold """
interval = int(num_row / k_fold)
np.random.seed(seed)
indices = np.random.permutation(num_row)
k... | mit | -3,633,637,477,088,594,400 | 35.391304 | 147 | 0.589805 | false | 3.014406 | false | false | false |
flit/pyOCD | pyocd/probe/pydapaccess/interface/__init__.py | 2 | 2267 | # pyOCD debugger
# Copyright (c) 2006-2013 Arm Limited
# Copyright (c) 2021 Chris Reed
# 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-2.0 | -2,750,158,031,165,137,400 | 33.348485 | 96 | 0.687252 | false | 3.587025 | false | false | false |
MennoNij/DrivePy | datacollector.py | 1 | 1416 | import os
class DataCollector(object):
def __init__(self, name, filename, fields):
self.name = name
self.filename = filename
self.fields = fields
self.numFields = len(fields)
self.entries = []
self.delimiter = '\t'
self.fp = open(self.filename,'w')
se... | mit | -7,478,594,534,251,103,000 | 24.745455 | 77 | 0.478107 | false | 3.786096 | false | false | false |
HewlettPackard/oneview-redfish-toolkit | oneview_redfish_toolkit/api/network_port.py | 1 | 2725 | # -*- coding: utf-8 -*-
# Copyright (2017-2018) Hewlett Packard Enterprise Development LP
#
# 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
#
# U... | apache-2.0 | 1,052,340,618,116,853,100 | 36.328767 | 77 | 0.645872 | false | 4.103916 | false | false | false |
umanium/trafficmon | BackgroundSubtraction.py | 1 | 2863 | import cv2
import numpy as np
import PostProcessing
from abc import ABCMeta, abstractmethod
"""
Author: Luqman A. M.
BackgroundSubtraction.py
Background Subtraction Algorithms Object Detection in Video Processing (Abstract Class)
Frame Difference, Running Average, Median, Online K-Means, 1-G, KDE
"""
class Backgroun... | mit | 6,760,772,987,791,512,000 | 30.822222 | 87 | 0.560251 | false | 3.633249 | false | false | false |
brentp/bwa-mips | bwamips.py | 1 | 20414 | """
With molecular inversion probes, we map reads to the genome that include the
ligation and extension arms, along with a molecular tag (AKA UMI).
This script takes:
1) ref.fasta
2) mips design file (likely from MIPgen)
3) de-multiplxed, paired-end fastqs
and moves the UMI into the read-name, aligns the r... | mit | -1,242,793,805,164,744,000 | 33.309244 | 112 | 0.524983 | false | 3.189189 | false | false | false |
kuscsik/chromiumembedded | tools/automate/automate-git.py | 1 | 34206 | # Copyright (c) 2014 The Chromium Embedded Framework Authors. All rights
# reserved. Use of this source code is governed by a BSD-style license that
# can be found in the LICENSE file.
from optparse import OptionParser
import os
import shlex
import shutil
import subprocess
import sys
import tempfile
import urllib
impo... | bsd-3-clause | -2,640,453,329,877,397,500 | 34.89297 | 99 | 0.638514 | false | 3.52821 | true | false | false |
SciLifeLab/bcbio-nextgen | bcbio/pipeline/region.py | 1 | 5873 | """Provide analysis of input files by chromosomal regions.
Handle splitting and analysis of files from chromosomal subsets separated by
no-read regions.
"""
import collections
import os
import toolz as tz
from bcbio.distributed.split import parallel_split_combine
def get_max_counts(samples):
"""Retrieve the max... | mit | -4,860,091,765,015,083,000 | 40.06993 | 116 | 0.570747 | false | 3.813636 | true | false | false |
ianj-als/pypeline | src/pypeline/helpers/tests/helper_pipeline_tests.py | 1 | 7559 | #
# Copyright Applied Language Solutions 2012
#
# This file is part of Pypeline.
#
# Pypeline is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any l... | gpl-3.0 | 6,663,194,150,949,690,000 | 40.994444 | 108 | 0.516735 | false | 4.399884 | true | false | false |
elsuizo/Dots_files | Ranger/colorschemes/candycane.py | 1 | 5327 | #= -------------------------------------------------------------------------
# @file candycane.py
#
# @date 12/08/17 12:59:58
# @author Martin Noblia
# @email mnoblia@disroot.org
#
# @brief
#
# @detail
#
# Licence:
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU G... | mit | 5,992,277,240,032,096,000 | 28.269231 | 78 | 0.437207 | false | 5.07817 | false | false | false |
PressLabs/pyolite | tests/test_git.py | 1 | 1457 | import pytest
from mock import MagicMock, patch, call
from pyolite.git import Git
def test_commit_with_no_message():
mock_repo = MagicMock()
with pytest.raises(ValueError):
git = Git(mock_repo)
objects = ['simple_object', 'more_complex_one']
git.commit(objects, '')
def test_commit... | bsd-2-clause | 6,586,957,615,115,815,000 | 31.377778 | 80 | 0.617708 | false | 3.372685 | false | false | false |
tachijuan/python | imap.py | 1 | 1583 | # simple stuff for raspberry pi
# turns on lights based on unread emails in an IMAP account
import os, sys, imaplib, rfc822, re, StringIO
import RPi.GPIO as GPIO
import time
server ='mail.xxxx.us'
username='juan@xxxx.us'
password='password'
GPIO.setmode(GPIO.BOARD)
GREEN_LED = 22
RED_LED = 7
GPIO.setup(GREEN_LED, ... | mit | 9,090,821,163,259,533,000 | 22.279412 | 65 | 0.550221 | false | 3.257202 | false | false | false |
michellab/SireUnitTests | unittests/SireIO/test_pdb2.py | 1 | 4335 | from Sire.Base import *
from Sire.IO import *
from Sire.Mol import *
from glob import glob
from nose.tools import assert_equal, assert_almost_equal
# Check that we have PDB2 support in this version of Sire.
has_pdb2 = True
try:
p = PDB2()
except:
# No PDB2 support.
has_pdb2 = False
# General test of abi... | gpl-3.0 | -8,667,253,502,027,538,000 | 28.896552 | 80 | 0.558708 | false | 3.795972 | true | false | false |
grpc/grpc | src/python/grpcio/support.py | 10 | 4388 | # Copyright 2016 gRPC authors.
#
# 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 writing... | apache-2.0 | 1,985,814,918,368,222,200 | 36.186441 | 85 | 0.672288 | false | 3.849123 | false | false | false |
jangorecki/h2o-3 | h2o-py/tests/testdir_munging/pyunit_date_munge.py | 6 | 1258 | import sys
sys.path.insert(1,"../../")
import h2o
from tests import pyunit_utils
def refine_date_col(data, col):
data["Day"] = data[col].day()
data["Month"] = data[col].month() + 1 # Since H2O indexes from 0
data["Year"] = data[col].year() + 1900 # Start of epoch is 1900
data["WeekNum"] ... | apache-2.0 | 1,107,474,734,357,149,000 | 31.25641 | 111 | 0.615262 | false | 2.783186 | false | false | false |
BL-Labs/poetryhunt | gale_links.py | 1 | 4625 | import os
import sqlite3
GALE_FILE = "/datastore/gale_links/link.db"
class GaleLinks(object):
def __init__(self, dbfile = GALE_FILE):
self._conn = sqlite3.connect(dbfile)
# Dict responses:
self._conn.row_factory = sqlite3.Row
self._cur = self._conn.cursor()
self._lookup_keys = ["int_id... | mit | -1,310,766,691,638,997,800 | 37.231405 | 233 | 0.541405 | false | 3.522468 | false | false | false |
janebeckman/gpdb | src/test/tinc/tincrepo/mpp/gpdb/tests/storage/aoco_compression/test_func_aococompression_large_01.py | 2 | 3016 | """
Copyright (c) 2004-Present Pivotal Software, Inc.
This program and the accompanying materials are made available under
the terms of the 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.... | apache-2.0 | 3,945,307,366,963,894,300 | 41.478873 | 123 | 0.695955 | false | 3.40791 | true | false | false |
f304646673/scheduler_frame | src/strategy/update_today_trade_info.py | 1 | 4631 | #coding=utf-8
#-*- coding: utf-8 -*-
import os
import re
import sys
import time
import urllib2
sys.path.append("../frame/")
import fetch_data
from loggingex import LOG_INFO
from loggingex import LOG_ERROR
from loggingex import LOG_WARNING
from job_base import job_base
from prepare_table import prepare_table
from mys... | apache-2.0 | 5,222,363,968,655,461,000 | 34.351145 | 154 | 0.574174 | false | 3.275106 | false | false | false |
ratnania/caid | caid-gui/geometry.py | 1 | 11361 | # -*- coding: UTF-8 -*-
from caid.cad_geometry import cad_geometry
from evaluator import CurveEvaluator, SurfaceEvaluator, VolumeEvaluator
from numpy import array, asarray
from OpenGL.GL import *
from theme import theme as Theme
from global_vars import strtoArray
theme = Theme()
ALPHA = theme.alpha... | mit | 5,248,606,936,573,861,000 | 28.897368 | 91 | 0.52469 | false | 3.917586 | false | false | false |
oihane/odoo-addons | stock_picking_template/wizard/stock_picking_duplicate.py | 2 | 1825 | # Copyright (c) 2019 Daniel Campos <danielcampos@avanzosc.es> - Avanzosc S.L.
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).
from odoo import api, fields, models
from odoo.models import expression
from odoo.tools.safe_eval import safe_eval
class StockPickingDuplicate(models.TransientModel):
_na... | agpl-3.0 | 1,541,403,533,081,965,300 | 42.452381 | 79 | 0.546301 | false | 4.002193 | false | false | false |
santazhang/simple-rpc | test/benchmark_service.py | 1 | 12420 | import os
from simplerpc.marshal import Marshal
from simplerpc.future import Future
point3 = Marshal.reg_type('point3', [('x', 'double'), ('y', 'double'), ('z', 'double')])
class BenchmarkService(object):
FAST_PRIME = 0x5b9365eb
FAST_DOT_PROD = 0x4a92c615
FAST_ADD = 0x484806bf
FAST_NOP = 0x4f29b7a5
... | bsd-3-clause | -3,532,710,573,567,985,700 | 51.627119 | 201 | 0.585507 | false | 3.529412 | false | false | false |
equitania/myodoo-addons-v10 | eq_hr/models/eq_res_users.py | 1 | 4933 | # -*- coding: utf-8 -*-
##############################################################################
#
# Odoo Addon, Open Source Management Solution
# Copyright (C) 2014-now Equitania Software GmbH(<http://www.equitania.de>).
#
# This program is free software: you can redistribute it and/or modify
# it un... | agpl-3.0 | 6,215,408,127,910,736,000 | 43.818182 | 140 | 0.551227 | false | 3.862853 | false | false | false |
alexandre/quokka | quokka/core/models/channel.py | 2 | 8267 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import logging
from flask.ext.mistune import markdown
from quokka.core.db import db
from quokka.core.models.custom_values import HasCustomValue
from quokka.core.models.signature import (
Tagged, Publishable, LongSlugged, ContentFormat, TemplateType
)
from quokka.core.... | mit | 7,350,539,074,475,366,000 | 34.480687 | 78 | 0.624652 | false | 4.040567 | false | false | false |
nilp0inter/cpe | cpe/cpelang2_3.py | 2 | 9692 | #! /usr/bin/env python
# -*- coding: utf-8 -*-
"""
This file is part of cpe package.
This module is an implementation of CPE language matching
algorithm in accordance with version 2.3 of CPE (Common Platform
Enumeration) specification.
Copyright (C) 2013 Alejandro Galindo García, Roberto Abdelkader Martínez Pérez
... | lgpl-3.0 | 4,507,366,771,445,993,000 | 33.343972 | 98 | 0.594115 | false | 4.017005 | true | false | false |
poldrack/myconnectome | myconnectome/taskbehavior/mkfiles_task002.py | 2 | 1605 | # -*- coding: utf-8 -*-
"""
analysis for task002 - stop signal (now called task003)
Created on Wed Jun 17 13:51:20 2015
@author: poldrack
"""
import os,glob
import numpy
datadir=os.path.join('/corral-repl/utexas/poldracklab/data/selftracking/task_behavior/task002')
origfilesdir=os.path.join(datadir,'origfiles')
out... | mit | -8,645,904,137,531,599,000 | 36.325581 | 105 | 0.653583 | false | 2.994403 | false | false | false |
vishdha/erpnext | erpnext/hr/doctype/salary_structure/salary_structure.py | 9 | 3441 | # Copyright (c) 2015, Frappe Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe
from frappe.utils import flt, cint, getdate
from frappe import _
from frappe.model.mapper import get_mapped_doc
from frappe.model.documen... | gpl-3.0 | -8,962,062,766,537,062,000 | 34.474227 | 109 | 0.694275 | false | 3.156881 | false | false | false |
beaker-project/beah | beah/wires/internals/twadaptors.py | 1 | 4891 | # Beah - Test harness. Part of Beaker project.
#
# Copyright (C) 2009 Red Hat, Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any l... | gpl-2.0 | 5,161,691,518,080,537,000 | 36.914729 | 81 | 0.645471 | false | 4.209122 | false | false | false |
pybursa/homeworks | HOMETASKS/hw3/hw3_solution8.py | 1 | 1994 | #!/usr/bin/env python
# -*- coding: utf8 -*-
"""
Задание 8: A-a-a (бонусное)
УСЛОВИЕ:
Посчитать в тексте количество букв "a" при условии что она окружена согласными
("car") и она не является первой или последней буквой слова.
Текст:
Cras ultricies ligula sed magna dictum porta. Vivamus magna justo, lacinia eget cons... | gpl-2.0 | -4,023,366,230,583,887,400 | 39.065217 | 646 | 0.708627 | false | 2.356777 | false | false | false |
tkolhar/robottelo | robottelo/ui/location.py | 1 | 7849 | # -*- encoding: utf-8 -*-
"""Implements Locations UI"""
from robottelo.constants import FILTER
from robottelo.ui.base import Base, UINoSuchElementError
from robottelo.ui.locators import common_locators, locators, tab_locators
from robottelo.ui.navigator import Navigator
from selenium.webdriver.support.select import Sel... | gpl-3.0 | 441,865,684,165,400,100 | 48.993631 | 79 | 0.515225 | false | 4.809436 | true | false | false |
KMU-embedded/mosbench-ext | mparts/server.py | 1 | 10500 | from __future__ import with_statement
import sys, os, subprocess, errno, hashlib, threading, signal, gzip
from mparts.rpc import RPCServer, RPCProxy
LOG_COMMANDS = False
__all__ = ["CAPTURE", "STDERR", "DISCARD",
"CHECKED", "UNCHECKED"]
CAPTURE = "\0CAPTURE"
STDERR = "\0STDERR"
DISCARD = "\0DISCARD"
CHE... | mit | -7,960,129,831,795,655,000 | 32.546326 | 96 | 0.499714 | false | 4.058755 | false | false | false |
eljost/pysisyphus | tests_staging/test_freq_distort/imgkill.py | 1 | 4397 | #!/usr/bin/env python3
from collections import namedtuple
import sys
import matplotlib.pyplot as plt
import numpy as np
# from pysisyphus.calculators.ORCA import ORCA
from pysisyphus.calculators.XTB import XTB
from pysisyphus.helpers import geom_from_xyz_file, eigval_to_wavenumber
from pysisyphus.TablePrinter import... | gpl-3.0 | 288,730,877,520,123,840 | 28.233333 | 85 | 0.600456 | false | 3.203068 | false | false | false |
citrix-openstack-build/nova | nova/tests/api/openstack/compute/contrib/test_flavor_swap.py | 11 | 3422 | # Copyright 2012 Nebula, 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... | apache-2.0 | 4,055,770,017,989,038,600 | 30.109091 | 78 | 0.613968 | false | 3.587002 | true | false | false |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.