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 |
|---|---|---|---|---|---|---|---|---|---|---|
tseaver/gcloud-python | monitoring/google/cloud/monitoring_v3/__init__.py | 3 | 2208 | # -*- coding: utf-8 -*-
#
# 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
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law... | apache-2.0 | -6,751,379,221,389,893,000 | 32.969231 | 74 | 0.760417 | false |
abusse/cinder | cinder/volume/drivers/ibm/storwize_svc/__init__.py | 2 | 51024 | # Copyright 2013 IBM Corp.
# Copyright 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/LIC... | apache-2.0 | -7,165,566,134,103,801,000 | 44.354667 | 79 | 0.544724 | false |
akaihola/bitcoin-price | old_versions/fast_dump_v11.py | 4 | 1386 | #!/usr/bin/env python3
import requests
import sys
def get_all():
page_num = 1
price_data = ''
while True:
req = requests.get("http://coinbase.com/api/v1/prices/historical?page="+str(page_num))
if req.status_code == 200:
price_data += '\n' + req.text
else:
pr... | mit | -6,026,962,514,987,022,000 | 26.72 | 94 | 0.562049 | false |
johankaito/fufuka | microblog/flask/venv/lib/python2.7/site-packages/pip/_vendor/distlib/metadata.py | 427 | 38314 | # -*- coding: utf-8 -*-
#
# Copyright (C) 2012 The Python Software Foundation.
# See LICENSE.txt and CONTRIBUTORS.txt.
#
"""Implementation of the Metadata for Python packages PEPs.
Supports all metadata formats (1.0, 1.1, 1.2, and 2.0 experimental).
"""
from __future__ import unicode_literals
import codecs
from email... | apache-2.0 | 1,468,120,979,943,838,700 | 35.213611 | 79 | 0.523151 | false |
henriquefacioli/gd-ae- | gda/admin.py | 1 | 1632 | from django.contrib import admin
from import_export import resources
from import_export.admin import ImportExportModelAdmin
from import_export.admin import ImportExportActionModelAdmin
from gda.models import Questionnaire, Question, Choice, Answer
## Questionnaires
# Class to import and export Questionnaire
class Qu... | gpl-3.0 | 6,312,490,031,681,824,000 | 23.358209 | 62 | 0.729779 | false |
hutchison/bp_mgmt | bp_cupid/tests/test_login.py | 1 | 1795 | from django.contrib.staticfiles.testing import StaticLiveServerTestCase
from selenium import webdriver
from django.contrib.auth.models import User
class TestLogin(StaticLiveServerTestCase):
def setUp(self):
self.username = 'alice'
self.email = 'alice@example.org'
self.password = 'test'
... | agpl-3.0 | 3,040,446,276,414,484,500 | 36.333333 | 130 | 0.677455 | false |
bbannier/ROOT | interpreter/llvm/src/tools/clang/bindings/python/tests/cindex/util.py | 12 | 2609 | # This file provides common utility functions for the test suite.
from clang.cindex import Cursor
from clang.cindex import TranslationUnit
def get_tu(source, lang='c', all_warnings=False, flags=[]):
"""Obtain a translation unit from source and language.
By default, the translation unit is created from source... | lgpl-2.1 | 951,695,942,087,871,500 | 27.053763 | 81 | 0.63051 | false |
StephaneP/volatility | volatility/conf.py | 57 | 15263 | ## This file was taken from PyFlag http://www.pyflag.net/
# Michael Cohen <scudette@users.sourceforge.net>
# David Collett <daveco@users.sourceforge.net>
#
# ******************************************************
# Version: FLAG $Version: 0.87-pre1 Date: Thu Jun 12 00:48:38 EST 2008$
# ********************************... | gpl-2.0 | -8,215,620,541,887,306,000 | 32.036797 | 167 | 0.594379 | false |
pincopallino93/rdfendpoints | lib/rdflib/plugins/parsers/pyRdfa/rdfs/__init__.py | 25 | 1729 | # -*- coding: utf-8 -*-
"""
Separate module to handle vocabulary expansions. The L{cache} module takes care of caching vocabulary graphs; the L{process}
module takes care of the expansion itself.
@organization: U{World Wide Web Consortium<http://www.w3.org>}
@author: U{Ivan Herman<a href="http://www.w3.org/People/Ivan... | apache-2.0 | -5,029,061,760,942,173,000 | 34.265306 | 124 | 0.725116 | false |
chispita/epiwork | apps/survey/migrations/0005_verify_single_user_assumption.py | 4 | 12061 | # encoding: utf-8
import datetime
from south.db import db
from south.v2 import DataMigration
from django.db import models
class Migration(DataMigration):
def forwards(self, orm):
for survey_user in orm['survey.SurveyUser'].objects.all():
assert survey_user.user.count() <= 1, survey_user.global... | agpl-3.0 | -6,844,392,325,395,507,000 | 72.09697 | 182 | 0.546306 | false |
harmy/kbengine | kbe/src/lib/python/Lib/test/test_plistlib.py | 55 | 7809 | # Copyright (C) 2003 Python Software Foundation
import unittest
import plistlib
import os
import datetime
from test import support
# This test data was generated through Cocoa's NSDictionary class
TESTDATA = b"""<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" \
"http://www... | lgpl-3.0 | 3,728,647,697,944,552,400 | 36.185714 | 91 | 0.543347 | false |
srm912/servo | tests/wpt/harness/wptrunner/metadata.py | 78 | 12836 | # 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 shutil
import sys
import tempfile
import types
import uuid
from collections import defaultdict
from mo... | mpl-2.0 | 932,387,140,883,712,600 | 35.674286 | 100 | 0.605718 | false |
therewillbecode/ichnaea | ichnaea/data/monitor.py | 1 | 3667 | from collections import defaultdict
from datetime import timedelta
from sqlalchemy import func
from sqlalchemy.orm import load_only
from ichnaea.models import (
ApiKey,
OCIDCell,
)
from ichnaea import util
class ApiKeyLimits(object):
def __init__(self, task, session):
self.task = task
s... | apache-2.0 | -2,295,239,486,701,998,600 | 29.057377 | 78 | 0.533951 | false |
audunv/andp | python/andp/view/web/widgets.py | 1 | 10766 | # -*- coding: utf-8; -*-
# Copyright (C) 2009 Østfold University College
#
# This file is part of ANDP.
#
# ANDP 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 you... | gpl-2.0 | -5,732,348,103,663,039,000 | 31.327327 | 139 | 0.511287 | false |
s0enke/boto | tests/integration/cloudformation/test_cert_verification.py | 126 | 1588 | # Copyright (c) 2012 Mitch Garnaat http://garnaat.org/
# Copyright (c) 2012 Amazon.com, Inc. or its affiliates.
# 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 Software withou... | mit | -2,095,200,390,268,686,000 | 39.717949 | 89 | 0.771411 | false |
GDGND/evm | allauth/account/auth_backends.py | 57 | 2101 | from django.contrib.auth.backends import ModelBackend
from ..utils import get_user_model
from .utils import filter_users_by_email
from .app_settings import AuthenticationMethod
from . import app_settings
class AuthenticationBackend(ModelBackend):
def authenticate(self, **credentials):
ret = None
... | mit | -1,464,291,154,103,092,700 | 36.517857 | 76 | 0.630176 | false |
SebastianLloret/CSCI-1310 | Assignments/Assignment8_Lloret/Assignment8_Lloret.py | 1 | 1401 | '''
Name: Sebastian Lloret
Recitation TA: Brennan Mcconnell
Assignment #: 8
'''
# Used to properly break the file into rows
import csv
def CreateDictionary(fileName):
slangDictionary = {}
# With just ensures a resource is cleaned even if exceptions are thrown.
# I had to use "rU" for universal n... | gpl-3.0 | 4,026,933,840,228,776,400 | 34.868421 | 94 | 0.613847 | false |
ewindisch/nova | nova/api/openstack/compute/contrib/console_output.py | 5 | 3746 | # Copyright 2011 OpenStack Foundation
# Copyright 2011 Grid Dynamics
# Copyright 2011 Eldar Nugaev, Kirill Shileev, Ilya Alekseyev
#
# 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
#
#... | apache-2.0 | 2,368,292,583,006,758,400 | 38.851064 | 79 | 0.626001 | false |
eahneahn/free | djangoproject/core/urls/__init__.py | 1 | 4601 | from django.conf.urls import patterns, include, url
from django.views.generic import TemplateView, RedirectView
from django.conf import settings
#from django.views.generic.simple import redirect_to, direct_to_template
from django.shortcuts import render,redirect
urlpatterns = patterns('core.views.main_views',
url(... | agpl-3.0 | -2,636,046,931,927,558,000 | 45.474747 | 131 | 0.63747 | false |
godiard/speak | aiml/DefaultSubs.py | 9 | 3590 | """This file contains the default (English) substitutions for the
PyAIML kernel. These substitutions may be overridden by using the
Kernel.loadSubs(filename) method. The filename specified should refer
to a Windows-style INI file with the following format:
# lines that start with '#' are comments
# The 'gen... | gpl-3.0 | 7,864,459,795,949,373,000 | 22.019231 | 70 | 0.521448 | false |
sanyaade-g2g-repos/key-mon | src/keymon/shaped_window.py | 15 | 3172 | #!/usr/bin/python
#
# Copyright 2010 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or a... | apache-2.0 | -5,034,165,190,098,059,000 | 32.744681 | 81 | 0.659836 | false |
4eek/edx-platform | lms/djangoapps/certificates/views/support.py | 52 | 5649 | """
Certificate end-points used by the student support UI.
See lms/djangoapps/support for more details.
"""
import logging
from functools import wraps
from django.http import (
HttpResponse,
HttpResponseBadRequest,
HttpResponseForbidden,
HttpResponseServerError
)
from django.views.decorators.http imp... | agpl-3.0 | 4,506,745,651,908,244,500 | 29.535135 | 106 | 0.653567 | false |
realms-team/solmanager | libs/smartmeshsdk-REL-1.3.0.1/libs/VManagerSDK/vmanager/configuration.py | 3 | 7415 | # coding: utf-8
"""
Copyright 2015 SmartBear Software
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable l... | bsd-3-clause | -5,936,042,476,031,169,000 | 30.155462 | 97 | 0.586514 | false |
111pontes/ydk-py | cisco-ios-xe/ydk/models/cisco_ios_xe/_meta/_Cisco_IOS_XE_bgp_oper.py | 1 | 48604 |
import re
import collections
from enum import Enum
from ydk._core._dm_meta_info import _MetaInfoClassMember, _MetaInfoClass, _MetaInfoEnum
from ydk.types import Empty, YList, YLeafList, DELETE, Decimal64, FixedBitsDict
from ydk._core._dm_meta_info import ATTRIBUTE, REFERENCE_CLASS, REFERENCE_LIST, REFERENCE_LEAFLI... | apache-2.0 | 29,991,553,735,175,612 | 49.471443 | 232 | 0.482738 | false |
tcmitchell/geni-tools | src/gcf/geni/am/aggregate.py | 3 | 3386 | #----------------------------------------------------------------------
# Copyright (c) 2011-2016 Raytheon BBN Technologies
#
# Permission is hereby granted, free of charge, to any person obtaining
# a copy of this software and/or hardware specification (the "Work") to
# deal in the Work without restriction, including ... | mit | -7,270,206,963,745,568,000 | 39.309524 | 72 | 0.620496 | false |
nicememory/pie | pyglet/pyglet/gl/glxext_mesa.py | 46 | 2050 | # ----------------------------------------------------------------------------
# pyglet
# Copyright (c) 2006-2008 Alex Holkner
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
# are met:
#
# * Redistribu... | apache-2.0 | -3,048,396,163,659,811,000 | 44.555556 | 96 | 0.704878 | false |
jpmpentwater/cvxpy | examples/extensions/ncvx/branch_and_bound.py | 12 | 3946 | import cvxopt
import cvxpy.problems.problem as problem
import cvxpy.settings as s
from boolean import Boolean
def branch(booleans):
bool_vals = (b for b in booleans if not b.fix_values)
# pick *a* boolean variable to branch on
# choose the most ambivalent one (smallest distance to 0.5)
# NOTE: if there... | gpl-3.0 | -6,258,885,580,991,344,000 | 31.883333 | 71 | 0.645971 | false |
Julian/urwid | examples/input_test.py | 11 | 3001 | #!/usr/bin/python
#
# Urwid keyboard input test app
# Copyright (C) 2004-2009 Ian Ward
#
# This library 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 2.1 of the Licens... | lgpl-2.1 | 2,864,991,766,714,025,500 | 28.421569 | 78 | 0.564812 | false |
vasyarv/edx-platform | lms/djangoapps/instructor_task/tasks.py | 12 | 12056 | """
This file contains tasks that are designed to perform background operations on the
running state of a course.
At present, these tasks all operate on StudentModule objects in one way or another,
so they share a visitor architecture. Each task defines an "update function" that
takes a module_descriptor, a particula... | agpl-3.0 | -522,893,223,179,021,700 | 44.323308 | 112 | 0.73565 | false |
MaximLich/oppia | core/tests/performance_tests/splash_test.py | 16 | 1597 | # Copyright 2016 The Oppia 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 applicable ... | apache-2.0 | -8,230,573,262,685,003,000 | 35.295455 | 74 | 0.722605 | false |
hmgaudecker/econ-project-templates | {{cookiecutter.project_slug}}/.mywaflib/waflib/Tools/cs.py | 55 | 6397 | #!/usr/bin/env python
# encoding: utf-8
# Thomas Nagy, 2006-2018 (ita)
"""
C# support. A simple example::
def configure(conf):
conf.load('cs')
def build(bld):
bld(features='cs', source='main.cs', gen='foo')
Note that the configuration may compile C# snippets::
FRAG = '''
namespace Moo {
public class Test ... | bsd-3-clause | -4,644,363,916,836,639,000 | 29.317536 | 115 | 0.663436 | false |
dhruve/spark | examples/src/main/python/ml/string_indexer_example.py | 123 | 1402 | #
# 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 us... | apache-2.0 | -2,375,105,611,489,932,000 | 33.195122 | 75 | 0.691155 | false |
piyushroshan/xen-4.3 | tools/python/logging/logging-0.4.9.2/logging/handlers.py | 42 | 28606 | # Copyright 2001-2004 by Vinay Sajip. All Rights Reserved.
#
# Permission to use, copy, modify, and distribute this software and its
# documentation for any purpose and without fee is hereby granted,
# provided that the above copyright notice appear in all copies and that
# both that copyright notice and this permissio... | gpl-2.0 | 3,200,678,611,683,470,300 | 35.348158 | 87 | 0.579808 | false |
raags/ansible-modules-core | windows/win_ping.py | 208 | 1376 | #!/usr/bin/python
# -*- coding: utf-8 -*-
# (c) 2012, Michael DeHaan <michael.dehaan@gmail.com>, and others
#
# 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 ... | gpl-3.0 | 5,008,684,289,495,437,000 | 27.666667 | 70 | 0.725291 | false |
lurch/python-gpiozero | gpiozero/pins/pigpiod.py | 1 | 9761 | from __future__ import (
unicode_literals,
absolute_import,
print_function,
division,
)
str = type('')
import warnings
import pigpio
import os
from . import Pin
from .data import pi_info
from ..exc import (
PinInvalidFunction,
PinSetInput,
PinFixedPull,
PinInvalidPull,
PinInval... | bsd-3-clause | 728,298,450,364,288,800 | 34.111511 | 95 | 0.580986 | false |
moehle/cvxpy_codegen | cvxpy_codegen/atoms/kron.py | 1 | 1098 | """
Copyright 2017 Nicholas Moehle
This file is part of CVXPY-CODEGEN.
CVXPY-CODEGEN 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.
CVXPY... | gpl-3.0 | 5,520,203,606,025,942,000 | 38.214286 | 84 | 0.70765 | false |
woobe/h2o | py/testdir_single_jvm/test_GLM2_tweedie.py | 2 | 2449 | import unittest, time, sys
sys.path.extend(['.','..','py'])
import h2o, h2o_cmd, h2o_glm, h2o_hosts, h2o_import as h2i, h2o_util
class Basic(unittest.TestCase):
def tearDown(self):
h2o.check_sandbox_for_errors()
@classmethod
def setUpClass(cls):
global localhost
localhost = h2o.dec... | apache-2.0 | -7,827,875,249,452,787,000 | 41.224138 | 397 | 0.600245 | false |
dfalt974/SickRage | lib/github/tests/Issue.py | 7 | 9092 | # -*- coding: utf-8 -*-
# ########################## Copyrights and license ############################
# #
# Copyright 2012 Vincent Jacques <vincent@vincent-jacques.net> #
# Copyright 2012 Zearin <zearin@gonk.net> ... | gpl-3.0 | 3,432,881,002,582,383,600 | 55.123457 | 151 | 0.613946 | false |
tmpgit/intellij-community | python/lib/Lib/encodings/mbcs.py | 860 | 1211 | """ Python 'mbcs' Codec for Windows
Cloned by Mark Hammond (mhammond@skippinet.com.au) from ascii.py,
which was written by Marc-Andre Lemburg (mal@lemburg.com).
(c) Copyright CNRI, All Rights Reserved. NO WARRANTY.
"""
# Import them explicitly to cause an ImportError
# on non-Windows systems
from codecs import mbcs... | apache-2.0 | 2,533,366,814,072,854,500 | 24.765957 | 65 | 0.729149 | false |
xen0l/ansible | lib/ansible/modules/windows/win_shell.py | 28 | 4846 | #!/usr/bin/python
# -*- coding: utf-8 -*-
# Copyright: (c) 2016, Ansible, inc
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
ANSIBLE_METADATA = {'metadata_version': '1.1',
'status': ['preview'],
'supported_by': 'core'}
DOCUMENTATIO... | gpl-3.0 | -990,400,696,005,544,700 | 32.652778 | 127 | 0.692117 | false |
draenog/gitolite-scripts | hooks/post-receive.d/gnome/git.py | 1 | 6496 | # Utility functions for git
#
# Copyright (C) 2008 Owen Taylor
# Copyright (C) 2009 Red Hat, Inc
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at you... | gpl-2.0 | 7,213,760,666,948,043,000 | 29.213953 | 92 | 0.605757 | false |
shibaniahegde/OpenStak_swift | swift/common/middleware/domain_remap.py | 20 | 6262 | # Copyright (c) 2010-2012 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 agree... | apache-2.0 | 5,116,620,896,321,533,000 | 42.186207 | 79 | 0.644363 | false |
chafique-delli/OpenUpgrade | addons/l10n_ro/__openerp__.py | 40 | 1804 | # -*- encoding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2012 (<http://www.erpsystems.ro>). All Rights Reserved
#
# This program is free software: you can redistribute it and/or modify
# it under the... | agpl-3.0 | 6,259,686,583,989,112,000 | 44.1 | 140 | 0.586475 | false |
git-keeper/git-keeper | git-keeper-server/gkeepserver/log_polling.py | 1 | 9468 | # Copyright 2016 Nathan Sommer and Ben Coleman
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is dis... | agpl-3.0 | -3,600,288,135,336,967,000 | 32.104895 | 79 | 0.621567 | false |
ammaradil/fibonacci | Lib/site-packages/django/utils/module_loading.py | 145 | 6290 | import copy
import os
import sys
from importlib import import_module
from django.utils import six
def import_string(dotted_path):
"""
Import a dotted module path and return the attribute/class designated by the
last name in the path. Raise ImportError if the import failed.
"""
try:
module... | mit | -2,450,045,815,625,227,000 | 37.121212 | 82 | 0.539428 | false |
Weihonghao/ECM | Vpy34/lib/python3.5/site-packages/pip/_vendor/requests/utils.py | 319 | 24163 | # -*- coding: utf-8 -*-
"""
requests.utils
~~~~~~~~~~~~~~
This module provides utility functions that are used within Requests
that are also useful for external consumption.
"""
import cgi
import codecs
import collections
import io
import os
import re
import socket
import struct
import warnings
from . import __vers... | agpl-3.0 | -1,493,731,281,731,799,600 | 28.575275 | 118 | 0.59856 | false |
Jordy281/Tic_Tac_Toe_SuperComputer | game.py | 1 | 1938 | import numpy as np
import copy
from random import randrange
"""
We will check across the diagonal top left to bottom right,
This will allow us to check all possible solutions for a win
"""
def threecheck(board):
win=False
#Top Left
if board[0]!=0:
#Row T-L to T-R
... | mit | -272,497,288,709,249,920 | 23.225 | 60 | 0.395769 | false |
xme1226/sahara | sahara/tests/unit/db/migration/test_migrations.py | 2 | 13912 | # Copyright 2014 OpenStack Foundation
# Copyright 2014 Mirantis 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 ... | apache-2.0 | 281,928,494,503,809,540 | 32.603865 | 79 | 0.565771 | false |
atosorigin/ansible | test/support/windows-integration/plugins/modules/win_lineinfile.py | 68 | 7333 | #!/usr/bin/python
# -*- coding: utf-8 -*-
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
ANSIBLE_METADATA = {'metadata_version': '1.1',
'status': ['preview'],
'supported_by': 'community'}
DOCUMENTATION = r'''
---
module: win_linein... | gpl-3.0 | -4,842,358,973,892,712,000 | 39.738889 | 152 | 0.691668 | false |
caser789/xuejiao-blog | app/api_1_0/posts.py | 1 | 1747 | from flask import jsonify, request, g, abort, url_for, current_app
from .. import db
from ..models import Post, Permission
from . import api
from .decorators import permission_required
from .errors import forbidden
@api.route('/posts/')
def get_posts():
page = request.args.get('page', 1, type=int)
pagination =... | mit | 1,953,097,622,053,751,600 | 32.596154 | 77 | 0.643389 | false |
wbyne/QGIS | python/plugins/processing/algs/qgis/HypsometricCurves.py | 2 | 8209 | # -*- coding: utf-8 -*-
"""
***************************************************************************
HypsometricCurves.py
---------------------
Date : November 2014
Copyright : (C) 2014 by Alexander Bruy
Email : alexander dot bruy at gmail dot com
******... | gpl-2.0 | 5,283,932,299,736,867,000 | 37.359813 | 102 | 0.542332 | false |
docker/docker-py | tests/integration/api_swarm_test.py | 4 | 9438 | import copy
import docker
import pytest
from ..helpers import force_leave_swarm, requires_api_version
from .base import BaseAPIIntegrationTest
class SwarmTest(BaseAPIIntegrationTest):
def setUp(self):
super(SwarmTest, self).setUp()
force_leave_swarm(self.client)
self._unlock_key = None
... | apache-2.0 | -8,196,727,219,823,829,000 | 36.011765 | 79 | 0.593452 | false |
sstruct/flasky | tests/test_api.py | 23 | 10686 | import unittest
import json
import re
from base64 import b64encode
from flask import url_for
from app import create_app, db
from app.models import User, Role, Post, Comment
class APITestCase(unittest.TestCase):
def setUp(self):
self.app = create_app('testing')
self.app_context = self.app.app_conte... | mit | 8,774,952,314,524,759,000 | 39.324528 | 77 | 0.580011 | false |
codingforfun/Olena-Mirror | swilena/python/box2d-misc.py | 2 | 1329 | #! /usr/bin/env python
# Copyright (C) 2009 EPITA Research and Development Laboratory (LRDE)
#
# This file is part of Olena.
#
# Olena 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, version 2 of the License.... | gpl-2.0 | 3,881,340,963,983,665,700 | 27.276596 | 72 | 0.732129 | false |
Beauhurst/django | django/contrib/admin/migrations/0001_initial.py | 95 | 1893 | import django.contrib.admin.models
from django.conf import settings
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
('contenttypes', '__first__'),
]
operations = [
migratio... | bsd-3-clause | -2,820,221,301,498,797,000 | 39.276596 | 114 | 0.522451 | false |
vadimtk/chrome4sdp | tools/telemetry/telemetry/internal/platform/power_monitor/msr_power_monitor_unittest.py | 24 | 1071 | # Copyright 2014 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 logging
import time
import unittest
from telemetry import decorators
from telemetry.internal.platform.power_monitor import msr_power_monitor
from tel... | bsd-3-clause | 958,169,318,238,568,700 | 35.931034 | 74 | 0.764706 | false |
alexallah/django | django/forms/widgets.py | 1 | 35356 | """
HTML Widget classes
"""
import copy
import datetime
import re
from itertools import chain
from django.conf import settings
from django.forms.utils import to_current_timezone
from django.templatetags.static import static
from django.utils import datetime_safe, formats
from django.utils.dates import MONTHS
from dja... | bsd-3-clause | -4,917,147,239,116,290,000 | 33.028874 | 115 | 0.581203 | false |
dcramer/django-compositepks | django/db/models/fields/related.py | 13 | 42537 | from django.db import connection, transaction
from django.db.models import signals, get_model
from django.db.models.fields import AutoField, Field, IntegerField, PositiveIntegerField, PositiveSmallIntegerField, FieldDoesNotExist
from django.db.models.related import RelatedObject
from django.db.models.query import Query... | bsd-3-clause | -9,099,354,057,314,996,000 | 44.936285 | 222 | 0.604368 | false |
Agana/MyBlogAgain | django/utils/synch.py | 376 | 2549 | """
Synchronization primitives:
- reader-writer lock (preference to writers)
(Contributed to Django by eugene@lazutkin.com)
"""
try:
import threading
except ImportError:
import dummy_threading as threading
class RWLock:
"""
Classic implementation of reader-writer lock with preference to writers.... | bsd-3-clause | -5,419,001,903,776,602,000 | 28.298851 | 99 | 0.534327 | false |
fernandezcuesta/ansible | contrib/inventory/openstack.py | 64 | 8980 | #!/usr/bin/env python
# Copyright (c) 2012, Marco Vito Moscaritolo <marco@agavee.com>
# Copyright (c) 2013, Jesse Keating <jesse.keating@rackspace.com>
# Copyright (c) 2015, Hewlett-Packard Development Company, L.P.
# Copyright (c) 2016, Rackspace Australia
#
# This module is free software: you can redistribute it and... | gpl-3.0 | -208,964,337,351,742,720 | 35.356275 | 78 | 0.644098 | false |
mogoweb/chromium-crosswalk | chrome/test/mini_installer/file_verifier.py | 125 | 1116 | # 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.
import os
import verifier
class FileVerifier(verifier.Verifier):
"""Verifies that the current files match the expectation dictionaries."""
def _Verif... | bsd-3-clause | 5,927,250,617,274,627,000 | 35 | 77 | 0.694444 | false |
AmesianX/amoco | amoco/arch/arm/v8/asm64.py | 6 | 15185 | # -*- coding: utf-8 -*-
# This code is part of Amoco
# Copyright (C) 2013 Axel Tillequin (bdcht3@gmail.com)
# published under GPLv2 license
from amoco.logger import Log
logger = Log(__name__)
from .env64 import *
from .utils import *
from amoco.cas.utils import *
def i_ADC(i,fmap):
fmap[pc] = fmap[pc]+i.length
... | gpl-2.0 | 4,208,071,343,236,591,000 | 24.957265 | 84 | 0.569114 | false |
akirk/youtube-dl | youtube_dl/extractor/folketinget.py | 92 | 2651 | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from .common import InfoExtractor
from ..compat import compat_parse_qs
from ..utils import (
int_or_none,
parse_duration,
parse_iso8601,
xpath_text,
)
class FolketingetIE(InfoExtractor):
IE_DESC = 'Folketinget (ft.dk; Danish parliame... | unlicense | -5,576,901,220,354,292,000 | 33.337662 | 113 | 0.530257 | false |
leemac/JellyfishRss | rss/migrations/0001_initial.py | 1 | 8815 | # -*- coding: utf-8 -*-
from south.utils import datetime_utils as datetime
from south.db import db
from south.v2 import SchemaMigration
from django.db import models
class Migration(SchemaMigration):
def forwards(self, orm):
# Adding model 'Folder'
db.create_table(u'rss_folder', (
(u'i... | mit | -3,279,557,934,306,948,000 | 61.084507 | 195 | 0.568009 | false |
evilpie/servo | tests/wpt/css-tests/tools/html5lib/html5lib/treebuilders/dom.py | 920 | 8469 | from __future__ import absolute_import, division, unicode_literals
from xml.dom import minidom, Node
import weakref
from . import _base
from .. import constants
from ..constants import namespaces
from ..utils import moduleFactoryFactory
def getDomBuilder(DomImplementation):
Dom = DomImplementation
class A... | mpl-2.0 | 1,695,116,534,286,119,700 | 36.30837 | 85 | 0.531822 | false |
guarddogofww/cs108test | src/jarabe/model/shell.py | 3 | 28033 | # Copyright (C) 2006-2007 Owen Williams.
# Copyright (C) 2006-2008 Red Hat, Inc.
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any late... | gpl-3.0 | -8,484,930,277,310,287,000 | 34.802043 | 79 | 0.582991 | false |
cwisecarver/osf.io | addons/dropbox/migrations/0001_initial.py | 28 | 1508 | # -*- coding: utf-8 -*-
# Generated by Django 1.9 on 2017-03-23 20:34
from __future__ import unicode_literals
from django.db import migrations, models
import osf.models.base
import osf.utils.datetime_aware_jsonfield
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operation... | apache-2.0 | 8,273,435,826,323,470,000 | 34.904762 | 129 | 0.574271 | false |
nuagenetworks/vspk-python | vspk/v5_0/numacfilterprofile.py | 1 | 7688 | # -*- coding: utf-8 -*-
#
# Copyright (c) 2015, Alcatel-Lucent Inc, 2017 Nokia
# 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 copyrigh... | bsd-3-clause | 2,725,360,634,292,582,000 | 28.802326 | 175 | 0.596124 | false |
teeple/pns_server | work/install/Python-2.7.4/Lib/lib2to3/fixes/fix_itertools.py | 148 | 1549 | """ Fixer for itertools.(imap|ifilter|izip) --> (map|filter|zip) and
itertools.ifilterfalse --> itertools.filterfalse (bugs 2360-2363)
imports from itertools are fixed in fix_itertools_import.py
If itertools is imported as something else (ie: import itertools as it;
it.izip(spam, eggs)) method calls w... | gpl-2.0 | 7,372,252,283,408,376,000 | 35.023256 | 77 | 0.567463 | false |
benchisell/photostream-bc | flask/lib/python2.7/site-packages/migrate/versioning/schemadiff.py | 52 | 8741 | """
Schema differencing support.
"""
import logging
import sqlalchemy
from sqlalchemy.types import Float
log = logging.getLogger(__name__)
def getDiffOfModelAgainstDatabase(metadata, engine, excludeTables=None):
"""
Return differences of model against database.
:return: object which will evaluate to... | bsd-3-clause | -7,693,069,572,257,641,000 | 28.934932 | 85 | 0.569386 | false |
bguillot/OpenUpgrade | addons/sale/sale.py | 17 | 67360 | # -*- 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 | 6,351,337,016,951,447,000 | 51.217054 | 306 | 0.576292 | false |
mmalorni/server-tools | __unported__/fetchmail_attach_from_folder/match_algorithm/email_domain.py | 6 | 1985 | # -*- encoding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# This module copyright (C) 2013 Therp BV (<http://therp.nl>)
# All Rights Reserved
#
# This program is free software: you can redistribute it and/or modify
#... | agpl-3.0 | 4,544,912,026,635,328,500 | 44.113636 | 78 | 0.578841 | false |
loco-odoo/localizacion_co | openerp/addons/crm_partner_assign/report/crm_partner_report.py | 264 | 3374 | # -*- 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 | 1,550,536,960,857,555,000 | 46.521127 | 131 | 0.577356 | false |
fuselock/odoo | addons/email_template/wizard/email_template_preview.py | 377 | 3851 | # -*- coding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2009 Sharoon Thomas
# Copyright (C) 2010-Today OpenERP SA (<http://www.openerp.com>)
#
# This program is free software: you can redistribute it ... | agpl-3.0 | -3,725,880,260,493,870,000 | 42.761364 | 194 | 0.613347 | false |
fronzbot/blinkpy | blinkpy/blinkpy.py | 1 | 13098 | # -*- coding: utf-8 -*-
"""
blinkpy is an unofficial api for the Blink security camera system.
repo url: https://github.com/fronzbot/blinkpy
Original protocol hacking by MattTW :
https://github.com/MattTW/BlinkMonitorProtocol
Published under the MIT license - See LICENSE file for more details.
"Blink Wire-Free HS Ho... | mit | 1,351,181,949,835,077,000 | 35.18232 | 172 | 0.563216 | false |
butchman0922/gourmet | gourmet/plugins/import_export/plaintext_plugin/plaintext_importer_plugin.py | 6 | 2087 | from gourmet.plugin import ImporterPlugin
from gourmet.importers.importer import Tester
from gourmet.threadManager import get_thread_manager
from gourmet.importers.interactive_importer import InteractiveImporter
from gourmet import check_encodings
import os.path
import fnmatch
from gettext import gettext as _
MAX_PLAI... | gpl-2.0 | 203,876,569,544,358,080 | 36.267857 | 282 | 0.621466 | false |
GbalsaC/bitnamiP | lms/djangoapps/notes/models.py | 100 | 3156 | from django.db import models
from django.contrib.auth.models import User
from django.core.urlresolvers import reverse
from django.core.exceptions import ValidationError
from django.utils.html import strip_tags
import json
from xmodule_django.models import CourseKeyField
class Note(models.Model):
user = models.Fo... | agpl-3.0 | -603,661,891,980,483,300 | 36.571429 | 94 | 0.60076 | false |
IllusionRom-deprecated/android_platform_external_chromium_org | tools/telemetry/telemetry/page/actions/click_element_unittest.py | 23 | 3183 | # Copyright (c) 2012 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.
from telemetry.core import util
from telemetry.page.actions import click_element
from telemetry.page.actions import wait
from telemetry.unittest import t... | bsd-3-clause | 6,434,020,205,041,921,000 | 36.447059 | 72 | 0.698712 | false |
vlegoff/tsunami | src/secondaires/crafting/commandes/__init__.py | 1 | 1676 | # -*-coding:Utf-8 -*
# Copyright (c) 2010-2017 LE GOFF Vincent
# 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
# ... | bsd-3-clause | -5,403,795,600,636,229,000 | 49.787879 | 79 | 0.782816 | false |
pap/nupic | tests/unit/nupic/support/consoleprinter_test/consoleprinter_test.py | 34 | 2887 | #!/usr/bin/env python
# ----------------------------------------------------------------------
# Numenta Platform for Intelligent Computing (NuPIC)
# Copyright (C) 2014, Numenta, Inc. Unless you have an agreement
# with Numenta, Inc., for a separate license for this software code, the
# following terms and conditions ... | agpl-3.0 | 3,753,009,007,812,555,000 | 27.303922 | 72 | 0.638379 | false |
ritchyteam/odoo | addons/l10n_fr_hr_payroll/__openerp__.py | 374 | 2165 | # -*- encoding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2011 OpenERP SA (<http://openerp.com>).
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the G... | agpl-3.0 | 4,053,482,730,837,610,000 | 36.982456 | 82 | 0.630023 | false |
pgleeson/TestArea | templates/clusterUtils/pullallsims.py | 5 | 1714 | # -*- coding: utf-8 -*-
'''
This file can be placed in the simulations directory of a neuroConstruct project and
when run it will search in all subdirectories for time.dat, and if it doesn't find it,
will try running pullsim.sh, which will attempt to retrieve the saved data from a remotely
executed simulation
'''
im... | gpl-2.0 | -2,094,117,950,751,211,500 | 33.28 | 113 | 0.607935 | false |
vitan/hue | desktop/core/ext-py/Django-1.6.10/docs/_ext/applyxrefs.py | 132 | 1842 | """Adds xref targets to the top of files."""
import sys
import os
testing = False
DONT_TOUCH = (
'./index.txt',
)
def target_name(fn):
if fn.endswith('.txt'):
fn = fn[:-4]
return '_' + fn.lstrip('./').replace('/', '-')
def process_file(fn, lines):
lines.insert(0, '\n')
lines... | apache-2.0 | 5,769,537,809,609,714,000 | 24.232877 | 75 | 0.516287 | false |
gohin/django | django/http/cookie.py | 460 | 4390 | from __future__ import unicode_literals
import sys
from django.utils import six
from django.utils.encoding import force_str
from django.utils.six.moves import http_cookies
# Some versions of Python 2.7 and later won't need this encoding bug fix:
_cookie_encodes_correctly = http_cookies.SimpleCookie().value_encode(';... | bsd-3-clause | 4,626,601,587,904,040,000 | 40.415094 | 94 | 0.572893 | false |
witcxc/libpinyin | scripts/pinyin.py | 2 | 13821 | # -*- coding: utf-8 -*-
# vim:set et sts=4 sw=4:
#
# libpinyin - Library to deal with pinyin.
#
# Copyright (c) 2007-2008 Peng Huang <shawn.p.huang@gmail.com>
# Copyright (C) 2011 Peng Wu <alexepico@gmail.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU Gener... | gpl-2.0 | 391,503,750,518,905,100 | 33.5525 | 81 | 0.36705 | false |
saimn/astropy | astropy/nddata/_testing.py | 11 | 1605 | # Licensed under a 3-clause BSD style license - see LICENSE.rst
"""Testing utilities. Not part of the public API!"""
from astropy.wcs import WCS
from astropy.wcs.wcsapi import BaseHighLevelWCS
def assert_wcs_seem_equal(wcs1, wcs2):
"""Just checks a few attributes to make sure wcs instances seem to be
equal.
... | bsd-3-clause | -7,296,106,230,798,705,000 | 28.181818 | 73 | 0.614953 | false |
mascot6699/Hackapi-Demo | src/core/views.py | 1 | 1412 |
from . import models, serializers, utils
from datetime import datetime, timedelta
from rest_framework.views import APIView
from rest_framework.response import Response
from rest_framework import status, permissions
class Process(APIView):
"""
These apis are for general purpose
"""
def get(self, re... | mit | -4,467,069,860,691,169,300 | 31.090909 | 83 | 0.631728 | false |
altaf-ali/luigi | test/scheduler_visualisation_test.py | 49 | 13542 | # -*- coding: utf-8 -*-
#
# Copyright 2012-2015 Spotify AB
#
# 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... | apache-2.0 | -3,280,088,414,123,040,300 | 30.131034 | 110 | 0.583001 | false |
uwevil/namebench | libnamebench/selectors.py | 176 | 3262 | #!/usr/bin/env python
# Copyright 2009 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... | apache-2.0 | 2,139,029,900,928,761,600 | 28.125 | 102 | 0.686695 | false |
TiVoMaker/boto | tests/integration/ec2/autoscale/test_cert_verification.py | 126 | 1575 | # Copyright (c) 2012 Mitch Garnaat http://garnaat.org/
# Copyright (c) 2012 Amazon.com, Inc. or its affiliates.
# 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 Software withou... | mit | 4,907,623,829,306,504,000 | 39.384615 | 84 | 0.767619 | false |
asutherland/opc-reviewboard | contrib/internal/release.py | 1 | 1785 | #!/usr/bin/env python
#
# Performs a release of Review Board. This can only be run by the core
# developers with release permissions.
#
import os
import re
import subprocess
import sys
sys.path.insert(0, os.path.join(os.path.dirname(__file__), "..", ".."))
from reviewboard import get_package_version, VERSION
PY_VER... | mit | -4,015,365,322,817,112,600 | 20.768293 | 72 | 0.60056 | false |
sliz1/servo | tests/wpt/css-tests/css-text-decor-3_dev/xhtml1print/support/generate-text-emphasis-line-height-tests.py | 829 | 3431 | #!/usr/bin/env python
# - * - coding: UTF-8 - * -
"""
This script generates tests text-emphasis-line-height-001 ~ 004 except
001z. They test the line height expansion in different directions. This
script outputs a list of all tests it generated in the format of Mozilla
reftest.list to the stdout.
"""
from __future__ ... | mpl-2.0 | 7,694,887,479,603,598,000 | 40.597561 | 213 | 0.634125 | false |
tordans/volunteer_planner | scheduler/management/commands/calculate_volunteer_hours.py | 3 | 1164 | # coding: utf-8
import datetime
from django.core.management.base import BaseCommand
from registration.models import RegistrationProfile
from stats.models import ValueStore
class Command(BaseCommand):
help = 'creates bulk shifts from existing data'
args = ""
option_list = BaseCommand.option_list
d... | agpl-3.0 | 6,819,728,927,408,078,000 | 32.257143 | 77 | 0.636598 | false |
syedjafri/ThinkStats2 | code/chap02soln.py | 69 | 2263 | """This file contains code for use with "Think Stats",
by Allen B. Downey, available from greenteapress.com
Copyright 2014 Allen B. Downey
License: GNU GPLv3 http://www.gnu.org/licenses/gpl.html
"""
from __future__ import print_function
import sys
from operator import itemgetter
import first
import thinkstats2
de... | gpl-3.0 | -2,958,441,997,668,105,700 | 22.329897 | 75 | 0.653115 | false |
guilhermegm/django-tastypie | tests/core/tests/paginator.py | 25 | 11701 | # -*- coding: utf-8 -*-
from django.conf import settings
from django.test import TestCase
from tastypie.exceptions import BadRequest
from tastypie.paginator import Paginator
from core.models import Note
from core.tests.resources import NoteResource
from django.db import reset_queries
from django.http import QueryDict
... | bsd-3-clause | 7,914,788,198,693,054,000 | 40.332155 | 124 | 0.600239 | false |
wroersma/volatility | volatility/scan.py | 14 | 6848 | # Volatility
# Copyright (C) 2007-2013 Volatility Foundation
#
# Derived from source in PyFlag developed by:
# Copyright 2004: Commonwealth of Australia.
# Michael Cohen <scudette@users.sourceforge.net>
# David Collett <daveco@users.sourceforge.net>
#
# This file is part of Volatility.
#
# Volatility is free software;... | gpl-2.0 | -1,684,165,884,424,054,000 | 38.583815 | 112 | 0.618867 | false |
hasecbinusr/pysal | pysal/esda/tests/test_geary.py | 5 | 2997 | """Geary Unittest."""
import unittest
from ... import open as popen
from ... import examples
from .. import geary
import numpy as np
from ...common import pandas
PANDAS_EXTINCT = pandas is None
class Geary_Tester(unittest.TestCase):
"""Geary class for unit tests."""
def setUp(self):
self.w = popen(ex... | bsd-3-clause | 7,710,925,304,270,476,000 | 37.423077 | 70 | 0.680347 | false |
peterbarker/ardupilot-1 | Tools/LogAnalyzer/DataflashLog.py | 17 | 29790 | #
# Code to abstract the parsing of APM Dataflash log files, currently only used by the LogAnalyzer
#
# Initial code by Andrew Chapman (amchapman@gmail.com), 16th Jan 2014
#
from __future__ import print_function
import collections
import os
import numpy
import bisect
import sys
import ctypes
from VehicleType import V... | gpl-3.0 | -1,630,936,543,845,855,700 | 41.925072 | 212 | 0.557033 | false |
DazWorrall/zulip | zilencer/management/commands/profile_request.py | 117 | 1632 | from __future__ import absolute_import
from optparse import make_option
from django.core.management.base import BaseCommand
from zerver.models import get_user_profile_by_email, UserMessage
from zerver.views.old_messages import get_old_messages_backend
import cProfile
import logging
from zerver.middleware import LogReq... | apache-2.0 | 7,563,429,974,418,282,000 | 31.64 | 122 | 0.647059 | false |
hellotomfan/v8-coroutine | build/gyp/test/library/gyptest-shared-obj-install-path.py | 289 | 1180 | #!/usr/bin/env python
# Copyright (c) 2012 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.
"""
Verifies that .so files that are order only dependencies are specified by
their install location rather than by their alias.
"""
# Pyth... | gpl-2.0 | 5,909,126,666,171,539,000 | 27.095238 | 73 | 0.731356 | 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.