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 |
|---|---|---|---|---|---|---|---|---|---|---|
embeddedarm/android_external_chromium_org | tools/run-bisect-perf-regression.py | 26 | 14140 | #!/usr/bin/env python
# Copyright (c) 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.
"""Run Performance Test Bisect Tool
This script is used by a trybot to run the src/tools/bisect-perf-regression.py
script with the... | bsd-3-clause | -7,143,241,393,861,652,000 | 32.349057 | 80 | 0.657638 | false |
anshulkgupta/viznow | Mayank/blpapi_python3.5.5/examples/SimpleAsyncSubscription.py | 1 | 10206 | # SimpleAsyncSubscription.py
import blpapi
import time
import traceback
import thread
import weakref
from optparse import OptionParser
from blpapi import Event as EventType
SESSION_STARTED = blpapi.Name("SessionStarted")
SESSION_STARTUP_FAILURE = blpapi.Name("SessionStartupFailure")
TOKEN_SUCCESS = blpapi.Name("Token... | mit | 4,046,798,626,188,617,700 | 36.8 | 78 | 0.594748 | false |
SUSE/azure-sdk-for-python | azure-mgmt-logic/azure/mgmt/logic/operations/workflows_operations.py | 4 | 37104 | # 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 | 807,917,002,134,598,900 | 45.671698 | 163 | 0.640497 | false |
darkfeline/animanager | animanager/files/anime.py | 1 | 3144 | # Copyright (C) 2015-2016 Allen Li
#
# This file is part of Animanager.
#
# Animanager 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.... | gpl-3.0 | 8,488,993,397,748,272,000 | 28.942857 | 78 | 0.611005 | false |
Robbie1977/TGscripts | CwarpToTemplate.py | 1 | 11633 | import os, shutil, subprocess, datetime, socket, fnmatch, tarfile, time
from mysettings import cmtkdir, fiji, Tfile, ver, Qual, LsmPP
outdir = os.getcwd() + '/'
#fo = open("PLpre.txt",'r')
#filelist = fo.readlines()
#fo.close()
hostn = socket.gethostname()
runid = os.getpid()
procid = '[' + ... | mit | -370,387,519,062,286,900 | 53.660287 | 313 | 0.435227 | false |
PeterSurda/PyBitmessage | dev/bloomfiltertest.py | 3 | 1918 | """
dev/bloomfiltertest.py
======================
"""
import sqlite3
from os import getenv, path
from time import time
from pybloom import BloomFilter as BloomFilter1 # pylint: disable=import-error
from pybloomfilter import BloomFilter as BloomFilter2 # pylint: disable=import-error
# Ubuntu: apt-get install pytho... | mit | 6,938,646,361,064,516,000 | 28.060606 | 99 | 0.647028 | false |
SahilTikale/haas | tests/deployment/vlan_networks.py | 4 | 10638 | """Test various properties re: vlan tagged networks, on real hardware.
For guidance on running these tests, see the section on deployment
tests in docs/testing.md
"""
import json
from collections import namedtuple
from hil import api, model, deferred, config, errors
from hil.test_common import config_testsuite, fail... | apache-2.0 | 165,807,373,512,891,000 | 43.325 | 79 | 0.535251 | false |
trevor/calendarserver | calendarserver/provision/root.py | 1 | 16292 | # -*- test-case-name: calendarserver.provision.test.test_root -*-
##
# Copyright (c) 2005-2014 Apple 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.a... | apache-2.0 | -7,186,751,252,213,585,000 | 36.281465 | 88 | 0.556776 | false |
infoelliex/odoo-saas-tools | saas_utils/connector.py | 13 | 1300 | # -*- coding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2004-2010, 2014 Tiny SPRL (<http://tiny.be>).
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of t... | lgpl-3.0 | -472,756,408,337,173,400 | 42.333333 | 78 | 0.613077 | false |
quark-mcu/qm-bootloader | tools/sysupdate/qmfmlib/qfu.py | 2 | 14462 | #!/usr/bin/python -tt
# -*- coding: utf-8 -*-
# Copyright (c) 2017, Intel Corporation
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above co... | bsd-3-clause | 6,907,986,873,129,123,000 | 33.598086 | 79 | 0.599917 | false |
jrwdunham/old-webapp | onlinelinguisticdatabase/controllers/analysis.py | 1 | 52638 | # −*− coding: UTF−8 −*−
# Copyright (C) 2010 Joel Dunham
#
# This file is part of OnlineLinguisticDatabase.
#
# OnlineLinguisticDatabase 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... | gpl-3.0 | 2,214,930,067,422,533,600 | 35.855042 | 94 | 0.5955 | false |
ScegfOd/wesnoth | data/tools/unit_tree/wiki_output.py | 15 | 6187 | import sys
from . import helpers
from .html_output import Translation
def main():
wesnoth = helpers.WesnothList(
options.wesnoth,
options.config_dir,
options.data_dir,
options.transdir)
translated = Translation(options.transdir, options.language)
original = Translation(... | gpl-2.0 | -7,558,117,287,068,225,000 | 35.181287 | 100 | 0.54065 | false |
vanpact/scipy | scipy/stats/tests/test_rank.py | 28 | 6323 | from __future__ import division, print_function, absolute_import
import numpy as np
from numpy.testing import TestCase, run_module_suite, assert_equal, \
assert_array_equal
from scipy.stats import rankdata, tiecorrect
class TestTieCorrect(TestCase):
def test_empty(self):
"""An empty array requires ... | bsd-3-clause | -1,244,138,375,132,788,200 | 31.761658 | 77 | 0.504982 | false |
pyNLO/PyNLO | src/pynlo/util/pynlo_ffts.py | 2 | 1292 | # -*- coding: utf-8 -*-
"""
Created on Sat Apr 19 12:08:09 2014
This file is part of pyNLO.
pyNLO is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your optio... | gpl-3.0 | -4,912,161,479,920,580,000 | 35.914286 | 81 | 0.709752 | false |
jvassev/dd-agent | jmxfetch.py | 14 | 18408 | # set up logging before importing any other components
if __name__ == '__main__':
from config import initialize_logging # noqa
initialize_logging('jmxfetch')
# std
import glob
import logging
import os
import signal
import sys
import time
# 3rd party
import yaml
# datadog
from config import (
DEFAULT_CHE... | bsd-3-clause | -8,383,728,626,071,692,000 | 40.931663 | 200 | 0.570621 | false |
marosi/SocialDesktopClient | plugins/buddycloud/3rdparty/swift/3rdParty/SCons/scons-local-2.0.0.final.0/SCons/Tool/suncc.py | 34 | 1978 | """SCons.Tool.suncc
Tool-specific initialization for Sun Solaris (Forte) CC and cc.
There normally shouldn't be any need to import this module directly.
It will usually be imported through the generic SCons.Tool.Tool()
selection method.
"""
#
# Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010... | gpl-3.0 | -8,685,766,431,366,180,000 | 33.103448 | 95 | 0.729525 | false |
Acehaidrey/incubator-airflow | airflow/contrib/secrets/hashicorp_vault.py | 8 | 1152 | #
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not... | apache-2.0 | -3,671,080,068,118,884,400 | 37.4 | 89 | 0.769097 | false |
swprojects/Advanced-Action-Scheduler | advancedactionscheduler/base.py | 1 | 18977 | # -*- coding: utf-8 -*
"""
@author Simon Wu <swprojects@runbox.com>
Copyright (c) 2018 by Simon Wu <Advanced Action Scheduler>
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... | gpl-2.0 | -121,047,236,581,522,830 | 29.170111 | 98 | 0.502292 | false |
dims/cinder | cinder/tests/unit/api/contrib/test_volume_host_attribute.py | 2 | 5323 | # Copyright 2012 OpenStack Foundation
#
# 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 | 1,668,633,759,151,440,100 | 35.710345 | 77 | 0.629156 | false |
scality/cinder | cinder/zonemanager/utils.py | 23 | 4376 | # (c) Copyright 2012-2014 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/lic... | apache-2.0 | 3,327,257,172,252,760,600 | 35.165289 | 78 | 0.603519 | false |
shootstar/novatest | nova/api/openstack/compute/limits.py | 3 | 16428 | # Copyright 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 requ... | apache-2.0 | 8,665,861,442,626,651,000 | 31.7251 | 79 | 0.607439 | false |
MechCoder/scikit-learn | sklearn/feature_selection/univariate_selection.py | 19 | 26302 | """Univariate features selection."""
# Authors: V. Michel, B. Thirion, G. Varoquaux, A. Gramfort, E. Duchesnay.
# L. Buitinck, A. Joly
# License: BSD 3 clause
import numpy as np
import warnings
from scipy import special, stats
from scipy.sparse import issparse
from ..base import BaseEstimator
from ..prepr... | bsd-3-clause | -6,488,583,189,400,307,000 | 33.883289 | 80 | 0.629952 | false |
PlutoniumHeart/ITK | Wrapping/Generators/Python/Tests/CastImageFilter.py | 19 | 1145 | #==========================================================================
#
# Copyright Insight Software Consortium
#
# 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... | apache-2.0 | 4,363,121,764,346,589,700 | 31.714286 | 77 | 0.636681 | false |
lshain-android-source/external-chromium_org | build/android/buildbot/bb_host_steps.py | 23 | 4602 | #!/usr/bin/env python
# Copyright 2013 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import os
import sys
import bb_utils
import bb_annotations
sys.path.append(os.path.join(os.path.dirname(__file__), '..'))
from pylib ... | bsd-3-clause | 6,647,442,044,972,894,000 | 31.638298 | 80 | 0.674272 | false |
StuartLittlefair/astropy | astropy/io/misc/asdf/tags/table/table.py | 8 | 4380 | # Licensed under a 3-clause BSD style license - see LICENSE.rst
# -*- coding: utf-8 -*-
import numpy as np
from asdf.tags.core.ndarray import NDArrayType
from astropy import table
from astropy.io.misc.asdf.types import AstropyType, AstropyAsdfType
class TableType:
"""
This class defines to_tree and from_tre... | bsd-3-clause | -4,751,110,466,474,300,000 | 31.205882 | 79 | 0.619178 | false |
evalsocket/tensorflow | object_detection/object_detection/utils/np_box_list_ops_test.py | 26 | 16886 | # 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... | bsd-2-clause | 6,379,117,208,551,208,000 | 39.78744 | 80 | 0.551818 | false |
marklescroart/bvp | bvp/Classes/render_options.py | 1 | 37159 | """
TODO:
Might be nice to store specific presets of RenderOptions, for specific final
choices for rendering stimuli for a given experiment.
FOR NOW, this is not going to be a mapped class...
"""
# Imports
import os
import sys
import math as bnp
from .. import utils as bvpu
from ..options import config
try:
im... | bsd-2-clause | -3,798,760,241,647,120,400 | 48.347942 | 157 | 0.5579 | false |
Synerty/vortexpy | vortex/test/TuplePerfTest.py | 1 | 1588 | from datetime import datetime
import gc
import os
import psutil
import pytz
process = psutil.Process(os.getpid())
ITER_COUNT = 1000 * 1000 * 5
RESULT = None
def makeL(i):
# Use this line to negate the effect of the strings on the test
# return "Python is smart and will only create one string with this lin... | mit | 8,186,198,323,836,041,000 | 22.701493 | 89 | 0.625945 | false |
go-python/gopy-gen | _examples/seqs/test.py | 2 | 1049 | # Copyright 2015 The go-python Authors. All rights reserved.
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
## py2/py3 compat
from __future__ import print_function
import sys
_PY3 = sys.version_info[0] == 3
if _PY3:
xrange = range
import seqs
### test docs... | bsd-3-clause | -7,480,195,438,124,358,000 | 19.98 | 61 | 0.580553 | false |
yuanming-hu/taichi | tests/python/test_grouped.py | 1 | 3479 | import taichi as ti
@ti.all_archs
def test_vector_index():
val = ti.field(ti.i32)
n = 4
m = 7
p = 11
ti.root.dense(ti.i, n).dense(ti.j, m).dense(ti.k, p).place(val)
@ti.kernel
def test():
for i in range(n):
for j in range(m):
for k in range(p):
... | mit | 2,686,256,191,990,908,400 | 18.220994 | 79 | 0.443806 | false |
harrissoerja/rapidpro | temba/msgs/migrations/0017_install_label_triggers.py | 2 | 4542 | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
def populate_label_counts(apps, schema_editor):
"""
Iterate across all our labels, calculate how many visible, non-test messages are in them
"""
Label = apps.get_model('msgs', 'Label')
user_la... | agpl-3.0 | -5,752,431,562,816,652,000 | 42.257143 | 107 | 0.581902 | false |
Stanford-Online/edx-platform | lms/djangoapps/support/urls.py | 10 | 1447 | """
URLs for the student support app.
"""
from django.conf.urls import url
from lms.djangoapps.support.views.contact_us import ContactUsView
from support.views.certificate import CertificatesSupportView
from support.views.course_entitlements import EntitlementSupportView
from support.views.enrollments import Enrollmen... | agpl-3.0 | 7,024,482,962,946,849,000 | 40.342857 | 88 | 0.712509 | false |
BGS/pyLauncher | pyl_ui/options_ui.py | 1 | 11888 | '''
pyLauncher: Windows Application Launcher
Copyright (C) Blaga Florentin Gabriel
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later versi... | gpl-3.0 | -7,839,995,187,203,604,000 | 47.522449 | 469 | 0.681023 | false |
dakcarto/suite-qgis-plugin | src/opengeo/gui/dialogs/projectdialog.py | 1 | 4580 | from PyQt4 import QtGui, QtCore
class PublishProjectDialog(QtGui.QDialog):
def __init__(self, catalogs, parent = None):
super(PublishProjectDialog, self).__init__(parent)
self.catalogs = catalogs
self.catalog = None
self.workspace = None
self.text = None
... | gpl-2.0 | -3,875,909,941,491,516,400 | 40.261261 | 126 | 0.604148 | false |
junhuac/MQUIC | src/tools/perf/benchmarks/dromaeo.py | 2 | 9603 | # Copyright 2013 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import math
import os
from core import perf_benchmark
from telemetry import benchmark
from telemetry import page as page_module
from telemetry.page import ... | mit | 3,813,881,779,592,105,000 | 27.580357 | 80 | 0.679059 | false |
ingenioustechie/zamboni | mkt/webapps/management/commands/generate_receipts.py | 18 | 3508 | import json
import os
import tempfile
import time
from optparse import make_option
from django.core.management.base import BaseCommand, CommandError
from mkt.users.models import UserProfile
from mkt.webapps.models import Installed, Webapp
class Command(BaseCommand):
"""
Used to generate a whole pile of rece... | bsd-3-clause | -6,061,104,202,163,082,000 | 37.130435 | 79 | 0.580103 | false |
pydata/conf_site | symposion/proposals/templatetags/proposal_tags.py | 1 | 2338 | from django import template
from symposion.proposals.models import AdditionalSpeaker
register = template.Library()
class AssociatedProposalsNode(template.Node):
@classmethod
def handle_token(cls, parser, token):
bits = token.split_contents()
if len(bits) == 3 and bits[1] == "as":
... | mit | -2,728,229,123,176,684,000 | 28.974359 | 77 | 0.606501 | false |
chen2aaron/SnirteneCodes | Spider/souche_spider.py | 1 | 5865 | # -*- coding:utf-8 -*-
import requests
import re
import json
from time import sleep
from Utils import torndb, sql
"""
brands_list_url 搜车网的获取汽车品牌接口
请求参数
'type': 'car-subdivision',
返回json为
{'items': [{'check': None,
'code': 'brand-170',
'dindex': 2147483647,
'enNa... | gpl-2.0 | 3,052,965,385,087,952,400 | 29.527174 | 145 | 0.456115 | false |
anntzer/numpy | numpy/typing/tests/data/reveal/mod.py | 3 | 6991 | from typing import Any
import numpy as np
f8 = np.float64()
i8 = np.int64()
u8 = np.uint64()
f4 = np.float32()
i4 = np.int32()
u4 = np.uint32()
td = np.timedelta64(0, "D")
b_ = np.bool_()
b = bool()
f = float()
i = int()
AR_b: np.ndarray[Any, np.dtype[np.bool_]]
AR_m: np.ndarray[Any, np.dtype[np.timedelta64]]
# T... | bsd-3-clause | -4,190,801,007,336,306,000 | 46.557823 | 243 | 0.643399 | false |
RealTimeWeb/wikisite | MoinMoin/util/diff_html.py | 1 | 5844 | # -*- coding: iso-8859-1 -*-
"""
MoinMoin - Side by side diffs
@copyright: 2002 Juergen Hermann <jh@web.de>,
2002 Scott Moonen <smoonen@andstuff.org>
@license: GNU GPL, see COPYING for details.
"""
from MoinMoin.support import difflib
from MoinMoin.wikiutil import escape
def indent(line):... | apache-2.0 | 5,856,964,714,600,919,000 | 38.755102 | 160 | 0.542779 | false |
alexus37/AugmentedRealityChess | pythonAnimations/pyOpenGLChess/engineDirectory/oglc-env/lib/python2.7/site-packages/OpenGL/GL/EXT/texture_mirror_clamp.py | 9 | 1396 | '''OpenGL extension EXT.texture_mirror_clamp
This module customises the behaviour of the
OpenGL.raw.GL.EXT.texture_mirror_clamp to provide a more
Python-friendly API
Overview (from the spec)
EXT_texture_mirror_clamp extends the set of texture wrap modes to
include three modes (GL_MIRROR_CLAMP_EXT, GL_MIRROR_CLA... | mit | 6,614,285,079,264,739,000 | 37.805556 | 71 | 0.786533 | false |
windskyer/nova | nova/virt/vmwareapi/vif.py | 3 | 7803 | # 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. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0... | gpl-2.0 | -3,051,860,152,735,354,400 | 41.178378 | 78 | 0.614635 | false |
abtink/openthread | tests/toranj/test-041-lowpan-fragmentation.py | 9 | 3582 | #!/usr/bin/env python3
#
# Copyright (c) 2020, The OpenThread Authors.
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
# 1. Redistributions of source code must retain the above copyright
# ... | bsd-3-clause | -2,570,936,491,317,190,700 | 40.172414 | 121 | 0.591569 | false |
NeostreamTechnology/Microservices | venv/lib/python2.7/site-packages/functools32/reprlib32.py | 23 | 5126 | """Redo the builtin repr() (representation) but with limits on most sizes."""
__all__ = ["Repr", "repr", "recursive_repr"]
import __builtin__ as builtins
from itertools import islice
try:
from thread import get_ident
except ImportError:
from _dummy_thread32 import get_ident
def recursive_repr(fillvalue='...'... | mit | -6,125,561,229,947,608,000 | 31.649682 | 79 | 0.527117 | false |
MasterAlish/kg_bible | bible_parser/saver.py | 1 | 2522 | import sqlite3
class BibleSqliteSaver(object):
def __init__(self, bible, db_name):
self.bible = bible
self.conn = sqlite3.connect(db_name)
def save(self):
self._init_tables()
for book in self.bible.books:
book_id = self.conn.execute("INSERT INTO 'books' (name) valu... | gpl-2.0 | -4,249,515,913,284,056,000 | 50.489796 | 141 | 0.530928 | false |
ITOO-UrFU/open-programs | open_programs/apps/disciplines/migrations/0001_initial.py | 1 | 4047 | # -*- coding: utf-8 -*-
# Generated by Django 1.11 on 2017-05-02 09:11
from __future__ import unicode_literals
from django.db import migrations, models
import django.db.models.deletion
import uuid
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migra... | unlicense | 2,942,173,603,907,159,600 | 52.57971 | 154 | 0.589938 | false |
nathanhilbert/cubes | cubes/server/blueprint.py | 6 | 19779 | # -*- coding: utf-8 -*-
from flask import Blueprint, Response, request, g, current_app, url_for, safe_join, make_response
from flask import render_template, redirect
from jinja2 import Template
import json, re
from functools import wraps
import sys
import traceback
from ..workspace import Workspace, SLICER_INFO_KEYS
f... | mit | -4,615,425,646,112,495,000 | 29.949922 | 150 | 0.598372 | false |
popazerty/enigma2cuberevo | lib/python/Plugins/Extensions/MediaScanner/plugin.py | 6 | 3157 | from Plugins.Plugin import PluginDescriptor
from Components.Scanner import scanDevice
from Screens.InfoBar import InfoBar
from os import access, F_OK, R_OK
def execute(option):
print "execute", option
if option is None:
return
(_, scanner, files, session) = option
scanner.open(files, session)
def mountpoint_ch... | gpl-2.0 | 1,347,949,624,936,353,800 | 31.214286 | 198 | 0.748812 | false |
hep7agon/city-feedback-hub | api/views.py | 1 | 7869 | import operator
from django.core.exceptions import ObjectDoesNotExist
from django.http import JsonResponse
from rest_framework import status
from rest_framework.exceptions import ValidationError
from rest_framework.response import Response
from rest_framework.views import APIView
from api.analysis import *
from api.m... | mit | -8,328,444,592,867,085,000 | 40.634921 | 114 | 0.657898 | false |
ctoher/pymatgen | pymatgen/io/tests/test_aseio.py | 3 | 1564 | # coding: utf-8
from __future__ import division, unicode_literals
"""
Created on Mar 8, 2012
"""
__author__ = "Shyue Ping Ong"
__copyright__ = "Copyright 2012, The Materials Project"
__version__ = "0.1"
__maintainer__ = "Shyue Ping Ong"
__email__ = "shyuep@gmail.com"
__date__ = "Mar 8, 2012"
import unittest
import... | mit | -263,003,649,504,093,440 | 27.436364 | 74 | 0.627877 | false |
kevin-coder/tensorflow-fork | tensorflow/contrib/eager/python/tfe.py | 4 | 5764 | # 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 | 8,656,220,638,262,042,000 | 36.428571 | 124 | 0.810722 | false |
pmarques/ansible | lib/ansible/modules/iptables.py | 13 | 30939 | #!/usr/bin/python
# -*- coding: utf-8 -*-
# Copyright: (c) 2015, Linus Unnebäck <linus@folkdatorn.se>
# Copyright: (c) 2017, Sébastien DA ROCHA <sebastien@da-rocha.net>
# 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_... | gpl-3.0 | -194,049,165,952,212,800 | 35.223653 | 128 | 0.627736 | false |
rbovard/las_extractor | setup.py | 2 | 1057 | # -*- coding: utf-8 -*-
try:
from setuptools import setup, find_packages
except ImportError:
from ez_setup import use_setuptools
use_setuptools()
from setuptools import setup, find_packages
setup(
name='las_extractor',
version='0.1',
description='SITN, a sitn project',
author='sitn',
... | gpl-2.0 | 4,500,942,745,142,716,000 | 23.581395 | 66 | 0.534532 | false |
qnu/gxp | vgxp/pinfo.py | 3 | 16415 | #!/usr/bin/env python
import sys, os, os.path, socket, time, random, glob, re, pwd, errno, select, urllib
"""
/proc/stat
cpu <user> <nice> <system> <idle> <iowait> <irq> <softirq> ...
- user: normal processes executing in user mode
- nice: niced processes executing in user mode
- system: processes executing in kernel... | bsd-3-clause | 8,217,518,457,316,253,000 | 34.684783 | 109 | 0.400792 | false |
Dino0631/RedRain-Bot | cogs/lib/nacl/__init__.py | 16 | 1170 | # Copyright 2013 Donald Stufft and individual contributors
#
# 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... | gpl-3.0 | 4,528,949,898,195,974,000 | 34.454545 | 74 | 0.677778 | false |
feend78/evennia | evennia/contrib/email_login.py | 1 | 12460 | """
Email-based login system
Evennia contrib - Griatch 2012
This is a variant of the login system that requires an email-address
instead of a username to login.
This used to be the default Evennia login before replacing it with a
more standard username + password system (having to supply an email
for some reason ca... | bsd-3-clause | -879,928,916,317,831,700 | 36.53012 | 120 | 0.630177 | false |
c86j224s/snippet | Python_Pygments/lib/python3.6/site-packages/pygments/lexers/pascal.py | 6 | 32651 | # -*- coding: utf-8 -*-
"""
pygments.lexers.pascal
~~~~~~~~~~~~~~~~~~~~~~
Lexers for Pascal family languages.
:copyright: Copyright 2006-2017 by the Pygments team, see AUTHORS.
:license: BSD, see LICENSE for details.
"""
import re
from pygments.lexer import Lexer, RegexLexer, include, bygroups, ... | apache-2.0 | 5,213,161,020,567,336,000 | 49.700311 | 88 | 0.49879 | false |
JustArchi/program-y | src/programy/dialog.py | 2 | 7300 | """
Copyright (c) 2016 Keith Sterling
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
documentation files (the "Software"), to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute,... | mit | 4,281,058,491,372,725,000 | 31.15859 | 126 | 0.619726 | false |
betterlife/flask-psi | tests/views/sales_order_test.py | 2 | 5799 | import random
from flask import url_for
from six import iteritems
from tests import fixture
from psi.app import const
from psi.app.utils import db_util, calc_inline_field_name
from tests.base_test_case import BaseTestCase
from tests.object_faker import object_faker as of
class TestSalesOrderPages(BaseTestCase):
... | mit | -1,449,102,264,506,841,900 | 48.144068 | 91 | 0.580617 | false |
rmaz/buck | programs/buck_package.py | 4 | 8319 | # Copyright 2018-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 to i... | apache-2.0 | 8,315,669,822,247,099,000 | 35.169565 | 98 | 0.591417 | false |
seberg/numpy | numpy/typing/tests/data/pass/simple.py | 10 | 2690 | """Simple expression that should pass with mypy."""
import operator
import numpy as np
from typing import Iterable # noqa: F401
# Basic checks
array = np.array([1, 2])
def ndarray_func(x):
# type: (np.ndarray) -> np.ndarray
return x
ndarray_func(np.array([1, 2]))
array == 1
array.dtype == float
# Dtype ... | bsd-3-clause | -5,487,341,036,122,079,000 | 15.30303 | 79 | 0.648327 | false |
testvidya11/ejrf | questionnaire/migrations/0037_auto__add_field_question_is_required.py | 1 | 19129 | # -*- coding: utf-8 -*-
import datetime
from south.db import db
from south.v2 import SchemaMigration
from django.db import models
class Migration(SchemaMigration):
def forwards(self, orm):
# Adding field 'Question.is_required'
db.add_column(u'questionnaire_question', 'is_required',
... | bsd-3-clause | 2,539,421,261,217,425,400 | 82.173913 | 190 | 0.566679 | false |
baoboa/pizza-lammps | src/pizza.py | 2 | 13330 | #!/usr/local/bin/python -i
# Pizza.py toolkit, www.cs.sandia.gov/~sjplimp/pizza.html
# Steve Plimpton, sjplimp@sandia.gov, Sandia National Laboratories
#
# Copyright (2005) Sandia Corporation. Under the terms of Contract
# DE-AC04-94AL85000 with Sandia Corporation, the U.S. Government retains
# certain rights in this... | gpl-2.0 | 808,714,202,700,126,700 | 28.821029 | 75 | 0.565791 | false |
Serag8/Bachelor | google_appengine/lib/django-1.2/django/views/generic/create_update.py | 65 | 8794 | from django.forms.models import ModelFormMetaclass, ModelForm
from django.template import RequestContext, loader
from django.http import Http404, HttpResponse, HttpResponseRedirect
from django.core.xheaders import populate_xheaders
from django.core.exceptions import ObjectDoesNotExist, ImproperlyConfigured
from django.... | mit | 3,720,483,763,845,306,400 | 39.902326 | 114 | 0.645781 | false |
nicjhan/MOM6-examples | tools/analysis/MOM6_ts_annual.py | 6 | 5031 | # Script to plot sub-surface ocean temperature drift.
# Analysis: using newer python 2.7.3
"""
module purge
module use -a /home/fms/local/modulefiles
module load gcc
module load netcdf/4.2
module load python/2.7.3
"""
import os
import math
import numpy as np
from numpy import ma
from netCDF4 import Dataset, MFDatase... | gpl-3.0 | -1,526,006,435,967,925,500 | 27.913793 | 98 | 0.601272 | false |
agmscode/agms_python | agms/invoicing.py | 1 | 1824 | from __future__ import absolute_import
from agms.agms import Agms
from agms.request.invoicing_request import InvoicingRequest
from agms.response.invoicing_response import InvoicingResponse
from agms.exception.invalid_request_exception import InvalidRequestException
class Invoicing(Agms):
"""
A class represent... | mit | -4,166,055,359,678,810,600 | 34.784314 | 88 | 0.651316 | false |
conejoninja/plugin.video.pelisalacarta | pelisalacarta/channels/filmpertutti.py | 5 | 5117 | # -*- coding: utf-8 -*-
#------------------------------------------------------------
# pelisalacarta - XBMC Plugin
# Canal para piratestreaming
# http://blog.tvalacarta.info/plugin-xbmc/pelisalacarta/
#------------------------------------------------------------
import urlparse,urllib2,urllib,re
import os, sys
from c... | gpl-3.0 | 773,171,514,831,139,100 | 40.934426 | 402 | 0.648358 | false |
sergiocorato/project-service | project_recalculate/models/project_project.py | 6 | 3161 | # -*- coding: utf-8 -*-
# See README.rst file on addon root folder for license details
from openerp import models, fields, api, _
from openerp.fields import DATE_LENGTH
from openerp.exceptions import Warning
class ProjectProject(models.Model):
_inherit = 'project.project'
calculation_type = fields.Selection... | agpl-3.0 | -8,846,634,485,652,405,000 | 42.30137 | 79 | 0.57292 | false |
kenorb-contrib/BitTorrent | twisted/web/distrib.py | 3 | 9522 | # -*- test-case-name: twisted.web.test.test_web -*-
# Copyright (c) 2001-2004 Twisted Matrix Laboratories.
# See LICENSE for details.
"""Distributed web servers.
This is going to have to be refactored so that argument parsing is done
by each subprocess and not by the main web server (i.e. GET, POST etc.).
"""
# Sy... | gpl-3.0 | 4,833,659,365,236,759,000 | 30.425743 | 92 | 0.572149 | false |
fengzhanglab/GUIDES | static/data/pre_processed/precompute_guides_cpickle.py | 2 | 4147 | import cPickle as pickle
import json
import os.path
from Queue import PriorityQueue
import re
import doench_score
class GuideRNA():
"""Holder of gRNA information"""
def __init__(self, selected, start, seq, PAM, score, exon_ranking, ensembl_gene, gene_name):
self.start = start
self.seq = seq
self.PAM = ... | agpl-3.0 | 772,124,631,386,194,000 | 32.991803 | 145 | 0.591994 | false |
wummel/patool | tests/archives/test_plzip.py | 1 | 1251 | # -*- coding: utf-8 -*-
# Copyright (C) 2010-2015 Bastian Kleineidam
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#... | gpl-3.0 | -7,750,703,512,421,245,000 | 35.794118 | 71 | 0.713829 | false |
ldong/vim_youcompleteme | third_party/jedi/test/test_regression.py | 1 | 4806 | """
Unit tests to avoid errors of the past. These are also all tests that didn't
found a good place in any other testing module.
"""
import os
import textwrap
from .helpers import TestCase, cwd_at
import pytest
import jedi
from jedi._compatibility import u
from jedi import Script
from jedi import api
from jedi.evalu... | gpl-3.0 | 1,023,334,937,124,774,300 | 29.807692 | 78 | 0.542031 | false |
nyuszika7h/youtube-dl | youtube_dl/extractor/vidme.py | 23 | 9894 | from __future__ import unicode_literals
import itertools
from .common import InfoExtractor
from ..compat import compat_HTTPError
from ..utils import (
ExtractorError,
int_or_none,
float_or_none,
parse_iso8601,
url_or_none,
)
class VidmeIE(InfoExtractor):
IE_NAME = 'vidme'
_VALID_URL = r'... | unlicense | 7,186,849,340,191,600,000 | 32.538983 | 97 | 0.480089 | false |
bk2204/urwid | urwid/tests/test_util.py | 19 | 6613 | # -*- coding: utf-8 -*-
import unittest
import urwid
from urwid import util
from urwid.compat import B
class CalcWidthTest(unittest.TestCase):
def wtest(self, desc, s, exp):
s = B(s)
result = util.calc_width( s, 0, len(s))
assert result==exp, "%s got:%r expected:%r" % (desc, result, exp)
... | lgpl-2.1 | -8,733,404,378,098,235,000 | 36.02809 | 78 | 0.490062 | false |
mchrzanowski/ProjectEuler | src/python/Problem106.py | 1 | 1943 | '''
Created on Aug 20, 2012
@author: mchrzanowski
'''
import argparse
import Problem105
import time
def main(n_value):
numbers = [number for number in xrange(1, n_value + 1)]
groups_to_check_for_equality = 0
for subset in Problem105.all_subsets(numbers):
first_subset, second_subset = subset
... | mit | -677,884,731,423,814,500 | 28.439394 | 76 | 0.606794 | false |
mike-lawrence/actichampy | pycorder/impedance.py | 1 | 18694 | # -*- coding: utf-8 -*-
'''
Impedance Display Module
PyCorder ActiChamp Recorder
------------------------------------------------------------
Copyright (C) 2010, Brain Products GmbH, Gilching
This file is part of PyCorder
PyCorder is free software: you can redistribute it and/or
modify it under the te... | gpl-3.0 | -6,931,737,067,982,420,000 | 37.944444 | 128 | 0.55467 | false |
landlab/landlab | tests/grid/test_raster_grid/test_bc_updates.py | 3 | 1905 | import numpy as np
from numpy.testing import assert_array_equal
from landlab import LinkStatus, RasterModelGrid
def test_issue_428_a():
"""Issue #428"""
grid = RasterModelGrid((4, 4))
grid.set_closed_boundaries_at_grid_edges(True, True, True, True)
assert grid.status_at_node[1] == 4
assert grid.... | mit | -8,330,857,016,671,884,000 | 30.75 | 80 | 0.656693 | false |
unreal666/youtube-dl | youtube_dl/utils.py | 2 | 121771 | #!/usr/bin/env python
# coding: utf-8
from __future__ import unicode_literals
import base64
import binascii
import calendar
import codecs
import contextlib
import ctypes
import datetime
import email.utils
import email.header
import errno
import functools
import gzip
import io
import itertools
import json
import local... | unlicense | 3,374,019,621,751,892,500 | 30.05998 | 130 | 0.529817 | false |
JulienMcJay/eclock | windows/Python27/Lib/site-packages/pywin32-218-py2.7-win32.egg/win32com/servers/perfmon.py | 18 | 1045 | """A COM Server which exposes the NT Performance monitor in a very rudimentary way
Usage from VB:
set ob = CreateObject("Python.PerfmonQuery")
freeBytes = ob.Query("Memory", "Available Bytes")
"""
from win32com.server import exception, register
import pythoncom, win32pdhutil, winerror
class PerfMonQuery:
_reg_verp... | gpl-2.0 | 4,480,837,282,250,981,000 | 37.703704 | 91 | 0.752153 | false |
9seconds/fuel-pdsh | fuelpdsh/ssh.py | 1 | 1494 | # -*- coding: utf-8 -*-
import sys
import asyncssh
import fuelpdsh
LOG = fuelpdsh.logger(__name__)
"""Logger."""
class SSHClientSession(asyncssh.SSHClientSession):
PREFIX_LENGTH = 10
def __init__(self, hostname):
super(SSHClientSession, self).__init__()
self.obuffer = ""
self.... | mit | -2,341,218,159,560,355,000 | 23.9 | 74 | 0.588353 | false |
LibraryOfCongress/gazetteer | conflate/ngram.py | 1 | 3527 | import array, re, math, json
def ngrams(text, n=3):
# this bit is special for Geonames:
text = re.sub(r'\s*\(.*?\)\s*', '', text)
text = re.sub(r'[^a-z]', '', text.strip().lower())
text = " " * (n-1) + text + " " * (n-1)
grams = []
for i in range(len(text)-n+1):
grams.append(text[i:i+n]... | mit | 1,661,719,351,906,280,200 | 29.669565 | 95 | 0.555713 | false |
hmartiro/zircon | zircon/utils/export.py | 1 | 2230 | """
"""
import csv
import argparse
class DataExporter():
def __init__(self, datastore=None):
if not datastore:
from zircon.datastores.influx import InfluxDatastore
datastore = InfluxDatastore()
self.db = datastore
def export_csv(self, signals, t0, t1, dt, aggregat... | mit | 5,935,580,710,210,425,000 | 26.195122 | 74 | 0.497309 | false |
Ayub-Khan/edx-platform | lms/djangoapps/certificates/migrations/0002_data__certificatehtmlviewconfiguration_data.py | 26 | 2181 | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
import json
# Converted from the original South migration 0020_certificatehtmlviewconfiguration_data.py
from django.db import migrations, models
def forwards(apps, schema_editor):
"""
Bootstraps the HTML view template with some default configu... | agpl-3.0 | -2,469,787,986,141,617,000 | 34.177419 | 114 | 0.648785 | false |
phr34k/serpent | packages/serpent-msbuild/validate.py | 1 | 5067 | import os, sys, re
required_intdir = '$(ADK_INT_DIR)'
required_outputdir = '$(ADK_BIN_PATH)'
required_targets = ['Debug|Win32', 'Release|Win32']
def is_external(path):
if 'Thirdparty' not in path and 'extern' not in path and 'msvc' not in path:
return False
return True
def is_properties(path):
if path.endswith(... | mit | -2,115,450,685,053,563,100 | 42.689655 | 147 | 0.6866 | false |
primecloud-controller-org/primecloud-controller | iaas-gw/src/iaasgw/controller/ec2/ec2LoadBalancercontroller.py | 5 | 25854 | # coding: UTF-8
#
# Copyright 2014 by SCSK Corporation.
#
# This file is part of PrimeCloud Controller(TM).
#
# PrimeCloud Controller(TM) 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... | gpl-2.0 | -7,124,395,639,295,868,000 | 41.73741 | 211 | 0.638793 | false |
jawilson/Flexget | flexget/tests/test_plugin_interfaces.py | 8 | 1353 | from __future__ import unicode_literals, division, absolute_import
from builtins import * # noqa pylint: disable=unused-import, redefined-builtin
from flexget import plugin
class TestInterfaces(object):
"""Test that any plugins declaring certain interfaces at least superficially comply with those interfaces."""... | mit | 4,115,027,193,662,372,400 | 49.111111 | 113 | 0.692535 | false |
arokem/nipy | nipy/algorithms/tests/test_resample.py | 3 | 9815 | # emacs: -*- mode: python; py-indent-offset: 4; indent-tabs-mode: nil -*-
# vi: set ft=python sts=4 ts=4 sw=4 et:
import numpy as np
from nipy.core.api import (AffineTransform, Image,
ArrayCoordMap, compose)
from nipy.core.reference import slices
from nipy.algorithms.resample import resam... | bsd-3-clause | -3,983,556,513,998,079,000 | 38.417671 | 79 | 0.584208 | false |
home-assistant/home-assistant | homeassistant/components/philips_js/device_trigger.py | 5 | 2230 | """Provides device automations for control of device."""
from __future__ import annotations
import voluptuous as vol
from homeassistant.components.automation import AutomationActionType
from homeassistant.components.device_automation import TRIGGER_BASE_SCHEMA
from homeassistant.const import CONF_DEVICE_ID, CONF_DOMA... | apache-2.0 | 8,366,974,317,532,377,000 | 31.318841 | 85 | 0.654709 | false |
mpetyx/DarwinsMusic | src/server/server/franz/openrdf/util/uris.py | 2 | 2282 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
# pylint: disable-msg=C0103
###############################################################################
# Copyright (c) 2006-2013 Franz Inc.
# All rights reserved. This program and the accompanying materials
# are made available under the terms of the Eclipse Public Li... | agpl-3.0 | 3,228,351,504,672,660,500 | 40.490909 | 85 | 0.641104 | false |
koiszzz/shadowsocks | shadowsocks/encrypt.py | 26 | 6429 | #!/usr/bin/env python
# Copyright (c) 2014 clowwindy
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, me... | mit | -536,966,463,627,423,740 | 30.826733 | 79 | 0.588427 | false |
cjahangir/geodash-new | geonode/people/urls.py | 2 | 1870 | # -*- coding: utf-8 -*-
#########################################################################
#
# Copyright (C) 2016 OSGeo
#
# 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 ... | gpl-3.0 | -5,356,872,534,226,905,000 | 50.944444 | 117 | 0.575936 | false |
storm-computers/odoo | openerp/tools/convert.py | 12 | 38867 | # -*- coding: utf-8 -*-
# Part of Odoo. See LICENSE file for full copyright and licensing details.
import cStringIO
import csv
import logging
import os.path
import re
import sys
import time
from datetime import datetime, timedelta
from dateutil.relativedelta import relativedelta
import pytz
from lxml import etree, b... | agpl-3.0 | -6,659,251,375,356,320,000 | 40.658092 | 219 | 0.527826 | false |
jralls/gramps | gramps/gen/plug/report/stdoptions.py | 2 | 14579 | #
# Gramps - a GTK+/GNOME based genealogy program
#
# Copyright (C) 2013 John Ralls <jralls@ceridwen.us>
# Copyright (C) 2013-2017 Paul Franklin
#
# 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 Foun... | gpl-2.0 | 2,420,177,266,173,407,700 | 43.31307 | 79 | 0.651211 | false |
archetipo/server-tools | base_external_dbsource/base_external_dbsource.py | 2 | 6784 | # -*- coding: utf-8 -*-
##############################################################################
#
# Daniel Reis
# 2011
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundati... | agpl-3.0 | -7,047,281,655,317,171,000 | 36.899441 | 79 | 0.544664 | false |
birkin/channels_exploration_project | primes_app/views.py | 1 | 1127 | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
import datetime, logging
from channels import Channel
from django.http import HttpResponse
log = logging.getLogger(__name__)
def hi( request ):
""" Returns simplest response. """
now = datetime.datetime.now()
log.debug( 'now, `{}`'.format(n... | mit | -139,578,035,403,708,100 | 27.897436 | 67 | 0.61402 | false |
LandRegistry-Attic/matching-alpha | matching/models.py | 1 | 1689 | from sqlalchemy.dialects.postgresql import TEXT
from sqlalchemy.dialects.postgresql import UUID
from sqlalchemy.dialects.postgresql import BOOLEAN
from sqlalchemy.types import Enum
from matching import db
roles_users = db.Table('roles_users',
db.Column('user_lrid',UUID(as_uuid=True), db.ForeignKey('users.lri... | mit | 2,334,935,415,609,113,600 | 32.117647 | 79 | 0.606276 | false |
shaunstanislaus/grab | grab/base.py | 8 | 23594 | # -*- coding: utf-8 -*-
# Copyright: 2011, Grigoriy Petukhov
# Author: Grigoriy Petukhov (http://lorien.name)
# License: BSD
"""
The core of grab package: the Grab class.
"""
from __future__ import absolute_import
import logging
import os
from random import randint
from copy import copy, deepcopy
import threading
impor... | mit | 6,771,816,484,406,206,000 | 30.126649 | 79 | 0.554887 | false |
ihaveamac/Kurisu | cogs/mod_db.py | 1 | 1934 | from discord.ext import commands
from utils.checks import is_staff
from utils import crud
class ModDB(commands.Cog):
"""
Database management commands.
"""
NOT_FOUND = 'Flag was not found in the database. ⚠️'
def __init__(self, bot):
self.bot = bot
async def cog_check(self, ctx):
... | apache-2.0 | 2,232,703,627,020,649,500 | 29.47619 | 69 | 0.589063 | false |
SherSingh07/albums | gallery/urls.py | 1 | 1586 | """gallery URL Configuration
The `urlpatterns` list routes URLs to views. For more information please see:
https://docs.djangoproject.com/en/1.9/topics/http/urls/
Examples:
Function views
1. Add an import: from my_app import views
2. Add a URL to urlpatterns: url(r'^$', views.home, name='home')
Class-bas... | apache-2.0 | 6,114,460,916,937,103,000 | 38.65 | 79 | 0.68348 | false |
lepistone/odoo | addons/mrp/product.py | 23 | 3371 | # -*- 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 | 277,573,788,760,050,270 | 42.779221 | 214 | 0.611391 | 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.