repo_name stringlengths 5 92 | path stringlengths 4 221 | copies stringclasses 19
values | size stringlengths 4 6 | content stringlengths 766 896k | license stringclasses 15
values | hash int64 -9,223,277,421,539,062,000 9,223,102,107B | line_mean float64 6.51 99.9 | line_max int64 32 997 | alpha_frac float64 0.25 0.96 | autogenerated bool 1
class | ratio float64 1.5 13.6 | config_test bool 2
classes | has_no_keywords bool 2
classes | few_assignments bool 1
class |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
ryfeus/lambda-packs | Pandas_numpy/source/pandas/core/indexes/multi.py | 1 | 99726 |
# pylint: disable=E1101,E1103,W0232
import datetime
import warnings
from functools import partial
from sys import getsizeof
import numpy as np
from pandas._libs import index as libindex, lib, Timestamp
from pandas.compat import range, zip, lrange, lzip, map
from pandas.compat.numpy import function as nv
from pandas ... | mit | 1,490,002,587,607,746,000 | 34.388928 | 79 | 0.524226 | false | 4.390122 | false | false | false |
lewisodriscoll/sasview | src/sas/sasgui/perspectives/calculator/collimation_editor.py | 1 | 22696 | """
"""
import wx
import sys
from copy import deepcopy
from sas.sascalc.dataloader.loader import Loader
from sas.sascalc.dataloader.data_info import Aperture, Collimation
from aperture_editor import ApertureDialog
from sas.sasgui.guiframe.utils import check_float
_BOX_WIDTH = 60
if sys.platform.count("win32") > 0:
... | bsd-3-clause | 1,283,563,231,592,060,000 | 40.491773 | 82 | 0.575916 | false | 3.813172 | false | false | false |
lilsweetcaligula/Online-Judges | hackerrank/algorithms/implementation/medium/the_grid_search/py/solution.py | 1 | 1174 | #!/bin/python3
import sys
def solution(grid, pattern):
for i in range(len(grid)):
if len(grid) - i < len(pattern):
break
offsets = set()
offset = grid[i].find(pattern[0])
while offset >= 0:
offsets.add(offset)
offset = grid[i]... | mit | -7,153,626,729,926,510,000 | 19.964286 | 60 | 0.423339 | false | 3.473373 | false | false | false |
akintolga/superdesk-core | apps/duplication/archive_move.py | 1 | 5307 | # -*- coding: utf-8; -*-
#
# This file is part of Superdesk.
#
# Copyright 2013, 2014 Sourcefabric z.u. and contributors.
#
# For the full copyright and license information, please see the
# AUTHORS and LICENSE files distributed with this source code, or
# at https://www.sourcefabric.org/superdesk/license
from eve.uti... | agpl-3.0 | -6,637,375,008,862,455,000 | 38.311111 | 117 | 0.659695 | false | 3.612662 | true | false | false |
CarlosManuelRodr/wxChaos | libs/wxMSW-3.1.4/src/stc/gen_docs.py | 1 | 60559 | #!/usr/bin/env python
#----------------------------------------------------------------------------
# Name: src/stc/gen_docs.py
# Purpose: Helper function and data used by gen_iface.py to generate
# docstrings for wxStyledTextCtrl methods.
# Author: New Pagodi
# Created: 2017-02-24... | gpl-3.0 | 2,932,748,497,012,403,700 | 40.168593 | 97 | 0.675622 | false | 3.759327 | false | false | false |
glennhickey/teHmm | bin/removeBedState.py | 1 | 1340 | #!/usr/bin/env python
#Copyright (C) 2013 by Glenn Hickey
#
#Released under the MIT license, see LICENSE.txt
import sys
import os
import argparse
import copy
from pybedtools import BedTool, Interval
"""
Filter out bed intervals that have a given name. Print result to stdout
"""
def main(argv=None):
if argv is... | mit | 2,065,504,077,651,398,100 | 28.130435 | 73 | 0.632836 | false | 3.895349 | false | false | false |
shincling/MemNN_and_Varieties | DataCoupus/1230实验数据/calculate_the_error.py | 1 | 12325 | # -*- coding: utf8 -*-
__author__ = 'shin'
import re
import jieba
import random
import datetime
'''
namelist=[395,237,283,432,370,137,388,453,447,270,407,378,190,350,308,205,422,20,280,297,261,231,306,213,457,161,459,364,420,75,383,117,112,428,325,179,454,443,390,424]
countlist=[224,417,434,209,134,223,393,95,286,396,1... | bsd-3-clause | 1,157,697,086,625,646,800 | 25.661442 | 168 | 0.52816 | false | 1.524467 | false | false | false |
lextoumbourou/simple-ranker | tests/test_ranker.py | 1 | 3895 | import unittest
import datetime
import pandas as pd
from simple_ranker import Ranker
class RankerTest(unittest.TestCase):
def setUp(self):
self.current_year = datetime.datetime.now().year
def test_rank_by_PE_returns_lowest_first(self):
pe_rank = {
'name': 'pe',
'asce... | mit | -6,904,181,074,526,721 | 29.193798 | 74 | 0.458793 | false | 3.219008 | true | false | false |
GHrama/ameowsmeowl-2015 | plotting scripts/more_clients_throughput.py | 1 | 3387 | author__ = 'ramapriyasridharan'
import matplotlib.pyplot as plt
import numpy as np
import argparse
import pandas as pd
import scipy as sp
import scipy.stats, math
import sys
import os
import ConfigParser
WARMUP_SECS = 20
COOLDOWN_SECS = 70
def mean_confidence_interval(data, confidence=0.95):
# a = 1.0*np.a... | mit | 1,628,782,268,278,129,400 | 27.462185 | 105 | 0.55034 | false | 2.984141 | false | false | false |
111pontes/ydk-py | cisco-ios-xe/ydk/models/cisco_ios_xe/Cisco_IOS_XE_memory_oper.py | 1 | 4373 | """ Cisco_IOS_XE_memory_oper
This module contains a collection of YANG definitions for
monitoring memory in a Network Element.Copyright (c) 2016\-2017 by Cisco Systems, Inc.All rights reserved.
"""
import re
import collections
from enum import Enum
from ydk.types import Empty, YList, YLeafList, DELETE, Decimal64... | apache-2.0 | -2,952,508,661,227,861,500 | 24.424419 | 152 | 0.540361 | false | 4.152896 | false | false | false |
lantianlz/qiexing | www/journey/interface.py | 1 | 13639 | # -*- coding: utf-8 -*-
import datetime
from django.db import transaction
from django.db.models import F
from common import utils, debug, cache
from www.misc.decorators import cache_required
from www.misc import consts
from www.message.interface import UnreadCountBase
from www.account.interface import UserBase
from w... | gpl-2.0 | 2,520,855,221,058,252,300 | 33.556728 | 155 | 0.594793 | false | 3.055763 | false | false | false |
realdubb/flask-microblog | app/views.py | 1 | 1136 | from flask import render_template, flash, redirect
from app import app
from .forms import LoginForm
@app.route('/')
@app.route('/index')
def index():
user = {'nickname': 'Alex'} # fake user
posts = [ # fake array of posts
{
'author': {'nickname': 'John'},
'body': 'Beautiful ... | mit | -8,520,321,134,805,134,000 | 32.441176 | 68 | 0.483275 | false | 4.369231 | false | false | false |
jpirko/lnst | lnst/Recipes/ENRT/VirtualBridgeVlanInGuestMirroredRecipe.py | 1 | 5773 | import logging
from lnst.Common.Parameters import Param
from lnst.Common.IpAddress import ipaddress
from lnst.Controller import HostReq, DeviceReq, RecipeParam
from lnst.Recipes.ENRT.BaseEnrtRecipe import BaseEnrtRecipe
from lnst.Recipes.ENRT.ConfigMixins.OffloadSubConfigMixin import (
OffloadSubConfigMixin)
from l... | gpl-2.0 | 122,444,251,705,942,030 | 36.487013 | 84 | 0.581327 | false | 3.399882 | true | false | false |
stadtgestalten/stadtgestalten | grouprise/core/migrations/0001_initial.py | 1 | 1226 | # -*- coding: utf-8 -*-
# Generated by Django 1.10.4 on 2017-04-19 17:45
from __future__ import unicode_literals
import grouprise.core.models
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
initial = True
dependencies = [
('gestalten'... | agpl-3.0 | -4,449,390,067,574,472,700 | 37.3125 | 127 | 0.624796 | false | 4.07309 | false | false | false |
certik/sfepy | sfepy/fem/materials.py | 1 | 5386 | from sfepy.base.base import *
##
# 21.07.2006, c
class Materials( Container ):
##
# 24.07.2006, c
def from_conf( conf, wanted = None ):
if wanted is None:
wanted = conf.keys()
objs = OneTypeList( Material )
for key, val in conf.iteritems():
if key in wanted... | bsd-3-clause | -6,589,278,138,820,363,000 | 27.052083 | 81 | 0.50687 | false | 3.651525 | false | false | false |
yhoogstrate/fuma | tests/test_FusionDetectionExperiment.py | 1 | 20805 | #!/usr/bin/env python
"""[License: GNU General Public License v3 (GPLv3)]
This file is part of FuMa.
FuMa 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 opti... | gpl-3.0 | 2,745,446,628,363,753,500 | 35.308901 | 259 | 0.625619 | false | 2.84727 | true | false | false |
antiX-Linux/gufw-jessie | gui-ufw-12.10.0/gufw/util.py | 1 | 2922 | # Gufw 12.10.0 - http://gufw.tuxfamily.org
# Copyright (C) 2008-2011 Raul Soriano https://launchpad.net/~gatoloko
# Marcos Alvarez Costales https://launchpad.net/~costales
#
# Gufw is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as p... | gpl-3.0 | -4,163,588,436,551,281,000 | 30.76087 | 93 | 0.574264 | false | 3.780078 | false | false | false |
NicovincX2/Python-3.5 | Analyse (mathématiques)/Analyse fonctionnelle/Analyse harmonique/Théorie de Fourier/Transformation de Fourier rapide (FFT)/fft-2d_example.py | 1 | 2898 | # -*- coding: utf-8 -*-
import os
# two dimensional FFT example
# following
# http://matlabgeeks.com/tips-tutorials/how-to-do-a-2-d-fourier-transform-in-matlab/
import matplotlib.cm
import pylab
import numpy
import math
# get the figure
f = pylab.imread("luna_bw.png")
# two dimension FFT -- F is complex
F = numpy... | gpl-3.0 | 5,805,982,785,886,531,000 | 22 | 87 | 0.636991 | false | 2.646575 | false | false | false |
aristanetworks/arista-ovs-quantum | quantum/openstack/common/rpc/impl_qpid.py | 1 | 20071 | # vim: tabstop=4 shiftwidth=4 softtabstop=4
# Copyright 2011 OpenStack LLC
# Copyright 2011 - 2012, 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
#
# h... | apache-2.0 | -5,016,163,917,021,905,000 | 33.605172 | 79 | 0.567186 | false | 4.311708 | false | false | false |
Enucatl/dpc_reconstruction | dpc_reconstruction/io/hdf5.py | 1 | 1091 | import os
import h5py
import numpy as np
def read_group(filename, group, drop_last_dataset=False):
input_file = h5py.File(filename)
datasets = [
dataset[...]
for dataset in input_file[group].values()
if isinstance(dataset, h5py.Dataset)
]
if drop_last_dataset:
datasets ... | gpl-3.0 | 2,888,513,053,529,854,500 | 27.710526 | 69 | 0.571952 | false | 3.44164 | false | false | false |
gsrp/opengsrp | gsrp/managers/dbmanager.py | 1 | 1639 | # --*-- coding: utf-8 --*--
import sys
import traceback
import logging
import psycopg2
import psycopg2.extras
from datetime import datetime
from managers.manager import Manager
from services.cursor import Cursor
from orm.common import *
from tools.translations import trlocal as _
_logger = logging.getLogger('listener.... | agpl-3.0 | 8,139,869,396,832,990,000 | 22.449275 | 115 | 0.703337 | false | 3.070209 | false | false | false |
slaughterjames/etendard | probeconnect.py | 1 | 11589 | '''
Etendard v0.4 - Copyright 2012 James Slaughter,
This file is part of Etendard v0.4.
Etendard v0.4 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... | gpl-3.0 | -5,317,377,660,412,161,000 | 31.647887 | 173 | 0.506083 | false | 4.680533 | false | false | false |
keflavich/pyspeckit-obsolete | examples/doublet_example.py | 1 | 1645 | import pyspeckit
# Read in J000002.09+155254.1 spectrum, a nice emission-line galaxy
sp = pyspeckit.Spectrum('../tests/SIIdoublet.fits')
# Read in rest wavelengths of SII lines. If you didn't know the names already,
# you could do sp.speclines.optical.lines.keys() to see what is available.
SIIa = sp.speclines.optic... | mit | 9,129,732,285,446,968,000 | 33.270833 | 89 | 0.682675 | false | 2.797619 | false | false | false |
planetceres/toy_neural_nets | neural_net_series.py | 1 | 4442 | '''
Author: Matt Shaffer
Contact: matt@discovermatt.com
'''
import numpy as np
import matplotlib.pyplot as plt
'''
1. Build simulated data graph
'''
steps = 1001
period = 1000
amplitude = 2
timeline = np.linspace(0, period, steps, dtype=int) # steps
num_prev = np.random.rand(1)*10
num = np.random.rand(1)*10
def ran... | mit | -3,556,781,273,088,272,400 | 28.03268 | 115 | 0.644304 | false | 2.901372 | false | false | false |
gappleto97/python-utils | call.py | 1 | 2208 | def call(mod, cmd, *args, **kargs):
"""Calls arbitrary python code
Arguments:
mod - The module from which you are calling
cmd - The command in said module
*args - Any arguments you need to give to it
index=0 - A specific index at which to return
end=0 - An end... | lgpl-3.0 | -1,322,745,193,364,802,300 | 30.542857 | 77 | 0.525362 | false | 4.051376 | false | false | false |
kcsaff/maze-builder | maze_builder/lost_text/exclamations.py | 1 | 2698 | import random
from maze_builder.sewer import Choice
EXCLAMATIONS = Choice({
('What', '?.'): 1,
('Well', '!.'): 1,
('Hmm', '.!?'): 1,
('Yikes', '!'): 1,
('Nope', '.!?'): 1,
('Bleh', '.'): 1,
('Super', '!.'): 1,
('Geez', '!.'): 1,
('What on earth', '.?!'): 1,
('Gah', '.!'): 1,
... | mit | -6,077,810,046,919,624,000 | 25.88 | 103 | 0.397469 | false | 2.975637 | false | false | false |
akissa/baruwa2 | baruwa/forms/reports.py | 1 | 6681 | # -*- coding: utf-8 -*-
# vim: ai ts=4 sts=4 et sw=4
# Baruwa - Web 2.0 MailScanner front-end.
# Copyright (C) 2010-2015 Andrew Colin Kissa <andrew@topdog.za.net>
#
# 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 S... | gpl-3.0 | 1,702,597,552,002,080,800 | 37.177143 | 78 | 0.601557 | false | 3.678965 | false | false | false |
shaivikochar/TouristNYC | setup.py | 1 | 1455 | import os
from setuptools import setup
requires = (
'Jinja2',
'Werkzeug',
'certifi',
'chardet',
'distribute',
'gunicorn',
'requests',
'urllib3',
'itsdangerous>=0.21',
'click>=2.0',
)
def read(fname):
return open(os.path.join(os.path.dirname(__file__), fname)).read()
setup(
name = "tourist-... | gpl-3.0 | 358,439,681,659,049,000 | 26.980769 | 70 | 0.582131 | false | 3.74036 | false | false | false |
jhia/fundayacucho-social | app/routes/api.py | 1 | 3730 | from flask import jsonify, g, request
from flask_login import login_required
from app import app
from app.database import db
from app.models import User, Post, Comment
from datetime import datetime
from app.mixins import jsonable_posts, jsonable_friends, jsonable_comments, post_dict, comment_dict, user_dict
@app.route... | gpl-3.0 | 4,744,035,402,950,067,000 | 33.229358 | 110 | 0.579625 | false | 3.628405 | false | false | false |
dacb/assembly_and_binning | prokka/contigs/glue_together_gffs.py | 1 | 2311 | import argparse
import glob
import os
import sys
def prep_filename(gff_dir):
# strip off trailing '/'
gff_dir = gff_dir.rstrip('/')
return os.path.join(gff_dir, '{}_gffs_concatenated.gff'.format(gff_dir))
def combine_gffs(gff_file_list, filename):
# sort gff files, just in case
gff_file_list ... | mit | -3,592,007,642,650,073,600 | 37.516667 | 93 | 0.574643 | false | 3.64511 | false | false | false |
ISMiller101/vpsolver | pyvpsolver/model/__init__.py | 1 | 4346 | """
This code is part of the Arc-flow Vector Packing Solver (VPSolver).
Copyright (C) 2013-2015, Filipe Brandao
Faculdade de Ciencias, Universidade do Porto
Porto, Portugal. All rights reserved. E-mail: <fdabrandao@dcc.fc.up.pt>.
This program is free software: you can redistribute it and/or modify
it under the terms ... | gpl-3.0 | -5,528,214,279,090,128,000 | 29.822695 | 72 | 0.562356 | false | 3.630744 | false | false | false |
mmccollow/TSV-Convert | tsv-convert.py | 1 | 3059 | #!bin/python
# TSV to Dublin Core/McMaster Repository conversion tool
# Matt McCollow <mccollo@mcmaster.ca>, 2011
# Nick Ruest <ruestn@mcmaster.ca>, 2011
from DublinCore import DublinCore
import csv
from sys import argv
from xml.dom.minidom import Document
from os.path import basename
DC_NS = 'http://purl.org/dc/ele... | gpl-2.0 | -2,450,947,185,222,058,500 | 30.536082 | 73 | 0.686172 | false | 2.907795 | false | false | false |
martinmcbride/pytexture | generativepy/drawing.py | 1 | 5054 | # Author: Martin McBride
# Created: 2018-10-22
# Copyright (C) 2018, Martin McBride
# License: MIT
import cairo
import generativepy.utils
import numpy as np
# Text align
CENTER = 0
MIDDLE = 0
LEFT = 1
RIGHT = 2
TOP = 3
BOTTOM = 4
BASELINE = 5
# Fill rule
EVEN_ODD=0
WINDING=1
## Line cap/join
MITER = 0 # join
ROU... | mit | -5,907,448,772,282,604,000 | 28.383721 | 116 | 0.63514 | false | 3.445126 | false | false | false |
Gobberwart/PokemonGo-Bot | pokemongo_bot/item_list.py | 1 | 1311 | from enum import Enum
class Item(Enum):
ITEM_UNKNOWN = 0
ITEM_POKE_BALL = 1
ITEM_GREAT_BALL = 2
ITEM_ULTRA_BALL = 3
ITEM_MASTER_BALL = 4
ITEM_PREMIER_BALL = 5
ITEM_POTION = 101
ITEM_SUPER_POTION = 102
ITEM_HYPER_POTION = 103
ITEM_MAX_POTION = 104
ITEM_REVIVE = 201
ITEM_... | mit | -924,461,611,706,677,400 | 26.333333 | 42 | 0.649123 | false | 2.308099 | false | false | false |
nexdatas/writer | test/TangoDataWriterH5CppH5PY_test.py | 1 | 35643 | #!/usr/bin/env python
# This file is part of nexdatas - Tango Server for NeXus data writer
#
# Copyright (C) 2012-2017 DESY, Jan Kotanski <jkotan@mail.desy.de>
#
# nexdatas is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the ... | gpl-3.0 | -2,173,909,368,705,749,200 | 34.500996 | 79 | 0.53023 | false | 3.948488 | true | false | false |
fountainhead-gq/DjangoBlog | blog/models.py | 1 | 5201 | from django.db import models
from django.utils import timezone
from django.contrib.auth.models import User
from django.core.urlresolvers import reverse
from redactor.fields import RedactorField
classify = {
'L': u'life',
'E': u'essay',
'T': u'tech',
}
class TimeStampedModel(models.Model):
... | gpl-2.0 | 2,796,394,287,783,963,600 | 29.594118 | 97 | 0.622188 | false | 3.892964 | false | false | false |
mic4ael/indico | indico/modules/events/registration/testing/fixtures.py | 1 | 1404 | # This file is part of Indico.
# Copyright (C) 2002 - 2020 CERN
#
# Indico is free software; you can redistribute it and/or
# modify it under the terms of the MIT License; see the
# LICENSE file for more details.
import pytest
from indico.modules.events.registration.models.forms import RegistrationForm
from indico.mo... | mit | 3,934,519,085,892,562,400 | 30.909091 | 99 | 0.712963 | false | 3.825613 | false | false | false |
EMSTrack/WebServerAndClient | equipment/serializers.py | 1 | 1031 | from rest_framework import serializers
from .models import EquipmentItem, Equipment
class EquipmentItemSerializer(serializers.ModelSerializer):
equipment_name = serializers.CharField(source='equipment.name')
equipment_type = serializers.CharField(source='equipment.type')
class Meta:
model = Equi... | bsd-3-clause | -6,224,577,214,652,226,000 | 32.290323 | 79 | 0.608147 | false | 4.124 | false | false | false |
encorehu/nlp | nlp/tokenizers.py | 1 | 12503 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
__author__ = 'Encore Hu, <huyoo353@126.com>'
import sys
import os
import time
start = time.time()
def _tokenize(textline):
#print 'you call me'
for x in textline:
yield x
tokenize = _tokenize
class BaseChineseWordTokenizer(object):
'''针对一行短语进行处理, 比如... | mit | 1,453,879,232,745,696,500 | 27.755952 | 191 | 0.509161 | false | 2.220409 | false | false | false |
erudit/zenon | tests/unit/core/solrq/test_query.py | 1 | 4779 | import pytest
from core.solrq.query import Q
from core.solrq.query import Query
from core.solrq.search import Search
class TestQ:
def test_can_have_a_default_operator(self):
# Run & check
q = Q(foo='bar')
assert q.operator == 'AND'
def test_has_no_operands_by_default(self):
# ... | gpl-3.0 | 5,694,989,882,623,195,000 | 35.204545 | 99 | 0.565599 | false | 3.389362 | true | false | false |
bazelbuild/continuous-integration | buildkite/promote_images.py | 1 | 3310 | #!/usr/bin/env python3
#
# Copyright 2018 The Bazel 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 ... | apache-2.0 | -3,757,866,311,503,582,700 | 27.050847 | 98 | 0.618127 | false | 3.778539 | false | false | false |
ltworf/DiveShare | model.py | 1 | 4641 | from google.appengine.ext import ndb
import os
import random
class Photo(object):
def __init__(self):
self.delete_link = ''
self.small_thumb = ''
self.large_thumb = ''
self.link = ''
class Tag(ndb.Model):
dives = ndb.PickleProperty(indexed=False, default={})
@staticmet... | gpl-3.0 | -1,679,915,722,897,202,400 | 24.360656 | 113 | 0.561086 | false | 3.893456 | false | false | false |
gogoair/foremast | src/foremast/awslambda/cloudwatch_event/cloudwatch_event.py | 1 | 4267 | # Foremast - Pipeline Tooling
#
# Copyright 2018 Gogo, 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... | apache-2.0 | 6,094,322,534,027,160,000 | 37.790909 | 114 | 0.666042 | false | 3.954588 | false | false | false |
mikepatrick/robotframework-requests | src/RequestsLibrary/RequestsKeywords.py | 1 | 41638 | import json
import sys
import requests
import logging
from requests.packages.urllib3.util import Retry
import robot
from robot.api import logger
from robot.libraries.BuiltIn import BuiltIn
from RequestsLibrary.compat import httplib, urlencode, PY3
try:
from requests_ntlm import HttpNtlmAuth
except ImportError:
... | mit | 7,014,907,199,782,141,000 | 32.52496 | 182 | 0.537754 | false | 4.863684 | false | false | false |
jdfekete/progressivis | progressivis/io/csv_loader.py | 1 | 17616 | import pandas as pd
import logging
from progressivis import SlotDescriptor
from progressivis.utils.errors import (ProgressiveError,
ProgressiveStopIteration)
from ..table.module import TableModule
from ..table.table import Table
from ..table.dshape import (dshape_from_dataframe,
... | bsd-2-clause | -4,276,727,171,300,443,000 | 43.372796 | 118 | 0.534571 | false | 4.343195 | false | false | false |
BiaDarkia/scikit-learn | sklearn/utils/multiclass.py | 15 | 15208 | # Author: Arnaud Joly, Joel Nothman, Hamzeh Alsalhi
#
# License: BSD 3 clause
"""
Multi-class / multi-label utility function
==========================================
"""
from __future__ import division
from collections import Sequence
from itertools import chain
from scipy.sparse import issparse
from scipy.sparse.b... | bsd-3-clause | 1,152,036,645,373,883,400 | 32.946429 | 79 | 0.580484 | false | 3.694849 | false | false | false |
fastai/fastai | fastai/imports.py | 1 | 3419 | import numpy as np
import io,operator,sys,os,re,mimetypes,csv,itertools,json,shutil,glob,pickle,tarfile,collections
import hashlib,itertools,types,inspect,functools,random,time,math,bz2,typing,numbers,string
import multiprocessing,threading,urllib,tempfile,concurrent.futures,matplotlib,warnings,zipfile
from concurren... | apache-2.0 | 7,716,992,708,032,014,000 | 37.41573 | 96 | 0.74671 | false | 3.664523 | false | false | false |
SUNET/python-ndnkdf | src/ndnkdf/__init__.py | 1 | 2118 | #
# Copyright (c) 2012, 2013 NORDUnet A/S
# 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 copyright
# notice, this li... | bsd-3-clause | -7,215,919,763,447,450,000 | 34.898305 | 72 | 0.73135 | false | 3.816216 | false | false | false |
Jumpscale/jumpscale6_core | lib/JumpScale/base/REGEXTOOL.py | 1 | 1648 | from JumpScale import j
try:
import regex
except:
pass
class REGEXTOOL():
@staticmethod
def match(pattern,text):
m = regex.match(pattern,text)
if m:
print("%s %s"%(pattern,text))
return True
else:
return False
@static... | bsd-2-clause | -8,614,214,836,529,604,000 | 28.428571 | 155 | 0.589806 | false | 4.348285 | false | false | false |
bjornlevi/schulze | schulze.py | 1 | 5153 | """
Schulze STV voting implementation.
See https://en.wikipedia.org/wiki/Schulze_method
"""
from collections import defaultdict, OrderedDict
import random
def compute_strongest_paths(preference, candidates):
"""
input: preference
p[i,j] = number of voters that prefer candidate i to candidate j
in... | mit | -6,438,146,763,280,195,000 | 38.638462 | 125 | 0.568795 | false | 3.626319 | false | false | false |
pvarney/PiLN | daemon/pilnfired.py | 1 | 15200 | #!/usr/bin/env python
from signal import *
import os
import time
import math
import logging as L
import sys
import MySQLdb
import RPi.GPIO as GPIO
import Adafruit_MAX31855.MAX31855 as MAX31855
import RPi.GPIO as GPIO
from RPLCD import CharLCD
#Set up LCD
lcd = CharLCD(pin_rs=17, pin_rw=None, pin_e=27, pins_data=[12, ... | gpl-3.0 | 6,040,297,167,345,445,000 | 28.457364 | 247 | 0.555197 | false | 2.866843 | false | false | false |
nprapps/debates | fabfile/assets.py | 1 | 6629 | #!/usr/bin/env python
"""
Commands related to the syncing assets.
"""
from glob import glob
import logging
import os
from fabric.api import prompt, task
import app_config
from fnmatch import fnmatch
import utils
logging.basicConfig(format=app_config.LOG_FORMAT)
logger = logging.getLogger(__name__)
logger.setLevel(app... | mit | 1,686,975,917,946,847,000 | 26.057143 | 118 | 0.570674 | false | 3.820749 | true | false | false |
google/material-design-icons | update/venv/lib/python3.9/site-packages/fontTools/ttLib/tables/O_S_2f_2.py | 5 | 23193 | from fontTools.misc import sstruct
from fontTools.misc.textTools import safeEval, num2binary, binary2num
from fontTools.ttLib.tables import DefaultTable
import bisect
import logging
log = logging.getLogger(__name__)
# panose classification
panoseFormat = """
bFamilyType: B
bSerifStyle: B
bWeight: ... | apache-2.0 | -141,088,035,243,062,620 | 43.26145 | 85 | 0.535118 | false | 3.09984 | false | false | false |
pablobesada/tw | frontend/gnip/test.py | 1 | 1264 | from pprint import pprint
from pymongo import MongoClient
from bson import ObjectId
dbuser = "monitor"
dbpasswd = "monitor678"
remote = MongoClient("nuev9.com")['monitor']
remote.authenticate(dbuser, dbpasswd)
local = MongoClient()['monitor']
"""
laccs = set([x['_id'] for x in local.accounts.find()])
accs = remote.ac... | apache-2.0 | -5,769,455,968,632,922,000 | 31.435897 | 96 | 0.663766 | false | 2.569106 | false | false | false |
shashwatak/chuck-wagon-backend | trucks/views.py | 1 | 1201 | from django.shortcuts import render
from django.http import HttpResponse
from .models import Truck
LAT_LONG_FUZZ = 0.005797101448 # approx .4 miles
FEET_PER_DEGREE = 364099.0681813498
# Create your views here.
def index(request):
return render(request, 'hello.html')
def trucks(request):
trucks = Truck.obje... | gpl-3.0 | -6,657,405,993,322,035,000 | 26.295455 | 67 | 0.65945 | false | 2.958128 | false | false | false |
za-creature/fcc | fcc/ast/operators/int.py | 1 | 3327 | # coding=utf-8
from __future__ import absolute_import, unicode_literals, division
from fcc.ast.operators.base import (UnaryOperator, BinaryOperator,
AssignmentOperator)
from fcc.ast.expressions import CharExpression, IntExpression, FloatExpression
# -----------------
# integer oper... | unlicense | -8,202,716,135,644,627,000 | 21.632653 | 79 | 0.688909 | false | 4.337679 | false | false | false |
HipSTR-Tool/HipSTR | scripts/filter_vcf.py | 1 | 11290 | import argparse
import collections
import sys
try:
import vcf
except ImportError:
exit("This script requires the PyVCF python package. Please install using pip or conda")
def filter_call(sample, filters):
if sample['DP'] < filters.DEPTH:
return "Depth"
elif sample['Q'] < filters.QUAL:
... | gpl-2.0 | 9,099,733,576,770,183,000 | 47.454936 | 160 | 0.527547 | false | 3.722387 | false | false | false |
mottosso/pyblish-magenta | pyblish_magenta/tools/instance_creator/lib.py | 1 | 1902 | from maya import cmds
from pyblish_magenta.vendor import inflection
# (key, value, help)
defaults = [
("name", lambda name, family: name,
"Name of instance"),
("family", lambda name, family: family,
"Which family to associate this instance with"),
("label", lambda name, family: inflection.... | lgpl-3.0 | -3,646,201,553,883,579,400 | 25.416667 | 67 | 0.517876 | false | 3.714844 | false | false | false |
ndaniel/fusioncatcher | bin/generate_nontumor.py | 1 | 158997 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
It generates the list of candidate fusion genes found in non-tumor cell lines. This list is hard coded inhere.
Author: Daniel Nicorici, Daniel.Nicorici@gmail.com
Copyright (c) 2009-2021 Daniel Nicorici
This file is part of FusionCatcher.
FusionCatcher is free soft... | gpl-3.0 | -3,261,568,639,304,612,400 | 26.603646 | 186 | 0.386963 | false | 2.580576 | false | false | false |
abhikeshav/ydk-py | cisco-ios-xr/ydk/models/cisco_ios_xr/Cisco_IOS_XR_bundlemgr_cfg.py | 1 | 6336 | """ Cisco_IOS_XR_bundlemgr_cfg
This module contains a collection of YANG definitions
for Cisco IOS\-XR bundlemgr package configuration.
This module contains definitions
for the following management objects\:
lacp\: Link Aggregation Control Protocol commands
This YANG module augments the
Cisco\-IOS\-XR\-ifmgr\-c... | apache-2.0 | -7,104,942,310,826,735,000 | 16.454545 | 87 | 0.623737 | false | 3.626789 | true | false | false |
tucbill/manila | tools/install_venv_common.py | 1 | 6528 | # vim: tabstop=4 shiftwidth=4 softtabstop=4
# Copyright 2013 OpenStack Foundation
# Copyright 2013 IBM Corp.
#
# 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.a... | apache-2.0 | -1,564,941,276,478,537,500 | 34.672131 | 79 | 0.581648 | false | 4.230719 | true | false | false |
vanlink/horizonadn-ah | src/ah-pbulic-server-all.py | 1 | 14705 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import web
import hashlib
import pprint
import sys
import logging
import traceback
import getopt
import re
from web.wsgiserver import CherryPyWSGIServer
import json
import threading
import time
import sqlite3
from wechatpy import WeChatClient
from wechatpy... | mit | 2,592,928,378,081,887,000 | 28.449367 | 160 | 0.496848 | false | 3.607348 | false | false | false |
katyaeka2710/python2017005 | account/migrations/0001_initial.py | 1 | 3176 | # -*- coding: utf-8 -*-
# Generated by Django 1.10.2 on 2016-10-26 19:03
from __future__ import unicode_literals
from django.db import migrations, models
import django_countries.fields
import localflavor.us.models
class Migration(migrations.Migration):
initial = True
dependencies = [
('auth', '0008... | mit | 7,155,109,424,734,985,000 | 57.814815 | 266 | 0.616814 | false | 4.206623 | false | false | false |
j831/zulip | zerver/lib/validator.py | 1 | 5915 | '''
This module sets up a scheme for validating that arbitrary Python
objects are correctly typed. It is totally decoupled from Django,
composable, easily wrapped, and easily extended.
A validator takes two parameters--var_name and val--and returns an
error if val is not the correct type. The var_name parameter is u... | apache-2.0 | 2,532,096,731,441,559,000 | 34.848485 | 84 | 0.62164 | false | 3.753173 | false | false | false |
brocade/pysdn | pysdn/controller/topology.py | 1 | 11161 |
# Copyright (c) 2015, BROCADE COMMUNICATIONS SYSTEMS, 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:
# 1. Redistributions of source code must retain the above copyright notice,
# this list... | bsd-3-clause | -8,051,950,230,973,919,000 | 29.831492 | 79 | 0.533375 | false | 3.927164 | false | false | false |
mrb/letsencrypt | letsencrypt/cli.py | 1 | 53025 | """Let's Encrypt CLI."""
# TODO: Sanity check all input. Be sure to avoid shell code etc...
# pylint: disable=too-many-lines
# (TODO: split this file into main.py and cli.py)
import argparse
import atexit
import functools
import json
import logging
import logging.handlers
import os
import sys
import time
import traceb... | apache-2.0 | -6,334,446,810,511,934,000 | 40.13654 | 98 | 0.639811 | false | 4.128708 | true | false | false |
antong/ldaptor | ldaptor/ldapfilter.py | 1 | 8030 | #!/usr/bin/python
from ldaptor.protocols import pureldap
"""
RFC2254:
filter = "(" filtercomp ")"
filtercomp = and / or / not / item
and = "&" filterlist
or = "|" filterlist
not = "!" filter
filterlist = 1*filter
item = simple /... | lgpl-2.1 | 5,723,418,065,663,182,000 | 32.739496 | 92 | 0.6533 | false | 3.575245 | false | false | false |
erkyrath/tworld | lib/two/playconn.py | 1 | 6725 | """
Keep track of which players are connected.
Each player is connected through a tweb server, so each PlayerConnection
is associated with a WebConnIOStream. (In fact, the way tworld is currently
set up, each PlayerConnection is associated with the *same* WebConnIOStream.
We only have one.)
"""
from bson.objectid imp... | mit | 1,418,908,052,047,296,000 | 34.209424 | 106 | 0.609814 | false | 4.063444 | false | false | false |
RacingTadpole/cmsplugin-rt | cmsplugin_rt/mailchimp_form/migrations/0004_auto__add_field_mailchimppluginmodel_button_type__add_field_mailchimpp.py | 1 | 3857 | # -*- 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):
# Adding field 'MailChimpPluginModel.button_type'
db.add_column('cmsplugin_mailchimppluginmodel', 'button_ty... | bsd-3-clause | 7,277,686,300,299,009,000 | 60.222222 | 156 | 0.585948 | false | 3.708654 | false | false | false |
openstack/murano | murano/tests/unit/api/middleware/test_context.py | 1 | 1533 | # Copyright 2016 AT&T Corp
# 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 app... | apache-2.0 | -6,995,692,609,124,327,000 | 33.066667 | 78 | 0.666667 | false | 4.188525 | false | false | false |
chfast/ethereum-buildbot | factories/go_ethereum_brew.py | 1 | 10225 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
# @Author: caktux
# @Date: 2015-02-23 15:02:59
# @Last Modified by: caktux
# @Last Modified time: 2015-03-09 18:07:51
import factory
reload(factory)
from factory import *
import go_ethereum
reload(go_ethereum)
from go_ethereum import *
def brew_go_factory(branch='de... | mit | -5,094,150,608,297,526,000 | 39.904 | 233 | 0.488998 | false | 4.081836 | false | false | false |
dhrproject/mydatasink | DataSink/app/__init__.py | 1 | 2951 | #!/usr/bin/env python2.7
# -*- coding: utf-8 -*-
'''
__author__ = 'Chen Xin'
__mtime__ = '02/06/15'
'''
import json
from flask import Flask
from flask.ext.sqlalchemy import SQLAlchemy
from flask.ext.cors import CORS
from flask.ext.restful import Api
import requests
app = Flask(__name__)
# Read Config
app.config.fr... | mit | 2,759,722,022,251,597,000 | 24.008475 | 108 | 0.485937 | false | 3.929427 | true | false | false |
microsoft/O-CNN | tensorflow/script/dataset.py | 1 | 7070 | import sys
import tensorflow as tf
sys.path.append("..")
from libs import bounding_sphere, points2octree, \
transform_points, octree_batch, normalize_points
class ParseExample:
def __init__(self, x_alias='data', y_alias='label', **kwargs):
self.x_alias = x_alias
self.y_alias = y_alias
s... | mit | 5,516,572,128,594,647,000 | 39.867052 | 98 | 0.625601 | false | 3.482759 | false | false | false |
psidnell/Pythonista | Location2Waze.py | 1 | 1428 | '''
Copyright 2015 Paul Sidnell
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, software
dis... | apache-2.0 | 7,217,216,877,618,476,000 | 28.75 | 163 | 0.747899 | false | 3.201794 | false | false | false |
Julian/home-assistant | homeassistant/components/http.py | 1 | 18121 | """
This module provides WSGI application to serve the Home Assistant API.
For more details about this component, please refer to the documentation at
https://home-assistant.io/components/http/
"""
from datetime import timedelta
from socketserver import ThreadingMixIn
import gzip
import io
import hmac
import json
impo... | mit | -795,720,691,551,919,000 | 33.320076 | 79 | 0.611776 | false | 4.096993 | true | false | false |
google/google-ctf | 2017/finals/2017-finals-crypto-bender/checker/checker.py | 1 | 1993 | #!/usr/bin/python
#
# Copyright 2018 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 ag... | apache-2.0 | 2,344,141,404,474,814,500 | 38.078431 | 91 | 0.738585 | false | 3.79619 | false | false | false |
jralls/gramps | gramps/plugins/textreport/descendreport.py | 1 | 22311 | #
# Gramps - a GTK+/GNOME based genealogy program
#
# Copyright (C) 2000-2007 Donald N. Allingham
# Copyright (C) 2007-2012 Brian G. Matherly
# Copyright (C) 2009 Gary Burton
# Copyright (C) 2010 Jakim Friant
# Copyright (C) 2011 Matt Keenan (matt.keenan@gmail.com)
# Copyright (C) 2013-2014 Paul Fr... | gpl-2.0 | -2,551,960,627,922,837,500 | 35.816832 | 79 | 0.538703 | false | 4.02 | false | false | false |
ipmLessing/python | dicMerge.py | 1 | 1914 | #encoding:utf-8
import os, sys, time
start_time = time.time()
dicDirectory = sys.argv[1]
outPutFile = sys.argv[2]
outPutPath = dicDirectory + outPutFile
dicArray = []
dicName = []
merge = []
'''get all dictionary in specify directory'''
for file in os.listdir(dicDirectory):
if file.endswith(".txt"):
file... | mit | -4,568,438,988,740,218,000 | 29.380952 | 193 | 0.57001 | false | 3.618147 | false | false | false |
patillacode/twallery | src/python/listener/models.py | 1 | 4258 | # import os
# import sys
import json
import logging
from tweepy import OAuthHandler
from tweepy import Stream
from tweepy.streaming import StreamListener
import settings
# Variables that contains the user credentials to access Twitter API
from keys import ACCESS_TOKEN
from keys import ACCESS_TOKEN_SECRET
from keys i... | gpl-3.0 | 4,377,943,316,390,133,000 | 32.007752 | 80 | 0.565289 | false | 4.593312 | false | false | false |
hubugui/raindrop | 1/WXMessageBuilder.py | 1 | 2536 | #!/usr/bin/env python
# coding: utf-8
from cron.PictureDay import *
from WXMessage import *
class WXMessageBuilder:
def to_text(self, msgs, to_user, from_user, create_time):
xml_string = u"<xml>\n" \
"<ToUserName><![CDATA[{}]]></ToUserName>\n" \
"<... | mit | 8,995,059,588,212,141,000 | 40 | 93 | 0.415409 | false | 3.803625 | false | false | false |
mackst/myRandomStuff | plugins/clothNode.py | 1 | 51685 | # --------------------------------------------------------------------------------
# Copyright (c) 2018 Shi Chi(Mack Stone). All rights reserved.
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Soft... | mit | 4,351,887,734,593,054,000 | 42.396306 | 154 | 0.651098 | false | 4.049914 | false | false | false |
littlefisher/hackerrank_solution | algorithms/dynamic_programming/grid_walking/main.py | 1 | 3409 | #!/usr/bin/python3
# encoding: utf-8
"""
@author: Eric Wong
@license: MIT Licence
@contact: ericwong@zju.edu.cn
@file: main.py
@time: 2016-06-09 18:40
"""
import sys
DEBUG = 0
if DEBUG:
handler = open("./input")
else:
handler = sys.stdin
cases = int(handler.readline())
MOD = 1000000007
... | mit | 361,541,095,807,135,600 | 29.168142 | 98 | 0.596069 | false | 3.121795 | false | false | false |
seryl/Nodetraq | nodetraq/lib/util/csv_import.py | 1 | 2013 | import csv
import os
from nodetraq.model.meta import Session, metadata
from nodetraq.model.nodes import Node
node_replacements = [
('Hostname', 'hostname'),
('Service Tag', 'service_tag'),
('RACK', 'rack'),
('RACK U', 'rack_u'),
('Description', 'description'),
('Firmwar... | mit | -4,577,228,528,618,522,000 | 23.851852 | 51 | 0.517139 | false | 3.994048 | false | false | false |
jecki/MetaInductionSim | KommentarSimWindow.py | 1 | 36838 | # -*- coding: cp1252 -*-
#!/usr/bin/python
# Input / Output for the induction simulation
#Kommentar zeigt Verlauf an: Step-Nr. ist Schrittnummer
#Optionen:
# Option 1: import pylab siehe unten. Importiert Schnittstelle mit MatLab
# Kurvenzeichnungen
# Option 2: Non-MI-Mean-Out siehe unten. Per Default wird Non-MI-Mea... | mit | 8,185,489,996,396,594,000 | 37.213693 | 92 | 0.580298 | false | 3.205534 | false | false | false |
jtegge095/data-science-blog | mysite/settings.py | 1 | 3822 |
"""
Django settings for mysite project.
Generated by 'django-admin startproject' using Django 1.8.6.
For more information on this file, see
https://docs.djangoproject.com/en/1.8/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/1.8/ref/settings/
"""
# Build path... | mit | -8,005,019,610,050,254,000 | 27.744361 | 102 | 0.70853 | false | 3.27226 | false | false | false |
Doingcast/bizmem | hackdisrupt.py | 1 | 10615 | # -*- coding: utf-8 -*-
from flask import Flask, jsonify, Response
import requests
import os
from ConcurOAuthPython import getbasic, getTokenGivenUsernamePasswordAndConsumerKey
from BeautifulSoup import BeautifulSoup
from datetime import datetime, timedelta
import hashlib
import binascii
import time
from evernote.edam.... | mit | 137,472,883,628,352,000 | 34.033003 | 163 | 0.584456 | false | 3.186731 | false | false | false |
boundlessgeo/geogig-py | src/test/commitishtest.py | 1 | 2772 | # -*- coding: utf-8 -*-
"""
***************************************************************************
commitishtest.py
---------------------
Date : November 2013
Copyright : (C) 2013-2016 Boundless, http://boundlessgeo.com
***************************************************... | bsd-3-clause | -5,039,279,328,816,411,000 | 34.088608 | 99 | 0.540043 | false | 3.96 | true | false | false |
kaushik94/sympy | sympy/core/tests/test_count_ops.py | 2 | 4926 | from sympy import symbols, sin, exp, cos, Derivative, Integral, Basic, \
count_ops, S, And, I, pi, Eq, Or, Not, Xor, Nand, Nor, Implies, \
Equivalent, MatrixSymbol, Symbol, ITE, Rel, Rational
from sympy.core.containers import Tuple
x, y, z = symbols('x,y,z')
a, b, c = symbols('a,b,c')
def test_count_ops_non_v... | bsd-3-clause | -1,235,456,578,231,049,700 | 35.220588 | 74 | 0.542428 | false | 2.702139 | false | false | false |
FloatingGhost/skype4py | unittests/skypetest.py | 1 | 26039 | import unittest
import skype4pytest
from Skype4Py.skype import *
class SkypeTest(skype4pytest.TestCase):
def setUpObject(self):
self.obj = self.skype
# Methods
# =======
def testApiSecurityContextEnabled(self):
# Returned type: bool
def test():
self.obj.ApiSecuri... | bsd-3-clause | 895,281,112,601,408,300 | 35.165278 | 78 | 0.592842 | false | 3.841694 | true | false | false |
SINGROUP/pycp2k | pycp2k/classes/_each370.py | 1 | 1114 | from pycp2k.inputsection import InputSection
class _each370(InputSection):
def __init__(self):
InputSection.__init__(self)
self.Just_energy = None
self.Powell_opt = None
self.Qs_scf = None
self.Xas_scf = None
self.Md = None
self.Pint = None
self.Meta... | lgpl-3.0 | 6,709,575,968,300,664,000 | 41.846154 | 447 | 0.576302 | false | 2.908616 | false | false | false |
neosergio/WisdomBox | cards/migrations/0001_initial.py | 1 | 1818 | # -*- coding: utf-8 -*-
# Generated by Django 1.10.5 on 2017-02-09 19:53
from __future__ import unicode_literals
import cards.models
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
initial = True
dependencies ... | mit | -6,598,924,741,016,624,000 | 45.615385 | 116 | 0.59736 | false | 4.198614 | false | false | false |
scizen9/kpy | tests/check_delay_slew.py | 1 | 1845 | # -*- coding: utf-8 -*-
"""
Created on Fri Mar 24 12:57:27 2017
@author: nblago
"""
import numpy as np
from matplotlib import pylab as plt
from astropy.coordinates import SkyCoord
import astropy.units as u
def get_lag(f):
'''
Input file obtained by running:
gethead JD EXPTIME OBJECT EXPTIME RA DEC IMGTYP... | gpl-2.0 | -1,939,430,039,682,239,500 | 28.774194 | 121 | 0.592412 | false | 2.878315 | false | false | false |
mina19/approval_processorMP | test/virgoImplementation/ER11Data/ER11Data.py | 1 | 5105 | from eventDictClassMethods import *
from astropy.time import Time
client = "https://gracedb-test.ligo.org/api/"
g = initGraceDb(client)
# Get ER11 Data from 6/16 08:00:00 UTC to 6/26 08:00:00 UTC
query_string = "1181635218 .. 1182499218"
allEvents = g.events(query_string)
V1events = {}
injectionCommentTimes = {}
DQC... | mit | -7,448,482,596,400,924,000 | 28.171429 | 85 | 0.693242 | false | 3.160991 | false | false | false |
chatziko/mopidy-youtube | setup.py | 1 | 1453 | from __future__ import unicode_literals
import re
from setuptools import setup, find_packages
def get_version(filename):
content = open(filename).read()
metadata = dict(re.findall("__([a-z]+)__ = '([^']+)'", content))
return metadata['version']
setup(
name='Mopidy-Youtube',
version=get_version(... | apache-2.0 | 7,265,016,438,777,524,000 | 27.490196 | 68 | 0.578802 | false | 3.552567 | false | false | false |
tedunderwood/20cgenres | page/parallelizepagemodel.py | 1 | 2509 | # parallelize_model
# Script designed to parallelize trainamodel.py, especially for
# purposes of grid search to optimize parameters.
# This version has a couple of minor changes to make it work for page models
import csv
from multiprocessing import Pool
import matplotlib.pyplot as plt
import trainapagemodel as tmod... | mit | -3,472,678,632,750,104,000 | 29.228916 | 126 | 0.638103 | false | 3.413605 | false | false | false |
Parisson/TimeSide | timeside/plugins/analyzer/externals/vamp_plugin.py | 1 | 7366 | # -*- coding: utf-8 -*-
#
# Copyright (c) 2013 Paul Brossier <piem@piem.org>
# This file is part of TimeSide.
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the Lic... | agpl-3.0 | -6,080,188,044,774,914,000 | 32.788991 | 94 | 0.542493 | false | 4.206739 | false | false | false |
agripo/website | core/tests/models/test_shop.py | 1 | 12360 | from unittest.mock import Mock
from core.exceptions import AddedMoreToCartThanAvailable
from django.core.exceptions import ValidationError
from django.db import IntegrityError
from django.utils import timezone
from core.tests.base import CoreTestCase
from core.models.shop import ProductCategory, Product, DeliveryPoint... | gpl-2.0 | -7,535,492,923,438,539,000 | 38.615385 | 103 | 0.661974 | false | 3.728507 | true | false | false |
petpaulsen/formenheizung | app/control/controller.py | 1 | 3836 | import asyncio
import numpy as np
class ControllerBase:
def __init__(self, raspberry, relay, sample_time, shutdown_temperature):
self._raspberry = raspberry
self._relay = relay
self._stop_controller = False
self._measurement = []
self.sample_time = sample_time
self... | gpl-3.0 | 3,778,572,294,074,455,000 | 33.872727 | 107 | 0.60975 | false | 4.174102 | false | false | false |
igel-kun/pyload | module/plugins/hoster/SpeedvidNet.py | 1 | 2962 | # -*- coding: utf-8 -*-
import re
from module.plugins.internal.misc import parse_size
from module.plugins.internal.SimpleHoster import SimpleHoster
class SpeedvidNet(SimpleHoster):
__name__ = "SpeedvidNet"
__type__ = "hoster"
__version__ = "0.01"
__pattern__ = r"https?://(?:\w*\.)*(?P<DOMAIN>speedvid\... | gpl-3.0 | -3,507,372,722,897,977,000 | 44.569231 | 165 | 0.541526 | false | 3.444186 | false | false | false |
TechInvestLab/dot15926 | editor_qt/iso15926/graph/graph_view.py | 1 | 49178 | """
.15925 Editor
Copyright 2014 TechInvestLab.ru dot15926@gmail.com
.15925 Editor 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.0 of the License, or (at your option) any later version.... | lgpl-3.0 | -7,217,522,429,011,297,000 | 32.846524 | 239 | 0.55173 | false | 3.955123 | false | false | false |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.