repo_name
stringlengths
6
100
path
stringlengths
4
294
copies
stringlengths
1
5
size
stringlengths
4
6
content
stringlengths
606
896k
license
stringclasses
15 values
libscie/liberator
liberator/lib/python3.6/site-packages/chardet/codingstatemachine.py
289
3590
######################## BEGIN LICENSE BLOCK ######################## # The Original Code is mozilla.org code. # # The Initial Developer of the Original Code is # Netscape Communications Corporation. # Portions created by the Initial Developer are Copyright (C) 1998 # the Initial Developer. All Rights Reserved. # # Con...
cc0-1.0
n-west/gnuradio
gnuradio-runtime/examples/volk_benchmark/volk_types.py
58
5995
#!/usr/bin/env python from gnuradio import gr from gnuradio import blocks import argparse from volk_test_funcs import * ###################################################################### def float_to_char(N): op = blocks.float_to_char() tb = helper(N, op, gr.sizeof_float, gr.sizeof_char, 1, 1) return...
gpl-3.0
imply/chuu
build/android/gyp/util/build_device.py
52
2894
# Copyright 2013 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """ A simple device interface for build steps. """ import logging import os import re import sys import build_utils BUILD_ANDROID_DIR = os.path.join(os.p...
bsd-3-clause
Jumpscale/jumpscale6_core
lib/JumpScale/baselib/remote/fabric/FabricTool.py
1
1222
from JumpScale import j j.system.platform.ubuntu.check() import fabric import fabric.api # from fabric.api import run as frun # from fabric.api import execute as fexecute # from fabric.api import env as fenv # from fabric.api import open_shell as fopen_shell # from fabric.api import path as fpath # from fabric.api i...
bsd-2-clause
rembo10/headphones
lib/unidecode/x08d.py
252
4636
data = ( 'Wei ', # 0x00 'Bai ', # 0x01 'Chen ', # 0x02 'Zhuan ', # 0x03 'Zhi ', # 0x04 'Zhui ', # 0x05 'Biao ', # 0x06 'Yun ', # 0x07 'Zeng ', # 0x08 'Tan ', # 0x09 'Zan ', # 0x0a 'Yan ', # 0x0b '[?] ', # 0x0c 'Shan ', # 0x0d 'Wan ', # 0x0e 'Ying ', # 0x0f 'Jin ', # 0x...
gpl-3.0
shsingh/ansible
lib/ansible/modules/network/dellos6/dellos6_facts.py
50
15435
#!/usr/bin/python # # (c) 2015 Peter Sprygada, <psprygada@ansible.com> # Copyright (c) 2016 Dell Inc. # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) from __future__ import absolute_import, division, print_function __metaclass__ = type ANSIBLE_METADATA = {'metadata_versio...
gpl-3.0
andnovar/networkx
networkx/algorithms/shortest_paths/tests/test_generic.py
1
7273
from __future__ import division from nose.tools import assert_almost_equal from nose.tools import assert_equal from nose.tools import assert_false from nose.tools import assert_true from nose.tools import assert_raises from nose.tools import ok_ from nose.tools import raises import networkx as nx def validate_grid_...
bsd-3-clause
blueboxgroup/neutron
neutron/db/migration/alembic_migrations/versions/1fcfc149aca4_agents_unique_by_type_and_host.py
17
1377
# Copyright 2013 OpenStack Foundation # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law ...
apache-2.0
18padx08/PPTex
PPTexEnv_x86_64/lib/python2.7/site-packages/numpy/distutils/__config__.py
2
1869
# This file is generated by /home/patrick/Documents/PPText/PPTexEnv_x86_64/build/numpy/-c # It contains system_info results at the time of building this package. __all__ = ["get_info","show"] atlas_3_10_blas_info={} atlas_3_10_blas_threads_info={} atlas_threads_info={} blas_opt_info={'libraries': ['f77blas', 'cblas', ...
mit
0x90sled/catapult
third_party/gsutil/third_party/boto/tests/integration/gs/test_generation_conditionals.py
135
14307
# -*- coding: utf-8 -*- # Copyright (c) 2013, Google, Inc. # All rights reserved. # # Permission is hereby granted, free of charge, to any person obtaining a # copy of this software and associated documentation files (the # "Software"), to deal in the Software without restriction, including # without limitation the rig...
bsd-3-clause
ronkitay/Rons-Tutorials
Python/APIs/tor_json_processing.py
1
3684
#!/usr/bin/python # -*- coding: utf-8 -*- """ Python considers any map or collection as JSON elements. 'Serializing/DeSerializing' them is VERY easy Read: - json.load(data_file) --> Loads an object from a File - json.loads(json_as_string) --> Loads an object from a string representing a JSON object Write: - json.d...
mit
schwartzmx/ansible-modules-extras
database/misc/redis.py
41
10582
#!/usr/bin/python # -*- coding: utf-8 -*- # This file is part of Ansible # # Ansible is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. #...
gpl-3.0
finalion/WordQuery
src/prepare.py
1
4014
#-*- coding:utf-8 -*- # # Copyright © 2016–2017 Liang Feng <finalion@gmail.com> # # Support: Report an issue at https://github.com/finalion/WordQuery/issues # # 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...
gpl-3.0
openiitbombayx/edx-platform
lms/djangoapps/foldit/tests.py
104
14019
"""Tests for the FoldIt module""" import json import logging from functools import partial from django.test import TestCase from django.test.client import RequestFactory from django.core.urlresolvers import reverse from foldit.views import foldit_ops, verify_code from foldit.models import PuzzleComplete, Score from s...
agpl-3.0
ossdemura/django-miniblog
Lib/site-packages/django/contrib/admindocs/urls.py
97
1192
from django.conf.urls import url from django.contrib.admindocs import views urlpatterns = [ url(r'^$', views.BaseAdminDocsView.as_view(template_name='admin_doc/index.html'), name='django-admindocs-docroot'), url(r'^bookmarklets/$', views.BookmarkletsView.as_view(), name='django-...
mit
Alwnikrotikz/pyglet
contrib/scene2d/examples/invaders.py
29
3055
import os import math import pyglet.window from resource import * from pyglet.window import key from pyglet import clock from scene2d import * class PlayerSprite(Sprite): bullets = [] def update(self, dt): self.x += (keyboard[key.RIGHT] - keyboard[key.LEFT]) * 200 * dt if self.left < 0: self.l...
bsd-3-clause
kfox1111/horizon
openstack_dashboard/dashboards/project/instances/tests.py
8
195767
# Copyright 2012 United States Government as represented by the # Administrator of the National Aeronautics and Space Administration. # All Rights Reserved. # # Copyright 2012 Nebula, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the...
apache-2.0
TheTypoMaster/chromium-crosswalk
build/android/pylib/gtest/test_package_exe.py
4
6058
# Copyright (c) 2012 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """Defines TestPackageExecutable to help run stand-alone executables.""" import logging import os import posixpath import sys import tempfile from pyli...
bsd-3-clause
alperyeg/elephant
elephant/test/test_spade.py
2
32565
""" Unit tests for the spade module. :copyright: Copyright 2014-2016 by the Elephant team, see `doc/authors.rst`. :license: Modified BSD, see LICENSE.txt for details. """ from __future__ import division import sys import unittest import random import neo import numpy as np import quantities as pq from numpy.testing....
bsd-3-clause
telefonicaid/selenium
wire.py
22
83032
# Copyright 2008-2010 WebDriver committers # Copyright 2008-2010 Google Inc. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENS...
apache-2.0
manics/ansible-modules-core
cloud/openstack/os_floating_ip.py
22
8639
#!/usr/bin/python # Copyright (c) 2015 Hewlett-Packard Development Company, L.P. # Author: Davide Guerri <davide.guerri@hp.com> # # This module 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 ...
gpl-3.0
goodwinos/linux-dm
tools/perf/scripts/python/event_analyzing_sample.py
4719
7393
# event_analyzing_sample.py: general event handler in python # # Current perf report is already very powerful with the annotation integrated, # and this script is not trying to be as powerful as perf report, but # providing end user/developer a flexible way to analyze the events other # than trace points. # # The 2 dat...
gpl-2.0
dalgibbard/fishfeedtime
fishfeedtime.py
1
4825
#!/usr/bin/python # # Fishfeedtime powers down Powerheads/Filters/Pumps of your choice (which are connected to 433.92MHz power socket controllers) # for a set duration. # ## GPIO Pin Definitions # Pin with button circuit GPIO Pullup BUTTON = 25 # LED Pin if present... LED = True LEDPIN = 11 # Pin connect to 434MHz tra...
bsd-3-clause
laborautonomo/django-extensions
django_extensions/management/utils.py
8
2237
from django.conf import settings import os import sys import logging try: from importlib import import_module except ImportError: try: from django.utils.importlib import import_module except ImportError: def import_module(module): return __import__(module, {}, {}, ['']) def ge...
mit
skyostil/albumart
lib/albumart/yahoo/search/webservices.py
1
48639
"""Yahoo Search Web Services This module implements a set of classes and functions to work with the Yahoo Search Web Services. All results from these services are properly formatted XML, and this package facilitates for proper parsing of these result sets. Some of the features include: * Extendandable API, with r...
gpl-2.0
viciantomas/TTSFB
lib/sleekxmpp/xmlstream/matcher/stanzapath.py
14
1566
# -*- coding: utf-8 -*- """ sleekxmpp.xmlstream.matcher.stanzapath ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Part of SleekXMPP: The Sleek XMPP Library :copyright: (c) 2011 Nathanael C. Fritz :license: MIT, see LICENSE for more details """ from sleekxmpp.xmlstream.matcher.base import MatcherBase from...
apache-2.0
fishstamp82/loprop
test/test_h2o_rot.py
2
13738
import os import numpy as np from ..loprop import MolFrag, penalty_function, xtang, pairs from ..daltools.util import full import re thisdir = os.path.dirname(__file__) case = "h2o_rot" tmpdir=os.path.join(thisdir, case, 'tmp') exec('import %s_data as ref'%case) def assert_(this, ref, atol=1e-5, text=None): if...
gpl-3.0
javiplx/cobbler-debian
cobbler/modules/authz_allowall.py
6
1400
""" Authorization module that allows everything, which is the default for new cobbler installs. Copyright 2007-2008, Red Hat, Inc Michael DeHaan <mdehaan@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 Softw...
gpl-2.0
raqqun/tweetcommander
packages/requests/packages/charade/gb2312freq.py
3132
36011
######################## BEGIN LICENSE BLOCK ######################## # The Original Code is Mozilla Communicator client code. # # The Initial Developer of the Original Code is # Netscape Communications Corporation. # Portions created by the Initial Developer are Copyright (C) 1998 # the Initial Developer. All Rights R...
gpl-3.0
8l/beri
cheritest/trunk/tests/mem/test_ll_unalign.py
2
2396
#- # 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...
apache-2.0
rjschwei/azure-sdk-for-python
azure-mgmt-redis/setup.py
1
2428
#!/usr/bin/env python #------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for # license information. #----------------------------------------------------------------...
mit
alekz112/statsmodels
statsmodels/regression/tests/lme_r_results.py
33
14824
import numpy as np coef_ml_drf_0 = np.array([-0.9887517]) vcov_ml_drf_0 = np.array([0.001317148]).reshape(1,1, order='F') cov_re_ml_drf_0 = np.array([0.2522485]).reshape(1,1, order='F') scale_ml_drf_0 = np.array([0.2718486]) loglike_ml_drf_0 = np.array([-240.1254]) ranef_mean_ml_drf_0 = np.array([0.04977167]) ra...
bsd-3-clause
orbitfp7/horizon
openstack_dashboard/dashboards/project/data_processing/data_image_registry/forms.py
10
4212
# Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the...
apache-2.0
abzaloid/maps
django-project/lib/python2.7/site-packages/pip/_vendor/requests/packages/chardet/euckrfreq.py
3121
45978
######################## BEGIN LICENSE BLOCK ######################## # The Original Code is Mozilla Communicator client code. # # The Initial Developer of the Original Code is # Netscape Communications Corporation. # Portions created by the Initial Developer are Copyright (C) 1998 # the Initial Developer. All Rights R...
mit
cherylyli/stress-aid
env/lib/python3.5/site-packages/werkzeug/urls.py
216
36710
# -*- coding: utf-8 -*- """ werkzeug.urls ~~~~~~~~~~~~~ ``werkzeug.urls`` used to provide several wrapper functions for Python 2 urlparse, whose main purpose were to work around the behavior of the Py2 stdlib and its lack of unicode support. While this was already a somewhat inconvenient situat...
mit
kevin-teddy/gajim
src/htmltextview.py
2
36141
# -*- coding:utf-8 -*- ## src/htmltextview.py ## ## Copyright (C) 2005 Gustavo J. A. M. Carneiro ## Copyright (C) 2006 Santiago Gala ## Copyright (C) 2006-2007 Jean-Marie Traissard <jim AT lapin.org> ## Copyright (C) 2006-2008 Yann Leboulanger <asterix AT lagaule.org> ## Copyright (C) 2007 Nikos Kouremenos <kourem AT g...
gpl-3.0
ravenac95/virtstrap
virtstrap-core/tests/test_hooks.py
1
1073
""" Test Plugins ------------ """ from nose.tools import raises from virtstrap.hooks import Hook, create def test_initialize_Hook(): hook = Hook() @raises(NotImplementedError) def test_run_hook(): hook = Hook() options = None hook.run('fake_event', options) def test_fake_hook(): class FakeHook(H...
mit
GheRivero/ansible
test/units/modules/system/test_pamd.py
19
17492
from __future__ import (absolute_import, division, print_function) from ansible.compat.tests import unittest from ansible.modules.system.pamd import PamdRule from ansible.modules.system.pamd import PamdLine from ansible.modules.system.pamd import PamdComment from ansible.modules.system.pamd import PamdInclude from ans...
gpl-3.0
vicky2135/lucious
oscar/lib/python2.7/site-packages/django/templatetags/i18n.py
115
19351
from __future__ import unicode_literals import sys from django.conf import settings from django.template import Library, Node, TemplateSyntaxError, Variable from django.template.base import TOKEN_TEXT, TOKEN_VAR, render_value_in_context from django.template.defaulttags import token_kwargs from django.utils import six...
bsd-3-clause
tiagocoutinho/qarbon
qarbon/qt/gui/style/nebula.py
2
5273
# ---------------------------------------------------------------------------- # This file is part of qarbon (http://qarbon.rtfd.org/) # # Copyright (c) 2013 European Synchrotron Radiation Facility, Grenoble, France # # Distributed under the terms of the GNU Lesser General Public License, # either version 3 of the Lice...
lgpl-3.0
pyqt/maya2012-qt4
PyQt4/uic/Compiler/qobjectcreator.py
1
5626
############################################################################# ## ## Copyright (C) 2011 Riverbank Computing Limited. ## Copyright (C) 2006 Thorsten Marek. ## All right reserved. ## ## This file is part of PyQt. ## ## You may use this file under the terms of the GPL v2 or the revised BSD ## license as fol...
gpl-3.0
sergecodd/FireFox-OS
B2G/gecko/testing/mozbase/mozrunner/mozrunner/runner.py
6
14272
#!/usr/bin/env python # 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/. __all__ = ['Runner', 'ThunderbirdRunner', 'FirefoxRunner', 'runners', 'CLI', 'cli', 'package_meta...
apache-2.0
wimnat/ansible-modules-extras
cloud/azure/azure_rm_deployment.py
9
27418
#!/usr/bin/python # # This file is part of Ansible # # Ansible is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # Ansible is distribut...
gpl-3.0
mrcslws/nupic.research
nupic/research/frameworks/dynamic_sparse/networks/hebbian.py
3
9819
# ---------------------------------------------------------------------- # Numenta Platform for Intelligent Computing (NuPIC) # Copyright (C) 2019, Numenta, Inc. Unless you have an agreement # with Numenta, Inc., for a separate license for this software code, the # following terms and conditions apply: # # This progra...
agpl-3.0
markYoungH/chromium.src
tools/telemetry/telemetry/unittest_util/run_tests_unittest.py
21
3310
# Copyright 2014 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. import unittest from telemetry.core import util from telemetry.unittest_util import run_tests class MockArgs(object): def __init__(self): self.posit...
bsd-3-clause
Honry/crosswalk-test-suite
cordova/cordova-lite-android-tests/lite/webapp_run.py
14
2269
#!/usr/bin/env python # # Copyright (c) 2016 Intel Corporation. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: # # * Redistributions of works must retain the original copyright notice, this # list of conditions and t...
bsd-3-clause
FrankBie/django-openid-auth
django_openid_auth/admin.py
2
3685
# django-openid-auth - OpenID integration for django.contrib.auth # # Copyright (C) 2008-2010 Canonical Ltd. # Copyright (C) 2010 Dave Walker # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # # * Redistributions of s...
bsd-2-clause
slowfranklin/samba
python/samba/netcmd/dns.py
25
48747
# DNS management tool # # Copyright (C) Amitay Isaacs 2011-2012 # # 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. # # Th...
gpl-3.0
openhealthcare/gloss
sites/uch/mock_api.py
1
4898
import random from gloss import models from gloss.translators.hl7 import coded_values from datetime import datetime, date, timedelta from gloss.external_api import save_message first_names = [ "Jane", "James", "Chandeep", "Samantha", "Oliver", "Charlie", "Sophie", "Emily", "Lily", "Olivia", "Amelia", "Isabell...
gpl-3.0
martydill/url_shortener
code/venv/lib/python2.7/site-packages/IPython/terminal/embed.py
4
10491
# encoding: utf-8 """ An embedded IPython shell. """ # Copyright (c) IPython Development Team. # Distributed under the terms of the Modified BSD License. from __future__ import with_statement from __future__ import print_function import sys import warnings from IPython.core import ultratb, compilerop from IPython.co...
mit
xyzoer/pyspider
pyspider/webui/result.py
32
1787
#!/usr/bin/env python # -*- encoding: utf-8 -*- # vim: set et sw=4 ts=4 sts=4 ff=unix fenc=utf8: # Author: Binux<i@binux.me> # http://binux.me # Created on 2014-10-19 16:23:55 from __future__ import unicode_literals from flask import render_template, request, json from flask import Response from .app import a...
apache-2.0
pillip8282/TizenRT
external/protobuf/conformance/update_failure_list.py
41
2898
#!/usr/bin/env python # Protocol Buffers - Google's data interchange format # Copyright 2008 Google Inc. All rights reserved. # https://developers.google.com/protocol-buffers/ # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are...
apache-2.0
EvanK/ansible
lib/ansible/modules/cloud/openstack/os_subnets_facts.py
31
4515
#!/usr/bin/python # Copyright (c) 2015 Hewlett-Packard Development Company, L.P. # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) from __future__ import absolute_import, division, print_function __metaclass__ = type ANSIBLE_METADATA = {'metadata_version': '1.1', ...
gpl-3.0
chidea/GoPythonDLLWrapper
bin/lib/site-packages/pkg_resources/_vendor/packaging/_structures.py
906
1809
# Copyright 2014 Donald Stufft # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, so...
mit
jtoppins/beaker
IntegrationTests/src/bkr/inttest/client/test_workflow.py
1
4319
# 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. import unittest2 as unittest import re from bkr.client import BeakerWo...
gpl-2.0
adamnew123456/myweb
myweb/backend/db.py
1
8614
""" An interface on top of a database, which stores articles along with associated metadata. """ from collections import namedtuple import os import os.path import sqlite3 import sys import zlib import myweb.backend.query as query import myweb.backend.utils as utils # The connected database - there's meant to be onl...
bsd-2-clause
wfxiang08/ansible
lib/ansible/playbook/handler.py
237
1957
# (c) 2012-2014, Michael DeHaan <michael.dehaan@gmail.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 # (at your option) an...
gpl-3.0
mcrowson/django
tests/auth_tests/test_handlers.py
328
2868
from __future__ import unicode_literals from django.contrib.auth.handlers.modwsgi import ( check_password, groups_for_user, ) from django.contrib.auth.models import Group, User from django.contrib.auth.tests.custom_user import CustomUser from django.test import TransactionTestCase, override_settings # This must ...
bsd-3-clause
NewpTone/stacklab-cinder
cinder/tests/test_nfs.py
2
20277
# vim: tabstop=4 shiftwidth=4 softtabstop=4 # Copyright (c) 2012 NetApp, Inc. # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.or...
apache-2.0
hexxcointakeover/hexxcoin
qa/rpc-tests/disablewallet.py
102
1820
#!/usr/bin/env python3 # Copyright (c) 2015-2016 The Bitcoin Core developers # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. # # Exercise API with -disablewallet. # from test_framework.test_framework import BitcoinTestFramework f...
mit
nzavagli/UnrealPy
UnrealPyEmbed/Development/Python/2015.08.07-Python2710-x64-Source-vs2015/Python27/Source/boto-2.38.0/boto/dynamodb2/items.py
103
14658
from copy import deepcopy class NEWVALUE(object): # A marker for new data added. pass class Item(object): """ An object representing the item data within a DynamoDB table. An item is largely schema-free, meaning it can contain any data. The only limitation is that it must have data for the ...
mit
fossoult/odoo
addons/lunch/report/__init__.py
441
1087
# -*- encoding: utf-8 -*- ############################################################################## # # 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 G...
agpl-3.0
mmazanec22/too-windy
env/lib/python3.5/site-packages/dateutil/tz/_common.py
46
11744
from six import PY3 from six.moves import _thread from datetime import datetime, timedelta, tzinfo import copy ZERO = timedelta(0) __all__ = ['tzname_in_python2', 'enfold'] def tzname_in_python2(namefunc): """Change unicode output into bytestrings in Python 2 tzname() API changed in Python 3. It used to r...
gpl-3.0
krikru/tensorflow-opencl
tensorflow/contrib/tfprof/python/tools/tfprof/model_analyzer.py
62
6724
# Copyright 2016 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
apache-2.0
Salat-Cx65/python-for-android
python3-alpha/python3-src/Lib/test/test_osx_env.py
59
1341
""" Test suite for OS X interpreter environment variables. """ from test.support import EnvironmentVarGuard, run_unittest import subprocess import sys import unittest class OSXEnvironmentVariableTestCase(unittest.TestCase): def _check_sys(self, ev, cond, sv, val = sys.executable + 'dummy'): with Environme...
apache-2.0
alogg/dolfin
demo/undocumented/bcs/python/demo_bcs.py
1
1676
"""This demo illustrates how to set boundary conditions for meshes that include boundary indicators. The mesh used in this demo was generated with VMTK (http://www.vmtk.org/).""" # Copyright (C) 2008-2012 Anders Logg # # This file is part of DOLFIN. # # DOLFIN is free software: you can redistribute it and/or modify # ...
gpl-3.0
HBehrens/feedsanitizer
django/contrib/gis/gdal/datasource.py
321
4734
""" DataSource is a wrapper for the OGR Data Source object, which provides an interface for reading vector geometry data from many different file formats (including ESRI shapefiles). When instantiating a DataSource object, use the filename of a GDAL-supported data source. For example, a SHP file or a TIGER/Line...
mit
JioCloud/contrail-generateDS
tests/recursive_simpletype2_sub.py
10
4772
#!/usr/bin/env python # # Generated by generateDS.py. # import sys import recursive_simpletype2_sup as supermod etree_ = None Verbose_import_ = False ( XMLParser_import_none, XMLParser_import_lxml, XMLParser_import_elementtree ) = range(3) XMLParser_import_library = None try: # lxml from lxml imp...
mit
muffl0n/ansible-cmdb
lib/mako/ast.py
60
6702
# mako/ast.py # Copyright (C) 2006-2015 the Mako authors and contributors <see AUTHORS file> # # This module is part of Mako and is released under # the MIT License: http://www.opensource.org/licenses/mit-license.php """utilities for analyzing expressions and blocks of Python code, as well as generating Python from AS...
mit
PopCap/GameIdea
Engine/Source/ThirdParty/HTML5/emsdk/Win64/python/2.7.5.3_64bit/Lib/site-packages/pip/vendor/html5lib/html5parser.py
79
117499
from __future__ import absolute_import, division, unicode_literals from pip.vendor.six import with_metaclass import types from . import inputstream from . import tokenizer from . import treebuilders from .treebuilders._base import Marker from . import utils from . import constants from .constants import spaceCharac...
bsd-2-clause
labordoc/labordoc-next
modules/bibsword/lib/bibsword_client_http.py
25
6651
## This file is part of Invenio. ## Copyright (C) 2010, 2011 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 version. ## ...
gpl-2.0
madan96/sympy
sympy/polys/rootisolation.py
78
55536
"""Real and complex root isolation and refinement algorithms. """ from __future__ import print_function, division from sympy.polys.densebasic import ( dup_LC, dup_TC, dup_degree, dup_strip, dup_reverse, dup_convert, dup_terms_gcd) from sympy.polys.densearith import ( dup_neg, dup_rshift, dup_rem)...
bsd-3-clause
navycrow/Sick-Beard
lib/imdb/parser/http/searchCharacterParser.py
67
2793
""" parser.http.searchCharacterParser module (imdb package). This module provides the HTMLSearchCharacterParser class (and the search_character_parser instance), used to parse the results of a search for a given character. E.g., when searching for the name "Jesse James", the parsed page would be: http://akas.imdb....
gpl-3.0
OpenAcademy-OpenStack/nova-scheduler
nova/tests/virt/vmwareapi/test_vm_util_datastore_selection.py
3
5170
# # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # ...
apache-2.0
yokose-ks/edx-platform
common/djangoapps/service_status/test.py
88
1381
"""Test for async task service status""" from django.utils import unittest from django.test.client import Client from django.core.urlresolvers import reverse import json class CeleryConfigTest(unittest.TestCase): """ Test that we can get a response from Celery """ def setUp(self): """ ...
agpl-3.0
yunify/qingcloud-cli
qingcloud/cli/iaas_client/actions/eip/allocate_eips.py
1
3185
# ========================================================================= # Copyright 2012-present Yunify, Inc. # ------------------------------------------------------------------------- # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this work except in compliance with the Licens...
apache-2.0
ChenJunor/hue
desktop/core/ext-py/Django-1.6.10/django/contrib/sessions/backends/db.py
101
2929
import logging from django.contrib.sessions.backends.base import SessionBase, CreateError from django.core.exceptions import SuspiciousOperation from django.db import IntegrityError, transaction, router from django.utils import timezone from django.utils.encoding import force_text class SessionStore(SessionBase): ...
apache-2.0
ktan2020/legacy-automation
win/Lib/site-packages/wx-3.0-msw/wx/tools/Editra/src/syntax/_actionscript.py
1
3261
############################################################################### # Name: actionscript.py # # Purpose: Define ActionScript syntax for highlighting and other features # # Author: Cody Precord <cprecord@editra.org> ...
mit
dreamsxin/kbengine
kbe/src/lib/python/Lib/encodings/iso2022_jp_2.py
816
1061
# # iso2022_jp_2.py: Python Unicode Codec for ISO2022_JP_2 # # Written by Hye-Shik Chang <perky@FreeBSD.org> # import _codecs_iso2022, codecs import _multibytecodec as mbc codec = _codecs_iso2022.getcodec('iso2022_jp_2') class Codec(codecs.Codec): encode = codec.encode decode = codec.decode class Incrementa...
lgpl-3.0
CredoReference/edx-platform
common/djangoapps/student/tests/test_userstanding.py
13
4168
""" These are tests for disabling and enabling student accounts, and for making sure that students with disabled accounts are unable to access the courseware. """ import unittest from django.conf import settings from django.urls import reverse from django.test import Client, TestCase from student.models import UserSt...
agpl-3.0
hwuiwon/namebench
nb_third_party/httplib2/__init__.py
451
51082
from __future__ import generators """ httplib2 A caching http interface that supports ETags and gzip to conserve bandwidth. Requires Python 2.3 or later Changelog: 2007-08-18, Rick: Modified so it's able to use a socks proxy if needed. """ __author__ = "Joe Gregorio (joe@bitworking.org)" __copyright__ = "Copyrigh...
apache-2.0
mhlechner/psi4
psi4/driver/inputparser.py
1
30572
# # @BEGIN LICENSE # # Psi4: an open-source quantum chemistry software package # # Copyright (c) 2007-2017 The Psi4 Developers. # # The copyrights for code used from other parties are included in # the corresponding files. # # This program is free software; you can redistribute it and/or modify # it under the terms of ...
gpl-2.0
vFense/vFenseAgent-nix
agent/deps/mac/Python-2.7.5/lib/python2.7/encodings/utf_16.py
404
3984
""" Python 'utf-16' Codec Written by Marc-Andre Lemburg (mal@lemburg.com). (c) Copyright CNRI, All Rights Reserved. NO WARRANTY. """ import codecs, sys ### Codec APIs encode = codecs.utf_16_encode def decode(input, errors='strict'): return codecs.utf_16_decode(input, errors, True) class IncrementalEncoder(c...
lgpl-3.0
GbalsaC/bitnamiP
venv/lib/python2.7/site-packages/dateutil/zoneinfo/__init__.py
144
2773
# -*- coding: utf-8 -*- """ Copyright (c) 2003-2005 Gustavo Niemeyer <gustavo@niemeyer.net> This module offers extensions to the standard Python datetime module. """ from dateutil.tz import tzfile from tarfile import TarFile import os __author__ = "Tomi Pieviläinen <tomi.pievilainen@iki.fi>" __license__ = "Simplifie...
agpl-3.0
ojengwa/odoo
addons/product/__init__.py
443
1120
# -*- coding: utf-8 -*- ############################################################################## # # OpenERP, Open Source Management Solution # Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>). # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU...
agpl-3.0
Kijewski/ctypesgen_to_pxd
convert_libc.py
1
3013
#!/usr/bin/env python3 from os import open, O_RDWR, makedirs, devnull from os.path import abspath, exists, isfile, isdir, dirname from subprocess import check_call, check_output, STDOUT from re import compile as compile_re, M from sys import argv, stderr # Standard headers as of POSIX.1-2008 (Base Specifications, Is...
apache-2.0
smcv/android_kernel_samsung_tuna
tools/perf/scripts/python/sctop.py
11180
1924
# system call top # (c) 2010, Tom Zanussi <tzanussi@gmail.com> # Licensed under the terms of the GNU GPL License version 2 # # Periodically displays system-wide system call totals, broken down by # syscall. If a [comm] arg is specified, only syscalls called by # [comm] are displayed. If an [interval] arg is specified,...
gpl-2.0
dylanlesko/youtube-dl
youtube_dl/extractor/hotnewhiphop.py
129
2306
from __future__ import unicode_literals import base64 from .common import InfoExtractor from ..compat import ( compat_urllib_parse, compat_urllib_request, ) from ..utils import ( ExtractorError, HEADRequest, ) class HotNewHipHopIE(InfoExtractor): _VALID_URL = r'http://www\.hotnewhiphop\.com/.*\....
unlicense
alkyl1978/gnuradio
gr-analog/python/analog/wfm_rcv.py
58
2782
# # Copyright 2005,2007,2012 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 ve...
gpl-3.0
chris-allan/openmicroscopy
components/tools/OmeroWeb/omeroweb/webgateway/templatetags/common_filters.py
3
2558
# #!/usr/bin/env python # # # # Copyright (c) 2008 University of Dundee. # # 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...
gpl-2.0
ProjectSWGCore/NGECore2
scripts/mobiles/endor/hardened_panshee_warrior.py
2
3153
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...
lgpl-3.0
KaranToor/MA450
google-cloud-sdk/platform/gsutil/third_party/boto/boto/cloudformation/connection.py
127
42922
# Copyright (c) 2006-2009 Mitch Garnaat http://garnaat.org/ # Copyright (c) 2014 Amazon.com, Inc. or its affiliates. All Rights Reserved # # Permission is hereby granted, free of charge, to any person obtaining a # copy of this software and associated documentation files (the # "Software"), to deal in the Software wit...
apache-2.0
sachintaware/sublime-wakatime
packages/wakatime/packages/pygments_py3/pygments/lexers/felix.py
72
9410
# -*- coding: utf-8 -*- """ pygments.lexers.felix ~~~~~~~~~~~~~~~~~~~~~ Lexer for the Felix language. :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ from pygments.lexer import RegexLexer, include, bygroups, default, words, \ comb...
bsd-3-clause
arborh/tensorflow
tensorflow/python/lib/io/file_io_test.py
7
24382
# This Python file uses the following encoding: utf-8 # Copyright 2015 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.o...
apache-2.0
CalthorpeAnalytics/urbanfootprint
footprint/main/publishing/user_initialization.py
1
5524
# UrbanFootprint v1.5 # Copyright (C) 2017 Calthorpe Analytics # # This file is part of UrbanFootprint version 1.5 # # UrbanFootprint is distributed under the terms of the GNU General # Public License version 3, as published by the Free Software Foundation. This # code is distributed WITHOUT ANY WARRANTY, without impl...
gpl-3.0
mttr/django
django/db/backends/postgresql/features.py
158
1063
from django.db.backends.base.features import BaseDatabaseFeatures from django.db.utils import InterfaceError class DatabaseFeatures(BaseDatabaseFeatures): allows_group_by_selected_pks = True can_return_id_from_insert = True has_real_datatype = True has_native_uuid_field = True has_native_duration_...
bsd-3-clause
SurfasJones/icecream-info
icecream/lib/python2.7/site-packages/pip/backwardcompat/__init__.py
394
3756
"""Stuff that differs in different Python versions and platform distributions.""" import os import imp import sys import site __all__ = ['WindowsError'] uses_pycache = hasattr(imp, 'cache_from_source') class NeverUsedException(Exception): """this exception should never be raised""" try: WindowsError = Wind...
mit
BhupeshGupta/erpnext
erpnext/manufacturing/doctype/production_order/test_production_order.py
7
2388
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors # License: GNU General Public License v3. See license.txt from __future__ import unicode_literals import unittest import frappe from erpnext.stock.doctype.purchase_receipt.test_purchase_receipt import set_perpetual_inventory from erpnext.manufact...
agpl-3.0
petteyg/intellij-community
python/lib/Lib/wsgiref/handlers.py
104
15596
"""Base classes for server/gateway implementations""" from types import StringType from util import FileWrapper, guess_scheme, is_hop_by_hop from headers import Headers import sys, os, time __all__ = ['BaseHandler', 'SimpleHandler', 'BaseCGIHandler', 'CGIHandler'] try: dict except NameError: def dict(items)...
apache-2.0
CuonDeveloper/cuon
cuon_client/cuon/Think/SingleThink.py
3
1731
# -*- coding: utf-8 -*- ##Copyright (C) [2005] [Jürgen Hamel, D-32584 Löhne] ##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 versio...
gpl-3.0