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 |
|---|---|---|---|---|---|---|---|---|---|---|
ACJTeam/enigma2 | lib/python/Components/AVSwitch.py | 1 | 10590 | from config import config, ConfigSlider, ConfigSelection, ConfigYesNo, ConfigEnableDisable, ConfigSubsection, ConfigBoolean, ConfigSelectionNumber, ConfigNothing, NoSave
from enigma import eAVSwitch, eDVBVolumecontrol, getDesktop
from SystemInfo import SystemInfo
import os
class AVSwitch:
def setInput(self, input):
... | gpl-2.0 | -5,518,978,411,526,034,000 | 40.206226 | 185 | 0.706232 | false |
darkonie/dcos | dcos_installer/prettyprint.py | 4 | 3850 | import json
import logging
import pprint
import re
log = logging.getLogger(__name__)
def print_header(string):
delimiter = '====>'
log.warning('{:5s} {:6s}'.format(delimiter, string))
class PrettyPrint():
"""
Pretty prints the output from the deployment process.
"""
def __init__(self, outp... | apache-2.0 | -3,003,576,329,997,714,000 | 36.378641 | 107 | 0.524156 | false |
jaharkes/home-assistant | homeassistant/components/notify/ios.py | 10 | 3658 | """
iOS push notification platform for notify component.
For more details about this platform, please refer to the documentation at
https://home-assistant.io/ecosystem/ios/notifications/
"""
import logging
from datetime import datetime, timezone
import requests
from homeassistant.components import ios
import homeass... | mit | -4,160,635,206,843,412,500 | 34.173077 | 78 | 0.591853 | false |
skosukhin/spack | lib/spack/spack/provider_index.py | 1 | 10997 | ##############################################################################
# Copyright (c) 2013-2017, Lawrence Livermore National Security, LLC.
# Produced at the Lawrence Livermore National Laboratory.
#
# This file is part of Spack.
# Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved.
# LLNL-CODE-64... | lgpl-2.1 | 2,157,932,681,051,611,100 | 35.293729 | 79 | 0.573702 | false |
transcranial/gensim | gensim/corpora/wikicorpus.py | 37 | 13015 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# Copyright (C) 2010 Radim Rehurek <radimrehurek@seznam.cz>
# Copyright (C) 2012 Lars Buitinck <larsmans@gmail.com>
# Licensed under the GNU LGPL v2.1 - http://www.gnu.org/licenses/lgpl.html
"""
Construct a corpus from a Wikipedia (or other MediaWiki-based) database dum... | gpl-3.0 | 4,490,660,027,610,061,300 | 40.449045 | 145 | 0.619516 | false |
lauralwatkins/voronoi | voronoi/bin2d.py | 1 | 4903 | #!/usr/bin/env python
# -----------------------------------------------------------------------------
# VORONOI.BIN2D
# Laura L Watkins [lauralwatkins@gmail.com]
# - converted from IDL code by Michele Cappellari (voronoi_2d_binning)
# -----------------------------------------------------------------------------
from n... | bsd-2-clause | -17,399,896,273,318,952 | 37.015504 | 79 | 0.566796 | false |
sadjadasghari/deeplab4a2d | segmenter.py | 1 | 1421 | #!/usr/bin/env python
# Martin Kersner, m.kersner@gmail.com
# 2016/03/11
# Segmenter is an image segmentation specialization of Net.
# Inspired by https://github.com/torrvision/crfasrnn/blob/master/caffe-crfrnn/python/caffe/segmenter.py
import numpy as np
caffe_root = 'code/'
import sys
sys.path.insert(0, caffe_root... | gpl-3.0 | 2,710,231,346,983,501,000 | 30.577778 | 103 | 0.665025 | false |
maxamillion/dnf | tests/test_cli.py | 1 | 10559 | # -*- coding: utf-8 -*-
# Copyright (C) 2012-2018 Red Hat, Inc.
#
# This copyrighted material is made available to anyone wishing to use,
# modify, copy, or redistribute it subject to the terms and conditions of
# the GNU General Public License v.2, or (at your option) any later version.
# This program is distributed ... | gpl-2.0 | 6,050,709,037,758,982,000 | 40.900794 | 95 | 0.641538 | false |
pombredanne/invenio-old | modules/webaccess/lib/access_control_firerole.py | 3 | 14461 | ## This file is part of CDS Invenio.
## Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008 CERN.
##
## CDS Invenio is free software; you can redistribute it and/or
## modify it under the terms of the GNU General Public License as
## published by the Free Software Foundation; either version 2 of the
## License, or (... | gpl-2.0 | 5,335,946,858,498,810,000 | 44.762658 | 306 | 0.577415 | false |
XiaoxiaoLiu/morphology_analysis | bigneuron/reor_data_for_tile_vis.py | 1 | 2826 | import pandas as pd
import os
import sys
import platform
if (platform.system() == "Linux"):
WORK_PATH = "/local1/xiaoxiaol/work"
else:
WORK_PATH = "/Users/xiaoxiaoliu/work"
p = WORK_PATH + '/src/morphology_analysis'
sys.path.append(p)
import pandas as pd
import numpy as np
import os
import blast_neuron.blast... | gpl-3.0 | -2,709,689,753,089,138,700 | 24.926606 | 121 | 0.63942 | false |
anryko/ansible | lib/ansible/modules/cloud/amazon/s3_logging.py | 13 | 5376 | #!/usr/bin/python
# Copyright: Ansible Project
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
from __future__ import absolute_import, division, print_function
__metaclass__ = type
ANSIBLE_METADATA = {'metadata_version': '1.1',
'status': ['stableinterf... | gpl-3.0 | -2,811,785,204,557,483,000 | 29.202247 | 134 | 0.656994 | false |
edx/edxanalytics | src/edx_embed/edx_embed/wsgi.py | 1 | 1140 | """
WSGI config for edx_embed project.
This module contains the WSGI application used by Django's development server
and any production WSGI deployments. It should expose a module-level variable
named ``application``. Django's ``runserver`` and ``runfcgi`` commands discover
this application via the ``WSGI_APPLICATION`... | agpl-3.0 | 1,823,118,006,196,194,600 | 39.714286 | 79 | 0.799123 | false |
openthread/silk | silk/node/openthread_sniffer.py | 1 | 3372 | # Copyright 2019 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 or agreed to in writing, ... | apache-2.0 | 5,528,026,267,215,853,000 | 30.514019 | 112 | 0.649466 | false |
vit2/vit-e2 | lib/python/Plugins/SystemPlugins/HdmiCEC/plugin.py | 8 | 5597 | from Screens.Screen import Screen
from Components.ConfigList import ConfigListScreen
from Components.config import config, getConfigListEntry
from Components.Sources.StaticText import StaticText
class HdmiCECSetupScreen(Screen, ConfigListScreen):
skin = """
<screen position="c-300,c-250" size="600,500" title="HDMI C... | gpl-2.0 | -6,350,070,534,226,412,000 | 48.530973 | 187 | 0.729677 | false |
adminrt/ssbc | search/management/commands/loadlist.py | 36 | 1208 | #coding: utf8
from django.core.management.base import BaseCommand
from django import db as ddb
from search.models import FileList
import pymongo
import json
import binascii
db = pymongo.MongoClient().dht
class Command(BaseCommand):
def handle(self, *args, **options):
#FileList.objects.all().delete()
... | gpl-2.0 | -6,755,880,455,603,540,000 | 27.761905 | 55 | 0.470199 | false |
lclchen/open-hackathon | open-hackathon-server/src/hackathon/expr/expr_starter.py | 3 | 4979 | # -*- coding: utf-8 -*-
"""
Copyright (c) Microsoft Open Technologies (Shanghai) Co. Ltd. All rights reserved.
The MIT License (MIT)
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 restr... | mit | -2,491,003,159,783,175,000 | 36.149254 | 115 | 0.668943 | false |
jermowery/xos | xos/xos/config.py | 2 | 7526 | #!/usr/bin/env python
import sys
import os
import time
import ConfigParser
import tempfile
import codecs
from StringIO import StringIO
from xml_util import Xml
default_config = \
"""
"""
XOS_DIR = "/opt/xos"
DEFAULT_CONFIG_FN = os.path.join(XOS_DIR, "xos_configuration/")
# warning for now, remove once we're sure eve... | apache-2.0 | -5,964,964,239,220,960,000 | 26.268116 | 102 | 0.645894 | false |
Alwnikrotikz/visvis | core/axises.py | 3 | 80699 | # -*- coding: utf-8 -*-
# Copyright (C) 2012, Almar Klein
#
# Visvis is distributed under the terms of the (new) BSD License.
# The full license can be found in 'license.txt'.
""" Module axises
Defines the Axis wobject class to draw tickmarks and lines for each
dimension.
I chose to name this module using an awkward... | bsd-3-clause | 7,639,935,343,637,107,000 | 34.707522 | 84 | 0.521047 | false |
suquant/django-vimeo | django_vimeo/templatetags/django_vimeo_tags.py | 1 | 5109 | import logging
import re
import requests
from django.template import Library, Node
from django.utils.encoding import smart_str
from django.utils.safestring import mark_safe
from ..exceptions import VideoDoesntExistException
register = Library()
logger = logging.getLogger(__name__)
@register.tag('vimeo')
class Vim... | gpl-2.0 | 2,138,548,051,289,716,200 | 33.761905 | 98 | 0.592288 | false |
nash-x/hws | nova/huawei/virt/ironic/rpcapi.py | 1 | 1480 | # -*- encoding: utf-8 -*-
from sys import argv
from oslo.config import cfg
from oslo import messaging
CONF=cfg.CONF
class ironicAgentApi(object):
def __init__(self):
transport = messaging.get_transport(CONF)
target = messaging.Target(topic='ironic-agent')
self.rpc_client = messaging.RPCCl... | apache-2.0 | 1,559,449,046,261,862,700 | 39.027027 | 75 | 0.646622 | false |
Teagan42/home-assistant | homeassistant/components/trafikverket_weatherstation/sensor.py | 4 | 5220 | """Weather information for air and road temperature (by Trafikverket)."""
import asyncio
from datetime import timedelta
import logging
import aiohttp
from pytrafikverket.trafikverket_weather import TrafikverketWeather
import voluptuous as vol
from homeassistant.components.sensor import PLATFORM_SCHEMA
from homeassis... | apache-2.0 | -7,280,607,483,734,799,000 | 26.760638 | 86 | 0.617743 | false |
nagyistoce/edx-platform | lms/djangoapps/ccx/overrides.py | 33 | 5443 | """
API related to providing field overrides for individual students. This is used
by the individual custom courses feature.
"""
import json
import logging
from django.db import transaction, IntegrityError
import request_cache
from courseware.field_overrides import FieldOverrideProvider # pylint: disable=import-er... | agpl-3.0 | -3,629,860,360,964,224,500 | 31.39881 | 92 | 0.656991 | false |
AllanYangZhou/oppia | extensions/interactions/Continue/Continue.py | 1 | 1632 | # coding: utf-8
#
# Copyright 2014 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 requi... | apache-2.0 | 892,074,680,913,916,200 | 34.478261 | 74 | 0.69424 | false |
tyrelsouza/glue | tests.py | 1 | 1157 | import unittest
from glue import glue
class GlueTests(unittest.TestCase):
def test_tuple(self):
output = glue("why", "would", "you", "run", "these", "tests")
assert output == "why would you run these tests"
def test_tuple_and_named(self):
output = glue("why", "would", "you"... | mit | 2,736,788,459,373,340,000 | 35.15625 | 83 | 0.556612 | false |
lgp171188/fjord | vendor/packages/requests-2.7.0/test_requests.py | 6 | 56192 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
"""Tests for Requests."""
from __future__ import division
import json
import os
import pickle
import unittest
import collections
import io
import requests
import pytest
from requests.adapters import HTTPAdapter
from requests.auth import HTTPDigestAuth, _basic_auth_str
fr... | bsd-3-clause | 1,352,540,414,281,156,000 | 33.29243 | 112 | 0.577415 | false |
pschella/scipy | benchmarks/benchmarks/go_benchmark_functions/go_funcs_T.py | 35 | 12866 | # -*- coding: utf-8 -*-
from __future__ import division, print_function, absolute_import
from numpy import (abs, arctan2, asarray, cos, exp, floor, log, log10,
arange, pi, sign, sin, sqrt, sum,
tan, tanh, atleast_2d)
from .go_benchmark import Benchmark
class TestTubeHolder(Bench... | bsd-3-clause | -3,311,406,547,242,495,000 | 31.737913 | 82 | 0.517177 | false |
justajeffy/anim-studio-tools | review_tool/sources/reviewTool/api/contexts/playlist.py | 5 | 7308 | ##
# \namespace reviewTool.contexts.playlist
#
# \remarks [desc::commented]
#
# \author Dr. D Studios
# \date 07/27/11
#
import datetime
import os.path
import re
import rv_tools
from .sequence import SequenceContext
from ..iosystem import IOSystem
from ..context import Context... | gpl-3.0 | -637,507,753,314,924,400 | 32.677419 | 99 | 0.53503 | false |
wolfier/incubator-airflow | tests/executors/test_executor.py | 15 | 2125 | # -*- coding: utf-8 -*-
#
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
#... | apache-2.0 | -7,909,010,839,748,441,000 | 33.836066 | 77 | 0.653176 | false |
polarise/BioClasses | TransitionMatrix.py | 1 | 8463 | #!/usr/bin/env python
# -*- encoding: utf-8 -*-
from __future__ import division
import sys
import math
import itertools
import cPickle
from Bio import SeqIO
class TransitionMatrix( object ):
def __init__( self ):
"""
Constructor
"""
self.transition_counts = dict()
self.initial_counts = dict()
self.transit... | gpl-2.0 | -8,355,798,465,676,707,000 | 32.322835 | 110 | 0.581945 | false |
tknorris/script.trakt | syncMovies.py | 1 | 17880 | # -*- coding: utf-8 -*-
import copy
import utilities
import kodiUtilities
import logging
from kodiUtilities import notification
logger = logging.getLogger(__name__)
class SyncMovies():
def __init__(self, sync, progress):
self.sync = sync
if not self.sync.show_progress and sync.sync_on_update and ... | gpl-2.0 | 6,765,245,835,865,363,000 | 51.899408 | 371 | 0.635515 | false |
weigj/django-multidb | tests/modeltests/get_or_create/models.py | 17 | 2572 | """
33. get_or_create()
``get_or_create()`` does what it says: it tries to look up an object with the
given parameters. If an object isn't found, it creates one with the given
parameters.
"""
from django.db import models, IntegrityError
class Person(models.Model):
first_name = models.CharField(max_length=100)
... | bsd-3-clause | 5,109,461,865,224,321,000 | 29.987952 | 130 | 0.670684 | false |
grahamhayes/designate | designate/tests/test_coordination.py | 1 | 10303 | # Copyright 2015 Hewlett-Packard Development Company, L.P.
#
# Author: Endre Karlson <endre.karlson@hpe.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/lic... | apache-2.0 | 4,359,935,634,310,086,000 | 32.343042 | 77 | 0.640396 | false |
mrknow/filmkodi | plugin.video.xbmcfilm/resources/lib/utils/xppod.py | 11 | 2757 | #!/usr/bin/env python2
# -*- coding: UTF-8 -*-
# 2014 - Anonymous
def decode(string):
import base64
s = ''
str = _reverse(string)
for x in range(0,len(str)):
s += _decode_char(str[x])
return base64.b64decode(s)
def _reverse(s):
string = ''
length = len(s)-3
while length > ... | apache-2.0 | 2,917,051,027,489,230,300 | 34.333333 | 148 | 0.404719 | false |
job/exscript | tests/Exscript/emulators/IOSEmulatorTest.py | 6 | 1099 | import sys, unittest, re, os.path
sys.path.insert(0, os.path.join(os.path.dirname(__file__), '..', '..', '..', 'src'))
from VirtualDeviceTest import VirtualDeviceTest
from Exscript.emulators import IOSEmulator
from Exscript.emulators.IOSEmulator import iosbanner
class IOSEmulatorTest(VirtualD... | gpl-2.0 | 5,588,313,901,772,205,000 | 35.633333 | 84 | 0.613285 | false |
airbnb/airflow | tests/providers/google/cloud/operators/test_mlengine_system.py | 10 | 1883 | #
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not... | apache-2.0 | 3,716,020,366,242,964,500 | 33.87037 | 103 | 0.731811 | false |
beschoenen/MusicClone | music_clone.py | 1 | 6438 | import os
import shutil
import re
import json
import subprocess
from mutagen.id3 import ID3
from configparser import ConfigParser
config = ConfigParser()
config.read("config.ini")
main = config.get('basic', 'main_folder')
folder_lossy = config.get('basic', 'lossy_folder')
folder_lossless = config.get('basic', 'lossl... | apache-2.0 | 6,808,435,926,520,776,000 | 33.612903 | 135 | 0.600963 | false |
elhuhdron/emdrp | legacy/neon/transforms/emcost.py | 2 | 3877 | # The MIT License (MIT)
#
# Copyright (c) 2016 Paul Watkins, National Institutes of Health / NINDS
#
# 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 l... | mit | 5,693,443,460,563,538,000 | 44.623529 | 110 | 0.637091 | false |
minimalparts/PeARS | app/posTagger.py | 1 | 1381 | import textblob_aptagger
from textblob import TextBlob, Word
#########################################
# Start POS tagger
#########################################
pt = textblob_aptagger.PerceptronTagger()
#######################################
# Tag query
#######################################
def tagQuery(query... | mit | -5,797,652,619,619,997,000 | 33.525 | 79 | 0.375091 | false |
twobob/buildroot-kindle | output/build/host-python-2.7.2/Tools/scripts/texi2html.py | 46 | 69824 | #! /usr/bin/env python
# Convert GNU texinfo files into HTML, one file per node.
# Based on Texinfo 2.14.
# Usage: texi2html [-d] [-d] [-c] inputfile outputdirectory
# The input file must be a complete texinfo file, e.g. emacs.texi.
# This creates many files (one per info node) in the output directory,
# overwriting e... | gpl-2.0 | 8,282,592,934,078,301,000 | 32.60154 | 78 | 0.517859 | false |
russelhampton05/MenMew | webApp/Team3/MenMew/migrations/0001_initial.py | 1 | 8120 | # -*- coding: utf-8 -*-
# Generated by Django 1.10.1 on 2016-09-25 03:09
from __future__ import unicode_literals
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.Crea... | mit | 2,713,011,691,249,339,400 | 40.010101 | 157 | 0.524877 | false |
cdeepakroy/TubeTK | Examples/SegmentVesselsUsingNeuralNetworks/scripts/PreProcessing.py | 1 | 5096 | #!/usr/bin/python
###########################################################################
# PreProcessing.py :
#
# Iterate through the expert labelmap and create 65x65 patches around the
# central pixel. All positive pixels are used as positives input cases.
# The same amount of negatives is randomly picked. For e... | apache-2.0 | 8,683,476,992,294,881,000 | 36.748148 | 98 | 0.683477 | false |
marc-sensenich/ansible | lib/ansible/plugins/callback/junit.py | 62 | 13564 | # (c) 2016 Matt Clay <matt@mystile.com>
# (c) 2017 Ansible Project
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
from __future__ import (absolute_import, division, print_function)
__metaclass__ = type
DOCUMENTATION = '''
callback: junit
type: aggregate
short_... | gpl-3.0 | 1,691,005,793,983,737,300 | 35.462366 | 157 | 0.590976 | false |
hendrikx-itc/python-minerva | src/minerva/loading/csv/parser.py | 1 | 4403 | from operator import itemgetter
import csv
import datetime
from itertools import chain, islice
import dateutil.parser
from minerva.directory.entityref import entity_name_ref_class
from minerva.error import ConfigurationError
from minerva.harvest.plugin_api_trend import HarvestParserTrend
from minerva.storage.trend.tr... | gpl-3.0 | 3,122,415,599,228,333,000 | 25.524096 | 109 | 0.614354 | false |
markroxor/gensim | gensim/test/test_keyedvectors.py | 1 | 4900 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# Author: Jayant Jain <jayantjain1992@gmail.com>
# Copyright (C) 2017 Radim Rehurek <me@radimrehurek.com>
# Licensed under the GNU LGPL v2.1 - http://www.gnu.org/licenses/lgpl.html
"""
Automated tests for checking the poincare module from the models package.
"""
import ... | lgpl-2.1 | -8,816,928,352,855,255,000 | 37.582677 | 107 | 0.633061 | false |
Lilykos/invenio | invenio/modules/deposit/testsuite/helpers.py | 13 | 5355 | # -*- coding: utf-8 -*-
#
# This file is part of Invenio.
# Copyright (C) 2014 CERN.
#
# Invenio is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License as
# published by the Free Software Foundation; either version 2 of the
# License, or (at your option) any later... | gpl-2.0 | 4,993,247,379,498,359,000 | 34.463576 | 78 | 0.622035 | false |
Northrend/mxnet | example/speech_recognition/stt_datagenerator.py | 44 | 13027 | # 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 u... | apache-2.0 | 8,733,191,609,085,622,000 | 45.691756 | 129 | 0.59891 | false |
govint/docker-volume-vsphere | esx_service/vmdk_ops.py | 3 | 83534 | #!/usr/bin/env python
# Copyright 2016 VMware, 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 | -5,459,104,080,962,051,000 | 39.649148 | 137 | 0.606508 | false |
offlinehacker/flumotion | flumotion/common/debug.py | 3 | 9604 | # Flumotion - a streaming media server
# Copyright (C) 2004,2005,2006,2007 Fluendo, S.L. (www.fluendo.com).
# All rights reserved.
# This file may be distributed and/or modified under the terms of
# the GNU General Public License version 2 as published by
# the Free Software Foundation.
# This file is distributed with... | gpl-2.0 | -865,422,278,063,557,100 | 29.782051 | 79 | 0.544461 | false |
bhaveshAn/crisscross | crisscross/platforms/macosx/wifi.py | 1 | 4934 | from crisscross.facades import Wifi
from pyobjus.dylib_manager import load_framework, INCLUDE
from pyobjus import autoclass
load_framework(INCLUDE.Foundation)
load_framework(INCLUDE.CoreWLAN)
CWInterface = autoclass('CWInterface')
CWNetwork = autoclass('CWNetwork')
CWWiFiClient = autoclass('CWWiFiClient')
NSArray = au... | mit | 98,203,984,812,987,540 | 36.097744 | 77 | 0.612485 | false |
coreycb/horizon | openstack_dashboard/dashboards/admin/networks/ports/views.py | 6 | 4347 | # Copyright 2012 NEC Corporation
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or ag... | apache-2.0 | 4,280,966,572,426,464,000 | 37.8125 | 78 | 0.657465 | false |
jaruba/chromium.src | tools/perf/page_sets/startup_pages_record.py | 20 | 1288 | # 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.
from telemetry.page import page as page_module
from telemetry.page import page_set as page_set_module
class StartupPagesRecordPage(page_module.Page):
def... | bsd-3-clause | 1,525,765,499,153,457,400 | 34.777778 | 76 | 0.697205 | false |
thomasyu888/synapsePythonClient | tests/integration/synapseclient/test_command_line_client.py | 1 | 39073 | import json
import logging
import filecmp
import os
import re
import sys
import uuid
import time
import tempfile
import shutil
import pytest
from unittest.mock import patch
from synapseclient import client
from synapseclient import Annotations, Column, Evaluation, File, Folder, Project, Row, RowSet, Schema, Synapse
i... | apache-2.0 | -5,918,253,265,935,864,000 | 34.618049 | 116 | 0.555524 | false |
SrNetoChan/QGIS | tests/src/python/featuresourcetestbase.py | 14 | 50722 | # -*- coding: utf-8 -*-
"""QGIS Unit test utils for QgsFeatureSource subclasses.
.. note:: 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 lat... | gpl-2.0 | -4,131,022,380,989,090,300 | 55.609375 | 434 | 0.595718 | false |
thispc/download-manager | module/plugins/accounts/ZeveraCom.py | 7 | 2379 | # -*- coding: utf-8 -*-
import time
from ..internal.MultiAccount import MultiAccount
class ZeveraCom(MultiAccount):
__name__ = "ZeveraCom"
__type__ = "account"
__version__ = "0.36"
__status__ = "testing"
__config__ = [("mh_mode", "all;listed;unlisted", "Filter hosters to use", "all"),
... | gpl-3.0 | -8,852,935,636,855,944,000 | 32.041667 | 117 | 0.527533 | false |
gabeharms/firestorm | indra/viewer_components/updater/scripts/darwin/janitor.py | 2 | 4649 | #!/usr/bin/python
"""\
@file janitor.py
@author Nat Goodspeed
@date 2011-09-14
@brief Janitor class to clean up arbitrary resources
2013-01-04 cloned from vita because it's exactly what update_install.py needs.
$LicenseInfo:firstyear=2011&license=viewerlgpl$
Copyright (c) 2011, Linden Research, Inc.
$/LicenseInf... | lgpl-2.1 | -976,991,545,134,254,300 | 33.954887 | 100 | 0.568294 | false |
voicesauce/opensauce-python | tools/generate_snack_samples.py | 1 | 1936 | # Script to generate raw Snack samples from test wav files
# The data is used for comparison in unit tests
# Licensed under Apache v2 (see LICENSE)
import sys
import os
import glob
import numpy as np
from opensauce.snack import snack_raw_pitch, snack_raw_formants, sformant_names
def save_samples(data, fn, col_name... | apache-2.0 | 4,129,909,481,922,300,000 | 35.528302 | 124 | 0.651343 | false |
Yuudachimoe/HikariChun-RedBot | lib/aiohttp/abc.py | 19 | 2147 | import asyncio
import sys
from abc import ABC, abstractmethod
from collections.abc import Iterable, Sized
PY_35 = sys.version_info >= (3, 5)
class AbstractRouter(ABC):
@asyncio.coroutine # pragma: no branch
@abstractmethod
def resolve(self, request):
"""Return MATCH_INFO for given request"""
... | gpl-3.0 | -9,145,994,920,863,235,000 | 23.397727 | 74 | 0.64136 | false |
peterfpeterson/mantid | Testing/SystemTests/tests/framework/GSASIIRefineFitPeaksTest.py | 3 | 5521 | # Mantid Repository : https://github.com/mantidproject/mantid
#
# Copyright © 2018 ISIS Rutherford Appleton Laboratory UKRI,
# NScD Oak Ridge National Laboratory, European Spallation Source,
# Institut Laue - Langevin & CSNS, Institute of High Energy Physics, CAS
# SPDX - License - Identifier: GPL - 3.0 +
from... | gpl-3.0 | -4,977,549,474,038,801,000 | 33.72327 | 119 | 0.646984 | false |
CINPLA/expipe-dev | phy-contrib/phycontrib/utils/precache.py | 1 | 1186 | # -*- coding: utf-8 -*-
"""Precache plugin."""
#------------------------------------------------------------------------------
# Imports
#------------------------------------------------------------------------------
import os.path as op
from tqdm import tqdm
from phy import IPlugin
#----------------------------... | gpl-3.0 | 3,707,451,821,832,769,000 | 29.410256 | 79 | 0.379427 | false |
ytsarev/rally | rally/openstack/common/db/sqlalchemy/session.py | 1 | 35132 | # 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 compliance with the License. You may obtain
# a ... | apache-2.0 | -2,689,039,843,084,943,400 | 37.862832 | 79 | 0.635261 | false |
LPM-HMS/COSMOS-2.0 | cosmos/job/drm/drm_slurm.py | 2 | 6911 | import datetime
import os
import re
import subprocess as sp
from pprint import pformat
from cosmos import TaskStatus
from cosmos.job.drm.DRM_Base import DRM
from cosmos.job.drm.util import convert_size_to_kb, div, exit_process_group, run_cli_cmd
from cosmos.util.retry import retry_call
from more_itertools import group... | gpl-3.0 | -5,378,785,879,452,457,000 | 29.311404 | 111 | 0.536536 | false |
mypaint/mypaint | tests/unported/memory_leak.py | 5 | 7796 | #!/usr/bin/env python
from __future__ import division, print_function
from time import time
import sys
import os
import gc
import numpy as np
os.chdir(os.path.dirname(__file__))
sys.path.insert(0, '..')
from lib import mypaintlib, tiledsurface, brush, document, command, helpers
import guicontrol
# loadtxt is know... | gpl-2.0 | -6,847,488,669,787,236,000 | 24.311688 | 91 | 0.557978 | false |
jtk54/spinnaker | testing/citest/tests/google_http_lb_upsert_scenario.py | 1 | 24264 | # Copyright 2016 Google Inc. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the 'License');
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or a... | apache-2.0 | -3,407,985,809,844,732,000 | 33.319661 | 81 | 0.585682 | false |
fzesch/lagesonum | tests/test_input_number.py | 3 | 2465 | # coding: utf-8
# test cases for validation function: success, failure, sanity
from lagesonum.input_number import parse_numbers, is_valid_number
from unittest import TestCase, main
class InputTests(TestCase):
"""Test case for checking whether input in form differing from well formatted line by line input is acce... | mit | 4,748,365,251,079,537,000 | 38.142857 | 116 | 0.620284 | false |
ad-m/django-mailbox | django_mailbox/management/commands/processincomingmessage.py | 2 | 1492 | import email
import logging
import sys
try:
from email import utils
except ImportError:
import rfc822 as utils
from django.core.management.base import BaseCommand
from django_mailbox.models import Mailbox
logger = logging.getLogger(__name__)
logging.basicConfig(level=logging.INFO)
class Command(BaseComman... | mit | -3,416,213,057,997,690,400 | 27.692308 | 72 | 0.61126 | false |
e-q/scipy | scipy/cluster/tests/test_vq.py | 6 | 12417 |
import warnings
import sys
import numpy as np
from numpy.testing import (assert_array_equal, assert_array_almost_equal,
assert_allclose, assert_equal, assert_,
suppress_warnings)
import pytest
from pytest import raises as assert_raises
from scipy.cluster.vq impor... | bsd-3-clause | 6,523,043,739,359,492,000 | 38.926045 | 80 | 0.502698 | false |
showerst/openstates | openstates/md/bills.py | 1 | 18648 | #!/usr/bin/env python
import datetime
import re
import lxml.html
from billy.scrape.bills import BillScraper, Bill
from billy.scrape.votes import Vote
CHAMBERS = {
'upper': ('SB','SJ'),
'lower': ('HB','HJ'),
}
classifiers = {
r'Committee Amendment .+? Adopted': 'amendment:passed',
r'Favorable': 'comm... | gpl-3.0 | -4,186,206,538,854,430,700 | 38.258947 | 242 | 0.505899 | false |
liqiangnlp/LiNMT | scripts/hint.aware/random.n.words/LiNMT-random-template.py | 1 | 2727 | #!/usr/bin/python
# -*- coding: utf-8 -*-
# Author: Qiang Li
# Email: liqiangneu@gmail.compile
# Time: 13:59, 03/27/2017
import sys
import codecs
import argparse
import random
from io import open
argparse.open = open
reload(sys)
sys.setdefaultencoding('utf8')
if sys.version_info < (3, 0):
sys.stderr = codecs.g... | mit | -3,784,532,567,617,443,000 | 28.967033 | 140 | 0.639531 | false |
erudit/eruditorg | eruditorg/core/subscription/management/commands/import_restrictions.py | 1 | 15791 | import sentry_sdk
import structlog
import datetime as dt
import os.path as op
from django.core.exceptions import ValidationError
from django.core.files import File
from django.core.management.base import BaseCommand
from django.db import transaction
from erudit.models import Journal
from erudit.models import Organis... | gpl-3.0 | 9,023,072,052,414,946,000 | 36.597619 | 100 | 0.62086 | false |
peterlauri/django | tests/distinct_on_fields/tests.py | 21 | 5863 | from __future__ import unicode_literals
from django.db.models import Max
from django.test import TestCase, skipUnlessDBFeature
from django.test.utils import str_prefix
from .models import Celebrity, Fan, Staff, StaffTag, Tag
@skipUnlessDBFeature('can_distinct_on_fields')
@skipUnlessDBFeature('supports_nullable_uniq... | bsd-3-clause | -790,203,134,454,279,000 | 44.1 | 118 | 0.563363 | false |
chengstone/FindFaceInVideo | VGGFace/lfw_test_deal.py | 1 | 8246 | # -*- coding: utf-8 -*-
'''
@authot:李华清
@brief:根据lfw网站所给的图片(lfw,lfwcrop_grey,lfwcrop_color)和pairs.txt,写出需要比较的两幅图像的路径(left.txt,right.txt)以及人脸匹配信息(label.txt)
@brief:选择性进行图像尺度变换和灰度化
'''
import os
import numpy as np
#import cv2
#得到一个文件夹下的子文件夹
def dir_subdir(dirname):
dirname=str(dirname)
if dirname=="":
... | bsd-2-clause | -1,247,507,121,667,997,700 | 26.422535 | 121 | 0.571135 | false |
fridex/fabric8-analytics-worker | f8a_worker/workers/anitya.py | 1 | 9373 | """
Adds project to Anitya, which will keep track of its latest version.
"""
import requests
from f8a_worker.enums import EcosystemBackend
from f8a_worker.errors import TaskError
from f8a_worker.utils import DownstreamMapCache, MavenCoordinates
from f8a_worker.base import BaseTask
# name of "RPM" distro for Anitya
RH... | gpl-3.0 | -5,621,608,549,190,938,000 | 48.331579 | 99 | 0.59266 | false |
adamchainz/django-assets | setup.py | 3 | 2543 | #!/usr/bin/env python
# coding: utf8
from __future__ import with_statement
from setuptools import setup, find_packages
import multiprocessing
# Figure out the version; this could be done by importing the
# module, though that requires dependencies to be already installed,
# which may not be the case when processing ... | bsd-2-clause | 2,344,149,345,523,406,000 | 32.447368 | 72 | 0.597954 | false |
AdaptiveApplications/carnegie | tarc_bus_locator_client/quantities-0.10.1/quantities/units/mass.py | 4 | 3415 | # -*- coding: utf-8 -*-
"""
"""
from __future__ import absolute_import
from ..unitquantity import UnitQuantity, UnitMass
from .length import m
kg = kilogram = UnitMass(
'kilogram',
symbol='kg',
aliases=['kilograms']
)
g = gram = UnitMass(
'gram',
kg/1000,
symbol='g',
aliases=['grams']
)
m... | mit | -1,126,116,311,280,413,400 | 19.171598 | 72 | 0.557642 | false |
LavirtheWhiolet/PETOOH | win-compiler/petoohc.py | 2 | 3800 | #!python3
import subprocess, os, sys
VALID_CHARS = "adehkKoOru"
OP_INC, OP_DEC, OP_INCPTR, OP_DECPTR, OP_OUT, OP_JMP, OP_RET = range(7)
COMMANDS = ['Ko', 'kO', 'Kudah', 'kudah', 'Kukarek', 'Kud', 'kud']
def parse(code):
code = filter(VALID_CHARS.__contains__, code)
commands = []
command, buffer = "", ""... | mit | -4,295,954,639,744,526,300 | 24.675676 | 87 | 0.532105 | false |
popazerty/dvbapp2-gui | lib/python/EGAMI/EGAMI_infobar_setup.py | 1 | 7053 | # -*- coding: utf-8 -*-
from Components.ActionMap import *
from Components.config import *
from Components.ConfigList import *
from Components.UsageConfig import *
from Components.Label import Label
from Components.UsageConfig import *
from Screens.Screen import Screen
import os
from EGAMI.EGAMI_skins import EGDecod... | gpl-2.0 | -591,332,294,901,382,100 | 42.006098 | 139 | 0.713597 | false |
cjaymes/pyscap | src/scap/model/oval_5/defs/independent/FileBehaviors.py | 1 | 5665 | # Copyright 2016 Casey Jaymes
# This file is part of PySCAP.
#
# PySCAP 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.
#
# PySCAP is ... | gpl-3.0 | -3,407,788,264,260,927,000 | 51.906542 | 128 | 0.6407 | false |
tyb0807/angr | tests/test_stochastic.py | 1 | 1171 | import os
import nose
import angr
location = str(os.path.join(os.path.dirname(os.path.realpath(__file__)), '../../binaries/tests'))
find = {
'veritesting_a': {
'x86_64': 0x40066a
}
}
criteria = {
'veritesting_a': lambda input_found: input_found.count('B') == 10
}
def run_stochastic(binary, arc... | bsd-2-clause | 9,043,780,010,512,844,000 | 26.880952 | 97 | 0.643894 | false |
GeoMop/GeoMop | testing/gm_base/polygons/test_aabb_lookup.py | 1 | 2016 | import pytest
import numpy as np
import numpy.linalg as la
from gm_base.polygons.aabb_lookup import *
def test_make_aabb():
points = [ [0,0], [4,1], [0,-4],[2, 5]]
box = make_aabb(points)
assert np.all(box == np.array([0,-4,4,5]))
box = make_aabb(points, margin=0.1)
assert np.all(box == np.array(... | gpl-3.0 | 6,148,171,258,568,407,000 | 27.394366 | 74 | 0.575397 | false |
Joel-U/sparkle | sparkle/gui/stim/component_detail.py | 2 | 5941 |
from sparkle.QtWrapper import QtGui
from sparkle.tools.util import clearLayout
class ComponentsDetailWidget(QtGui.QWidget):
"""class that presents the stimulus doc in a clear and useful way"""
def __init__(self, parent=None):
super(ComponentsDetailWidget, self).__init__(parent)
self.lyt = Qt... | gpl-3.0 | 794,067,393,031,871,900 | 32.755682 | 128 | 0.611682 | false |
ktosiek/spacewalk | backend/server/action_extra_data/solarispkgs.py | 2 | 3853 | #
# Copyright (c) 2008--2012 Red Hat, Inc.
#
# This software is licensed to you under the GNU General Public License,
# version 2 (GPLv2). There is NO WARRANTY for this software, express or
# implied, including the implied warranties of MERCHANTABILITY or FITNESS
# FOR A PARTICULAR PURPOSE. You should have received a c... | gpl-2.0 | -5,224,145,350,613,914,000 | 33.711712 | 138 | 0.626265 | false |
SUPINFOLaboDev/TheSnake | Affichage.py | 1 | 1351 | import pygame
import Jeu
import Snake
class Affichage:
def __init__(self):
self.__fenetre = pygame.display.set_mode((450, 450))
pygame.display.set_caption('Snake')
self.__resolution_x = 640
self.__resolution_y = 480
self.__corps_snake = pygame.image.load("case snake.png")
... | mit | -3,050,992,350,878,395,000 | 22.719298 | 79 | 0.586973 | false |
skycucumber/Messaging-Gateway | webapp/venv/lib/python2.7/site-packages/sqlalchemy/orm/state.py | 33 | 21014 | # orm/state.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
"""Defines instrumentation of instances.
This module is usually not directly visible t... | gpl-2.0 | 347,556,891,364,119,700 | 29.812317 | 77 | 0.59289 | false |
newren/git-multimail | setup.py | 2 | 1403 | #! /usr/bin/env python2
import sys
import os
from setuptools import setup
assert 0x02040000 <= sys.hexversion < 0x03000000, \
"Install Python 2, version 2.4 or greater"
def read_version():
sys.path.insert(0, os.path.join('git-multimail'))
import git_multimail
return git_multimail.__version__
def rea... | gpl-2.0 | -8,852,782,307,343,172,000 | 31.627907 | 75 | 0.647897 | false |
recklessromeo/otm-core | opentreemap/api/tests.py | 2 | 69747 | # -*- coding: utf-8 -*-
from __future__ import print_function
from __future__ import unicode_literals
from __future__ import division
from StringIO import StringIO
from json import loads, dumps
from urlparse import urlparse
import urllib
import os
import json
import base64
import datetime
from unittest.case import sk... | agpl-3.0 | 5,247,549,353,910,923,000 | 36.060043 | 79 | 0.577071 | false |
danvk/webdiff | webdiff/dirdiff.py | 1 | 2757 | '''Compute the diff between two directories on local disk.'''
from collections import defaultdict
import copy
import os
from webdiff.localfilediff import LocalFileDiff
from webdiff import util
def diff(a_dir, b_dir):
pairs = find_diff(a_dir, b_dir)
moves, pairs = find_moves(pairs)
diffs = [LocalFileDif... | apache-2.0 | -6,129,527,204,904,868,000 | 28.021053 | 88 | 0.587595 | false |
XiaoTaoWang/TADLib | tadlib/visualize/heatmaps.py | 1 | 7770 | # -*- coding: utf-8 -*-
"""
Created on Thu Jun 28 19:38:21 2018
@author: XiaoTao Wang
"""
import itertools, cooler
import numpy as np
import matplotlib
#matplotlib.use('Agg')
import matplotlib.pyplot as plt
from matplotlib.colors import LinearSegmentedColormap
class Triangle(object):
def __ini... | gpl-3.0 | 8,681,426,830,051,000,000 | 34.824645 | 103 | 0.484299 | false |
elssar/calibre | src/calibre/gui2/preferences/emailp.py | 14 | 10118 | #!/usr/bin/env python2
# vim:fileencoding=UTF-8:ts=4:sw=4:sta:et:sts=4:ai
__license__ = 'GPL v3'
__copyright__ = '2010, Kovid Goyal <kovid@kovidgoyal.net>'
__docformat__ = 'restructuredtext en'
import textwrap
from PyQt5.Qt import QAbstractTableModel, QFont, Qt
from calibre.gui2.preferences import ConfigWidgetBa... | gpl-3.0 | -2,747,201,342,243,837,000 | 36.198529 | 87 | 0.581933 | false |
Jgarcia-IAS/localizacion | openerp/addons-extra/odoo-pruebas/odoo-server/addons-extra/account_transfer_advance/wizard/__init__.py | 7 | 1514 | # -*- encoding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (c) 2013 Cubic ERP - Teradata SAC. (http://cubicerp.com).
#
# WARNING: This program as such is intended to be used by professional
# programmers who take t... | agpl-3.0 | 2,669,471,566,412,868,600 | 44.878788 | 78 | 0.690885 | false |
jroivas/odt-html5 | odt.py | 1 | 23990 | import zipfile
import os
import xml.etree.ElementTree as etree
import re
import copy
class ODTPage:
def __init__(self, name, odt=None, pagename='page', indexname='index'):
self.pagename = pagename
self.indexname = indexname
if odt is None:
self.odt = ODT(name, pagename=pagename)... | mit | 2,451,137,702,651,230,000 | 32.412256 | 122 | 0.478199 | false |
sam-m888/gramps | gramps/gen/filters/rules/media/_matchessourceconfidence.py | 5 | 1869 | #
# Gramps - a GTK+/GNOME based genealogy program
#
# Copyright (C) 2011 Jerome Rapinat
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) ... | gpl-2.0 | -3,949,259,287,551,906,000 | 40.533333 | 93 | 0.574639 | false |
Komzpa/GroundHog | tutorials/DT_RNN_Tut_Ex.py | 4 | 16484 | """
Test of the classical LM model for language modelling
"""
from groundhog.datasets import LMIterator
from groundhog.trainer.SGD_momentum import SGD as SGD_m
from groundhog.trainer.SGD import SGD
from groundhog.mainLoop import MainLoop
from groundhog.layers import MultiLayer, \
RecurrentMultiLayer, \
Re... | bsd-3-clause | 8,476,574,881,672,587,000 | 33.27027 | 92 | 0.577772 | false |
dokterbob/django-shopkit | shopkit/category/advanced/models.py | 1 | 1254 | # Copyright (C) 2010-2011 Mathijs de Bruin <mathijs@mathijsfietst.nl>
#
# This file is part of django-shopkit.
#
# django-shopkit 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 2, or (at... | agpl-3.0 | -6,294,358,828,998,404,000 | 37 | 77 | 0.748006 | false |
IQSS/miniverse | dv_apps/metrics/views_maintenance.py | 1 | 2855 | """
Metric views, returning JSON repsonses
"""
from django.shortcuts import render
from django.views.decorators.cache import cache_page
#from django.http import JsonResponse, HttpResponse, Http404
from dv_apps.metrics.stats_util_files import StatsMakerFiles, FILE_TYPE_OCTET_STREAM
from dv_apps.utils.metrics_cache_time ... | mit | 8,064,920,246,181,727,000 | 36.565789 | 96 | 0.657443 | false |
geminy/aidear | oss/qt/qt-everywhere-opensource-src-5.9.0/qtwebengine/src/3rdparty/chromium/net/data/verify_certificate_chain_unittest/generate-target-has-keycertsign-but-not-ca.py | 5 | 1255 | #!/usr/bin/python
# Copyright (c) 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.
"""Certificate chain with 1 intermediate, a trusted root, and a target
certificate that is not a CA, and yet has the keyCertSign bit se... | gpl-3.0 | 5,629,663,130,636,404,000 | 35.911765 | 83 | 0.766534 | false |
MostlyOpen/odoo_addons | myo_summary/models/summary_log.py | 1 | 2815 | # -*- coding: utf-8 -*-
###############################################################################
#
# Copyright (C) 2013-Today Carlos Eduardo Vercelino - CLVsol
#
# 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 | 3,287,787,353,323,953,000 | 32.511905 | 93 | 0.590409 | false |
MauHernandez/cyclope | cyclope/migrations/0016_frontend_views_simplified_option.py | 2 | 14467 | # 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):
rvs = orm.RegionView.objects.filter(content_view=u"simplified_teaser_list")
mis = orm.MenuItem.objects.filter(content_v... | gpl-3.0 | -7,144,526,115,020,062,000 | 79.372222 | 189 | 0.545932 | false |
mslovy/barrelfish | tools/arm_gem5/O3_ARM_v7a.py | 9 | 6472 | # Copyright (c) 2012 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 list ... | mit | -926,356,532,002,963,500 | 32.020408 | 81 | 0.662083 | false |
Gustavosdo/django-salmonella | salmonella/admin.py | 1 | 1434 | from salmonella.widgets import SalmonellaIdWidget, SalmonellaMultiIdWidget
class SalmonellaMixin(object):
salmonella_fields = ()
def formfield_for_foreignkey(self, db_field, request=None, **kwargs):
if db_field.name in self.salmonella_fields:
try:
kwargs['widget'] = Salmon... | mit | -3,950,196,689,673,282,600 | 50.214286 | 89 | 0.521618 | false |
bcl/pykickstart | tests/commands/url.py | 2 | 7541 | #
# Martin Gracik <mgracik@redhat.com>
#
# Copyright 2009 Red Hat, Inc.
#
# This copyrighted material is made available to anyone wishing to use, modify,
# copy, or redistribute it subject to the terms and conditions of the GNU
# General Public License v.2. This program is distributed in the hope that it
# will be use... | gpl-2.0 | 8,349,713,520,328,970,000 | 41.60452 | 105 | 0.607744 | 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.