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 |
|---|---|---|---|---|---|---|---|---|---|---|
Azure/azure-sdk-for-python | sdk/network/azure-mgmt-network/azure/mgmt/network/v2018_10_01/aio/operations/_interface_endpoints_operations.py | 1 | 23817 | # coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for license information.
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may ... | mit | -8,307,013,246,436,605,000 | 48.930818 | 205 | 0.647941 | false |
yaroslavvb/tensorflow | tensorflow/python/lib/io/file_io.py | 23 | 14674 | # 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 | 449,743,245,204,139,200 | 29.380952 | 80 | 0.676775 | false |
kobolabs/calibre | src/calibre/utils/pyconsole/console.py | 9 | 16915 | #!/usr/bin/env python
# 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 sys, textwrap, traceback, StringIO
from functools import partial
from codeop import CommandCompiler
from PyQt4.Qt i... | gpl-3.0 | -6,390,470,925,879,596,000 | 31.591522 | 83 | 0.54969 | false |
Ubuntu-Solutions-Engineering/conjure | conjureup/ui/views/destroy_confirm.py | 3 | 3999 | import datetime
from ubuntui.utils import Color, Padding
from ubuntui.widgets.buttons import menu_btn
from ubuntui.widgets.hr import HR
from ubuntui.widgets.text import Instruction
from urwid import Columns, Filler, Frame, Pile, Text, WidgetWrap
class DestroyConfirmView(WidgetWrap):
def __init__(self, app, cont... | mit | 565,828,565,105,347,700 | 33.179487 | 84 | 0.540635 | false |
Telerivet/telerivet-python-client | telerivet/contact.py | 1 | 12556 | from .entity import Entity
class Contact(Entity):
"""
Fields:
- id (string, max 34 characters)
* ID of the contact
* Read-only
- name
* Name of the contact
* Updatable via API
- phone_number (string)
* Phone number of the co... | mit | -4,420,296,154,701,561,000 | 32.662198 | 107 | 0.505575 | false |
jameswenzel/mydy | tests/test.py | 1 | 9590 | '''
Tests for MIDI modules
'''
import unittest
import random
import math
from itertools import chain
# in the dev environment, mydy is known as src
import src as mydy
# from mydy import Util, FileIO, Events
# from mydy.Constants import MAX_TICK_RESOLUTION
Util = mydy.Util
FileIO = mydy.FileIO
Events = mydy.Events
Cont... | mit | 1,308,363,646,772,172,000 | 35.325758 | 81 | 0.611679 | false |
hlieberman/debian-ansible | lib/ansible/runner/lookup_plugins/first_found.py | 33 | 5953 | # (c) 2013, seth vidal <skvidal@fedoraproject.org> red hat, inc
#
# This file is part of Ansible
#
# Ansible is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your optio... | gpl-3.0 | -4,262,551,166,050,060,300 | 30.834225 | 97 | 0.592642 | false |
hsnlab/mapping | generator/sg_generator.py | 1 | 5884 | #!/usr/bin/python -u
#
# Copyright (c) 2016 Balazs Nemeth
#
# This file is free software: you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This file i... | apache-2.0 | -6,003,011,394,337,642,000 | 32.816092 | 79 | 0.599422 | false |
dpinney/omf | omf/solvers/REopt/post_and_poll.py | 1 | 1120 | import requests
import json
from logger import log
from results_poller import poller
results_file = 'results.json'
API_KEY = 'WhEzm6QQQrks1hcsdN0Vrd56ZJmUyXJxTJFg6pn9' # REPLACE WITH YOUR API KEY
# API_KEY = 'Y8GMAFsqcPtxhjIa1qfNj5ILxN5DH5cjV3i6BeNE'
root_url = 'https://developer.nrel.gov/api/reopt'
post_url = root_... | gpl-2.0 | -2,044,019,572,903,973,600 | 31 | 81 | 0.674107 | false |
MaximLich/oppia | main_taskqueue.py | 11 | 1803 | # Copyright 2016 The Oppia Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable ... | apache-2.0 | 6,589,000,064,213,346,000 | 35.795918 | 80 | 0.740433 | false |
CptDemocracy/Python | MITx-6.00.1x-EDX-Introduction-to-Computer-Science/Week-3/Lecture-5/problem3.py | 1 | 1417 | """
Problem 3.
The function recurPower(base, exp) from Problem 2 computed base^exp
by decomposing the problem into one recursive case and one base case:
base^exp = base * base^(exp - 1) if exp > 0
base^exp = 1 if exp = 0
Another way to solve this problem just using multiplication
(and r... | mit | -3,404,950,140,497,356,000 | 26.25 | 73 | 0.539873 | false |
martynovp/edx-platform | common/djangoapps/student/helpers.py | 2 | 10810 | """Helpers for the student app. """
import time
from datetime import datetime
import urllib
from pytz import UTC
from django.utils.http import cookie_date
from django.conf import settings
from django.core.urlresolvers import reverse, NoReverseMatch
import third_party_auth
from verify_student.models import SoftwareSe... | agpl-3.0 | 7,328,953,190,709,362,000 | 44.805085 | 119 | 0.654209 | false |
CartesianCo/argentum-control | src/simcon.py | 2 | 1786 | #!/usr/bin/python
# -*- coding: utf-8 -*-
"""
Argentum Control GUI
Copyright (C) 2013 Isabella Stevens
Copyright (C) 2014 Michael Shiel
Copyright (C) 2015 Trent Waddington
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License... | gpl-3.0 | 6,288,955,210,944,737,000 | 35.44898 | 109 | 0.671333 | false |
simbuerg/benchbuild | benchbuild/projects/gentoo/portage_gen.py | 1 | 4310 | """
Generic experiment to test portage packages within gentoo chroot.
"""
import logging
import os
from benchbuild.projects.gentoo import autoportage
from benchbuild.utils.run import run, uchroot_no_args
from benchbuild.utils.container import Gentoo
from plumbum import local, ProcessExecutionError
def PortageFactory(... | mit | 8,436,380,484,041,424,000 | 34.619835 | 77 | 0.535731 | false |
victorlin/ansible-docker-hellobaby | setup.py | 1 | 1061 | import os
from setuptools import setup, find_packages
here = os.path.abspath(os.path.dirname(__file__))
with open(os.path.join(here, 'README.txt')) as f:
README = f.read()
with open(os.path.join(here, 'CHANGES.txt')) as f:
CHANGES = f.read()
requires = [
'pyramid',
'pyramid_chameleon',
'pyramid_d... | mit | 3,099,108,538,728,659,000 | 24.261905 | 63 | 0.579642 | false |
HyperBaton/ansible | lib/ansible/module_utils/vca.py | 38 | 11383 | #
# This file is part of Ansible
#
# Ansible is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# Ansible is distributed in the hope tha... | gpl-3.0 | 7,062,952,371,725,994,000 | 32.777448 | 90 | 0.604498 | false |
rosskynch/complex_bessel | tests/hankelcontours.py | 2 | 1310 | # Python script to generate the contour plot
# seen in Abramowitz & Stegun's book on p. 359.
# The values are imported from the file "contours.dat"
#
# The pylab module is required for this script to run
#
# Joey Dumont <joey.dumont@gmail.com>
# Denis Gagnon <gagnon88@gmail.com>
#
import numpy as np
import matplotlib... | lgpl-3.0 | -98,053,031,246,251,260 | 23.259259 | 121 | 0.682443 | false |
shin-/compose | compose/cli/errors.py | 4 | 5174 | from __future__ import absolute_import
from __future__ import unicode_literals
import contextlib
import logging
import socket
from distutils.spawn import find_executable
from textwrap import dedent
from docker.errors import APIError
from requests.exceptions import ConnectionError as RequestsConnectionError
from reque... | apache-2.0 | 4,879,124,926,595,999,000 | 29.797619 | 98 | 0.672014 | false |
listamilton/supermilton.repository | plugin.video.traquinas/resources/lib/resolvers/xvidstage.py | 23 | 1461 | # -*- coding: utf-8 -*-
'''
Specto Add-on
Copyright (C) 2015 lambda
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 l... | gpl-2.0 | -7,894,659,031,319,673,000 | 30.76087 | 73 | 0.632444 | false |
danieldmm/minerva | evaluation_runs/aac_lrec_full_text_experiments.py | 1 | 12208 | # Experiments with the ACL corpus like the ones for LREC'16
#
# Copyright: (c) Daniel Duma 2016
# Author: Daniel Duma <danielduma@gmail.com>
# For license information, see LICENSE.TXT
from __future__ import print_function
from __future__ import absolute_import
from proc.nlp_functions import AZ_ZONES_LIST, CORESC_LI... | gpl-3.0 | 7,758,306,421,760,707,000 | 47.444444 | 193 | 0.594938 | false |
guilhermelawless/randgen_omni_dataset | randgen_omni_dataset/src/randgen_omni_dataset/omni_custom.py | 1 | 8687 | import rospy
import tf
import random
from read_omni_dataset.msg import *
from randgen_omni_dataset.msg import *
from geometry_msgs.msg import PoseStamped, PoseWithCovariance, PointStamped, Point
from visualization_msgs.msg import Marker, MarkerArray
from randgen_omni_dataset.robot import norm2
GLOBAL_FRAME = 'world'
M... | gpl-3.0 | -5,166,600,241,205,232,000 | 37.955157 | 124 | 0.612524 | false |
nextgis/buildbot | makedeb.py | 1 | 12823 | # -*- python -*-
# ex: set syntax=python:
# production builds into nextgis ppa
from buildbot.plugins import *
import os
c = {}
repositories = [
{'repo':'lib_geos', 'deb':'geos', 'repo_root':'git://github.com', 'org': 'nextgis-borsch', 'os':['bionic', 'stretch', 'focal', 'buster', ], 'repo_id':11},
{'repo':'l... | gpl-2.0 | 597,300,990,202,796,500 | 59.201878 | 316 | 0.562583 | false |
mweisman/QGIS | python/plugins/processing/algs/ftools/PointsInPolygonUnique.py | 6 | 4944 | # -*- coding: utf-8 -*-
"""
***************************************************************************
PointsInPolygon.py
---------------------
Date : August 2012
Copyright : (C) 2012 by Victor Olaya
Email : volayaf at gmail dot com
***********************... | gpl-2.0 | 3,896,842,395,292,248,600 | 38.552 | 79 | 0.535599 | false |
rgayon/plaso | plaso/parsers/symantec.py | 1 | 12476 | # -*- coding: utf-8 -*-
"""This file contains a Symantec parser in plaso."""
from __future__ import unicode_literals
from dfdatetime import time_elements as dfdatetime_time_elements
from plaso.containers import events
from plaso.containers import time_events
from plaso.lib import definitions
from plaso.parsers impor... | apache-2.0 | 2,688,859,780,277,799,400 | 36.241791 | 80 | 0.664716 | false |
LennonChin/Django-Practices | MxOnline/extra_apps/xadmin/views/list.py | 1 | 26491 | from collections import OrderedDict
from django.core.exceptions import PermissionDenied, ObjectDoesNotExist
from django.core.paginator import InvalidPage, Paginator
from django.core.urlresolvers import NoReverseMatch
from django.db import models
from django.http import HttpResponseRedirect
from django.template.re... | apache-2.0 | 725,250,696,843,273,700 | 38.016616 | 173 | 0.546827 | false |
avoorhis/vamps-node.js | public/scripts/node_process_scripts/gast/chimera.py | 1 | 34367 | import subprocess
import sys, os
import re
import time
from pipeline.pipelinelogging import logger
from pipeline.utils import Dirs, PipelneUtils
from pipeline.utils import *
from pprint import pprint
from collections import defaultdict, namedtuple
sys.path.append("/xraid/bioware/linux/seqinfo/bin")
sys.path.append("/Us... | mit | -1,459,004,407,187,858,000 | 44.04194 | 200 | 0.529549 | false |
ecsalina/gtrends | test_download.py | 1 | 4390 | # -*- coding: utf-8 -*-
import pytest
import getpass
import datetime
import gtrends
#SETUP
username = getpass.getpass("username: ")
password = getpass.getpass("password: ")
startDt = datetime.datetime(year=2006, month=1, day=1)
#countMonth = 1 for daily and 5 for weekly
#TEST DOES DOWNLOAD?
#many files
def testDow... | mit | 4,239,487,882,005,819,400 | 30.314286 | 134 | 0.628565 | false |
fintech-circle/edx-platform | pavelib/paver_tests/test_paver_quality.py | 1 | 14472 | """
Tests for paver quality tasks
"""
import os
import tempfile
import textwrap
import unittest
import paver.easy
import paver.tasks
from ddt import ddt, file_data
from mock import MagicMock, mock_open, patch
from path import Path as path
from paver.easy import BuildFailure
import pavelib.quality
from pavelib.paver_t... | agpl-3.0 | -2,740,539,081,380,800,500 | 39.766197 | 134 | 0.635918 | false |
zstackorg/zstack-woodpecker | zstackwoodpecker/zstackwoodpecker/header/checker.py | 3 | 3333 | '''
Zstack checker header classes
@author: YYK
'''
import zstackwoodpecker.test_util as test_util
class TestChecker(object):
def __init__(self):
import os
self.exp_result = True
self.real_result = None
self.retry_count = 5
self.test_obj = None
re... | apache-2.0 | -1,096,926,603,586,833,300 | 30.149533 | 79 | 0.561956 | false |
kennethreitz/pipenv | pipenv/vendor/passa/models/providers.py | 1 | 8586 | # -*- coding=utf-8 -*-
from __future__ import absolute_import, print_function, unicode_literals
import os
import resolvelib
from ..internals.candidates import find_candidates
from ..internals.dependencies import get_dependencies
from ..internals.utils import (
filter_sources, get_allow_prereleases, identify_req... | mit | -7,365,321,261,601,924,000 | 42.363636 | 79 | 0.658164 | false |
dreamsxin/adonthell | test/questtest.py | 2 | 1251 | from adonthell import event, main, rpg
import sys
# -- test event callbacks
# -- test class
class App (main.AdonthellApp):
def run (self):
# -- add data directory to python search path
sys.path.insert (0, "data")
# -- load quest tree
rpg.quest.load ()
# -- setup some quest events
factory = event.f... | gpl-2.0 | 8,304,030,802,440,692,000 | 26.8 | 78 | 0.66267 | false |
gxx/lettuce | lettuce/plugins/reporter.py | 19 | 2156 | import sys
class Reporter(object):
def __init__(self):
self.failed_scenarios = []
self.scenarios_and_its_fails = {}
def wrt(self, what):
if isinstance(what, unicode):
what = what.encode('utf-8')
sys.stdout.write(what)
def store_failed_step(self, step):
... | gpl-3.0 | -3,331,234,153,947,072,000 | 31.179104 | 70 | 0.533859 | false |
AloneRoad/Inforlearn | vendor/django/contrib/gis/tests/test_geos.py | 5 | 31499 | import random, unittest, sys
from ctypes import ArgumentError
from django.contrib.gis.geos import *
from django.contrib.gis.geos.base import HAS_GDAL
from django.contrib.gis.tests.geometries import *
if HAS_NUMPY: from numpy import array
if HAS_GDAL: from django.contrib.gis.gdal import OGRGeometry, SpatialReferenc... | apache-2.0 | 493,359,934,862,514,500 | 39.643871 | 121 | 0.561224 | false |
hazelcast/hazelcast | extensions/python/src/main/resources/jet_to_python_grpc_server.py | 10 | 3200 | import grpc
import sys
import os
import socket
import logging
import importlib
from concurrent import futures
import jet_to_python_pb2
import jet_to_python_pb2_grpc
logger = logging.getLogger('Python PID %d' % os.getpid())
class JetToPythonServicer(jet_to_python_pb2_grpc.JetToPythonServicer):
def __init__(self,... | apache-2.0 | 4,658,484,364,949,678,000 | 40.558442 | 138 | 0.68875 | false |
creasyw/IMTAphy | modules/phy/imtaphy/testConfigs/imtaphyViewer/ui/Windows_Main_ui.py | 1 | 9101 | # -*- coding: utf-8 -*-
# Form implementation generated from reading ui file 'Windows_Main.ui'
#
# Created: Tue Jan 24 03:15:16 2012
# by: PyQt4 UI code generator 4.8.5
#
# WARNING! All changes made in this file will be lost!
from PyQt4 import QtCore, QtGui
try:
_fromUtf8 = QtCore.QString.fromUtf8
except At... | gpl-2.0 | -7,998,344,511,708,677,000 | 69.550388 | 158 | 0.745413 | false |
tlakshman26/cinder-https-changes | cinder/db/sqlalchemy/migrate_repo/versions/037_add_cgsnapshot_id_column_to_consistencygroups.py | 20 | 1371 | # Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# d... | apache-2.0 | 5,296,566,347,016,533,000 | 36.054054 | 78 | 0.73523 | false |
DarthMaulware/EquationGroupLeaks | Leak #1 - Equation Group Cyber Weapons Auction - Invitation/EQGRP-Free-File/Firewall/EXPLOITS/EPBA/EPICBANANA/versions/asa804.py | 1 | 2673 | from params import *
from util import *
from asa804_loader import *
def payload(params):
block_enc = []
while len(block_enc) == 0:
mask_byte = ord(rand_byte()) # one byte, used as an int
#print "trying to mask data with 0x%02x" % mask_byte
block_enc = prepare_blocks(params, mask_byte... | unlicense | -5,213,213,743,489,663,000 | 40.123077 | 99 | 0.617284 | false |
blablack/ams-lv2 | waflib/Tools/d_scan.py | 16 | 5052 | #!/usr/bin/env python
# encoding: utf-8
# Thomas Nagy, 2016-2018 (ita)
"""
Provide a scanner for finding dependencies on d files
"""
import re
from waflib import Utils
def filter_comments(filename):
"""
:param filename: d file name
:type filename: string
:rtype: list
:return: a list of characters
"""
txt = Ut... | gpl-2.0 | 8,168,800,896,246,255,000 | 22.943128 | 126 | 0.60669 | false |
krzykwas/rhqagent | pyagent/test/data/model/PastMeasurementsManagerTest.py | 1 | 3503 | #-*- coding: utf-8 -*-
#
# Krzysztof „krzykwas” Kwaśniewski
# Gdańsk, 15-07-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 late... | gpl-3.0 | 2,079,253,867,258,000,000 | 38.738636 | 117 | 0.76294 | false |
hehewa/pytorchStudy | methods_exist/Regression/REGRESSION.py | 1 | 1796 | #!/usr/bin/env python
from __future__ import print_function
from itertools import count
import torch
import torch.autograd
import torch.nn.functional as F
from torch.autograd import Variable
import matplotlib.pyplot as plt
import numpy as np
POLY_DEGREE = 4
W_target = torch.randn(POLY_DEGREE, 1) * 5
b_target = torch.... | apache-2.0 | -5,541,937,584,037,717,000 | 23.958333 | 83 | 0.625278 | false |
Bauble/bauble.classic | scripts/bauble-upgrade-0.6-to-0.7.py | 3 | 5641 | #!/usr/bin/env python
# this script needs both a connections to a database created with bauble 0.6.x
# and the csv files exported from the same database, it will create a directory
# called 0.7 in the same directory as the exported csv files with the new
# converted files...you will also need the default geography dat... | gpl-2.0 | 5,320,437,833,767,806,000 | 30.870056 | 94 | 0.674349 | false |
silly-wacky-3-town-toon/SOURCE-COD | Panda3D-1.10.0/direct/showbase/CountedResource.py | 11 | 7016 |
class CountedResource(object):
"""
This class is an attempt to combine the RAIA idiom with reference
counting semantics in order to model shared resources. RAIA stands
for "Resource Allocation Is Acquisition" (see 'Effective C++' for a
more in-depth explanation)
When a resource is needed, ... | apache-2.0 | 5,393,298,083,505,471,000 | 29.504348 | 84 | 0.585946 | false |
cstavr/synnefo | snf-pithos-app/pithos/api/manage_accounts/__init__.py | 10 | 15419 | # Copyright (C) 2010-2014 GRNET S.A.
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed i... | gpl-3.0 | 2,453,471,580,110,344,000 | 39.576316 | 79 | 0.541215 | false |
Starbow/StarbowWebSite | starbowmodweb/streams/views.py | 1 | 1876 | from django.shortcuts import render_to_response
from django.contrib.auth.decorators import login_required
from django.template import RequestContext
from starbowmodweb.streams.models import StreamInfo
from starbowmodweb.streams.forms import AddStreamForm
@login_required
def edit_stream(request):
messages = []
... | mit | -1,552,262,692,296,011,000 | 44.780488 | 97 | 0.615139 | false |
ISKU/BOJ-AutoCommit | option.py | 1 | 4258 | DEFAULT_COMMIT_MESSAGE = 'BOJ #[NO]'
DEFAULT_DIR_NAME = '[NO]'
DEFAULT_POLL = 600
DEFAULT_SOURCE_NAME = '[NO]'
class Option:
def __init__(self, option):
self.option = option
def commit_message(self, problem):
if not 'commit_message' in self.option:
return self.replace_msg(DEFAULT... | mit | -229,388,674,643,249,000 | 28.748252 | 84 | 0.443112 | false |
libretees/libreshop | libreshop/common/tests/test_UniqueTogetherFormSet.py | 1 | 3653 | from django.core.exceptions import ValidationError
from django.forms.models import inlineformset_factory
from django.test import TestCase
from ..forms.models import UniqueTogetherFormSet
from ..models import Inventory, Location, Warehouse
# Create your tests here.
class UniqueTogetherFormSetTest(TestCase):
def se... | gpl-3.0 | 7,416,644,987,825,297,000 | 31.90991 | 87 | 0.61648 | false |
M-Carter/zettaknight | zk_import.py | 1 | 3525 | #!/usr/bin/python
import yaml
import json
import six
import logging
from zk_utils import spawn_job
#open logging instance
logger = logging.getLogger(__name__)
class ZkBase(object):
def __init__(self):
pass
def conv_str_to_dict(self, string):
'''
takes a console ... | gpl-3.0 | 1,426,781,401,315,458,000 | 27.658537 | 99 | 0.560567 | false |
pfschwartz/openelisglobal-core | liquibase/OE2.9/testCatalogHT_Clinical/scripts/testResult.py | 6 | 3274 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
def convert_type_to_symbole( type):
if type == 'Numeric' or type == 'numeric' :
return 'N'
if 'Free Text' in type:
return 'R'
if type == 'Select list':
return 'D'
if type == 'multi' or type == 'Multi Select':
ret... | mpl-2.0 | -3,478,365,595,080,684,500 | 30.76 | 151 | 0.558338 | false |
thisisALPINE/subterfuge | modules/views.py | 21 | 6546 | import os
#Django Web Modules
from django.template import Context, loader
from django.http import HttpResponse
from django.http import HttpRequest
from django.http import HttpResponseRedirect
from django.shortcuts import render_to_response
from django.views.decorators.csrf import csrf_protect
from django.views.deco... | gpl-3.0 | -4,396,786,117,080,553,000 | 33.634921 | 169 | 0.602047 | false |
DougFirErickson/qgisSpaceSyntaxToolkit | esstoolkit/external/networkx/algorithms/operators/all.py | 11 | 4215 | """Operations on many graphs.
"""
# Copyright (C) 2013 by
# Aric Hagberg <hagberg@lanl.gov>
# Dan Schult <dschult@colgate.edu>
# Pieter Swart <swart@lanl.gov>
# All rights reserved.
# BSD license.
try:
from itertools import izip_longest as zip_longest
except ImportError: # Python3 has zip_longest
... | gpl-3.0 | 9,105,696,972,748,943,000 | 26.913907 | 79 | 0.638909 | false |
Tagar/incubator-airflow | airflow/contrib/sensors/wasb_sensor.py | 3 | 3696 | # -*- 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,009,662,320,566,134,000 | 36.333333 | 75 | 0.650974 | false |
gkarlin/django-jenkins | build/pylint/epylint.py | 3 | 6363 | # -*- coding: utf-8; mode: python; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=python:et:sw=4:ts=4:sts=4
# Copyright (c) 2003-2012 LOGILAB S.A. (Paris, FRANCE).
# http://www.logilab.fr/ -- mailto:contact@logilab.fr
#
# This program is free software; you can redistribute it and/or modify... | lgpl-3.0 | -1,224,322,329,500,459,000 | 37.563636 | 137 | 0.664938 | false |
brianjgeiger/osf.io | tests/test_cas_authentication.py | 4 | 14397 | # -*- coding: utf-8 -*-
import furl
import responses
import mock
from nose.tools import * # noqa: F403
import unittest
from framework.auth import cas
from tests.base import OsfTestCase, fake
from osf_tests.factories import UserFactory
def make_successful_response(user):
return cas.CasResponse(
authenti... | apache-2.0 | 7,033,508,628,497,800,000 | 37.792453 | 117 | 0.627501 | false |
pettarin/ipapy | ipapy/data/__init__.py | 1 | 8249 | #!/usr/bin/env python
# coding=utf-8
"""
ipapy contains data and functions to work with IPA strings.
This module defines data constants and it loads the built-in IPA database.
"""
from __future__ import absolute_import
from __future__ import print_function
import io
import re
import os
from ipapy.compatibility impo... | mit | 2,773,272,724,314,759,700 | 36.325792 | 144 | 0.630864 | false |
MerlinZhang/osf.io | tests/test_mailchimp.py | 16 | 3743 | # -*- coding: utf-8 -*-
import mock
from website import mailchimp_utils
from tests.base import OsfTestCase
from nose.tools import * # noqa; PEP8 asserts
from tests.factories import UserFactory
import mailchimp
from framework.tasks import handlers
class TestMailChimpHelpers(OsfTestCase):
def setUp(self, *args, *... | apache-2.0 | 3,636,353,774,546,548,000 | 45.209877 | 100 | 0.650815 | false |
Azure/azure-linux-extensions | OSPatching/handler.py | 5 | 17340 | #!/usr/bin/python
#
# OSPatching extension
#
# Copyright 2014 Microsoft 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
#
# Unle... | apache-2.0 | -6,010,134,014,404,228,000 | 37.362832 | 228 | 0.627047 | false |
outvader/soclone | soclone/settings.py | 4 | 3026 | """SOClone settings.
A ``local_settings`` module must be made available to define sensitive
and highly installation-specific settings.
The following is a template for the settings which should be provided by
the ``local_settings`` module::
# Database settings
DATABASE_ENGINE = ''
DATABASE_NAME = ''
DATAB... | mit | 7,243,192,881,112,871,000 | 28.096154 | 98 | 0.727032 | false |
bwasti/caffe2 | caffe2/python/model_helper.py | 1 | 22712 | ## @package model_helper
# Module caffe2.python.model_helper
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
from __future__ import unicode_literals
from caffe2.python import core, scope, workspace
from caffe2.python.modeling import parameter_info
from caffe... | apache-2.0 | 2,902,912,391,106,800,000 | 35.691438 | 86 | 0.591273 | false |
matejcik/weblate | weblate/trans/tests/test_reports.py | 3 | 5000 | # -*- coding: utf-8 -*-
#
# Copyright © 2012 - 2016 Michal Čihař <michal@cihar.com>
#
# This file is part of Weblate <https://weblate.org/>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, eith... | gpl-3.0 | 8,745,143,199,600,205,000 | 29.284848 | 78 | 0.537723 | false |
praekelt/seed-stage-based-messaging | subscriptions/migrations/0003_auto_20160322_1534.py | 2 | 1901 | # -*- coding: utf-8 -*-
# Generated by Django 1.9.1 on 2016-03-22 15:34
from __future__ import unicode_literals
import django.db.models.deletion
from django.conf import settings
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
("contentstore", "0002_messag... | bsd-3-clause | -1,693,147,647,634,246,400 | 31.220339 | 80 | 0.54708 | false |
makinacorpus/ionyweb | ionyweb/administration/views/action.py | 2 | 2947 | # -*- coding: utf-8 -*-
from django.conf import settings
from django.core.urlresolvers import resolve
from django.http import Http404
from djangorestframework.response import ErrorResponse
from djangorestframework import status
from ionyweb.plugin.models import PluginRelation
from ionyweb.administration.views import ... | bsd-3-clause | 2,270,526,240,031,009,300 | 35.382716 | 79 | 0.582626 | false |
EvaSDK/sqlalchemy | lib/sqlalchemy/__init__.py | 6 | 2113 | # sqlalchemy/__init__.py
# Copyright (C) 2005-2015 the SQLAlchemy authors and contributors
# <see AUTHORS file>
#
# This module is part of SQLAlchemy and is released under
# the MIT License: http://www.opensource.org/licenses/mit-license.php
from .sql import (
alias,
and_,
asc,
between,
bindparam,... | mit | -3,461,235,421,455,484,000 | 14.311594 | 77 | 0.587317 | false |
roopali8/tempest | tempest/api/network/test_dhcp_ipv6.py | 9 | 18480 | # Copyright 2014 OpenStack Foundation
# All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless requ... | apache-2.0 | -4,462,429,140,617,705,500 | 46.384615 | 79 | 0.518074 | false |
huguesv/PTVS | Python/Product/Miniconda/Miniconda3-x64/Lib/site-packages/win32/scripts/VersionStamp/vssutil.py | 6 | 4694 | import win32con, string, traceback
import win32com.client, win32com.client.gencache
import pythoncom
import time
import os
constants = win32com.client.constants
win32com.client.gencache.EnsureModule('{783CD4E0-9D54-11CF-B8EE-00608CC9A71F}', 0, 5, 0)
error = "vssutil error"
def GetSS():
ss=win32com.client.Dispatch(... | apache-2.0 | -1,498,354,072,023,844,600 | 26.611765 | 109 | 0.702599 | false |
edx/edx-enterprise | tests/test_integrated_channels/test_lms_utils.py | 1 | 2824 | # -*- coding: utf-8 -*-
"""
Tests for the lms_utils used by integration channels.
"""
import unittest
import mock
import pytest
from opaque_keys import InvalidKeyError
from opaque_keys.edx.keys import CourseKey
from integrated_channels.lms_utils import get_course_certificate, get_course_details, get_single_user_grad... | agpl-3.0 | -3,214,498,446,191,658,000 | 38.222222 | 107 | 0.684844 | false |
m1093782566/openstack_org_ceilometer | ceilometer/compute/notifications/__init__.py | 6 | 1335 | #
# Copyright 2013 Intel
#
# Author: Shuangtai Tian <shuangtai.tian@intel.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 r... | apache-2.0 | -5,234,107,409,743,114,000 | 29.340909 | 77 | 0.692884 | false |
timsnyder/bokeh | bokeh/colors/color.py | 2 | 4822 | #-----------------------------------------------------------------------------
# Copyright (c) 2012 - 2019, Anaconda, Inc., and Bokeh Contributors.
# All rights reserved.
#
# The full license is in the file LICENSE.txt, distributed with this software.
#-------------------------------------------------------------------... | bsd-3-clause | 6,358,433,311,000,688,000 | 24.648936 | 82 | 0.412692 | false |
Epirex/android_external_chromium_org | tools/telemetry/telemetry/page/html_page_measurement_results_unittest.py | 23 | 7625 | # Copyright 2013 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import os
import StringIO
import unittest
from telemetry.page import html_page_measurement_results
from telemetry.page import page_set
def _MakePageSet():
... | bsd-3-clause | 7,517,208,105,708,663,000 | 29.62249 | 79 | 0.502164 | false |
amsn/amsn2 | amsn2/ui/front_ends/cocoa/image.py | 2 | 1362 |
from AppKit import *
from amsn2.ui import base
class Image(object):
""" This interface will represent an image to be used by the UI"""
def __init__(self, amsn_core, parent):
"""Initialize the interface. You should store the reference to the core in here """
self._img = NSImage.alloc().initWith... | gpl-2.0 | 3,850,015,471,914,863,600 | 40.272727 | 113 | 0.618209 | false |
kerneltask/micropython | tests/micropython/import_mpy_invalid.py | 2 | 1511 | # test importing of invalid .mpy files
try:
import sys, uio, uos
uio.IOBase
uos.mount
except (ImportError, AttributeError):
print("SKIP")
raise SystemExit
class UserFile(uio.IOBase):
def __init__(self, data):
self.data = memoryview(data)
self.pos = 0
def readinto(self, b... | mit | -3,037,296,073,319,553,500 | 20.898551 | 63 | 0.583719 | false |
sdague/home-assistant | homeassistant/components/lutron_caseta/switch.py | 7 | 1494 | """Support for Lutron Caseta switches."""
import logging
from homeassistant.components.switch import DOMAIN, SwitchEntity
from . import DOMAIN as CASETA_DOMAIN, LutronCasetaDevice
_LOGGER = logging.getLogger(__name__)
async def async_setup_entry(hass, config_entry, async_add_entities):
"""Set up the Lutron Cas... | apache-2.0 | 3,226,165,471,130,838,000 | 29.489796 | 76 | 0.679384 | false |
JackDandy/SickGear | lib/apprise/plugins/NotifyDiscord.py | 2 | 17395 | # -*- coding: utf-8 -*-
#
# Copyright (C) 2019 Chris Caron <lead2gold@gmail.com>
# All rights reserved.
#
# This code is licensed under the MIT License.
#
# 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 th... | gpl-3.0 | -2,154,137,183,837,371,400 | 32.133333 | 79 | 0.539983 | false |
peterfpeterson/mantid | Framework/PythonInterface/test/python/plugins/algorithms/WorkflowAlgorithms/SwapWidthsTest.py | 3 | 3004 | # 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 +
impo... | gpl-3.0 | 8,340,603,536,086,600,000 | 37.025316 | 108 | 0.629161 | false |
Jake0720/XChat-Scripts | short.py | 1 | 3543 | __module_name__ = 'Short'
__module_version__ = '1.0'
__module_description__ = 'Auto link shortener with http://links.ml'
__module_author__ = 'Liam Stanley'
import xchat
import urllib, re
c = '\x0304'
help = ("/short <url|enable|disable>\n"
" - url: url/link that you would like to be shortened. E.g, http://lia... | mit | 9,194,640,254,899,396,000 | 33.067308 | 123 | 0.570421 | false |
colede/qtcreator | tests/system/shared/hook_utils.py | 2 | 21179 | #############################################################################
##
## Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies).
## Contact: http://www.qt-project.org/legal
##
## This file is part of Qt Creator.
##
## Commercial License Usage
## Licensees holding valid commercial Qt licenses may use this f... | lgpl-2.1 | -5,980,354,771,092,611,000 | 50.530414 | 140 | 0.646159 | false |
jbermudezcabrera/campos | examples/building.py | 1 | 2507 | """This example demonstrates the basics on building complete forms using campos.
It creates several fields, marking some of them as required and adding some
custom validation.
Finally fields are added to a CreationForm which have several buttons and a
custom callback connected to one of them. After added, some relate... | mit | 6,705,875,902,798,463,000 | 32.864865 | 80 | 0.623703 | false |
jeffery-do/Vizdoombot | doom/lib/python3.5/site-packages/matplotlib/artist.py | 4 | 46827 | from __future__ import (absolute_import, division, print_function,
unicode_literals)
from matplotlib.externals import six
import re
import warnings
import inspect
import numpy as np
import matplotlib
import matplotlib.cbook as cbook
from matplotlib.cbook import mplDeprecation
from matplotlib i... | mit | 6,246,624,058,802,314,000 | 30.490921 | 79 | 0.556666 | false |
uber/pyro | pyro/infer/mcmc/nuts.py | 1 | 21097 | # Copyright (c) 2017-2019 Uber Technologies, Inc.
# SPDX-License-Identifier: Apache-2.0
from collections import namedtuple
import pyro
import pyro.distributions as dist
from pyro.distributions.util import scalar_like
from pyro.infer.autoguide import init_to_uniform
from pyro.infer.mcmc.hmc import HMC
from pyro.ops.in... | apache-2.0 | -5,235,973,262,115,647,000 | 50.082324 | 112 | 0.592122 | false |
CommitAnalyzingService/CAS_Reader | localrepository.py | 1 | 2688 | """
file: localrepository.py
author: Ben Grawi <bjg1568@rit.edu>
date: October 2013
description: Holds the repository abstraction class
"""
from git import *
from commit import *
from datetime import datetime
import os
import logging
class LocalRepository():
"""
Repository():
description: Abst... | gpl-2.0 | -2,973,074,924,643,994,000 | 31.209877 | 85 | 0.585193 | false |
zbyufei/fabric-bolt | src/fabric_bolt/accounts/forms.py | 17 | 6324 | import string
import random
from django import forms
from django.contrib.auth import get_user_model
from django.contrib.auth.models import Group
from django.contrib.auth.forms import PasswordChangeForm, SetPasswordForm
from django.utils.timezone import now
from django.utils.translation import ugettext_lazy as _
from... | mit | 5,131,589,913,344,467,000 | 29.408654 | 98 | 0.612587 | false |
zstackorg/zstack-woodpecker | integrationtest/vm/basic/test_vm_with_volumes_boot_option.py | 1 | 2167 | '''
New Integration test for testing vm with 2 additional data volumes boot option.
@author: ChenyuanXu
'''
import zstackwoodpecker.test_util as test_util
import zstackwoodpecker.test_lib as test_lib
import zstackwoodpecker.test_state as test_state
import zstacklib.utils.shell as shell
import zstackwoodpecker.opera... | apache-2.0 | -4,675,907,969,492,191,000 | 32.859375 | 108 | 0.704661 | false |
eReuse/DeviceHub | ereuse_devicehub/resources/group/domain.py | 1 | 26205 | from collections import Iterable
from typing import Dict, List, Set, Type
from bson import ObjectId
from ereuse_utils.naming import Naming
from passlib.utils import classproperty
from pydash import compact, difference, difference_with, flatten, map_values, pick, pluck, py_, \
union_by
from pymongo.errors import Op... | agpl-3.0 | -4,580,337,173,036,685,000 | 56.462719 | 120 | 0.629584 | false |
chetan/cherokee | qa/base.py | 2 | 12534 | # -*- coding: utf-8 -*-
# Cherokee QA Tests
#
# Authors:
# Alvaro Lopez Ortega <alvaro@alobbs.com>
#
# Copyright (C) 2001-2010 Alvaro Lopez Ortega
# This file is distributed under the GPL license.
import os
import imp
import sys
import types
import socket
import string
import tempfile
from conf import *
from ut... | gpl-2.0 | 1,023,215,754,151,048,200 | 27.293454 | 106 | 0.476863 | false |
inmcm/micropyGPS | pyboard/GPIO_interrupt_updater.py | 1 | 1474 | from pyb import UART
from pyb import ExtInt
from pyb import Pin
from micropyGPS import MicropyGPS
# Global Flag to Start GPS data Processing
new_data = False
# Callback Function
def pps_callback(line):
print("Updated GPS Object...")
global new_data # Use Global to trigger update
new_data = True
print('... | mit | 5,018,743,199,084,742,000 | 30.361702 | 108 | 0.685889 | false |
kkaushik24/python-design-patterns | creational/builder_pattern.py | 1 | 2207 | from abc import ABCMeta, abstractmethod
class Item():
__metaclass__ = ABCMeta
@abstractmethod
def name(self):
pass
@abstractmethod
def packing(self):
pass
@abstractmethod
def price(self):
pass
class Packing():
__metaclass__ = ABCMeta
@abstractme... | apache-2.0 | 1,464,812,849,426,969,900 | 15.227941 | 66 | 0.572723 | false |
tjcorona/PyFR | pyfr/plugins/catalyst.py | 1 | 7516 | # -*- coding: utf-8 -*-
from ctypes import *
from mpi4py import MPI
import numpy as np
from pyfr.plugins.base import BasePlugin
from pyfr.ctypesutil import load_library
from pyfr.shapes import BaseShape
from pyfr.util import proxylist, subclass_where
import os
# Contains relevant data pertaining to all instances of a... | bsd-3-clause | -1,598,465,594,740,299,800 | 34.45283 | 105 | 0.577967 | false |
DaveBuckingham/robosoft | mctransmitter.py | 1 | 3109 | #
# TRANSMITS COMMANDS TO THE ARDUINO OVER SERIAL
#
import os
import sys
import time
import serial
import struct
import global_data
import record_mode
TRANSMIT_DELAY = 0.08 # SECONDS
# SET TO FALSE FOR TESTING WITHOUT ARDUINO
TRANSMIT = True
# THIS WILL GET ASSIGNED DURING INITIALIZATION
CONNECTION = None
######... | mit | -8,217,914,187,891,279,000 | 23.674603 | 119 | 0.548729 | false |
pierreg/tensorflow | tensorflow/contrib/graph_editor/tests/util_test.py | 28 | 5696 | # 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 | 4,765,823,526,182,708,000 | 37.228188 | 80 | 0.642381 | false |
WimPessemier/OntoManager | ontomanager/ontomanager/triplestore.py | 1 | 4899 | """
Module containing some functions related to the triple store (the global graph).
"""
import os
import rdflib
import fnmatch
import context
from logging import DEBUG, INFO, ERROR
import pprint
PPRINTER = pprint.PrettyPrinter(depth=6)
###############################################################################... | gpl-3.0 | -132,449,730,624,846,110 | 24.252577 | 99 | 0.564809 | false |
kidaa/aurora | src/test/python/apache/aurora/client/cli/test_command_hooks.py | 7 | 5573 | #
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under ... | apache-2.0 | 11,837,275,848,459,540 | 35.664474 | 94 | 0.708774 | false |
hvy/chainer | tests/chainer_tests/functions_tests/evaluation_tests/test_accuracy.py | 6 | 4114 | import unittest
import numpy
import six
import chainer
from chainer.backends import cuda
from chainer import functions
from chainer import testing
from chainer.testing import attr
from chainer.utils import force_array
from chainer.utils import type_check
def accuracy(x, t, ignore_label):
x_ = numpy.rollaxis(x, ... | mit | 8,064,799,634,941,198,000 | 29.029197 | 79 | 0.533787 | false |
seung-lab/kimimaro | kimimaro/postprocess.py | 1 | 19044 | """
Postprocessing for joining skeletons chunks generated by
skeletonizing adjacent image chunks.
Authors: Alex Bae and Will Silversmith
Affiliation: Seung Lab, Princeton Neuroscience Institue
Date: June 2018 - June 2019
This file is part of Kimimaro.
Kimimaro is free software: you can redistribute it and/or modify... | gpl-3.0 | 9,190,897,515,746,704,000 | 30.634551 | 119 | 0.67197 | false |
marionleborgne/nupic.research | tests/nlp/unit/hierarchical_clustering_test.py | 8 | 4036 | #!/usr/bin/env python
# ----------------------------------------------------------------------
# Numenta Platform for Intelligent Computing (NuPIC)
# Copyright (C) 2015, Numenta, Inc. Unless you have purchased from
# Numenta, Inc. a separate commercial license for this software code, the
# following terms and conditio... | agpl-3.0 | -6,371,929,708,740,457,000 | 31.031746 | 81 | 0.657334 | false |
tylertian/Openstack | openstack F/horizon/horizon/dashboards/nova/overview/urls.py | 3 | 1098 | # vim: tabstop=4 shiftwidth=4 softtabstop=4
# Copyright 2012 United States Government as represented by the
# Administrator of the National Aeronautics and Space Administration.
# All Rights Reserved.
#
# Copyright 2012 Nebula, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# no... | apache-2.0 | -4,844,407,295,060,887,000 | 36.862069 | 78 | 0.738616 | false |
phazel/pixelated-user-agent | service/test/unit/adapter/search/test_index_storage_key.py | 9 | 2159 | #
# Copyright (c) 2015 ThoughtWorks, Inc.
#
# Pixelated 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 version.
#
# Pixelated is distrib... | agpl-3.0 | -5,284,624,681,563,570,000 | 40.519231 | 203 | 0.724873 | false |
randlet/Orbis | orbis/orbis.py | 1 | 2525 | import gui
import gui.grid_utils
import numpy
import settings
import shmo
import sys
import os
os.chdir(os.path.dirname(__file__))
import wx
#====================================================================================
class MainFrame(gui.VOrbisFrame):
"""The main Orbis application frame"""
#---------... | bsd-3-clause | -4,218,916,548,015,141,000 | 36.701493 | 90 | 0.457426 | false |
hefen1/chromium | tools/telemetry/telemetry/core/platform/power_monitor/cros_power_monitor.py | 2 | 5726 | # Copyright 2014 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import collections
import re
from telemetry import decorators
from telemetry.core.platform.power_monitor import sysfs_power_monitor
class CrosPowerMonitor... | bsd-3-clause | -7,981,824,072,240,068,000 | 36.424837 | 79 | 0.676388 | false |
cms-externals/sherpa | MODEL/UFO/py_to_cpp.py | 1 | 3556 | """
Conversion of python expressions to C++ compatible strings.
This code is based on 'converter.py', part of the HERWIG++ UFO interface.
Many thanks to David Grellscheid for the permission to use this code.
Does not support custom functions other than the ones in the cmath_dictionary defined below.
Does not support ... | gpl-3.0 | -9,153,510,512,711,954,000 | 26.353846 | 104 | 0.566929 | false |
RubenSchmidt/giscademy | layers/models.py | 1 | 1095 | from django.contrib.gis.db.models import MultiPolygonField, PointField, LineStringField
from django.contrib.postgres.fields import JSONField
from django.db import models
from giscademy.utils.model_utils import Timestampable
class Layer(Timestampable):
name = models.CharField(max_length=255)
exercise = models... | mit | 9,149,400,294,067,611,000 | 21.8125 | 102 | 0.693151 | false |
cntnboys/cmput410-project | venv/lib/python2.7/site-packages/pkg_resources/__init__.py | 16 | 103944 | """
Package resource API
--------------------
A resource is a logical file contained within a package, or a logical
subdirectory thereof. The package resource API expects resource names
to have their path parts separated with ``/``, *not* whatever the local
path separator is. Do not use os.path operations to manipul... | apache-2.0 | 7,487,369,823,120,158,000 | 33.822111 | 82 | 0.592867 | 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.