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 |
|---|---|---|---|---|---|---|---|---|---|---|
GitAngel/django | django/db/models/aggregates.py | 161 | 6624 | """
Classes to represent the definitions of aggregate functions.
"""
from django.core.exceptions import FieldError
from django.db.models.expressions import Func, Value
from django.db.models.fields import FloatField, IntegerField
__all__ = [
'Aggregate', 'Avg', 'Count', 'Max', 'Min', 'StdDev', 'Sum', 'Variance',
]
... | bsd-3-clause | -5,585,138,041,370,369,000 | 36.005587 | 110 | 0.621679 | false |
andmaj/unrank-bottleneck-bench | sdsl_linear/gtest-1.6.0/scripts/pump.py | 603 | 23316 | #!/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... | gpl-3.0 | -910,758,963,271,655,700 | 26.527745 | 80 | 0.622234 | false |
tonicbupt/flask-navigator | tests/test_navbar.py | 2 | 1514 | from pytest import fixture, raises
from flask.ext.navigation.navbar import NavigationBar
from flask.ext.navigation.item import Item, ItemReference
@fixture
def navbar():
navbar = NavigationBar('mybar', [
Item(u'Home', 'home'),
Item(u'News', 'news'),
])
return navbar
def test_attrs(navba... | mit | -4,549,393,273,315,191,000 | 23.819672 | 66 | 0.626816 | false |
ResearchSoftwareInstitute/MyHPOM | hs_file_types/models/base.py | 1 | 39179 | import os
import copy
from django.db import models
from django.contrib.contenttypes.models import ContentType
from django.contrib.contenttypes.fields import GenericRelation
from django.core.exceptions import ValidationError, ObjectDoesNotExist
from django.forms.models import model_to_dict
from django.contrib.postgres... | bsd-3-clause | -2,300,341,929,535,121,700 | 49.553548 | 100 | 0.524465 | false |
forrestv/pyderiv | deriv.py | 1 | 5500 | # This file is part of pyderiv. http://forre.st/pyderiv
#
# pyderiv 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.
#
# pyderiv is distr... | gpl-3.0 | -2,566,797,785,603,388,400 | 29.054645 | 97 | 0.559636 | false |
David-Amaro/bank-payment | __unported__/account_banking/migrations/6.1.0.1.81/post-set-statement-line-state.py | 14 | 1439 | # -*- coding: utf-8 -*-
##############################################################################
#
# Copyright (C) 2011 Therp BV (<http://therp.nl>)
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published
# by ... | agpl-3.0 | 533,808,001,725,223,360 | 41.323529 | 78 | 0.578874 | false |
chrta/canfestival-3-ct | objdictgen/eds_utils.py | 2 | 40678 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
#This file is part of CanFestival, a library implementing CanOpen Stack.
#
#Copyright (C): Edouard TISSERANT, Francis DUPIN and Laurent BESSARD
#
#See COPYING file for copyrights details.
#
#This library is free software; you can redistribute it and/or
#modify it under th... | lgpl-2.1 | 6,767,115,358,776,499,000 | 50.621827 | 167 | 0.54012 | false |
ZirkCoin/ZirkCoin | share/qt/extract_strings_qt.py | 1294 | 1784 | #!/usr/bin/python
'''
Extract _("...") strings for translation and convert to Qt4 stringdefs so that
they can be picked up by Qt linguist.
'''
from subprocess import Popen, PIPE
import glob
OUT_CPP="src/qt/bitcoinstrings.cpp"
EMPTY=['""']
def parse_po(text):
"""
Parse 'po' format produced by xgettext.
Ret... | mit | 5,940,951,416,686,363,000 | 24.485714 | 80 | 0.563341 | false |
iwarobots/aerodynamics | src/test_section.py | 1 | 1447 | #!/usr/bin/env python
from __future__ import absolute_import, division
from common import Model
# TODO: Refinement needed.
class TestSection(Model):
def __init__(self,
in_mach,
in_area,
in_p,
in_t,
p01,
t01,
... | apache-2.0 | -5,986,436,818,786,117,000 | 17.551282 | 48 | 0.485142 | false |
CeltonMcGrath/TACTIC | 3rd_party/CherryPy/cherrypy/tutorial/tut06_default_method.py | 9 | 2118 | """
Tutorial - The default method
Request handler objects can implement a method called "default" that
is called when no other suitable method/object could be found.
Essentially, if CherryPy2 can't find a matching request handler object
for the given request URI, it will use the default method of the object
located de... | epl-1.0 | -3,320,382,102,094,509,600 | 34.898305 | 74 | 0.653447 | false |
Jumpscale/jumpscale_core8 | lib/JumpScale/baselib/atyourservice81/Service.py | 1 | 30866 | from JumpScale import j
import capnp
import time
class Service:
def __init__(self, aysrepo, actor=None, model=None, name="", args={}, path=None):
"""
init from a template or from a model
"""
self.model = None
self._schema = None
self._path = ""
self._schema... | apache-2.0 | 1,746,238,077,986,849,800 | 39.242503 | 248 | 0.592918 | false |
dstufft/ooni-backend | oonib/otime.py | 1 | 2318 | import time
from oonib import errors as e
from datetime import datetime
def utcDateNow():
"""
Returns the datetime object of the current UTC time.
"""
return datetime.utcnow()
def utcTimeNow():
"""
Returns seconds since epoch in UTC time, it's of type float.
"""
return time.mktime(ti... | bsd-2-clause | -3,563,289,505,155,473,000 | 22.414141 | 79 | 0.595341 | false |
Alwnikrotikz/cortex-vfx | python/IECoreMaya/ParameterUI.py | 12 | 14067 | ##########################################################################
#
# Copyright (c) 2007-2011, Image Engine Design 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:
#
# * Redis... | bsd-3-clause | 190,147,296,433,490,340 | 34.255639 | 140 | 0.699296 | false |
jaggu303619/asylum | openerp/addons/portal_crm/__openerp__.py | 55 | 1734 | # -*- 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 | -8,797,731,151,924,660,000 | 37.533333 | 132 | 0.546136 | false |
JuliBakagianni/META-SHARE | misc/tools/generateDS-2.7a/generate_coverage.py | 33 | 3800 | #!/usr/bin/env python
#
# Imports
import sys
from optparse import OptionParser
import os
import re
#
# Globals and constants
EXCLUDE_BASE = [
'MixedContainer',
'_MemberSpec',
]
PATTERN = "^class\s*(\w*)"
RE_PATTERN = re.compile(PATTERN)
#
# Functions for external use
def generate_coverage(outfile,... | bsd-3-clause | 802,192,059,007,941,100 | 18.28934 | 72 | 0.594474 | false |
cernops/nova | nova/tests/functional/api_sample_tests/test_networks_associate.py | 9 | 3149 | # Copyright 2012 Nebula, Inc.
# Copyright 2014 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 | -847,080,795,879,207,200 | 38.860759 | 78 | 0.618927 | false |
linvictor88/vse-lbaas-driver | quantum/plugins/bigswitch/tests/test_server.py | 3 | 6568 | #!/usr/bin/env python
# vim: tabstop=4 shiftwidth=4 softtabstop=4
# Copyright 2012, Big Switch Networks, 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
... | apache-2.0 | -971,353,842,177,792,800 | 34.502703 | 78 | 0.515073 | false |
sankalpg/Essentia_tonicDebug_TEMP | src/python/essentia/extractor/segmentation_simple.py | 10 | 2872 | # Copyright (C) 2006-2013 Music Technology Group - Universitat Pompeu Fabra
#
# This file is part of Essentia
#
# Essentia is free software: you can redistribute it and/or modify it under
# the terms of the GNU Affero General Public License as published by the Free
# Software Foundation (FSF), either version 3 of the ... | agpl-3.0 | -1,822,485,630,926,241,500 | 30.911111 | 95 | 0.685585 | false |
shubhdev/edx-platform | common/test/acceptance/tests/studio/test_studio_settings_details.py | 4 | 7591 | """
Acceptance tests for Studio's Settings Details pages
"""
from unittest import skip
from .base_studio_test import StudioCourseTest
from ...fixtures.course import CourseFixture
from ...pages.studio.settings import SettingsPage
from ...pages.studio.overview import CourseOutlinePage
from ...tests.studio.base_studio_te... | agpl-3.0 | -5,740,725,429,276,370,000 | 37.928205 | 113 | 0.642735 | false |
torresj/cafe | contacto.py | 2 | 7363 | # -*- coding: utf-8 -*-
"""
Created on Sun Nov 3 13:07:55 2013
@author: jaime
"""
import web
from web.contrib.template import render_mako
from web import form
import pymongo
import feedparser
import time
from keys import *
import tweepy
render = render_mako(
directories=['plantillas'],
input_encodin... | gpl-2.0 | 1,535,667,005,186,142,700 | 27.307692 | 155 | 0.555374 | false |
hynekcer/django | tests/foreign_object/test_empty_join.py | 232 | 1498 | from django.test import TestCase
from .models import SlugPage
class RestrictedConditionsTests(TestCase):
def setUp(self):
slugs = [
'a',
'a/a',
'a/b',
'a/b/a',
'x',
'x/y/z',
]
SlugPage.objects.bulk_create([SlugPage(sl... | bsd-3-clause | 1,918,732,513,960,612,900 | 30.87234 | 78 | 0.530708 | false |
ppyordanov/HCI_4_Future_Cities | Server/src/virtualenv/Lib/site-packages/pip/_vendor/requests/packages/urllib3/fields.py | 1 | 5990 | # urllib3/fields.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
import email.utils
import mimetypes
from .packages import six
def guess_content_type(filename... | mit | -6,864,710,002,359,419,000 | 32.463687 | 97 | 0.599165 | false |
malja/cvut-python | cviceni07/frequency.py | 1 | 1393 | import sys
from collections import Counter
def loadFile( filename ):
words = []
with open(filename) as file:
for line in file:
# Kvůli poslednímu slovu
line += " "
word = ""
for char in line:
if not char.isalpha():
... | mit | 2,125,759,338,699,850,800 | 21.095238 | 106 | 0.485981 | false |
erikdejonge/newsrivr | daemons/d_checkdoubleusernames.py | 1 | 3053 | from __future__ import print_function
from __future__ import unicode_literals
from __future__ import division
from __future__ import absolute_import
from future import standard_library
standard_library.install_aliases()
from builtins import str
from d_utils import *
def clog(s):
s= str(s)
print('\033[%96m'+strfti... | gpl-2.0 | -375,972,500,351,243,840 | 38.141026 | 95 | 0.666885 | false |
nikoonia/gem5v | configs/common/Benchmarks.py | 36 | 6206 | # Copyright (c) 2006-2007 The Regents of The University of Michigan
# 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,316,038,759,171,885,000 | 48.253968 | 78 | 0.621495 | false |
fjbatresv/odoo | addons/website_sale_delivery/controllers/main.py | 124 | 1551 | # -*- coding: utf-8 -*-
import openerp
from openerp import http
from openerp.http import request
import openerp.addons.website_sale.controllers.main
class website_sale(openerp.addons.website_sale.controllers.main.website_sale):
@http.route(['/shop/payment'], type='http', auth="public", website=True)
def paym... | agpl-3.0 | 837,645,498,407,480,600 | 42.083333 | 129 | 0.652482 | false |
bcarroll/authmgr | python-3.6.2-Win64/Lib/site-packages/werkzeug/contrib/securecookie.py | 91 | 12174 | # -*- coding: utf-8 -*-
r"""
werkzeug.contrib.securecookie
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
This module implements a cookie that is not alterable from the client
because it adds a checksum the server checks for. You can use it as
session replacement if all you have is a user id or something to mark
... | bsd-3-clause | 3,238,733,264,377,720,300 | 36.690402 | 79 | 0.587482 | false |
jeremiahmarks/Todo.txt-python | tests/base.py | 2 | 3810 | # TODO.TXT-CLI-python test script
# Copyright (C) 2011-2012 Sigmavirus24, Jeff Stein
#
# 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) an... | gpl-3.0 | -3,524,293,289,227,194,400 | 29 | 85 | 0.585827 | false |
Kha/flask-admin | examples/layout_bootstrap3/app.py | 43 | 6109 | import os
import os.path as op
from flask import Flask
from flask_sqlalchemy import SQLAlchemy
import flask_admin as admin
from flask_admin.contrib.sqla import ModelView
# Create application
app = Flask(__name__)
# Create dummy secrey key so we can use sessions
app.config['SECRET_KEY'] = '123456790'
# Create in-me... | bsd-3-clause | -3,639,933,405,811,045,000 | 40 | 120 | 0.625143 | false |
testmana2/test | Helpviewer/HelpSearchWidget.py | 2 | 4654 | # -*- coding: utf-8 -*-
# Copyright (c) 2009 - 2015 Detlev Offenbach <detlev@die-offenbachs.de>
#
"""
Module implementing a window for showing the QtHelp index.
"""
from __future__ import unicode_literals
from PyQt5.QtCore import pyqtSignal, Qt, QEvent, QUrl
from PyQt5.QtWidgets import QWidget, QVBoxLayout, QTextBr... | gpl-3.0 | 3,148,641,403,850,601,000 | 32.482014 | 79 | 0.585733 | false |
Judystudy/gooderp_addons | sell/report/sell_summary_goods.py | 6 | 6707 | # -*- coding: utf-8 -*-
from odoo import fields, models, api
import odoo.addons.decimal_precision as dp
import datetime
class SellSummaryGoods(models.Model):
_name = 'sell.summary.goods'
_inherit = 'report.base'
_description = u'销售汇总表(按商品)'
id_lists = fields.Text(u'移动明细行id列表')
goods_categ = fiel... | agpl-3.0 | 5,290,346,230,518,311,000 | 40.649682 | 110 | 0.544426 | false |
zerkrx/zerkbox | lib/youtube_dl/extractor/disney.py | 21 | 6696 | # coding: utf-8
from __future__ import unicode_literals
import re
from .common import InfoExtractor
from ..utils import (
int_or_none,
unified_strdate,
compat_str,
determine_ext,
ExtractorError,
)
class DisneyIE(InfoExtractor):
_VALID_URL = r'''(?x)
https?://(?P<domain>(?:[^/]+\.)?(?... | gpl-3.0 | -1,637,865,295,245,653,000 | 40.333333 | 257 | 0.528524 | false |
mastizada/kuma | kuma/wiki/migrations/0023_attachment_m2m.py | 5 | 17911 | # encoding: utf-8
import datetime
from south.db import db
from south.v2 import SchemaMigration
from django.db import models
class Migration(SchemaMigration):
def forwards(self, orm):
# Adding model 'DocumentAttachment'
db.create_table('wiki_documentattachment', (
('id', self.gf('djang... | mpl-2.0 | 7,916,257,407,508,146,000 | 81.16055 | 187 | 0.555245 | false |
hernandito/SickRage | lib/sqlalchemy/dialects/postgresql/zxjdbc.py | 79 | 1395 | # postgresql/zxjdbc.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:: postgresql+zxjdbc
:name: zxJDBC for Jython
:dbapi: zxjdb... | gpl-3.0 | 6,737,825,263,692,701,000 | 30 | 84 | 0.717563 | false |
sserrot/champion_relationships | venv/Lib/site-packages/win32/lib/pywintypes.py | 6 | 7120 | # Magic utility that "redirects" to pywintypesxx.dll
import imp, sys, os
def __import_pywin32_system_module__(modname, globs):
# This has been through a number of iterations. The problem: how to
# locate pywintypesXX.dll when it may be in a number of places, and how
# to avoid ever loading it twice. This... | mit | 8,582,109,002,368,490,000 | 51.352941 | 94 | 0.603511 | false |
yavalvas/yav_com | build/matplotlib/examples/user_interfaces/embedding_in_wx2.py | 9 | 2706 | #!/usr/bin/env python
"""
An example of how to use wx or wxagg in an application with the new
toolbar - comment out the setA_toolbar line for no toolbar
"""
# Used to guarantee to use at least Wx2.8
import wxversion
wxversion.ensureMinimal('2.8')
from numpy import arange, sin, pi
import matplotlib
# uncomment the f... | mit | -3,529,546,067,889,718,000 | 29.75 | 79 | 0.640798 | false |
cbschaff/NBP | src/models/beacon10.py | 1 | 1853 | """
Copyright (C) 2017 Charles Schaff, David Yunis, Ayan Chakrabarti,
Matthew R. Walter. See LICENSE.txt for details.
"""
# Beacon model 10: fixed beacons of 8 channels in alternating clusters (of different subsets of 16)
import tensorflow as tf
import numpy as np
# Use with 8 channels
wn=1
def beacon(self):
N... | gpl-3.0 | 6,338,860,614,589,693,000 | 22.75641 | 99 | 0.426875 | false |
msreis/SigNetSim | signetsim/views/auth/ActivateAccountView.py | 2 | 2778 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# Copyright 2014-2017 Vincent Noel (vincent.noel@butantan.gov.br)
#
# This file is part of libSigNetSim.
#
# libSigNetSim 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 Fou... | agpl-3.0 | 8,917,291,774,644,286,000 | 30.579545 | 161 | 0.706263 | false |
Jin-W-FS/chinese-words-segmentation-test | WordDict.py | 1 | 1045 | #!/usr/bin/env python
# *- coding: utf-8 -*-
PUNCTUATIONS = (set(u'''`~!@#$%^&*()_+-={}[]|\:";'<>?,./ ''') |
set(u'''~`!@#¥%……&*()——+-=『』【】、‘’“”:;《》?,。/''')) - \
set(u'''_''') # not punctuation
class WordDict(dict):
def __init__(self, *args, **kwargs):
dict.__init__(self, ... | gpl-2.0 | -1,600,387,630,918,851,300 | 34.607143 | 68 | 0.446339 | false |
SU-ECE-17-7/ibeis | ibeis/web/routes.py | 1 | 58514 | # -*- coding: utf-8 -*-
"""
Dependencies: flask, tornado
"""
from __future__ import absolute_import, division, print_function
import random
import math
from flask import request, current_app, url_for
from ibeis.control import controller_inject
from ibeis import constants as const
from ibeis.constants import KEY_DEFAULT... | apache-2.0 | -1,131,818,135,503,844,000 | 39.833217 | 275 | 0.558516 | false |
rlaboiss/pelican-plugins | post_stats/readability.py | 73 | 1362 | # -*- coding: utf-8 -*-
# Adadpted from here: http://acdx.net/calculating-the-flesch-kincaid-level-in-python/
# See here for details: http://en.wikipedia.org/wiki/Flesch%E2%80%93Kincaid_readability_test
from __future__ import division
import re
def mean(seq):
return sum(seq) / len(seq)
def syllables(word):
... | agpl-3.0 | -3,312,280,517,650,598,000 | 23.321429 | 92 | 0.569016 | false |
shrimo/PyQt4 | examples/webkit/previewer/ui_previewer.py | 6 | 3467 | # -*- coding: utf-8 -*-
# Form implementation generated from reading ui file 'previewer.ui'
#
# Created: Mon Nov 29 17:09:55 2010
# by: PyQt4 UI code generator snapshot-4.8.2-241fbaf4620d
#
# WARNING! All changes made in this file will be lost!
from PyQt4 import QtCore, QtGui
try:
_fromUtf8 = QtCore.QString... | gpl-2.0 | 8,707,240,979,276,832,000 | 51.530303 | 126 | 0.726565 | false |
zstyblik/infernal-twin | build/reportlab/tests/test_platypus_accum.py | 14 | 3168 | from reportlab.lib.testutils import setOutDir,makeSuiteForClasses, outputfile, printLocation
setOutDir(__name__)
import os,unittest
from reportlab.platypus import Spacer, SimpleDocTemplate, Table, TableStyle, LongTable
from reportlab.platypus.doctemplate import PageAccumulator
from reportlab.platypus.paragraph import P... | gpl-3.0 | -5,599,083,950,257,946,000 | 33.813187 | 92 | 0.619949 | false |
kiall/designate-py3 | tools/install_venv.py | 11 | 2341 | # Copyright 2010 United States Government as represented by the
# Administrator of the National Aeronautics and Space Administration.
# All Rights Reserved.
#
# Copyright 2010 OpenStack Foundation
# Copyright 2013 IBM Corp.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this... | apache-2.0 | -1,269,447,356,887,836,700 | 32.927536 | 79 | 0.689876 | false |
mangalaman93/docker-py | docker/utils/types.py | 43 | 2304 | import six
class LogConfigTypesEnum(object):
_values = (
'json-file',
'syslog',
'journald',
'gelf',
'fluentd',
'none'
)
JSON, SYSLOG, JOURNALD, GELF, FLUENTD, NONE = _values
class DictType(dict):
def __init__(self, init):
for k, v in six.iterit... | apache-2.0 | 7,601,276,588,095,561,000 | 23 | 69 | 0.547743 | false |
alander/StarCluster | starcluster/commands/removenode.py | 19 | 5236 | # Copyright 2009-2014 Justin Riley
#
# This file is part of StarCluster.
#
# StarCluster is free software: you can redistribute it and/or modify it under
# the terms of the GNU Lesser General Public License as published by the Free
# Software Foundation, either version 3 of the License, or (at your option) any
# later ... | gpl-3.0 | 5,828,462,376,033,988,000 | 40.228346 | 79 | 0.582124 | false |
mbrugg/MC-EWIO64-ORG | board/pxa255_idp/pxa_reg_calcs.py | 65 | 11003 | #!/usr/bin/python
# (C) Copyright 2004
# BEC Systems <http://bec-systems.com>
# Cliff Brake <cliff.brake@gmail.com>
# 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 Li... | gpl-2.0 | 6,184,264,800,727,650,000 | 34.379421 | 128 | 0.549487 | false |
cgcgbcbc/django-xadmin | xadmin/plugins/themes.py | 25 | 2797 | #coding:utf-8
import urllib
from django.template import loader
from django.core.cache import cache
from django.utils.translation import ugettext as _
from xadmin.sites import site
from xadmin.models import UserSettings
from xadmin.views import BaseAdminPlugin, BaseAdminView
from xadmin.util import static, json
THEME_C... | bsd-3-clause | -5,510,038,210,642,784,000 | 34.858974 | 128 | 0.5867 | false |
myerpengine/odoo | openerp/modules/migration.py | 64 | 7546 | # -*- coding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
# Copyright (C) 2010-2013 OpenERP s.a. (<http://openerp.com>).
#
# This program is free software: you ca... | agpl-3.0 | 2,573,357,705,919,711,000 | 39.789189 | 155 | 0.518553 | false |
dstroppa/openstack-smartos-nova-grizzly | nova/tests/test_test.py | 25 | 1731 | # vim: tabstop=4 shiftwidth=4 softtabstop=4
# Copyright 2010 United States Government as represented by the
# Administrator of the National Aeronautics and Space Administration.
# All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compli... | apache-2.0 | -7,932,088,463,272,151,000 | 32.941176 | 78 | 0.707106 | false |
andmos/ansible | lib/ansible/modules/cloud/google/gcp_sql_database.py | 9 | 9612 | #!/usr/bin/python
# -*- coding: utf-8 -*-
#
# Copyright (C) 2017 Google
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
# ----------------------------------------------------------------------------
#
# *** AUTO GENERATED CODE *** AUTO GENERATED CODE ***
#
... | gpl-3.0 | -193,369,060,651,039,100 | 29.807692 | 148 | 0.596442 | false |
Jannes123/inasafe | safe/impact_functions/inundation/flood_polygon_population/test/test_flood_polygon_population.py | 2 | 3475 | # coding=utf-8
"""
InaSAFE Disaster risk assessment tool developed by AusAid and World Bank
- *Flood Vector on Population Test Cases.**
Contact : ole.moller.nielsen@gmail.com
.. note:: This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as pub... | gpl-3.0 | -1,906,181,947,858,958,000 | 35.578947 | 78 | 0.656115 | false |
gautam1858/tensorflow | tensorflow/python/framework/subscribe_test.py | 22 | 13362 | # 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 | -1,539,091,892,599,012,000 | 32.913706 | 80 | 0.661428 | false |
j0lly/molecule | test/unit/verifier/test_ansible_lint.py | 3 | 1797 | # Copyright (c) 2015-2016 Cisco Systems, Inc.
#
# 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... | mit | 3,209,938,926,068,100,000 | 42.829268 | 79 | 0.742905 | false |
glove747/liberty-neutron | neutron/db/migration/alembic_migrations/versions/liberty/expand/48153cb5f051_qos_db_changes.py | 32 | 2545 | # Copyright 2015 Huawei Technologies India Pvt Ltd, 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 ... | apache-2.0 | -347,799,548,453,589,100 | 35.884058 | 78 | 0.63222 | false |
Zentyal/samba | source4/scripting/devel/repl_cleartext_pwd.py | 43 | 16362 | #!/usr/bin/env python
#
# Copyright Stefan Metzmacher 2011-2012
#
# 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.
#
# Th... | gpl-3.0 | 1,433,489,055,485,473,300 | 39.00489 | 140 | 0.598704 | false |
163gal/Time-Line | libs/wx/py/PySlices.py | 10 | 3159 | #!/usr/bin/env python
"""PySlices is a python block code editor / shell and namespace browser application."""
# The next two lines, and the other code below that makes use of
# ``__main__`` and ``original``, serve the purpose of cleaning up the
# main namespace to look as much as possible like the regular Python
# she... | gpl-3.0 | -3,069,522,285,386,507,000 | 30.59 | 89 | 0.609687 | false |
rlutz/xorn | tests/cpython/storage/get_obdata.py | 1 | 1953 | # Copyright (C) 2013-2019 Roland Lutz
#
# 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.
#
# This program is distributed ... | gpl-2.0 | 3,698,071,841,098,026,000 | 31.016393 | 73 | 0.737839 | false |
qguv/config | weechat/community/wee-slack/wee_slack.py | 1 | 197049 | # Copyright (c) 2014-2016 Ryan Huber <rhuber@gmail.com>
# Copyright (c) 2015-2018 Tollef Fog Heen <tfheen@err.no>
# Copyright (c) 2015-2020 Trygve Aaberge <trygveaa@gmail.com>
# Released under the MIT license.
from __future__ import print_function, unicode_literals
from collections import OrderedDict
from datetime im... | gpl-3.0 | -5,768,731,387,078,710,000 | 37.79681 | 277 | 0.603911 | false |
partofthething/home-assistant | homeassistant/components/fortios/device_tracker.py | 24 | 2933 | """
Support to use FortiOS device like FortiGate as device tracker.
This component is part of the device_tracker platform.
"""
import logging
from fortiosapi import FortiOSAPI
import voluptuous as vol
from homeassistant.components.device_tracker import (
DOMAIN,
PLATFORM_SCHEMA,
DeviceScanner,
)
from hom... | mit | 5,338,194,131,105,834,000 | 28.33 | 78 | 0.609615 | false |
msarana/selenium_python | ENV/Lib/site-packages/pip/_vendor/html5lib/treewalkers/dom.py | 505 | 1421 | from __future__ import absolute_import, division, unicode_literals
from xml.dom import Node
from . import _base
class TreeWalker(_base.NonRecursiveTreeWalker):
def getNodeDetails(self, node):
if node.nodeType == Node.DOCUMENT_TYPE_NODE:
return _base.DOCTYPE, node.name, node.publicId, node.sy... | apache-2.0 | -9,084,194,263,731,290,000 | 32.046512 | 80 | 0.612245 | false |
elliott10/qemu-instru-tracer | scripts/qemu-gdb.py | 286 | 2813 | #!/usr/bin/python
# GDB debugging support
#
# Copyright 2012 Red Hat, Inc. and/or its affiliates
#
# Authors:
# Avi Kivity <avi@redhat.com>
#
# This work is licensed under the terms of the GNU GPL, version 2. See
# the COPYING file in the top-level directory.
#
# Contributions after 2012-01-13 are licensed under the... | gpl-2.0 | 8,246,101,005,666,771,000 | 30.606742 | 71 | 0.503733 | false |
Ictp/indico | doc/api/source/event_api_docs.py | 2 | 2619 | import StringIO
import os, sys, re, types
from zope.interface import Interface, interface
import conf
PATH = '../../../indico/'
from MaKaC import common
from indico.core.extpoint import IListener, IContributor
def iterate_sources(dir, exclude=[]):
"""
iterates through all *.py files inside a dir, recursiv... | gpl-3.0 | 5,479,062,163,109,221,000 | 26.28125 | 76 | 0.499809 | false |
qiyuangong/leetcode | python/404_Sum_of_Left_Leaves.py | 2 | 1068 | # Definition for a binary tree node.
# class TreeNode(object):
# def __init__(self, x):
# self.val = x
# self.left = None
# self.right = None
class Solution(object):
# def sumOfLeftLeaves(self, root):
# """
# :type root: TreeNode
# :rtype: int
# """
#... | mit | -1,721,707,686,396,930,300 | 32.375 | 83 | 0.51779 | false |
taigaio/taiga-back | taiga/importers/asana/api.py | 1 | 5842 | # -*- coding: utf-8 -*-
# Copyright (C) 2014-present Taiga Agile LLC
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later ver... | agpl-3.0 | -5,992,208,784,804,923,000 | 39.569444 | 93 | 0.631462 | false |
htwenhe/DJOA | env/Lib/site-packages/django/conf/locale/cy/formats.py | 504 | 1822 | # -*- 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 = 'j F Y' # '25 Hy... | mit | 4,262,840,898,290,709,500 | 46.947368 | 77 | 0.467069 | false |
baruch/libsigrokdecode | decoders/usb_packet/pd.py | 10 | 12962 | ##
## This file is part of the libsigrokdecode project.
##
## Copyright (C) 2011 Gareth McMullin <gareth@blacksphere.co.nz>
## Copyright (C) 2012-2014 Uwe Hermann <uwe@hermann-uwe.de>
##
## This program is free software; you can redistribute it and/or modify
## it under the terms of the GNU General Public License as pu... | gpl-3.0 | -2,096,504,582,498,325,200 | 37.235988 | 109 | 0.534794 | false |
spennihana/h2o-3 | h2o-py/tests/testdir_hdfs/pyunit_NOFEATURE_INTERNAL_HDFS_import_folder_csv_orc_same_milsongs.py | 4 | 1316 | from __future__ import print_function
import sys
sys.path.insert(1,"../../")
import h2o
import time
from tests import pyunit_utils
#----------------------------------------------------------------------
# This test is used to show what happens if we split the same datasets
# into one part csv, one part orc
#-----------... | apache-2.0 | -2,969,104,315,063,898,000 | 34.594595 | 103 | 0.582827 | false |
mayapurmedia/tovp | tovp/contributions/migrations/0030_auto_20150514_1332.py | 2 | 1154 | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
import model_utils.fields
import django.utils.timezone
class Migration(migrations.Migration):
dependencies = [
('contributions', '0029_auto_20150514_1331'),
]
operations = [
migratio... | mit | 7,606,827,020,279,090,000 | 35.0625 | 220 | 0.621317 | false |
abdellatifkarroum/odoo | addons/crm_partner_assign/wizard/__init__.py | 389 | 1038 | # -*- 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 | -9,222,829,374,188,990,000 | 44.173913 | 78 | 0.612717 | false |
mfalaize/carnet-entretien | compta/forms.py | 2 | 3602 | from django import forms
from django.utils.translation import ugettext_lazy as _
from compta.models import Budget, OperationEpargne, Operation, CategorieEpargne
class BudgetForm(forms.ModelForm):
class Meta:
model = Budget
fields = ['categorie', 'compte_associe', 'budget', 'solde_en_une_fois']
... | gpl-3.0 | 3,203,191,791,390,964,700 | 47.621622 | 116 | 0.573096 | false |
dyrock/trafficserver | tests/gold_tests/thread_config/thread_32_0.test.py | 2 | 2467 | '''
'''
# 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");... | apache-2.0 | 3,944,221,662,348,823,000 | 36.378788 | 159 | 0.724362 | false |
erwilan/ansible | contrib/inventory/ovirt4.py | 70 | 7682 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# Copyright (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, ... | gpl-3.0 | 6,245,048,312,908,488,000 | 28.320611 | 96 | 0.611299 | false |
ThinkOpen-Solutions/odoo | addons/account/project/wizard/account_analytic_chart.py | 362 | 2100 | # -*- 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 | 504,554,301,668,686,700 | 41.857143 | 106 | 0.600476 | false |
darktears/chromium-crosswalk | tools/grit/grit/tool/diff_structures.py | 62 | 3923 | #!/usr/bin/env python
# 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.
'''The 'grit sdiff' tool.
'''
import os
import getopt
import tempfile
from grit.node import structure
from grit.tool import inter... | bsd-3-clause | 4,675,875,689,353,524,000 | 33.412281 | 80 | 0.654091 | false |
hequn8128/flink | flink-python/pyflink/table/sources.py | 10 | 2202 | ################################################################################
# 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... | apache-2.0 | -5,193,428,207,122,846,000 | 40.54717 | 82 | 0.629428 | false |
jedie/pypyjs-standalone | website/js/pypy.js-0.3.0/lib/modules/test/test_netrc.py | 50 | 4636 | import netrc, os, unittest, sys, textwrap
from test import test_support
temp_filename = test_support.TESTFN
class NetrcTestCase(unittest.TestCase):
def make_nrc(self, test_data):
test_data = textwrap.dedent(test_data)
mode = 'w'
if sys.platform != 'cygwin':
mode += 't'
... | mit | 8,679,122,582,430,099,000 | 34.661538 | 79 | 0.566221 | false |
AndresVillan/pyafipws | formatos/formato_sql.py | 4 | 15333 | #!/usr/bin/python
# -*- coding: latin-1 -*-
# 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, or (at your option) any later
# version.
#
# This program is distributed in the hope... | gpl-3.0 | -4,232,584,886,085,562,000 | 44.230088 | 257 | 0.515294 | false |
diagramsoftware/odoo | addons/edi/models/__init__.py | 442 | 1116 | # -*- coding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Business Applications
# Copyright (c) 2011 OpenERP S.A. <http://openerp.com>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GN... | agpl-3.0 | 2,092,458,624,888,739,300 | 40.333333 | 78 | 0.62724 | false |
kermitfr/kermit-webui | src/webui/platforms/oc4j/applications.py | 1 | 2735 | '''
Created on Oct 25, 2011
@author: mmornati
'''
from webui.servers.models import Server
from guardian.shortcuts import get_objects_for_user
import logging
from webui.platforms.oc4j.utils import extract_appli_info, check_contains,\
extract_appli_details
from webui.platforms.abstracts import Application
from webui... | gpl-3.0 | 2,970,411,000,821,777,400 | 38.652174 | 84 | 0.590859 | false |
GovCERT-CZ/dionaea | modules/python/util/logsql2postgres.py | 3 | 10245 | #!/opt/dionaea/bin/python3
# sudo su postgres
# createdb --owner=xmpp logsql
# psql -U xmpp logsql < modules/python/util/xmpp/pg_schema.sql
import sqlite3
import postgresql.driver as pg_driver
import optparse
def copy(name, lite, pg, src, dst):
print("[+] {0}".format(name))
pg.execute("DELETE FROM {0}".form... | gpl-2.0 | 4,433,618,170,527,844,000 | 25.472868 | 98 | 0.561835 | false |
Teamxrtc/webrtc-streaming-node | third_party/webrtc/src/chromium/src/tools/perf/page_sets/extension_profile_shared_state.py | 8 | 1202 | # 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 shutil
from profile_creators import extension_profile_extender
from profile_creators import profile_generator
from telemetry.page import shared_page_... | mit | 7,033,498,901,055,003,000 | 34.352941 | 72 | 0.742097 | false |
namccart/gnuradio | grc/python/epy_block_io.py | 5 | 2648 |
import inspect
import collections
from gnuradio import gr
import pmt
TYPE_MAP = {
'complex64': 'complex', 'complex': 'complex',
'float32': 'float', 'float': 'float',
'int32': 'int', 'uint32': 'int',
'int16': 'short', 'uint16': 'short',
'int8': 'byte', 'uint8': 'byte',
}
BlockIO = collections.na... | gpl-3.0 | 3,098,903,623,530,642,000 | 26.873684 | 80 | 0.588746 | false |
garg10may/youtube-dl | youtube_dl/extractor/telemb.py | 177 | 2964 | # coding: utf-8
from __future__ import unicode_literals
import re
from .common import InfoExtractor
from ..utils import remove_start
class TeleMBIE(InfoExtractor):
_VALID_URL = r'https?://(?:www\.)?telemb\.be/(?P<display_id>.+?)_d_(?P<id>\d+)\.html'
_TESTS = [
{
'url': 'http://www.telemb... | unlicense | 1,713,063,301,316,409,300 | 36.961538 | 112 | 0.498818 | false |
FireWalkerX/eyeOS-FOSS-V.2.0 | devtools/qooxdoo-sdk/tool/pylib/graph/classes/Digraph.py | 4 | 19100 | # Copyright (c) 2007-2009 Pedro Matiello <pmatiello@gmail.com>
# Nathan Davis <davisn90210@gmail.com>
# Zsolt Haraszti <zsolt@drawwell.net>
#
# Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation
# f... | agpl-3.0 | -8,219,105,318,877,260,000 | 26.601156 | 101 | 0.563194 | false |
geosolutions-it/wps-remote | src/wpsremote/xmpp_data/configs/myservice/code/test.py | 1 | 3686 | # (c) 2016 Open Source Geospatial Foundation - all rights reserved
# (c) 2014 - 2015 Centre for Maritime Research and Experimentation (CMRE)
# (c) 2013 - 2014 German Aerospace Center (DLR)
# This code is licensed under the GPL 2.0 license, available at the root
# application directory.
import subprocess
import logging... | gpl-2.0 | -1,464,296,127,468,004,400 | 36.232323 | 120 | 0.622355 | false |
majdigital/bigworldgraph | backend/bwg/wikidata_mixins.py | 1 | 13085 | # -*- coding: utf-8 -*-
"""
This module provides two different way to access Wikidata:
* Through the Wikimedia API with ``Pywikibot`` as a wrapper
* Over a scraper using ``BeautifulSoup4``
Currently, accessing the data via the API is faster than the scraper.
"""
# STD
import abc
import hashlib
import thre... | mit | -788,782,512,497,445,600 | 35.046832 | 120 | 0.584868 | false |
pong3489/TEST_Mission | Lib/site-packages/numpy/lib/utils.py | 54 | 36175 | import os
import sys
import types
import re
from numpy.core.numerictypes import issubclass_, issubsctype, issubdtype
from numpy.core import product, ndarray, ufunc
__all__ = ['issubclass_', 'get_numpy_include', 'issubsctype', 'issubdtype',
'deprecate', 'deprecate_with_doc', 'get_numarray_include',
'ge... | gpl-3.0 | -6,702,397,263,208,574,000 | 30.566318 | 95 | 0.530477 | false |
errx/django | django/conf/locale/sr/formats.py | 394 | 2011 | # -*- 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 = 'j. F Y.'
TIME_FORMAT = 'H:i'
DATE... | bsd-3-clause | 6,677,947,519,616,462,000 | 42.717391 | 77 | 0.46544 | false |
wolverineav/neutron | neutron/services/metering/drivers/noop/noop_driver.py | 53 | 1594 | # Copyright (C) 2013 eNovance SAS <licensing@enovance.com>
#
# 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 applicabl... | apache-2.0 | -7,643,003,988,865,234,000 | 29.653846 | 75 | 0.715182 | false |
Nicolou/grrSallesRepetition | fckeditor/editor/filemanager/connectors/py/fckcommands.py | 14 | 6293 | #!/usr/bin/env python
"""
FCKeditor - The text editor for Internet - http://www.fckeditor.net
Copyright (C) 2003-2009 Frederico Caldeira Knabben
== BEGIN LICENSE ==
Licensed under the terms of any of the following licenses at your
choice:
- GNU General Public License Version 2 or later (the "GPL")
http://www.gnu.or... | gpl-2.0 | -7,170,777,282,900,533,000 | 30.782828 | 101 | 0.690291 | false |
codeforsanjose/trash-pickup-portal | data/env/lib/python2.7/site-packages/setuptools/extension.py | 229 | 1649 | import sys
import re
import functools
import distutils.core
import distutils.errors
import distutils.extension
from .dist import _get_unpatched
from . import msvc9_support
_Extension = _get_unpatched(distutils.core.Extension)
msvc9_support.patch_for_specialized_compiler()
def _have_cython():
"""
Return True... | mit | 4,587,230,672,972,920,300 | 28.981818 | 76 | 0.669497 | false |
SEMCOG/synthpop | synthpop/test/test_categorizer.py | 4 | 3418 | import pytest
import numpy as np
from ..census_helpers import Census
from .. import categorizer as cat
@pytest.fixture
def c():
return Census("827402c2958dcf515e4480b7b2bb93d1025f9389")
@pytest.fixture
def acs_data(c):
population = ['B01001_001E']
sex = ['B01001_002E', 'B01001_026E']
race = ['B02001... | bsd-3-clause | 5,728,817,937,670,630,000 | 35.361702 | 77 | 0.499415 | false |
ginkgobioworks/edge | src/edge/models/genome_updater.py | 1 | 2960 | from contextlib import contextmanager
from edge.models.fragment import Fragment
class Genome_Updater(object):
"""
Mixin with helpers for updating genome.
"""
@contextmanager
def annotate_fragment_by_name(self, name):
f = [x for x in self.fragments.all() if x.name == name]
if len(f... | mit | 4,635,774,173,059,254,000 | 36 | 86 | 0.588514 | false |
shuggiefisher/django-on-google-app-engine-base | django/db/models/fields/subclassing.py | 229 | 4356 | """
Convenience routines for creating non-trivial Field subclasses, as well as
backwards compatibility utilities.
Add SubfieldBase as the __metaclass__ for your Field subclass, implement
to_python() and the other necessary methods and everything will work seamlessly.
"""
from inspect import getargspec
from warnings i... | bsd-3-clause | -2,189,686,644,350,454,000 | 36.230769 | 93 | 0.626492 | false |
neale/CS-program | 434-MachineLearning/final_project/linearClassifier/sklearn/decomposition/tests/test_incremental_pca.py | 297 | 8265 | """Tests for Incremental PCA."""
import numpy as np
from sklearn.utils.testing import assert_almost_equal
from sklearn.utils.testing import assert_array_almost_equal
from sklearn.utils.testing import assert_raises
from sklearn import datasets
from sklearn.decomposition import PCA, IncrementalPCA
iris = datasets.load... | unlicense | -6,878,377,739,908,298,000 | 35.897321 | 78 | 0.643557 | false |
tthtlc/volatility | volatility/plugins/overlays/linux/linux64.py | 44 | 1595 | # Volatility
# Copyright (c) 2011 Michael Cohen <scudette@gmail.com>
#
# This file is part of Volatility.
#
# Volatility 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
# (a... | gpl-2.0 | 5,811,200,238,909,870,000 | 32.93617 | 72 | 0.684013 | false |
ujjvala-addsol/addsol_hr | openerp/addons/account/account_financial_report.py | 339 | 7636 | # -*- 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 | -3,442,987,804,468,047,000 | 52.739437 | 501 | 0.588914 | false |
lindsayad/sympy | sympy/interactive/tests/test_ipythonprinting.py | 11 | 6263 | """Tests that the IPython printing module is properly loaded. """
from sympy.core.compatibility import u
from sympy.interactive.session import init_ipython_session
from sympy.external import import_module
from sympy.utilities.pytest import raises
# run_cell was added in IPython 0.11
ipython = import_module("IPython",... | bsd-3-clause | 2,265,527,711,930,941,200 | 46.090226 | 102 | 0.612486 | false |
tinkerinestudio/Tinkerine-Suite | TinkerineSuite/python/Lib/site-packages/wx-2.8-msw-unicode/wx/lib/agw/ribbon/art_aui.py | 6 | 55653 | """
L{RibbonAUIArtProvider} is responsible for drawing all the components of the ribbon
interface using an AUI-compatible appearance.
Description
===========
This allows a ribbon bar to have a pluggable look-and-feel, while retaining the same
underlying behaviour. As a single art provider is used for all ribbon comp... | agpl-3.0 | -4,951,443,095,080,023,000 | 45.146766 | 154 | 0.620721 | 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.