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
# -*- coding: utf-8 -*- # Copyright(c) 2016-2020 Jonas Sjöberg <autonameow@jonasjberg.com> # Source repository: https://github.com/jonasjberg/autonameow # # This file is part of autonameow. # # autonameow is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public L...
jonasjberg/autonameow
tests/unit/test_core_config_config_parser.py
Python
gpl-2.0
21,677
#!/usr/bin/python -tt """This checks that the include guard is complete and the same style.""" import os def find_relpath_to_base_dir(abspath): fn = os.path.abspath(abspath) while fn != '/' and os.path.basename(fn) != 'src': fn = os.path.abspath(os.path.join(fn, os.path.pardir)) return os.path.r...
widelands/widelands
cmake/codecheck/rules/wrong_or_missing_include_guard.py
Python
gpl-2.0
1,025
from io import StringIO _max_depth = 10 def _convert_to_string(d): return _str("\"%s\"" % (_str(d).\ replace('\\', '\\\\').\ replace('"', '\\"'))) # Python 2/3 compatibility. _str = str try: unicode long except NameError: unicode = str l...
dsoprea/pytzPure
pytzpure/random_utility/get_as_python.py
Python
gpl-2.0
2,594
import sys import argparse import os.path as op class InputSourceError(Exception): def __init__(self, value): self.text = value def __str__(self): print("INPUT SOURCE ERROR: ".format(self.text)) print("No file or directory incorrect") class UserInputParse(object): ''' ...
rCorvidae/CppPyDoc
UserInputParse.py
Python
gpl-2.0
1,672
class aMSNMainWindow(object): """ This Interface represents the main window of the application. Everything will be done from here When the window is shown, it should call: amsn_core.mainWindowShown() When the user wants to close that window, amsn_core.quit() should be called. """ def __init__(self...
kakaroto/amsn2
amsn2/ui/base/main.py
Python
gpl-2.0
647
#!/usr/bin/env python import os import sys if __name__ == "__main__": os.environ.setdefault("DJANGO_SETTINGS_MODULE", "timeatworkapi.settings") from django.core.management import execute_from_command_line execute_from_command_line(sys.argv)
Tryle/time-at-work-api
manage.py
Python
gpl-2.0
256
# This file is part of WSRC. # # WSRC 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. # # WSRC is distributed in the hope that it will ...
perrys/WSRC
modules/wsrc/site/courts/apps.py
Python
gpl-2.0
951
"""Check for use of for loops that only check for a condition.""" from typing import TYPE_CHECKING from astroid import nodes from pylint.checkers import BaseChecker from pylint.checkers.utils import check_messages, returns_bool from pylint.interfaces import IAstroidChecker if TYPE_CHECKING: from pylint.lint.pyli...
PyCQA/pylint
pylint/extensions/for_any_all.py
Python
gpl-2.0
2,677
from Plugins.SystemPlugins.Hotplug.plugin import hotplugNotifier from Components.Button import Button from Components.Label import Label from Components.ActionMap import ActionMap from Components.MenuList import MenuList from Components.FileList import FileList from Components.Task import Task, Job, job_manager, Condit...
popazerty/openhdf-enigma2
lib/python/Plugins/SystemPlugins/SoftwareManager/Flash_online.py
Python
gpl-2.0
24,740
#!/usr/bin/python3 import subprocess, sys sys.path.append('/root/hubops') project_dir = '/root/hubops' def vagrant_health_checks(): #Check for vagrant init current_status = subprocess.call(['{}/exec_scripts/vagrant_up.sh'.format(project_dir),'c_init']) if current_status == 0: print("Vagrant was al...
containscafeine/hubops
exec_scripts/vagrant_launch.py
Python
gpl-2.0
2,600
#!/usr/bin/python # -*- coding: utf-8 -*- import re from glob import glob from os import path from subprocess import Popen, PIPE # Local module: generator for texture lookup builtins from texture_builtins import generate_texture_functions builtins_dir = path.join(path.dirname(path.abspath(__file__)), "..") # Read t...
rex-xxx/mt6572_x201
external/mesa3d/src/glsl/builtins/tools/generate_builtins.py
Python
gpl-2.0
8,394
# ============================================================================ # # Copyright (C) 2007-2012 Conceptive Engineering bvba. All rights reserved. # www.conceptive.be / project-camelot@conceptive.be # # This file is part of the Camelot Library. # # This file may be used under the terms of the GNU General...
jeroendierckx/Camelot
camelot/view/controls/editors/imageeditor.py
Python
gpl-2.0
9,076
from qgis.core import QgsMessageLog try: import local_settings log_it = local_settings.log_it category = local_settings.category except ImportError: log_it = False def msg(txt): if log_it: QgsMessageLog.logMessage(txt, category)
NathanW2/qgiscommand
logger.py
Python
gpl-2.0
260
from abapy.mesh import Mesh, Nodes mesh = Mesh() nodes = mesh.nodes # Adding some nodes nodes.add_node(label = 1, x = 0. ,y = 0. , z = 0.) nodes.add_node(label = 2, x = 1. ,y = 0. , z = 0.) nodes.add_node(label = 3, x = 1. ,y = 1. , z = 0.) nodes.add_node(label = 4, x = 0. ,y = 1. , z = 0.) nodes.add_node(label = 5, x ...
lcharleux/abapy
doc/example_code/mesh/Mesh-add_set.py
Python
gpl-2.0
808
############################################################################### # # # Copyright 2019. Triad National Security, LLC. All rights reserved. # # This program was produced under U.S. Government contract 89233218CNA000001 # ...
CSD-Public/stonix
src/stonix_resources/rules/ConfigurePowerManagement.py
Python
gpl-2.0
17,321
import os import logging DEBUG = True SQLALCHEMY_ECHO = True SECURITY_CONFIRMABLE = True SECURITY_SEND_REGISTER_EMAIL = True SQLALCHEMY_DATABASE_URI = os.environ['DATABASE_URL'] SECRET_KEY = os.environ['SECRET_KEY'] logger = logging.getLogger('Sourcemash') stream_handler = logging.StreamHandler() logger.addHandler...
sourcemash/Sourcemash
config/staging.py
Python
gpl-2.0
409
from django.conf.urls import url from apprest import views urlpatterns = [ url(r'^libro/$', views.lista_libro), url(r'^autor/$', views.lista_autor), url(r'^$', views.lista_libro), ]
srmf9/aplicacion-libros
test_rest/urls.py
Python
gpl-2.0
195
""" Django settings for mysite project. Generated by 'django-admin startproject' using Django 1.10.2. For more information on this file, see https://docs.djangoproject.com/en/1.10/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/1.10/ref/settings/ """ import os ...
algui91/djangoTutorialv1.5
mysite/settings.py
Python
gpl-2.0
3,126
# Patchwork - automated patch tracking system # Copyright (C) 2011 Jeremy Kerr <jk@ozlabs.org> # # This file is part of the Patchwork package. # # Patchwork 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...
joselamego/patchwork
patchwork/tests/test_confirm.py
Python
gpl-2.0
2,717
from util import testAttribute, error from util import testIntAttribute def test(): print 'testing source code syntax' from xml.dom.html import HTMLUListElement from xml.dom import implementation doc = implementation.createHTMLDocument('Title') u = doc.createElement('UL') print 'testing get/se...
Pikecillo/genna
external/PyXML-0.8.4/test/dom/html/test_ul.py
Python
gpl-2.0
538
#!/usr/bin/env python from __future__ import print_function import json, sys, os from subprocess import call, check_output from shutil import copyfile import argparse parser = argparse.ArgumentParser() parser.add_argument('--norun', action='store_true') args = parser.parse_args() name = 'water2' pfx = os.path.join(o...
LukasSukenik/faunus
src/examples/water2.py
Python
gpl-2.0
2,890
# This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # bu...
autotest/arc
arc/test.py
Python
gpl-2.0
4,019
#!/usr/bin/env python2 import argparse import subprocess from dockerbot import SeleniumDocker from utils.net import random_port from utils.conf import docker as docker_conf if __name__ == "__main__": parser = argparse.ArgumentParser(argument_default=None) interaction = parser.add_argument_group('Ports') ...
thom-at-redhat/cfme_tests
scripts/dockerbot/sel_container.py
Python
gpl-2.0
1,602
#!/usr/bin/env python # # Copyright (c) 2014-2015 SUSE LLC # # This software is licensed to you under the GNU General Public License, # version 2 (GPLv2). There is NO WARRANTY for this software, express or # implied, including the implied warranties of MERCHANTABILITY or FITNESS # FOR A PARTICULAR PURPOSE. You should h...
SUSE/spacewalk-osad2
osad2/service.py
Python
gpl-2.0
898
# # script for testing ScGeom shear computation # Runs the same 2-sphere setup for useShear=False and for useShear=True # O.bodies.append([ utils.sphere([0,0,0],.5000001,dynamic=False,color=(1,0,0)), utils.sphere([0,0,1],.5000001,dynamic=True,color=(0,0,1)) ]) O.engines=[ InsertionSortCollider([Bo1_Sphere_...
woodem/woo
obsolete/test-OLD/shear.py
Python
gpl-2.0
1,243
from flask_wtf import FlaskForm from flask_wtf.file import FileField, FileRequired from wtforms import StringField, SubmitField, DateField, IntegerField,\ SelectField, DateTimeField, BooleanField, TextAreaField from wtforms import ValidationError from wtforms.validators import Required, Optional, Nu...
jyundt/oval
app/race/forms.py
Python
gpl-2.0
7,412
#Testing values for the dilation class from dilation import TimeDilation from datetime import timedelta interval = timedelta(days=365, hours=6) #interval = timedelta(days=2) speed = 7666.74 dilation = TimeDilation() variation = dilation.variationPerInterval(speed, interval) print("%s seconds gained." % variation)
davidjonas/timeDilation
python/test.py
Python
gpl-2.0
318
#------------------------------------------------------------------------------- # # Copyright (c) 2007, Enthought, Inc. # All rights reserved. # # This software is provided without warranty under the terms of the BSD # license included in /LICENSE.txt and may be redistributed only # under the conditions described...
HyperloopTeam/FullOpenMDAO
lib/python2.7/site-packages/traits-4.3.0-py2.7-macosx-10.10-x86_64.egg/traits/tests/interface_checker_test_case.py
Python
gpl-2.0
10,324
from functools import partial from pulsar import task, in_loop, Protocol, EventHandler, coroutine_return from . import base class PubsubProtocol(Protocol): def __init__(self, handler, *args, **kw): super(PubsubProtocol, self).__init__(*args, **kw) self.parser = self._producer._parser_class() ...
Ghost-script/dyno-chat
kickchat/apps/pulsar/apps/data/stores/pulsards/pubsub.py
Python
gpl-2.0
3,067
""" InaSAFE Disaster risk assessment tool developed by AusAid - **QGIS plugin implementation.** Contact : ole.moller.nielsen@gmail.com .. note:: 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 Foundat...
bstroebl/QGIS
python/plugins/sextante/tests/qgis_interface.py
Python
gpl-2.0
3,448
# DFF -- An Open Source Digital Forensics Framework # Copyright (C) 2009-2013 ArxSys # # This program is free software, distributed under the terms of # the GNU General Public License Version 2. See the LICENSE file # at the top of the source tree. # # See http://www.digital-forensic.org for more information about th...
arxsys/dff-unsupported
viewer/hist.py
Python
gpl-2.0
3,696
from django.contrib import admin import models # Register your models here. class MessageAdmin(admin.ModelAdmin): list_display = ("id", "title", "related_user", "related_event") list_filter = ("related_event","related_categories") search_fields = ("related_user__username", "related_event__name", "title", ...
Requinard/OperationSquid
sharing/admin.py
Python
gpl-2.0
577
""" NFS server set up and mount. """ import os import shutil from libvirttestapi.utils import process from . import utils def local_nfs_exported(nfs_path, logger): logger.info("Configure /etc/exports.") cmd = "grep -nr '%s' /etc/exports" % nfs_path ret = process.run(cmd, shell=True, ignore_status=True) ...
libvirt/libvirt-test-API
libvirttestapi/utils/nfs.py
Python
gpl-2.0
7,039
#!/usr/bin/python ############################################################################### # # # view.py # # ...
JoshDaly/footballdb
lib/python2.7/site-packages/footballdb/view.py
Python
gpl-2.0
5,617
#!/usr/bin/env python3 """ N queens problem. The (well-known) problem is due to Niklaus Wirth. This solution is inspired by Dijkstra (Structured Programming). It is a classic recursive backtracking approach. """ N = 8 # Default; command line overrides class Queens: def __ini...
pez2001/sVimPy
test_scripts/queens2a.py
Python
gpl-2.0
2,129
#!/usr/bin/python ### v0.1 ### Front-End Script by Ndaru (orasionseis@gmail.com) ### Mikrotik Script by Yudhis (yudhistira.anggi@gmail.com) ### Pyperclip Module by Coffeeghost. Source code : http://coffeeghost.net/2010/10/09/pyperclip-a-cross-platform-clipboard-module-for-python/ import os, sys, pyperclip, linecache ...
Orasion/msg
script/vpn_mobile2.py
Python
gpl-2.0
2,832
import wx class packet_information(wx.Frame): def __init__(self,packet_info_list, *args, **kw): wx.Frame.__init__(self, None, -1) # self.InitUI(packet_info_list) def InitUI(self, packet_info_list): dest_mac_addr=wx.StaticText(self, label='Destina...
guptaarchit/nacsniff
packet_info.py
Python
gpl-2.0
5,906
# Filename: virtlab.py # Summary: Writing test logs and case generator for virtlab. # Description: This module is for test logs and case generation use. # Maintainer: nzhang@redhat.com, xhu@redhat.com # Updated: Thu Apr 1, 2010 # Version: 0.1.0 import os import re from . import utils from . import process guest = {}...
libvirt/libvirt-test-API
libvirttestapi/utils/virtlab.py
Python
gpl-2.0
2,949
#!/usr/bin/env python # -*- encoding: utf-8 -*- """ Topic: python操作Excel 2007+ XLSX/XLSM Desc : 使用OpenPyxl来操作Excel 2007 xlsx/xlsm files. OpenPyxl is a Python library to read/write Excel 2007 xlsx/xlsm files. XLSM文件XLSX文件都是excel2007文件,但前者是含有宏启用,Excel中默认情况下不自动启用宏 另外如果只是写文件Excel 2007+ XLSX的话,可以使用XlsxWriter库 如果要读/写老版本的ex...
tongpo/Holle-World
py/python3-cookbook/basic/samples/excel/__init__.py
Python
gpl-2.0
491
""" Classes for parameters for exports and the results. @author: rwilkinson """ import logging import re import ecomaps.lib.outline_layer as outline_layer log = logging.getLogger(__name__) class ExportParameters: """Processes and holds the parameters for an export. """ def __init__(self, params, figureOp...
NERC-CEH/ecomaps
ecomaps/lib/export_parameters.py
Python
gpl-2.0
4,116
#!/usr/bin/env python # # Copyright (C) 2013 Julius Hader <bacon@linuxbbq.org> # and/or Joe Brock <DebianJoe@linuxbbq.org> # Forked from a PCLinuxOS Community Project # Copyright (C) 2007, 2008, 2009 Jan Michael Alonzo <jmalonzo@gmai.com> # # This program is free software; you can redistribute it and/or modify # it und...
DebianJoe/roaster
roaster.py
Python
gpl-2.0
27,479
# # Gramps - a GTK+/GNOME based genealogy program # # Copyright (C) 2000-2007 Donald N. Allingham # Copyright (C) 2010 Michiel D. Nauta # Copyright (C) 2011 Tim G L Lyons # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as publi...
Forage/Gramps
gramps/gen/lib/eventref.py
Python
gpl-2.0
8,963
# -*- coding: utf-8 -*- """ direct PAS Python Application Services ---------------------------------------------------------------------------- (C) direct Netware Group - All rights reserved https://www.direct-netware.de/redirect?pas;upnp The following license agreement remains valid unless any additions or changes a...
dNG-git/pas_upnp
src/dNG/data/upnp/resource.py
Python
gpl-2.0
22,391
#!/usr/bin/python # -*- coding: utf-8 -*- # # network.py - Copyright (C) 2012 Red Hat, Inc. # Written by Fabian Deutsch <fabiand@redhat.com> # # 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; ver...
sdoumbouya/ovirt-node
src/ovirt/node/config/network.py
Python
gpl-2.0
7,456
__author__ = 'ariel' #!/usr/bin/python3 import threading import time class Parameters(): def __init__(self): self.sum=0 self.ave=0 self.min=0 self.max=0 def set_sum(self, sum): self.sum = sum def set_ave(self, ave): self.ave = ave def set_min(self,...
arielisidro/myprograms
python/thread/Statistics.py
Python
gpl-2.0
3,467
# Patchwork - automated patch tracking system # Copyright (C) 2008 Jeremy Kerr <jk@ozlabs.org> # # This file is part of the Patchwork package. # # Patchwork 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...
joselamego/patchwork
patchwork/views/xmlrpc.py
Python
gpl-2.0
22,859
# -*- coding: utf-8 -*- ## ## This file is part of Invenio. ## Copyright (C) 2014 CERN. ## ## Invenio is free software; you can redistribute it and/or ## modify it under the terms of the GNU General Public License as ## published by the Free Software Foundation; either version 2 of the ## License, or (at your option) a...
MSusik/invenio
invenio/modules/workflows/testsuite/test_workflows_others.py
Python
gpl-2.0
3,587
""" Run external commands AUTHOR: - Badi' Abdul-Wahid CHANGES: - 2015-06-12: - return Result from `call` (issue #26) - add `run` (issue #27) - rename module to `subprocess` (issue #29) - 2015-06-11: - reimplement everything (issue #3) - 2014-07-25: - propagate CTRL-C to subprocess - ...
badi/pxul
pxul/subprocess.py
Python
gpl-2.0
6,314
# coding=utf-8 from django.forms import Widget, forms from django.utils.safestring import mark_safe from django.utils.html import escapejs from django.conf import settings class UMEditor(Widget): scheme = 'default' toolbar = 'mini' def __init__(self, attrs=None): attrs = attrs or {} attrs...
yuanxu/django-scaffold
scaffold_toolkit/forms/umeditor.py
Python
gpl-2.0
8,370
#!/usr/bin/env python # -*- coding: utf-8 -*- # # ============================================================================= # PAQUETE: instalador # ARCHIVO: instalador/config.py # COPYRIGHT: # (C) 2012 William Abrahan Cabrera Reyes <william@linux.es> # (C) 2012 Erick Manuel Birbe Salazar <erickcion@gmai...
willicab/instalador
instalador/pasos/__init__.py
Python
gpl-2.0
1,242
import unittest import main import sys import argparse import logging import time def run(): unittest.TextTestRunner(verbosity=2).run(suite()) def suite(): return unittest.TestLoader().loadTestsFromTestCase(TestSetup) class TestSetup(unittest.TestCase): def setUp(self): self.main = main.Main()...
EdvardPedersen/BasicPython
our_tests.py
Python
gpl-2.0
849
#!/usr/bin/python import wiringpi import sys, getopt import settings io = wiringpi.GPIO(wiringpi.GPIO.WPI_MODE_SYS) io.pinMode(settings.ThermPin,io.OUTPUT) def error_end(reason): #in case of an error, handle it by calling this function which kills #the sql connection, and sets the pin to low, closing the relay io....
davegreen/PiCH
core/killtherm.py
Python
gpl-2.0
477
def authorize(email, password): def _check(func): def inner(self, *args, **kwargs): self.login_user(email, password) x = func(self, *args, **kwargs) self.clear_user() return x return inner return _check def signature(params): """ Looks for...
Simversity/benchPress
api/core/decorators.py
Python
gpl-2.0
802
# # gPrime - A web-based genealogy program # # Copyright (C) 2002-2006 Donald N. Allingham # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your optio...
sam-m888/gprime
gprime/filters/rules/person/_familywithincompleteevent.py
Python
gpl-2.0
2,281
import matplotlib.pyplot as plot from Input import ColorGrabber from Resources.Colors import Colors, getColor from Algorithm.MenuGenerators.Menu import Menu class BrightnessMapGenerator(object): def __init__(self): pass def detectMenuPosition(self, width, height, oBitmap): iFollowingPoints = 0 ...
qjcina/GomokuBot
GomokuBot/GomokuBot/Algorithm/MenuGenerators/BrightnessMapGenerator.py
Python
gpl-2.0
5,005
"""Test generation helpers Intended to functionalize common tasks when working with the pytest_generate_tests hook. When running a test, it is quite often the case that multiple parameters need to be passed to a single test. An example of this would be the need to run a Provider Add test against multiple providers. W...
akrzos/cfme_tests
utils/testgen.py
Python
gpl-2.0
20,134
# This is a sample commands.py. You can add your own commands here. # # Please refer to commands_full.py for all the default commands and a complete # documentation. Do NOT add them all here, or you may end up with defunct # commands when upgrading ranger. # A simple command for demonstration purposes follows. # ---...
magnetophon/.dot
common/.config/ranger/commands.py
Python
gpl-2.0
13,638
# # Copyright (C) 2014 # Sean Poyser (seanpoyser@gmail.com) # # This Program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2, or (at your option) # any later version. # # This...
quequino/Revolution
script.tvguidedixie.tools/utils.py
Python
gpl-2.0
4,679
# # Copyright (C) 2006-2015 BalaBit IT Security, 2015-2017 BalaSys IT Security. # This program/include file is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License as published # by the Free Software Foundation; either version 2 of the License, or # (at your optio...
Balasys/kzorp
driver/tests/communication/testall.py
Python
gpl-2.0
1,163
#!/usr/bin/env python #coding=utf-8 import locale import serial, time import linecache from decimal import Decimal #===========================================================# # RASPBERRY PI (tested with Raspbian Jan 2012): # - Ensure that ttyAMA0 is not used for serial console access: # edit /boot/cmdline.txt (remov...
hiramvillarreal/iotpos
py-thermal-printer-master/printerlabel.py
Python
gpl-2.0
15,356
# -*- coding: utf-8 -*- # # This file is part of Invenio. # Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2014 CERN. # # Invenio is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License as # published by the Free Software Foundation; either version 2 of the # Li...
CERNDocumentServer/invenio
modules/websession/lib/websession_webinterface.py
Python
gpl-2.0
91,795
#! /usr/bin/env python """ counts number of FASTA sequences and total bases for each file with given extension example usage: python fasta-summary.py .fa Copyright: fasta-summary.py Print numbers of sequences and bases in FASTA file Copyright (C) 2016 William Brazelton This program is free software:...
Brazelton-Lab/lab_scripts
fasta-summary.py
Python
gpl-2.0
1,365
#!/usr/bin/env python # -*- coding: utf-8 -*- #****************************************************************************** # $Id: gdal_polygonize.py 25664 2013-02-22 15:43:33Z rouault $ # # Project: GDAL Python Interface # Purpose: Application for converting raster data to a vector polygon layer. # Author: ...
SmileEric/SEIMS
preprocess/gdal_polygonize.py
Python
gpl-2.0
6,461
import pickle import re from itertools import groupby class RLECompress: def __init__(self, file): self.file = file def verifier(self, objet): if isinstance(objet, list): return all(map(lambda elt: isinstance(elt, list), objet)) return False def dump(self, objet): ...
Loodoor/UrWorld-Alpha-3.x
src/compressor.py
Python
gpl-2.0
2,667
# -*- coding: utf-8 -*- # # This file is part of Glances. # # Copyright (C) 2017 Nicolargo <nicolas@nicolargo.com> # # Glances is free software; you can redistribute it and/or modify # it under the terms of the GNU Lesser General Public License as published by # the Free Software Foundation, either version 3 of the Lic...
fraoustin/ocglances
ocglances/plugins/glances_sensors.py
Python
gpl-2.0
9,941
# ##### BEGIN GPL LICENSE BLOCK ##### # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later version. # # This program is distrib...
PLyczkowski/Sticky-Keymap
2.74/scripts/addons/space_view3d_panel_measure.py
Python
gpl-2.0
55,863
""" Loaders ======= Workers to load files from disk. """ from Queue import Queue from PyQt4 import QtGui, QtCore import logging class WorkerImageLoader(QtCore.QThread): """ WorkerImageLoader ================= Worker to defered load images from local files. All the images will be scaled afther l...
arielvb/collector
collector/ui/workers/loaders.py
Python
gpl-2.0
1,585
# # Gramps - a GTK+/GNOME based genealogy program # # Copyright (c) 2015-2016 Gramps Development Team # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at ...
gramps-project/gramps_connect
gramps_connect/handlers/citationhandler.py
Python
gpl-2.0
3,311
import numpy import numpy.fft import numpy.linalg import numpy.random import scipy import scipy.constants import scipy.fftpack import scipy.integrate import scipy.interpolate import scipy.linalg import scipy.misc import scipy.optimize import scipy.special import scipy.stats import matplotlib import matplotlib.pyplot ...
viswimmer1/PythonGenerator
data/python_files/33569219/__init__.py
Python
gpl-2.0
656
#!/usr/bin/env python #-*- coding: utf-8 -*- import re __author__ = 'mah' __email__ = 'andrew.makhotin@gmail.com' import os import logging.handlers # keywork = ['qwerty'] keyword = ['Memorandum of Understanding', 'Revenue', 'Invoice', 'Statement', 'Asset Purchase Agreement', ...
mahandra/recipes_video_conv
local_scripts/parse_pdf.py
Python
gpl-2.0
3,950
### # GPGExt - supybot plugin to verify user identity on external sites using GPG keys # Copyright (C) 2011, Daniel Folkinshteyn <nanotube@users.sourceforge.net> # # 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 F...
tecan/xchat-rt
plugins/scripts/encryption/supybot-bitcoin-marketmonitor-master/GPGExt/test.py
Python
gpl-2.0
2,402
############################################################################## # # OpenERP, Open Source Management Solution # Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>). # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public L...
3dfxsoftware/cbss-addons
product_catalog_m321/report/product_catalog.py
Python
gpl-2.0
6,662
#!/usr/bin/env python """ lien http://www.java2s.com/Tutorial/Python/0360__Tkinker/Drawtext.htm http://effbot.org/tkinterbook/canvas.htm#Tkinter.Canvas.create_text-method http://apprendre-python.com/page-tkinter-interface-graphique-python-tutoriel http://www.java2s.com/Tutorial/Python/0360__Tkinker/Scrolledcanvas.htm ...
LionelJouin/Projet-STI2D-Parking-Vertical
Programme python/main.py
Python
gpl-2.0
615
from socket import error as socket_error from django.conf import settings from django import template from mcstatus import MinecraftServer from wagtail.wagtailcore.models import Page register = template.Library() @register.assignment_tag(takes_context=True) def get_site(context): # This returns a core.Page. T...
Uncaught-Exceptions/minedash
core/templatetags/core_tags.py
Python
gpl-2.0
2,357
# -*- coding: utf-8 -*- # # This file is part of Invenio. # Copyright (C) 2015, 2016 CERN. # # Invenio is free software; you can redistribute it # and/or modify it under the terms of the GNU General Public License as # published by the Free Software Foundation; either version 2 of the # License, or (at your option) any...
Dziolas/invenio-oaiserver-1
examples/app.py
Python
gpl-2.0
4,096
from util import error from util import testAttribute from util import testIntAttribute def test(): print 'testing source code syntax' from xml.dom.html import HTMLMapElement from xml.dom import implementation doc = implementation.createHTMLDocument('Title') m = doc.createElement('MAP') a = doc...
Pikecillo/genna
external/PyXML-0.8.4/test/dom/html/test_map.py
Python
gpl-2.0
551
# -*- coding: utf-8 -*- ## ## This file is part of Invenio. ## Copyright (C) 2014 CERN. ## ## Invenio is free software; you can redistribute it and/or ## modify it under the terms of the GNU General Public License as ## published by the Free Software Foundation; either version 2 of the ## License, or (at your option) a...
egabancho/invenio
invenio/modules/oaiharvester/workflows/oaiharvest_record_approval.py
Python
gpl-2.0
1,982
from time import strftime, localtime def now(): # now = strftime("%I:%M:%S %p", gmtime()) now = strftime("%A, %B %d, %Y @ %I:%M:%S %p", localtime()) return now def header(f): f.writelines(";(***************uWellPlate******************)\n") f.writelines(";(*** " + str(now()) + " ***)\n") f.writelines("""G91 ; ab...
Team02-TeamGuinness/BIOE421_RoboHand
ablation-GUI/writefile.py
Python
gpl-2.0
523
# -*- coding: utf-8 -*- """ Created on Sun Jan 17 18:15:03 2016 @author: jeroen """ import numpy import cv2 cap = cv2.VideoCapture(0) print "Frame default resolution: (" + str(cap.get(cv2.cv.CV_CAP_PROP_FRAME_WIDTH)) + ";" cap.set(cv2.cv.CV_CAP_PROP_FRAME_WIDTH, 1280) cap.set(cv2.cv.CV_CAP_PROP_FRAME_HEIGHT, 1024) ...
PublicVoids/ImageAveraging
Prog/try1.py
Python
gpl-2.0
1,248
#!/usr/bin/python import os from ncbi import get_ncbi_tax_name, taxid2parentid, taxid2name from ensembl import get_compara_name, species2taxid, get_species from mysql import switch_to_db, connect_to_mysql ######################################################### class Node: ##################################...
ivanamihalek/biogrid
bg_utils/tree.py
Python
gpl-2.0
7,352
import os import unittest import logging try: from unittest import mock except ImportError: import mock from crmsh import bootstrap from crmsh import sbd class TestSBDTimeout(unittest.TestCase): """ Unitary tests for crmsh.sbd.SBDTimeout """ @classmethod def setUpClass(cls): """...
ClusterLabs/crmsh
test/unittests/test_sbd.py
Python
gpl-2.0
43,302
#!/usr/bin/env python # -*- coding: utf-8 -*- from .dependency import Dependency from ..model.target import WPSState from ..util.process import Process import json class Wash(Dependency): ''' Wrapper for Wash program. ''' dependency_required = False dependency_name = 'wash' dependency_url = 'https://g...
derv82/wifite2
wifite/tools/wash.py
Python
gpl-2.0
2,328
# -*- coding: utf-8 -*- # # This file is part of Invenio. # Copyright (C) 2016 CERN. # # Invenio is free software; you can redistribute it # and/or modify it under the terms of the GNU General Public License as # published by the Free Software Foundation; either version 2 of the # License, or (at your option) any later...
CERNDocumentServer/cds-videos
cds/modules/records/serializers/__init__.py
Python
gpl-2.0
2,984
# -*- coding: utf-8 -*- # vim:set shiftwidth=4 softtabstop=4 expandtab textwidth=79: """ SUMMARY ------- Display Btrfs internal data structures :: btrfs <command> <superblock> COMMANDS -------- ``btrfs list [-m]`` -- list all btrfs file systems (-m to show metadata uuid) """ import argparse from crash.command...
jeffmahoney/crash-python
crash/commands/btrfs.py
Python
gpl-2.0
2,126
""" Test Kernel """ from shogun.Features import * from shogun.Kernel import * from shogun.Preprocessor import * from shogun.Distance import * from shogun.Classifier import PluginEstimate from shogun.Distribution import HMM, BW_NORMAL from numpy import array, ushort, ubyte, double import util ########################...
ratschlab/ASP
testsuite/python_modular/kernel.py
Python
gpl-2.0
7,199
#!/usr/bin/env python ############################################################################### # # __script_name__.py - description! # ############################################################################### # # # This program is free software: you can redistribute it and/or modify # # it under the terms ...
JoshDaly/scriptShed
template.py
Python
gpl-2.0
4,691
# -*- coding: utf-8 -*- # vim:set shiftwidth=4 softtabstop=4 expandtab textwidth=79: import addrxlat class attrdict(object): def __init__(self): self.dict = dict() def __setitem__(self, name, value): self.dict[name] = value def __getitem__(self, name): return self.dict[name] ...
jeffmahoney/crash-python
doc-source/mock/kdumpfile/__init__.py
Python
gpl-2.0
860
## import some packages useful for python development that we don't ## necessarily want imported by default import pdb import yaml
aufrank/VisualWorld
src/visualworld2/developer.py
Python
gpl-3.0
132
# search.py # --------- # Licensing Information: You are free to use or extend these projects for # educational purposes provided that (1) you do not distribute or publish # solutions, (2) you retain this notice, and (3) you provide clear # attribution to UC Berkeley, including a link to # http://inst.eecs.berkele...
kharazi/ai
search.py
Python
gpl-3.0
8,608
""" Test the API for Gyms """ from app.tests.api.system_wide.gym_collection.gym_common import \ GymAPICommonCase class TestGymCollectionHTTPVerbs(GymAPICommonCase): """ Test the API methods for the Gym """ def test_not_logged_in(self): """ Test that when user isn't authenticated that the ...
Gimpneek/exclusive-raid-gym-tracker
app/tests/api/system_wide/gym_collection/test_http_verbs.py
Python
gpl-3.0
1,590
# vim: ft=python fileencoding=utf-8 sts=4 sw=4 et: # Copyright 2015-2016 Florian Bruhin (The Compiler) <mail@qutebrowser.org> # # This file is part of qutebrowser. # # qutebrowser 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 S...
meles5/qutebrowser
tests/end2end/features/conftest.py
Python
gpl-3.0
17,501
from __future__ import unicode_literals import unittest import operator import string import decimal from django.template import ( defaulttags, Context, Node, Variable, VariableDoesNotExist, TemplateSyntaxError, ) from django.utils.timezone import now from django.utils.translation import gettext_lazy from ..fun...
AJHMvR/django-jsrender
jsrender/tests/translate.py
Python
gpl-3.0
26,753
__author__ = "David Rusk <drusk@uvic.ca>" import Queue import threading from src.daomop.gui import logger from src.validate.gui import config MAX_THREADS = config.read('APP.MAX_THREADS') class AsynchronousDownloadManager(object): """ Coordinates the downloading of images asynchronously from the rest of ...
CFIS-Octarine/octarine
validate/downloads/async.py
Python
gpl-3.0
4,800
from distutils.core import setup with open("README") as f: readme = f.read() setup( name="gizz", version="0.5", description="Command-line interface to GitHub.", long_description=readme, author="Ross Lagerwall", author_email="rosslagerwall@gmail.com", url="https://github.com/rosslagerwa...
rosslagerwall/gizz
setup.py
Python
gpl-3.0
869
# -*- coding: utf-8 -*- # Copyright (C) 2016-2018 Mathew Topper # # 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...
DTOcean/dtocean-app
dtocean_app/tools/constraints.py
Python
gpl-3.0
2,284
#!/usr/bin/python #------------------------------------------------------------------------------ # # Copyright (C) 2016 Cisco Systems, Inc. # # 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 Fou...
ios-xr/iosxr-ansible
local/library/iosxr_show_install_committed.py
Python
gpl-3.0
2,132
# _*_ coding:utf-8 _*_ import urllib import json content = raw_input('请输入需要翻译的内容:') url = 'http://fanyi.baidu.com/v2transapi' data = {} data['from'] = 'en' data['to'] = 'zh' data['query'] = content data['transtype'] = 'translang' data['simple_means_flag'] = '3' data = urllib.urlencode(data).encode('utf-8') respons...
lsp84ch83/PyText
公开课/爬虫/英译汉 - 副本.py
Python
gpl-3.0
510
from __future__ import absolute_import from icons.literals import (ARROW_RIGHT, PAGE, PAGE_ADD, PAGE_EDIT, PAGE_DELETE, BUILDING_PAGE, WAND, BUILDING, INFO_RHOMBUS, INFO_RHOMBUS_EDIT, INFO_RHOMBUS_DELETE, MONEY, MONEY_EDIT, MONEY_DELETE, MEASURE, MEASURE_EDIT, MEASURE_DELETE, THUMB_UP, THUMB_UP_EDIT, THUMB...
commonwealth-of-puerto-rico/lean
paart/apps/projects/icons.py
Python
gpl-3.0
1,685
# -*- coding: utf-8 -*- """_create_dmverity_fsimage command. @author: Tobias Hunger <tobias.hunger@gmail.com> """ from cleanroom.binarymanager import Binaries from cleanroom.command import Command from cleanroom.location import Location from cleanroom.helper.file import size_extend from cleanroom.helper.run import r...
hunger/cleanroom
cleanroom/commands/_create_dmverity_fsimage.py
Python
gpl-3.0
2,140
#!/usr/bin/env python # -*- coding: utf-8 -*- # Clipsync, clipboard synchronizer # Copyright (C) 2011-2012 Maëlick Claes (himself [at] maelick [dot] net) # 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 Fou...
maelick/Clipsync
src/shellpaste.py
Python
gpl-3.0
1,417