repo_name stringlengths 5 92 | path stringlengths 4 232 | copies stringclasses 19
values | size stringlengths 4 7 | content stringlengths 721 1.04M | license stringclasses 15
values | hash int64 -9,223,277,421,539,062,000 9,223,102,107B | line_mean float64 6.51 99.9 | line_max int64 15 997 | alpha_frac float64 0.25 0.97 | autogenerated bool 1
class |
|---|---|---|---|---|---|---|---|---|---|---|
benpicco/mate-deskbar-applet | deskbar/ui/cuemiac/CuemiacEntry.py | 1 | 5439 | import gobject
import gtk
import deskbar.ui.iconentry
# Make epydoc document signal
__extra_epydoc_fields__ = [('signal', 'Signals')]
class CuemiacEntry (deskbar.ui.iconentry.IconEntry):
"""
For all outside purposes this widget should appear to be a gtk.Entry
with an icon inside it. Use it as such - if y... | gpl-2.0 | 1,979,936,256,918,578,700 | 36.253425 | 110 | 0.58963 | false |
Uli1/mapnik | scons/scons-local-2.4.0/SCons/Tool/packaging/tarbz2.py | 1 | 1780 | """SCons.Tool.Packaging.tarbz2
The tarbz2 SRC packager.
"""
#
# Copyright (c) 2001 - 2015 The SCons Foundation
#
# 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, includ... | lgpl-2.1 | -4,742,350,656,658,062,000 | 39.454545 | 115 | 0.754494 | false |
GitYiheng/reinforcement_learning_test | test00_previous_files/mountaincar_q_learning.py | 1 | 4304 | import gym
import os
import sys
import numpy as np
import matplotlib
import matplotlib.pyplot as plt
from mpl_toolkits.mplot3d import Axes3D
from gym import wrappers
from datetime import datetime
from sklearn.pipeline import FeatureUnion
from sklearn.preprocessing import StandardScaler
from sklearn.kernel_approximation... | mit | 8,215,012,395,460,675,000 | 29.316901 | 104 | 0.702602 | false |
TOTVS/mdmpublic | couchbase-cli/lib/python/pysnappy2/snappy_cffi.py | 1 | 7457 | import sys
from cffi import FFI
if sys.hexversion > 0x03000000:
unicode = str
ffi = FFI()
ffi.cdef('''
typedef enum {
SNAPPY_OK = 0,
SNAPPY_INVALID_INPUT = 1,
SNAPPY_BUFFER_TOO_SMALL = 2
} snappy_status;
typedef uint32_t crc_t;
int snappy_compress(const char* input,
size_t input_leng... | bsd-2-clause | -6,329,586,353,257,445,000 | 28.243137 | 78 | 0.670913 | false |
fracpete/wekamooc | moredataminingwithweka/class-4.2.py | 1 | 2966 | # This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# bu... | gpl-3.0 | 8,800,521,282,337,979,000 | 36.075 | 102 | 0.708699 | false |
aemerick/galaxy_analysis | particle_analysis/sn_rate.py | 1 | 9054 | #import yt.mods as yt
import yt
import matplotlib as mpl
mpl.use('Agg')
import matplotlib.pyplot as plt
import numpy as np
import glob
__all__ = ['future_snr', 'snr']
_core_collapse_labels = ["SNII", "II", "2", "SN_II", "TypeII", "Type 2",
"Type II", "type II", "typeII", 'core collapse']
_... | mit | -6,070,210,651,879,594,000 | 35.955102 | 140 | 0.594765 | false |
cqhtyi/ADfree-Player-Offline | onServer/ruletool/oredirectlist.py | 1 | 3038 | [
{
"name": "youkujson",
"find": "https?:\/\/val[fcopb]\.atm\.youku\.com\/v[fcopb]",
"replace": "about:blank",
"extra": "adkillrule"
},
{
"name": "youkuloader",
"find": "https?:\/\/static\.youku\.com(\/v[\d\.]*)?\/v\/swf\/.*\/loaders?\.swf",
"exfind": ... | gpl-3.0 | -8,872,727,850,452,770,000 | 33.134831 | 146 | 0.473009 | false |
Mariusz-v7/MZCreeper | upload_all.py | 1 | 4210 | #-*- coding: utf-8 -*-
import time
import getpass
import os
from selenium import webdriver
from selenium.webdriver.support.ui import Select
max_wait_time = 60
#page_url = "http://gamesstats.hopto.org/"
#page_url = "http://gamesstats.loc/"
def login(driver):
file_ = open("config/upload")
page_url = file_.re... | gpl-2.0 | -7,388,926,398,939,125,000 | 25.987179 | 74 | 0.569359 | false |
spacy-io/sense2vec | bin/cythonize.py | 1 | 6170 | #!/usr/bin/env python
""" cythonize
Cythonize pyx files into C files as needed.
Usage: cythonize [root_dir]
Default [root_dir] is 'spacy'.
Checks pyx files to see if they have been changed relative to their
corresponding C files. If they have, then runs cython on these files to
recreate the C files.
The script th... | mit | -7,298,232,426,281,872,000 | 30.01005 | 107 | 0.602431 | false |
jeremiah-c-leary/vhdl-style-guide | vsg/rules/single_space_before_token.py | 1 | 1995 |
from vsg import parser
from vsg import rule
from vsg import violation
from vsg.rules import utils as rules_utils
class single_space_before_token(rule.Rule):
'''
Checks for a single space between two tokens.
Parameters
----------
name : string
The group the rule belongs to.
identifi... | gpl-3.0 | 6,567,652,907,927,217,000 | 32.813559 | 88 | 0.59198 | false |
Lindy21/CSE498-LRS | lrs/urls.py | 1 | 1256 | from django.conf.urls import patterns, include, url
urlpatterns = patterns('lrs.views',
url(r'^$', 'home'),
url(r'^statements/more/(?P<more_id>.{32})$', 'statements_more'),
url(r'^statements', 'statements'),
url(r'^activities/state', 'activity_state'),
url(r'^activities/profile', 'activity_profile'... | apache-2.0 | 124,041,952,411,922,200 | 38.25 | 77 | 0.60828 | false |
joshrule/LOTlib | LOTlib/Hypotheses/Proposers/RegenerationProposal.py | 1 | 1997 |
"""Regenerate proposals - chooses a node of type X and replaces it
with a newly sampled value of type X.
"""
from LOTlib.BVRuleContextManager import BVRuleContextManager
from LOTlib.FunctionNode import FunctionNode, NodeSamplingException
from LOTlib.Hypotheses.Proposers import ProposalFailedException
from LOTlib.Mis... | gpl-3.0 | -8,992,234,683,923,649,000 | 37.403846 | 122 | 0.696044 | false |
AdamWill/bodhi | bodhi/server/services/packages.py | 1 | 2320 | # 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 program is distributed in the hope that it will be useful,
# bu... | gpl-2.0 | -6,014,736,767,507,379,000 | 34.151515 | 81 | 0.673276 | false |
oscarforri/WebServices_Json | server.py | 1 | 3555 | #!flask/bin/python
from flask import Flask, jsonify, abort, make_response, request
from resources import posts, todos, comments, albums, photos, users
app = Flask(__name__)
@app.errorhandler(404)
def not_found(error):
return make_response(jsonify({'error': 'Not found'}), 404)
@app.errorhandler(400)
def bad_requ... | gpl-3.0 | -146,195,189,189,963,100 | 27.902439 | 117 | 0.603657 | false |
iglpdc/dmrg_helpers | scripts/append_metadata_from_xml.py | 1 | 2434 | #!/usr/bin/env python
"""Appends metadata to estimators files reading from input xml files.
The current version of the DMRG does not include any metadata into the
estimator files. Metadata are comment lines that have information about the run
the estimator was obtained from, such as the value of the Hamiltonian
parame... | mit | -7,388,700,737,663,430,000 | 37.634921 | 79 | 0.732128 | false |
metamath/set.mm | scripts/iset-match.py | 1 | 1795 | #!/usr/bin/env python3
# iset-match.py: Report where iset.mm statements differ from set.mm.
# Author: David A. Wheeler
# SPDX-License-Identifier: MIT
import os,re
# Generate list of statements in set.mm and iset.mm.
os.system("metamath 'read set.mm' 'set width 9999' 'show statement *' quit > ,set-mm-statements")
os.s... | cc0-1.0 | 8,621,906,787,565,850,000 | 29.948276 | 99 | 0.640111 | false |
SlicerRt/SlicerDebuggingTools | PyDevRemoteDebug/ptvsd-4.1.3/ptvsd/_local.py | 1 | 4791 | # Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See LICENSE in the project root
# for license information.
import sys
import time
import pydevd
from _pydevd_bundle.pydevd_comm import get_global_debugger
from ptvsd.pydevd_hooks import install
from ptvsd.runner ... | bsd-3-clause | -6,504,013,464,289,144,000 | 31.503497 | 77 | 0.594448 | false |
saisankargochhayat/algo_quest | leetcode/1423. Maximum Points You Can Obtain from Cards/soln.py | 1 | 1199 | # Get prefix sum array, find n-k window for which n-k is minimum.
class Solution:
def maxScore(self, cardPoints: List[int], k: int) -> int:
n = len(cardPoints)
pSum = [0] * n
pSum[0] = cardPoints[0]
for i in range(1, n):
pSum[i] = cardPoints[i] + pSum[i-1]
... | apache-2.0 | -272,638,181,483,588,160 | 32.305556 | 76 | 0.527106 | false |
robintw/Py6S | tests/test_profiles.py | 1 | 19426 | # This file is part of Py6S.
#
# Copyright 2012 Robin Wilson and contributors listed in the CONTRIBUTORS file.
#
# Py6S 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 License, o... | lgpl-3.0 | -2,371,384,820,571,932,700 | 27.95082 | 83 | 0.304952 | false |
johnnoone/json-spec | tests/test_commands.py | 1 | 4664 | """
tests.tests_cli
~~~~~~~~~~~~~~~
"""
import pytest
from subprocess import Popen, PIPE
from jsonspec import cli
import json
from . import move_cwd
def runner(cmd, args, success, result):
try:
args = cmd.parse_args(args)
response = cmd(args)
if not success:
raise Exc... | bsd-3-clause | -8,597,363,922,463,089,000 | 31.84507 | 102 | 0.582976 | false |
tinkerinestudio/Tinkerine-Suite | TinkerineSuite/Cura/cura_sf/fabmetheus_utilities/geometry/geometry_utilities/evaluate_elements/creation.py | 1 | 1903 | """
Boolean geometry utilities.
"""
from __future__ import absolute_import
from fabmetheus_utilities.geometry.geometry_utilities import evaluate
from fabmetheus_utilities import archive
__author__ = 'Enrique Perez (perez_enrique@yahoo.com)'
__credits__ = 'Art of Illusion <http://www.artofillusion.org/>'
__date__ =... | agpl-3.0 | 4,311,426,377,472,465,400 | 32.982143 | 108 | 0.76721 | false |
gppg1994/Machine_Learning | Mail_Check/Main.py | 1 | 1521 | '''This automation helps you to automatically sign in to yahoo mail
without a single mouse/keyboard stroke. To run this piece of code successfully,
you need to have an existing yahoo account'''
from selenium import webdriver
import time
from Configure import Configure
def if_exists(idstr):
try:
el... | gpl-3.0 | -900,942,733,077,118,500 | 27.823529 | 80 | 0.610125 | false |
anybox/anybox.recipe.odoo | anybox/recipe/odoo/vcs/tests/test_bzr.py | 1 | 21368 | """VCS tests: Bazaar."""
import os
import subprocess
from zc.buildout import UserError
from ..testing import COMMIT_USER_FULL
from ..testing import VcsTestCase
from ..bzr import BzrBranch
from ..bzr import working_directory_keeper
from ..base import UpdateError
from ..base import CloneError
class BzrBaseTestCase(Vcs... | agpl-3.0 | -7,794,256,435,786,472,000 | 37.850909 | 79 | 0.599588 | false |
ulfalizer/Kconfiglib | examples/find_symbol.py | 1 | 3437 | # Prints all menu nodes that reference a given symbol any of their properties
# or property conditions, along with their parent menu nodes.
#
# Usage:
#
# $ make [ARCH=<arch>] scriptconfig SCRIPT=Kconfiglib/examples/find_symbol.py SCRIPT_ARG=<name>
#
# Example output for SCRIPT_ARG=X86:
#
# Found 470 locations that... | isc | 8,374,800,690,160,126,000 | 29.6875 | 97 | 0.629328 | false |
LazoCoder/Pokemon-Terminal | tests/test_broken.py | 1 | 1183 | #!/usr/bin/env python3
# To run the tests, use: python3 -m pytest --capture=sys
from pokemonterminal.database import Database
from tests.test_utils import expected_len
def broken_test_extra_length(region_name='extra'):
assert len(Database().get_extra()) == expected_len(region_name)
def broken_test_kanto_lengt... | gpl-3.0 | 5,885,401,772,013,508,000 | 29.333333 | 68 | 0.710904 | false |
CFIS-Octarine/octarine | src/daomop/wcs.py | 1 | 12869 | import warnings
from copy import deepcopy
from astropy.units import Quantity
import math
from astropy import wcs as astropy_wcs
from astropy import units
import numpy
import logging
__author__ = "David Rusk <drusk@uvic.ca>"
PI180 = 57.2957795130823208767981548141052
class WCS(astropy_wcs.WCS):
def __init__(self, ... | gpl-3.0 | 2,123,899,054,085,605,400 | 26.794816 | 93 | 0.477737 | false |
afrubin/FQRead | docs/conf.py | 1 | 8421 | # -*- coding: utf-8 -*-
#
# FQRead documentation build configuration file, created by
# sphinx-quickstart on Wed Aug 6 13:49:02 2014.
#
# 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.
#
# Al... | mit | 7,981,866,955,841,524,000 | 30.421642 | 79 | 0.705261 | false |
googleapis/java-bigquery | synth.py | 1 | 1127 | # Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, s... | apache-2.0 | 7,252,506,326,706,707,000 | 34.21875 | 74 | 0.735581 | false |
mosra/m.css | plugins/m/link.py | 1 | 2187 | #
# This file is part of m.css.
#
# Copyright © 2017, 2018, 2019, 2020 Vladimír Vondruš <mosra@centrum.cz>
#
# 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, inc... | mit | -436,906,536,956,411,650 | 38.709091 | 78 | 0.722527 | false |
dagwieers/ansible | lib/ansible/modules/cloud/google/gcp_storage_bucket.py | 1 | 44498 | #!/usr/bin/python
# -*- coding: utf-8 -*-
#
# Copyright (C) 2017 Google
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
# ----------------------------------------------------------------------------
#
# *** AUTO GENERATED CODE *** AUTO GENERATED CODE ***
#
... | gpl-3.0 | -5,727,255,997,407,053,000 | 34.120758 | 151 | 0.593802 | false |
TheModMaker/shaka-player | build/check.py | 1 | 6755 | #!/usr/bin/env python
#
# 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 requir... | apache-2.0 | 7,833,908,527,984,224,000 | 30.418605 | 80 | 0.691192 | false |
ContributeToScience/participant-booking-app | booking/core/ip2geo/__init__.py | 1 | 10628 | import math
import mmap
import gzip
import os
import codecs
import pytz
import const
from util import ip2long
from timezone import time_zone_by_country_and_region
MMAP_CACHE = const.MMAP_CACHE
MEMORY_CACHE = const.MEMORY_CACHE
STANDARD = const.STANDARD
class GeoIPError(Exception):
pass
class GeoIPMetaclass(t... | gpl-2.0 | -1,734,714,524,999,281,000 | 31.604294 | 117 | 0.5414 | false |
VirusTotal/vt-graph-api | tests/test_search.py | 1 | 25999 | """Test search VTGraph methods."""
import pytest
import six
import vt_graph_api
try:
from unittest.mock import call
from unittest.mock import Mock
import urllib.parse as urlparse
except ImportError:
from mock import call
from mock import Mock
import urlparse
test_graph = vt_graph_api.VTGraph(
"Dumm... | apache-2.0 | 9,134,466,188,610,243,000 | 32.764935 | 79 | 0.456402 | false |
afein/docker-microservice | service/service.py | 1 | 3362 | from flask import Flask, request, abort
import os
import time
import random
import requests
app = Flask("microservice")
service_name = os.environ["SERVICE_NAME"]
log = open("/var/log/micro/" + service_name + ".log", "w+")
requestID_counter = 1
def busy_wait(seconds):
dt = time.strptime(str(seconds), "%S")
... | apache-2.0 | -9,102,237,164,221,150,000 | 28.491228 | 91 | 0.516359 | false |
clems71/pogle | pyassimp/structs.py | 1 | 34579 | #-*- coding: UTF-8 -*-
from ctypes import POINTER, c_void_p, c_int, c_uint, c_char, c_float, Structure, c_char_p, c_double, c_ubyte, c_size_t, c_uint32
class Vector2D(Structure):
"""
See 'aiVector2D.h' for details.
"""
_fields_ = [
("x", c_float),("y", c_float),
]
class Matrix... | mit | -883,316,027,591,678,700 | 37.027503 | 128 | 0.541109 | false |
gzamboni/sdnResilience | loxi/of11/action.py | 1 | 47031 | # Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University
# Copyright (c) 2011, 2012 Open Networking Foundation
# Copyright (c) 2012, 2013 Big Switch Networks, Inc.
# See the file LICENSE.pyloxi which should have been included in the source distribution
# Automatically generated by LOXI from ... | gpl-2.0 | 5,950,182,360,299,091,000 | 27.297834 | 88 | 0.512534 | false |
jakeharding/repo-health | repo_health/gh_issues/serializers/GhIssueStatsSerializer.py | 1 | 4835 | """
GhIssueStatsSerializer.py - (C) Copyright - 2017
This software is copyrighted to contributors listed in CONTRIBUTIONS.md.
SPDX-License-Identifier: MIT
Author(s) of this file:
J. Harding
Serializer for issue stats of a GitHub repo.
"""
import datetime
from rest_framework import serializers as s
from ..models i... | mit | -7,466,337,894,348,510,000 | 41.052174 | 132 | 0.658945 | false |
wanghongjuan/crosswalk-test-suite | misc/sampleapp-android-tests/sampleapp/webgl_uninstall.py | 1 | 2600 | #!/usr/bin/env python
#
# Copyright (c) 2015 Intel Corporation.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
#
# * Redistributions of works must retain the original copyright notice, this
# list of conditions and t... | bsd-3-clause | 6,075,899,156,710,533,000 | 43.067797 | 108 | 0.693077 | false |
yhilpisch/dx | dx/plot.py | 1 | 5805 | #
# DX Analytics
# Helper Function for Plotting
# dx_plot.py
#
# DX Analytics is a financial analytics library, mainly for
# derviatives modeling and pricing by Monte Carlo simulation
#
# (c) Dr. Yves J. Hilpisch
# The Python Quants GmbH
#
# This program is free software: you can redistribute it and/or modify
# it unde... | agpl-3.0 | -1,432,545,182,039,051,300 | 30.042781 | 79 | 0.604134 | false |
all-of-us/raw-data-repository | rdr_service/lib_fhir/fhirclient_4_0_0/models/range.py | 1 | 1470 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# Generated from FHIR 4.0.0-a53ec6ee1b (http://hl7.org/fhir/StructureDefinition/Range) on 2019-05-07.
# 2019, SMART Health IT.
from . import element
class Range(element.Element):
""" Set of values bounded by low and high.
A set of ordered Quantities defi... | bsd-3-clause | 917,025,002,437,808,800 | 29 | 102 | 0.6 | false |
ging/python-keystoneclient | keystoneclient/auth/identity/v3.py | 1 | 13078 | # Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under t... | apache-2.0 | -5,012,167,486,128,561,000 | 38.391566 | 79 | 0.61829 | false |
TheGoldLab/Lab-Matlab-Control | modularTasks/utilities/readPupilLabsData.py | 1 | 1388 | import sys
import scipy.io as scpy
import numpy as np
import msgpack
from file_methods import *
#Python Script to read Eye Data, extract desired information and then create a .mat structure where rows are times, columns are:
# 1. timestamp
# 2. gaze x
# 3. gaze y
# 4. confidence
#input:
#... | apache-2.0 | -4,823,258,720,058,868,000 | 32.071429 | 128 | 0.608069 | false |
jgeewax/googlepersonfinder | app/photo.py | 1 | 1131 | #!/usr/bin/python2.5
# Copyright 2010 Google 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 ... | apache-2.0 | 5,566,294,216,070,481,000 | 32.264706 | 74 | 0.71176 | false |
AdrianGaudebert/elmo | lib/auth/backends.py | 1 | 9276 | # 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 ldap
from ldap.filter import filter_format
from django.conf import settings
from django.contrib.auth.models impor... | mpl-2.0 | -8,468,056,727,729,221,000 | 34.953488 | 79 | 0.559077 | false |
ambyte/Vertaler | src/modules/httprequest.py | 1 | 1619 | # -*- coding: utf-8 -*-
# ----------------------------------------------------------------------------
# Copyright (c) 2011 Sergey Gulyaev <astraway@gmail.com>
#
# This file is part of Vertaler.
#
# Vertaler is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License ... | gpl-2.0 | -4,815,225,284,546,109,000 | 41.631579 | 118 | 0.64546 | false |
Railk/T3S | Typescript.py | 1 | 23768 | # coding=utf8
import sublime
import sublime_plugin
from queue import Queue
from threading import Thread
from subprocess import Popen, PIPE
import subprocess
import os
import json
import re
import sys
# --------------------------------------- CONSTANT -------------------------------------- #
dirname = os.path.dirnam... | mit | 4,896,523,224,958,104,000 | 25.310421 | 161 | 0.64491 | false |
fsquillace/pycious | tests/rc.py | 1 | 2263 | #!/usr/bin/python
from __future__ import division
from pycious.widgets.system import BatteryTextWidget, DateTextWidget, CPUGraphWidget
from pycious.widgets.web import MailTextWidget, GrssTextWidget
from pycious.api.timer import Timer
from pycious.api.widget import ImageBoxWidget
if __name__ == "__main__":
# ... | gpl-2.0 | 4,042,621,580,200,080,400 | 32.294118 | 84 | 0.526734 | false |
barneygale/barneymc | barneymc/protocol/packet.py | 1 | 1741 | from time import gmtime, strftime
from data_types import *
from packet_structs import *
import packet_extensions
class Packet:
def __init__(self, **kargs):
self.ident = kargs.get('ident', 0)
self.direction = kargs.get('direction', CLIENT_TO_SERVER)
self.data = kargs.get('data', {}... | mit | -6,908,231,330,771,204,000 | 31.240741 | 106 | 0.569787 | false |
openaid-IATI/OIPA | OIPA/api/codelist/views.py | 1 | 4510 | from django.apps import apps
from django.core.exceptions import FieldError
from rest_framework.exceptions import NotFound
from rest_framework.filters import OrderingFilter
from rest_framework_extensions.cache.mixins import CacheResponseMixin
from api.codelist.filters import AllDjangoFilterBackend
from api.codelist.ser... | agpl-3.0 | -3,173,719,476,157,136,400 | 29.680272 | 78 | 0.64745 | false |
sfu-fas/coursys | oldcode/management/commands/crim_import.py | 1 | 5753 | from django.core.management.base import BaseCommand
from django.db import transaction
from django.core.files import File
from optparse import make_option
import csv
import datetime
import os.path
import mimetypes
from advisornotes.models import AdvisorNote
from coredata.models import Person, Unit
from coredata.queries... | gpl-3.0 | 9,127,078,747,302,222,000 | 34.085366 | 114 | 0.566661 | false |
aligoren/pyalgo | evolutionary_algo.py | 1 | 1389 | from string import letters
from random import choice, random
target = list("METHINKS IT IS LIKE A WEASEL")
charset = letters + ' '
parent = [choice(charset) for _ in range(len(target))]
minmutaterate = .09
C = range(100)
perfectfitness = float(len(target))
def fitness(trial):
'Sum of matching chars by positio... | mit | 556,866,754,575,191,800 | 28.553191 | 88 | 0.637869 | false |
openstack/python-glanceclient | glanceclient/tests/unit/test_progressbar.py | 1 | 3006 | # Copyright 2013 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 | -22,959,252,073,428,704 | 35.658537 | 78 | 0.597804 | false |
aykut/django-oscar | oscar/apps/product/reviews/abstract_models.py | 1 | 5476 | from django.db import models
from django.utils.translation import gettext as _
from django.core.urlresolvers import reverse
from django.core.exceptions import ValidationError
from django.conf import settings
from django.db.models import Sum, Count
from oscar.apps.product.reviews.managers import (ApprovedReviewsManage... | bsd-3-clause | -6,377,473,219,612,442,000 | 38.395683 | 109 | 0.643718 | false |
mozilla/kitchensinkserver | kitchensink/device/models.py | 1 | 1115 | """
device.models
-------------
"""
import logging
from django.db import models
from kitchensink.base.models import BaseModel
from kitchensink.device.managers import MakeManager
_log = logging.getLogger('kss.%s' % __name__)
class Make(BaseModel):
""" Which company made the device (i.e. LG)
"""
objects ... | bsd-3-clause | 6,497,167,644,692,732,000 | 20.037736 | 68 | 0.610762 | false |
dwavesystems/dimod | dimod/sampleset.py | 1 | 63014 | # Copyright 2018 D-Wave Systems 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... | apache-2.0 | 2,160,505,098,050,896,100 | 36.86899 | 132 | 0.521233 | false |
upconsulting/IsisCB | isiscb/isisdata/migrations/0076_auto_20180601_1948.py | 1 | 7720 | # -*- coding: utf-8 -*-
# Generated by Django 1.11.10 on 2018-06-01 19:48
from __future__ import unicode_literals
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
migrations.swappable_depend... | mit | 1,103,525,495,658,646,800 | 57.484848 | 210 | 0.605829 | false |
jobscry/vz-wiki | vz_wiki/admin.py | 1 | 1672 | from django.contrib import admin
from models import WikiPage, Revision, Comparison
def latest_revision_display(obj):
latest_revision = obj.latest_revision()
if latest_revision is None:
return '0'
return u'%s' % latest_revision.number
latest_revision_display.short_description = 'Version'
def who_... | mit | -6,895,925,225,505,879,000 | 29.962963 | 76 | 0.73445 | false |
xSAVIKx/PRESENT-cipher | gmac/util/galue_fields.py | 1 | 3561 | # Author: Joao H de A Franco (jhafranco@acm.org)
#
# Description: Binary finite field multiplication in Python 3
#
# Date: 2012-02-16
#
# License: Attribution-NonCommercial-ShareAlike 3.0 Unported
# (CC BY-NC-SA 3.0)
# ===========================================================
from functools import reduce
# ... | apache-2.0 | 7,770,864,948,732,986,000 | 28.92437 | 89 | 0.505757 | false |
penguintutor/networking-quiz | src/quizapp.py | 1 | 12224 | # This uses the dev branch of guizero which needs to be linked to the appropriate
# directory - in future this will use the normal production version of guizero
from guizero.build.lib.guizero import App, Text, PushButton, info, MenuBar, Picture, yesno
import quizdetails
# For testing the gui without the arduino comme... | gpl-3.0 | 7,559,067,779,343,305,000 | 39.343234 | 151 | 0.590396 | false |
cellular-nanoscience/pyotic | pyoti/modification/modification.py | 1 | 26859 | # -*- coding: utf-8 -*-
"""
Created on Fri Feb 12 14:22:31 2016
@author: Tobias Jachowski
"""
import collections
import matplotlib.pyplot as plt
import numpy as np
from abc import ABCMeta, abstractmethod
from .. import gui
from .. import helpers as hp
from .. import traces as tc
from ..evaluate import signal as sn
fr... | apache-2.0 | -1,852,494,407,888,080,000 | 37.757576 | 82 | 0.601102 | false |
dougbenjamin/panda-harvester | pandaharvester/harvestermisc/apfmon.py | 1 | 16445 | """
API described here: http://apfmon.lancs.ac.uk/help
"""
import requests
import json
import time
import traceback
from pandaharvester.harvesterconfig import harvester_config
from pandaharvester.harvestercore import core_utils
from pandaharvester import panda_pkg_info
from pandaharvester.harvestermisc import generic... | apache-2.0 | 1,477,390,547,732,146,700 | 38.24821 | 272 | 0.515172 | false |
willingc/gentledocs | config/settings/common.py | 1 | 8186 | # -*- coding: utf-8 -*-
"""
Django settings for Gentle Docs project.
For more information on this file, see
https://docs.djangoproject.com/en/dev/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/dev/ref/settings/
"""
from __future__ import absolute_import, unicode... | bsd-3-clause | 7,349,928,663,983,266,000 | 34.903509 | 98 | 0.607256 | false |
kipe/miplant | miplant/miplant.py | 1 | 4030 | # -*- encoding: utf-8 -*-
from bluepy import btle
import logging
from math import isnan
class MiPlant(object):
def __init__(self, address, interface_index=0):
'''
Initializes the MiPlant -object.
Parameters
----------
address : string
The MAC-address of the dev... | mit | -1,960,080,027,998,492,200 | 30.724409 | 155 | 0.573591 | false |
monikagrabowska/osf.io | kinto/kinto/core/errors.py | 1 | 7950 | import six
from pyramid import httpexceptions
from enum import Enum
from kinto.core.logs import logger
from kinto.core.utils import json, reapply_cors, encode_header
class ERRORS(Enum):
"""Predefined errors as specified by the API.
+-------------+-------+------------------------------------------------+
... | apache-2.0 | -8,970,654,734,963,827,000 | 40.19171 | 84 | 0.470189 | false |
apophys/freeipa | ipatests/test_ipapython/test_session_storage.py | 1 | 1069 | #
# Copyright (C) 2017 FreeIPA Contributors see COPYING for license
#
"""
Test the `session_storage.py` module.
"""
import pytest
from ipapython import session_storage
@pytest.mark.skip_ipaclient_unittest
@pytest.mark.needs_ipaapi
class test_session_storage(object):
"""
Test the session storage interface
... | gpl-3.0 | 8,177,739,086,821,916,000 | 25.725 | 71 | 0.638915 | false |
natukikazemizo/sedna | Sedna/src/python/recasting/grep_object.py | 1 | 5780 | #!BPY
# -*- coding: UTF-8 -*-
# Set IK Limits
#
# 2016.01.17 Natukikazemizo
import bpy
import math
import re
# Using Regular expression
#"[0]" 1文字が0
#"[0-9]" 1文字が0,1,2,3,4,5,6,7,8,9のいずれか
#"[02468]" 1文字が偶数
#"[BCD]" 1文字がB,C,Dのいずれか
#"[B-D]" 1文字がB,C,Dのいずれか
#"[0-2A-C]" 1文字が0,1,2,A,B,Cのいずれか
#"[^12]" 1文字が1,2以外
#"\w" 1文字が英数字
... | mit | 7,223,568,034,813,345,000 | 27.887218 | 117 | 0.598126 | false |
702nADOS/sumo | tools/contributed/sumopy/coremodules/network/network.py | 1 | 164969 | # size limit at 1280x1280
# http://maps.googleapis.com/maps/api/staticmap?size=500x500&path=color:0x000000|weight:10|44.35789,11.3093|44.4378,11.3935&format=GIF&maptype=satellite&scale=2
import os
import sys
import subprocess
import platform
from xml.sax import saxutils, parse, handler
if __name__ == '__main__':
... | gpl-3.0 | -8,687,516,388,149,125,000 | 42.039134 | 255 | 0.470337 | false |
fatherlinux/atomic-reactor | tests/plugins/test_import_image.py | 1 | 5039 | """
Copyright (c) 2015 Red Hat, Inc
All rights reserved.
This software may be modified and distributed under the terms
of the BSD license. See the LICENSE file for details.
"""
from __future__ import unicode_literals
import json
import os
from atomic_reactor.core import DockerTasker
from atomic_reactor.inner import... | bsd-3-clause | -6,431,589,620,434,505,000 | 24.321608 | 79 | 0.642985 | false |
firemark/grazyna | grazyna/tests/test_request.py | 1 | 2043 | from grazyna.request import RequestBot
from grazyna.test_mocks.sender import SayMessage, Message
from grazyna.irc.models import User
def make_bot(protocol, **kwargs):
return RequestBot(protocol, user=User('socek!a@b'), chan='#czarnobyl', **kwargs)
def test_init(protocol):
bot = RequestBot(protocol)
asse... | gpl-2.0 | 3,544,072,557,143,436,300 | 25.881579 | 89 | 0.669114 | false |
citrix-openstack/nodepool | nodepool/provider_manager.py | 1 | 22543 | #!/usr/bin/env python
# Copyright (C) 2011-2013 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 ... | apache-2.0 | 4,222,597,944,849,373,000 | 35.418417 | 79 | 0.576764 | false |
a10networks/acos-client | acos_client/v30/slb/virtual_server.py | 1 | 5582 | # Copyright 2014-2016, A10 Networks.
#
# 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 o... | apache-2.0 | -5,504,389,639,245,075,000 | 48.839286 | 115 | 0.626478 | false |
tumluliu/tracks-rest-api | tracksdb.py | 1 | 3636 | """
ORM definitions for mapping tracks data stored in PostgreSQL database
"""
from sqlalchemy import create_engine, Column, Integer, Float, String
from sqlalchemy.dialects.postgresql import INTERVAL, TIMESTAMP
from sqlalchemy.orm import sessionmaker, scoped_session
from sqlalchemy.ext.declarative import declarative_ba... | mit | -7,546,321,651,937,122,000 | 37.680851 | 80 | 0.637514 | false |
fabiking/plugin.video.fabiking | resources/tools/epg_formulatv.py | 1 | 24493 | # -*- coding: utf-8 -*-
#------------------------------------------------------------
# PalcoTV EPG FórmulaTV.com
# License: GPL (http://www.gnu.org/licenses/gpl-3.0.html)
#------------------------------------------------------------
# Gracias a la librería plugintools de Jesús (www.mimediacenter.info)
#---------------... | gpl-2.0 | -6,917,189,217,825,973,000 | 41.670157 | 336 | 0.590798 | false |
j00bar/django-widgy | widgy/contrib/urlconf_include/tests.py | 1 | 5207 | import imp
import django
from django.test import TestCase
from django.test.client import RequestFactory
from django.utils.decorators import decorator_from_middleware
from django.http import HttpResponse, HttpResponseNotFound
from django.core import urlresolvers
from django.contrib.auth.models import AnonymousUser
from... | apache-2.0 | 7,117,233,488,581,188,000 | 30.36747 | 94 | 0.645861 | false |
raulperula/python_tutorials | tutorial-pygame/src/example18.py | 1 | 2277 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
from django.utils.termcolors import background
__author__ = "Raul Perula-Martinez"
__date__ = "2015-01"
__version__ = "$ Revision: 1.0 $"
import pygame
class Player(pygame.sprite.Sprite):
def __init__(self, image):
self.image = image
self.rect = sel... | gpl-3.0 | -8,708,156,146,956,355,000 | 24.021978 | 57 | 0.515591 | false |
jelly/calibre | src/calibre/ebooks/oeb/reader.py | 1 | 28670 | """
Container-/OPF-based input OEBBook reader.
"""
from __future__ import with_statement
__license__ = 'GPL v3'
__copyright__ = '2008, Marshall T. Vandegrift <llasram@gmail.com>'
import sys, os, uuid, copy, re, cStringIO
from itertools import izip
from urlparse import urldefrag, urlparse
from urllib import unquote ... | gpl-3.0 | -4,345,886,397,232,031,000 | 38.599448 | 99 | 0.518242 | false |
openstack/tooz | tooz/partitioner.py | 1 | 3970 | # -*- coding: utf-8 -*-
#
# Copyright (C) 2016 Red Hat, 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 r... | apache-2.0 | -8,275,849,643,799,480,000 | 39.927835 | 78 | 0.631234 | false |
Spotipo/spotipo | tests/modules/analytics/test_methods.py | 1 | 1724 | import sys
import pytest
from flask import current_app,url_for
from flask_wtf import Form
from wtforms import TextField
from faker import Faker
import arrow
import uuid
import stripe
from unifispot.core.models import Wifisite,Device,Guesttrack,Guest
from unifispot.core.guestutils import init_track,validate_track,redi... | agpl-3.0 | 1,730,948,159,544,591,600 | 27.75 | 78 | 0.678654 | false |
thinkopensolutions/tkobr-addons | tko_br_delivery_sale_stock/models/sale.py | 1 | 1879 |
from odoo import models, api, _
from odoo.exceptions import UserError
class SaleOrder(models.Model):
_inherit ='sale.order'
# do not create delivery line but set the value in total_frete
@api.multi
def delivery_set(self):
# Remove delivery products from the sale order
self._delivery_... | agpl-3.0 | -3,344,389,447,532,597,000 | 42.697674 | 110 | 0.566791 | false |
deeplook/svglib | tests/test_samples.py | 1 | 16463 | #!/usr/bin/env python
"""Testsuite for svglib.
This tests conversion of sample SVG files into PDF files.
Some tests try using a tool called uniconv (if installed)
to convert SVG files into PDF for comparision with svglib.
Read ``tests/README.rst`` for more information on testing!
"""
import os
import glob
import re... | lgpl-3.0 | -2,501,537,814,356,397,600 | 36.162528 | 91 | 0.568183 | false |
horazont/aioxmpp | aioxmpp/shim/__init__.py | 1 | 1907 | ########################################################################
# File name: __init__.py
# This file is part of: aioxmpp
#
# LICENSE
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as
# published by the Free Software Foundat... | lgpl-3.0 | 6,548,399,703,151,503,000 | 28.796875 | 75 | 0.639748 | false |
blueskycoco/rtt | bsp/mini2440/rtconfig.py | 1 | 2546 | import os
# panel options
# 'PNL_A70','PNL_N35', 'PNL_T35' , 'PNL_X35'
RT_USING_LCD_TYPE = 'PNL_T35'
# toolchains options
ARCH = 'arm'
CPU = 's3c24x0'
TextBase = '0x30000000'
CROSS_TOOL = 'keil'
if os.getenv('RTT_CC'):
CROSS_TOOL = os.getenv('RTT_CC')
if CROSS_TOOL == 'gcc':
PLATFORM = 'gcc'
... | gpl-2.0 | -6,611,863,965,330,386,000 | 24.717172 | 179 | 0.536135 | false |
bigswitch/snac-nox | src/nox/apps/directory/dm_ws_groups.py | 1 | 18122 | # Copyright 2008 (C) Nicira, Inc.
#
# This file is part of NOX.
#
# NOX 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.
#
# NOX is dist... | gpl-3.0 | 8,808,889,502,028,325,000 | 45.706186 | 96 | 0.539676 | false |
laurentgo/pants | src/python/pants/backend/jvm/tasks/classpath_products.py | 1 | 3952 | # coding=utf-8
# Copyright 2015 Pants project contributors (see CONTRIBUTORS.md).
# Licensed under the Apache License, Version 2.0 (see LICENSE).
from __future__ import (absolute_import, division, generators, nested_scopes, print_function,
unicode_literals, with_statement)
import os
from pant... | apache-2.0 | -8,199,300,134,605,323,000 | 44.425287 | 99 | 0.672824 | false |
MartinThoma/PyMySQL | pymysql/connections.py | 1 | 53902 | # Python implementation of the MySQL client-server protocol
# http://dev.mysql.com/doc/internals/en/client-server-protocol.html
# Error codes:
# http://dev.mysql.com/doc/refman/5.5/en/error-messages-client.html
from __future__ import print_function
from ._compat import PY2, range_type, text_type, str_type, JYTHON, IRON... | mit | -927,726,751,287,593,100 | 35.793174 | 134 | 0.575841 | false |
elbeardmorez/quodlibet | quodlibet/quodlibet/player/xinebe/player.py | 1 | 12177 | # -*- coding: utf-8 -*-
# Copyright 2006-2007 Lukas Lalinsky
#
# 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.
from gi.... | gpl-2.0 | -3,936,165,923,608,529,000 | 34.920354 | 79 | 0.581506 | false |
mihaip/readerisdead | reader_archive/reader_archive.py | 1 | 21719 | import argparse
import itertools
import json
import logging
import os.path
import urllib
import urllib2
import sys
import xml.etree.cElementTree as ET
import base.api
import base.atom
import base.log
import base.tag_helper
import base.url_fetcher
import base.worker
def main():
base.log.init()
base.atom.init()
... | apache-2.0 | 8,641,984,040,435,914,000 | 39.672285 | 81 | 0.648833 | false |
luzheqi1987/nova-annotation | nova/tests/unit/api/openstack/compute/contrib/test_cloudpipe.py | 1 | 8260 | # 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,797,628,048,734,600,000 | 38.333333 | 78 | 0.602663 | false |
krieghan/kobold_python | kobold/tests/test_swap.py | 1 | 3135 | import asyncio
import unittest
from kobold import (
assertions,
compare,
doubles,
swap)
class Host(object):
def subject(self, arg, kwarg=None):
return "original subject"
async def subject_cr(self, arg, kwarg=None):
return "original subject"
class TestInstallP... | mit | 5,797,207,600,288,745,000 | 26.5 | 74 | 0.540032 | false |
carlini/cleverhans | examples/multigpu_advtrain/utils_cifar.py | 1 | 5805 | """
https://github.com/renmengye/revnet-public/blob/master/resnet/data/cifar_input.py
MIT License
Copyright (c) 2017 Mengye Ren
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 restrictio... | mit | 5,248,748,673,369,022,000 | 31.982955 | 81 | 0.681137 | false |
tensorflow/tfx | tfx/benchmarks/benchmark_utils.py | 1 | 1823 | # Copyright 2019 Google LLC. 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 | -6,241,290,098,297,118,000 | 30.982456 | 78 | 0.721338 | false |
felexx90/service.subtitles.subdivx | service.py | 1 | 21861 | # -*- coding: utf-8 -*-
# Subdivx.com subtitles, based on a mod of Undertext subtitles
# Adaptation: enric_godes@hotmail.com | Please use email address for your
# comments
# Port to XBMC 13 Gotham subtitles infrastructure: cramm, Mar 2014
from __future__ import print_function
from json import loads
import os
from os.p... | gpl-2.0 | 526,871,402,262,129,540 | 35.551839 | 562 | 0.57965 | false |
anandpdoshi/erpnext | erpnext/manufacturing/doctype/production_planning_tool/production_planning_tool.py | 1 | 17777 | # Copyright (c) 2015, Frappe Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe
from frappe.utils import cstr, flt, cint, nowdate, add_days, comma_and
from frappe import msgprint, _
from frappe.model.document import ... | agpl-3.0 | -849,179,727,550,764,800 | 35.805383 | 120 | 0.660179 | false |
uwosh/uwosh.emergency.client | uwosh/emergency/client/tests.py | 1 | 1484 | import unittest
from zope.testing import doctestunit
from zope.component import testing
from Testing import ZopeTestCase as ztc
from Products.Five import zcml
from Products.Five import fiveconfigure
from Products.PloneTestCase import PloneTestCase as ptc
from Products.PloneTestCase.layer import PloneSite
ptc.setupPlo... | gpl-2.0 | 6,942,139,128,027,517,000 | 26.481481 | 61 | 0.645553 | false |
joshmoore/openmicroscopy | components/tools/OmeroWeb/omeroweb/webgateway/webgateway_cache.py | 1 | 30403 | #
# webgateway/webgateway_cache - web cache handler for webgateway
#
# Copyright (c) 2008, 2009 Glencoe Software, Inc. All rights reserved.
#
# This software is distributed under the terms described by the LICENCE file
# you can find at the root of the distribution bundle, which states you are
# free to use it only f... | gpl-2.0 | 1,907,028,645,191,416,800 | 34.476079 | 119 | 0.516791 | false |
johnlb/strange_wp | strange_bak/tests/test_text.py | 1 | 25260 | # coding: utf-8
"""
weasyprint.tests.test_text
--------------------------
Test the text layout.
:copyright: Copyright 2011-2014 Simon Sapin and contributors, see AUTHORS.
:license: BSD, see LICENSE for details.
"""
from __future__ import division, unicode_literals
from ..css impor... | gpl-3.0 | -650,783,121,996,463,400 | 31.103811 | 78 | 0.540211 | false |
bolkedebruin/airflow | tests/providers/amazon/aws/operators/test_s3_copy_object.py | 1 | 4133 | # -*- coding: utf-8 -*-
#
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
#... | apache-2.0 | 2,913,947,881,592,704,000 | 45.438202 | 86 | 0.620615 | false |
consultit/Ely | ely/direct/data_structures_and_algorithms/ch12/decorated_merge_sort.py | 1 | 1681 | # Copyright 2013, Michael H. Goldwasser
#
# Developed for use with the book:
#
# Data Structures and Algorithms in Python
# Michael T. Goodrich, Roberto Tamassia, and Michael H. Goldwasser
# John Wiley & Sons, 2013
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of... | lgpl-3.0 | -2,266,771,482,216,979,700 | 38.093023 | 86 | 0.654967 | false |
rplevka/robottelo | tests/foreman/sys/test_rename.py | 1 | 10708 | """Test class for ``katello-change-hostname``
:Requirement: katello-change-hostname
:CaseAutomation: Automated
:CaseLevel: System
:CaseComponent: satellite-change-hostname
:Assignee: pondrejk
:TestType: Functional
:CaseImportance: High
:Upstream: No
"""
import pytest
from fauxfactory import gen_string
from nai... | gpl-3.0 | 1,660,779,668,490,670,600 | 38.080292 | 95 | 0.590493 | false |
kalhartt/dnestpy | examples/example_uistring.py | 1 | 1067 | #!/usr/bin/python2.7
import sqlalchemy as sqla
import codecs, re
uistring = '/mnt/500G/Games/dragonnest/extract/resource/uistring/uistring.xml'
message_re = re.compile(r'<message mid="(\d+)"><!\[CDATA\[(.+)\]\]></message>', re.UNICODE|re.DOTALL)
def readlines(f, bufsize):
buf = u''
data = True
while data:... | gpl-2.0 | 7,095,719,596,313,183,000 | 31.333333 | 101 | 0.621368 | false |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.