text
stringlengths
6
947k
repo_name
stringlengths
5
100
path
stringlengths
4
231
language
stringclasses
1 value
license
stringclasses
15 values
size
int64
6
947k
score
float64
0
0.34
import vdf import urllib2 import json import time import shelve filters = ['basic','genres'] URL_BASE = 'http://store.steampowered.com/api/appdetails?appids=' FILTERS = '&filters=' + ','.join(filters) OWNED_GAMES_URL = 'http://api.steampowered.com/IPlayerService/GetOwnedGames/v0001/?key=' ERR_STR = '\t'*4 + 'Error:...
itsWeller/SteamCategorizer
categorizer.py
Python
mit
2,724
0.008811
from django.conf.urls import patterns, include, url urlpatterns = patterns( '', url(r'^api/', include('api.urls')), url(r'^', include('base.urls')) )
tedle/acdb
acdb/acdb/urls.py
Python
mit
163
0
import numpy as np import scipy.linalg as la def calculate_vertex_normals(verts, tris): v_array = np.array(verts) tri_array = np.array(tris, dtype=int) tri_pts = v_array[tri_array] n = np.cross( tri_pts[:,1] - tri_pts[:,0], tri_pts[:,2] - tri_pts[:,0]) v_normals = np.zeros(v_...
jfozard/pyvol
pyvol/mesh/algo.py
Python
mit
602
0.026578
#!/usr/bin/env python # -*- coding: utf-8 -*- # # nukebox2000 documentation build configuration file, created by # sphinx-quickstart on Tue Jul 9 22:26:36 2013. # # This file is execfile()d with the current directory set to its # containing dir. # # Note that not all possible configuration values are present in this #...
k1nk33/NukeBox2000
docs/conf.py
Python
mit
8,447
0.005327
# 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 ...
lmazuel/azure-sdk-for-python
azure-mgmt-compute/azure/mgmt/compute/v2017_12_01/models/disk_encryption_settings.py
Python
mit
1,716
0.001166
# encoding: cinje : import traceback : from marrow.package.canonical import name : log = __import__('logging').getLogger(__name__) : def render_page_panel context, page, wrap : from web.component.asset.render import render_asset_panel : using render_asset_panel context, page, True <li class="list-group-item" id...
marrow/web.component.page
web/component/page/render.py
Python
mit
3,059
0.037267
#!/usr/bin/env python # Copyright (C) 2006-2021 Music Technology Group - Universitat Pompeu Fabra # # This file is part of Essentia # # Essentia is free software: you can redistribute it and/or modify it under # the terms of the GNU Affero General Public License as published by the Free # Software Foundation (FSF), e...
MTG/essentia
test/src/unittests/stats/test_minmax.py
Python
agpl-3.0
2,805
0.001783
from database.db_sql import db_sql as db from sqlalchemy import PrimaryKeyConstraint from itsdangerous import (TimedJSONWebSignatureSerializer as Serializer, BadSignature, SignatureExpired) from flask import current_app from . import passwords import time from sqlalchemy.orm import relationshi...
soybean217/lora-python
UServer/userver/user/models.py
Python
mit
4,041
0.002475
import socket import android droid = android.Android() servidor = droid.dialogGetInput('Servidor', 'Ingrese el Servidor').result server = socket.socket(socket.AF_INET, socket.SOCK_STREAM) #'foxcarlos.no-ip.biz' server.connect((servidor, 8000)) mensaje = droid.dialogGetInput('Mensaje', 'Ingrese el Mensaje a Enviar')...
foxcarlos/pyganso
cliente_socket.py
Python
gpl-3.0
350
0.005714
# pylint: disable=E1101 from __future__ import division import operator import warnings from datetime import time, datetime from datetime import timedelta import numpy as np from pandas.core.base import _shared_docs from pandas.core.dtypes.common import ( _NS_DTYPE, _INT64_DTYPE, is_object_dtype, is_datetime64...
Winand/pandas
pandas/core/indexes/datetimes.py
Python
bsd-3-clause
79,180
0.000025
#!/bin/env python import sys import os args = sys.argv[1:] files = args[0:-1] newdir = args[-1] for file in files: cmd = "svn mv %s %s/" % (file,newdir) print cmd os.system(cmd)
chryswoods/Sire
corelib/build/svnmvall.py
Python
gpl-2.0
200
0.01
"""unset a default setting unset config unset target """ from mod import log, settings #------------------------------------------------------------------------------- def run(fips_dir, proj_dir, args) : """run the 'unset' verb""" if len(args) > 0 : noun = args[0] settings.unset(proj_dir, nou...
floooh/fips
verbs/unset.py
Python
mit
705
0.01844
from disco.core import Job from disco.worker.task_io import task_input_stream import hustle import hustle.core import hustle.core.marble from hustle.core.marble import Marble, Column, Aggregation from functools import partial from hustle.core.pipeworker import HustleStage import sys SPLIT = "split" GROUP_ALL = "group_...
txiner/db-xiner
hustle/core/pipeline.py
Python
mit
19,643
0.002851
# -*- Mode:Python; indent-tabs-mode:nil; tab-width:4 -*- # # Copyright (C) 2016 Canonical Ltd # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License version 3 as # published by the Free Software Foundation. # # This program is distributed in the h...
jocave/snapcraft
snapcraft/tests/test_commands_cleanbuild.py
Python
gpl-3.0
3,951
0
# Copyright 2014 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 agreed to in writ...
openstack/python-aodhclient
aodhclient/osc.py
Python
apache-2.0
1,844
0
#coding:utf8 """ yet another logging wrapper - log level logging.CRITICAL, logging.ERROR, logging.WARNING, logging.INFO, logging.DEBUG """ import logging from config import PROJECT_ROOT def configLogger(logFile="spider.log", logLevel=logging.DEBUG, logTree=""): logFile = PROJECT_ROOT+"/log/"+ logF...
zhkzyth/a-super-fast-crawler
logmanager.py
Python
mit
783
0.003995
from django.db import transaction from rest_framework import serializers from questions.models import Question, Choice from votes.models import Vote, VoteChoice from streams.models import Stream from ..accounts.serializers import AccountSerializer class VoteChoiceUserSerializer(serializers.ModelSerializer): use...
ballotify/django-backend
ballotify/apps/api_v1/questions/serializers.py
Python
agpl-3.0
4,502
0.001333
# -*- 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 model 'WombatToken' db.create_table('wombat_authenticator_wombattoken', ( ('id', self.g...
AgainFaster/django-wombat-authenticator
wombat_authenticator/migrations/0001_initial.py
Python
bsd-3-clause
5,385
0.008357
# coding: utf-8 # file generated by setuptools_scm # don't change, don't track in version control version = '6.2.5' version_tuple = (6, 2, 5)
pexip/os-pytest
src/_pytest/_version.py
Python
mit
142
0
# GUI Application automation and testing library # Copyright (C) 2006 Mark Mc Mahon # # This library is free software; you can redistribute it and/or # modify it under the terms of the GNU Lesser General Public License # as published by the Free Software Foundation; either version 2.1 # of the License, or (at you...
manojklm/pywinauto-x64
pywinauto/win32structures.py
Python
lgpl-2.1
32,760
0.004701
from __future__ import absolute_import from django.http import HttpRequest, HttpResponse from typing import Iterable, Optional, Sequence, Text from zerver.lib.events import do_events_register from zerver.lib.request import REQ, has_request_variables from zerver.lib.response import json_success from zerver.lib.validat...
vaidap/zulip
zerver/views/events_register.py
Python
apache-2.0
2,368
0.005912
# -*- coding: utf-8 -*- # Generated by Django 1.10.6 on 2017-03-26 10:54 from __future__ import unicode_literals from django.db import migrations, models import uuid class Migration(migrations.Migration): dependencies = [ ('news', '0001_initial'), ] operations = [ migrations.AddField( ...
helfertool/helfertool
src/news/migrations/0002_person_token.py
Python
agpl-3.0
478
0.002092
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # Code generated by Microsoft (R) AutoRest Code Generator. # Changes may ...
Azure/azure-sdk-for-python
sdk/containerregistry/azure-mgmt-containerregistry/azure/mgmt/containerregistry/v2018_02_01_preview/_configuration.py
Python
mit
3,281
0.004572
from unittest import TestCase from sorting.merge import merge_list, merge_sort, merge_sort_recursive class TestSortingMerge(TestCase): def test_merge_list(self): left = [1, 4, 6] right = [2, 3, 5] result = merge_list(left, right) self.assertEquals(6, len(result)) for i in ...
narfman0/challenges
algorithms/tests/sorting/test_merge.py
Python
gpl-3.0
1,709
0.00117
############################################################################## # # Copyright (C) 2015 ADHOC SA (http://www.adhoc.com.ar) # All Rights Reserved. # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as # pub...
ingadhoc/product
product_management_group/__manifest__.py
Python
agpl-3.0
1,296
0
# 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...
rabipanda/tensorflow
tensorflow/python/tools/saved_model_cli.py
Python
apache-2.0
29,293
0.006111
#!/usr/bin/py import os import sys import shutil import unittest sys.path.append(os.path.abspath('..')) from sample.LazyCF import LazyCF from sample.CodeForces import CodeForces class TestLazyCF(unittest.TestCase): def test__init__(self): lazy_test = LazyCF() self.assertEqual(str(lazy_test.__cla...
filipecn/lazycf
tests/Test_LazyCF.py
Python
mit
1,628
0.001229
# -*- coding: utf-8 -*- from setuptools import setup, find_packages from djangocms_bootstrap3 import __version__ INSTALL_REQUIRES = [] CLASSIFIERS = [ 'Development Status :: 5 - Production/Stable', 'Environment :: Web Environment', 'Framework :: Django', 'Intended Audience :: Developers', 'Licens...
m-mix/djangocms-bootstrap3-grid
setup.py
Python
bsd-2-clause
1,149
0
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors # MIT License. See license.txt # For license information, please see license.txt from __future__ import unicode_literals import webnotes from webnotes import msgprint, _ from webnotes.utils import cint,cstr class DocType: def __init__(self, d, ...
gangadhar-kadam/powapp
selling/doctype/device_group/device_group.py
Python
agpl-3.0
1,071
0.035481
#: Okay # 情 #: W291:1:6 print #: W293:2:1 class Foo(object): bang = 12 #: W291:2:35 '''multiline string with trailing whitespace''' #: W292:1:36 noeol # This line doesn't have a linefeed #: W292:1:5 E225:1:2 noeol 1+ 1 #: W292:1:27 E261:1:12 noeol import this # no line feed #: W292:3:22 noeol class Test(object): ...
urisimchoni/samba
third_party/pep8/testsuite/W29.py
Python
gpl-3.0
367
0.016438
import pytest from hms_irc.commands.agenda import get_instance from hms_irc.commands.tests import build_command @pytest.fixture def instance(irc_server, irc_chan, rabbit): return get_instance(irc_server, irc_chan, rabbit) # Misc def test_commands_available(instance): """Test that all required subcomma...
haum/hms_irc
hms_irc/commands/tests/test_agenda.py
Python
gpl-3.0
4,323
0.000232
# -*- coding: utf-8 -*- # This file is part of wger Workout Manager. # # wger Workout Manager is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any ...
rolandgeider/wger
wger/utils/generic_views.py
Python
agpl-3.0
10,530
0.00095
# -*- coding: utf-8 -*- import os import errno import time import tarfile import shutil import re from utils import * import configuration # a helper class for actual backends class BaseBackend(object): def __init__(self, keep_dirs): self._root_dir = configuration.Configuration.get( 'backen...
wk8/Brive
backend.py
Python
unlicense
8,783
0
import numpy as n, matplotlib.pyplot as p, scipy.special import cosmolopy.perturbation as pb import cosmolopy.density as cd from scipy.integrate import quad,tplquad import itertools from scipy.interpolate import interp1d from scipy.interpolate import RectBivariateSpline as RBS import optparse, sys from sigmas import si...
yunfanz/ReionBub
Choud14/FZH04.py
Python
mit
5,526
0.056279
#!/usr/bin/env python3 import subprocess import sys from os.path import abspath, dirname, join from time import sleep, perf_counter from selenium import webdriver from selenium.webdriver.common.by import By from selenium.webdriver.support.ui import WebDriverWait from selenium.webdriver.support import expected_conditi...
apeschar/webwinkelkeur-virtuemart
test/test.py
Python
gpl-3.0
3,695
0.001083
#!/usr/bin/env python # coding: utf-8 """Unit tests for vtdb.tablet""" import unittest import mock from net import gorpc import utils from vtdb import tablet class TestRPCCallAndExtract(unittest.TestCase): """Tests rpc_call_and_extract_error is tolerant to various responses.""" tablet_conn = tablet.TabletConn...
cgvarela/vitess
test/tablet_test.py
Python
bsd-3-clause
2,879
0.015283
#!/usr/bin/env python """QX100 interfacing code for python""" import json import requests import numpy as np import cv2 import threading from cmd import Cmd class LiveviewThread(threading.Thread): running = True def __init(self, url): threading.Thread.__init__(self) self.url = url self.running = True ...
UCSD-E4E/qx100-interfacing
qx100.py
Python
gpl-2.0
3,536
0.019231
# -*- coding: utf-8 -*- """Setup/installation tests for this package.""" from atrealtheme.alderamin.testing import IntegrationTestCase from plone import api class TestInstall(IntegrationTestCase): """Test installation of atrealtheme.alderamin into Plone.""" def setUp(self): """Custom shared utility ...
atreal/atrealtheme.alderamin
src/atrealtheme/alderamin/tests/test_setup.py
Python
gpl-2.0
1,242
0.003221
#! /usr/bin/env python # vim:ts=4:sw=4:expandtab 2 # -*- coding: utf-8 -*- ''' Based on https://github.com/mortnerDHCPv4v6 ''' # TODO: # * refactor # * read conf from dhclient.conf # * daemonize # * requests in loop # * send renew according to renew time # * implement release # * implement nak case # FIXME: # * bui...
duy/dhcpscapy
scripts/dhcpclientscapy.py
Python
agpl-3.0
11,570
0.005618
from flask.ext.wtf import Form from wtforms import StringField, PasswordField from wtforms.validators import DataRequired, Length, Email class LoginForm(Form): email = StringField(validators=[DataRequired(), Length(1, 64), Email()]) password = PasswordField(validators=[DataRequired()])
simpleapples/light-blog
app/auth/forms/login_form.py
Python
mit
295
0.00678
""" Please forgive any typos or errors in the comments, I'll be cleaning them up as frequently as I can. Pygcurse v0.1 alpha Pygcurse (pronounced "pig curse") is a curses library emulator that runs on top of the Pygame framework. It provides an easy way to create text adventures, roguelikes, and console-style applic...
drestuart/delvelib
lib/pygcurse/pygcurse_old.py
Python
lgpl-3.0
110,209
0.006288
#!/usr/bin/env python # ---------------------------------------------------------------------- # Numenta Platform for Intelligent Computing (NuPIC) # Copyright (C) 2013, Numenta, Inc. Unless you have an agreement # with Numenta, Inc., for a separate license for this software code, the # following terms and conditions ...
passiweinberger/nupic
tests/swarming/nupic/swarming/swarming_test.py
Python
agpl-3.0
101,562
0.009561
# apis_v1/documentation_source/voter_star_on_save_doc.py # Brought to you by We Vote. Be good. # -*- coding: UTF-8 -*- def voter_star_on_save_doc_template_values(url_root): """ Show documentation about voterStarOnSave """ required_query_parameter_list = [ { 'name': 'api_key...
wevote/WebAppPublic
apis_v1/documentation_source/voter_star_on_save_doc.py
Python
bsd-3-clause
4,125
0.003394
# -*- coding: utf-8 -*- # Generated by Django 1.10.7 on 2017-06-20 09:25 from __future__ import unicode_literals from django.db import migrations, models import location_field.models.plain class Migration(migrations.Migration): dependencies = [ ('events', '0005_merge_20170619_1150'), ] operatio...
hinrek/Suvepraktika
events/migrations/0006_auto_20170620_1225.py
Python
mit
1,100
0.001818
# 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 ...
SUSE/azure-sdk-for-python
azure-mgmt-resource/azure/mgmt/resource/subscriptions/v2016_06_01/models/location_paged.py
Python
mit
874
0
#!/usr/bin/python # -*- coding: utf-8 -*- # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) from __future__ import absolute_import, division, print_function __metaclass__ = type ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['preview'], ...
tsdmgz/ansible
lib/ansible/modules/network/aci/aci_bd.py
Python
gpl-3.0
12,055
0.002323
#!/usr/bin/env python # """oocgcm.oceanfuncs.eos.teos10 Equation of state of sea water and related quantities. This module uses the formulas from the Thermodynamic Equation Of Seawater - 2010 (TEOS-10) """
lesommer/oocgcm
oocgcm/oceanfuncs/eos/teos10.py
Python
apache-2.0
209
0.004785
# $Id: cs.py 7119 2011-09-02 13:00:23Z milde $ # Author: Marek Blaha <mb@dat.cz> # Copyright: This module has been placed in the public domain. # New language mappings are welcome. Before doing a new translation, please # read <http://docutils.sf.net/docs/howto/i18n.html>. Two files must be # translated for each lan...
JulienMcJay/eclock
windows/Python27/Lib/site-packages/docutils/parsers/rst/languages/cs.py
Python
gpl-2.0
4,857
0.002059
# 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 u...
ctrlaltdel/neutrinator
vendor/stevedore/enabled.py
Python
gpl-3.0
3,569
0
# -*- coding: utf-8 -*- # # desispec documentation build configuration file, created by # sphinx-quickstart on Tue Dec 9 10:43:33 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. # # ...
desihub/desispec
doc/conf.py
Python
bsd-3-clause
10,086
0.005057
#!/usr/bin/env python import os def create_asm(instruction): if instruction.startswith("main:"): if "ja" in instruction: instruction = "." + instruction #print instruction out = open("temp.asm", "wb") out.write(" " + instruction + "\n") out.close() # --------------------------------- fold her...
mikeakohn/naken_asm
tests/comparison/scripts/gen_riscv.py
Python
gpl-3.0
1,166
0.030875
# 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 # distrib...
openstack/python-openstackclient
openstackclient/network/v2/l3_conntrack_helper.py
Python
apache-2.0
8,285
0
import numpy as np, gevent, traceback from gevent.queue import Queue, Empty from sakura.common.release import auto_release from sakura.common.chunk import NumpyChunk from sakura.common.exactness import EXACT, APPROXIMATE, UNDEFINED, Exactness def reassemble_chunk_stream(it, dt, chunk_size): if chunk_size is None: ...
eduble/panteda
sakura/common/stream.py
Python
gpl-3.0
4,447
0.003823
# Copyright 2017, OpenCensus Authors # # 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 w...
census-instrumentation/opencensus-python
tests/unit/trace/test_tracer.py
Python
apache-2.0
9,886
0
# generated from catkin/cmake/template/pkg.context.pc.in CATKIN_PACKAGE_PREFIX = "" PROJECT_PKG_CONFIG_INCLUDE_DIRS = "".split(';') if "" != "" else [] PROJECT_CATKIN_DEPENDS = "".replace(';', ' ') PKG_CONFIG_LIBRARIES_WITH_PREFIX = "".split(';') if "" != "" else [] PROJECT_NAME = "selected_points_publisher" PROJECT_SP...
mikewrock/phd_backup_full
build/selected_points_publisher/catkin_generated/pkg.installspace.context.pc.py
Python
apache-2.0
387
0
# -*- coding: utf-8 -*- """ Copyright (c) 2012 University of Oxford 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, modif...
benosteen/django-databank
src/frontend/utils/_old/ident_md.py
Python
mit
1,379
0.000725
import datetime as dt import threading from serial_device.or_event import OrEvent import numpy as np import pandas as pd import gobject import gtk import matplotlib as mpl from streaming_plot import StreamingPlot from ...max11210_adc_ui import MAX11210_read import logging def _generate_data(stop_event, data_ready, d...
wheeler-microfluidics/mr-box-peripheral-board.py
mr_box_peripheral_board/ui/gtk/measure_dialog.py
Python
mit
7,247
0.001932
#!/usr/bin/python # Copyright 2015 Comcast Cable Communications Management, 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 ...
Comcast/rulio
examples/actionendpoint.py
Python
apache-2.0
2,070
0.004831
# This file is part of Buildbot. Buildbot 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, version 2. # # This program is distributed in the hope that it will be useful, but WITHOUT # ANY WARRANTY; without eve...
pmisik/buildbot
master/buildbot/db/base.py
Python
gpl-2.0
5,687
0.000528
#FIXME: UNDO, click time at end to undo from PyQt4 import QtCore, QtGui import sys, os import volume_editor_layout, settings_layout, cPickle import numpy as np from utils import Utils class SettingsEditWidget(QtGui.QDialog, settings_layout.Ui_Dialog): #################################################### Init ...
singleswitch/ticker
settings_editor.py
Python
mit
9,463
0.012575
import re import collections from enum import Enum from ydk._core._dm_meta_info import _MetaInfoClassMember, _MetaInfoClass, _MetaInfoEnum from ydk.types import Empty, YList, YLeafList, DELETE, Decimal64, FixedBitsDict from ydk._core._dm_meta_info import ATTRIBUTE, REFERENCE_CLASS, REFERENCE_LIST, REFERENCE_LEAFLI...
111pontes/ydk-py
cisco-ios-xr/ydk/models/cisco_ios_xr/_meta/_Cisco_IOS_XR_infra_objmgr_oper.py
Python
apache-2.0
57,513
0.016987
import signal signal_names = {} for signame in dir(signal): if signame.startswith('SIG'): signum = getattr(signal, signame) if isinstance(signum, int): signal_names[signum] = signame def get_signal_name(signal_code): name = signal_names.get(signal_code, '') if name: r...
Mimino666/tc-marathoner
marathoner/utils/ossignal.py
Python
mit
765
0
#! /usr/bin/env python3 # Create a rotate by 13 encoder - http://www.rot13.com/ # Use: # hint use codecs.encode. look it up in the documentation import codecs def rot13_encode(data): """ Take in unencoded data and rot13 and return new data """ return codecs.encode(data, 'rot13') # What will be the output? h...
micronicstraining/python
module_3/lesson_3/practice.py
Python
agpl-3.0
3,261
0.003068
{ 'name': "Legacy Partner integration", 'version': "1.1", 'author': "José A. Ramírez", 'category': "Tools", 'depends': ['base'], 'data': ['legacy_partner.xml'], 'demo': [], 'installable': True, }
jarcodallo/custom_modules
legacy_clients/__openerp__.py
Python
gpl-2.0
229
0.004405
# -*- coding: utf-8 -*- ############################################################################## # # Copyright (C) 2010-2012 Associazione OpenERP Italia # (<http://www.openerp-italia.org>). # Copyright (C) 2014 Didotech srl # (<http://www.didotech.com>). # # This program is free software: you can r...
iw3hxn/LibrERP
stock_picking_extended/models/inherit_stock_location.py
Python
agpl-3.0
5,169
0.002902
import math import os import re import signal import sys import matplotlib from matplotlib import verbose from matplotlib.cbook import is_string_like, onetrue from matplotlib.backend_bases import RendererBase, GraphicsContextBase, \ FigureManagerBase, FigureCanvasBase, NavigationToolbar2, IdleEvent, \ curso...
alephu5/Soundbyte
environment/lib/python3.3/site-packages/matplotlib/backends/backend_qt4.py
Python
gpl-3.0
31,660
0.008654
# -*- coding: utf-8 -*- # (c) 2019, Google Inc. # # This file is part of Ansible # # Ansible is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later ver...
GoogleCloudPlatform/magic-modules
mmv1/provider/ansible/test_gcp_session.py
Python
apache-2.0
6,426
0.002023
# -*- Mode:python; c-file-style:"gnu"; indent-tabs-mode:nil -*- */ # # Copyright (C) 2015 The University of Memphis, # Arizona Board of Regents, # Regents of the University of California. # # This file is part of Mini-NDN. # See AUTHORS.md for a complete list of Mini-NDN authors an...
ndncomm/mini-ndn
ndn/experiments/integration_tests.py
Python
gpl-3.0
3,981
0.004019
import _plotly_utils.basevalidators class FamilyValidator(_plotly_utils.basevalidators.StringValidator): def __init__( self, plotly_name="family", parent_name="funnelarea.title.font", **kwargs ): super(FamilyValidator, self).__init__( plotly_name=plotly_name, parent_nam...
plotly/python-api
packages/python/plotly/plotly/validators/funnelarea/title/font/_family.py
Python
mit
616
0.001623
#!flask/bin/python import os import unittest from config import basedir from app import app, db from app.models import User class TestCase(unittest.TestCase): def setUp(self): app.config['TESTING'] = True app.config['WTF_CSRF_ENABLED'] = False app.config['SQLALCHEMY_DATABASE_URI'] = 'sqlit...
mcvmcv/wurstboard
tests.py
Python
gpl-2.0
1,285
0.004669
#!/usr/bin/env python from setuptools import setup, find_packages setup( name="luigi-td", version='0.6.10.dev0', description="Luigi integration for Treasure Data", author="Treasure Data, Inc.", author_email="support@treasure-data.com", url="https://github.com/treasure-data/luigi-td", insta...
treasure-data/luigi-td
setup.py
Python
apache-2.0
778
0
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # Code generated by Microsoft (R) AutoRest Code Generator. # Changes may ...
Azure/azure-sdk-for-python
sdk/sql/azure-mgmt-sql/azure/mgmt/sql/operations/_database_automatic_tuning_operations.py
Python
mit
10,488
0.003719
# encoding: utf-8 # module PyKDE4.kdeui # from /usr/lib/python2.7/dist-packages/PyKDE4/kdeui.so # by generator 1.135 # no doc # imports import PyKDE4.kdecore as __PyKDE4_kdecore import PyQt4.QtCore as __PyQt4_QtCore import PyQt4.QtGui as __PyQt4_QtGui import PyQt4.QtSvg as __PyQt4_QtSvg from KComboBox import KComboB...
ProfessorX/Config
.PyCharm30/system/python_stubs/-1247972723/PyKDE4/kdeui/KTimeComboBox.py
Python
gpl-2.0
3,363
0.011299
# Copyright (c) 2014 OpenStack Foundation. # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless...
gkotton/vmware-nsx
vmware-nsx/neutron/tests/unit/vmware/extensions/test_portsecurity.py
Python
apache-2.0
1,831
0.000546
import FWCore.ParameterSet.Config as cms process = cms.Process("Demo") process.load("FWCore.MessageService.MessageLogger_cfi") process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(-1) ) #process.MessageLogger.cerr.FwkReport.reportEvery = 100 process.source = cms.Source("PoolSource", # replace 'my...
tuos/FlowAndCorrelations
flowCorr/cmssw5320/FlowCorr/test/ConfFile_cfg.py
Python
mit
2,206
0.031732
import unittest from nose.tools import assert_equal class TestBar(unittest.TestCase): def call_FUT(self, count): from pypkg_template.foo import bar return bar(count) def test_friday_sunday(self): for day in (5, 6): assert_equal(self.call_FUT(day), "I'm in a bar") de...
hanula/pypkg_template
pypkg_template/tests/test_foo.py
Python
bsd-2-clause
449
0
#!/usr/bin/python # # This file is part of Ansible # # Ansible is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # Ansible is distribut...
konstruktoid/ansible-upstream
lib/ansible/modules/network/eos/eos_config.py
Python
gpl-3.0
19,251
0.001454
from decorator import decorator from inspect import getargspec # ------------------------------------------------------------------------ # decorators # ------------------------------------------------------------------------ def lazy_property(func): """Decorator that makes a property lazy-evaluated. """ ...
Quantipy/quantipy
quantipy/core/tools/qp_decorators.py
Python
mit
6,656
0.003456
# Copyright (c) 2014 Bull. # # 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, sof...
frossigneux/python-kwrankingclient
kwrankingclient/v1/shell_commands/nodes.py
Python
apache-2.0
1,816
0
#! /usr/bin/env python # -*- coding: utf-8 -*- # # Interpreter version: python 2.7 # import os.path import pytest import abclinuxuapi from abclinuxuapi import shared @pytest.fixture def bp_url(): return "http://www.abclinuxu.cz/blog/bystroushaak/2015/2/bolest-proxy" @pytest.fixture def do_that_fucking_monkey_p...
Bystroushaak/abclinuxuapi
tests/test_blogpost.py
Python
mit
4,767
0.001049
#!usr/bin/python try: f = open("link.txt","r") except IOError: print "ERROR!\n" exit o = open("download_all_files.sh","w") for line in f: if len(line)==0: continue file_name = line.split("/") file_name = file_name[len(file_name)-1] file_name = "\""+file_name[:len(file_name)-1]+".mp4\...
lawki/get_flash_videos_assembler
create_exec_.py
Python
gpl-3.0
628
0.007962
""" BNF reference: http://theory.lcs.mit.edu/~rivest/sexp.txt <sexp> :: <string> | <list> <string> :: <display>? <simple-string> ; <simple-string> :: <raw> | <token> | <base-64> | <hexadecimal> | <quoted-string> ; <display> :: "[" <simple-string> "]" ; <raw> :: <decimal> ":" <bytes> ; <deci...
bossiernesto/uLisp
uLisp/parser/uLispParser.py
Python
bsd-3-clause
2,979
0.004028
# -*- 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...
grap/OpenUpgrade
addons/stock/stock.py
Python
agpl-3.0
273,917
0.005732
#!/usr/bin/env python # coding: utf-8 #http://python-3-patterns-idioms-test.readthedocs.org/en/latest/Metaprogramming.html class RegisterClasses(type): def __init__(cls, name, bases, atts): super(RegisterClasses, cls).__init__(name, bases, atts) if not hasattr(cls, 'registry'): ...
heibanke/python_do_something
Code/Chapter5/meta_04.py
Python
apache-2.0
1,022
0.016634
""" Prosta klasa reprezentująca posiłek składający się z wielu innych obiektów jadalnych. """ class BigMeal: def __init__(self, edibles): # TODO: zainicjuj obiekt przekazaną listą obiektów jadalnych # "edibles" def get_name(self): # TODO: zaimplementuj metodę zwracającą nazwę obiektu ...
CodeCarrots/warsztaty
sesja07/bigmeal.py
Python
cc0-1.0
955
0.007592
'''@file main.py this function is used to run distributed training on a local cluster''' import os import atexit import subprocess import tensorflow as tf def local_cluster(expdir, class_type): '''main function''' #read the cluster file clusterfile = os.path.join(expdir, 'cluster', 'cluster') machin...
JeroenBosmans/nabu
nabu/distributed/local_cluster.py
Python
mit
1,506
0.001992
# ***** BEGIN LICENSE BLOCK ***** # Version: MPL 1.1/GPL 2.0/LGPL 2.1 # # The contents of this file are subject to the Mozilla Public License Version # 1.1 (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.mozilla.org/MPL/ # # Softwa...
windmill/windmill
windmill/dep/_mozrunner/__init__.py
Python
apache-2.0
7,224
0.006506
## @package net_printer # Module caffe2.python.net_printer from __future__ import absolute_import from __future__ import division from __future__ import print_function from __future__ import unicode_literals from caffe2.proto.caffe2_pb2 import OperatorDef, NetDef from caffe2.python.checkpoint import Job from caffe2.py...
xzturn/caffe2
caffe2/python/net_printer.py
Python
apache-2.0
12,712
0.000393
# Copyright 2010 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...
Akrog/cinder
cinder/api/common.py
Python
apache-2.0
15,127
0
# -*- coding: utf-8 -*- import os import httplib2 from apiclient.discovery import build from oauth2client.file import Storage from datetime import datetime from jobs import AbstractJob class Calendar(AbstractJob): def __init__(self, conf): self.interval = conf["interval"] self.timeout = conf.get...
mpolden/jarvis2
jarvis/jobs/calendar.py
Python
mit
1,462
0.000684
# -*- 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...
crmccreary/openerp_server
openerp/addons/procurement/wizard/orderpoint_procurement.py
Python
agpl-3.0
2,927
0.003416
import unittest from django.contrib.auth.models import User, Group from enhydris.hcore.models import Gentity class PermissionsTestCase(unittest.TestCase): def setUp(self): self.object = Gentity.objects.create(name='testgent') self.object.save() self.user = User.objects.create(username='test...
ellak-monades-aristeias/enhydris
enhydris/permissions/tests.py
Python
agpl-3.0
1,553
0.007083
#!/usr/bin/env python3.4 # ---------------------------------------------------------------------------- # import csv, os # ---------------------------------------------------------------------------- # def Validate(): Message1 = 'VALIDATED!!!' Message2 = ''' $$$$$$$$\ $$ | $$$$$$\ $$$$$$\ $$$$$$\ $$$$$...
rssenar/PyToolkit
ValidateFiles.py
Python
bsd-2-clause
2,072
0.034749
################################################################################ # $Id: output.py 2552 2007-02-08 21:40:46Z b4rt $ # $Date: 2007-02-08 15:40:46 -0600 (Thu, 08 Feb 2007) $ # $Revision: 2552 $ ################################################################################ # ...
sulaweyo/torrentflux-b4rt-php7
html/bin/clients/fluazu/fluazu/output.py
Python
gpl-2.0
3,408
0.012911
# Copyright 2013: Mirantis Inc. # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required b...
yeming233/rally
rally/plugins/openstack/cfg/nova.py
Python
apache-2.0
12,529
0
# This file is part of ConfigFile - Parse and edit configuration files. # Copyright (C) 2011-present Dario Giovannetti <dev@dariogiovannetti.net> # Licensed under MIT # https://github.com/kynikos/lib.py.configfile/blob/master/LICENSE """ This library provides the :py:class:`ConfigFile` class, whose goal is to provide...
kynikos/lib.py.configfile
configfile/__init__.py
Python
mit
60,029
0.000983
#!/usr/bin/env python # -*- coding: utf-8 -*- import os print "Sana da merhaba %s" % (os.getenv("USER"))
examachine/pisi
tests/buildtests/merhaba-pisi-1.0/usr/bin/merhaba-pisi.py
Python
gpl-3.0
107
0.009346
""" WSGI config for eve_site project. It exposes the WSGI callable as a module-level variable named ``application``. For more information on this file, see https://docs.djangoproject.com/en/1.6/howto/deployment/wsgi/ """ import os os.environ.setdefault("DJANGO_SETTINGS_MODULE", "eve_site.settings") from django.core...
spatuloricaria/Uncap
eve_site/eve_site/wsgi.py
Python
gpl-3.0
391
0.002558
import ConfigParser import StringIO from test_support import TestFailed, verify def basic(src): print "Testing basic accessors..." cf = ConfigParser.ConfigParser() sio = StringIO.StringIO(src) cf.readfp(sio) L = cf.sections() L.sort() verify(L == [r'Commented Bar', r'Foo ...
MalloyPower/parsing-python
front-end/testsuite-python-lib/Python-2.2/Lib/test/test_cfgparser.py
Python
mit
7,274
0
from kafka import KafkaProducer #oducer = KafkaProducer(bootstrap_servers='kafka-kf.kafka.svc.cluster.local:9092') producer = KafkaProducer(bootstrap_servers='localhost:9092') producer.send('test', 'hello')
madcore-ai/containers
kfn/examples/producer.py
Python
mit
207
0.009662