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
shinate/phantomjs
src/qt/qtwebkit/Tools/Scripts/webkitpy/common/system/outputcapture.py
124
5478
# Copyright (c) 2009, Google Inc. All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are # met: # # * Redistributions of source code must retain the above copyright # notice, this list of conditions and the...
bsd-3-clause
-268,936,401,586,776,220
41.796875
154
0.692223
false
danielquinn/spirithunter
src/spirits/migrations/0002_auto_20160904_1741.py
1
2320
# -*- coding: utf-8 -*- # Generated by Django 1.10.1 on 2016-09-04 17:41 from __future__ import unicode_literals from django.conf import settings from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): initial = True dependencies = [ migratio...
agpl-3.0
4,100,323,036,932,990,500
37.666667
157
0.613362
false
fedora-infra/fmn.consumer
tests/test_sse_backend.py
2
5500
""" Unit tests for the SSE backend. """ from __future__ import unicode_literals, absolute_import import json import unittest import mock from fmn.consumer.backends import SSEBackend @mock.patch('fmn.consumer.backends.sse.protocol.ClientCreator', mock.Mock()) class TestSSEBackend(unittest.TestCase): def test_f...
gpl-2.0
1,209,929,337,784,353,500
38.007092
93
0.502182
false
mcrowson/django
django/utils/functional.py
234
13622
import copy import operator from functools import total_ordering, wraps from django.utils import six from django.utils.six.moves import copyreg # You can't trivially replace this with `functools.partial` because this binds # to classes and returns bound instances, whereas functools.partial (on # CPython) is a type a...
bsd-3-clause
3,670,553,300,481,786,000
33.838875
96
0.571942
false
rwatson/chromium-capsicum
third_party/scons/scons-local/SCons/Tool/cvf.py
3
2399
"""engine.SCons.Tool.cvf Tool-specific initialization for the Compaq Visual Fortran compiler. """ # # Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 The SCons Foundation # # Permission is hereby granted, free of charge, to any person obtaining # a copy of this software and associated documentatio...
bsd-3-clause
-2,009,289,899,430,156,000
45.134615
174
0.73489
false
inveniosoftware/kwalitee
kwalitee/cli/githooks.py
2
2832
# -*- coding: utf-8 -*- # # This file is part of kwalitee # Copyright (C) 2014, 2015 CERN. # # kwalitee 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) an...
gpl-2.0
3,105,231,613,633,305,600
28.5
77
0.637712
false
xaviercobain88/framework-python
openerp/addons/account/account_analytic_line.py
31
7587
# -*- coding: utf-8 -*- ############################################################################## # # OpenERP, Open Source Management Solution # Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>). # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU...
agpl-3.0
-5,107,192,865,294,292,000
46.716981
233
0.580598
false
adamschmideg/mal
rpython/step2_eval.py
32
3030
#import sys, traceback import mal_readline import mal_types as types from mal_types import (MalSym, MalInt, MalStr, _keywordu, MalList, _list, MalVector, MalHashMap, MalFunc) import reader, printer # read def READ(str): return reader.read_str(str) # eval def eval_ast(...
mpl-2.0
-4,262,228,240,801,030,700
26.545455
72
0.575248
false
angryrancor/kivy
kivy/core/clipboard/clipboard_pygame.py
39
1446
''' Clipboard Pygame: an implementation of the Clipboard using pygame.scrap. ''' __all__ = ('ClipboardPygame', ) from kivy.utils import platform from kivy.compat import PY2 from kivy.core.clipboard import ClipboardBase if platform not in ('win', 'linux', 'macosx'): raise SystemError('unsupported platform for pyg...
mit
7,406,963,261,212,281,000
23.931034
72
0.594744
false
arista-eosplus/ansible
lib/ansible/modules/network/panos/panos_security_policy.py
39
16244
#!/usr/bin/python # -*- coding: utf-8 -*- # # Ansible module to manage PaloAltoNetworks Firewall # (c) 2016, techbizdev <techbizdev@paloaltonetworks.com> # # 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 publish...
gpl-3.0
-9,135,327,369,128,480,000
31.816162
116
0.62854
false
amoikevin/gyp
test/win/gyptest-cl-enable-enhanced-instruction-set.py
52
1432
#!/usr/bin/env python # Copyright (c) 2014 Google Inc. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """ Test VCCLCompilerTool EnableEnhancedInstructionSet setting. """ import TestGyp import os import sys if sys.platform == 'win32': tes...
bsd-3-clause
6,768,219,745,631,797,000
31.545455
74
0.651536
false
mila-iqia/babyai
scripts/il_perf.py
1
2047
#!/usr/bin/env python3 import argparse import pandas import os import json import re import numpy as np from scipy import stats from babyai import plotting as bp parser = argparse.ArgumentParser("Analyze performance of imitation learning") parser.add_argument("--path", default='.', help="path to model logs") par...
bsd-3-clause
-5,121,100,608,454,657,000
32.557377
81
0.66341
false
boundlessgeo/QGIS
python/plugins/db_manager/db_plugins/postgis/plugins/versioning/__init__.py
32
2259
# -*- coding: utf-8 -*- """ /*************************************************************************** Name : Versioning plugin for DB Manager Description : Set up versioning support for a table Date : Mar 12, 2012 copyright : (C) 2012 by Giuseppe Sucameli email ...
gpl-2.0
1,873,845,665,409,150,500
42.403846
96
0.551617
false
edum1978/eduengage
boilerplate/lib/basehandler.py
8
12971
# *-* coding: UTF-8 *-* # standard library imports import logging import re import traceback import sys # related third party imports import webapp2 from google.appengine.api.users import NotAllowedError from webapp2_extras import jinja2 from webapp2_extras import auth from webapp2_extras import sessions from google.a...
lgpl-3.0
-6,065,742,665,887,119,000
35.540845
138
0.587464
false
CloverHealth/airflow
airflow/example_dags/example_passing_params_via_test_command.py
14
2351
# -*- coding: utf-8 -*- # # 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 #...
apache-2.0
-8,027,758,272,358,939,000
35.169231
88
0.680987
false
Luobiny/bioconda-recipes
recipes/mtnucratio/mtnucratio.py
20
2667
#!/usr/bin/env python # # Wrapper script for Java Conda packages that ensures that the java runtime # is invoked with the right options. Adapted from the bash script (http://stackoverflow.com/questions/59895/can-a-bash-script-tell-what-directory-its-stored-in/246128#246128). # # # Program Parameters # import os import...
mit
-8,165,809,715,266,996,000
28.633333
175
0.633296
false
ahamilton55/ansible
lib/ansible/modules/network/cloudengine/ce_netconf.py
46
5922
#!/usr/bin/python # # 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 License, or # (at your option) any later version. # # Ansible is distribut...
gpl-3.0
-1,764,544,194,913,864,000
28.61
118
0.553698
false
OpenBfS/dokpool-plone
Plone/src/elan.sitrep/elan/sitrep/content/srmoduleconfig.py
1
3765
# -*- coding: utf-8 -*- # # File: srmoduleconfig.py # # Copyright (c) 2017 by Condat AG # Generator: ConPD2 # http://www.condat.de # __author__ = '' __docformat__ = 'plaintext' """Definition of the SRModuleConfig content type. See srmoduleconfig.py for more explanation on the statements below. """ from Acc...
gpl-3.0
1,140,776,488,611,942,300
28.645669
118
0.656574
false
safwanrahman/mozillians
vendor-local/lib/python/unidecode/x0fa.py
252
4406
data = ( 'Chey ', # 0x00 'Thak ', # 0x01 'Thak ', # 0x02 'Thang ', # 0x03 'Thayk ', # 0x04 'Thong ', # 0x05 'Pho ', # 0x06 'Phok ', # 0x07 'Hang ', # 0x08 'Hang ', # 0x09 'Hyen ', # 0x0a 'Hwak ', # 0x0b 'Wu ', # 0x0c 'Huo ', # 0x0d '[?] ', # 0x0e '[?] ', # 0x0f 'Zhong ', ...
bsd-3-clause
-917,433,629,175,011,100
16.143969
19
0.258284
false
camptocamp/odoo
addons/crm_claim/__init__.py
390
1078
# -*- coding: utf-8 -*- ############################################################################## # # OpenERP, Open Source Management Solution # Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>). # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU...
agpl-3.0
-5,220,181,429,007,546,000
40.461538
78
0.616883
false
ptisserand/docker-registry
tests/test_s3.py
30
6105
# -*- coding: utf-8 -*- import StringIO import sys import time from nose import tools from docker_registry.core import exceptions import docker_registry.testing as testing from docker_registry.testing import mock_boto # noqa from . import mock_s3 # noqa class StringIOWithError(StringIO.StringIO): '''Throw...
apache-2.0
-4,708,033,643,386,103,000
33.885714
79
0.57887
false
MoritzS/django
django/utils/archive.py
52
7462
""" Based on "python-archive" -- http://pypi.python.org/pypi/python-archive/ Copyright (c) 2010 Gary Wilson Jr. <gary.wilson@gmail.com> and contributors. 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 So...
bsd-3-clause
-8,572,850,418,039,428,000
31.872247
101
0.588046
false
buntyke/Flask
microblog/flask/lib/python2.7/site-packages/sqlalchemy/util/__init__.py
10
2520
# util/__init__.py # Copyright (C) 2005-2015 the SQLAlchemy authors and contributors # <see AUTHORS file> # # This module is part of SQLAlchemy and is released under # the MIT License: http://www.opensource.org/licenses/mit-license.php from .compat import callable, cmp, reduce, \ threading, py3k, py33, py36, py2k...
mit
6,179,880,468,462,195,000
50.428571
80
0.754762
false
ojii/sandlib
lib/lib-python/2.7/importlib/__init__.py
456
1327
"""Backport of importlib.import_module from 3.x.""" # While not critical (and in no way guaranteed!), it would be nice to keep this # code compatible with Python 2.3. import sys def _resolve_name(name, package, level): """Return the absolute name of the module to be imported.""" if not hasattr(package, 'rindex...
bsd-3-clause
8,607,384,532,238,540,000
33.921053
79
0.608892
false
nelsongoh/tembotsu
libs/future/backports/email/generator.py
82
19520
# Copyright (C) 2001-2010 Python Software Foundation # Author: Barry Warsaw # Contact: email-sig@python.org """Classes to generate plain text from a message object tree.""" from __future__ import print_function from __future__ import unicode_literals from __future__ import division from __future__ import absolute_impo...
apache-2.0
250,567,028,001,611,070
38.196787
93
0.602357
false
fabaff/ansible
lib/ansible/executor/playbook_executor.py
1
9866
# (c) 2012-2014, Michael DeHaan <michael.dehaan@gmail.com> # # 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 License, or # (at your option) an...
gpl-3.0
-1,444,482,905,630,737,400
40.628692
157
0.534259
false
savi-dev/horizon
horizon/dashboards/nova/containers/forms.py
1
7384
# vim: tabstop=4 shiftwidth=4 softtabstop=4 # Copyright 2012 United States Government as represented by the # Administrator of the National Aeronautics and Space Administration. # All Rights Reserved. # # Copyright 2012 Nebula, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # no...
apache-2.0
7,625,742,781,935,055,000
42.181287
79
0.527221
false
mahak/keystone
keystone/auth/plugins/base.py
2
3476
# Copyright 2013 OpenStack Foundation # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in...
apache-2.0
4,375,000,550,260,059,600
36.376344
79
0.546893
false
GaussDing/django
tests/gis_tests/geoapp/test_feeds.py
33
4256
from __future__ import unicode_literals from xml.dom import minidom from django.conf import settings from django.contrib.gis.geos import HAS_GEOS from django.contrib.sites.models import Site from django.test import ( TestCase, modify_settings, override_settings, skipUnlessDBFeature, ) if HAS_GEOS: from .mode...
bsd-3-clause
8,169,172,913,197,229,000
45.26087
103
0.643797
false
SkillSmart/ConferenceManagementSystem
ApplicationManagement/migrations/0012_auto_20170331_1943.py
1
1448
# -*- coding: utf-8 -*- # Generated by Django 1.10.5 on 2017-03-31 17:43 from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('ApplicationManagement', '0011_auto_20170331_1649'), ] operations = [ migrat...
mit
1,433,048,053,057,716,500
30.478261
138
0.575276
false
michaelyin/code-for-blog
2009/plotting_data_monitor/com_monitor.py
15
2988
import Queue import threading import time import serial class ComMonitorThread(threading.Thread): """ A thread for monitoring a COM port. The COM port is opened when the thread is started. data_q: Queue for received data. Items in the queue are (data, ti...
unlicense
8,809,533,817,093,793,000
31.255556
71
0.498996
false
systemdaemon/systemd
tools/gdb-sd_dump_hashmaps.py
112
5114
# -*- Mode: python; coding: utf-8; indent-tabs-mode: nil -*- */ # # This file is part of systemd. # # Copyright 2014 Michal Schmidt # # systemd 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; eith...
gpl-2.0
-2,819,548,992,402,399,000
53.404255
185
0.437231
false
lukeburden/django-allauth
allauth/socialaccount/providers/bitbucket_oauth2/provider.py
10
1122
from allauth.socialaccount.providers.base import ProviderAccount from allauth.socialaccount.providers.oauth2.provider import OAuth2Provider class BitbucketOAuth2Account(ProviderAccount): def get_profile_url(self): return (self.account.extra_data .get('links', {}) .get('html...
mit
3,572,753,055,431,844,400
29.324324
74
0.610517
false
rancher/validation-tests
tests/v3_validation/cattlevalidationtest/core/test_network_policy.py
2
33949
from common_fixtures import * # NOQA test_network_policy = os.environ.get( 'TEST_NETWORK_POLICY', "False") np_reason = \ 'Intended to not execute this network policy test' if_network_policy = pytest.mark.skipif(test_network_policy != "ALL", reason=np_reason) if_network_...
apache-2.0
-7,541,229,297,950,756,000
40.655215
79
0.659813
false
michelts/lettuce
tests/integration/test_brocolis.py
17
2167
# -*- coding: utf-8 -*- # <Lettuce - Behaviour Driven Development for python> # Copyright (C) <2010-2012> Gabriel Falcão <gabriel@nacaolivre.org> # # 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 Foundatio...
gpl-3.0
4,176,015,016,514,085,400
37
108
0.731764
false
Chrispassold/ionicons
builder/generate.py
357
9438
from subprocess import call import os import json BUILDER_PATH = os.path.dirname(os.path.abspath(__file__)) ROOT_PATH = os.path.join(BUILDER_PATH, '..') FONTS_FOLDER_PATH = os.path.join(ROOT_PATH, 'fonts') CSS_FOLDER_PATH = os.path.join(ROOT_PATH, 'css') SCSS_FOLDER_PATH = os.path.join(ROOT_PATH, 'scss') LESS_FOLDER_...
mit
7,055,744,480,035,983,000
28.679245
113
0.593346
false
dvliman/jaikuengine
.google_appengine/lib/django-1.4/django/contrib/gis/gdal/datasource.py
92
4724
""" DataSource is a wrapper for the OGR Data Source object, which provides an interface for reading vector geometry data from many different file formats (including ESRI shapefiles). When instantiating a DataSource object, use the filename of a GDAL-supported data source. For example, a SHP file or a TIGER/Line...
apache-2.0
-1,417,176,880,735,346,400
35.90625
92
0.617273
false
Rogentos/legacy-anaconda
storage/devicelibs/crypto.py
2
6138
# # crypto.py # # Copyright (C) 2009 Red Hat, Inc. All rights reserved. # # 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 versi...
gpl-2.0
-6,418,685,966,033,070,000
30.803109
97
0.620398
false
eunchong/build
scripts/slave/recipe_modules/skia/ios_flavor.py
1
5292
# Copyright 2015 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. import copy import default_flavor """iOS flavor utils, used for building for and running tests on iOS.""" class iOSFlavorUtils(default_flavor.DefaultFla...
bsd-3-clause
-1,379,111,132,624,642,300
33.815789
79
0.595049
false
hipnusleo/laserjet
resource/pypi/cryptography-1.7.1/src/_cffi_src/openssl/engine.py
1
5445
# This file is dual licensed under the terms of the Apache License, Version # 2.0, and the BSD License. See the LICENSE file in the root of this repository # for complete details. from __future__ import absolute_import, division, print_function INCLUDES = """ #include <openssl/engine.h> """ TYPES = """ st...
apache-2.0
-2,814,201,960,246,762,000
35.294521
79
0.713315
false
rhinstaller/anaconda
tests/unit_tests/pyanaconda_tests/modules/payloads/payload/test_module_payload_dnf_utils.py
2
15676
# # Copyright (C) 2020 Red Hat, Inc. # # This copyrighted material is made available to anyone wishing to use, # modify, copy, or redistribute it subject to the terms and conditions of # the GNU General Public License v.2, or (at your option) any later version. # This program is distributed in the hope that it will be...
gpl-2.0
-7,208,815,140,267,659,000
37.610837
92
0.598941
false
adfernandes/pcp
src/pcp/pidstat/test/process_stackutil_test.py
6
2213
#!/usr/bin/env pmpython # # Copyright (C) 2016 Sitaram Shelke. # # 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. # # Thi...
lgpl-2.1
4,987,127,336,330,948,000
31.072464
114
0.676005
false
mou4e/zirconium
build/android/adb_reverse_forwarder.py
15
2519
#!/usr/bin/env python # # Copyright (c) 2013 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """Command line tool for forwarding ports from a device to the host. Allows an Android device to connect to services running on ...
bsd-3-clause
261,904,930,896,026,880
31.294872
80
0.637555
false
zaqwes8811/micro-apps
extern/gmock-1.6.0/gtest/test/gtest_uninitialized_test.py
2901
2480
#!/usr/bin/env python # # Copyright 2008, Google Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are # met: # # * Redistributions of source code must retain the above copyright # notice, this list...
mit
-5,457,692,574,667,149,000
34.428571
77
0.755645
false
pim89/youtube-dl
youtube_dl/extractor/brightcove.py
5
27756
# coding: utf-8 from __future__ import unicode_literals import re import json from .common import InfoExtractor from ..compat import ( compat_etree_fromstring, compat_parse_qs, compat_str, compat_urllib_parse_urlparse, compat_urlparse, compat_xml_parse_error, compat_HTTPError, ) from ..uti...
unlicense
3,632,902,321,030,330,000
42.291732
484
0.52436
false
BowdoinOrient/bongo
bongo/apps/bongo/tests/model_tests.py
1
13646
from bongo.apps.bongo.tests import factories from django.test import TestCase from django.contrib.auth.models import User from django.conf import settings from django.utils.text import slugify import os """ Test content type models and related: test, video, PDF, photo, HTML, pullquote, post """ class TextTestCase(Te...
mit
8,609,577,131,761,195,000
28.473002
116
0.630808
false
viridia/coda
third-party/python/ply-3.4/ply/cpp.py
192
33040
# ----------------------------------------------------------------------------- # cpp.py # # Author: David Beazley (http://www.dabeaz.com) # Copyright (C) 2007 # All rights reserved # # This module implements an ANSI-C style lexical preprocessor for PLY. # -------------------------------------------------------------...
apache-2.0
2,012,393,019,758,861,300
35.792873
141
0.415406
false
Chilledheart/chromium
tools/telemetry/third_party/typ/typ/arg_parser.py
33
13928
# Copyright 2014 Google 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 applicable law or ag...
bsd-3-clause
3,381,652,566,841,887,000
43.215873
79
0.48923
false
bazz-erp/erpnext
erpnext/setup/doctype/company/company.py
1
15659
# Copyright (c) 2015, Frappe Technologies Pvt. Ltd. and Contributors # License: GNU General Public License v3. See license.txt from __future__ import unicode_literals import frappe, os from frappe import _ from frappe.utils import cint, today, formatdate import frappe.defaults from frappe.model.document import Docu...
gpl-3.0
-8,096,426,726,978,281,000
42.985955
180
0.592694
false
jedie/pypyjs-standalone
website/js/pypy.js-0.3.0/lib/modules/test/test_macpath.py
100
2000
import macpath from test import test_support, test_genericpath import unittest class MacPathTestCase(unittest.TestCase): def test_abspath(self): self.assertEqual(macpath.abspath("xx:yy"), "xx:yy") def test_isabs(self): isabs = macpath.isabs self.assertTrue(isabs("xx:yy")) sel...
mit
-306,350,961,789,963,800
34.087719
79
0.5705
false
Kaftanov/Cchat
chat-client/client.py
1
5334
#!/usr/bin/env python3 """ ############################# Server applycation version python: python3 based on socket ############################# """ import select import socket import sys import datetime from PyQt5 import QtWidgets from PyQt5.QtCore import QThread, QPoint import userf...
gpl-3.0
7,761,749,070,141,927,000
29.306818
77
0.512186
false
mikewiebe-ansible/ansible
test/units/modules/network/iosxr/test_iosxr_user.py
48
4023
# (c) 2016 Red Hat Inc. # # 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 License, or # (at your option) any later version. # # Ansible is dis...
gpl-3.0
-5,538,975,829,170,900,000
41.797872
104
0.693512
false
saketkc/statsmodels
statsmodels/sandbox/distributions/tests/_est_fit.py
31
2609
# NOTE: contains only one test, _est_cont_fit, that is renamed so that # nose doesn't run it # I put this here for the record and for the case when someone wants to # verify the quality of fit # with current parameters: relatively small sample size, default starting values # Ran 84 tests in 401.797s # ...
bsd-3-clause
1,604,428,408,017,526,500
36.271429
85
0.633959
false
nwjs/chromium.src
components/test/data/password_manager/form_classification_tests/signin_forms_test.py
19
24192
# Copyright 2016 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. import unittest from form_classification_test import FormClassificationTest """Unittest class for testing signin forms. The test methods were generated by ...
bsd-3-clause
-1,097,490,221,883,458,600
36.047473
80
0.634218
false
Dexhub/MTX
src/arch/x86/isa/insts/simd64/integer/data_reordering/unpack_and_interleave.py
91
4097
# Copyright (c) 2007 The Hewlett-Packard Development Company # All rights reserved. # # The license below extends only to copyright in the software and shall # not be construed as granting a license to any other intellectual # property including but not limited to intellectual property relating # to a hardware implemen...
bsd-3-clause
-3,750,553,566,638,720,500
31.007813
72
0.721504
false
AOSPA-L/android_external_skia
gm/rebaseline_server/compare_rendered_pictures_test.py
67
4021
#!/usr/bin/python """ Copyright 2014 Google Inc. Use of this source code is governed by a BSD-style license that can be found in the LICENSE file. Test compare_rendered_pictures.py TODO(epoger): Create a command to update the expected results (in self._output_dir_expected) when appropriate. For now, you should: 1....
bsd-3-clause
18,097,560,818,985,228
32.508333
80
0.65705
false
quarkonics/zstack-woodpecker
zstackwoodpecker/zstackwoodpecker/operations/deploy_operations.py
1
47036
''' deploy operations for setup zstack database. @author: Youyk ''' import zstackwoodpecker.test_util as test_util import apibinding.api_actions as api_actions import account_operations import resource_operations as res_ops import zstacklib.utils.sizeunit as sizeunit import zstacklib.utils.jsonobject as ...
apache-2.0
-89,130,814,888,051,550
39.698582
228
0.566268
false
nooperpudd/pulsar
examples/httpbin/manage.py
5
12153
'''Pulsar HTTP test application:: python manage.py Implementation ====================== .. autoclass:: HttpBin :members: :member-order: bysource Server Hooks =================== This example shows how to use :ref:`server hooks <setting-section-application-hooks>` to log each request .. automodule:: exa...
bsd-3-clause
-6,857,042,363,070,801,000
35.277612
78
0.570888
false
s20121035/rk3288_android5.1_repo
external/lldb/test/functionalities/inferior-changed/TestInferiorChanged.py
2
3689
"""Test lldb reloads the inferior after it was changed during the session.""" import os, time import unittest2 import lldb from lldbtest import * import lldbutil class ChangedInferiorTestCase(TestBase): mydir = os.path.join("functionalities", "inferior-changed") @unittest2.skipUnless(sys.platform.startswith...
gpl-3.0
-7,694,408,415,580,739,000
35.166667
119
0.611277
false
EliotBerriot/django
django/utils/inspect.py
323
4195
from __future__ import absolute_import import inspect from django.utils import six def getargspec(func): if six.PY2: return inspect.getargspec(func) sig = inspect.signature(func) args = [ p.name for p in sig.parameters.values() if p.kind == inspect.Parameter.POSITIONAL_OR_KEYWOR...
bsd-3-clause
2,578,453,951,049,575,400
31.022901
89
0.613111
false
fluxw42/youtube-dl
youtube_dl/extractor/laola1tv.py
14
6314
# coding: utf-8 from __future__ import unicode_literals from .common import InfoExtractor from ..utils import ( ExtractorError, unified_strdate, urlencode_postdata, xpath_element, xpath_text, urljoin, update_url_query, ) class Laola1TvEmbedIE(InfoExtractor): IE_NAME = 'laola1tv:embed'...
unlicense
768,122,792,356,735,400
34.857955
110
0.495484
false
maciekcc/tensorflow
tensorflow/python/estimator/export/export.py
19
7374
# Copyright 2017 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,457,649,978,876,341,000
38.859459
80
0.685788
false
sridevikoushik31/openstack
nova/availability_zones.py
3
3309
# Copyright (c) 2012 OpenStack Foundation # 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
4,454,980,183,463,405,600
36.602273
78
0.6712
false
mohseniaref/adore-doris
gui/snaphuConfigEditor.py
2
11609
#!/usr/bin/env python # example basictreeview.py import pygtk pygtk.require('2.0') import gtk import os import dialogs class SnaphuConfigEditor: def snaphuParser(self, set=None, setFile=None): if setFile is None: setFile=self.setFile; if set is None: set=self.set; ...
gpl-2.0
-5,694,778,346,069,999,000
40.021201
118
0.600224
false
ldtp/pyatom
atomac/ldtpd/text.py
2
16670
# Copyright (c) 2012 VMware, Inc. All Rights Reserved. # This file is part of ATOMac. #@author: Nagappan Alagappan <nagappan@gmail.com> #@copyright: Copyright (c) 2009-12 Nagappan Alagappan #http://ldtp.freedesktop.org # ATOMac is free software; you can redistribute it and/or modify # it under the terms of the GNU G...
gpl-2.0
-7,937,828,098,198,052,000
35.557018
85
0.611938
false
initzx/aobot
commands/private/changepic.py
1
1135
import aiohttp from registrar import AbstractCommand, bot_command @bot_command class Command(AbstractCommand): """ Template for bot command classes. """ _name = 'changepic' _aliases = ['changepic'] _enabled = True tags = {'misc': ['private'], 'args': {'req': ['pic'], 'nreq': []}} @staticmeth...
gpl-3.0
-8,128,590,722,962,857,000
26.02381
71
0.586784
false
TheTimmy/spack
var/spack/repos/builtin/packages/gflags/package.py
3
1900
############################################################################## # Copyright (c) 2013-2017, Lawrence Livermore National Security, LLC. # Produced at the Lawrence Livermore National Laboratory. # # This file is part of Spack. # Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved. # LLNL-CODE-64...
lgpl-2.1
-6,356,458,891,907,912,000
43.186047
78
0.680526
false
data-exp-lab/girder
girder/utility/search.py
4
3228
#!/usr/bin/env python # -*- coding: utf-8 -*- ############################################################################### # Copyright 2013 Kitware 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 cop...
apache-2.0
3,221,596,797,205,632,500
30.960396
98
0.644672
false
Manuel4131/youtube-dl
youtube_dl/extractor/onionstudios.py
109
2787
# coding: utf-8 from __future__ import unicode_literals import re from .common import InfoExtractor from ..utils import determine_ext class OnionStudiosIE(InfoExtractor): _VALID_URL = r'https?://(?:www\.)?onionstudios\.com/(?:videos/[^/]+-|embed\?.*\bid=)(?P<id>\d+)(?!-)' _TESTS = [{ 'url': 'http:/...
unlicense
-3,026,676,659,829,315,600
35.671053
110
0.52099
false
Mashape/dd-agent
tests/core/test_histogram.py
40
4851
# stdlib import unittest # project from aggregator import Histogram, MetricsAggregator from config import get_histogram_aggregates, get_histogram_percentiles class TestHistogram(unittest.TestCase): def test_default(self): stats = MetricsAggregator('myhost') for i in xrange(20): stats....
bsd-3-clause
3,797,583,063,153,037,300
30.705882
81
0.582148
false
lxwvictor/flask-ask
samples/session/session.py
2
1928
import logging import os from flask import Flask, json, render_template from flask_ask import Ask, request, session, question, statement app = Flask(__name__) ask = Ask(app, "/") logging.getLogger('flask_ask').setLevel(logging.DEBUG) COLOR_KEY = "COLOR" @ask.launch def launch(): card_title = render_template(...
apache-2.0
8,475,155,738,597,935,000
31.133333
101
0.685685
false
cmdunkers/DeeperMind
PythonEnv/lib/python2.7/site-packages/scipy/io/harwell_boeing/hb.py
23
18482
""" Implementation of Harwell-Boeing read/write. At the moment not the full Harwell-Boeing format is supported. Supported features are: - assembled, non-symmetric, real matrices - integer for pointer/indices - exponential format for float values, and int format """ from __future__ import division, print_...
bsd-3-clause
-529,123,285,604,996,100
32.664845
92
0.571096
false
danielreed/python-hpOneView
hpOneView/resources/networking/logical_downlinks.py
1
5419
# -*- coding: utf-8 -*- ### # (C) Copyright (2012-2016) Hewlett Packard Enterprise Development LP # # 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 limi...
mit
6,708,738,407,590,560,000
37.985612
95
0.640709
false
sholloway/Jitterbug
ext/vendor/glm-0.9.2.3/util/gen_external_templates.py
18
5678
__author__ = "eloraiby" __date__ = "$5-Sep-2010 9:35:29 PM$" atomic_types = ["unsigned char", "unsigned short", "unsigned int", "signed char", "signed short", "signed int", "float", "double"] glsl_vector_types = ["tvec2", "tvec3", "tvec4"] glsl_matrix_types = ["tmat2x2", "tmat2x3", "tmat2x4", "...
mit
-8,502,481,359,433,495,000
36.62585
146
0.451567
false
googleapis/python-speech
setup.py
1
2804
# 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 agreed to in writing, s...
apache-2.0
-668,839,975,031,349,000
28.515789
75
0.67903
false
asm-products/movie-database-service
ani/lib/python2.7/site-packages/django/db/models/sql/query.py
13
84272
""" Create SQL statements for QuerySets. The code in here encapsulates all of the SQL construction so that QuerySets themselves do not have to (and could be backed by things other than SQL databases). The abstraction barrier only works one way: this module has to know all about the internals of models in order to get ...
agpl-3.0
737,084,032,429,890,700
42.664249
129
0.591869
false
tectronics/py-lepton
lepton/pygame_renderer.py
6
3955
############################################################################# # # Copyright (c) 2008 by Casey Duncan and contributors # All Rights Reserved. # # This software is subject to the provisions of the MIT License # A copy of the license should accompany this distribution. # THE SOFTWARE IS PROVIDED "AS IS", W...
mit
1,196,420,979,823,259,600
27.65942
78
0.643236
false
takaaptech/sky_engine
build/linux/unbundle/replace_gyp_files.py
40
2929
#!/usr/bin/env python # Copyright 2013 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """ Replaces gyp files in tree with files from here that make the build use system libraries. """ import optparse import os.path impo...
bsd-3-clause
-8,113,458,690,183,102,000
34.719512
78
0.679754
false
fabiobrandespim/flat-earth
flat_earth.py
1
4983
""" Author: Fabio Brandespim Email: bayareaservices@gmail.com Location: Brazil - Goiania Date: 09-19-2016 """ #!C:/Python27_32/python.exe import pygame import math import particle import titulos import email_py #import time from threading import Thread from pygame.locals import * img = pygame.image.load("te...
gpl-3.0
-2,121,083,049,372,370,200
21.963134
110
0.549669
false
Karm/qpid-proton
proton-j/src/main/resources/cmessenger.py
17
5177
# # 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...
apache-2.0
914,276,588,698,954,400
22.008889
71
0.72204
false
kumar303/zamboni
mkt/tags/tests/test_models.py
17
2143
from nose.tools import eq_, ok_ import mkt.site.tests from mkt.site.utils import app_factory from mkt.tags.models import attach_tags, Tag from mkt.websites.utils import website_factory class TestTagManager(mkt.site.tests.TestCase): def test_not_blocked(self): """Make sure Tag Manager filters right for n...
bsd-3-clause
-1,933,067,569,631,609,600
30.985075
71
0.616892
false
pschmitt/home-assistant
homeassistant/components/keba/__init__.py
16
8405
"""Support for KEBA charging stations.""" import asyncio import logging from keba_kecontact.connection import KebaKeContact import voluptuous as vol from homeassistant.const import CONF_HOST from homeassistant.helpers import discovery import homeassistant.helpers.config_validation as cv _LOGGER = logging.getLogger(_...
apache-2.0
-7,524,593,204,434,205,000
34.167364
84
0.6232
false
ludmilamarian/invenio
invenio/base/setuptools/__init__.py
21
1323
# -*- coding: utf-8 -*- # # This file is part of Invenio. # Copyright (C) 2014 CERN. # # Invenio 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...
gpl-2.0
8,730,223,333,637,374,000
29.068182
74
0.686319
false
elit3ge/SickRage
sickbeard/notifiers/synologynotifier.py
12
2585
# Author: Nyaran <nyayukko@gmail.com> # # 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 Software Foundation, either version 3 of the License, or # (at your option) any later version. #...
gpl-3.0
3,332,266,006,298,008,600
41.377049
117
0.70677
false
AdrianoMaron/kWantera
argparse.py
490
87791
# Author: Steven J. Bethard <steven.bethard@gmail.com>. """Command-line parsing library This module is an optparse-inspired command-line parsing library that: - handles both optional and positional arguments - produces highly informative usage messages - supports parsers that dispatch to sub-parsers The...
gpl-2.0
8,972,317,420,490,129,000
36.168078
80
0.558987
false
aptrishu/coala-bears
tests/haskell/HaskellLintBearTest.py
8
1995
from queue import Queue from bears.haskell.HaskellLintBear import HaskellLintBear from coalib.testing.LocalBearTestHelper import LocalBearTestHelper from coalib.testing.BearTestHelper import generate_skip_decorator from coalib.settings.Section import Section good_single_line_file = """ myconcat = (++) """.splitlines...
agpl-3.0
-6,586,619,287,682,781,000
28.338235
74
0.607018
false
salivatears/ansible
lib/ansible/plugins/cache/base.py
124
1479
# (c) 2014, Brian Coca, Josh Drake, et al # # 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 License, or # (at your option) any later version. ...
gpl-3.0
5,494,726,859,176,623,000
22.47619
70
0.69236
false
alxgu/ansible
lib/ansible/modules/identity/keycloak/keycloak_client.py
27
32548
#!/usr/bin/python # -*- coding: utf-8 -*- # Copyright (c) 2017, Eike Frost <ei@kefro.st> # 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_version': '1.1...
gpl-3.0
-5,134,648,339,766,925,000
37.793802
146
0.607134
false
fparrel/regepe
wamp-src/cgi-bin/mathutil.py
2
13205
from math import sqrt,cos,sin,atan2,ceil,floor,log10,pi,atan,tan from log import Warn try: from math import fsum except ImportError: from mymath import fsum ## MISC MATH FUNCTIONS ## def Mean(numbers): "Returns the arithmetic mean of a numeric list." return fsum(numbers) / len(numbers) def InBound...
gpl-3.0
-1,777,497,493,673,461,200
32.0125
203
0.56259
false
edmundgentle/schoolscript
SchoolScript/bin/Debug/pythonlib/Lib/ctypes/test/test_values.py
3
3597
""" A testcase which accesses *values* in a dll. """ import unittest from ctypes import * import _ctypes_test class ValuesTestCase(unittest.TestCase): def test_an_integer(self): # This test checks and changes an integer stored inside the # _ctypes_test dll/shared lib. ctdll...
gpl-2.0
5,324,689,836,292,118,000
38.875
95
0.542952
false
beni55/networkx
examples/drawing/giant_component.py
33
2084
#!/usr/bin/env python """ This example illustrates the sudden appearance of a giant connected component in a binomial random graph. Requires pygraphviz and matplotlib to draw. """ # Copyright (C) 2006-2008 # Aric Hagberg <hagberg@lanl.gov> # Dan Schult <dschult@colgate.edu> # Pieter Swart <swart@lanl.gov...
bsd-3-clause
4,740,078,087,520,301,000
27.547945
77
0.578215
false
execuc/LCInterlocking
panel/hingeswidget.py
1
5079
#!/usr/bin/env python # -*- coding: utf-8 -*- # *************************************************************************** # * * # * Copyright (c) 2016 execuc * # * ...
lgpl-2.1
-4,049,863,118,812,959,000
69.541667
127
0.492617
false
junbochen/pylearn2
pylearn2/gui/tangent_plot.py
44
1730
""" Code for plotting curves with tangent lines. """ __author__ = "Ian Goodfellow" try: from matplotlib import pyplot except Exception: pyplot = None from theano.compat.six.moves import xrange def tangent_plot(x, y, s): """ Plots a curve with tangent lines. Parameters ---------- x : lis...
bsd-3-clause
6,418,200,293,736,956,000
21.467532
75
0.508092
false
goFrendiAsgard/kokoropy
kokoropy/packages/sqlalchemy/dialects/sqlite/pysqlite.py
23
14980
# sqlite/pysqlite.py # Copyright (C) 2005-2014 the SQLAlchemy authors and contributors # <see AUTHORS file> # # This module is part of SQLAlchemy and is released under # the MIT License: http://www.opensource.org/licenses/mit-license.php """ .. dialect:: sqlite+pysqlite :name: pysqlite :dbapi: sqlite3 :con...
mit
1,461,469,480,222,139,000
38.734748
135
0.70494
false
AsimmHirani/ISpyPi
tensorflow/contrib/tensorflow-master/tensorflow/python/debug/wrappers/local_cli_wrapper_test.py
20
13116
# 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
3,531,258,227,906,135,600
37.576471
80
0.685499
false
mcreenan/eve
eve/logging.py
17
1323
from __future__ import absolute_import import logging from flask import request # TODO right now we are only logging exceptions. We should probably # add support for some INFO and maybe DEBUG level logging (like, log each time # a endpoint is hit, etc.) class RequestFilter(logging.Filter): """ Adds Flask's requ...
bsd-3-clause
3,074,480,693,844,551,700
27.76087
78
0.643235
false
vybstat/scikit-learn
examples/bicluster/plot_spectral_biclustering.py
403
2011
""" ============================================= A demo of the Spectral Biclustering algorithm ============================================= This example demonstrates how to generate a checkerboard dataset and bicluster it using the Spectral Biclustering algorithm. The data is generated with the ``make_checkerboard`...
bsd-3-clause
6,146,612,982,188,058,000
31.435484
68
0.696668
false
NickDaly/GemRB-MultipleConfigs
gemrb/GUIScripts/pst/Start.py
2
3127
# -*-python-*- # GemRB - Infinity Engine Emulator # Copyright (C) 2003 The GemRB Project # # 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) ...
gpl-2.0
-7,505,186,259,014,147,000
27.953704
80
0.760793
false
sander76/home-assistant
homeassistant/components/iaqualink/switch.py
12
1713
"""Support for Aqualink pool feature switches.""" from homeassistant.components.switch import DOMAIN, SwitchEntity from homeassistant.config_entries import ConfigEntry from homeassistant.helpers.typing import HomeAssistantType from . import AqualinkEntity, refresh_system from .const import DOMAIN as AQUALINK_DOMAIN P...
apache-2.0
6,473,368,994,462,506,000
30.145455
74
0.645067
false
lupien/pyHegel
pyHegel/instruments_base.py
1
162990
# -*- coding: utf-8 -*- ########################## Copyrights and license ############################ # # # Copyright 2011-2015 Christian Lupien <christian.lupien@usherbrooke.ca> # # ...
lgpl-3.0
-8,544,140,090,590,581,000
42.050713
166
0.580011
false