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 |
|---|---|---|---|---|---|---|---|---|---|---|
vicnet/weboob | modules/bred/bred/browser.py | 1 | 9230 | # -*- coding: utf-8 -*-
# Copyright(C) 2014 Romain Bignon
#
# This file is part of a weboob module.
#
# This weboob module is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation, either version 3 of the Licens... | lgpl-3.0 | 5,252,652,381,449,629,000 | 38.784483 | 136 | 0.626869 | false |
kawamon/hue | desktop/core/ext-py/Django-1.11.29/tests/template_tests/syntax_tests/test_if_equal.py | 23 | 9893 | from django.test import SimpleTestCase
from ..utils import setup
class IfEqualTagTests(SimpleTestCase):
@setup({'ifequal01': '{% ifequal a b %}yes{% endifequal %}'})
def test_ifequal01(self):
output = self.engine.render_to_string('ifequal01', {'a': 1, 'b': 2})
self.assertEqual(output, '')
... | apache-2.0 | 2,469,291,981,971,232,300 | 44.589862 | 98 | 0.603356 | false |
zakandrewking/cobrapy | cobra/test/data/update_pickles.py | 1 | 4077 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
from __future__ import absolute_import
from collections import OrderedDict
from json import dump as json_dump
import cobra
from cobra.io import (
load_matlab_model, read_sbml_model, save_json_model, save_matlab_model,
write_sbml_model)
from cobra.io.sbml3 import ... | lgpl-2.1 | 1,391,955,940,159,979,000 | 34.452174 | 79 | 0.696591 | false |
antoyo/qutebrowser | qutebrowser/misc/split.py | 8 | 6637 | # vim: ft=python fileencoding=utf-8 sts=4 sw=4 et:
# Copyright 2014-2016 Florian Bruhin (The Compiler) <mail@qutebrowser.org>
#
# This file is part of qutebrowser.
#
# qutebrowser 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 S... | gpl-3.0 | -454,895,341,120,122,600 | 30.454976 | 78 | 0.530661 | false |
plowman/python-mcparseface | models/syntaxnet/tensorflow/tensorflow/contrib/ffmpeg/decode_audio_op_test.py | 6 | 2865 | # Copyright 2016 Google Inc. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or a... | apache-2.0 | -4,921,773,979,012,477,000 | 36.207792 | 79 | 0.658988 | false |
caxiam/sqlalchemy-jsonapi-collections | jsonapiquery/errors.py | 1 | 1697 | import functools
import json
class CollectErrors:
def __init__(self, exc_type):
self.errors = []
self.exc_type = exc_type
def __enter__(self):
return self
def __exit__(self, exc_type, exc_value, traceback):
if exc_type == self.exc_type:
self.errors.append(exc... | apache-2.0 | 1,136,566,707,540,158,800 | 25.515625 | 76 | 0.619328 | false |
domluna/deep-rl-gym-tutorials | q_learning/utils.py | 1 | 1954 | from __future__ import absolute_import
from __future__ import print_function
from __future__ import division
import tensorflow as tf
import numpy as np
import os
import warnings
from six.moves import range
from skimage.color import rgb2gray
from skimage.transform import resize
from skimage import img_as_ubyte
def pr... | mit | -1,835,463,773,438,896,000 | 31.566667 | 86 | 0.657114 | false |
DirtyUnicorns/android_external_chromium_org | tools/cr/cr/plugin.py | 103 | 9675 | # 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.
"""The plugin management system for the cr tool.
This holds the Plugin class and supporting code, that controls how plugins are
found and used.
The module r... | bsd-3-clause | -47,986,741,874,317,416 | 27.794643 | 80 | 0.662326 | false |
Tchanders/socorro | webapp-django/crashstats/api/views.py | 4 | 14434 | import json
import re
import datetime
from django import http
from django.shortcuts import render
from django.contrib.auth.models import Permission
from django.contrib.sites.models import RequestSite
from django.core.urlresolvers import reverse
from django.conf import settings
from django import forms
# explicit impor... | mpl-2.0 | -2,504,321,937,024,819,000 | 31.004435 | 79 | 0.578634 | false |
uni-peter-zheng/tp-qemu | qemu/tests/block_stream_simple.py | 5 | 1367 | import logging
from autotest.client.shared import error
from qemu.tests import blk_stream
class BlockStreamSimple(blk_stream.BlockStream):
def __init__(self, test, params, env, tag):
super(BlockStreamSimple, self).__init__(test, params, env, tag)
@error.context_aware
def query_status(self):
... | gpl-2.0 | -2,845,077,598,982,918,000 | 31.547619 | 72 | 0.65545 | false |
santisiri/popego | envs/ALPHA-POPEGO/lib/python2.5/site-packages/twisted/web2/iweb.py | 1 | 13392 | # -*- test-case-name: twisted.web2.test -*-
"""
I contain the interfaces for several web related objects including IRequest
and IResource. I am based heavily on ideas from nevow.inevow
"""
from zope.interface import Attribute, Interface, interface
# server.py interfaces
class IResource(Interface):
"""
... | bsd-3-clause | 2,801,832,953,199,898,600 | 34.335092 | 157 | 0.636499 | false |
aio-libs/aiohttp_session | examples/postgres_storage.py | 1 | 3068 | import json
import uuid
from typing import Any, Callable, Dict, Optional
import psycopg2.extras
from aiohttp import web
from aiohttp_session import AbstractStorage, Session
from aiopg import Pool
class PgStorage(AbstractStorage):
"""PG storage"""
def __init__(self, pg_pool: Pool, *, cookie_name: str = "AIOH... | apache-2.0 | -7,523,939,616,466,870,000 | 42.211268 | 126 | 0.558344 | false |
guillaume-philippon/aquilon | lib/aquilon/aqdb/model/building.py | 1 | 1260 | # -*- cpy-indent-level: 4; indent-tabs-mode: nil -*-
# ex: set expandtab softtabstop=4 shiftwidth=4:
#
# Copyright (C) 2008,2009,2010,2011,2012,2013,2014 Contributor
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a... | apache-2.0 | 6,849,712,266,774,559,000 | 33.054054 | 78 | 0.70873 | false |
anryko/ansible | lib/ansible/modules/network/nxos/nxos_lldp_global.py | 19 | 6889 | #!/usr/bin/python
# -*- coding: utf-8 -*-
# Copyright 2019 Red Hat
# GNU General Public License v3.0+
# (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
#############################################
# WARNING #
#############################################
#
# This file is au... | gpl-3.0 | 326,287,199,728,916,000 | 26.556 | 149 | 0.6072 | false |
chromium/chromium | third_party/blink/tools/blinkpy/web_tests/port/browser_test_driver_unittest.py | 7 | 2202 | # Copyright (C) 2014 Google Inc. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
# met:
#
# * Redistributions of source code must retain the above copyright
# notice, this list of conditions and the f... | bsd-3-clause | -5,011,113,789,510,793,000 | 47.933333 | 72 | 0.764759 | false |
prefetchnta/questlab | bin/x64bin/python/36/Lib/distutils/command/install_lib.py | 3 | 8614 | """distutils.command.install_lib
Implements the Distutils 'install_lib' command
(install all Python modules)."""
import os
import importlib.util
import sys
from distutils.core import Command
from distutils.errors import DistutilsOptionError
# Extension for Python source files.
PYTHON_SOURCE_EXTENSION... | lgpl-2.1 | 4,027,984,148,738,640,400 | 37.695853 | 77 | 0.550035 | false |
manipopopo/tensorflow | tensorflow/contrib/autograph/converters/decorators_test.py | 5 | 4348 | # Copyright 2017 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 | 2,167,846,485,572,631,000 | 29.194444 | 80 | 0.683303 | false |
babyliynfg/cross | tools/project-creator/Python2.6.6/Lib/webbrowser.py | 4 | 21759 | #! /usr/bin/env python
"""Interfaces for launching and remotely controlling Web browsers."""
# Maintained by Georg Brandl.
import os
import shlex
import sys
import stat
import subprocess
import time
__all__ = ["Error", "open", "open_new", "open_new_tab", "get", "register"]
class Error(Exception):
p... | mit | -3,437,311,423,236,437,000 | 30.819005 | 98 | 0.548601 | false |
cloudera/hue | apps/sqoop/src/sqoop/api/link.py | 2 | 5885 | #!/usr/bin/env python
# Licensed to Cloudera, Inc. under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. Cloudera, Inc. licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you ma... | apache-2.0 | -6,707,982,355,164,739,000 | 32.628571 | 145 | 0.704333 | false |
gioman/QGIS | python/plugins/processing/gui/HistoryDialog.py | 1 | 5564 | # -*- coding: utf-8 -*-
"""
***************************************************************************
HistoryDialog.py
---------------------
Date : August 2012
Copyright : (C) 2012 by Victor Olaya
Email : volayaf at gmail dot com
*************************... | gpl-2.0 | 2,202,754,153,261,598,700 | 37.109589 | 128 | 0.563623 | false |
psci2195/espresso-ffans | testsuite/python/interactions_non-bonded.py | 1 | 27466 | #
# Copyright (C) 2013-2019 The ESPResSo project
#
# This file is part of ESPResSo.
#
# ESPResSo 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... | gpl-3.0 | -3,481,423,916,790,049,000 | 36.368707 | 81 | 0.552501 | false |
syphar/django | tests/modeladmin/tests.py | 7 | 62231 | from __future__ import unicode_literals
from datetime import date
from django import forms
from django.contrib.admin import BooleanFieldListFilter, SimpleListFilter
from django.contrib.admin.models import LogEntry
from django.contrib.admin.options import (
HORIZONTAL, VERTICAL, ModelAdmin, TabularInline,
)
from d... | bsd-3-clause | 4,748,427,532,780,828,000 | 34.039977 | 116 | 0.608555 | false |
jaredkoontz/leetcode | Python/optimal-account-balancing.py | 3 | 1111 | # Time: O(n * 2^n), n is the size of the debt.
# Space: O(n * 2^n)
class Solution(object):
def minTransfers(self, transactions):
"""
:type transactions: List[List[int]]
:rtype: int
"""
account = collections.defaultdict(int)
for transaction in transactions:
... | mit | 3,390,924,850,970,744,000 | 29.027027 | 61 | 0.422142 | false |
tiagocoutinho/bliss | bliss/controllers/mca/simulation.py | 1 | 4984 | """Provide an MCA simulator."""
import time
import numpy
import gevent
from .base import BaseMCA, PresetMode, TriggerMode, Stats
class SimulatedMCA(BaseMCA):
_init_time = 1.
_prepare_time = 0.1
_cleanup_time = 0.1
_gate_end = 0.5
_mapping_modulo = 2
# Initialization
def initialize_at... | lgpl-3.0 | 3,883,550,063,179,060,700 | 27.318182 | 76 | 0.58427 | false |
frouty/odoo_oph | addons/lunch/report/report_lunch_order.py | 52 | 2799 | # -*- coding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU... | agpl-3.0 | 2,054,504,855,772,869,400 | 42.061538 | 102 | 0.549482 | false |
prontotools/zendesk-tickets-machine | zendesk_tickets_machine/tickets/tests/test_services.py | 1 | 5515 | import datetime
from django.test import TestCase
from django.utils.timezone import utc
from ..models import Ticket
from ..services import TicketServices
from agents.models import Agent
from agent_groups.models import AgentGroup
from boards.models import Board
from requesters.models import Requester
class TicketServ... | mit | 3,247,515,967,635,474,000 | 32.628049 | 73 | 0.554306 | false |
evancich/apm_motor | modules/PX4Firmware/integrationtests/demo_tests/flight_path_assertion.py | 15 | 7439 | #!/usr/bin/env python
#***************************************************************************
#
# Copyright (c) 2015 PX4 Development Team. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
# are met:
#
... | gpl-3.0 | 196,801,837,651,360,700 | 36.761421 | 136 | 0.546848 | false |
clusto/clusto | src/clusto/commands/console.py | 3 | 2031 | #!/usr/bin/env python
# -*- mode: python; sh-basic-offset: 4; indent-tabs-mode: nil; coding: utf-8 -*-
# vim: tabstop=4 softtabstop=4 expandtab shiftwidth=4 fileencoding=utf-8
#
# Shell command
# Copyright 2010, Jeremy Grosser <synack@digg.com>
import os
import sys
import clusto
from clusto import script_helper
cla... | bsd-3-clause | 399,416,895,033,877,760 | 30.246154 | 80 | 0.593796 | false |
alexander-yu/nycodex | nycodex/scrape/dataset.py | 1 | 5707 | import os
import tempfile
import typing
import geoalchemy2
import geopandas as gpd
import pandas as pd
import sqlalchemy as sa
from nycodex import db
from nycodex.logging import get_logger
from . import exceptions, utils
BASE = "https://data.cityofnewyork.us/api"
RAW_SCHEMA = 'raw'
logger = get_logger(__name__)
d... | apache-2.0 | -2,777,829,309,018,861,600 | 33.587879 | 78 | 0.566497 | false |
drwyrm/Flexget | flexget/tests/test_validator.py | 9 | 4255 | """
These validate methods are never run by FlexGet anymore, but these tests serve as a sanity check that the
old validators will get converted to new schemas properly for plugins still using the `validator` method.
"""
from __future__ import unicode_literals, division, absolute_import
from builtins import * # noqa py... | mit | -6,372,121,253,035,960,000 | 38.036697 | 109 | 0.627732 | false |
oliverlee/sympy | sympy/sets/tests/test_sets.py | 7 | 36780 | from sympy import (Symbol, Set, Union, Interval, oo, S, sympify, nan,
GreaterThan, LessThan, Max, Min, And, Or, Eq, Ge, Le, Gt, Lt, Float,
FiniteSet, Intersection, imageset, I, true, false, ProductSet, E,
sqrt, Complement, EmptySet, sin, cos, Lambda, ImageSet, pi,
Eq, Pow, Contains, Sum, rootof, Symmetr... | bsd-3-clause | 6,755,135,656,937,935,000 | 36.378049 | 107 | 0.604051 | false |
skosukhin/spack | lib/spack/spack/version.py | 1 | 26634 | ##############################################################################
# Copyright (c) 2013-2017, Lawrence Livermore National Security, LLC.
# Produced at the Lawrence Livermore National Laboratory.
#
# This file is part of Spack.
# Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved.
# LLNL-CODE-64... | lgpl-2.1 | -6,174,181,543,707,250,000 | 29.40411 | 78 | 0.551551 | false |
acsone/website | website_blog_facebook_comment/models/website.py | 27 | 1338 | # -*- coding: utf-8 -*-
# Python source code encoding : https://www.python.org/dev/peps/pep-0263/
##############################################################################
#
# This module copyright :
# (c) 2015 Antiun Ingenieria, SL (Madrid, Spain, http://www.antiun.com)
# Endika Iglesias... | agpl-3.0 | -6,454,213,489,108,411,000 | 42.16129 | 78 | 0.622571 | false |
filipp/py-gsxws | tests/test_gsxws.py | 1 | 21335 | # -*- coding: utf-8 -*-
import os
import sys
import logging
from datetime import date, datetime
from unittest import TestCase, main, skip
sys.path.append(os.path.abspath('..'))
from gsxws.core import validate, GsxCache, connect
from gsxws.objectify import parse, gsx_diags_timestamp
from gsxws.products import Produc... | bsd-2-clause | -4,900,335,449,283,007,000 | 33.393548 | 112 | 0.646173 | false |
freakboy3742/django-push-notifications | push_notifications/fields.py | 12 | 2892 | import re
import struct
from django import forms
from django.core.validators import RegexValidator
from django.db import models, connection
from django.utils import six
from django.utils.translation import ugettext_lazy as _
__all__ = ["HexadecimalField", "HexIntegerField"]
hex_re = re.compile(r"^(([0-9A-f])|(0x[0-... | mit | 553,495,842,151,306,100 | 33.023529 | 102 | 0.728216 | false |
Portugol-Studio-TTC/Portugol-GoGoBoard-Plugin | Portugol-GoGoBoard-Plugin/src/main/resources/br/univali/portugol/plugin/gogoboard/compilador/logoc.py | 1 | 56708 | #
# Tinker Logo Compiler - A lexical analyzer and parser for a
# Logo language for Robotics
#
# Copyright (C) 2014 Chiang Mai University
# Contact Arnan (Roger) Sipiatkiat [arnans@gmail.com]
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Publi... | gpl-3.0 | -4,086,673,645,929,676,000 | 30.628308 | 133 | 0.446269 | false |
MSeal/py_cache_manager | cacheman/registers.py | 2 | 8195 | import pickle
from six.moves import cPickle
from six import iteritems
import shutil
import os
import sys
import psutil
import csv
import traceback
from .utils import random_name
if sys.version_info[0] == 2:
text_read_mode = 'rU'
text_write_mode = 'wb'
else:
text_read_mode = 'r'
text_w... | bsd-2-clause | -3,871,558,480,038,379,500 | 35.081448 | 109 | 0.594997 | false |
VojtechBartos/smsgw | smsgw/resources/contacts/schemas/put.py | 1 | 1911 | # -*- coding: utf-8 -*-
# http://google-styleguide.googlecode.com/svn/trunk/pyguide.html
from smsgw.resources import patterns
schema = {
"description": "Schema for the contacts PUT endpoint",
"type": "object",
"method": "PUT",
"required": [ "firstName", "lastName", "phoneNumber" ],
"additionalProp... | mit | 2,341,249,699,059,499,000 | 29.822581 | 92 | 0.440607 | false |
berkmancenter/mediacloud | apps/common/src/python/mediawords/util/process.py | 1 | 2628 | import os
import psutil
from mediawords.util.log import create_logger
from mediawords.util.perl import decode_object_from_bytes_if_needed
log = create_logger(__name__)
def _kill_children(pid: int) -> None:
"""Kill all children of PID except for ourselves."""
proc = psutil.Process(pid)
command = proc.c... | agpl-3.0 | -7,614,883,986,507,458,000 | 35.5 | 116 | 0.679224 | false |
redouane/Dzik | dzik.py | 1 | 2117 | # -*- coding: latin-1 -*-
### App By : Redouane ###
### E-MAIL : unrealdz@gmail.com ###
### BLOG : redouanezait.com ###
### LICENSE : GNU GPL v3 ###
from main import gui
from PyQt4.QtGui import QApplication, QMessageBox
from PyQt4.QtCore import QThread, SIGNAL
import urllib
import... | gpl-3.0 | -750,749,802,087,596,700 | 35.344828 | 264 | 0.538206 | false |
pypa/virtualenv | docs/conf.py | 2 | 2481 | import subprocess
import sys
from datetime import date, datetime
from pathlib import Path
import sphinx_rtd_theme
from virtualenv.version import __version__
company = "PyPA"
name = "virtualenv"
version = ".".join(__version__.split(".")[:2])
release = __version__
copyright = f"2007-{date.today().year}, {company}, PyP... | mit | 3,847,665,274,110,247,000 | 26.876404 | 93 | 0.655784 | false |
fgmacedo/django-awards | docs/conf.py | 1 | 8151 | # -*- coding: utf-8 -*-
#
# complexity documentation build configuration file, created by
# sphinx-quickstart on Tue Jul 9 22:26:36 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.
#
# ... | mit | 2,122,734,400,599,213,000 | 31.090551 | 80 | 0.706784 | false |
yannrouillard/weboob | weboob/applications/radioob/radioob.py | 1 | 10151 | # -*- coding: utf-8 -*-
# Copyright(C) 2010-2012 Romain Bignon
#
# This file is part of weboob.
#
# weboob 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... | agpl-3.0 | -5,309,808,482,953,308,000 | 32.50165 | 120 | 0.547237 | false |
papaeye/pep8 | docs/conf.py | 9 | 7991 | # -*- coding: utf-8 -*-
#
# pep8 documentation build configuration file, created by
# sphinx-quickstart on Tue Aug 21 09:47:49 2012.
#
# 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 ... | mit | 1,003,528,522,612,535,800 | 30.964 | 79 | 0.698035 | false |
nicecapj/crossplatfromMmorpgServer | ThirdParty/protobuf/python/setup.py | 2 | 10221 | #! /usr/bin/env python
#
# See README for usage instructions.
import glob
import os
import subprocess
import sys
# We must use setuptools, not distutils, because we need to use the
# namespace_packages option for the "google" package.
from setuptools import setup, Extension, find_packages
from distutils.command.clean... | mit | 2,703,297,802,181,223,000 | 39.399209 | 84 | 0.669993 | false |
rhelmer/socorro-collector | tests/test_throttler.py | 12 | 6818 | # This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
import re
import mock
from socorro.lib.util import DotDict
from socorro.collector.throttler import (
LegacyThrottler,... | mpl-2.0 | -5,109,374,843,130,263,000 | 34.14433 | 79 | 0.505133 | false |
DarthMaulware/EquationGroupLeaks | Leak #5 - Lost In Translation/windows/exploits/ZIBE/pyreadline/lineeditor/wordmatcher.py | 1 | 3330 | # -*- coding: utf-8 -*-
#*****************************************************************************
# Copyright (C) 2006 Jorgen Stenarson. <jorgen.stenarson@bostream.nu>
#
# Distributed under the terms of the BSD License. The full license is in
# the file COPYING, distributed as part of this software.
#***... | unlicense | 3,479,548,934,251,788,000 | 31.647059 | 100 | 0.554955 | false |
yugang/crosswalk-test-suite | webapi/tct-messaging-email-tizen-tests/inst.wgt.py | 2 | 7218 | #!/usr/bin/env python
import os
import shutil
import glob
import time
import sys
import subprocess
import string
from optparse import OptionParser, make_option
SCRIPT_DIR = os.path.dirname(os.path.abspath(__file__))
PKG_NAME = os.path.basename(SCRIPT_DIR)
PARAMETERS = None
#XW_ENV = "export DBUS_SESSION_BUS_ADDRESS=... | bsd-3-clause | -3,413,121,798,800,158,700 | 29.455696 | 106 | 0.548074 | false |
grlee77/numpy | numpy/core/tests/test_indexerrors.py | 17 | 5130 | import numpy as np
from numpy.testing import (
assert_raises, assert_raises_regex,
)
class TestIndexErrors:
'''Tests to exercise indexerrors not covered by other tests.'''
def test_arraytypes_fasttake(self):
'take from a 0-length dimension'
x = np.empty((2, 3, 0, 4))
a... | bsd-3-clause | 5,362,057,874,939,715,000 | 37.571429 | 76 | 0.566667 | false |
gismo141/pyew | plugins/pdf.py | 16 | 13682 | #!/usr/bin/env python
"""
This file is part of Pyew
Copyright (C) 2009, 2010 Joxean Koret
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 2 of the License, or
(at your option) any la... | gpl-2.0 | 2,374,352,709,856,762,400 | 30.671296 | 132 | 0.484944 | false |
ric2b/Vivaldi-browser | chromium/third_party/blink/renderer/build/scripts/name_utilities.py | 2 | 2769 | # Copyright (C) 2013 Google Inc. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
# met:
#
# * Redistributions of source code must retain the above copyright
# notice, this list of conditions and the ... | bsd-3-clause | 1,987,616,045,949,472,300 | 38.557143 | 102 | 0.757313 | false |
chitianhao/trafficserver | tests/gold_tests/runroot/runroot_use.test.py | 3 | 2925 | '''
'''
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License");... | apache-2.0 | -5,781,999,822,426,159,000 | 42.656716 | 117 | 0.742222 | false |
NoBodyCam/TftpPxeBootBareMetal | tools/hacking.py | 1 | 16186 | #!/usr/bin/env python
# vim: tabstop=4 shiftwidth=4 softtabstop=4
# Copyright (c) 2012, Cloudscaling
# All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# ... | apache-2.0 | 5,683,344,426,554,000,000 | 32.861925 | 79 | 0.575188 | false |
yongshengwang/hue | desktop/core/ext-py/MarkupSafe-0.9.3/setup.py | 38 | 3105 | import os
import sys
from setuptools import setup, Extension, Feature
from distutils.command.build_ext import build_ext
from distutils.errors import CCompilerError, DistutilsExecError, \
DistutilsPlatformError
# fail safe compilation shamelessly stolen from the simplejson
# setup.py file. Original author: Bob Ip... | apache-2.0 | -3,455,539,869,542,415,000 | 26.723214 | 99 | 0.622866 | false |
hesam-setareh/nest-simulator | topology/pynest/tests/test_dumping.py | 9 | 3718 | # -*- coding: utf-8 -*-
#
# test_dumping.py
#
# This file is part of NEST.
#
# Copyright (C) 2004 The NEST Initiative
#
# NEST 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, o... | gpl-2.0 | 2,658,483,919,810,561,000 | 31.614035 | 76 | 0.575847 | false |
sethkontny/blaze | blaze/io/sql/ops.py | 4 | 3542 | """SQL implementations of element-wise ufuncs."""
from __future__ import absolute_import, division, print_function
from ...compute.function import BlazeFunc
from ...compute.ops import ufuncs
from .kernel import SQL
from .syntax import Call, Expr, QOrderBy, QWhere, And, Or, Not
def sqlfunction(signature):
def de... | bsd-3-clause | -5,534,572,950,848,651,000 | 26.457364 | 76 | 0.592038 | false |
trnewman/VT-USRP-daughterboard-drivers_python | gnuradio-core/src/python/gnuradio/blksimpl/wfm_tx.py | 1 | 3136 | #
# Copyright 2005 Free Software Foundation, Inc.
#
# This file is part of GNU Radio
#
# GNU Radio is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3, or (at your option)
# any later version.
#... | gpl-3.0 | 8,647,302,850,588,590,000 | 38.696203 | 85 | 0.596301 | false |
akshar-raaj/importd | importd/__init__.py | 1 | 24831 | # -*- coding: utf-8 -*-
"""ImportD django mini framework."""
__version__ = "0.3.3"
__license__ = "BSD"
__author__ = "Amit Upadhyay"
__email__ = "upadhyay@gmail.com"
__url__ = "http://amitu.com/importd"
__source__ = "https://github.com/amitu/importd"
__docformat__ = "html"
# stdlib imports
import copy
import inspe... | bsd-3-clause | -6,445,214,912,893,763,000 | 35.786667 | 99 | 0.551488 | false |
scottwernervt/cloudstorage | tests/test_drivers_amazon.py | 1 | 8614 | from http import HTTPStatus
import pytest
import requests
from pathlib import Path
from cloudstorage.drivers.amazon import S3Driver
from cloudstorage.exceptions import (
CloudStorageError,
CredentialsError,
IsNotEmptyError,
NotFoundError,
)
from cloudstorage.helpers import file_checksum
from tests imp... | mit | 7,527,081,261,133,218,000 | 32.130769 | 87 | 0.72626 | false |
yteraoka/googleapps-directory-tools | calendar-acl.py | 1 | 8051 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import os
import sys
import pprint
from apiclient.discovery import build
import httplib2
from oauth2client.client import flow_from_clientsecrets
from oauth2client.file import Storage
from oauth2client import tools
import argparse
import simplejson as json
from const impor... | apache-2.0 | -3,583,292,375,005,266,000 | 39.457286 | 117 | 0.532729 | false |
qitta/libhugin | hugin/analyze/stopwords/__init__.py | 2 | 1717 | #!/usr/bin/env python
# encoding: utf-8
"""
Overview
~~~~~~~~
Interface for loading stopwords from a set of 12 languages that
are packaged along libmunin.
The stopwords can be used to split text into important and unimportant words.
Additionally text language can be guessed through the ``guess_language`` module.
Re... | gpl-3.0 | -7,410,330,641,471,257,000 | 23.884058 | 80 | 0.669773 | false |
cedricbonhomme/Stegano | bin/lsb.py | 1 | 4377 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
# Stegano - Stegano is a pure Python steganography module.
# Copyright (C) 2010-2021 Cédric Bonhomme - https://www.cedricbonhomme.org
#
# For more information : https://github.com/cedricbonhomme/Stegano
#
# This program is free software: you can redistribute it and/or modi... | gpl-3.0 | 5,437,824,163,409,713,000 | 40.283019 | 83 | 0.626828 | false |
ClaudioGranatiero/ClyphX_CG | ClyphX/ClyphXControlSurfaceActions.py | 1 | 16560 | """
# Copyright (C) 2013-2015 Stray <stray411@hotmail.com>
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public
# License as published by the Free Software Foundation; either
# version 2.1 of the License, or (at your option) any later version.
#
... | gpl-2.0 | 5,056,214,246,186,629,000 | 37.071264 | 147 | 0.653502 | false |
nagaozen/my-os-customizations | home/nagaozen/gedit-2.30.4/plugins/externaltools/tools/filelookup.py | 2 | 4761 | # -*- coding: utf-8 -*-
#
# Copyright (C) 2009-2010 Per Arneng <per.arneng@anyplanet.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# ... | gpl-3.0 | 157,991,573,610,847,140 | 31.834483 | 80 | 0.634741 | false |
GenericStudent/home-assistant | tests/util/test_yaml.py | 5 | 16219 | """Test Home Assistant yaml loader."""
import io
import logging
import os
import unittest
import pytest
from homeassistant.config import YAML_CONFIG_FILE, load_yaml_config_file
from homeassistant.exceptions import HomeAssistantError
import homeassistant.util.yaml as yaml
from homeassistant.util.yaml import loader as ... | apache-2.0 | -6,587,619,202,486,819,000 | 34.00432 | 88 | 0.573333 | false |
thorgate/tg-utils | tg_utils/managers.py | 1 | 2021 | from django.db import models
from django.utils import timezone
from tg_utils.signals import post_modify
class ClosableObjectsQuerySet(models.QuerySet):
""" Provides easy way to mark ClosableModel objects as closed
"""
def close(self, user):
return self.update(closed_at=timezone.now(), closed_by=u... | isc | -7,063,999,307,600,676,000 | 32.131148 | 120 | 0.680851 | false |
ThirstyGoat/mvvmFX | addServer.py | 3 | 1809 | #!/usr/bin/env python
# This script file is used for travis-ci snapshot deployment.
# This script creates a maven settings file 'mySettings.xml'.
# If there is an existing settings.xml, it is used as base for the new settings file.
# After that it adds the server configuration for the sonatype maven repository
# The ... | apache-2.0 | -8,408,112,794,754,028,000 | 30.736842 | 110 | 0.789939 | false |
apple/swift-lldb | packages/Python/lldbsuite/test/arm/breakpoint-thumb-codesection/TestBreakpointThumbCodesection.py | 5 | 1098 | """
Test that breakpoints correctly work in an thumb function in an arbitrary
named codesection.
"""
from __future__ import print_function
import lldb
from lldbsuite.test.decorators import *
from lldbsuite.test.lldbtest import *
from lldbsuite.test import lldbutil
class TestBreakpointThumbCodesection(TestBase):
... | apache-2.0 | -5,055,532,931,843,639,000 | 31.294118 | 97 | 0.689435 | false |
Jumpers/MysoftAutoTest | Step1-PythonBasic/Practices/wangr/6-9/ex8.py | 1 | 1341 | # -*- coding: utf-8 -*-
#
# formatter = "%r %r %r %r"
#
# print formatter % (1,2,3,4)
# print formatter % ("one","two","three","four")
# print formatter % (True,False,False,True)
# print formatter % ("True",'False','''False''',True)
# # true 和 false 加不加引号都是输出原样,有什么区别呢?
# print formatter % (formatter,formatt... | apache-2.0 | 5,468,197,875,144,148,000 | 32.151515 | 64 | 0.562667 | false |
pudo/nomenklatura | nomenklatura/views/matching.py | 2 | 1119 | from random import randint
from flask import Blueprint, request
from apikit import jsonify, Pager, arg_int
from nomenklatura.model.matching import find_matches
from nomenklatura.model import Dataset, Entity
section = Blueprint('matching', __name__)
@section.route('/match', methods=['GET'])
def match():
datase... | mit | 2,324,831,375,649,056,300 | 30.971429 | 64 | 0.655049 | false |
CIECODE-Madrid/tipi-engine | extractors/spain/deputy_extractors/deputy_extractor.py | 1 | 5354 | import re
from lxml.html import document_fromstring
from tipi_data.models.deputy import Deputy
from tipi_data.utils import generate_id
from urllib.parse import urlparse, parse_qs
class DeputyExtractor():
BASE_URL = 'https://www.congreso.es'
def __init__(self, response):
self.response = response
... | gpl-3.0 | 374,042,878,691,597,630 | 39.233083 | 190 | 0.587367 | false |
rec/echomesh | code/python/external/platform/darwin/numpy/f2py/tests/test_kind.py | 34 | 1076 | import os
import math
from numpy.testing import *
from numpy import array
import util
def _path(*a):
return os.path.join(*((os.path.dirname(__file__),) + a))
from numpy.f2py.crackfortran import _selected_int_kind_func as selected_int_kind
from numpy.f2py.crackfortran import _selected_real_kind_func as selected_... | mit | -3,999,098,604,160,743,400 | 30.647059 | 118 | 0.628253 | false |
autosportlabs/RaceCapture_App | autosportlabs/racecapture/views/setup/selectpresetview.py | 1 | 4451 | #
# Race Capture App
#
# Copyright (C) 2014-2017 Autosport Labs
#
# This file is part of the Race Capture App
#
# This 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 ... | gpl-3.0 | 2,016,710,277,483,842,300 | 32.977099 | 93 | 0.607279 | false |
pvpnvz/internshipsystem | app/auth/views.py | 1 | 1273 | from flask import render_template, redirect, url_for, request, flash
from . import auth
from .form import LoginForm
from ..models import Teacher, Student,Permission
from flask.ext.login import login_required, login_user, logout_user,session,current_user
from .LoginAction import LoginAction
import os
logout_url = 'http... | mit | 33,430,227,792,179,736 | 29.170732 | 88 | 0.678254 | false |
PatrickgHayes/nnClassify | src/Predictor_.py | 1 | 9708 | import cv2
import numpy as np
from src.MyUtils_ import MyUtils
from src.ImageCropper_ import ImageCropper
from src.Evaluator_ import Evaluator
from src.Pickler_ import Pickler
from src import Constants
from src.Transfer_Calculator_ import Transfer_Calculator as tc
import pickle
import os
# This class contains the logi... | mit | 7,380,742,079,694,068,000 | 41.025974 | 78 | 0.522559 | false |
arrabito/DIRAC | Resources/Storage/GFAL2_StorageBase.py | 1 | 67689 | """ :mod: GFAL2_StorageBase
=================
.. module: python
:synopsis: GFAL2 class from StorageElement using gfal2. Other modules can inherit from this use the gfal2 methods.
"""
# pylint: disable=arguments-differ
# # imports
import os
import datetime
import errno
from stat import S_ISREG, S_ISDIR,... | gpl-3.0 | 5,363,154,736,559,909,000 | 34.199688 | 137 | 0.615861 | false |
kennethreitz-archive/macspoof | macspoof/interfaces.py | 1 | 1440 | import netifaces
import os
BLACK_ID = ('lo0', 'gif0')
BLACK_MAC = ('', '::1')
class Interface(object):
"""Network Interface Object"""
def __init__(self, id):
super(Interface, self).__init__()
self.id = id
_meta = netifaces.ifaddresses(self.id)
self.mac = _meta[18][0]['addr']
try:
self.broadcase... | mit | -7,330,067,767,098,584,000 | 19.28169 | 80 | 0.609028 | false |
bbulkow/MagnusFlora | flask/led_task.py | 1 | 2997 | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
#
# led_task.py
#
# This module provides a Clery task interface to set specified led states
# via the Fadecandy server
#
# the functions in this module should interact directly with Fadecandy
#
# the Celery tasks defined in this module should be intended to be r... | mit | 6,758,847,182,765,939,000 | 33.848837 | 98 | 0.650984 | false |
SUSE/azure-sdk-for-python | azure-mgmt-recoveryservicesbackup/azure/mgmt/recoveryservicesbackup/operations/protection_policy_operation_results_operations.py | 2 | 4784 | # 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 ... | mit | 3,101,230,408,185,767,400 | 43.71028 | 197 | 0.6551 | false |
chjp2046/proxygen | proxygen/lib/utils/gen_trace_event_constants.py | 22 | 6840 | #!/bin/env python
# @lint-avoid-python-3-compatibility-imports
import os
import re
import sys
import optparse
def main(argv):
# args parser
parser = optparse.OptionParser()
parser.add_option("--install_dir", dest="install_dir", type="string",
default=None, help="Absolute path to gene... | bsd-3-clause | -1,223,221,361,531,553,800 | 38.085714 | 80 | 0.54883 | false |
hansmeets/bio2rdf-scripts | linkedSPLs/LinkedSPLs-update/load-dailymed-spls/dailymed_rss.py | 1 | 4530 | '''
Created 03/15/2012
@auther: gag30
@summary: Download and extract all of the xml files for drugs updated on Dailymed within the past 7 days.
Extracted xml files are saved to ./spls and ./spls/updates, both of which are created if they
don't exist.
'''
import feedparser
from lxml.html import ... | mit | 1,745,702,138,065,895,700 | 30.027397 | 105 | 0.608609 | false |
nicholasserra/sentry | src/sentry/api/endpoints/group_events_latest.py | 3 | 1307 | from __future__ import absolute_import
from rest_framework.response import Response
from sentry.api import client
from sentry.api.base import DocSection
from sentry.api.bases.group import GroupEndpoint
from sentry.models import Group
from sentry.utils.apidocs import scenario, attach_scenarios
@scenario('GetLatestGr... | bsd-3-clause | 7,867,201,354,274,145,000 | 30.119048 | 81 | 0.672533 | false |
lptorres/noah-inasafe | web_api/safe/messaging/item/emphasized_text.py | 1 | 1990 | """
InaSAFE Disaster risk assessment tool developed by AusAid - **Paragraph.**
Contact : ole.moller.nielsen@gmail.com
.. note:: This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; eithe... | gpl-3.0 | 5,129,373,317,291,118,000 | 24.533333 | 78 | 0.573367 | false |
signalnine/zxcvbn | data-scripts/build_frequency_lists.py | 5 | 7267 |
import os
import time
import codecs
import urllib
import urllib2
from pprint import pprint
SLEEP_TIME = 20 # seconds
def get_ranked_english():
'''
wikitionary has a list of ~40k English words, ranked by frequency of occurance in TV
and movie transcripts. more details at:
http://en.wiktionary.org/wik... | mit | -3,165,214,987,900,263,000 | 35.517588 | 98 | 0.592404 | false |
mapattacker/cheatsheets | python/nltk.py | 1 | 10103 | import nltk
# BASICS
#---------------------------------------
# types of features in text classification
# 1) Words
# stopwords
# normalisation (lowercase or not)
# stemming/lemmatising or not
# Caps or not
# POS in a sentence
# Grammatical structure
# Grouping of words of same meaning (se... | mit | -8,646,577,840,105,274,000 | 33.831034 | 158 | 0.670033 | false |
githubutilities/LeetCode | Python/kth-smallest-element-in-a-bst.py | 3 | 1033 | # Time: O(max(h, k))
# Space: O(h)
# Given a binary search tree, write a function kthSmallest to find the kth smallest element in it.
#
# Note:
# You may assume k is always valid, 1 ≤ k ≤ BST's total elements.
#
# Follow up:
# What if the BST is modified (insert/delete operations) often and
# you need to find the kt... | mit | 8,156,352,121,990,785,000 | 25.384615 | 98 | 0.539359 | false |
zennobjects/kivy | kivy/core/audio/audio_pygame.py | 4 | 3145 | '''
AudioPygame: implementation of Sound with Pygame
'''
__all__ = ('SoundPygame', )
from kivy.clock import Clock
from kivy.utils import platform
from kivy.core.audio import Sound, SoundLoader
_platform = platform
try:
if _platform == 'android':
try:
import android.mixer as mixer
exce... | mit | 7,294,687,923,665,151,000 | 26.587719 | 70 | 0.575517 | false |
Bytewerk/Fernwartung | Fernwartung.py | 1 | 1401 | #!/usr/bin/env python3
# Requirements:
# - zenity
# - lxqt-sudo, gksudo or similar (see config)
# - sshd and possibly port forwarding must be already configured
#
# CONFIG
#
config_graphical_sudo_bin = "lxqt-sudo"
config_zenity_bin = "zenity"
config_sshd_start = ["systemctl", "start", "sshd"]
config_sshd_stop = ["sy... | unlicense | 334,722,960,870,031,900 | 19.304348 | 65 | 0.685225 | false |
rgayon/plaso | tests/parsers/sqlite_plugins/chrome_history.py | 1 | 12609 | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""Tests for the Google Chrome History database plugin."""
from __future__ import unicode_literals
import unittest
from plaso.formatters import chrome as _ # pylint: disable=unused-import
from plaso.lib import definitions
from plaso.parsers.sqlite_plugins import chrome... | apache-2.0 | -2,171,431,143,122,919,200 | 37.093656 | 77 | 0.685701 | false |
osgcc/ryzom | nel/tools/build_gamedata/processes/anim/1_export.py | 3 | 4632 | #!/usr/bin/python
#
# #################################################################
# ## WARNING : this is a generated file, don't change it !
# #################################################################
#
# \file 1_export.py
# \brief Export anim
# \date 2011-09-21-20-51-GMT
# \author Jan Boon (Kaetemi)
# ... | agpl-3.0 | 7,485,434,476,453,457,000 | 32.323741 | 138 | 0.657168 | false |
shsingh/ansible | lib/ansible/modules/cloud/azure/azure_rm_storageaccount_info.py | 10 | 22917 | #!/usr/bin/python
#
# Copyright (c) 2016 Matt Davis, <mdavis@ansible.com>
# Chris Houseknecht, <house@redhat.com>
# 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
ANSI... | gpl-3.0 | 5,622,439,457,724,269,000 | 40.143627 | 152 | 0.535585 | false |
mjoblin/netdumplings | netdumplings/dumplingchefs/dnslookupchef.py | 1 | 2558 | import time
from netdumplings import DumplingChef
class DNSLookupChef(DumplingChef):
"""
Makes dumplings which describe DNS activity. Sends per-packet dumplings
for individual DNS (Domain Name System) lookups; and poke-interval
dumplings which describe the hosts lookups seen so far with per-host loo... | mit | -6,226,850,122,016,848,000 | 25.102041 | 79 | 0.497263 | false |
voxpupuli/puppetboard | puppetboard/default_settings.py | 4 | 1712 | import os
PUPPETDB_HOST = 'localhost'
PUPPETDB_PORT = 8080
PUPPETDB_PROTO = None
PUPPETDB_SSL_VERIFY = True
PUPPETDB_KEY = None
PUPPETDB_CERT = None
PUPPETDB_TIMEOUT = 20
DEFAULT_ENVIRONMENT = 'production'
SECRET_KEY = os.urandom(24)
DEV_LISTEN_HOST = '127.0.0.1'
DEV_LISTEN_PORT = 5000
DEV_COFFEE_LOCATION = 'coffee'
U... | apache-2.0 | -6,717,358,751,225,282,000 | 30.127273 | 73 | 0.584696 | false |
hsavolai/vmlab | src/kiwi/accessor.py | 3 | 18200 | #
# Kiwi: a Framework and Enhanced Widgets for Python
#
# Copyright (C) 2002-2005 Async Open Source
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public
# License as published by the Free Software Foundation; either
# version 2.1 of the License, ... | gpl-3.0 | 1,366,487,333,307,515,400 | 36.371663 | 78 | 0.554451 | false |
whip112/Whip112 | vendor/packages/translate/misc/optrecurse.py | 24 | 32471 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# Copyright 2002-2006 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... | mpl-2.0 | -1,564,789,509,277,742,800 | 43.664374 | 118 | 0.585753 | false |
emijrp/pywikibot-core | scripts/login.py | 2 | 4478 | #!/usr/bin/python
# -*- coding: utf-8 -*-
"""
Script to log the bot in to a wiki account.
Suggestion is to make a special account to use for bot use only. Make
sure this bot account is well known on your home wiki before using.
Parameters:
-family:FF
-lang:LL Log in to the LL language of the FF family.
... | mit | -651,188,939,974,501,400 | 33.713178 | 103 | 0.577267 | false |
DPaaS-Raksha/horizon | openstack_dashboard/dashboards/admin/users/views.py | 7 | 4104 | # 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 | -3,582,051,108,274,903,000 | 35.642857 | 78 | 0.61501 | false |
huguesv/PTVS | Python/Product/Miniconda/Miniconda3-x64/Lib/turtledemo/fractalcurves.py | 14 | 3473 | #!/usr/bin/env python3
""" turtle-example-suite:
tdemo_fractalCurves.py
This program draws two fractal-curve-designs:
(1) A hilbert curve (in a box)
(2) A combination of Koch-curves.
The CurvesTurtle class and the fractal-curve-
methods are taken from the PythonCard example
scripts for turtle-graphics.
... | apache-2.0 | 1,199,790,521,574,341,000 | 24.166667 | 83 | 0.553124 | false |
codificat/sos | sos/plugins/smartcard.py | 5 | 1355 | # Copyright (C) 2007 Sadique Puthen <sputhenp@redhat.com>
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
# This progr... | gpl-2.0 | 867,349,903,535,783,000 | 32.04878 | 70 | 0.665683 | false |
gogo40/GoGo-Pokerbot | h_power_calc.py | 1 | 4342 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
# GoGo - Pokerbot
# Copyright 2015 Péricles Lopes Machado
#
# 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/... | apache-2.0 | -8,282,153,635,375,138,000 | 21.609375 | 107 | 0.504262 | 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.