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 |
|---|---|---|---|---|---|---|---|---|---|---|
devoid/nova | nova/tests/db/test_migration_utils.py | 3 | 28910 | # Copyright (c) 2013 Boris Pavlovic (boris@pavlovic.me).
# 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... | apache-2.0 | 7,695,907,303,963,113,000 | 42.539157 | 79 | 0.511138 | false |
daevaorn/sentry | tests/sentry/api/endpoints/test_user_details.py | 2 | 2045 | from __future__ import absolute_import
from django.core.urlresolvers import reverse
from sentry.models import User
from sentry.testutils import APITestCase
class UserDetailsTest(APITestCase):
def test_simple(self):
user = self.create_user(email='a@example.com')
self.login_as(user=user)
... | bsd-3-clause | 8,106,798,348,610,766,000 | 28.637681 | 78 | 0.577995 | false |
airbnb/airflow | airflow/contrib/hooks/spark_jdbc_hook.py | 7 | 1170 | #
# 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 | 5,826,819,363,365,302,000 | 39.344828 | 95 | 0.768376 | false |
mediatum/mediatum | core/database/postgres/connector.py | 1 | 20887 | # -*- coding: utf-8 -*-
"""
:copyright: (c) 2014 by the mediaTUM authors
:license: GPL3, see COPYING for details
"""
import logging
import atexit
import pwd
import os.path
import time
from sqlalchemy import create_engine, event
from sqlalchemy.engine import Engine
from sqlalchemy.orm import sessionmaker, scope... | gpl-3.0 | 7,418,163,225,976,108,000 | 41.713701 | 147 | 0.627759 | false |
wbinventor/openmc | examples/python/pincell_multigroup/build-xml.py | 1 | 7284 | import numpy as np
import openmc
import openmc.mgxs
###############################################################################
# Simulation Input File Parameters
###############################################################################
# OpenMC simulation parameters
batches = 100
inac... | mit | 5,276,218,147,830,047,000 | 40.386364 | 86 | 0.587589 | false |
orchidinfosys/odoo | addons/sale/report/sale_report.py | 2 | 6005 | # -*- coding: utf-8 -*-
# Part of Odoo. See LICENSE file for full copyright and licensing details.
from openerp import tools
from openerp.osv import fields, osv
class sale_report(osv.osv):
_name = "sale.report"
_description = "Sales Orders Statistics"
_auto = False
_rec_name = 'date'
_columns = {... | gpl-3.0 | -4,253,150,912,885,934,000 | 48.628099 | 143 | 0.531724 | false |
magicrub/MissionPlanner | Lib/site-packages/scipy/lib/blas/__init__.py | 57 | 2028 | #
# BLAS wrappers
#
from info import __doc__
__all__ = ['fblas','cblas','get_blas_funcs']
import fblas
import cblas
_use_force_cblas = 1
if hasattr(cblas,'empty_module'):
cblas = fblas
_use_force_cblas = 0
elif hasattr(fblas,'empty_module'):
fblas = cblas
_type_conv = {'f':'s', 'd':'d', 'F':'c', 'D':'z... | gpl-3.0 | -199,373,108,604,541,630 | 28.823529 | 82 | 0.562623 | false |
papapep/python | PFE_UMichigan/4_UsingDatabases/Week5/Geocoding/geoload.py | 1 | 1806 | import urllib
import sqlite3
import json
import time
import ssl
# If you are in China use this URL:
# serviceurl = "http://maps.google.cn/maps/api/geocode/json?"
#serviceurl = "http://maps.googleapis.com/maps/api/geocode/json?"
serviceurl = 'https://maps.googleapis.com/maps/api/place/textsearch/json?'
apikey ='YOUR AP... | gpl-3.0 | -1,836,214,071,308,913,400 | 28.606557 | 91 | 0.638981 | false |
plowman/python-mcparseface | models/syntaxnet/tensorflow/tensorflow/contrib/learn/python/learn/preprocessing/categorical.py | 7 | 4053 | """Implements preprocesing transformers for categorical variables."""
# Copyright 2015-present The Scikit Flow 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 a... | apache-2.0 | -2,279,777,209,195,272,400 | 31.685484 | 79 | 0.680237 | false |
alexston/calibre-webserver | src/calibre/ebooks/metadata/book/__init__.py | 9 | 5366 | #!/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'
'''
All fields must have a NULL value represented as None for simple types,
an empty list/dictionary for complex types and ... | gpl-3.0 | -954,920,378,011,277,400 | 39.044776 | 82 | 0.581439 | false |
HybridF5/nova | nova/tests/functional/api_sample_tests/test_cloudpipe.py | 8 | 3439 | # Copyright 2014 IBM Corp.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed t... | apache-2.0 | 5,554,966,729,186,697,000 | 38.528736 | 78 | 0.623437 | false |
fubecka/f5-dashboard | flask/lib/python2.6/site-packages/pbr/tests/test_setup.py | 20 | 15025 | # vim: tabstop=4 shiftwidth=4 softtabstop=4
# Copyright (c) 2011 OpenStack Foundation
# Copyright (c) 2013 Hewlett-Packard Development Company, L.P.
# 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 obta... | apache-2.0 | 6,605,694,283,085,214,000 | 39.173797 | 78 | 0.602995 | false |
xijunlee/leetcode | 39.py | 1 | 1578 | #!/usr/bin/env python
# coding=utf-8
import copy
class Solution(object):
def combinationSum(self, candidates, target):
"""
:type candidates: List[int]
:type target: int
:rtype: List[List[int]]
"""
ret = []
def dfs(sum, step, stack):
if step>=le... | mit | -3,387,380,965,697,453,000 | 26.701754 | 66 | 0.479087 | false |
log2timeline/dfvfs | tests/resolver_helpers/qcow_resolver_helper.py | 2 | 1443 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
"""Tests for the QCOW image resolver helper implementation."""
import unittest
from dfvfs.lib import definitions
from dfvfs.path import factory as path_spec_factory
from dfvfs.resolver_helpers import qcow_resolver_helper
from tests.resolver_helpers import test_lib
clas... | apache-2.0 | -6,156,833,488,490,423,000 | 33.357143 | 73 | 0.737353 | false |
mapeveri/django-endless-pagination-angular | endless_pagination/tests/integration/__init__.py | 9 | 5479 | """Integration tests base objects definitions."""
from __future__ import unicode_literals
from contextlib import contextmanager
import os
from django.core.urlresolvers import reverse
from django.http import QueryDict
from django.test import LiveServerTestCase
from django.utils import unittest
from selenium.common imp... | mit | -6,592,669,038,139,208,000 | 34.577922 | 79 | 0.632232 | false |
rob-smallshire/asq | docs/source/conf.py | 1 | 7442 | # -*- coding: utf-8 -*-
#
# asq documentation build configuration file, created by
# sphinx-quickstart on Thu Feb 17 19:12:20 2011.
#
# This file is execfile()d with the current directory set to its containing dir.
#
# Note that not all possible configuration values are present in this
# autogenerated file.
#
# All con... | mit | 5,043,088,478,161,745,000 | 31.356522 | 82 | 0.707068 | false |
doug-wade/AlgorithmsGreatestHits | graph_algorithms/topological_sort.py | 2 | 1397 | from collections import deque
def depth_first_search(graph, start, path, explored):
"""
Performs depth-first search to find a sink node. At the sink node, it
appends the sink node to a queue, which tracks the topological sorting
of the graph.
"""
explored |= {start}
if start in graph.keys(... | mit | 2,767,040,236,139,109,000 | 28.104167 | 78 | 0.595562 | false |
bartoldeman/easybuild-easyconfigs | easybuild/easyconfigs/l/LAMMPS/lammps_vs_yaff_test_single_point_energy.py | 6 | 109971 | #!/usr/bin/env python
#
# Correctness test for LAMMPS, comparison with result produced by yaff;
# calculates single-point energy with both LAMMPS and yaff, and compares the results.
# The energy difference should not exceed 1 kJ/mol, otherwise an error is raised.
# It should run to completion in a matter of seconds.
#
... | gpl-2.0 | 4,154,871,986,466,351,600 | 81.996981 | 101 | 0.478535 | false |
keishi/chromium | third_party/mesa/MesaLib/src/gallium/tests/graw/fragment-shader/fragment-shader.py | 32 | 7321 | #!/usr/bin/env python
##########################################################################
#
# Copyright 2009 VMware, Inc.
# All Rights Reserved.
#
# Permission is hereby granted, free of charge, to any person obtaining a
# copy of this software and associated documentation files (the
# "Software"), to deal in ... | bsd-3-clause | 7,435,287,178,502,534,000 | 27.486381 | 99 | 0.542002 | false |
grundic/yagocd | tests/test_package_repository.py | 1 | 7501 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
###############################################################################
# The MIT License
#
# Copyright (c) 2016 Grigory Chernyshev
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation file... | isc | -2,367,280,102,324,830,700 | 32.337778 | 106 | 0.639781 | false |
cyberplant/scrapy | tests/test_spiderstate.py | 17 | 1292 | import os
from datetime import datetime
from twisted.trial import unittest
from scrapy.extensions.spiderstate import SpiderState
from scrapy.spiders import Spider
from scrapy.exceptions import NotConfigured
from scrapy.utils.test import get_crawler
class SpiderStateTest(unittest.TestCase):
def test_store_load(s... | bsd-3-clause | 5,931,210,219,580,721,000 | 29.761905 | 76 | 0.658669 | false |
olakiril/pipeline | python/pipeline/settings.py | 6 | 3063 | """
Settings for DataJoint.
"""
import json
from collections import OrderedDict
from .exceptions import PipelineException
import collections
from pprint import pformat
LOCALCONFIG = 'pipeline_config.json'
GLOBALCONFIG = '.pipeline_config.json'
validators = collections.defaultdict(lambda: lambda value: True)
default =... | lgpl-3.0 | -8,438,406,022,688,926,000 | 30.265306 | 110 | 0.589944 | false |
trolldbois/python-haystack-reverse | test/haystack/reverse/test_structure.py | 1 | 6644 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
"""Tests for haystack.reverse.structure."""
import logging
import os
import unittest
from haystack.mappings import folder
from haystack.reverse import config
from haystack.reverse import context
from haystack.reverse import fieldtypes
from haystack.reverse import structu... | gpl-3.0 | -5,797,053,801,691,626,000 | 36.965714 | 102 | 0.613486 | false |
khchine5/xl | lino_xl/lib/ledger/accounts.py | 1 | 1481 | # -*- coding: UTF-8 -*-
# Copyright 2012-2017 Luc Saffre
# License: BSD (see file COPYING for details)
"""Defines referrable names for certain well-known accounts.
These names depend on :attr:`lino_xl.lib.ledger.Plugin.use_pcmn`
Currently used by the :mod:`minimal_ledger
<lino_xl.lib.ledger.fixtures.minimal_ledger>`... | bsd-2-clause | -913,734,980,422,852,400 | 28.62 | 66 | 0.717083 | false |
nathanross/amiens | src/amiens/core/util.py | 1 | 6740 | #!/usr/bin/python3
# Copyright 2015 Nathan Ross
#
# 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... | apache-2.0 | -7,644,443,310,563,183,000 | 28.432314 | 84 | 0.549407 | false |
roadmapper/ansible | lib/ansible/modules/cloud/vmware/vmware_host_vmhba_info.py | 6 | 8764 | #!/usr/bin/python
# -*- coding: utf-8 -*-
# Copyright: (c) 2018, Christian Kotte <christian.kotte@gmx.de>
# 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 = {
'metad... | gpl-3.0 | 2,828,567,438,932,037,600 | 37.270742 | 109 | 0.516203 | false |
sealcode/gpandoc | settings.py | 1 | 2909 | import os
import sys
import configparser
import settings_dialog
import PyQt5
from PyQt5 import QtGui
from PyQt5.QtGui import QFont
"""
Settings with global variables
"""
pathsOfDocuments = []
listPaths = []
selectedRecipe = ""
loadedRecipe = ""
defaultRecipe = ""
zipsFolder = ""
tempFolder = ""
localPath = ""
sets... | lgpl-3.0 | -4,959,815,925,449,559,000 | 24.517544 | 89 | 0.66449 | false |
platinhom/CADDHom | python/algorithm/Data2D.py | 1 | 20820 | '''Module for 2D data based on numpy.ndarray'''
__author__="Zhixiong Zhao"
__date__="2015.12.08"
import string
#import traceback
import numpy as np
### Test Data
a=[[1,2,3],[2,3,4],[3,4,5],[4,5,6]]
b=Data2D(a)
c=Data2D([1,1.2,1.4,1.6]).T
class mlarray(np.ndarray):
@property
def I(self):
''' Inverse of the array... | gpl-2.0 | 3,786,618,927,551,604,700 | 29.261628 | 141 | 0.651633 | false |
nrz/ylikuutio | external/bullet3/examples/pybullet/gym/pybullet_envs/minitaur/envs/minitaur_randomize_terrain_gym_env_example.py | 2 | 2208 | """An example to run minitaur gym environment with randomized terrain.
"""
import math
import numpy as np
import tf.compat.v1 as tf
#from google3.pyglib import app
#from google3.pyglib import flags
from pybullet_envs.minitaur.envs import minitaur_randomize_terrain_gym_env
FLAGS = flags.FLAGS
flags.DEFINE_enum("exa... | agpl-3.0 | 8,645,204,355,993,900,000 | 27.675325 | 97 | 0.663496 | false |
drlagos/unify-playpen | playpen.py | 1 | 1433 | import subprocess
def playpen(command, arguments):
return subprocess.Popen(("playpen",
"root",
"--mount-proc",
"--user=rust",
"--timeout=5",
"--syscalls-file=whitelist",
... | mit | 6,710,819,243,707,378,000 | 37.72973 | 58 | 0.432659 | false |
tedder/ansible | lib/ansible/modules/network/checkpoint/checkpoint_host_facts.py | 30 | 2740 | #!/usr/bin/python
#
# This file is part of Ansible
#
# Ansible is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# Ansible is distribut... | gpl-3.0 | -1,846,599,469,748,569,900 | 25.862745 | 108 | 0.683212 | false |
Bismarrck/tensorflow | tensorflow/python/data/experimental/kernel_tests/optimization/map_vectorization_test.py | 3 | 16516 | # Copyright 2018 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,651,972,429,710,658,000 | 36.282167 | 80 | 0.635989 | false |
virtualopensystems/nova | nova/tests/virt/vmwareapi/test_driver_api.py | 1 | 125894 | # Copyright (c) 2013 Hewlett-Packard Development Company, L.P.
# Copyright (c) 2012 VMware, Inc.
# Copyright (c) 2011 Citrix Systems, Inc.
# Copyright 2011 OpenStack Foundation
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. Yo... | apache-2.0 | 8,041,043,002,991,961,000 | 43.834046 | 79 | 0.560479 | false |
apple/swift-lldb | packages/Python/lldbsuite/test/functionalities/memory/read/TestMemoryRead.py | 5 | 5028 | """
Test the 'memory read' command.
"""
from __future__ import print_function
import lldb
from lldbsuite.test.lldbtest import *
import lldbsuite.test.lldbutil as lldbutil
class MemoryReadTestCase(TestBase):
mydir = TestBase.compute_mydir(__file__)
def setUp(self):
# Call super's setUp().
... | apache-2.0 | -4,204,341,505,956,777,500 | 36.522388 | 82 | 0.538385 | false |
guardicore/monkey | monkey/infection_monkey/system_info/collectors/scoutsuite_collector/scoutsuite_collector.py | 1 | 1280 | import logging
from typing import Union
import ScoutSuite.api_run
from ScoutSuite.providers.base.provider import BaseProvider
from common.cloud.scoutsuite_consts import CloudProviders
from common.utils.exceptions import ScoutSuiteScanError
from infection_monkey.config import WormConfiguration
from infection_monkey.te... | gpl-3.0 | -3,070,371,654,368,405,500 | 35.571429 | 88 | 0.751563 | false |
sneeu/little | little/migrations/0003_auto__add_visit.py | 1 | 6090 | # -*- coding: utf-8 -*-
from south.utils import datetime_utils as datetime
from south.db import db
from south.v2 import SchemaMigration
from django.db import models
class Migration(SchemaMigration):
def forwards(self, orm):
# Adding model 'Visit'
db.create_table(u'little_visit', (
(u'... | mit | -474,116,276,274,267,140 | 65.934066 | 195 | 0.556979 | false |
agussman/talon | talon/signature/learning/featurespace.py | 8 | 2965 | # -*- coding: utf-8 -*-
""" The module provides functions for conversion of a message body/body lines
into classifiers features space.
The body and the message sender string are converted into unicode before
applying features to them.
"""
from talon.signature.constants import (SIGNATURE_MAX_LINES,
... | apache-2.0 | -314,456,891,696,160,000 | 39.067568 | 78 | 0.661046 | false |
mohland/dogetipbot | src/ctb/ctb_action.py | 2 | 56747 | """
This file is part of ALTcointip.
ALTcointip 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.
ALTcointip is distr... | gpl-2.0 | 9,034,789,442,223,852,000 | 44.144789 | 223 | 0.527693 | false |
Devyani-Divs/twython | setup.py | 1 | 1293 | #!/usr/bin/env python
import os
import sys
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
__author__ = 'Ryan McGrath <ryan@venodesigns.net>'
__version__ = '3.2.0'
packages = [
'twython',
'twython.streaming'
]
if sys.argv[-1] == 'publish':
os.system('pytho... | mit | 866,624,229,310,748,300 | 27.108696 | 71 | 0.641145 | false |
Fat-Zer/FreeCAD_sf_master | src/Mod/Fem/femtest/app/support_utils.py | 12 | 13251 | # ***************************************************************************
# * Copyright (c) 2018 Bernd Hahnebach <bernd@bimstatik.org> *
# * *
# * This file is part of the FreeCAD CAx development system. *
# * ... | lgpl-2.1 | 7,238,724,692,584,307,000 | 30.55 | 96 | 0.556713 | false |
prophile/django_split | tests/test_overlapping.py | 1 | 1674 | import pytest
from django_split.utils import overlapping
class OverlappingTests(object):
def test_identity(self):
assert overlapping(
(10, 30),
(10, 30),
)
def test_contains(self):
assert overlapping(
(10, 30),
(0, 40),
)
de... | mit | -3,989,410,077,130,463,000 | 21.32 | 73 | 0.469534 | false |
bancek/egradebook | src/lib/debug_toolbar/panels/template.py | 11 | 5162 | from os.path import normpath
from pprint import pformat
from django import http
from django.conf import settings
from django.core.signals import request_started
from django.dispatch import Signal
from django.template.context import get_standard_processors
from django.template.loader import render_to_string
from django... | gpl-3.0 | 6,607,130,047,074,682,000 | 41.311475 | 96 | 0.603255 | false |
ESOedX/edx-platform | openedx/core/djangoapps/user_api/accounts/utils.py | 1 | 7905 | """
Utility methods for the account settings.
"""
from __future__ import absolute_import, unicode_literals
import random
import re
import string
import waffle
from completion import waffle as completion_waffle
from completion.models import BlockCompletion
from django.conf import settings
from django.utils.translation... | agpl-3.0 | -1,499,620,048,383,449,000 | 35.597222 | 118 | 0.68425 | false |
noironetworks/heat | heat/tests/openstack/sahara/test_cluster.py | 1 | 9642 | # Copyright (c) 2014 Mirantis Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writ... | apache-2.0 | 5,846,905,977,214,334,000 | 40.560345 | 77 | 0.627671 | false |
moiseslorap/RIT | Computer Science 1/Miscellaneous/slList.py | 4 | 7414 | """
File: slList.py
Purpose: rit_object-based single-linked list for CS141 LECTURE.
Author: ben k steele <bks@cs.rit.edu>
Author: sean strout <sps@cs.rit.edu>
Language: Python 3
Description: Implementation of a single-linked list data structure.
"""
from slCursor import *
##############################################... | mit | -8,660,290,868,300,033,000 | 27.40613 | 115 | 0.4884 | false |
tuxology/bcc | examples/tracing/hello_perf_output_using_ns.py | 2 | 1843 | #!/usr/bin/python
# Carlos Neira <cneirabustos@gmail.com>
# This is a Hello World example that uses BPF_PERF_OUTPUT.
# in this example bpf_get_ns_current_pid_tgid(), this helper
# works inside pid namespaces.
# bpf_get_current_pid_tgid() only returns the host pid outside any
# namespace and this will not work when the ... | apache-2.0 | -1,083,691,668,696,982,900 | 23.573333 | 81 | 0.642973 | false |
ulrichard/electrum | lib/daemon.py | 1 | 5794 | #!/usr/bin/env python
#
# Electrum - lightweight Bitcoin client
# Copyright (C) 2015 Thomas Voegtlin
#
# 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 y... | gpl-3.0 | -4,235,953,728,070,261,000 | 34.546012 | 105 | 0.616155 | false |
nagyistoce/edx-platform | lms/djangoapps/instructor/views/api.py | 11 | 100710 | """
Instructor Dashboard API views
JSON views which the instructor dashboard requests.
Many of these GETs may become PUTs in the future.
"""
import StringIO
import json
import logging
import re
import time
import requests
from django.conf import settings
from django.views.decorators.csrf import ensure_csrf_cookie
fro... | agpl-3.0 | 3,830,859,681,415,716,400 | 38.324483 | 159 | 0.653421 | false |
ee08b397/LeetCode-4 | 225 Implement Stack using Queues.py | 3 | 1673 | """
Implement the following operations of a stack using queues.
push(x) -- Push element x onto stack.
pop() -- Removes the element on top of the stack.
top() -- Get the top element.
empty() -- Return whether the stack is empty.
Notes:
You must use only standard operations of a queue -- which means only push to back, p... | mit | -7,114,226,794,162,634,000 | 24.348485 | 118 | 0.54991 | false |
manojgudi/sandhi | modules/gr36/grc/python/extract_docs.py | 11 | 2155 | """
Copyright 2008-2011 Free Software Foundation, Inc.
This file is part of GNU Radio
GNU Radio Companion 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 l... | gpl-3.0 | 9,208,080,398,036,305,000 | 31.651515 | 80 | 0.67471 | false |
wuzheng-sjtu/FastFPN | libs/memory_util.py | 2 | 13633 | import os
import re
import sys
import tempfile
import tensorflow as tf
debug_messages = False
def vlog(level):
os.environ['TF_CPP_MIN_VLOG_LEVEL'] = str(level)
# this helper is here in case we later want to capture huge stderr that doesn't fit in RAM
class TemporaryFileHelper:
"""Provides a way to fetch contents... | apache-2.0 | -6,577,896,874,996,883,000 | 44.142384 | 363 | 0.633463 | false |
diorcety/translate | translate/storage/bundleprojstore.py | 3 | 10529 | # -*- coding: utf-8 -*-
#
# Copyright 2010 Zuza Software Foundation
#
# This file is part of the Translate Toolkit.
#
# 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 Lice... | gpl-2.0 | -6,607,760,367,712,483,000 | 36.738351 | 94 | 0.595403 | false |
Cadasta/cadasta-platform | cadasta/spatial/models.py | 1 | 11284 | from core.models import RandomIDModel
from django.utils.functional import cached_property
from django.core.urlresolvers import reverse
from django.contrib.gis.db.models import GeometryField
from django.contrib.postgres.fields import JSONField
from django.db import models
from django.utils.translation import ugettext as... | agpl-3.0 | 2,044,181,148,656,346,400 | 36.613333 | 128 | 0.635147 | false |
Anaatti/Follow-the-leader-simulation | src/follower.py | 1 | 2059 | '''
Created on 16.3.2012
@author: Antti Vainio
'''
from thinker import thinker
class follower(thinker):
'''
This class is a very simple derivation of the thinker class.
The class implements the required think() function where it tries to follow its leader.
'''
def __init__(self, leader, x, y, ma... | unlicense | 3,078,281,819,314,505,000 | 38.596154 | 121 | 0.569694 | false |
mlhim/tb | src/data_RDF_gen.py | 1 | 5580 | #!/usr/bin/env python
# -*- coding: UTF-8 -*-
"""
data_RDF_gen.py
Extracts MLHIM 2.5.0 data and creates RDF triples in RDF/XML based on the CCDs.
This script must be executed after the the CCD RDF/XML files are created.
Copyright (C) 2015 Timothy W. Cook tim@mlhim.org
This program is free software: you can ... | gpl-3.0 | 1,293,129,447,734,749,700 | 39.434783 | 123 | 0.596237 | false |
indradhanush/U1DB-ZeroMQ-Transport | zmq_transport/u1db/zmq_target.py | 1 | 14544 | """
SyncTarget API implementation to a remote ZMQ server.
"""
# Local Imports
from zmq_transport.client.zmq_client import ZMQClientBase
from zmq_transport.common.errors import UserIDNotSet
from zmq_transport.common import message_pb2 as proto
from zmq_transport.common.utils import (
serialize_msg,
create_get_sy... | gpl-2.0 | -3,582,001,112,336,405,500 | 40.084746 | 83 | 0.611386 | false |
Tiglas/pickup-planner | request_handler/request_handler.py | 1 | 2210 | #!flask/bin/python
from flask import Flask, jsonify, abort
from flask import make_response
from flask import request
from flask import url_for
import psycopg2 as pg
app = Flask(__name__)
def make_public_request(request):
new_request = {}
new_request['uri'] = url_for('get_requests', request_id=request[0], _ex... | mit | 5,616,394,711,720,372,000 | 29.273973 | 103 | 0.654299 | false |
pointhi/searx | tests/unit/engines/test_yahoo.py | 1 | 5765 | # -*- coding: utf-8 -*-
from collections import defaultdict
import mock
from searx.engines import yahoo
from searx.testing import SearxTestCase
class TestYahooEngine(SearxTestCase):
def test_parse_url(self):
test_url = 'http://r.search.yahoo.com/_ylt=A0LEb9JUSKcAEGRXNyoA;_ylu=X3oDMTEzZm1qazYwBHNlYwNzcgRw... | agpl-3.0 | 6,518,948,343,053,568,000 | 39.598592 | 119 | 0.566522 | false |
ppjk1/conference-central | models.py | 1 | 6153 | #!/usr/bin/env python
"""models.py
Udacity conference server-side Python App Engine data & ProtoRPC models
$Id: models.py,v 1.1 2014/05/24 22:01:10 wesc Exp $
created/forked from conferences.py by wesc on 2014 may 24
"""
__author__ = 'wesc+api@google.com (Wesley Chun)'
import httplib
import endpoints
from protor... | apache-2.0 | -4,351,080,315,380,698,000 | 31.384211 | 83 | 0.685357 | false |
asmundg/coherence | misc/Rhythmbox-Plugin/upnp_coherence/__init__.py | 5 | 18399 | # -*- Mode: python; coding: utf-8; tab-width: 8; indent-tabs-mode: t; -*-
#
# Copyright 2011, Caleb Callaway <enlightened-despot@gmail.com>
# Copyright 2008-2010, Frank Scholz <dev@coherence-project.org>
# Copyright 2008, James Livingston <doclivingston@gmail.com>
#
# Licensed under the MIT license
# http://opensource.... | mit | -5,631,350,750,587,948,000 | 38.911063 | 119 | 0.552856 | false |
bbc/kamaelia | Sketches/MH/Layout/Visualisation/Axon/PComponent.py | 3 | 3060 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
# Copyright 2010 British Broadcasting Corporation and Kamaelia Contributors(1)
#
# (1) Kamaelia Contributors are listed in the AUTHORS file and at
# http://www.kamaelia.org/AUTHORS - please extend this file,
# not this notice.
#
# Licensed under the Apache License,... | apache-2.0 | 7,623,455,718,069,045,000 | 33 | 111 | 0.583333 | false |
tanglei528/nova | nova/tests/api/openstack/compute/contrib/test_hosts.py | 13 | 17166 | # Copyright (c) 2011 OpenStack Foundation
# All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless ... | apache-2.0 | 98,876,251,007,403,070 | 38.644342 | 78 | 0.611092 | false |
michaelarnauts/home-assistant | tests/components/test_device_sun_light_trigger.py | 5 | 3506 | """
tests.test_component_device_sun_light_trigger
~~~~~~~~~~~~~~~~~~~~~~~~~~
Tests device sun light trigger component.
"""
# pylint: disable=too-many-public-methods,protected-access
import os
import unittest
import homeassistant.loader as loader
from homeassistant.const import CONF_PLATFORM
from homeassistant.compone... | mit | 6,791,135,812,417,860,000 | 26.606299 | 78 | 0.635767 | false |
bjoernricks/kommons | docs/source/conf.py | 1 | 7934 | # -*- coding: utf-8 -*-
#
# kommons documentation build configuration file, created by
# sphinx-quickstart on Thu Oct 10 20:29:23 2013.
#
# This file is execfile()d with the current directory set to its containing dir.
#
# Note that not all possible configuration values are present in this
# autogenerated file.
#
# All... | lgpl-2.1 | -3,670,814,229,177,733,000 | 30.863454 | 80 | 0.704311 | false |
tensorflow/quantum | tensorflow_quantum/core/ops/math_ops/inner_product_op.py | 1 | 6703 | # Copyright 2020 The TensorFlow Quantum 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... | apache-2.0 | -5,318,145,168,956,347,000 | 44.290541 | 80 | 0.627629 | false |
bobbyrward/fr0st | fr0stlib/gui/preview.py | 1 | 7462 | import wx, sys, numpy as N
from fr0stlib.decorators import *
from config import config
from _events import InMain
class PreviewFrame(wx.Frame):
@BindEvents
def __init__(self,parent):
self.title = "Flame Preview"
self.parent = parent
wx.Frame.__init__(self,parent,wx.I... | gpl-3.0 | -5,828,525,901,854,154,000 | 26.158491 | 75 | 0.531761 | false |
stonier/ecto | python/ecto/cell.py | 3 | 2815 | #
# Copyright (c) 2011, Willow Garage, Inc.
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
# * Redistributions of source code must retain the above copyright
# notice, this list of cond... | bsd-3-clause | -2,987,144,213,507,633,000 | 40.397059 | 79 | 0.662167 | false |
vrenkens/Nabu-asr | nabu/scripts/prepare_data.py | 2 | 2975 | '''dataprep.py
does the data preperation for a single database'''
import sys
import os
sys.path.append(os.getcwd())
import subprocess
import shutil
from six.moves import configparser
import tensorflow as tf
import data
def main(expdir, recipe, computing):
'''main method'''
if recipe is None:
raise Ex... | mit | -3,562,746,009,994,248,700 | 32.806818 | 75 | 0.567395 | false |
nickhand/pyRSD | pyRSD/rsdfit/solvers/emcee_solver.py | 1 | 15344 | from ... import numpy as np, os
from .. import logging
from ..results import EmceeResults
from . import tools, objectives
import time
import signal
import traceback
import functools
logger = logging.getLogger('rsdfit.emcee_fitter')
logger.addHandler(logging.NullHandler())
#-------------------------------------------... | gpl-3.0 | -4,063,767,412,536,699,400 | 40.358491 | 136 | 0.590394 | false |
kYc0o/RIOT | tests/posix_time/tests/01-run.py | 21 | 1343 | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
# vim:fenc=utf-8
# Copyright (C) 2017 Freie Universität Berlin
#
# This file is subject to the terms and conditions of the GNU Lesser
# General Public License v2.1. See the file LICENSE in the top level
# directory for more details.
import sys
import time
from testrunner... | lgpl-2.1 | -2,776,041,272,215,573,000 | 27.553191 | 86 | 0.592399 | false |
breunigs/livestreamer-debian | src/livestreamer/plugins/nhkworld.py | 34 | 1262 | """Plugin for NHK World, NHK Japan's english TV channel."""
import re
from livestreamer.plugin import Plugin
from livestreamer.plugin.api import http, validate
from livestreamer.stream import HDSStream
API_URL = "http://api.sh.nhk.fivecool.tv/api/cdn/?publicId=3bz2huey&playerId=7Dy"
_url_re = re.compile("http(s)?:/... | bsd-2-clause | -3,643,217,686,225,475,000 | 27.044444 | 88 | 0.576862 | false |
hajicj/FEL-NLP-IR_2016 | npfl103/io/collection.py | 1 | 5340 | # -*- coding: utf-8 -*-
"""This module implements a class that..."""
from __future__ import print_function, unicode_literals
import logging
import os
import xml.etree.ElementTree as ET
import time
from npfl103.io.document import Document
from npfl103.io.topic import Topic
__version__ = "0.0.1"
__author__ = "Jan Haj... | apache-2.0 | -4,777,920,385,166,660,000 | 33.179487 | 83 | 0.586272 | false |
paolomonella/ursus | xmlToolBox/lxmlToolBox.py | 1 | 11692 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# This script simplifies the encoding of casanatensis.xml
# and creates a file ALIM2_publication/casanatensis_AL.xml
# with the Alphabetic Layer only.
#
# It's written in Python 3.4, but also works with Python 2.7.
# It uses the Python lxml library.
from __future__ impo... | gpl-2.0 | -5,554,226,811,947,690,000 | 38.486486 | 124 | 0.539185 | false |
alialiev/dj-stripe | djstripe/signals.py | 4 | 1499 | # -*- coding: utf-8 -*-
from django.dispatch import Signal
cancelled = Signal(providing_args=["stripe_response"])
card_changed = Signal(providing_args=["stripe_response"])
subscription_made = Signal(providing_args=["plan", "stripe_response"])
webhook_processing_error = Signal(providing_args=["data", "exception"])
WE... | bsd-3-clause | -867,833,763,552,967,400 | 29.591837 | 71 | 0.603069 | false |
rapidpro/tracpro | tracpro/orgs_ext/migrations/0002_auto_20150724_1609.py | 2 | 1035 | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
import json
from django.conf import settings
from django.db import models, migrations
def add_available_languages(apps, schema_editor):
"""Set default available_languages to all languages defined for this project."""
all_languages = [l[0] for l... | bsd-3-clause | -4,159,729,107,407,770,000 | 29.441176 | 84 | 0.634783 | false |
facebookresearch/Detectron | detectron/core/test_retinanet.py | 1 | 7825 | # Copyright (c) 2017-present, Facebook, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed... | apache-2.0 | -7,050,057,338,502,659,000 | 38.125 | 82 | 0.604856 | false |
xia2/xia2 | tests/Modules/Indexer/test_DIALS_indexer.py | 1 | 2572 | from unittest import mock
import os
import pytest
import sys
from dxtbx.model import ExperimentList
from xia2.Handlers.Phil import PhilIndex
from xia2.Modules.Indexer.DialsIndexer import DialsIndexer
from xia2.Schema.XCrystal import XCrystal
from xia2.Schema.XWavelength import XWavelength
from xia2.Schema.XSweep impo... | bsd-3-clause | -5,237,932,397,015,187,000 | 33.756757 | 83 | 0.702955 | false |
BanzaiTokyo/askapp | askapp/migrations/0019_auto_20191119_0846.py | 2 | 1308 | # Generated by Django 2.2.5 on 2019-11-19 08:46
from django.db import migrations, models
import django.db.models.deletion
def add_level(apps, schema_editor):
UserLevel = apps.get_model("askapp", "UserLevel")
db_alias = schema_editor.connection.alias
UserLevel.objects.using(db_alias).bulk_create([
... | apache-2.0 | 5,249,319,833,664,830,000 | 32.538462 | 129 | 0.59633 | false |
dutradda/myreco | tests/integration/engines/test_engines_integration.py | 1 | 19507 | # MIT License
# Copyright (c) 2016 Diogo Dutra <dutradda@gmail.com>
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, co... | mit | -6,780,705,163,787,334,000 | 36.01518 | 99 | 0.499103 | false |
MarkTheF4rth/youtube-dl | youtube_dl/extractor/crunchyroll.py | 29 | 16834 | # encoding: utf-8
from __future__ import unicode_literals
import re
import json
import base64
import zlib
import xml.etree.ElementTree
from hashlib import sha1
from math import pow, sqrt, floor
from .common import InfoExtractor
from ..compat import (
compat_urllib_parse,
compat_urllib_parse_unquote,
compa... | unlicense | -993,487,340,882,416,400 | 42.488372 | 237 | 0.552704 | false |
GuessWhoSamFoo/pandas | pandas/tests/indexes/multi/test_format.py | 2 | 3635 | # -*- coding: utf-8 -*-
import warnings
import pytest
from pandas.compat import PY3, range, u
import pandas as pd
from pandas import MultiIndex, compat
import pandas.util.testing as tm
def test_dtype_str(indices):
dtype = indices.dtype_str
assert isinstance(dtype, compat.string_types)
assert dtype ==... | bsd-3-clause | 7,238,619,758,494,744,000 | 26.537879 | 74 | 0.561486 | false |
aleksandar-mitrevski/fault_and_anomaly_detection | generative_model_fd/tests/multi-memory/test_td_trbm.py | 1 | 3598 | import numpy as np
from test_generic import *
def train1(y, f, model_manager, number_of_model_parameters, sequence_len):
x = np.linspace(0, sequence_len, sequence_len)
models = model_manager.optimise_td(x, y, f, sequence_len)
models, arr_min, arr_max = rescale(models)
network = TRBM(number_of_model_p... | bsd-2-clause | 257,775,259,246,922,800 | 44.556962 | 197 | 0.692885 | false |
cdriehuys/chmvh-website | chmvh_website/chmvh_website/settings.py | 1 | 6882 | """
Django settings for chmvh_website project.
Generated by 'django-admin startproject' using Django 1.10.1.
For more information on this file, see
https://docs.djangoproject.com/en/1.10/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/1.10/ref/settings/
"""
impo... | mit | 6,999,142,171,614,039,000 | 24.969811 | 94 | 0.647632 | false |
duncanmmacleod/gwpy | gwpy/table/tests/test_gravityspy.py | 3 | 2176 | # -*- coding: utf-8 -*-
# Copyright (C) Duncan Macleod (2014-2020)
#
# This file is part of GWpy.
#
# GWpy 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)... | gpl-3.0 | -1,615,811,458,453,927,200 | 35.881356 | 74 | 0.686581 | false |
galtys/galtys-addons | galtys_deploy/galtys_deploy.py | 1 | 24393 | from odoo import fields, models
#import openerp.addons.decimal_precision as dp
import bitcoin
#Steps
#golive register
#golive pull
#Main menu: Deploy
def secret_random_key(a):
return bitcoin.random_key()
#class SkynetCode(models.Model):
# pass
class deploy_account(models.Model):
_order = "name"
... | agpl-3.0 | 6,955,040,989,887,281,000 | 38.663415 | 173 | 0.608494 | false |
peterjliu/rate_limit | test_lib.py | 2 | 2134 | #!/usr/bin/env python
"""
Test rate-limiter lib
"""
import logging
import sys
import time
import unittest
from google.appengine.api import memcache
from google.appengine.ext import testbed
from lib import Limiter, QuotaKey
class Events:
USER_READ = 1
USER_WRITE = 2
RATE_LIMIT_SPEC = {
Events.USER_READ: ... | mit | 1,269,979,692,019,813,400 | 28.638889 | 78 | 0.64105 | false |
CUCWD/edx-platform | common/test/acceptance/tests/xblock/test_crowdsourcehinter_problem.py | 14 | 4260 | """
Javascript tests for the crowdsourcehinter xblock
"""
from textwrap import dedent
from common.test.acceptance.fixtures.course import CourseFixture, XBlockFixtureDesc
from common.test.acceptance.pages.common.auto_auth import AutoAuthPage
from common.test.acceptance.pages.lms.courseware import CoursewarePage
from co... | agpl-3.0 | 8,654,292,654,914,702,000 | 45.304348 | 213 | 0.652582 | false |
nijel/translate | translate/storage/tiki.py | 2 | 6958 | #
# Copyright 2008 Mozilla Corporation, Zuza Software Foundation
#
# This file is part of translate.
#
# translate 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... | gpl-2.0 | 80,276,186,011,743,940 | 34.5 | 107 | 0.587525 | false |
bohdan-shramko/learning-python | source/chapter07/read_it.py | 1 | 1172 | # Read It
# Demonstrates reading from a text file
print("Opening and closing the file.")
text_file = open("read_it.txt", "r")
text_file.close()
print("\nReading characters from the file.")
text_file = open("read_it.txt", "r")
print(text_file.read(1))
print(text_file.read(5))
text_file.close()
print("\nReading the en... | mit | 8,929,293,620,233,847,000 | 23.416667 | 50 | 0.692833 | false |
azdkj532/sligen | src/generate.py | 1 | 1078 | import os
import sys
import random
from slidegen import Generator
from slidegen import DataProvider
from wordgen import Wordgen
if len(sys.argv) < 2:
print('Usage: %s output-path' % sys.argv[0])
exit(1)
class WordgenProvider(DataProvider):
def __init__(self):
self.wg = Wordgen()
def text(self... | mit | 2,383,481,675,161,381,400 | 22.955556 | 96 | 0.600186 | false |
r-icarus/openstack_microserver | horizon/tables/actions.py | 7 | 25614 | # vim: tabstop=4 shiftwidth=4 softtabstop=4
# Copyright 2012 Nebula, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# ... | apache-2.0 | -1,195,086,635,827,140,000 | 38.045732 | 79 | 0.590654 | false |
wyojustin/clockthreesr | arduino/libraries/ClockTHREE/examples/ClockTHREE_02/scanwin32.py | 26 | 8092 | import ctypes
import re
def ValidHandle(value):
if value == 0:
raise ctypes.WinError()
return value
NULL = 0
HDEVINFO = ctypes.c_int
BOOL = ctypes.c_int
CHAR = ctypes.c_char
PCTSTR = ctypes.c_char_p
HWND = ctypes.c_uint
DWORD = ctypes.c_ulong
PDWORD = ctypes.POINTER(DWORD)
ULONG = ctypes.c_ulong
ULONG... | mit | -7,163,676,177,331,834,000 | 33.87931 | 147 | 0.605783 | false |
rwightman/tensorflow-litterbox | litterbox/models/google/nets/inception.py | 1 | 1833 | # Copyright 2016 The TensorFlow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable ... | apache-2.0 | -1,821,658,035,064,631,300 | 49.916667 | 80 | 0.768685 | false |
2PacIsAlive/deepnet.works | deep_networks/data/preprocessing/segment_lungs.py | 2 | 2713 | import logging
import numpy as np
from skimage import measure
class LungSegmenter(object):
"""Extract the lungs from a scan.
Attributes:
log (logging.Logger): The logger for this module.
"""
logging.basicConfig(level=logging.INFO)
log = logging.getLogger(__name__)
def largest_label_v... | mit | 6,750,953,811,845,551,000 | 31.297619 | 90 | 0.573535 | false |
andrebellafronte/stoq | plugins/ecf/ecfprinterdialog.py | 2 | 14094 | # -*- coding: utf-8 -*-
# vi:si:et:sw=4:sts=4:ts=4
##
## Copyright (C) 2007 Async Open Source <http://www.async.com.br>
## All rights reserved
##
## This program is free software; you can redistribute it and/or modify
## it under the terms of the GNU Lesser General Public License as published by
## the Free Software F... | gpl-2.0 | 1,691,430,609,699,142,000 | 39.148148 | 83 | 0.584729 | false |
hguemar/cinder | cinder/api/views/transfers.py | 18 | 3335 | # Copyright (C) 2012 Hewlett-Packard Development Company, L.P.
# 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/LICEN... | apache-2.0 | -4,970,848,433,441,745,000 | 36.47191 | 78 | 0.564918 | false |
ymilord/OctoPrint-MrBeam | docs/conf.py | 2 | 8692 | # -*- coding: utf-8 -*-
#
# OctoPrint documentation build configuration file, created by
# sphinx-quickstart on Mon Dec 02 17:08:50 2013.
#
# This file is execfile()d with the current directory set to its containing dir.
#
# Note that not all possible configuration values are present in this
# autogenerated file.
#
# A... | agpl-3.0 | -7,994,767,260,644,734,000 | 32.011407 | 128 | 0.708708 | false |
P4ELTE/t4p4s | src/hardware_indep/multi/actions.stage.c.py | 1 | 3080 | # SPDX-License-Identifier: Apache-2.0
# Copyright 2016 Eotvos Lorand University, Budapest, Hungary
from utils.codegen import format_expr, format_type
from compiler_common import get_hdrfld_name, generate_var_name, SugarStyle, make_const
compiler_common.current_compilation['is_multicompiled'] = True
part_count = comp... | apache-2.0 | 3,627,202,186,726,088,700 | 41.777778 | 157 | 0.602273 | false |
LiamMayfair/utils | timecalc.py | 1 | 1752 | """@@@"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
""" """
""" timecalc.py """
""" """
""" Accepts a timespan and returns the d... | mit | -8,306,291,390,187,111,000 | 45.105263 | 106 | 0.422945 | false |
bloomark/python-bitcoinlib | examples/make-bootstrap-rpc.py | 14 | 1584 | #!/usr/bin/env python3
# Copyright (C) 2013-2014 The python-bitcoinlib developers
#
# This file is part of python-bitcoinlib.
#
# It is subject to the license terms in the LICENSE file found in the top-level
# directory of this distribution.
#
# No part of python-bitcoinlib, including this file, may be copied, modifie... | lgpl-3.0 | -5,203,403,247,920,980,000 | 24.967213 | 120 | 0.674874 | 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.