repo_name stringlengths 5 100 | path stringlengths 4 299 | copies stringclasses 990
values | size stringlengths 4 7 | content stringlengths 666 1.03M | license stringclasses 15
values | hash int64 -9,223,351,895,964,839,000 9,223,297,778B | line_mean float64 3.17 100 | line_max int64 7 1k | alpha_frac float64 0.25 0.98 | autogenerated bool 1
class |
|---|---|---|---|---|---|---|---|---|---|---|
ZacariasBendeck/youtube-dl | youtube_dl/extractor/hentaistigma.py | 109 | 1201 | from __future__ import unicode_literals
from .common import InfoExtractor
class HentaiStigmaIE(InfoExtractor):
_VALID_URL = r'^https?://hentai\.animestigma\.com/(?P<id>[^/]+)'
_TEST = {
'url': 'http://hentai.animestigma.com/inyouchuu-etsu-bonus/',
'md5': '4e3d07422a68a4cc363d8f57c8bf0d23',
... | unlicense | 5,707,690,199,560,478,000 | 29.794872 | 69 | 0.509575 | false |
SauloAislan/ironic | ironic/tests/unit/drivers/test_utils.py | 3 | 16883 | # Copyright 2013 Hewlett-Packard Development Company, L.P.
# 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... | apache-2.0 | -8,670,711,354,964,153,000 | 43.196335 | 79 | 0.616952 | false |
Arcanemagus/plexpy | lib/dns/rdtypes/ANY/NSEC.py | 18 | 4690 | # Copyright (C) 2004-2007, 2009-2011 Nominum, Inc.
#
# Permission to use, copy, modify, and distribute this software and its
# documentation for any purpose with or without fee is hereby granted,
# provided that the above copyright notice and this permission notice
# appear in all copies.
#
# THE SOFTWARE IS PROVIDED "... | gpl-3.0 | 4,216,438,806,497,371,000 | 36.222222 | 76 | 0.575906 | false |
PyGotham/pygotham | pygotham/frontend/profile.py | 2 | 2262 | """PyGotham user profiles."""
from flask import (
Blueprint, flash, g, redirect, render_template, request, url_for
)
from flask_login import current_user
from flask_security import login_required
from pygotham.core import db
from pygotham.frontend import route
from pygotham.models import Talk, Volunteer
__all__ ... | bsd-3-clause | 3,880,330,524,057,142,300 | 28.763158 | 74 | 0.677719 | false |
wcalvert/LPC11U_LPC13U_CodeBase | src/drivers/sensors/testscripts/plot_xyz_plus_mag_sma.py | 2 | 3774 | #-------------------------------------------------------------------------------
# Name: plot_sensors_event.py
# Purpose: Plots logged sensors_event_t data from logger.c CSV files
#
# Author: K. Townsend
#
# Created: 09/06/2013
# Copyright: (c) K. Townsend 2013
# Licence: BSD
#----------------... | bsd-3-clause | 1,037,113,969,853,388,500 | 32.39823 | 99 | 0.579491 | false |
Openergy/oplus | setup.py | 1 | 1042 | from setuptools import setup, find_packages
from pkg_resources import parse_requirements
import os
with open(os.path.join("oplus", "version.py")) as f:
version = f.read().split("=")[1].strip().strip("'").strip('"')
with open("requirements.txt", "r") as f:
requirements = [str(r) for r in parse_requirements(f.... | mpl-2.0 | -5,161,642,850,197,494,000 | 31.5625 | 66 | 0.637236 | false |
lude-ma/python-ivi | ivi/agilent/agilentMSO6052A.py | 7 | 1687 | """
Python Interchangeable Virtual Instrument Library
Copyright (c) 2012-2014 Alex Forencich
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 Software without restriction, including without limitation the... | mit | -2,294,360,695,260,446,700 | 37.340909 | 86 | 0.736811 | false |
Alluxio/alluxio | integration/vagrant/bin/spot_request.py | 6 | 7965 | #!/usr/bin/env python
#
# The Alluxio Open Foundation licenses this work under the Apache License, version 2.0
# (the "License"). You may not use this work except in compliance with the License, which is
# available at www.apache.org/licenses/LICENSE-2.0
#
# This software is distributed on an "AS IS" basis, WITHOUT WAR... | apache-2.0 | -5,987,553,202,681,328,000 | 31.913223 | 129 | 0.629253 | false |
brandon-rhodes/numpy | numpy/polynomial/tests/test_printing.py | 208 | 2004 | from __future__ import division, absolute_import, print_function
import numpy.polynomial as poly
from numpy.testing import TestCase, run_module_suite, assert_
class test_str(TestCase):
def test_polynomial_str(self):
res = str(poly.Polynomial([0, 1]))
tgt = 'poly([0., 1.])'
assert_(res, tg... | bsd-3-clause | 8,789,086,979,464,637,000 | 26.081081 | 64 | 0.504491 | false |
CauldronDevelopmentLLC/buildbot | buildbot/test/test_svnpoller.py | 2 | 16276 | # -*- test-case-name: buildbot.test.test_svnpoller -*-
import time
from twisted.internet import defer
from twisted.trial import unittest
from buildbot.changes.svnpoller import SVNPoller
# this is the output of "svn info --xml
# svn+ssh://svn.twistedmatrix.com/svn/Twisted/trunk"
prefix_output = """\
<?xml version="1.0... | gpl-2.0 | 979,710,681,418,245,200 | 33.193277 | 139 | 0.642173 | false |
greg-hellings/ansible-modules-extras | monitoring/sensu_check.py | 42 | 11565 | #!/usr/bin/python
# -*- coding: utf-8 -*-
# (c) 2014, Anders Ingemann <aim@secoya.dk>
#
# This file is part of Ansible
#
# Ansible 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 Licen... | gpl-3.0 | 6,896,624,655,275,960,000 | 33.419643 | 104 | 0.570255 | false |
kushal124/gensim | gensim/test/test_utils.py | 53 | 2863 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# Licensed under the GNU LGPL v2.1 - http://www.gnu.org/licenses/lgpl.html
"""
Automated tests for checking various utils functions.
"""
import logging
import unittest
from gensim import utils
class TestIsCorpus(unittest.TestCase):
def test_None(self):
#... | gpl-3.0 | -8,537,000,927,375,444,000 | 31.908046 | 89 | 0.613343 | false |
randynobx/ansible | test/runner/lib/changes.py | 57 | 5755 | """Detect changes in Ansible code."""
from __future__ import absolute_import, print_function
import re
import os
from lib.util import (
ApplicationError,
SubprocessError,
MissingEnvironmentVariable,
CommonConfig,
display,
)
from lib.http import (
HttpClient,
urlencode,
)
from lib.git im... | gpl-3.0 | -4,119,838,988,702,826,500 | 31.331461 | 108 | 0.57967 | false |
suninsky/ReceiptOCR | Python/server/lib/python2.7/site-packages/werkzeug/http.py | 85 | 36658 | # -*- coding: utf-8 -*-
"""
werkzeug.http
~~~~~~~~~~~~~
Werkzeug comes with a bunch of utilities that help Werkzeug to deal with
HTTP data. Most of the classes and functions provided by this module are
used by the wrappers, but they are useful on their own, too, especially if
the response and ... | mit | -1,931,132,630,411,118,000 | 33.777989 | 83 | 0.598783 | false |
UManPychron/pychron | pychron/file_defaults.py | 2 | 11951 | # ===============================================================================
# Copyright 2015 Jake Ross
#
# 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... | apache-2.0 | 4,311,021,293,203,045,000 | 25.616927 | 88 | 0.633336 | false |
nomadcube/scikit-learn | sklearn/decomposition/incremental_pca.py | 199 | 10508 | """Incremental Principal Components Analysis."""
# Author: Kyle Kastner <kastnerkyle@gmail.com>
# License: BSD 3 clause
import numpy as np
from scipy import linalg
from .base import _BasePCA
from ..utils import check_array, gen_batches
from ..utils.extmath import svd_flip, _batch_mean_variance_update
class Increme... | bsd-3-clause | 7,555,955,023,578,288,000 | 40.207843 | 80 | 0.606681 | false |
supriyantomaftuh/django | tests/staticfiles_tests/test_storage.py | 147 | 18183 | from __future__ import unicode_literals
import os
import sys
import unittest
from django.conf import settings
from django.contrib.staticfiles import finders, storage
from django.contrib.staticfiles.management.commands import collectstatic
from django.contrib.staticfiles.management.commands.collectstatic import \
... | bsd-3-clause | -3,708,478,434,379,620,400 | 42.709135 | 118 | 0.670461 | false |
MiltosD/CEFELRC | lib/python2.7/site-packages/django/db/models/sql/constants.py | 394 | 1043 | import re
# Valid query types (a dictionary is used for speedy lookups).
QUERY_TERMS = dict([(x, None) for x in (
'exact', 'iexact', 'contains', 'icontains', 'gt', 'gte', 'lt', 'lte', 'in',
'startswith', 'istartswith', 'endswith', 'iendswith', 'range', 'year',
'month', 'day', 'week_day', 'isnull', 'search'... | bsd-3-clause | 3,794,071,409,986,952,700 | 27.189189 | 79 | 0.649089 | false |
multigcs/quadfork | Libraries/Mavlink/pymavlink/generator/lib/minixsv/minixsvWrapper.py | 79 | 2400 | #!/usr/local/bin/python
import sys
import getopt
from ..genxmlif import GenXmlIfError
from xsvalErrorHandler import ErrorHandler, XsvalError
from ..minixsv import *
from pyxsval import parseAndValidate
##########################################
# minixsv Wrapper for calling mi... | gpl-3.0 | 1,943,417,319,065,918,200 | 29.578947 | 86 | 0.5275 | false |
aerler/Ensemble | src/ensemble/ensemble_test.py | 1 | 8702 | '''
Created on 2013-08-24
Unittest for the GeoPy main package geodata.
@author: Andre R. Erler, GPL v3
'''
import unittest
import netCDF4 as nc
import numpy as np
import numpy.ma as ma
import scipy.stats as ss
import os
import gc
from copy import deepcopy
import shutil
# internal imports
# from ensemble.base impor... | gpl-3.0 | 3,458,317,141,232,719,400 | 33.395257 | 99 | 0.591588 | false |
mwcraig/ccdproc | ccdproc/tests/test_cosmicray.py | 2 | 10917 | # Licensed under a 3-clause BSD style license - see LICENSE.rst
import numpy as np
from numpy.testing import assert_allclose
import pytest
from astropy.utils import NumpyRNGContext
from astropy.nddata import StdDevUncertainty
from astropy import units as u
from ccdproc.core import (cosmicray_lacosmic, cosmicray_medi... | bsd-3-clause | 3,243,147,568,152,654,000 | 35.881757 | 77 | 0.635339 | false |
transientskp/aartfaac-arthur | scripts/arthur-plot.py | 1 | 1440 | #!/usr/bin/env python3
import sys
import numpy as np
from arthur.imaging import full_calculation, calculate_lag
from arthur.io import read_full
from arthur.plot import plot_image, plot_lag, plot_chan_power, plot_corr_mat, plot_diff
from arthur.constants import NUM_CHAN
from matplotlib import pyplot
FRQ = 58398437.5 ... | gpl-3.0 | 7,387,992,118,067,336,000 | 31 | 87 | 0.63125 | false |
seiji56/rmaze-2016 | testes/sharp.py | 1 | 1113 | import time
import Adafruit_ADS1x15
import sys
addr = 0
def convert( aString ):
if aString.startswith("0x") or aString.startswith("0X"):
return int(aString,16)
elif aString.startswith("0"):
return int(aString,8)
else:
return int(aString)
milli_time = lambda: int(round(time.time() ... | gpl-3.0 | -4,920,968,997,997,010,000 | 23.733333 | 99 | 0.573226 | false |
mbr/unleash | tests/test_depgraph.py | 1 | 1538 | import pytest
from unleash.depgraph import DependencyGraph
@pytest.fixture
def dg():
# our example dependency graph. it looks like this
#
# D -> B
# \
# A E -> F
# /
# C
g = DependencyGraph()
g.add_obj('D', ['B'])
g.add_obj('B', ['A'])
g.add_obj... | mit | 8,220,235,134,665,998,000 | 19.783784 | 57 | 0.550715 | false |
cstipkovic/spidermonkey-research | testing/marionette/harness/marionette/tests/unit/test_addons.py | 1 | 1985 | # This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
import os
import unittest
from marionette import MarionetteTestCase
from marionette_driver.addons import Addons, AddonI... | mpl-2.0 | 3,420,210,611,468,736,500 | 33.224138 | 81 | 0.654408 | false |
jimbobhickville/libcloud | libcloud/test/compute/test_vcloud.py | 33 | 32420 | # Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use ... | apache-2.0 | -5,506,104,586,087,110,000 | 44.216179 | 119 | 0.631956 | false |
GoogleCloudPlatform/sap-deployment-automation | third_party/github.com/ansible/awx/awx_collection/plugins/modules/tower_credential.py | 1 | 13502 | #!/usr/bin/python
# coding: utf-8 -*-
# Copyright: (c) 2017, Wayne Witzel III <wayne@riotousliving.com>
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
from __future__ import absolute_import, division, print_function
__metaclass__ = type
ANSIBLE_METADATA = {'metadata_ver... | apache-2.0 | -317,633,327,197,229,200 | 30.620609 | 150 | 0.63598 | false |
paweljasinski/ironpython3 | Src/StdLib/Lib/multiprocessing/semaphore_tracker.py | 5 | 4863 | #
# On Unix we run a server process which keeps track of unlinked
# semaphores. The server ignores SIGINT and SIGTERM and reads from a
# pipe. Every other process of the program has a copy of the writable
# end of the pipe, so we get EOF when all other processes have exited.
# Then the server process unlinks any remai... | apache-2.0 | -3,411,210,705,306,444,000 | 32.537931 | 79 | 0.557269 | false |
benbox69/pyload | module/plugins/internal/Extractor.py | 6 | 4390 | # -*- coding: utf-8 -*-
import os
import re
from module.PyFile import PyFile
from module.plugins.internal.Plugin import Plugin
class ArchiveError(Exception):
pass
class CRCError(Exception):
pass
class PasswordError(Exception):
pass
class Extractor(Plugin):
__name__ = "Extractor"
__type_... | gpl-3.0 | 5,119,132,440,145,374,000 | 23.80226 | 118 | 0.549658 | false |
xodus7/tensorflow | tensorflow/python/autograph/utils/type_check.py | 26 | 1170 | # Copyright 2016 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 | -2,660,473,299,974,355,000 | 34.454545 | 80 | 0.692308 | false |
yanheven/keystone | keystone/common/wsgi.py | 3 | 31025 | # Copyright 2012 OpenStack Foundation
# Copyright 2010 United States Government as represented by the
# Administrator of the National Aeronautics and Space Administration.
# Copyright 2010 OpenStack Foundation
# All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not... | apache-2.0 | -321,072,724,926,001,100 | 36.651699 | 79 | 0.595133 | false |
magic2du/contact_matrix | Contact_maps/DeepLearning/DeepLearningTool/DL_contact_matrix_load2-new10fold_01_09_2015_01.py | 1 | 25014 |
# coding: utf-8
# In[1]:
# this part imports libs and load data from csv file
import sys
sys.path.append('../../../libs/')
import csv
from dateutil import parser
from datetime import timedelta
from sklearn import svm
import numpy as np
import pandas as pd
import pickle
from sklearn.cross_validation import train_test... | gpl-2.0 | -2,474,494,673,687,344,600 | 46.375 | 258 | 0.611378 | false |
maizy/ambient7 | ambient7-arduino/serial2influxdb/serial2influxdb.py | 1 | 4275 | #!/usr/bin/env python3
# coding: utf-8
import argparse
import configparser
import logging
import time
import re
import datetime
import serial
import influxdb
SERIAL_RETRY_DELAY = 5.0
logger = logging.getLogger('s2i')
def parse_args_and_config(args):
parser = argparse.ArgumentParser(description='ambient7 - ser... | apache-2.0 | 4,087,495,277,312,809,500 | 29.319149 | 102 | 0.553684 | false |
mannygit/zerorpc-python | zerorpc/events.py | 51 | 9209 | # -*- coding: utf-8 -*-
# Open Source Initiative OSI - The MIT License (MIT):Licensing
#
# The MIT License (MIT)
# Copyright (c) 2012 DotCloud Inc (opensource@dotcloud.com)
#
# Permission is hereby granted, free of charge, to any person obtaining a copy of
# this software and associated documentation files (the "Softwa... | mit | 2,456,981,820,384,678,400 | 28.802589 | 83 | 0.5689 | false |
yaroslavvb/tensorflow | tensorflow/contrib/learn/python/learn/dataframe/estimator_utils.py | 75 | 7274 | # pylint: disable=g-bad-file-header
# Copyright 2016 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/LICENS... | apache-2.0 | 520,605,405,067,000,260 | 40.329545 | 80 | 0.668683 | false |
Arable/old-www-do-not-use | lib/python2.7/site-packages/requests/packages/urllib3/_collections.py | 310 | 3111 | # urllib3/_collections.py
# Copyright 2008-2013 Andrey Petrov and contributors (see CONTRIBUTORS.txt)
#
# This module is part of urllib3 and is released under
# the MIT License: http://www.opensource.org/licenses/mit-license.php
from collections import MutableMapping
try:
from threading import RLock
except ImportE... | mit | -5,688,311,323,667,925,000 | 29.203883 | 92 | 0.620058 | false |
psychopy/versions | psychopy/app/utils.py | 1 | 17380 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
# Part of the PsychoPy library
# Copyright (C) 2002-2018 Jonathan Peirce (C) 2019-2020 Open Science Tools Ltd.
# Distributed under the terms of the GNU General Public License (GPL).
"""utility classes for the Builder
"""
from __future__ import absolute_import, division, ... | gpl-3.0 | 2,146,391,062,270,683,000 | 39.798122 | 116 | 0.531243 | false |
netscaler/horizon | openstack_dashboard/dashboards/project/firewalls/tests.py | 5 | 19627 | # vim: tabstop=4 shiftwidth=4 softtabstop=4
# Copyright 2013, Big Switch Networks, 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/... | apache-2.0 | 7,097,110,327,593,757,000 | 36.744231 | 79 | 0.556478 | false |
foursquare/pants | src/python/pants/backend/jvm/tasks/jvm_compile/execution_graph.py | 1 | 11698 | # coding=utf-8
# Copyright 2015 Pants project contributors (see CONTRIBUTORS.md).
# Licensed under the Apache License, Version 2.0 (see LICENSE).
from __future__ import absolute_import, division, print_function, unicode_literals
import queue
import sys
import threading
import traceback
from builtins import map, objec... | apache-2.0 | 1,957,824,382,805,941,500 | 32.711816 | 111 | 0.653103 | false |
foursquare/pants | tests/python/pants_test/backend/jvm/tasks/test_jvmdoc_gen.py | 2 | 1845 | # coding=utf-8
# Copyright 2014 Pants project contributors (see CONTRIBUTORS.md).
# Licensed under the Apache License, Version 2.0 (see LICENSE).
from __future__ import absolute_import, division, print_function, unicode_literals
import os
from pants.backend.jvm.tasks.jvmdoc_gen import Jvmdoc, JvmdocGen
from pants.ba... | apache-2.0 | -4,552,293,231,459,239,000 | 27.828125 | 82 | 0.716531 | false |
xyuanmu/XX-Net | code/default/x_tunnel/local/cloudfront_front/web_control.py | 4 | 5336 | #!/usr/bin/env python
# coding:utf-8
import os
import time
import urllib.parse
import simple_http_server
from .front import front
current_path = os.path.dirname(os.path.abspath(__file__))
root_path = os.path.abspath(os.path.join(current_path, os.pardir, os.pardir))
top_path = os.path.abspath(os.path.join(root_path... | bsd-2-clause | 4,726,747,232,259,229,000 | 37.121429 | 127 | 0.529048 | false |
lz1988/company-site | django/contrib/sites/management.py | 232 | 1587 | """
Creates the default Site object.
"""
from django.db.models import signals
from django.db import connections
from django.db import router
from django.contrib.sites.models import Site
from django.contrib.sites import models as site_app
from django.core.management.color import no_style
def create_default_site(app, c... | bsd-3-clause | 8,895,923,184,502,504,000 | 43.083333 | 81 | 0.674858 | false |
ruuk/script.module.youtube.dl | lib/youtube_dl/extractor/urort.py | 64 | 2249 | # coding: utf-8
from __future__ import unicode_literals
from .common import InfoExtractor
from ..compat import (
compat_urllib_parse,
)
from ..utils import (
unified_strdate,
)
class UrortIE(InfoExtractor):
IE_DESC = 'NRK P3 Urørt'
_VALID_URL = r'https?://(?:www\.)?urort\.p3\.no/#!/Band/(?P<id>[^/]+)... | gpl-2.0 | 6,488,771,619,845,157,000 | 33.060606 | 132 | 0.483096 | false |
sdopoku/flask-blog | env/lib/python2.7/site-packages/pip/_vendor/requests/packages/charade/utf8prober.py | 2919 | 2652 | ######################## BEGIN LICENSE BLOCK ########################
# The Original Code is mozilla.org code.
#
# The Initial Developer of the Original Code is
# Netscape Communications Corporation.
# Portions created by the Initial Developer are Copyright (C) 1998
# the Initial Developer. All Rights Reserved.
#
# Con... | gpl-2.0 | 1,224,546,314,913,529,600 | 33.894737 | 69 | 0.633107 | false |
Ted1993/Flasky | venv/lib/python2.7/site-packages/mako/ext/turbogears.py | 39 | 2132 | # ext/turbogears.py
# Copyright (C) 2006-2015 the Mako authors and contributors <see AUTHORS file>
#
# This module is part of Mako and is released under
# the MIT License: http://www.opensource.org/licenses/mit-license.php
from mako import compat
from mako.lookup import TemplateLookup
from mako.template import Templat... | mit | 8,990,383,964,585,528,000 | 35.758621 | 79 | 0.625235 | false |
telerik/cloudbase-init | cloudbaseinit/openstack/common/notifier/rabbit_notifier.py | 1 | 1108 | # Copyright 2012 Red Hat, Inc.
# 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... | apache-2.0 | 3,942,909,638,147,022,000 | 37.206897 | 78 | 0.728339 | false |
AlexBoogaard/Sick-Beard-Torrent-Edition | lib/unidecode/x0b5.py | 253 | 4919 | data = (
'dyil', # 0x00
'dyilg', # 0x01
'dyilm', # 0x02
'dyilb', # 0x03
'dyils', # 0x04
'dyilt', # 0x05
'dyilp', # 0x06
'dyilh', # 0x07
'dyim', # 0x08
'dyib', # 0x09
'dyibs', # 0x0a
'dyis', # 0x0b
'dyiss', # 0x0c
'dying', # 0x0d
'dyij', # 0x0e
'dyic', # 0x0f
'dyik', # ... | gpl-3.0 | -5,185,665,382,399,024,000 | 18.065891 | 20 | 0.478146 | false |
DazWorrall/ansible | lib/ansible/modules/network/avi/avi_snmptrapprofile.py | 27 | 3396 | #!/usr/bin/python
#
# Created on Aug 25, 2016
# @author: Gaurav Rastogi (grastogi@avinetworks.com)
# Eric Anderson (eanderson@avinetworks.com)
# module_check: supported
#
#
# This file is part of Ansible
#
# Ansible is free software: you can redistribute it and/or modify
# it under the terms of the GNU General... | gpl-3.0 | -275,794,914,653,128,060 | 29.321429 | 77 | 0.651649 | false |
quodlibet/quodlibet | tests/test_pattern.py | 4 | 24758 | # 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 later version.
import os
from senf import fsnative
from tests import TestCase
from ... | gpl-2.0 | 6,373,307,308,129,381,000 | 41.515464 | 79 | 0.533988 | false |
c0hen/django-venv | lib/python3.4/site-packages/psycopg2/pool.py | 3 | 8136 | """Connection pooling for psycopg2
This module implements thread-safe (and not) connection pools.
"""
# psycopg/pool.py - pooling code for psycopg
#
# Copyright (C) 2003-2010 Federico Di Gregorio <fog@debian.org>
#
# psycopg2 is free software: you can redistribute it and/or modify it
# under the terms of the GNU Less... | gpl-3.0 | 513,129,088,310,076,300 | 33.621277 | 78 | 0.60263 | false |
Darthkpo/xtt | openpyxl/tests/test_backend.py | 4 | 2038 | #
# 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 Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# co... | mit | 8,471,415,294,556,642,000 | 33.542373 | 79 | 0.736997 | false |
InterfaceMasters/ONL | components/all/vendor-config/qemu/src/python/qemu/__init__.py | 9 | 1313 | #!/usr/bin/python
############################################################
# <bsn.cl fy=2013 v=onl>
#
# Copyright 2013, 2014 Big Switch Networks, Inc.
#
# Licensed under the Eclipse Public License, Version 1.0 (the
# "License"); you may not use this file except in compliance
# with the License. You ... | epl-1.0 | -6,204,466,505,490,720,000 | 28.840909 | 62 | 0.593298 | false |
shipci/boto | tests/unit/vpc/test_customergateway.py | 114 | 4610 | from tests.compat import OrderedDict
from tests.unit import unittest
from tests.unit import AWSMockServiceTestCase
from boto.vpc import VPCConnection, CustomerGateway
class TestDescribeCustomerGateways(AWSMockServiceTestCase):
connection_class = VPCConnection
def default_body(self):
return b"""
... | mit | 2,568,950,329,228,620,300 | 39.086957 | 95 | 0.580694 | false |
vim-IDE/python-mode | pymode/libs/_markerlib/markers.py | 1769 | 3979 | # -*- coding: utf-8 -*-
"""Interpret PEP 345 environment markers.
EXPR [in|==|!=|not in] EXPR [or|and] ...
where EXPR belongs to any of those:
python_version = '%s.%s' % (sys.version_info[0], sys.version_info[1])
python_full_version = sys.version.split()[0]
os.name = os.name
sys.platform = sys.platfo... | lgpl-3.0 | 4,987,659,097,569,394,000 | 32.436975 | 106 | 0.621262 | false |
jayceyxc/hue | desktop/core/ext-py/tablib-0.10.0/tablib/packages/openpyxl/writer/dump_worksheet.py | 61 | 8158 | # file openpyxl/writer/straight_worksheet.py
# Copyright (c) 2010 openpyxl
#
# 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 Software without restriction, including without limitation the rights
# to... | apache-2.0 | 8,361,752,331,826,589,000 | 30.867188 | 114 | 0.599657 | false |
ApolloAuto/apollo | third_party/gpus/check_cuda_libs.py | 3 | 2904 | # Copyright 2020 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 | -2,862,822,080,672,765,400 | 33.571429 | 83 | 0.692149 | false |
slava-sh/NewsBlur | vendor/readability/cleaners.py | 13 | 1199 | # strip out a set of nuisance html attributes that can mess up rendering in RSS feeds
import re
from lxml.html.clean import Cleaner
bad_attrs = ['style', '[-a-z]*color', 'background[-a-z]*', 'on*']
single_quoted = "'[^']+'"
double_quoted = '"[^"]+"'
non_space = '[^ "\'>]+'
htmlstrip = re.compile("<" # open
"([^>]+... | mit | 1,016,075,113,468,532,400 | 36.46875 | 85 | 0.59633 | false |
polyaxon/polyaxon | core/polyaxon/polypod/common/container_resources.py | 1 | 1492 | #!/usr/bin/python
#
# Copyright 2018-2021 Polyaxon, 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 ... | apache-2.0 | -2,722,190,665,310,583,300 | 31.434783 | 74 | 0.691019 | false |
leapcode/bitmask-dev | tests/integration/mail/outgoing/test_outgoing.py | 1 | 9783 | # -*- coding: utf-8 -*-
# test_gateway.py
# Copyright (C) 2013 LEAP
#
# 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.
#
... | gpl-3.0 | -2,455,723,392,723,195,400 | 38.289157 | 79 | 0.580088 | false |
rvraghav93/scikit-learn | sklearn/feature_extraction/tests/test_text.py | 8 | 35969 | from __future__ import unicode_literals
import warnings
from sklearn.feature_extraction.text import strip_tags
from sklearn.feature_extraction.text import strip_accents_unicode
from sklearn.feature_extraction.text import strip_accents_ascii
from sklearn.feature_extraction.text import HashingVectorizer
from sklearn.fe... | bsd-3-clause | 3,974,509,567,453,235,000 | 35.891282 | 79 | 0.636576 | false |
xgds/xgds_core | setup.py | 1 | 1649 | # __BEGIN_LICENSE__
# Copyright (c) 2015, United States Government, as represented by the
# Administrator of the National Aeronautics and Space Administration.
# All rights reserved.
#
# The xGDS platform is licensed under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance... | apache-2.0 | -489,253,708,743,833,800 | 33.354167 | 83 | 0.688902 | false |
40423126/2016fallcadp_ag9 | plugin/liquid_tags/mdx_liquid_tags.py | 281 | 3447 | """
Markdown Extension for Liquid-style Tags
----------------------------------------
A markdown extension to allow user-defined tags of the form::
{% tag arg1 arg2 ... argn %}
Where "tag" is associated with some user-defined extension.
These result in a preprocess step within markdown that produces
either markdo... | agpl-3.0 | 6,307,572,002,454,985,000 | 34.173469 | 77 | 0.591529 | false |
f-guichard/cf-sample-php-buildpack-custo | extensions/composer/extension.py | 6 | 16424 | # Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use ... | apache-2.0 | -3,752,372,668,106,999,300 | 37.644706 | 174 | 0.555102 | false |
pipermerriam/django | django/contrib/auth/migrations/0001_initial.py | 108 | 4524 | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
import django.contrib.auth.models
from django.core import validators
from django.db import migrations, models
from django.utils import timezone
class Migration(migrations.Migration):
dependencies = [
('contenttypes', '__first__'),
]
... | bsd-3-clause | -5,594,721,615,096,761,000 | 54.851852 | 277 | 0.580239 | false |
blackye/luscan-devel | thirdparty_libs/yaml/parser.py | 409 | 25542 |
# The following YAML grammar is LL(1) and is parsed by a recursive descent
# parser.
#
# stream ::= STREAM-START implicit_document? explicit_document* STREAM-END
# implicit_document ::= block_node DOCUMENT-END*
# explicit_document ::= DIRECTIVE* DOCUMENT-START block_node? DOCUMENT-END*
# block_node_or_inden... | gpl-2.0 | -5,762,860,175,286,385,000 | 42.365025 | 156 | 0.561467 | false |
allinpaybusiness/ACS | allinpay projects/creditscoreMLP/classMLP.py | 1 | 9585 | # -*- coding: utf-8 -*-
"""
Spyder Editor
This is a temporary script file.
"""
import sys;
import os;
sys.path.append("allinpay projects")
from creditscore.creditscore import CreditScore
import numpy as np
import pandas as pd
import time
from sklearn.model_selection import train_test_split
from sklearn.linear_model ... | apache-2.0 | 361,407,939,134,608,700 | 46.547872 | 169 | 0.602305 | false |
silizium/ardupilot | Tools/scripts/frame_sizes.py | 351 | 1117 | #!/usr/bin/env python
import re, sys, operator, os
code_line = re.compile("^\s*\d+:/")
frame_line = re.compile("^\s*\d+\s+/\* frame size = (\d+) \*/")
class frame(object):
def __init__(self, code, frame_size):
self.code = code
self.frame_size = int(frame_size)
frames = []
def process_lst(filena... | gpl-3.0 | 6,439,051,330,673,832,000 | 24.386364 | 76 | 0.557744 | false |
mlperf/training_results_v0.7 | SIAT/benchmarks/resnet/implementations/tensorflow_open_src/resnet.py | 1 | 21852 | import tensorflow as tf
# from mlperf_compliance import mlperf_log
# from mlperf_compliance import resnet_log_helper
# from configs.res50.res50_config import res50_config
_BATCH_NORM_EPSILON = 1e-4
_BATCH_NORM_DECAY = 0.9
ML_PERF_LOG=False
class LayerBuilder(object):
def __init__(self, activation=None, data_form... | apache-2.0 | 8,897,350,612,938,748,000 | 43.571429 | 141 | 0.556227 | false |
surchs/brainbox | visu/base.py | 1 | 8414 | __author__ = 'surchs'
import sys
import numpy as np
from matplotlib import gridspec
from nilearn import plotting as nlp
from matplotlib import pyplot as plt
from matplotlib import colors as mpc
def add_subplot_axes(ax, rect, axisbg='w'):
fig = plt.gcf()
box = ax.get_position()
width = box.width
height... | mit | -8,054,908,546,902,702,000 | 31.996078 | 79 | 0.54445 | false |
jvs/sourcer | sourcer/expressions/str.py | 1 | 1444 | from outsourcer import Code
from . import utils
from .base import Expression
from .constants import POS, RESULT, STATUS, TEXT
class Str(Expression):
is_commented = False
def __init__(self, value):
if not isinstance(value, (bytes, str)):
raise TypeError(f'Expected bytes or str. Received: ... | mit | 1,280,094,630,958,975,700 | 27.313725 | 81 | 0.572715 | false |
rhiever/bokeh | sphinx/source/docs/tutorials/exercises/unemployment.py | 23 | 2160 | import numpy as np
from bokeh.models import HoverTool
from bokeh.plotting import ColumnDataSource, figure, output_file, show
from bokeh.sampledata.unemployment1948 import data
# Read in the data with pandas. Convert the year column to string
data['Year'] = [str(x) for x in data['Year']]
years = list(data['Year'])
mon... | bsd-3-clause | 8,508,792,494,792,177,000 | 30.304348 | 82 | 0.662963 | false |
heiher/libreoffice-core | scripting/examples/python/HelloWorld.py | 12 | 1539 | # HelloWorld python script for the scripting framework
#
# This file is part of the LibreOffice project.
#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#
# This file... | gpl-3.0 | -6,799,308,032,610,818,000 | 41.75 | 78 | 0.730344 | false |
abrowning80/solutions-geoevent-java | data/packages/geoprocessing/visibility/Toolshare/scripts/makefeature.py | 6 | 1382 | #-------------------------------------------------------------------------------
# Name: module2
# Purpose:
#
# Author: patr5136
#
# Created: 23/08/2013
# Copyright: (c) patr5136 2013
# Licence: <your licence>
#-------------------------------------------------------------------------------
import ... | apache-2.0 | 2,700,602,174,642,429,400 | 26.098039 | 87 | 0.48987 | false |
ccarouge/cwsl-mas | cwsl/core/file_creator.py | 4 | 11088 | """
Authors: Tim Bedin, Tim Erwin
Copyright 2014 CSIRO
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,285,513,506,962,864,000 | 34.652733 | 103 | 0.602273 | false |
knxd/PyKNyX | tests/core/dptXlator/dptXlator2ByteFloat.py | 2 | 2328 | # -*- coding: utf-8 -*-
from pyknyx.core.dptXlator.dptXlator2ByteFloat import *
import unittest
# Mute logger
from pyknyx.services.logger import logging
logger = logging.getLogger(__name__)
logging.getLogger("pyknyx").setLevel(logging.ERROR)
class DPTXlator2ByteFloatTestCase(unittest.TestCase):
def setUp(self):... | gpl-3.0 | -735,284,505,910,309,400 | 37.163934 | 114 | 0.57646 | false |
wweiradio/django | django/conf/locale/zh_Hant/formats.py | 1008 | 1810 | # -*- encoding: utf-8 -*-
# This file is distributed under the same license as the Django package.
#
from __future__ import unicode_literals
# The *_FORMAT strings use the Django date format syntax,
# see http://docs.djangoproject.com/en/dev/ref/templates/builtins/#date
DATE_FORMAT = 'Y年n月j日' # 2016年9月5... | bsd-3-clause | 7,908,479,657,532,321,000 | 36.6 | 77 | 0.536643 | false |
ycl2045/nova-master | nova/tests/integrated/v3/test_security_groups.py | 29 | 2233 | # Copyright 2012 Nebula, Inc.
# 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.apache.org/licenses/LICENSE-2.0
#
# Unless required... | apache-2.0 | 5,530,289,195,131,717,000 | 34.444444 | 78 | 0.648455 | false |
dannyboi104/SickRage | sickbeard/providers/t411.py | 2 | 9980 | # -*- coding: latin-1 -*-
# Author: djoole <bobby.djoole@gmail.com>
# URL: http://code.google.com/p/sickbeard/
#
# This file is part of Sick Beard.
#
# Sick Beard 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... | gpl-3.0 | 121,364,437,317,147,620 | 35.691176 | 125 | 0.547395 | false |
444thLiao/VarappX | tests/data_models/test_users.py | 2 | 3481 | #!/usr/bin/env python3
import unittest
import django.test
from varapp.data_models.users import *
from varapp.models.users import *
from django.conf import settings
class TestUser(unittest.TestCase):
def test_user_constructor(self):
s = User('A', 'a@a', 'code', '', 1, Person(firstname='A'), Role('guest'))
... | gpl-3.0 | -908,909,783,271,142,300 | 33.127451 | 84 | 0.620511 | false |
bmerry/mlsgpu | utils/simulate.py | 1 | 12858 | #!/usr/bin/env python
# mlsgpu: surface reconstruction from point clouds
# Copyright (C) 2013 University of Cape Town
#
# This file is part of mlsgpu.
#
# mlsgpu 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 Foundatio... | gpl-3.0 | 6,755,193,426,946,831,000 | 30.208738 | 99 | 0.549697 | false |
kc4271/batch_downloader | requests/packages/urllib3/contrib/pyopenssl.py | 304 | 15086 | '''SSL with SNI_-support for Python 2. Follow these instructions if you would
like to verify SSL certificates in Python 2. Note, the default libraries do
*not* do certificate checking; you need to do additional work to validate
certificates yourself.
This needs the following packages installed:
* pyOpenSSL (tested wi... | mit | 3,865,868,602,345,258,000 | 34.748815 | 79 | 0.56052 | false |
elahejalalpour/ELRyu | ryu/services/protocols/bgp/operator/commands/show/memory.py | 27 | 2971 | import gc
import sys
from ryu.services.protocols.bgp.operator.command import Command
from ryu.services.protocols.bgp.operator.command import CommandsResponse
from ryu.services.protocols.bgp.operator.command import STATUS_ERROR
from ryu.services.protocols.bgp.operator.command import STATUS_OK
class Memory(Command):
... | apache-2.0 | -55,127,114,808,981,940 | 32.382022 | 78 | 0.464827 | false |
mastizada/pontoon | pontoon/base/migrations/0049_create_translation_memory_entries.py | 3 | 1418 | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import migrations, models
def create_translation_memory_entries(apps, schema):
Translation = apps.get_model('base', 'Translation')
TranslationMemoryEntry = apps.get_model('base', 'TranslationMemoryEntry')
def get_memory_entry(... | bsd-3-clause | 4,044,819,193,914,254,000 | 35.358974 | 98 | 0.672073 | false |
kosgroup/odoo | addons/note/models/note.py | 2 | 5954 | # -*- coding: utf-8 -*-
# Part of Odoo. See LICENSE file for full copyright and licensing details.
from odoo import api, fields, models, _
from odoo.tools import html2plaintext
class Stage(models.Model):
_name = "note.stage"
_description = "Note Stage"
_order = 'sequence'
name = fields.Char('Stage ... | gpl-3.0 | 7,629,107,794,595,674,000 | 42.144928 | 160 | 0.549547 | false |
magicrub/MissionPlanner | Lib/distutils/version.py | 59 | 11732 | #
# distutils/version.py
#
# Implements multiple version numbering conventions for the
# Python Module Distribution Utilities.
#
# $Id$
#
"""Provides classes to represent module version numbers (one class for
each style of version numbering). There are currently two such classes
implemented: StrictVersion ... | gpl-3.0 | 8,511,797,182,796,536,000 | 37.237458 | 79 | 0.636123 | false |
ukanga/SickRage | sickbeard/search.py | 3 | 30233 | # coding=utf-8
# Author: Nic Wolfe <nic@wolfeden.ca>
# URL: https://sickrage.github.io
# Git: https://github.com/SickRage/SickRage.git
#
# This file is part of SickRage.
#
# SickRage 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... | gpl-3.0 | -6,609,789,846,448,220,000 | 41.462079 | 174 | 0.621473 | false |
ghchinoy/tensorflow | tensorflow/python/tools/freeze_graph_test.py | 4 | 13446 | # 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 | -328,287,658,419,026,600 | 39.378378 | 80 | 0.65856 | false |
BeZazz/lamebench | nb_third_party/dns/rdtypes/IN/WKS.py | 248 | 4116 | # Copyright (C) 2003-2007, 2009, 2010 Nominum, Inc.
#
# Permission to use, copy, modify, and distribute this software and its
# documentation for any purpose with or without fee is hereby granted,
# provided that the above copyright notice and this permission notice
# appear in all copies.
#
# THE SOFTWARE IS PROVIDED ... | apache-2.0 | 446,422,037,357,367,600 | 35.424779 | 79 | 0.584305 | false |
kod3r/neon | neon/backends/tests/test_batched_dot.py | 10 | 3638 | # ----------------------------------------------------------------------------
# Copyright 2015 Nervana Systems 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.o... | apache-2.0 | -6,557,122,120,701,619,000 | 33.980769 | 95 | 0.615173 | false |
cntnboys/410Lab6 | build/django/build/lib.linux-x86_64-2.7/django/db/backends/mysql/validation.py | 65 | 1311 | from django.core import checks
from django.db.backends import BaseDatabaseValidation
class DatabaseValidation(BaseDatabaseValidation):
def check_field(self, field, **kwargs):
"""
MySQL has the following field length restriction:
No character (varchar) fields can have a length exceeding 255... | apache-2.0 | -1,364,551,610,489,862,000 | 36.457143 | 95 | 0.55225 | false |
jostep/tensorflow | tensorflow/python/kernel_tests/string_to_number_op_test.py | 104 | 4041 | # 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 | 6,205,451,113,576,852,000 | 39.41 | 80 | 0.539223 | false |
zhwei/cabric | cabric/perm.py | 1 | 2522 | # -*- coding: utf-8 -*-
from fabric.api import *
from cabric.cmd import cmd_expanduser,cmd_su
import os
def put_public_key(path=None, user=None):
"""
Upload pub key from remote server.
Limit: Openssh standard key,must comment with user mail.
:param path:local path
:param user:remote username
... | mit | 6,725,413,645,272,268,000 | 26.662921 | 89 | 0.559708 | false |
vvv1559/intellij-community | python/lib/Lib/site-packages/django/utils/_os.py | 71 | 2011 | import os
from os.path import join, normcase, normpath, abspath, isabs, sep
from django.utils.encoding import force_unicode
# Define our own abspath function that can handle joining
# unicode paths to a current working directory that has non-ASCII
# characters in it. This isn't necessary on Windows since the
# Wind... | apache-2.0 | 5,173,750,275,702,239,000 | 42.717391 | 79 | 0.688712 | false |
sparkslabs/kamaelia_ | Sketches/DK/Kamaelia-Paint/App/XYPad.py | 3 | 22735 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
# Copyright 2010 British Broadcasting Corporation and Kamaelia Contributors(1)
#
# (1) Kamaelia Contributors are listed in the AUTHORS file and at
# http://www.kamaelia.org/AUTHORS - please extend this file,
# not this notice.
#
# Licensed under the Apache License, ... | apache-2.0 | 431,071,562,639,047,940 | 44.47 | 128 | 0.537717 | false |
fhaoquan/kbengine | kbe/src/lib/python/Lib/test/list_tests.py | 106 | 17676 | """
Tests common to list and UserList.UserList
"""
import sys
import os
from functools import cmp_to_key
from test import support, seq_tests
class CommonTest(seq_tests.CommonTest):
def test_init(self):
# Iterable arg is optional
self.assertEqual(self.type2test([]), self.type2test())
# ... | lgpl-3.0 | 1,550,433,381,947,286,000 | 29.215385 | 81 | 0.500905 | false |
jakesyl/pychess | testing/draw.py | 21 | 1665 | import unittest
from pychess.Savers import pgn
from pychess.Utils.lutils import ldraw
class DrawTestCase(unittest.TestCase):
def setUp(self):
with open('gamefiles/3fold.pgn') as f1:
self.PgnFile1 = pgn.load(f1)
with open('gamefiles/bilbao.pgn') as f2:
self.PgnFil... | gpl-3.0 | 8,872,808,236,522,490,000 | 29.735849 | 63 | 0.587387 | false |
chirilo/kitsune | kitsune/search/tests/test_plugin.py | 15 | 1279 | from django.contrib.sites.models import Site
import mock
from nose.tools import eq_
from kitsune.sumo.tests import TestCase
from kitsune.sumo.urlresolvers import reverse
class OpenSearchTestCase(TestCase):
"""Test the SUMO OpenSearch plugin."""
@mock.patch.object(Site.objects, 'get_current')
def test_p... | bsd-3-clause | 6,138,544,491,154,991,000 | 35.542857 | 78 | 0.615324 | false |
CognetTestbed/COGNET_CODE | LIB_NETLINK/libnl-3-android-nogit/python/netlink/route/links/vlan.py | 13 | 1943 | #
# Copyright (c) 2011 Thomas Graf <tgraf@suug.ch>
#
"""VLAN network link
"""
from __future__ import absolute_import
from ... import core as netlink
from .. import capi as capi
class VLANLink(object):
def __init__(self, link):
self._link = link
@property
@netlink.nlattr(type=int)
def id(s... | gpl-3.0 | 2,117,081,151,696,543,000 | 26.366197 | 75 | 0.545548 | false |
pixelrebel/st2 | st2actions/st2actions/resultstracker/resultstracker.py | 5 | 4285 | # Licensed to the StackStorm, Inc ('StackStorm') under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use th... | apache-2.0 | 7,826,983,016,845,986,000 | 37.603604 | 92 | 0.665578 | false |
HLFH/CouchPotatoServer | couchpotato/core/media/movie/providers/trailer/youtube_dl/extractor/walla.py | 27 | 2976 | # coding: utf-8
from __future__ import unicode_literals
import re
from .subtitles import SubtitlesInfoExtractor
from ..utils import (
xpath_text,
int_or_none,
)
class WallaIE(SubtitlesInfoExtractor):
_VALID_URL = r'http://vod\.walla\.co\.il/[^/]+/(?P<id>\d+)/(?P<display_id>.+)'
_TEST = {
'ur... | gpl-3.0 | 3,063,681,558,481,189,400 | 32.168539 | 101 | 0.521341 | false |
Subsets and Splits
Gradio Code Samples
Limits the results to entries containing the word 'gradio' in the repo_name, content, or path, providing a filtered subset of the dataset.