code
stringlengths
6
947k
repo_name
stringlengths
5
100
path
stringlengths
4
226
language
stringclasses
1 value
license
stringclasses
15 values
size
int64
6
947k
""" this file does variant calling for RNAseq """ #============= import required packages ================= import os import sys import subprocess sys.stdout = os.fdopen(sys.stdout.fileno(), 'w', 0) # disable buffer from Modules.f00_Message import Message from Modules.f01_list_trim_fq import list_files_human,Trimmoma...
shl198/Pipeline
VariantCall/Human_GATK_RNA_vari_call.py
Python
mit
7,218
# Copyright (c) 2017 Microsoft Corporation. # # Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated # documentation files (the "Software"), to deal in the Software without restriction, including without limitation the # rights to use, copy, modify, merge, publis...
domin1101/malmo-challenge
malmopy/version.py
Python
mit
1,232
'''OpenGL extension AMD.transform_feedback3_lines_triangles This module customises the behaviour of the OpenGL.raw.GL.AMD.transform_feedback3_lines_triangles to provide a more Python-friendly API Overview (from the spec) OpenGL 4.0 introduced the ability to record primitives into multiple output streams using t...
Universal-Model-Converter/UMC3.0a
data/Python/x86/Lib/site-packages/OpenGL/GL/AMD/transform_feedback3_lines_triangles.py
Python
mit
1,021
from django.core.management import color from django.db import connection, models from common import BaseEvolutionOperations TEMP_TABLE_NAME = 'TEMP_TABLE' class EvolutionOperations(BaseEvolutionOperations): def delete_column(self, model, f): qn = connection.ops.quote_name output = [] ...
broderboy/ai-stager
stager/django_evolution/db/sqlite3.py
Python
mit
8,294
__author__ = 'aniket' import freenect import cv2 import numpy as np kernel = np.ones((5,5),np.uint8) def grayscale(): maske = np.zeros((480,640,3)) a = freenect.sync_get_depth()[0] np.clip(a, 0, 2**10 - 1, a) a >>= 2 a = a.astype(np.uint8) median = cv2.medianBlur(a,5) ret,mask = cv2.thre...
amirajdhawan/eYSIP_2015_Depth_Mapping_Kinect
Resources/Examples/PycharmProjects/Python freenect examples/Codec.py
Python
cc0-1.0
826
import unittest import os from model.index import Index from model.page import Page class TestPage(unittest.TestCase): def test_str_outputStringIsAsExpected(self): test_page = Page() test_page.title = 'D01' test_page.content = 'Bla Bla Blub' expected_output = os.linesep.join([ ...
pascalweiss/SearchEngine
model/test_model.py
Python
cc0-1.0
1,742
# -*- coding: utf-8 -*- # # This file is part of Invenio. # Copyright (C) 2013, 2014, 2015 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 optio...
egabancho/invenio-communities
invenio_communities/__init__.py
Python
gpl-2.0
1,040
# # THIS IS WORK IN PROGRESS. # # The Python Imaging Library. # $Id: //modules/pil/PIL/WmfImagePlugin.py#4 $ # # WMF support for PIL # # history: # 96-12-14 fl Created # # notes: # This code currently supports placable metafiles only, and # just a few graphics operations are implemented. # # Copyr...
fxia22/ASM_xf
PythonD/lib/python2.4/site-packages/display/PIL/WmfImagePlugin.py
Python
gpl-2.0
7,556
class TNumberDataLines(object): """ Adapter used in TTableClipboard Requires: getNumberDataRows or GetNumberRows getNumberDataCols or GetNumberCols Provides: _getNumberDataRows _getNumberDataCols _getBaseDataRow _getBaseDataCol """ def _getBaseDataRow(self): if hasattr(self, 'getBaseData...
onoga/toolib
toolib/wx/grid/table/TNumberDataLines.py
Python
gpl-2.0
844
##################################################################### # -*- coding: iso-8859-1 -*- # # # # Frets on Fire X (FoFiX) # # Copyright (C) 2006 Sami Kyöstilä ...
paulhayes/fofix
src/Theme.py
Python
gpl-2.0
112,732
# ICE Revision: $Id$ """Read and create IPython-Notebooks """ import json from copy import deepcopy from time import asctime from PyFoam.Error import error,warning from PyFoam.ThirdParty.six import string_types,text_type,u class Notebook(object): """Class that represents an IPython-notebook in memory""" d...
mortbauer/openfoam-extend-Breeder-other-scripting-PyFoam
PyFoam/IPythonHelpers/Notebook.py
Python
gpl-2.0
6,200
# -*- coding: utf-8 -*- import re,urlparse,base64 from resources.lib.modules import client domains = ['miplayer.net'] def resolve(url): try: try: referer = urlparse.parse_qs(urlparse.urlparse(url).query)['referer'][0] except: referer=url id = urlpar...
azumimuo/family-xbmc-addon
plugin.video.phstreams/resources/lib/resolvers/miplayer.py
Python
gpl-2.0
902
# Opus/UrbanSim urban simulation software. # Copyright (C) 2005-2009 University of Washington # See opus_core/LICENSE import os import waterdemand basepath = waterdemand.__path__[0] path = os.path.join(basepath, "docs", "latex") cwd = os.getcwd() os.chdir(path) modules = ["userguide"] for module ...
christianurich/VIBe2UrbanSim
3rdparty/opus/src/waterdemand/docs/latex/build_docs.py
Python
gpl-2.0
1,657
__author__ = 'binary' __version__ = "1.0"
Mariam118/UYR
uyr/__init__.py
Python
gpl-2.0
42
#!/usr/bin/python # -*- coding: utf-8 -*- ##################################################################### # Frets on Fire X (FoFiX) # # Copyright (C) 2006 Sami Kyöstilä # # 2008 evilynux <evilynux@gmail.com> ...
fofix/fofix
fofix/game/Main.py
Python
gpl-2.0
5,400
# -*- coding: utf-8 -*- def on_next_stage(old_entity, new_entity, choised_attr, entities): if not old_entity.specials or 'ancestors' not in old_entity.specials: new_entity.specials['ancestors']='False' else: print ">>>>>>> passo di qui!" print old_entity.specials for special in...
Onirik79/aaritmud
data/proto_items/flora/flora_item_rename-04-piantina.py
Python
gpl-2.0
422
# This file is part of the dionaea honeypot # # SPDX-FileCopyrightText: 2009 Markus Koetter # SPDX-FileCopyrightText: 2016-2020 PhiBo (DinoTools) # # SPDX-License-Identifier: GPL-2.0-or-later import glob import logging import pkgutil import traceback from threading import Event, Thread from typing import Callable, Opt...
DinoTools/dionaea
modules/python/dionaea/__init__.py
Python
gpl-2.0
6,176
# -*- coding: utf-8 -*- # isort: skip_file from django.contrib.auth.models import User from django.db import models # This line cannot move to the below according to the isort linter. # Resolve it firstly, then apply isort again. from .base import TCMSContentTypeBaseModel # noqa from tcms.logs.views import TCMSLog ...
Nitrate/Nitrate
src/tcms/core/models/__init__.py
Python
gpl-2.0
2,359
# -*- coding: utf-8 -*- """ @author: Jeff Cavner @contact: jcavner@ku.edu @license: gpl2 @copyright: Copyright (C) 2014, University of Kansas Center for Research Lifemapper Project, lifemapper [at] ku [dot] edu, Biodiversity Institute, 1345 Jayhawk Boulevard, Lawrence, Kansas, 66045, US...
lifemapper/LmQGIS
lifemapperTools/tools/newExperiment.py
Python
gpl-2.0
17,776
# -*- coding: utf-8 -*- """ Internationalization facilities Authors: David Malcolm <dmalcolm@redhat.com> """ __author__ = """David Malcolm <dmalcolm@redhat.com>, Zack Cerza <zcerza@redhat.com>""" import config import os import re import gettext from logging import debugLogger as logger from __builtin__ import unic...
vrutkovs/dogtail
dogtail/i18n.py
Python
gpl-2.0
10,076
#!/usr/bin/env python # encoding: utf-8 import random def color_variant(brightness_offset=1): hex_color = "#%06x" % random.randint(0,0xFFFFFF) """ takes a color like #87c95f and produces a lighter or darker variant """ if len(hex_color) != 7: raise Exception("Passed %s into color_variant(), ne...
Ahed91/SPS
wsgi/util.py
Python
gpl-2.0
729
# # Gramps - a GTK+/GNOME based genealogy program # # Copyright (C) 2016 Nick Hall # # 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) a...
beernarrd/gramps
gramps/plugins/db/dbapi/test/db_test.py
Python
gpl-2.0
33,675
# Miro - an RSS based video player application # Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011 # Participatory Culture Foundation # # 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...
debugger06/MiroX
windows/plat/resources.py
Python
gpl-2.0
3,655
# -*- coding: utf-8 -*- from qgis.core import NULL from mole3.project import config from mole3.oeq_global import OeQ_get_bld_id, isnull from qgis.PyQt import QtGui, QtCore def load(self=None): self.load_wfs() return True def preflight(self=None): from mole3.project import config from qgis.PyQt.QtCor...
UdK-VPT/Open_eQuarter
mole3x/extensions/acqu_berlin/fbinter_wfs_buildings_alk.py
Python
gpl-2.0
6,104
import mmap from cpc.network.com.client_response import ClientResponse from cpc.util import ClientError, cpc import logging log=logging.getLogger(__name__) class ConnectionBase: """ Abstract class Responsible for sending a request and receiving a response """ def connect(self,host,port): r...
gromacs/copernicus
cpc/network/com/connection_base.py
Python
gpl-2.0
2,425
# This file is part of pybootchartgui. # pybootchartgui 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. # pybootchartgui is dis...
dpaleino/bootchart2
pybootchartgui/batch.py
Python
gpl-3.0
1,604
# -*- coding: utf-8 -*- ## ## ## This file is part of Indico. ## Copyright (C) 2002 - 2014 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; eith...
pferreir/indico-backup
indico/MaKaC/webinterface/rh/helpDisplay.py
Python
gpl-3.0
978
''' This class implements the AIML pattern-matching algorithm described by Dr. Richard Wallace at the following site: http://www.alicebot.org/documentation/matching.html ''' from __future__ import print_function import marshal import pprint import re import string import sys from .constants import * class PatternMg...
walterbender/speak
aiml/PatternMgr.py
Python
gpl-3.0
13,510
# This file is part of Indico. # Copyright (C) 2002 - 2015 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...
XeCycle/indico
indico/MaKaC/services/interface/rpc/offline.py
Python
gpl-3.0
3,627
# -*- coding: utf-8 -*- """ DNSLabel/DNSBuffer - DNS label handling & encoding/decoding """ from __future__ import print_function import fnmatch from mitmflib.dnslib.bit import get_bits,set_bits from mitmflib.dnslib.buffer import Buffer, BufferError class DNSLabelError(Exception): pass class DNSLabel(obje...
CiuffysHub/MITMf
mitmflib-0.18.4/mitmflib/dnslib/label.py
Python
gpl-3.0
8,406
# -*- encoding: utf-8 -*- from abjad import * def test_pitchtools_Registration___init___01(): r'''Initialize from items. ''' mapping = pitchtools.Registration([('[A0, C4)', 15), ('[C4, C8)', 27)]) assert isinstance(mapping, pitchtools.Registration) def test_pitchtools_Registration___init___02(): ...
mscuthbert/abjad
abjad/tools/pitchtools/test/test_pitchtools_Registration___init__.py
Python
gpl-3.0
1,317
# -*- coding: utf-8 -*- import re import urllib from module.plugins.internal.Hoster import Hoster class YourfilesTo(Hoster): __name__ = "YourfilesTo" __type__ = "hoster" __version__ = "0.24" __status__ = "testing" __pattern__ = r'http://(?:www\.)?yourfiles\.(to|biz)/\?d=\w+' __descr...
joberreiter/pyload
module/plugins/hoster/YourfilesTo.py
Python
gpl-3.0
2,040
# The MIT License # # Copyright (c) 2010 Daniel R. Craig # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify,...
bikash/omg-monitor
monitor/utils/pingdom.py
Python
gpl-3.0
4,612
# -*- coding: utf-8 -*- # Copyright 2017 Chris Meyers <cmeyers@ansible.com> # # This file is part of Ansible # # Ansible is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (...
tedelhourani/ansible
test/units/plugins/inventory/test_script.py
Python
gpl-3.0
4,169
#-*- coding: utf-8 -*- from django.conf.urls.defaults import patterns, url from shop_simplevariations.views import SimplevariationCartDetails urlpatterns = patterns('', url(r'^delete/$', SimplevariationCartDetails.as_view(action='delete'), name='cart_delete'), url('^item/$', Simplevari...
hzlf/openbroadcast
website/shop/shop_simplevariations/urls.py
Python
gpl-3.0
697
import sys, os import toml import pandas as pd import numpy as np from DatabaseExtractor import DatabaseExtractor def check_output_config(config): """ Check that the configuration is valid""" ok = True if config['output']['sort_column'] not in config['output']['columns']: print("Sort column not in output c...
BjerknesClimateDataCentre/QuinCe
DataPreparation/sqlite/sqlite_extractor.py
Python
gpl-3.0
2,156
#!/usr/bin/python # Copyright 2008 Jurko Gospodnetic # Distributed under the Boost Software License, Version 1.0. # (See accompanying file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) # Test that Boost Build configuration file handling. import BoostBuild import os.path import string ######...
cppisfun/GameEngine
foreign/boost/tools/build/v2/test/configuration.py
Python
gpl-3.0
4,839
from pixie.vm.reader import read, StringReader from pixie.vm.object import Object from pixie.vm.cons import Cons from pixie.vm.numbers import Integer from pixie.vm.symbol import symbol, Symbol from pixie.vm.persistent_vector import PersistentVector import pixie.vm.rt as rt import unittest data = {u"(1 2)": (1, 2,), ...
andrewchambers/pixie
pixie/vm/test/test_reader.py
Python
gpl-3.0
1,607
# vim: ft=python fileencoding=utf-8 sts=4 sw=4 et: # Copyright 2014-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...
EliteTK/qutebrowser
qutebrowser/browser/webkit/network/webkitqutescheme.py
Python
gpl-3.0
4,617
# ***** BEGIN LICENSE BLOCK ***** # Version: MPL 1.1/GPL 2.0/LGPL 2.1 # # The contents of this file are subject to the Mozilla Public License Version # 1.1 (the "License"); you may not use this file except in compliance with # the License. You may obtain a copy of the License at # http://www.mozilla.org/MPL/ # # Softwa...
samn/spectral-workbench
webserver/public/lib/bespin-0.9a2/lib/dryice/tests/test_combiner.py
Python
gpl-3.0
2,130
# encoding: latin-1 import re import json import xml.etree.ElementTree from .common import InfoExtractor from ..utils import ( compat_urllib_parse, find_xpath_attr, compat_urlparse, ExtractorError, ) class BrightcoveIE(InfoExtractor): _VALID_URL = r'https?://.*brightcove\.com/(services|viewer).*...
lebabouin/CouchPotatoServer-develop
couchpotato/core/providers/trailer/vftrailers/youtube_dl/extractor/brightcove.py
Python
gpl-3.0
5,375
#!/usr/bin/python # -*- coding: utf-8 -*- # Copyright: (c) 2018-2019, Andrew Klychkov (@Andersson007) <aaklychkov@mail.ru> # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) from __future__ import absolute_import, division, print_function __metaclass__ = type ANSIBLE_METADAT...
kustodian/ansible
lib/ansible/modules/database/postgresql/postgresql_idx.py
Python
gpl-3.0
18,616
""" GCode M668 Adjust backlash compensation for each named axis M668 Xn Yn Zn En Hn An Bn Cn Author: Anthony Clay License: CC BY-SA: http://creativecommons.org/licenses/by-sa/2.0/ """ from GCodeCommand import GCodeCommand import logging class M668(GCodeCommand): def execute(self, g): for index, axis ...
ericd/redeem
redeem/gcodes/M668.py
Python
gpl-3.0
835
# -*- coding: utf-8 -*- # # Copyright © 2012 - 2014 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...
paour/weblate
weblate/trans/migrations/0027_auto__chg_field_subproject_template.py
Python
gpl-3.0
15,556
# -*- coding: utf-8 -*- """ Created on Thu Jun 04 13:53:39 2015 This file is part of pyNLO. pyNLO 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 optio...
pyNLO/PyNLO
src/pynlo/interactions/FourWaveMixing/SSFM.py
Python
gpl-3.0
34,494
# This file is part of Indico. # Copyright (C) 2002 - 2017 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...
eliasdesousa/indico
indico/modules/networks/fields.py
Python
gpl-3.0
2,522
""" .. _xarray.Dataset: http://xarray.pydata.org/en/stable/data-structures.html#dataset .. _xarray.DataArray: http://xarray.pydata.org/en/stable/data-structures.html#dataarray .. _Numpy: http://www.numpy.org/ The following functions provide the high-level API of the ESDC Python DAT. It provides additional analytical u...
CAB-LAB/cablab-core
esdl/dat.py
Python
gpl-3.0
3,600
# Copyright 2009 Noam Yorav-Raphael # # This file is part of DreamPie. # # DreamPie 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. # ...
uri-mog/dreampie
dreampielib/gui/subprocess_handler.py
Python
gpl-3.0
10,125
# This file is part of Headphones. # # Headphones 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. # # Headphones is distributed i...
gylian/headphones
headphones/lastfm.py
Python
gpl-3.0
5,263
#!/usr/bin/python # write an experiment that raises an exception import sys import os BOREALISPATH = os.environ['BOREALISPATH'] sys.path.append(BOREALISPATH) import experiments.superdarn_common_fields as scf from experiment_prototype.experiment_prototype import ExperimentPrototype from utils.experiment_options.expe...
SuperDARNCanada/borealis
experiments/testing_archive/test_rxfreq_not_num.py
Python
gpl-3.0
1,611
# vim: ft=python fileencoding=utf-8 sts=4 sw=4 et: # Copyright 2014-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...
shaggytwodope/qutebrowser
qutebrowser/completion/models/sortfilter.py
Python
gpl-3.0
6,490
# # Copyright 2014-2019 Universidad Complutense de Madrid # # This file is part of Megara DRP # # SPDX-License-Identifier: GPL-3.0+ # License-Filename: LICENSE.txt # from numina.core import Result, Parameter from numina.array import combine from megaradrp.processing.combine import basic_processing_with_combination fr...
sergiopasra/megaradrp
megaradrp/recipes/calibration/bias.py
Python
gpl-3.0
2,560
""" stubo ~~~~~ Stub-O-Matic - Enable automated testing by mastering system dependencies. Use when reality is simply not good enough. :copyright: (c) 2015 by OpenCredo. :license: GPLv3, see LICENSE for more details. """ import os import sys version = "0.8.3" version_info = tuple(ver...
rusenask/mirage
stubo/__init__.py
Python
gpl-3.0
585
""" Numerical python functions written for compatability with MATLAB commands with the same names. MATLAB compatible functions ------------------------------- :func:`cohere` Coherence (normalized cross spectral density) :func:`csd` Cross spectral density uing Welch's average periodogram :func:`detrend` Remov...
SpaceKatt/CSPLN
apps/scaffolding/mac/web2py/web2py.app/Contents/Resources/lib/python2.7/matplotlib/mlab.py
Python
gpl-3.0
100,604
import psycopg2 import os import sys import csv from datetime import datetime, date, timedelta from utils import S3CompressedWriter from summarize import summarize # How many days "back" do we look for activity? latency_interval = 10 default_bucket = 'telemetry-public-analysis-2' current_cutoff = date.today() - time...
whd/data-pipeline
reports/stability-summary/rollup.py
Python
mpl-2.0
11,194
import pytest from udata import uris from udata.settings import Defaults PUBLIC_HOSTS = [ 'http://foo.com/blah_blah', 'http://foo.com/blah_blah/', 'http://foo.com/blah_blah_(wikipedia)', 'http://foo.com/blah_blah_(wikipedia)_(again)', 'http://www.example.com/wpstyle/?p=364', 'https://www.exam...
opendatateam/udata
udata/tests/test_uris.py
Python
agpl-3.0
8,266
from django.test import TestCase from codewiki.models import Scraper from django.contrib.auth.models import User class Test__unicode__(TestCase): def test_scraper_name(self): self.assertEqual( 'test_scraper', unicode(Scraper(title='Test Scraper', short_name='test_scraper')) ...
lkundrak/scraperwiki
web/codewiki/tests/models.py
Python
agpl-3.0
322
""" Tests for the plugin API """ from __future__ import absolute_import from django.test import TestCase from openedx.core.lib.plugins import PluginError from openedx.core.lib.course_tabs import CourseTabPluginManager class TestCourseTabApi(TestCase): """ Unit tests for the course tab plugin API """ ...
ESOedX/edx-platform
openedx/core/lib/tests/test_course_tab_api.py
Python
agpl-3.0
653
from kombu.tests.utils import unittest from kombu.transport import pyamqplib from kombu.connection import BrokerConnection class MockConnection(dict): def __setattr__(self, key, value): self[key] = value class test_amqplib(unittest.TestCase): def test_default_port(self): class Transport(...
mzdaniel/oh-mainline
vendor/packages/kombu/kombu/tests/test_transport_pyamqplib.py
Python
agpl-3.0
806
############################################################################## # # Copyright (C) 2021 Compassion CH (http://www.compassion.ch) # Releasing children from poverty in Jesus' name # @author: Emanuel Cino <ecino@compassion.ch> # # The licence is in the file __manifest__.py # #####################...
eicher31/compassion-switzerland
partner_communication_switzerland/models/partner_communication_config.py
Python
agpl-3.0
4,913
# -*- encoding: utf-8 -*- ############################################################################### # # # Copyright (C) 2009-2013 Renato Lima - Akretion # # ...
rodrigoasmacedo/l10n-brazil
__unported__/l10n_br_account/__openerp__.py
Python
agpl-3.0
2,625
#!/usr/bin/env python # Copyright (C) 2009-2015: # Coavoux Sebastien <s.coavoux@free.fr> # # This file is part of Shinken. # # Shinken 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...
naparuba/shinken
test/test_end_parsing_types.py
Python
agpl-3.0
6,105
# Copyright (C) 2011, CloudCaptive # # 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 i...
nlake44/UserInfuser
serverside/testing/test.py
Python
agpl-3.0
22,168
# -*- coding: utf-8 -*- """ """ from __future__ import unicode_literals import logging import os import hashlib logger = logging.getLogger(__name__) _log = "pelican_comment_system: avatars: " try: from . identicon import identicon _identiconImported = True except ImportError as e: logger.warning(_log + "identi...
znegva/pelican-plugins
pelican_comment_system/avatars.py
Python
agpl-3.0
2,305
# -*- coding: utf-8 -*- import collections import cStringIO import datetime import hashlib import json import itertools import logging import math import os import re import sys import textwrap import uuid from subprocess import Popen, PIPE from urlparse import urlparse import babel import babel.dates import werkzeug ...
flh/odoo
openerp/addons/base/ir/ir_qweb.py
Python
agpl-3.0
59,920
# 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. # # This program is distributed in the hope that it will be usefu...
scylladb/scylla-cluster-tests
sdcm/sct_provision/aws/layout.py
Python
agpl-3.0
2,241
# -*- coding: utf-8 -*- # Generated by Django 1.11.2 on 2017-08-01 12:06 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('boites', '0007_auto_20170801_0645'), ] operations = [ migrations.AlterField( model_name='tile', ...
bgaultier/laboitepro
boites/migrations/0008_auto_20170801_1406.py
Python
agpl-3.0
568
BLACKLIST_SIGNUP_DOMAINS = ['gmail.com', 'yahoo.com', 'hotmail.com'] ACCOUNT_RESERVED_KEYWORDS = [ 'company', 'admin', 'api', 'signout', 'reset', '404', '500', 'docs', 'signup', 'signin', 'invitation', 'chat', 'report', 'community', 'user', 'notification', 'notifications', 'feedback', 'media', 'static', ...
jessamynsmith/boards-backend
blimp_boards/accounts/constants.py
Python
agpl-3.0
667
# This file is part of Shuup. # # Copyright (c) 2012-2021, Shuup Commerce Inc. All rights reserved. # # This source code is licensed under the OSL-3.0 license found in the # LICENSE file in the root directory of this source tree. import datetime import pytest from shuup.simple_cms.models import Page from shuup.simple_...
shoopio/shoop
shuup_tests/simple_cms/test_custom_templates.py
Python
agpl-3.0
1,062
""" Models for User Information (students, staff, etc) Migration Notes If you make changes to this model, be sure to create an appropriate migration file and check it in at the same time as your model changes. To do that, 1. Go to the edx-platform dir 2. ./manage.py lms schemamigration student --auto description_of_...
shubhdev/openedx
common/djangoapps/student/models.py
Python
agpl-3.0
67,408
# -*- coding: utf-8 -*- # vim: tabstop=4 shiftwidth=4 softtabstop=4 # # LICENSE # # Copyright (c) 2015 GEM Foundation # # The Catalogue Toolkit 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 ...
g-weatherill/catalogue_toolkit
eqcat/catalogue_query_tools.py
Python
agpl-3.0
60,867
#!/usr/bin/env python # -*- coding: utf-8; tab-width: 4; indent-tabs-mode: t -*- # # NetProfile: PDF-related tables, utility functions etc. # © Copyright 2015 Alex 'Unik' Unigovsky # # This file is part of NetProfile. # NetProfile is free software: you can redistribute it and/or # modify it under the terms of the GNU A...
nikitos/npui
netprofile/netprofile/pdf/__init__.py
Python
agpl-3.0
10,229
# worksheet search on analysis basis. from openerp import models, fields, api from openerp.tools.translate import _ class SerachWroksheet(models.TransientModel): _name = "olims.search_wroksheet" _rec_name = "selection_type" @api.multi def _selection_services(self): list_of_name = [] items_types_o...
yasir1brahim/OLiMS
models/search_ar.py
Python
agpl-3.0
7,325
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import models, migrations def add_categories(apps, schema_editor): Category = apps.get_model('niqati', 'Category') # We are going to add categories only if none already exists. if not Category.objects.exists(): Category...
enjaz/enjaz
niqati/migrations/0002_add_categories.py
Python
agpl-3.0
1,163
from __future__ import unicode_literals import locale import sys #=================================================================================================== # _StreamWrapper #=================================================================================================== class _StreamWrapper(object): ...
Kaniabi/ben10
source/python/ben10/foundation/print_detailed_traceback.py
Python
lgpl-2.1
6,374
import sys, mapper def h(sig, id, f, timetag): try: print sig.name, f except: print 'exception' print sig, f def setup(d): sig = d.add_input("/freq", 1, 'i', "Hz", None, None, h) print 'inputs',d.num_inputs print 'minimum',sig.minimum sig.minimum = 34.0 print 'mini...
davidhernon/libmapper
swig/test.py
Python
lgpl-2.1
3,790
# cerbero - a multi-platform build system for Open Source software # Copyright (C) 2012 Andoni Morales Alastruey <ylatuya@gmail.com> # # This library is free software; you can redistribute it and/or # modify it under the terms of the GNU Library General Public # License as published by the Free Software Foundation; eit...
nirbheek/cerbero
cerbero/packages/wix_packager.py
Python
lgpl-2.1
13,420
import os import shutil import pytest from ..pyautoupdate.launcher import Launcher @pytest.fixture(scope='function') def fixture_update_dir(request): """Fixture that creates and tears down version.txt and log files""" def create_update_dir(version="0.0.1"): def teardown(): if os.path.isfil...
rlee287/pyautoupdate
test/pytest_makevers.py
Python
lgpl-2.1
1,008
#!/usr/bin/env python2 from eagle import * def callback(app, entry, value): print app, entry, value App(title="Slider test", left=Slider(id="hslider", label="Slider:", value_pos=Slider.POS_NONE, horizontal=True, min=0, max=10, ca...
ramalho/eagle-py
tests/slider.py
Python
lgpl-2.1
611
""" Test the case where the vCard get made prior to a vCard set fails. """ from servicetest import call_async, EventPattern from gabbletest import ( acknowledge_iq, elem, exec_test, make_result_iq, sync_stream) import constants as cs import ns def test(q, bus, conn, stream): event = q.expect('stream-iq', to=...
jku/telepathy-gabble
tests/twisted/vcard/update-get-failed.py
Python
lgpl-2.1
1,108
#!/usr/bin/env python2 from eagle import * def changed(app, entry, value): print "app %s, entry %s, value %r" % (app.id, entry.id, value) App(title="Entries Test", center=(Entry(id="single"), Entry(id="multi", multiline=True), Entry(id="non-editable", label="non-edi...
ramalho/eagle-py
tests/entries.py
Python
lgpl-2.1
572
import sys from services.spawn import MobileTemplate from services.spawn import WeaponTemplate from resources.datatables import WeaponType from resources.datatables import Difficulty from resources.datatables import Options from java.util import Vector def addTemplate(core): mobileTemplate = MobileTemplate...
agry/NGECore2
scripts/mobiles/yavin4/hooded_crystal_snake.py
Python
lgpl-3.0
1,650
files = ["multiplier_u16x16_DSP.ngc", "multiplier_u16x16_DSP.vhd", "multiplier_16x10_DSP.ngc", "multiplier_16x10_DSP.vhd"]
lerwys/GitTest
hdl/platform/virtex6/Manifest.py
Python
lgpl-3.0
126
# -*- coding: utf-8 -*- # Copyright(C) 2016 Edouard Lambert # # This file is part of a weboob module. # # This weboob module 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...
laurentb/weboob
modules/spirica/test.py
Python
lgpl-3.0
947
DEFAULT_STEMMER = 'snowball' DEFAULT_TOKENIZER = 'word' DEFAULT_TAGGER = 'pos' TRAINERS = ['news', 'editorial', 'reviews', 'religion', 'learned', 'science_fiction', 'romance', 'humor'] DEFAULT_TRAIN = 'news'
viktorRock/myFirstPythonAPI
pythapp/nltk/nltk_constants.py
Python
unlicense
222
# coding: utf-8 from __future__ import unicode_literals import re import hashlib from .common import InfoExtractor from ..compat import compat_str from ..utils import ( ExtractorError, int_or_none, float_or_none, sanitized_Request, urlencode_postdata, ) class YandexMusicBaseIE(InfoExtractor): ...
nandhp/youtube-dl
youtube_dl/extractor/yandexmusic.py
Python
unlicense
8,328
#!/usr/bin/env python import json inv = { '_meta': { 'hostvars': {} }, 'hosts': [] } for num in range(0, 3): host = u"host-%0.2d" % num inv['hosts'].append(host) inv['_meta']['hostvars'][host] = dict(ansible_ssh_host='127.0.0.1', ansible_connection='local') print(json.dumps(inv, inde...
ansible/tower-cli
docs/source/cli_ref/examples/inventory_script_example.py
Python
apache-2.0
327
# vim: tabstop=4 shiftwidth=4 softtabstop=4 # # Copyright 2012, Cisco Systems, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE...
xchenum/quantum
quantum/plugins/linuxbridge/tests/unit/test_database.py
Python
apache-2.0
11,211
import pytest from addons.osfstorage.models import OsfStorageFile from api.base.settings.defaults import API_BASE from api_tests import utils as test_utils from api_tests.preprints.filters.test_filters import PreprintsListFilteringMixin from api_tests.preprints.views.test_preprint_list_mixin import PreprintIsPublished...
TomBaxter/osf.io
api_tests/nodes/views/test_node_preprints.py
Python
apache-2.0
6,285
# -*- coding: utf-8 -*- # Copyright (c) 2015-2022, Exa Analytics Development Team # Distributed under the terms of the Apache License 2.0 #''' #PW Module Input File Editor #==================================== # #''' #import numpy as np #from exatomic.exa import DataFrame #from exatomic import Length, Frame, Atom #from...
exa-analytics/exatomic
exatomic/qe/pw/input.py
Python
apache-2.0
1,703
# vim: tabstop=4 shiftwidth=4 softtabstop=4 # Copyright 2012 OpenStack Foundation # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apach...
adkerr/tempest
tempest/api/compute/v3/servers/test_servers_negative.py
Python
apache-2.0
17,583
# 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 # # http://www.apache.org/licenses/LICENSE-2.0 # # ...
mahak/neutron
neutron/tests/unit/db/test_migration.py
Python
apache-2.0
30,671
import mxnet as mx from mxnet import gluon from mxnet.gluon import nn, rnn class RNNModel(gluon.Block): """A model with an encoder, recurrent layer, and a decoder.""" def __init__(self, mode, vocab_size, num_embed, num_hidden, num_layers, dropout=0.5, tie_weights=False, **kwargs): sup...
hotpxl/mxnet
example/gluon/word_language_model/model.py
Python
apache-2.0
2,085
# -*- coding: utf-8 -*- ''' :codeauthor: :email:`Jayesh Kariya <jayeshk@saltstack.com>` ''' # Import Python Libs from __future__ import absolute_import # Import Salt Testing Libs from salttesting import TestCase, skipIf from salttesting.mock import ( MagicMock, patch, NO_MOCK, NO_MOCK_REASON ) fro...
stephane-martin/salt-debian-packaging
salt-2016.3.3/tests/unit/modules/moosefs_test.py
Python
apache-2.0
2,122
import uuid from paho.mqtt import publish from paho.mqtt.client import MQTTv31 from conf.mqttconf import * def send(msg, user_list, qos=2, retain=False): """ 发布mqtt消息 :param msg:消息内容,可以是字符串、int、bytearray :param user_list: 用户列表数组(不带前缀的),例如:["zhangsan","lilei"] :param qos: 消息质量(0:至多一次,1:至少一次,2:只有一...
cherrishes/weilai
xingxing/common/mqtt_helper.py
Python
apache-2.0
1,402
# # 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 "License"); you may not us...
holdenk/spark
python/pyspark/ml/classification.py
Python
apache-2.0
127,312
#!/usr/bin/env python # Copyright (c) 2011 OpenStack Foundation # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICE...
openstack/cinder
cinder/cmd/volume_usage_audit.py
Python
apache-2.0
10,093
#- # Copyright (c) 2011 Robert N. M. Watson # All rights reserved. # # This software was developed by SRI International and the University of # Cambridge Computer Laboratory under DARPA/AFRL contract FA8750-10-C-0237 # ("CTSRD"), as part of the DARPA CRASH research programme. # # @BERI_LICENSE_HEADER_START@ # # License...
8l/beri
cheritest/trunk/tests/framework/test_raw_nop.py
Python
apache-2.0
1,415
# 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 # "License"); you may not u...
Huyuwei/tvm
tests/webgl/test_static_webgl_library.py
Python
apache-2.0
2,490
#!/usr/bin/python from pyzabbix import ZabbixAPI import sys username="wentian" password="65107318" zapi = ZabbixAPI("http://zabbix.ustack.com") zapi.login(username, password) print "Connected To Zabbix API Version %s" % zapi.api_version() hostgroup_id = sys.argv[1] status = int(sys.argv[2]) def get_hostgroup_id(h...
zhaozhilong1993/demon
scripts/online_action/reset_zabbix_hosts.py
Python
apache-2.0
942