code
stringlengths
2
1.05M
repo_name
stringlengths
5
104
path
stringlengths
4
251
language
stringclasses
1 value
license
stringclasses
15 values
size
int32
2
1.05M
from lib.models.basemodels import *
hzlf/openbroadcast
website/lib/models/__init__.py
Python
gpl-3.0
35
# -*- coding: utf-8 -*- # # segraph documentation build configuration file, created by # sphinx-quickstart on Wed May 31 11:53:59 2017. # # 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. # # A...
alivcor/segraph
docs/conf.py
Python
gpl-3.0
4,734
# -*- coding: utf-8 -*- """ Created on Thu Sep 12 09:25:49 2013 @author: ozdemircili """ """ Installation: pip install clint """ from clint.textui import colored, indent, puts print 'Colored output ' + colored.yellow('pyt') + colored.blue('hon') '''Indent Example''' with indent(3, quote=colored.red(' >')): pu...
ozdemircili/pycheat
pycheat/clint.py
Python
gpl-3.0
487
from zope.interface import Interface, Attribute class IPengine(Interface): """Interface to a pengine thread on a server""" id=Attribute("Identifier (session) of pengine interaction.") options=Attribute("Dictionary of stanadard options used in communications") connection=Attribute("Connection data in f...
eugeneai/pengines
pengines/interfaces.py
Python
gpl-3.0
1,735
# Author: Dieter Blomme <dieterblomme@gmail.com> # URL: http://code.google.com/p/sickbeard/ # # This file is part of Sick Beard. # # Sick Beard 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 ver...
Zelgadis87/Sick-Beard
sickbeard/traktSync.py
Python
gpl-3.0
5,813
''' Created on 2014-02-13 A module that introduces a special class intended for station datasets (i.e. time-series only). @author: Andre R. Erler, GPL v3 ''' # internal imports from geodata.base import Dataset, Variable, Axis from geodata.netcdf import DatasetNetCDF ## the basic station class, without a...
aerler/GeoPy
src/geodata/station.py
Python
gpl-3.0
3,438
""" Copyright (C) 2016 Travis DeWolf 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 t...
studywolf/pydmps
examples/draw_number_2_temporal_scaling.py
Python
gpl-3.0
1,727
#!/usr/bin/env python3 # Count Active Transactions import pymysql def mainactions(args_list, configs, db_cur) : # Count Active Transactions help_string=''' Usage: * Default: Returns the number of currently opened & tracked transaction Specify the Warning and Critical Thresholds as the next two ...
chalbersma/persist_transaction
perf/count_active_transactions.py
Python
gpl-3.0
1,679
from django.core.mail import send_mail from django.shortcuts import redirect, render # Create your views here. from contact.forms import ContactForm def contact(request): form_class = ContactForm # new logic! if request.method == 'POST': form = form_class(request.POST, request.FILES) if ...
osonwanne/smallplexsites
contact/views.py
Python
gpl-3.0
932
from fenics import * from time import time from helper import * import numpy as np import matplotlib as mpl mpl.rcParams['font.family'] = 'serif' mpl.rcParams['legend.fontsize'] = 'medium' mpl.rcParams['text.usetex'] = True mpl.rcParams['text.latex.preamble'] = ['\usepackage[mathsc...
pf4d/wood_pyrolysis
diblasi/p_diblasi_1998.py
Python
gpl-3.0
20,019
#!/usr/bin/env python2 import sys, os import json import argparse import sqlite3 as lite con = None def extant_file(x): if not os.path.exists(x): raise argparse.ArgumentError("{0} does not exist".format(x)) return x def main(): parser = argparse.ArgumentParser(description="Import flairs") pa...
thelectronicnub/redditswapbot
util/flair_sql_import.py
Python
gpl-3.0
1,111
from __future__ import print_function import argparse, os, requests, json, csv, shutil, gzip def dict_to_file(d): with open('dictionary.tsv', 'w') as outFile: writer = csv.writer(outFile, delimiter='\t') writer.writerow(['file_id', 'case_id']) for k in d: writer.writerow([k, d[k]]) def filter_metadat...
poddus/tcga_fetch_n_clean
fetch_n_clean_0.0.1.py
Python
gpl-3.0
8,154
from django.conf.urls import patterns, include, url from django.contrib import admin admin.autodiscover() urlpatterns = patterns('', # Examples: # url(r'^$', 'psybrowse.views.home', name='home'), # url(r'^blog/', include('blog.urls')), url(r'^', include('psybrowse_app.urls')), url(r'^admin/', inc...
jeff-hughes/PsyBrowse
psybrowse/urls.py
Python
gpl-3.0
346
""" Platform dependend OS calls - Windows edition FIXME Not tested, yet """ import logging import win32gui import ctypes from PyQt5.QtCore import QDir, QStandardPaths, QByteArray, QBuffer, QIODevice from extract_icon import ExtractIcon LOGGER = logging.getLogger(__name__) # Change windows 7 group ID myappid = 'net....
Cybso/gameplay
gameplay/platform/windows.py
Python
gpl-3.0
1,468
#!/usr/bin/env python # encoding=utf-8 # Author : idwar # http://secer.org ''' 可能需要你改的几个地方: 1、host 2、port 3、request中的phpinfo页面名字及路径 4、hello_lfi() 函数中的url,即存在lfi的页面和参数 5、如果不成功或报错,尝试增加padding长度到7000、8000试试 6、某些开了magic_quotes_gpc或者其他东西不能%00的,自行想办法截断并在(4)的位置对应修改 Good Luck :) 7、payload的./指的是当前脚本的目录下,所以要注意最后输出的结果 ''' i...
hackersql/sq1map
Web/信息收集/pentest_tools/漏洞利用/web漏洞/lfi/lfi_tmp.py
Python
gpl-3.0
2,542
import json from collections import OrderedDict import os class Config: config_file_path = './config.json' _instance = None def __init__(self): self.config = self.load_configs() def load_configs(self): dir_path = os.path.dirname(os.path.realpath(__file__)) with open(dir_path...
MShel/PyChatBot
config/Config.py
Python
gpl-3.0
891
#!/usr/bin/env python # -*- coding: utf-8; py-indent-offset:4 -*- ############################################################################### # # Copyright (C) 2015-2020 Daniel Rodriguez # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License a...
mementum/backtrader
backtrader/metabase.py
Python
gpl-3.0
11,160
## Copyright (C) 2012 by Kevin L. Mitchell <klmitch@mit.edu> ## ## 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. ## #...
klmitch/tendril
tendril/__init__.py
Python
gpl-3.0
12,025
# -*- coding: utf-8 -*- # Generated by Django 1.11.3 on 2017-07-26 21:00 from __future__ import unicode_literals from django.db import migrations, models import image_cropping.fields class Migration(migrations.Migration): dependencies = [ ('gardens', '0009_auto_20170726_2055'), ] operations = [...
bengosney/rhgd3
gardens/migrations/0010_auto_20170726_2100.py
Python
gpl-3.0
1,195
# -*- coding: utf-8 -*- # # Copyright (C) 2015-2016 Jakub Beranek # # This file is part of Devi. # # Devi 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 3 of the License, or # (at yo...
Kobzol/debug-visualizer
debugger/mi/mi_debugger.py
Python
gpl-3.0
6,700
# -*- coding: utf-8 -*- from module.plugins.internal.DeadCrypter import DeadCrypter, create_getInfo class HotfileComFolder(DeadCrypter): __name__ = "HotfileComFolder" __type__ = "crypter" __version__ = "0.3" __pattern__ = r'https?://(?:www\.)?hotfile\.com/list/\w+/\w+' __config__ = [] ...
sebdelsol/pyload
module/plugins/crypter/HotfileComFolder.py
Python
gpl-3.0
511
#!/usr/bin/env python """server.py.py: Module Description ...""" from __future__ import print_function import gevent import time import zmq.green as zmq import ga_messages_pb2 as gmessages __author__ = "Minos Galanakis" __license__ = "GPL3" __version__ = "0.0.1" __email__ = "minos197@gmail.com" __project__ = "ga" _...
minosg/guardian_angel
dev/prototyping/server.py
Python
gpl-3.0
2,369
# -*- coding: utf-8 -*- from django.conf import settings from pyerp.fnd.shortcuts import fnd_render_to_response from pyerp.fnd.gbl import fnd_global from pyerp.fnd.utils.version import get_svn_revision, get_version __svnid__ = '$Id$' __svn__ = get_svn_revision(__name__) def display_login_form(request, error_messa...
dreams6/pyerpcn
pyerp/fnd/functions/pub/login/views.py
Python
gpl-3.0
829
import os import sys def build_exe(filename, version="1.0.0", description="", author="", modules=[], includes=[], packages="[]", include_files=[], zip_includes=[], icon=None, additional_executables=[], target=None, window=True, onefile=True): args = [] if window: args.append("--noconsol...
madsmpedersen/MMPE
build_exe/pyinstaller/build_exe.py
Python
gpl-3.0
615
#!/usr/bin/env python ''' ThunderGate - an open source toolkit for PCI bus exploration Copyright (C) 2015-2016 Saul St. John 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, eith...
sstjohn/thundergate
py/main.py
Python
gpl-3.0
7,973
#!/usr/bin/env python # Small program for storing and retrieving paths from a database # Copyright (C) 2014 Gustav Behm # 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 ...
rootmos/qcd
qcd.py
Python
gpl-3.0
5,030
def my_power_func(n, a): if a == 0: return 1 y = my_power_func(n, a/2) if a % 2 == 0: return y*y else: return n*my_power_func(n, a-1) print my_power_func(3, 6)
purushothamc/myibitsolutions
mathematics/power_function.py
Python
gpl-3.0
194
# # Copyright 2017 Russell Smiley # # This file is part of timetools. # # timetools 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. # #...
blueskyjunkie/timeTools
timetools/synchronization/compliance/ituTG8262/eecOption2/noiseTransfer.py
Python
gpl-3.0
986
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import fields, models class SurveyStage(models.Model): _name = 'survey.stage' _description = 'Survey Stage' _order = 'sequence,id' name = fields.Char(required=True, translate=True) sequen...
t3dev/odoo
addons/survey/models/survey_stage.py
Python
gpl-3.0
637
""" WSGI config for circuitSimSite 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.8/howto/deployment/wsgi/ """ import os from django.core.wsgi import get_wsgi_application os.environ.setdefault("DJANG...
daniloefl/circuitSim
web/circuitSimSite/circuitSimSite/wsgi.py
Python
gpl-3.0
405
import functools from numpy import * arange = functools.partial(arange, dtype="float") array = functools.partial(array, dtype="float")
pavpanchekha/oranj
oranj/pystdlib/numpy_or.py
Python
gpl-3.0
136
from urbansearch.clustering import text_preprocessor p = text_preprocessor.PreProcessor() def test_strip_words(): text = ['de', 'buik', 'van', 'Marko'] expected = ['buik', 'Marko'] assert expected == p.strip_words(text) def test_strip_words_size(): text = ['aa', 'bbb', 'cccccccccccccccccccccccccccc...
urbansearchTUD/UrbanSearch
tests/clustering/test_text_preprocessor.py
Python
gpl-3.0
1,044
class Solution: # backtracking/recursion def subsets(self, nums): """ :type nums: List[int] :rtype: List[List[int]] """ def backtracking(ans, s_set, r_nums, s_len, t_len): if s_len == t_len: ans.append(s_set) return ...
YiqunPeng/Leetcode-pyq
solutions/78Subsets.py
Python
gpl-3.0
1,090
def to_icinga2_expression(a): return "\n".join([var2string(k, v) for (k, v) in a.items()]) def var2string(key, value): """ generate vars.*http_vhosts*[*Default Page*] = { ... } entries if value is a dict vars.*os* = ... entries if value is a string :param key: :param value: :return: ""...
zauberpony/ansible-to-icinga2
filter_plugins/to_icinga2.py
Python
gpl-3.0
1,574
#!/usr/bin/python """ CONFIG CONVERTER this script converts your custom tag string section from the v.3.1 syntax to the current format. >>> tagsections_convert.py -o config.new config.old will convert your whole alot config safely to the new format. """ from configobj import ConfigObj import argparse import...
dcbaker/alot
extra/tagsections_convert.py
Python
gpl-3.0
2,099
from .base import main
ForgemAR/rocket-tip-creation
conegen/__init__.py
Python
gpl-3.0
23
#!/usr/bin/python ################################################################################ ##3456789 123456789 123456789 123456789 123456789 123456789 123456789 123456789 ## 10 20 30 40 50 60 70 80 ## ## Info: ## Example of how to use libnotify correctl...
dkasak/notify-osd-customizable
examples/append-hint-example.py
Python
gpl-3.0
5,175
#################################################################################################### # # Patro - A Python library to make patterns for fashion design # Copyright (C) 2019 Fabrice Salvaire # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero Gene...
FabriceSalvaire/PyValentina
tools/license-template.py
Python
gpl-3.0
965
#!/usr/bin/env python # -*- coding: UTF-8 -*- ''' # # DAI - Desarrollo de Aplicaciones para Internet # # 2014 Ernesto Serrano <erseco@correo.ugr.es> # #----------------------------------------------- Cree un programa que lea de un fichero de texto un numero entero n y escriba en otro fichero de texto el n-esimo numer...
erseco/ugr_desarrollo_aplicaciones_internet
Practica_01/ejercicio_04.py
Python
gpl-3.0
997
# This file is part of Indico. # Copyright (C) 2002 - 2016 European Organization for Nuclear Research (CERN). # # Indico 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 (a...
OmeGak/indico-plugins
livesync/tests/uploader_test.py
Python
gpl-3.0
6,150
# -*- coding: utf-8 -*- # Form implementation generated from reading ui file 'User_interface.ui' # # Created: Tue May 16 10:33:40 2017 # by: PyQt4 UI code generator 4.10.4 # # WARNING! All changes made in this file will be lost! from PyQt4 import QtCore, QtGui try: _fromUtf8 = QtCore.QString.fromUtf8 except...
jocoteles/photogate
PyQtGate/User_interface.py
Python
gpl-3.0
62,173
from OpenGL.GL import glUniformMatrix4fv, glUniform2fv, glUniform4fv class MatrixUniform: def __init__(self, data): self._data = data def bind(self, uniform_location): count = 1 transpose = False glUniformMatrix4fv(uniform_location, count, transpose, self._data) class VectorU...
nicholasbishop/bel
bel/uniform.py
Python
gpl-3.0
697
from _winreg import * import boto3 import botocore import os def GetCredentialsFromUser(): print "IN GetCredentialsFromUser" try: ASKI = os.environ['AWS_ACCESS_KEY_ID'] except: ASKI = raw_input("\n\nAWS Access Key ID: ") try: ASAK = os.environ['AWS_SECRET_ACCESS_KEY'] except: ASAK = ra...
pktomlinson/awsregkeys
readwinreg.py
Python
gpl-3.0
1,449
class Communicator: def __init__(self, group): self.group = group radio.on() radio.config(group=group) def send_command(self, command, value): vals = {} vals["command"] = command vals["value"] = value data = ":".join([str(x) + "," + str(vals[x]) for x in ...
mdaudali/AdventureBit-MicroBit-Project
utilities.py
Python
gpl-3.0
639
# Copyright 2011 # # Author: Dorgival Guedes # Author: Kyriakos Zarifis # # This file is part of POX. # Some of the arp/openflow-related code was borrowed from dumb_l3_switch. # # POX is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Fre...
jmiserez/pox
pox/host_tracker/buggy_host_tracker.py
Python
gpl-3.0
10,685
# # Copyright 2005,2006 Free Software Foundation, Inc. # # This file is part of GNU Radio # # GNU Radio is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3, or (at your option) # any later versi...
trnewman/VT-USRP-daughterboard-drivers_python
gnuradio-core/src/python/gnuradio/blksimpl/qam16.py
Python
gpl-3.0
7,447
# -*- coding: utf-8 -*- import scrapy import json import re class MeetingsSpider(scrapy.Spider): name = "meetings" allowed_domains = ["ratsinfo.leipzig.de"] def start_requests(self): url = getattr( self, "start_url", "https://ratsinfo.leipzig.de/bi/oparl/1.0/me...
CodeforLeipzig/allris-scraper
allris/spiders/meetings.py
Python
gpl-3.0
843
""" Test that Layers work as advertised. """ from __future__ import print_function from __future__ import division from __future__ import unicode_literals __author__ = "Han Altae-Tran and Bharath Ramsundar" __copyright__ = "Copyright 2016, Stanford University" __license__ = "GPL" import numpy as np import unittest im...
bowenliu16/deepchem
deepchem/nn/tests/test_layers.py
Python
gpl-3.0
4,390
#!/usr/bin/env python2.6 # -*- coding: utf-8 -*- import sys import logging ### RESTful service routing from optparse import OptionParser from bottle import route, run, debug, request, static_file _SENSOR_FULL_NAMES= { "t" : u"Temperature (ºC)", "p" : "Pressure (Pascal)", "a" : "Air ...
guyzmo/PolluxNZcity_PoC
PolluxInTheCloud/polluxinthecloud.py
Python
gpl-3.0
19,860
import six from django.forms.models import ModelFormMetaclass, ModelForm from django.template import loader from django.http import Http404, HttpResponse, HttpResponseRedirect from django.core.exceptions import ObjectDoesNotExist, ImproperlyConfigured from django.utils.translation import ugettext from django.contrib.a...
Karaage-Cluster/karaage-debian
karaage/common/create_update.py
Python
gpl-3.0
8,549
# -*- coding: utf-8 -*- # Generated by Django 1.10.4 on 2017-09-14 18:48 from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('authorization', '0004_auto_20170628_1323'), ] operations = [ migrations.Alt...
erudit/zenon
eruditorg/core/authorization/migrations/0005_auto_20170914_1348.py
Python
gpl-3.0
1,272
# -*- coding: utf-8 -*- """This module implements the standalone filtering tool in the chaosc framework. It uses the chaosc osc_lib but does not depend on chaosc features, so it can be used with other osc compatible gear. We provide here osc message filtering based on python regex defined in a file and a very flexib...
DerLiveCode/chaosc
chaosc/chaosc_filter.py
Python
gpl-3.0
6,118
""" 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, but WITHOUT...
fneuorg/fneuproject
tests/settings_test.py
Python
gpl-3.0
863
from __future__ import absolute_import, unicode_literals import csv from builtins import str import time import os, sys # setting django environment from django.core.wsgi import get_wsgi_application from config import * sys.path.append(SPOKEN_PATH) os.environ["DJANGO_SETTINGS_MODULE"] = "spoken.settings" application = ...
Spoken-tutorial/spoken-website
cron/tasks.py
Python
gpl-3.0
8,023
from django.db import models, migrations class Migration(migrations.Migration): dependencies = [ ("forum", "0003_auto_20150414_2324"), ] operations = [ migrations.AlterField( model_name="topic", name="is_locked", field=models.BooleanField(default=False...
ChantyTaguan/zds-site
zds/forum/migrations/0003_auto_20151110_1145.py
Python
gpl-3.0
429
#!/usr/bin/env python from scribus import * import os, time, datetime, math ###################################### imagepath = "/data/projects/slitscan/malisca/tile-data/2011-12-16--chunar-banares/128" imagepath = "/data/projects/slitscan/malisca/tile-data/2012-03-21--istanbul-straight/128" imagepath = "/data/projec...
backface/malisca
tools/scribus/a6-postkarten.py
Python
gpl-3.0
3,321
import abc import collections import logging import time from golem.core.databuffer import DataBuffer from golem.core.simplehash import SimpleHash from golem.core.simpleserializer import SimpleSerializer logger = logging.getLogger(__name__) class Message: """ Communication message that is sent in a...
imapp-pl/golem
golem/network/transport/message.py
Python
gpl-3.0
70,548
#!/usr/bin/env python3 # vim:fileencoding=utf-8 # # FreeDB2MusicBrainz.py: Submit data from FreeDB to MusicBrainz # Copyright © 2017 Frederik “Freso” S. Olesen <https://freso.dk/> # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published...
Freso/freedb2musicbrainz
freedb2musicbrainz.py
Python
gpl-3.0
3,656
# KissTodo - a simple, Django based todo management tool. # Copyright (C) 2011 Massimo Barbieri - http://www.massimobarbieri.it # # 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 ...
BRupholdt/KissTodo
todo/models.py
Python
gpl-3.0
10,319
# -*- coding: utf-8 -*- from module.plugins.internal.SimpleCrypter import SimpleCrypter, create_getInfo class UploadableChFolder(SimpleCrypter): __name__ = "UploadableChFolder" __type__ = "crypter" __version__ = "0.06" __status__ = "testing" __pattern__ = r'http://(?:www\.)?uploadable\.ch...
fzimmermann89/pyload
module/plugins/crypter/UploadableChFolder.py
Python
gpl-3.0
1,264
# -*- coding: utf-8 -*- # Generated by Django 1.10.5 on 2017-02-16 05:35 from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('api', '0002_auto_20170215_0652'), ] operations = [ migrations.AddField( ...
makemytrip/webGuard-Server
api/migrations/0003_zapinstance_pid.py
Python
gpl-3.0
505
#-*- coding: utf-8 -*- from django.views.decorators.csrf import csrf_exempt from django.shortcuts import render from django.http import HttpResponse from profs.processing import * from profs.models import * from profs.forms import * def main(re...
LeMinaw/minaw.net
profs/views.py
Python
gpl-3.0
3,465
# Python Scripts for the Card Fighters' Clash definition for OCTGN # Copyright (C) 2013 Raohmaru # This python script 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 ...
raohmaru/CFC
o8g/Scripts/rs/RuleScript_abilities.py
Python
gpl-3.0
7,534
#!/usr/bin/env python import os import sys if __name__ == "__main__": os.environ.setdefault("DJANGO_SETTINGS_MODULE", "checkmate.settings") from django.core.management import execute_from_command_line execute_from_command_line(sys.argv)
esrefozturk/checkmate
checkmate/manage.py
Python
gpl-3.0
252
""" ======================== Cycle finding algorithms ======================== """ from collections import defaultdict import networkx as nx from networkx.utils import not_implemented_for, pairwise __all__ = [ "cycle_basis", "simple_cycles", "recursive_simple_cycles", "find_cycle", "minimum_cycle...
SpaceGroupUCL/qgisSpaceSyntaxToolkit
esstoolkit/external/networkx/algorithms/cycles.py
Python
gpl-3.0
21,635
import pygame from pygame.locals import * from basic_objects import MovingObject, Map class App: def __init__(self): self._maze = None self._moving_thing = None self._running = True self._image_black = None self._image_white = None self._image_mthing = None ...
antonionikolov/blind-labyrinth
gui.py
Python
gpl-3.0
3,611
from collections import OrderedDict from WowItem import Item import math class Character: def __init__(self): # base stats are taken from a lvl 70 character # or look those stats up from wowwiki self._baseStats = OrderedDict([ ("mana", 0), ("spellcrit", 0), ("i...
nessz/tbc_theory-crafter
ClassSpecs/StandardCharacter.py
Python
gpl-3.0
4,156
# -*- coding: utf-8 -*- import os def cls(): os.system('cls' if os.name == 'nt' else 'clear') cls() nome = raw_input('Digite seu nome: ') print 'Olá %s' % nome
fcomaciel/python
exercicio2.2.py
Python
gpl-3.0
169
# # TestConstants.py # # 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 ...
octronic-uk/python-web-apis
octronic/webapis/user/test/TestConstants.py
Python
gpl-3.0
843
"""Unit tests for the mmap backed array class. Tests are a modified version of the pypy array unit tests.""" import sys import py from pytest import raises class BaseArrayTests: def test_ctor_basic(self): assert len(self.array('B')) == 0 assert len(self.array('i')) == 0 raises(TypeError, s...
JaggedVerge/mmap_backed_array
mmap_backed_array/tests/test_array.py
Python
gpl-3.0
18,864
# -*- coding: utf-8 -*- __author__ = 'Xabier Fernandez Gutierrez' __copyright__ = 'Copyright (C) 2017,Xabier Fernandez Gutierrez' __credits__ = 'Xabier Fernandez Gutierrez' __license__ = 'GNU GPL v3.0 ' __version__ = '2017.01' __maintainer__ = 'Xabier Fernandez Gutierrez' __email__ = 'xabier.fernandez@outlook.com' # F...
XabierFernandez/Scripts-For-Robots
ABB/Robtargets_Converter/GUI/ABB_RapidTools.py
Python
gpl-3.0
32,147
# Authors: # Derek Battams <derek@battams.ca> # Pedro Jose Pereira Vieito (@pvieito) <pvieito@gmail.com> # # URL: https://github.com/sickgear/sickgear # # This file is part of SickGear. # # SickGear is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as publish...
jetskijoe/SickGear
sickbeard/notifiers/emailnotify.py
Python
gpl-3.0
7,110
from django.conf.urls.defaults import url, patterns from django.contrib.aderit.access_account.views import (LoginView, LogoutView, UpdateView, ChangePasswordView, ...
safanaj/django-contrib-aderit
project_template/account/urls.py
Python
gpl-3.0
3,092
""" Define the base Protocol classes and meta-classes. For documentation on broker and common message types see parlay.protocols:: """ class InvalidProtocolDeclaration(Exception): """ Raised when there was a problem with your protocol declaration """ pass class ProtocolMeta(type): """ Meta-...
PromenadeSoftware/Parlay
parlay/protocols/meta_protocol.py
Python
gpl-3.0
1,074
from django.conf.urls import url, patterns, include from django.conf import settings from rest_framework.urlpatterns import format_suffix_patterns from rest_framework import viewsets, routers from blog.feeds import BlogPostFeed, BlogPostFeedByCategory from blog import views """ # Routers provide an easy way of autom...
argonemyth/argonemyth-blog
blog/urls.py
Python
gpl-3.0
3,001
# -*- coding: utf-8 -*- """ Created on Sun Apr 27 10:59:45 2014 @author: James Ahad """ from django import forms from django.contrib.auth.models import User from idp.models import UserProfile, Sequence, Sequence_seqdata, Sequence_jobs class UserForm(forms.ModelForm): username = forms.CharField(help_text="Please ...
panda4life/idpserver
mysite/idp/forms.py
Python
gpl-3.0
20,697
from pyatompaw import AtompawMaster # Atom definition atom = AtompawMaster('14-Si') atom.Atom_name = 'Si' atom.Z = 14 # Keywords atom.XC_functional = 'LDA-PW' atom.projector_keyword = 'custom' atom.logderivrange = 'logderivrange', -6, 10, 2001 atom.ps_scheme = 'rrjk' atom.ortho_scheme = 'gramschmidtortho' atom.Vloc_s...
GkAntonius/pyatompaw
examples/Si.py
Python
gpl-3.0
1,075
from backend import db class Institution(db.Model): id = db.Column(db.Integer, primary_key=True) name = db.Column(db.String(250)) abbreviation = db.Column(db.String(20)) cnpj = db.Column(db.String(18), unique=True) address = db.Column(db.String(250)) current_program_section = db.Column(db.Str...
sandroandrade/emile-server
cruds/crud_institution/models.py
Python
gpl-3.0
680
# -*- coding: utf-8 -*- ''' Mepinta Copyright (c) 2011-2012, Joaquin G. Duo This file is part of Mepinta. Mepinta 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 opti...
joaduo/mepinta
plugins/c_and_cpp/k3dv1/plugins/c_and_cpp/processors/k3dv1/bitmap/generators/bitmap_checker/bitmap_checker__0001.py
Python
gpl-3.0
1,211
#!/usr/bin/env python3 '''OpenVG context access.''' # Copyright © 2013-14 Tim Pederick. # # This file is part of Povg. # # Povg 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...
perey/povg
povg/context/__init__.py
Python
gpl-3.0
25,961
from panda3d.core import ( Geom, GeomNode, GeomTristrips, GeomVertexFormat, GeomVertexData, GeomVertexWriter, Vec3, ) from utils import center, lerp class Level: def __init__(self, border, top, cover=True): self.fmt = GeomVertexFormat.getV3c4() self.border = borde...
Alkxzv/procedural-city
buildings.py
Python
gpl-3.0
2,213
# Copyright 2016 Sam Parkinson <sam@sam.today> # # This file is part of Something for Reddit. # # Something for Reddit 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 ...
samdroid-apps/something-for-reddit
redditisgtk/buttons.py
Python
gpl-3.0
9,564
from ImportModel import load_unet import numpy as np from PIL import Image from os.path import join import matplotlib.pyplot as plt import cv2 dim = 512 unet = load_unet(input_shape=(dim, dim, 3), weight_path='text_segmentation.h5') def segment_im(im, dim=dim): def postprocess(im): im[im < 0.1] = 0 ...
Rignak/Scripts-Python
DeepLearning/_Others/OCR/in2thumb.py
Python
gpl-3.0
1,989
# Copyright 2014-2016 The ODL development group # # This file is part of ODL. # # ODL 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. #...
bgris/ODL_bgris
lib/python3.5/site-packages/odl/tomo/operators/ray_trafo.py
Python
gpl-3.0
16,832
#!/usr/bin/python import Adafruit_GPIO as GPIO import time, os #print "GETTING GPIO OBJECT" gpio = GPIO.get_platform_gpio() #print "SETUP CSID1" #gpio.setup("CSID1", GPIO.OUT) #print os.path.exists('/sys/class/gpio/gpio133') #print "SETUP XIO-P1" #gpio.setup("XIO-P1", GPIO.IN) #GPIO.setup("U14_13", GPIO.IN) #prin...
fantoms/psychic-octo-spork
chipenable.py
Python
gpl-3.0
1,216
''' Created on 07.02.2018 @author: michael ''' import codecs import logging import os import re import shutil import struct import sys import tempfile from _io import BytesIO from math import ceil from subprocess import call from injector import inject, provider, ClassProvider, singleton, Module from PIL import Ima...
archivsozialebewegungen/AlexandriaBase
alexandriabase/services.py
Python
gpl-3.0
69,870
#!/usr/bin/python # -*- coding: utf-8 -*- """ ZetCode Tkinter tutorial This script shows a simple window on the screen. Author: Jan Bodnar Last modified: November 2015 Website: www.zetcode.com """ from Tkinter import Tk, Frame, BOTH from ttk import Button, Style class myApp(Frame): def __init__(self, paren...
iosonosempreio/getsorted
ex1.py
Python
gpl-3.0
1,164
# encoding: utf-8 # # # 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/. # # Author: Kyle Lahnakoski (kyle@lahnakoski.com) # from __future__ import absolute_import from __f...
maggienj/ActiveData
jx_elasticsearch/es14/deep.py
Python
mpl-2.0
10,475
import pathlib __author__ = 'EAMY' __email__ = 'team@eamy.org' __version__ = '0.1.0' from . import config datapath = pathlib.Path('.').resolve().joinpath(config.DATADIR) config.DATADIR = str(datapath) config.PIDFILE = str(datapath.joinpath(config.PIDFILE)) config.LOGFILE = str(datapath.joinpath(config.LOGFILE))
eamy-org/imi
imi/__init__.py
Python
mpl-2.0
316
# flake8: noqa # 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/. from .logger import * from .loglistener import LogMessageServer from .loggingmixin import LoggingMixin
Yukarumya/Yukarum-Redfoxes
testing/mozbase/mozlog/mozlog/unstructured/__init__.py
Python
mpl-2.0
318
#!/usr/bin/env python # -*- coding: utf-8 -*- """ Get current date. """ import datetime CURDATE = None def get_current_date(): """ Returns the current date as a date object. """ return datetime.date.today() if __name__ == '__main__': CURDATE = get_current_date() print CURDATE
rrafiringa/is210-week-05-synthesizing
task_01.py
Python
mpl-2.0
308
# coding=utf-8 ''' @author:黄鑫晨 2016.12 ''' import json import urllib import urllib2 from mod.databases.tables import Users _uuid = 'fd4b2c58db1e394d312c9e7ca53e588999f491ce' def get_uinfo_from_uuid(_uuid): """ 通过uuid 获取一卡通号,获得真实姓名等信息 """ _check_path = 'http://www.heraldstudio.com/api/user' # prin...
HeraldStudio/HeraldAppApi
mod/huati/getUserInfo.py
Python
mpl-2.0
3,658
import json from configparser import ConfigParser, NoOptionError, NoSectionError import pymysql class Link(object): def __init__(self, *args): (self.kind, self.target, self.extra, self.slug, self.locale, self.hash) = args @property def args(self): return (self.kind, self.target,...
mythmon/sumomo-importer
sumomomig/utils.py
Python
mpl-2.0
2,741
# 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/. """ Maintain Signature data using crash data in Elasticsearch. """ import datetime from django.core.management.base im...
lonnen/socorro
webapp-django/crashstats/crashstats/management/commands/updatesignatures.py
Python
mpl-2.0
5,999
import json def test_patch_status(client, bugs, header_bot): """ Fetch detailled analysis, with bugs """ from shipit_uplift.models import BugResult url = '/bugs/1139560/patches' revision = '80c32af73390' # existing patch revision branch = 'test' # Check patches in bug payload bug...
andrei987/services
src/shipit_uplift/tests/test_patch_status.py
Python
mpl-2.0
1,729
import importlib import sys sys.path.append("modules/problems/alltoall") ''' Temporarily using term "model" to represent some form of "operations" ''' def get_model(params): mod = importlib.import_module("app") app = mod.get_app(params) return app
undertherain/benchmarker
benchmarker/kernels/alltoall/openmpi.py
Python
mpl-2.0
264
# -*- coding: utf-8 -*- # 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 responses import pytest import json @responses.activate def test_conf(mock_config): ...
srfraser/services
src/shipit_static_analysis/tests/test_reporter_mail.py
Python
mpl-2.0
2,723
class UNPREPARED(DataClassification): editprotect=True name="UNPREPARED" usage = 'Applies to un-"prepared" datasets, datasets which have not had the prepare task run on them.' parent = "RAW" requirement= PHU({'{prohibit,re}.*?PREPAR*?': ".*?" }) newtypes.append(UNPREPARED())
pyrrho314/recipesystem
trunk/dontload-astrodata_Gemini/ADCONFIG_Gemini/classifications/status/gemdtype.UNPREPARED.py
Python
mpl-2.0
301
from django.apps import AppConfig class GroupsConfig(AppConfig): name = "agir.groups"
lafranceinsoumise/api-django
agir/groups/apps.py
Python
agpl-3.0
92
# -*- coding: utf-8 -*- # # 2015-05-15 Cornelius Kölbel <cornelius.koelbel@netknights.it> # Initial writup # # License: AGPLv3 # # This code is free software; you can redistribute it and/or # modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE # License as published by the Free Software Fou...
jalr/privacyidea
privacyidea/api/caconnector.py
Python
agpl-3.0
3,052