code
stringlengths
3
1.05M
repo_name
stringlengths
5
104
path
stringlengths
4
251
language
stringclasses
1 value
license
stringclasses
15 values
size
int64
3
1.05M
# Copyright 2008-2015 Nokia Solutions and 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 l...
caio2k/RIDE
src/robotide/lib/robot/result/keyword.py
Python
apache-2.0
2,149
# -*- coding: utf-8 -*- # * Copyright (c) 2009-2018. Authors: see NOTICE file. # * # * 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...
cytomine/Cytomine-python-client
cytomine/tests/test_social.py
Python
apache-2.0
1,941
#!/usr/bin/python3 import os listTests = os.listdir('.') print(listTests) for test in listTests: if os.path.isdir(test) == True: os.chdir(test) print('cleaning environment for test: ',test) os.system('rm -rf logs mpiCode data logClean logCompilation logExecution') os.system('scons...
montanier/pandora
tests/functionalTests/cppFunctionalTests/parallelTests/executeTestsLocal.py
Python
lgpl-3.0
575
""" tests for dns_parser.py The latest version of this package is available at: <https://github.com/jantman/pydnstest> ################################################################################## Copyright 2013-2017 Jason Antman <jason@jasonantman.com> This file is part of pydnstest. pydnstest is free...
jantman/pydnstest
pydnstest/tests/dnstest_parser_test.py
Python
agpl-3.0
9,750
# Copyright The Cloud Custodian Authors. # SPDX-License-Identifier: Apache-2.0 from .core import ( ANNOTATION_KEY, FilterValidationError, OPERATORS, FilterRegistry, Filter, Or, And, Not, ValueFilter, AgeFilter, EventFilter, ReduceFilter, ) from .config import ConfigCompli...
thisisshi/cloud-custodian
c7n/filters/__init__.py
Python
apache-2.0
548
{ 'name': 'eCommerce FairMarket', 'category': 'Website', 'summary': 'Modification in website_sale for FairMarket', 'website': 'https://www.odoo.com/page/e-commerce', 'version': '1.0', 'description': """ OpenERP E-Commerce modifications for FairMarket ================== """, 'author': 'P...
Punto0/addons-fm
website_sale_fm/__openerp__.py
Python
agpl-3.0
570
# Copyright 2012 Patrick Varilly, Stefano Angioletti-Uberti # # 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...
patvarilly/DNACC
examples/explicit_competing_linkages/explicit_competing_linkages.py
Python
gpl-3.0
5,092
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('email_campaigns', '0002_auto_20160722_1657'), ] operations = [ migrations.AlterField( model_name='campaign', ...
mpetyx/psymbiosys-questionnaire
email_campaigns/migrations/0003_auto_20160907_1146.py
Python
mit
483
# -*- coding: utf-8 -*-1 """Tests of phy spike sorting commands.""" #------------------------------------------------------------------------------ # Imports #------------------------------------------------------------------------------ from phy.scripts import main #-----------------------------------------------...
nippoo/phy
tests/scripts/test_phy_spikesort.py
Python
bsd-3-clause
1,152
class Solution: def exist(self, board, word): """ :type board: List[List[str]] :type word: str :rtype: bool """ for i in range(0, len(board)): if not board: return False for j in range(0, len(board[0])): ...
MingfeiPan/leetcode
backtracking/79.py
Python
apache-2.0
1,039
import sqlalchemy from www import server from www import login from common.config import config import common.rpc import datetime import pytz import flask import common.storm from common import googlecalendar @server.app.route("/api/stormcount") def stormcount(): return flask.jsonify({ 'twitch-subscription': common...
andreasots/lrrbot
www/api.py
Python
apache-2.0
3,738
# Copyright (c) 2005 The Regents of The University of Michigan # Copyright (c) 2010 Advanced Micro Devices, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are # met: redistributions of source code mu...
bxshi/gem5
src/python/m5/util/convert.py
Python
bsd-3-clause
9,855
# Copyright 2013 Google Inc. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or ...
UniMOOC/AAClassroom
models/models.py
Python
apache-2.0
75,333
#!/usr/bin/env python """ Run subgrid as a python script with colored output """ import argparse import logging import os import sys from python_subgrid.tests.utils import colorlogs from python_subgrid.tools.scenario import apply_events, clean_events from python_subgrid.raingrid import AREA_WIDE_RAIN, RainGridContain...
nens/python-subgrid
python_subgrid/tools/subgridpy.py
Python
gpl-3.0
3,587
# Copyright 2017 James McCauley # # 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 writi...
MurphyMc/pox
pox/lib/interfaceio/__init__.py
Python
apache-2.0
17,797
# -*- coding: utf-8 -*- ''' Specto Add-on Copyright (C) 2015 lambda 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 l...
repotvsupertuga/repo
plugin.video.pancas/resources/lib/sources/primewire_mv_tv.py
Python
gpl-2.0
8,324
# -*- coding: utf-8 -*- # Generated by Django 1.9.6 on 2016-05-30 12:33 from __future__ import unicode_literals from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('todo', '0006_auto_20160530_1210'), ] operations = [...
Azarn/mytodo
todo/migrations/0007_auto_20160530_1233.py
Python
apache-2.0
593
# -*- encoding: utf-8 -*- TEST_RUNNER = 'django_nose.NoseTestSuiteRunner' SECRET_KEY = 'cheese' DATABASE_ENGINE = 'sqlite3' DATABASES = { 'default': { 'ENGINE': 'django.db.backends.sqlite3', 'NAME': ':memory:', } } INSTALLED_APPS = ( 'memcached_memoize', 'django_nose', ) ROOT_URLCO...
globocom/memcached_memoize
tests/settings.py
Python
bsd-3-clause
457
# -*- 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 # "...
wagavulin/arrow
python/pyarrow/tests/test_scalars.py
Python
apache-2.0
6,936
default_app_config = 'website.apps.CoreConfig'
jonge-democraten/website
website/core/__init__.py
Python
mit
48
""" WSGI config for c_all_in 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.9/howto/deployment/wsgi/ """ import os from django.core.wsgi import get_wsgi_application os.environ.setdefault("DJANGO_SETT...
uwekamper/c-all-in
c_all_in/c_all_in/wsgi.py
Python
mit
393
from bs4 import BeautifulSoup import requests import re url = "https://play.google.com/store/apps/details?id=com.sillygames.killingSpree" #using mobile agent to reduce the website size headers = { 'User-Agent': 'Mozilla/5.0 (iPhone; CPU iPhone OS 7_1_1 like Mac OS X) AppleWebKit/537.51.1 (KHTML, like Gecko) CriO...
ganeshkamathp/PlayStore-Parser
parser.py
Python
cc0-1.0
832
""" ============================================================================ File name: rpy2_ggplot_test.py Author: gong-yi@GongTop0 Created on: 2013/12/24 02:17:42 Purpose: To show Copyright: BSD / Apache ---------------...
GongYiLiao/Python_Daily
2013/Dec/23/rpy2_ggplot_test.py
Python
mit
4,822
class TimetableGenerator: def __init__(self): self.generated = [] self.generated2 = [] self.total_combinations = 0 def store_timetable(self, tt): self.total_combinations += 1 tt.heuristic = tt.total_time() tt.heuristic2 = tt.total_time2() if len(self.generated) <= 99: self.generated.append(tt) ...
colobas/gerador-horarios
tt_generator.py
Python
mit
4,842
try: from IBMQuantumExperience import IBMQuantumExperience from pprint import pprint def quant_exp(args): with open('etc/IBMtoken', 'r') as infile: token = infile.read().replace('\n', '') config = { "url": 'https://quantumexperience.ng.bluemix.net/api' } ...
LSaldyt/qnp
scripts/quant_exp.py
Python
mit
901
def my_or(x, y): return x or y my_or(True, False)
DEVSENSE/PTVS
Python/Tests/TestData/DebuggerProject/LocalBooleanTest.py
Python
apache-2.0
55
import unittest import sys import traceback from util import * class FakeImporter(Importer): def do_import_module(self, name): x = compile('import doesntexist\n', 'not_a_file.py', 'exec') eval(x) class TestImport(unittest.TestCase): def test_backtrace(self): imp = FakeImporte...
epronk/pyfit2
test_import.py
Python
gpl-2.0
765
from __future__ import unicode_literals, print_function import pytest import logging from psd_tools.compression import ( compress, decompress, encode_prediction, decode_prediction, encode_rle, decode_rle ) from psd_tools.constants import Compression logger = logging.getLogger(__name__) RAW_IMAGE_3x3_8bit = b'...
kmike/psd-tools
tests/psd_tools/compression/test_compression.py
Python
mit
3,424
# -*- coding: utf-8 -*- # pylint: disable=invalid-name import html from http import HTTPStatus from django.conf import settings from django.urls import reverse from django.utils.translation import gettext_lazy as _ from tcms.tests import LoggedInTestCase from tcms.tests.factories import UserFactory class TestAdmin...
kiwitcms/Kiwi
tcms/core/tests/test_admin.py
Python
gpl-2.0
6,142
# -*- cpy-indent-level: 4; indent-tabs-mode: nil -*- # ex: set expandtab softtabstop=4 shiftwidth=4: # # Copyright (C) 2011-2018 Contributor # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at #...
quattor/aquilon
lib/aquilon/worker/commands/search_audit.py
Python
apache-2.0
10,400
#! /usr/bin/env python3 import API as pk import requests import pygeocoder def main(): print("__________________________________________ \n \n \n Welcome to YikYak upvote Hack"); geocoder = pygeocoder.Geocoder("AIzaSyAGeW6l17ATMZiNTRExwvfa2iuPA1DvJqM") currentlist = [] #Code pulled from YikYak.py terminal GU...
MrAjsTech/YakUpVoteHack
YikYak.py
Python
bsd-3-clause
4,519
#!/usr/bin/env python3 # Copyright (c) 2017-2020 The Bitcoin Core developers # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. """Test that the mempool ensures transaction delivery by periodically sending to peers until a GETDATA is ...
Bitcoin-ABC/bitcoin-abc
test/functional/mempool_unbroadcast.py
Python
mit
4,377
# -*- coding: utf-8 -*- """ Created on Mon Jul 13 09:11:25 2015 @author: paulinkenbrandt """ import py_compile py_compile.compile("C:\\Users\\PAULINKENBRANDT\\Documents\\GitHub\\Snake_Valley\\snake.py")
inkenbrandt/Snake_Valley
untitled1.py
Python
gpl-2.0
205
import unittest from roadhouse import parser class PortParseTest(unittest.TestCase): @classmethod def setUpClass(cls): cls.parse = parser.ports.parseString def test_port_and_range(self): tmp = self.parse("22, 80-100") self.assertEqual(tmp.ports[0], (22, 22)) self.assertEqua...
awsroadhouse/roadhouse
roadhouse/tests/test_parser.py
Python
bsd-2-clause
3,629
#!/usr/bin/env python3 # Copyright (c) 2017-2018 The Bitcoin Core developers # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. """Test wallet replace-by-fee capabilities in conjunction with the fallbackfee.""" from test_framework.tes...
litecoin-project/litecoin
test/functional/wallet_fallbackfee.py
Python
mit
1,487
import string import tensorflow as tf import numpy as np import os import time from tempfile import TemporaryFile class Seq2Seq: def __init__(self, input_file, window_size, overlap_size, batch_size, hidden_size, no_stacked_cells=3, vocab=None): if vocab == None: vocab = string.ascii_letters ...
wecliqued/deep_learning
seq2seq/seq2seq.py
Python
mit
15,669
#coding: utf-8 from django import template register = template.Library() @register.simple_tag def upload_js(): return """ <!-- The template to display files available for upload --> <script id="template-upload" type="text/x-tmpl"> {% for (var i=0, file; file=o.files[i]; i++) { %} <tr class="template-upload ...
tianweidut/ChemToolsWebService
chemistry/templatetags/upload_tags.py
Python
agpl-3.0
2,694
#!/usr/bin/python # # CDDL HEADER START # # The contents of this file are subject to the terms of the # Common Development and Distribution License (the "License"). # You may not use this file except in compliance with the License. # # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE # or http://www....
marcellodesales/svnedge-console
ext/windows/pkg-toolkit/pkg/vendor-packages/pkg/client/transport/__init__.py
Python
agpl-3.0
946
# from context import sample as pump import context as pump import time import sys import getopt def main(argv): fabrica = 0 ntimes = 1 sec = 5.0 WorA = 'a' try: opts, args = getopt.getopt( argv, "hwf:v:s:", ["fabrica=", "veces=", "segund...
xavigisbeg/ELECTROAD_PiUMP
tests/test_knf.py
Python
apache-2.0
1,987
# -*- coding: utf-8 -*- # # Copyright © 2012 - 2015 Michal Čihař <michal@cihar.com> # # This file is part of Weblate <http://weblate.org/> # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, eithe...
leohmoraes/weblate
weblate/trans/tests/test_acl.py
Python
gpl-3.0
5,904
"""Implementation of JSONEncoder """ import re try: from _json import encode_basestring_ascii as c_encode_basestring_ascii except ImportError: c_encode_basestring_ascii = None try: from _json import encode_basestring as c_encode_basestring except ImportError: c_encode_basestring = None try:...
prefetchnta/questlab
bin/x64bin/python/36/Lib/json/encoder.py
Python
lgpl-2.1
16,461
#!/usr/bin/env python import datetime import os import time import bs4 import psycopg2 import requests ENV_VARS = { "FERRY_DBNAME": "dbname", "FERRY_DBUSER": "user", "FERRY_DBPWD": "password", } DB_CREDS = " ".join(ENV_VARS[var]+"="+os.environ[var] for var in ENV_VARS.keys() if var in os.environ) FERRIE...
mikemcbrearty/ferry-app
py/scrape.py
Python
mit
2,701
# -*- test-case-name: twisted.test.test_process -*- # Copyright (c) 2001-2008 Twisted Matrix Laboratories. # See LICENSE for details. """ http://isometric.sixsided.org/_/gates_in_the_head/ """ # pylint: disable-msg=F0401,E1101 import os # Win32 imports import win32api import win32con import win32event import win32f...
TaskEvolution/Task-Coach-Evolution
taskcoach/buildbot/slaves/WinXPSP3/_dumbwin32proc.py
Python
gpl-3.0
11,364
"""Test AdaNet single graph subnetwork implementation. Copyright 2018 The AdaNet 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 https://www.apache.org/licenses/L...
tensorflow/adanet
adanet/subnetwork/report_test.py
Python
apache-2.0
4,130
# -*- coding: utf-8 -*- """ Generator.py create (generate) annotated data H. Déjean copyright Xerox 2017 READ project Developed for the EU project READ. The READ project has received funding from the European Union's Horizon 2020 research and innovation programme ...
Transkribus/TranskribusDU
TranskribusDU/dataGenerator/listGenerator.py
Python
bsd-3-clause
2,135
""" Extended docstrings for functions.py """ pi = r""" `\pi`, roughly equal to 3.141592654, represents the area of the unit circle, the half-period of trigonometric functions, and many other things in mathematics. Mpmath can evaluate `\pi` to arbitrary precision:: >>> from mpmath import * >>> mp.dps = 50; m...
ammarkhann/FinalSeniorCode
lib/python2.7/site-packages/mpmath/function_docs.py
Python
mit
277,901
# vim: tabstop=4 shiftwidth=4 softtabstop=4 # # Copyright 2012 New Dream Network, LLC (DreamHost) # 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 # # h...
ntt-sic/neutron
neutron/tests/unit/test_db_migration.py
Python
apache-2.0
3,643
import asyncio import functools import os import shutil import tempfile from unittest import mock from unittest.mock import MagicMock import pytest from aiohttp import web from aiohttp.web_urldispatcher import SystemRoute @pytest.fixture(scope='function') def tmp_dir_path(request): """ Give a path for a tem...
panda73111/aiohttp
tests/test_web_urldispatcher.py
Python
apache-2.0
7,407
#!/usr/bin/python from tabulate import tabulate class State: #Constructor, add self on function for non-static methods / variables def __init__(self, transition, name): self.accept_state = False self.accept_num = 0 self.transition = transition self.next_state = [] se...
tjmonsi/cmsc129-2016-repo
submissions/exercise2/doron/tokengenerator.py
Python
mit
16,095
def grade(tid, answer): if answer.find("failed_up_is_the_best_fail_you_are_ctf_champion") != -1: return { "correct": False, "message": "It's not going to be the same as last year's...." } if answer.find("yeee3ee3ew_sha44aal11l1l1l_bE#eeee_azzzzzsimmileitted!!") != -1: return { "correct": True, "message": "Now sen...
EasyCTF/easyctf-2015
api/problems/recon/ioexception/ioexception_grader.py
Python
mit
461
import os import sqlite3 import pandas as pd import numpy as np import matplotlib.pyplot as plt from statsmodels.distributions.empirical_distribution import ECDF from matplotlib.ticker import FuncFormatter def thousands(x, pos): if x>=1e9: return '%.1fB' % (x*1e-9) elif x>=1e6: return '%.1fM' %...
natasasdj/OpenWPM
analysis/12_images_third-domains2.py
Python
gpl-3.0
19,012
__version_info__ = { 'major': 2, 'minor': 2, 'micro': 0, 'releaselevel': 'final', 'serial': 0 } def get_version(short=False): assert __version_info__['releaselevel'] in ('alpha', 'beta', 'final') vers = ["%(major)i.%(minor)i" % __version_info__, ] if __version_info__['micro']: ...
epantry/django-sql-explorer
explorer/__init__.py
Python
mit
693
""" Virtualization installation functions for image based deployment Copyright 2008 Red Hat, Inc. Bryan Kearney <bkearney@redhat.com> Original version based on virt-image David Lutterkort <dlutter@redhat.com> This program is free software; you can redistribute it and/or modify it under the terms of the GNU General P...
remotesyssupport/koan
koan/imagecreate.py
Python
gpl-2.0
5,995
import json from functools import partial import factory from factory.django import DjangoModelFactory # Imported to re-export # pylint: disable=unused-import from student.tests.factories import UserFactory # Imported to re-export from student.tests.factories import GroupFactory # Imported to re-export from student....
mjg2203/edx-platform-seas
lms/djangoapps/courseware/tests/factories.py
Python
agpl-3.0
4,471
import sys import threading import traceback import warnings from _pydev_bundle._pydev_filesystem_encoding import getfilesystemencoding from _pydev_bundle.pydev_imports import xmlrpclib, _queue from _pydevd_bundle.pydevd_constants import Null, IS_PY3K Queue = _queue.Queue #This may happen in IronPython (in Python it...
fabioz/Pydev
plugins/org.python.pydev.core/pysrc/_pydev_runfiles/pydev_runfiles_xml_rpc.py
Python
epl-1.0
11,034
############################################################################## # # Copyright (c) 2004 Zope Corporation and Contributors. # All Rights Reserved. # # This software is subject to the provisions of the Zope Public License, # Version 2.0 (ZPL). A copy of the ZPL should accompany this distribution. # THIS SO...
Donkyhotay/MoonPy
zope/cachedescriptors/tests.py
Python
gpl-3.0
856
#!/usr/bin/env python # # Copyright 2010 The Closure Linter 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 #...
teeple/pns_server
work/install/node-v0.10.25/tools/closure_linter/setup.py
Python
gpl-2.0
1,323
# -*- coding: utf-8 -*- import copy import datetime import mock import pytest import elastalert.alerts import elastalert.ruletypes from elastalert.config import get_file_paths from elastalert.config import load_configuration from elastalert.config import load_modules from elastalert.config import load_options from el...
amoennin/elastalert
tests/config_test.py
Python
apache-2.0
8,299
""" WSGI config for superlists 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.10/howto/deployment/wsgi/ """ import os from django.core.wsgi import get_wsgi_application os.environ.setdefault("DJANGO_S...
xueyaodeai/DjangoWebsite
superlists/wsgi.py
Python
mit
398
# 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 the...
glyph/cryptography
setup.py
Python
apache-2.0
3,258
import wx import wx.html from ..utils.generic_class import GenericClass from ..utils.constants import control, dtype from ..utils.validator import CharValidator import pkg_resources as p class NonLinearTimeSeriesAnalysis(wx.html.HtmlWindow): def __init__(self, parent, counter = 0): from urllib2 import u...
roijo/C-PAC_complexitytools
CPAC/GUI/interface/pages/nonlinearts.py
Python
bsd-3-clause
5,523
__author__ = 'antonioirizar' from boto3 import resource from boto3.exceptions import ResourceNotExistsError from boto3.session import Session from botonio.create_service_aws import Instance class User: def __init__(self, name, user_id): self.name = name self.user_id = user_id self._state...
antonioIrizar/telegram-bot-AWS
botonio/user.py
Python
gpl-3.0
3,555
class GameStatus: Error = -1 Quit = 0 LaunchMapbuilder = 1 LoadMap = 2 def main(world): player = world.player while(True): print print print player.currentArea.entranceText print print 'The area contains:' for feature in player.currentArea.features: print feature.description print 'Wh...
stevenvergenz/pyVenture
pyVenture/game/main.py
Python
gpl-3.0
903
import seaborn as sns import matplotlib.pyplot as plt def neg_plot(data): sns.set(style="whitegrid") sns.set_context("notebook", font_scale=3, rc={"lines.linewidth": 0.3}) sns.set_color_codes("bright") temp = (1500 / float(data.neg.max())) size = data.neg * temp size = 10000 * (data.neg ** ...
S0MEC0DE/v1
somecode/neg_plot.py
Python
mit
1,247
# -*- coding: utf-8 -*- import wx import random from pagina import pagina class pagina12 ( pagina ) : def __init__ ( self , parent , grandParent , index ) : pagina.__init__ ( self, parent , grandParent , index ) self.caricaImmagineDiSfondo ("12_Gioco_carte/Forma schermo.png") self.caricaImmagine ("12_G...
melfnt/librotecnologico
pagina/pagina12.py
Python
gpl-3.0
3,551
# This program is free software; you can redistribute it and/or modify # it under the terms of the (LGPL) GNU Lesser 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 ...
obsoleter/suds
suds/mx/typer.py
Python
lgpl-3.0
4,234
# Copyright 2015 gRPC 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 writing...
ejona86/grpc
src/python/grpcio/grpc_core_dependencies.py
Python
apache-2.0
80,840
#!/usr/bin/env python import re import sys import requests import json import bs4 # Bros import base64 TARGET_URL = 'http://www.parlimen.gov.my' MRBILLS = TARGET_URL + '/bills-dewan-rakyat.html' file_rule = re.compile("loadResult\('(.*)','(.*)'\)") def doReq(): params = {'uweb':'dr'} print "Requesting latest...
sweemeng/Malaysian-Bill-Watcher
billwatcher/scrapers/parliament.py
Python
gpl-3.0
3,779
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import migrations, models from django.conf import settings class Migration(migrations.Migration): dependencies = [ migrations.swappable_dependency(settings.AUTH_USER_MODEL), ('blog', '0005_auto_20151215_1433'), ] ...
FarmCodeGary/InspirationForge
blog/migrations/0006_auto_20151216_1349.py
Python
mit
955
import nengo import numpy as np import nengo.spa as spa vocab = spa.Vocabulary(32) vocab2 = spa.Vocabulary(32) model = nengo.Network() with model: state = spa.State(32, vocab=vocab) bg = nengo.networks.actionselection.BasalGanglia(4) nengo.Connection(state.output, bg.input, transform...
tcstewar/nengo_assignments
groningen_2018/day4-action/action5.py
Python
gpl-3.0
1,029
""" Definition of forms. """ from django.shortcuts import render, redirect from django import forms from app import models from django.contrib.auth.forms import AuthenticationForm from django.contrib.auth import authenticate, login, get_user_model,logout from django.contrib import auth from django.contrib.auth.models i...
0909023/Dev6B_English_Website
DjangoWebProject1/DjangoWebProject1/app/forms.py
Python
mit
2,175
#legacy from HTMLParser import HTMLParser tehlink='nuffin' class NoisyParser(HTMLParser): def __init__(self): HTMLParser.__init__(self) self.tehtree={} def handle_starttag(self, tag, attrs): print("Starting tag ({0}), Value ({1})".format(tag,attrs)) global tehlink try: self.tehtree[tag]=se...
BackupTheBerlios/hiss
hostmodule/core/grep2.py
Python
gpl-3.0
959
# Licensed to the Software Freedom Conservancy (SFC) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The SFC licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not...
HtmlUnit/selenium
py/test/selenium/webdriver/phantomjs/phantomjs_launcher_tests.py
Python
apache-2.0
1,739
# -*- coding: utf-8 -*- from plivo.utils import to_param_dict from plivo.utils.validators import * from ..base import ListResponseObject, PlivoResource, PlivoResourceInterface class Endpoint(PlivoResource): _name = 'Endpoint' _identifier_string = 'endpoint_id' @validate_args( password=[of_type(s...
plivo/plivo-python
plivo/resources/endpoints.py
Python
mit
2,946
''' Kivy Imports ''' from kivy.config import Config Config.set('input', 'mouse', 'mouse,disable_multitouch') Config.set('graphics', 'minimum_width', '620') Config.set('graphics', 'minimum_height', '440') Config.set('kivy', 'exit_on_escape', '0') Config.set('graphics', 'multisamples', '0') from kivy.app...
abetusk/dev
projects/maslowcnc/software/GroundControl-master/main.py
Python
agpl-3.0
24,128
from django.utils.translation import ugettext_noop as _ from custom.reports.mc.models import WEEKLY_SUMMARY_XMLNS HF_MONTHLY_REPORT = [ { 'section': _('mc_section_home_visits'), 'total_column': _('home_visits_total'), 'columns': [ _('home_visits_pregnant'), _('home_v...
puttarajubr/commcare-hq
custom/reports/mc/reports/definitions.py
Python
bsd-3-clause
7,380
total = 0 with open('day2.txt') as f: for line in f: l, w, h = map(int, line.split('x')) total += l * w * h total += 2 * (l + w + h - max(l, w, h)) print total
BethyDiakabananas/Advent-of-Code
Day 2/day2_part2.py
Python
mit
170
#sem:name: PDF LaTeX #sem:tip: Generates a LaTeX project for obtaining PDF files # Thomas Nagy, 2007-2018 GPLV3 import os, time, shutil, re, getpass # Additional variables: # exclude 1 # picdim [width=10cm] settings = { 'doc_content':'', 'doc_class':'article', 'all_latex':False, 'header_off':'', 'footer_off':...
ita1024/semantik
src/templates/pdflatex.sem.py
Python
gpl-3.0
4,634
#!/usr/bin/env python """ exons2gff.py <exons file> <gff file> <reference> <source> """ import re import csv import sys gffFields = [ 'reference', 'source', 'type', 'start', 'end', 'score', 'strand', 'phase', 'group' ] strand = {'>': '+', '<': '-'} def exons2gff(iFilename, oFil...
PapenfussLab/Mungo
snippets/exons2gff.py
Python
artistic-2.0
3,622
# This is work in progress. The aim of this file is to create a common template # so the look and feel of all ABM embedded screens is uniform # screen has always been 600 x 500 so stick with that. # button size was always 140 x 40 so stick with that. # use 8 px margin either side of buttons and 4 px margin above and b...
oe-alliance/AutoBouquetsMaker
AutoBouquetsMaker/src/skin_templates.py
Python
gpl-3.0
13,277
# 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-cognitiveservices-search-entitysearch/azure/cognitiveservices/search/entitysearch/operations/__init__.py
Python
mit
567
# -*- coding: utf-8 -*- # Generated by Django 1.9.2 on 2016-03-02 01:22 from __future__ import unicode_literals import django.db.models.deletion import jsonfield.fields from django.conf import settings from django.db import migrations, models import openslides.utils.models class Migration(migrations.Migration): ...
FinnStutzenstein/OpenSlides
server/openslides/motions/migrations/0001_initial.py
Python
mit
12,740
""" Implements the EN track check, described on pp 7 and 21 of http://www.metoffice.gov.uk/hadobs/en3/OQCpaper.pdf """ import numpy as np import util.main as main import util.geo as geo import copy, datetime, math, sys, calendar, sqlite3 # module constants DistRes = 20000. # meters TimeRes = 600. # seconds def test(...
s-good/AutoQC
qctests/EN_track_check.py
Python
mit
15,479
#!/usr/bin/python2.5 # # Copyright 2010 the Melange authors. # Copyright 2009 Jake McGuire. # # 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 # ...
MatthewWilkes/mw4068-packaging
src/melange/src/soc/profiling/profiler.py
Python
apache-2.0
3,602
#!/usr/bin/env python # Copyright (C) 2009,2010 Junta de Andalucia # # Authors: # Roberto Majadas <roberto.majadas at openshine.com> # Cesar Garcia Tapia <cesar.garcia.tapia at openshine.com> # Luis de Bethencourt <luibg at openshine.com> # Pablo Vieytes <pvieytes at openshine.com> # # This program is free so...
hychen/gnome-nanny
daemon/src/Win32Filtering.py
Python
gpl-2.0
10,565
# 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 https://mozilla.org/MPL/2.0/. """ tests for sisl/geom """
zerothi/sisl
sisl/geom/tests/__init__.py
Python
mpl-2.0
228
#!/usr/bin/env ${python_interpreter} import os import sys import unittest import numpy # This is a hack for nw. What this does is, add the build directory to python's # path, so that it can find the module mtca4u. sys.path.insert(0,os.path.abspath(os.curdir)) import mtca4u import versionnumbers as vn #to lock the mtc...
ChimeraTK/DeviceAccess-PythonBindings
tests/testMtca4upy.py
Python
lgpl-3.0
22,852
import sys from robotremoteserver import RobotRemoteServer from sikuli import * class SikuliRemoteLibrary: def __init__(self): self.SS = Screen() self.PT = Pattern() def _wait(self, imgFile, timeOut, similarity): try: self.PT = Pattern(imgFile) self.PT = self.P...
priyesingh/rijenpy
libs/SikuliRemoteLibrary.py
Python
gpl-3.0
1,635
#!/usr/bin/env python # # Use the raw transactions API to spend sinertalers received on particular addresses, # and send any change back to that same address. # # Example usage: # spendfrom.py # Lists available funds # spendfrom.py --from=ADDRESS --to=ADDRESS --amount=11.00 # # Assumes it will talk to a sinertalerd ...
fourty2/sinertaler
contrib/spendfrom/spendfrom.py
Python
mit
10,168
# -*- coding: utf-8 -*- # Generated by Django 1.11.4 on 2017-09-20 22:16 from __future__ import unicode_literals from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): initial = True dependencies = [ ('quiz_view', '0001_initial'), ] ...
tetsucceed/quiz-app
qapp/quiz_view/migrations/0002_auto_20170920_2216.py
Python
mit
1,785
#!/usr/bin/env python # -*- coding: utf-8 -*- import time from datetime import datetime from helpers.loghelpers import LOG from .trigger import Trigger from .triggertype import TriggerType from validators.validators import valid_amount, valid_timestamp class RecurringTrigger(Trigger): def __init__(self, trigger_...
ValyrianTech/BitcoinSpellbook-v0.3
trigger/recurringtrigger.py
Python
gpl-3.0
2,696
# This file is part of CherryPy <http://www.cherrypy.org/> # -*- coding: utf-8 -*- # vim:ts=4:sw=4:expandtab:fileencoding=utf-8 from hashlib import md5 import cherrypy from cherrypy._cpcompat import ntob from cherrypy.lib import auth_basic from cherrypy.test import helper class BasicAuthTest(helper.CPWebCase): ...
Southpaw-TACTIC/TACTIC
3rd_party/python2/site-packages/cherrypy/test/test_auth_basic.py
Python
epl-1.0
3,034
''' ÔÚ Python1.6 ºÍºó¼Ì°æ±¾£¬¸ü¶àµÄ×Ö·û´®²Ù×÷¶¼¿ÉÒÔ×÷Ϊ×Ö·û´®·½·¨À´·ÃÎÊ, Èç ÏÂÀý Ëùʾ, string Ä£¿éÖеÄÐí¶àº¯ÊýÖ»ÊǶÔÏà¶ÔÓ¦×Ö·û´®·½·¨µÄ·â×°. ''' text = "Monty Python's Flying Circus" print "upper", "=>", text.upper() print "lower", "=>", text.lower() print "split", "=>", text.split() print "join", "=>", "+".join(text....
iamweilee/pylearn
string-example-2.py
Python
mit
478
# Copyright 2012 Nebula, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agree...
JioCloud/horizon
openstack_dashboard/dashboards/project/access_and_security/security_groups/tables.py
Python
apache-2.0
8,526
# Copyright (c) 2014 Amazon.com, Inc. or its affiliates. All Rights Reserved # # Permission is hereby granted, free of charge, to any person obtaining a # copy of this software and associated documentation files (the # "Software"), to deal in the Software without restriction, including # without limitation the rights ...
mikel-egana-aranguren/SADI-Galaxy-Docker
galaxy-dist/eggs/boto-2.27.0-py2.7.egg/boto/rds2/layer1.py
Python
gpl-3.0
158,263
#!/usr/bin/env python3 # Copyright (C) 2012-2015 ASTRON (Netherlands Institute for Radio Astronomy) # P.O. Box 2, 7990 AA Dwingeloo, The Netherlands # # This file is part of the LOFAR software suite. # The LOFAR software suite is free software: you can redistribute it and/or # modify it under the terms of the GNU Gen...
kernsuite-debian/lofar
LCS/MessageBus/src/Protocols/taskfeedbackprocessing.py
Python
gpl-3.0
1,244
########################################################################### ## PyBot ## ## Copyright (C) 2015, Kyle Repinski ## ## ## ## This program ...
MWisBest/PyBot
Commands/pun/pun.py
Python
gpl-3.0
1,692
# coding=utf-8 from django.shortcuts import render,render_to_response,get_object_or_404 from django.http import HttpResponse,HttpResponseRedirect from interfapp.interface_form import InterfaceForm,ProjectForm,CaseForm,OwnerForm from interfapp.models import Project,Interfaces,Case from django.views.decorators.csrf impor...
EmerJuny/djcasemg
interfmg/interfapp/views.py
Python
gpl-3.0
14,221
# prosaicweb # Copyright (C) 2016 nathaniel smith # # 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 Foundation, either version 3 of the License, or # (at your option) any later version. # # T...
nathanielksmith/prosaicweb
prosaicweb/models.py
Python
agpl-3.0
3,373
#!/usr/bin/env python # -*- coding: utf-8 -*- # # Copyright 2016 University of Oslo, Norway # # This file is part of Cerebrum. # # Cerebrum 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 t...
unioslo/cerebrum
Cerebrum/modules/exchange/config.py
Python
gpl-2.0
7,395