repo_name
stringlengths
5
100
ref
stringlengths
12
67
path
stringlengths
4
244
copies
stringlengths
1
8
content
stringlengths
0
1.05M
apark263/tensorflow
refs/heads/master
tensorflow/contrib/gan/python/losses/python/losses_wargs.py
73
# Copyright 2017 Google Inc. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agree...
illfelder/compute-image-packages
refs/heads/master
packages/python-google-compute-engine/google_compute_engine/networking/network_setup/__init__.py
12133432
DBarthe/wikigraph
refs/heads/master
wikigraph/collector/__init__.py
12133432
tundebabzy/frappe
refs/heads/develop
frappe/patches/v11_0/__init__.py
12133432
arun6582/django
refs/heads/master
django/contrib/gis/db/backends/oracle/__init__.py
12133432
hernad/frappe
refs/heads/develop
frappe/desk/doctype/__init__.py
12133432
LWJensen/coala-bears
refs/heads/master
bears/markdown/__init__.py
12133432
yewang15215/django
refs/heads/master
django/contrib/sites/migrations/__init__.py
12133432
carrillo/scikit-learn
refs/heads/master
sklearn/datasets/tests/test_covtype.py
335
"""Test the covtype loader. Skipped if covtype is not already downloaded to data_home. """ import errno from sklearn.datasets import fetch_covtype from sklearn.utils.testing import assert_equal, SkipTest def fetch(*args, **kwargs): return fetch_covtype(*args, download_if_missing=False, **kwargs) def test_fetc...
huchoi/edx-platform
refs/heads/master
cms/djangoapps/contentstore/views/checklist.py
5
import json import copy from util.json_request import JsonResponse from django.http import HttpResponseBadRequest from django.contrib.auth.decorators import login_required from django.views.decorators.http import require_http_methods from django_future.csrf import ensure_csrf_cookie from edxmako.shortcuts import rende...
ashepelev/TopologyWeigher
refs/heads/master
test_framework/testing.py
1
import BandwidthHistory import Scheduler __author__ = 'ash' import yaml import GraphDrawer import TrafficGen stream_nodes = file('topology-examples/nodes1.yaml','r') stream_edges = file('topology-examples/edges1.yaml','r') node_list = yaml.load(stream_nodes) edge_list = yaml.load(stream_edges) bwhist = Bandwidt...
i945/An
refs/heads/master
An/extra_apps/xadmin/plugins/quickfilter.py
10
''' Created on Mar 26, 2014 @author: LAB_ADM ''' from future.utils import iteritems from django.utils import six from django.utils.translation import ugettext_lazy as _ from xadmin.filters import manager,MultiSelectFieldListFilter from xadmin.plugins.filters import * from xadmin.util import is_related_field @manager....
klmitch/nova
refs/heads/master
nova/tests/functional/compute/test_instance_list.py
5
# 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 # d...
OpenFAST/r-test
refs/heads/f/driver
updateBaselineSolutions.py
1
# # Copyright 2017 National Renewable Energy Laboratory # # 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 la...
mistercrunch/airflow
refs/heads/master
airflow/hooks/dbapi.py
5
# # 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...
rdeheele/odoo
refs/heads/master
addons/auth_openid/controllers/main.py
382
# -*- coding: utf-8 -*- ############################################################################## # # OpenERP, Open Source Management Solution # Copyright (C) 2010-2012 OpenERP s.a. (<http://openerp.com>). # # This program is free software: you can redistribute it and/or modify # it under the terms of ...
blackzw/openwrt_sdk_dev1
refs/heads/master
staging_dir/target-mips_r2_uClibc-0.9.33.2/usr/lib/python2.7/test/test_getargs.py
130
""" Test the internal getargs.c implementation PyArg_ParseTuple() is defined here. The test here is not intended to test all of the module, just the single case that failed between 2.1 and 2.2a2. """ # marshal.loads() uses PyArg_ParseTuple(args, "s#:loads") # The s code will cause a Unicode conversion to occur. Th...
nolanamy/zxing
refs/heads/master
cpp/scons/scons-local-2.0.0.final.0/SCons/Tool/sunar.py
34
"""engine.SCons.Tool.sunar Tool-specific initialization for Solaris (Forte) ar (library archive). If CC exists, static libraries should be built with it, so that template instantians can be resolved. There normally shouldn't be any need to import this module directly. It will usually be imported through the generic S...
gangadharkadam/smrterp
refs/heads/develop
erpnext/accounts/report/sales_invoice_trends/__init__.py
12133432
namili/blueman
refs/heads/master
blueman/main/applet/__init__.py
12133432
nikolas/lettuce
refs/heads/master
tests/integration/lib/Django-1.3/tests/regressiontests/test_utils/__init__.py
12133432
spaceone/pyjs
refs/heads/master
examples/_examples/__init__.py
12133432
digimarc/django
refs/heads/master
django/contrib/sessions/management/commands/__init__.py
12133432
memsharded/conan
refs/heads/develop
conans/test/functional/command/help_test.py
1
import sys import unittest from six import StringIO from conans import __version__ from conans.test.utils.tools import TestClient class BasicClientTest(unittest.TestCase): def help_test(self): client = TestClient() client.run("") self.assertIn('Conan commands. Type "conan <command> -h" ...
jeremymcrhat/Nexus_5X_kernel
refs/heads/8992_upstream_test_v2
scripts/gdb/linux/__init__.py
2010
# nothing to do for the initialization of this package
munhanha/mtg-random
refs/heads/master
django/test/client.py
73
import urllib from urlparse import urlparse, urlunparse, urlsplit import sys import os import re import mimetypes import warnings from copy import copy try: from cStringIO import StringIO except ImportError: from StringIO import StringIO from django.conf import settings from django.contrib.auth import authenti...
samisalkosuo/clipasswordmgr
refs/heads/master
clipwdmgr/commands/ExitCommand.py
1
# -*- coding: utf-8 -*- #The MIT License (MIT) # #Copyright (c) 2015,2018 Sami Salkosuo # #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 r...
seanli9jan/tensorflow
refs/heads/master
tensorflow/python/ops/partitioned_variables.py
4
# 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.org/licenses/LICENSE-2.0 # # Unless required by applica...
trol73/avr-ic-tester-v2
refs/heads/master
python/device.py
1
# -*- coding: utf-8 -*- import time import serial __author__ = 'Trol' class Device: CMD_SYNC = 1 CMD_ENTER_TEST_MODE = 2 CMD_TEST_INSTRUCTION = 3 CMD_READ_CHIP = 4 CMD_EXIT_TEST_MODE = 5 CMD_SEND_BYTE_TO_DISPLAY = 6 CMD_SEND_BYTES_TO_DISPLAY = 7 CMD_READ_BYTE_FROM_DISPLAY = 8 CMD...
Sage-Bionetworks/U4CChallenge
refs/heads/master
python/challenge_config.template.py
3
##----------------------------------------------------------------------------- ## ## challenge specific code and configuration ## ##----------------------------------------------------------------------------- ## A Synapse project will hold the assetts for your challenge. Put its ## synapse ID here, for example ## C...
agoose77/hivesystem
refs/heads/master
dragonfly/std/generator.py
1
import bee from bee.segments import * class generator(object): metaguiparams = {"type": "type", "generator": "object"} def __new__(cls, type, generator): genfunc = generator class generator(bee.worker): gen = None outp = output("pull", type) v_outp = varia...
c-benko/HHG_Phasematching
refs/heads/master
test/i_scan.py
1
# i_scan.py import sys, os here = os.path.dirname(os.path.abspath(__file__)) sys.path.insert(0, os.path.normpath(os.path.join(here, '../src'))) from phasematching import * import matplotlib from matplotlib import pyplot as plt num = 100 iscan = np.linspace(0.1, 1.0, num) harm = np.array(np.zeros(num)) Lcoh = np.a...
nevercast/home-assistant
refs/heads/dev
homeassistant/bootstrap.py
3
""" homeassistant.bootstrap ~~~~~~~~~~~~~~~~~~~~~~~ Provides methods to bootstrap a home assistant instance. Each method will return a tuple (bus, statemachine). After bootstrapping you can add your own components or start by calling homeassistant.start_home_assistant(bus) """ from collections import defaultdict imp...
corredD/ePMV
refs/heads/master
cinema4d/c4dAdaptor.py
1
""" Copyright (C) <2010> Autin L. This file ePMV_git/cinema4d/c4dAdaptor.py is part of ePMV. ePMV 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 ...
tchernomax/ansible
refs/heads/devel
contrib/inventory/fleet.py
79
#!/usr/bin/env python """ fleetctl base external inventory script. Automatically finds the IPs of the booted coreos instances and returns it under the host group 'coreos' """ # Copyright (C) 2014 Andrew Rothstein <andrew.rothstein at gmail.com> # # This program is free software: you can redistribute it and/or modify ...
yograterol/django
refs/heads/master
tests/field_deconstruction/tests.py
69
from __future__ import unicode_literals from django.db import models from django.test import SimpleTestCase, override_settings from django.utils import six class FieldDeconstructionTests(SimpleTestCase): """ Tests the deconstruct() method on all core fields. """ def test_name(self): """ ...
glenngillen/dotfiles
refs/heads/master
.vscode/extensions/ms-python.python-2021.5.842923320/pythonFiles/lib/python/debugpy/_vendored/pydevd/_pydev_imps/_pydev_saved_modules.py
2
import sys IS_PY2 = sys.version_info < (3,) import threading import time import socket import select if IS_PY2: import thread import Queue as _queue import xmlrpclib import SimpleXMLRPCServer as _pydev_SimpleXMLRPCServer import BaseHTTPServer else: import _thread as thread...
pixelated/pixelated-user-agent
refs/heads/master
service/pixelated/resources/mail_resource.py
2
# # Copyright (c) 2015 ThoughtWorks, Inc. # # Pixelated 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. # # Pixelated is distrib...
israelbenatar/boto
refs/heads/develop
boto/rds/__init__.py
126
# Copyright (c) 2009-2012 Mitch Garnaat http://garnaat.org/ # # 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, modi...
eeshangarg/zulip
refs/heads/master
zerver/migrations/0279_message_recipient_subject_indexes.py
5
# Generated by Django 2.2.12 on 2020-04-30 00:35 from django.db import migrations class Migration(migrations.Migration): atomic = False dependencies = [ ("zerver", "0278_remove_userprofile_alert_words"), ] operations = [ migrations.RunSQL( """ CREATE INDEX CONCUR...
timrudge/Platypus
refs/heads/master
ConvertPlateReader.py
1
import sys import os import datetime import csv usage = """usage: ConvertPlateReader.py infile outfile row-name* """ def find_in_sublists(lst, value): for sub_i, sublist in enumerate(lst): try: return (sub_i, sublist.index(value)) except ValueError: pass ...
cts2/rf2db
refs/heads/master
bin/__init__.py
8
# -*- coding: utf-8 -*- # Copyright (c) 2013, Mayo Clinic # All rights reserved. # # Redistribution and use in source and binary forms, with or without modification, # are permitted provided that the following conditions are met: # # Redistributions of source code must retain the above copyright notice, this # ...
sixu05202004/newsmeme
refs/heads/master
newsmeme-blueprints/newsmeme/newsmeme/apps/comment/forms.py
2
#!/usr/bin/env python # -*- coding: utf-8 -*- from flask_wtf import Form from wtforms import TextAreaField, SubmitField from wtforms.validators import Required from flask.ext.babel import lazy_gettext as _ class CommentForm(Form): comment = TextAreaField(validators=[ Required(message...
asm-products/cloudroutes-service
refs/heads/master
src/web/user/__init__.py
12133432
github-account-because-they-want-it/django-allauth
refs/heads/master
allauth/socialaccount/providers/google/__init__.py
12133432
hryamzik/ansible
refs/heads/devel
lib/ansible/modules/remote_management/__init__.py
12133432
unseenlaser/python-for-android
refs/heads/master
python-build/python-libs/gdata/samples/oauth/oauth_on_appengine/appengine_utilities/__init__.py
12133432
gangadhar-kadam/verve-erp
refs/heads/v5.0
erpnext/hr/doctype/deduction_type/deduction_type.py
41
# 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 frappe from frappe.model.document import Document class DeductionType(Document): pass
emorozov/django-basic-apps
refs/heads/master
basic/profiles/views.py
10
from django.shortcuts import render_to_response from django.template import RequestContext from django.http import Http404, HttpResponseRedirect from django.views.generic import list_detail from django.contrib.auth.models import User from django.contrib.auth.decorators import login_required from django.core.urlresolver...
trezorg/django
refs/heads/master
django/conf/locale/fy_NL/formats.py
1293
# -*- encoding: utf-8 -*- # This file is distributed under the same license as the Django package. # # The *_FORMAT strings use the Django date format syntax, # see http://docs.djangoproject.com/en/dev/ref/templates/builtins/#date # DATE_FORMAT = # TIME_FORMAT = # DATETIME_FORMAT = # YEAR_MONTH_FORMAT = # MONTH_DA...
FHannes/intellij-community
refs/heads/master
python/testData/refactoring/changeSignature/keywordOnlyMove.after.py
83
def f<caret>(param2, *, param1): pass f(param2=2, param1=1)
ettm2012/MissionPlanner
refs/heads/master
Lib/site-packages/numpy/core/src/multiarray/testcalcs.py
59
from scipy import weave class YMD(object): year = 0 month = 0 days = 0 month_offset = [ [ 0, 31, 59, 90, 120, 151, 181, 212, 243, 273, 304, 334, 365 ], [ 0, 31, 60, 91, 121, 152, 182, 213, 244, 274, 305, 335, 366 ] ] days_in_month = [ [ 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 ], ...
isaac-philip/loolu
refs/heads/master
common/django/contrib/localflavor/ro/ro_counties.py
428
# -*- coding: utf-8 -*- """ A list of Romanian counties as `choices` in a formfield. This exists as a standalone file so that it's only imported into memory when explicitly needed. """ COUNTIES_CHOICES = ( ('AB', u'Alba'), ('AR', u'Arad'), ('AG', u'Argeş'), ('BC', u'Bacău'), ('BH', u'Bihor'), ...
hazrpg/calibre
refs/heads/master
src/html5lib/trie/datrie.py
14
from __future__ import absolute_import, division, unicode_literals from datrie import Trie as DATrie try: text_type = unicode except NameError: text_type = str from ._base import Trie as ABCTrie class Trie(ABCTrie): def __init__(self, data): chars = set() for key in data.keys(): ...
swannapa/erpnext
refs/heads/develop
erpnext/docs/user/manual/de/human-resources/setup/__init__.py
12133432
ghedsouza/django
refs/heads/master
tests/migrations/migrations_test_apps/lookuperror_a/__init__.py
12133432
RossBrunton/django
refs/heads/master
tests/migrations/migrations_test_apps/alter_fk/__init__.py
12133432
farodin91/servo
refs/heads/master
tests/wpt/web-platform-tests/websockets/handlers/echo_exit_wsh.py
258
#!/usr/bin/python from mod_pywebsocket import msgutil _GOODBYE_MESSAGE = u'Goodbye' def web_socket_do_extra_handshake(request): # This example handler accepts any request. See origin_check_wsh.py for how # to reject access from untrusted scripts based on origin value. pass # Always accept. def web_soc...
anant-dev/django
refs/heads/master
django/db/backends/postgresql/utils.py
682
from django.utils.timezone import utc def utc_tzinfo_factory(offset): if offset != 0: raise AssertionError("database connection isn't set to UTC") return utc
cloudfoundry/php-buildpack-legacy
refs/heads/master
builds/runtimes/python-2.7.6/lib/python2.7/distutils/tests/test_cmd.py
54
"""Tests for distutils.cmd.""" import unittest import os from test.test_support import captured_stdout, run_unittest from distutils.cmd import Command from distutils.dist import Distribution from distutils.errors import DistutilsOptionError from distutils import debug class MyCmd(Command): def initialize_options(...
kinsamanka/linux
refs/heads/rpi-3.6.y
tools/perf/scripts/python/Perf-Trace-Util/lib/Perf/Trace/SchedGui.py
12980
# SchedGui.py - Python extension for perf script, basic GUI code for # traces drawing and overview. # # Copyright (C) 2010 by Frederic Weisbecker <fweisbec@gmail.com> # # This software is distributed under the terms of the GNU General # Public License ("GPL") version 2 as published by the Free Software # Foundation. ...
tclose/PyPe9
refs/heads/master
pype9/simulate/common/code_gen/base.py
2
""" This module defines common methods used in simulator specific build modules @author Tom Close """ ########################################################################## # # Copyright 2011 Okinawa Institute of Science and Technology (OIST), Okinawa # ###################################################...
jmartu/testing
refs/heads/master
venv/lib/python3.6/site-packages/pip/_vendor/requests/status_codes.py
481
# -*- coding: utf-8 -*- from .structures import LookupDict _codes = { # Informational. 100: ('continue',), 101: ('switching_protocols',), 102: ('processing',), 103: ('checkpoint',), 122: ('uri_too_long', 'request_uri_too_long'), 200: ('ok', 'okay', 'all_ok', 'all_okay', 'all_good', '\\o/'...
cyisfor/Python-Markdown
refs/heads/master
markdown/inlinepatterns.py
65
""" INLINE PATTERNS ============================================================================= Inline patterns such as *emphasis* are handled by means of auxiliary objects, one per pattern. Pattern objects must be instances of classes that extend markdown.Pattern. Each pattern object uses a single regular express...
waxmanr/moose
refs/heads/devel
framework/contrib/nsiqcppstyle/rules/RULE_5_2_C_provide_doxygen_class_comment_on_class_def.py
43
""" Provide the class doxygen comment. It checks if there is doxygen sytle comment in front of each class definition. == Violation == class A { <== Violation. No doxygen comment. }; /* <== Violation. It's not a doxygen comment * */ class B { }; == Good == /** * blar bl...
optima-ict/odoo
refs/heads/9.0
addons/hr/res_users.py
46
from openerp import api from openerp.osv import fields, osv class res_users(osv.Model): """ Update of res.users class - add field for the related employee of the user - if adding groups to an user, check if base.group_user is in it (member of 'Employee'), create an employee form linked to it. ""...
joshkh/intermine
refs/heads/beta
bio/scripts/humanmine/gen_ncbi_linkouts.py
12
#!/usr/bin/env python # This is an automatically generated script to run your query # to use it you will require the intermine python client. # To install the client, run the following command from a terminal: # # sudo easy_install intermine # # For further documentation you can visit: # http://intermine.readt...
vimalkvn/riboseqr_wrapper
refs/heads/master
riboseqr/__init__.py
1349
# -*- coding: utf-8 -*-
HubSpot/vitess
refs/heads/hubspot-client
py/util/static_auth_client.py
8
# Copyright 2017 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, ...
sigma-random/scrapy
refs/heads/master
tests/test_utils_signal.py
15
from twisted.trial import unittest from twisted.python import log as txlog from twisted.python.failure import Failure from twisted.internet import defer, reactor from scrapy.xlib.pydispatch import dispatcher from scrapy.utils.signal import send_catch_log, send_catch_log_deferred from scrapy import log class SendCatch...
zx8/youtube-dl
refs/heads/master
youtube_dl/extractor/nowtv.py
9
# coding: utf-8 from __future__ import unicode_literals import re from .common import InfoExtractor from ..compat import compat_str from ..utils import ( ExtractorError, int_or_none, parse_iso8601, parse_duration, remove_start, ) class NowTVIE(InfoExtractor): _VALID_URL = r'https?://(?:www\....
kalxas/QGIS
refs/heads/master
python/plugins/processing/gui/BatchAlgorithmDialog.py
25
# -*- coding: utf-8 -*- """ *************************************************************************** BatchAlgorithmDialog.py --------------------- Date : August 2012 Copyright : (C) 2012 by Victor Olaya Email : volayaf at gmail dot com ******************...
Vagab0nd/SiCKRAGE
refs/heads/master
lib3/oauthlib/oauth1/rfc5849/endpoints/resource.py
10
# -*- coding: utf-8 -*- """ oauthlib.oauth1.rfc5849.endpoints.resource ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ This module is an implementation of the resource protection provider logic of OAuth 1.0 RFC 5849. """ from __future__ import absolute_import, unicode_literals import logging from .. import errors from .b...
asser/django
refs/heads/master
tests/foreign_object/models/person.py
64
import datetime from django.db import models from django.utils.encoding import python_2_unicode_compatible @python_2_unicode_compatible class Country(models.Model): # Table Column Fields name = models.CharField(max_length=50) def __str__(self): return self.name @python_2_unicode_compatible cla...
the-zebulan/CodeWars
refs/heads/master
katas/kyu_4/human_readable_duration_format.py
1
IN_SECONDS = (('year', 31536000), ('day', 86400), ('hour', 3600), ('minute', 60), ('second', 1)) def format_duration(seconds): if not seconds: return 'now' times = [] words = 0 for name, num in IN_SECONDS: q, seconds = divmod(seconds, num) if q: times....
mkennedy04/knodj
refs/heads/master
env/Lib/site-packages/pip/_vendor/requests/packages/chardet/eucjpprober.py
2918
######################## 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...
stvstnfrd/edx-platform
refs/heads/master
openedx/core/djangoapps/credentials/settings/__init__.py
12133432
StackStorm/st2
refs/heads/master
st2api/st2api/controllers/exp/__init__.py
12133432
UNINETT/nav
refs/heads/master
python/nav/metrics/__init__.py
2
# Copyright (C) 2013 Uninett AS # # This file is part of Network Administration Visualized (NAV). # # NAV is free software: you can redistribute it and/or modify it under # the terms of the GNU General Public License version 3 as published by # the Free Software Foundation. # # This program is distributed in the hope t...
ianyh/heroku-buildpack-python-opencv
refs/heads/master
vendor/.heroku/lib/python2.7/encodings/zlib_codec.py
533
""" Python 'zlib_codec' Codec - zlib compression encoding Unlike most of the other codecs which target Unicode, this codec will return Python string objects for both encode and decode. Written by Marc-Andre Lemburg (mal@lemburg.com). """ import codecs import zlib # this codec needs the optional zlib modu...
whaleygeek/mb_sdcard
refs/heads/master
src/microbit/auto_serial/serial/serialposix.py
141
#!/usr/bin/env python # # Python Serial Port Extension for Win32, Linux, BSD, Jython # module for serial IO for POSIX compatible systems, like Linux # see __init__.py # # (C) 2001-2010 Chris Liechti <cliechti@gmx.net> # this is distributed under a free software license, see license.txt # # parts based on code from Gran...
anandsimmy/ecommerce
refs/heads/master
src/oscar/apps/address/migrations/0003_auto_20150927_1551.py
10
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import models, migrations class Migration(migrations.Migration): dependencies = [ ('address', '0002_auto_20150927_1547'), ] operations = [ migrations.AlterModelOptions( name='useraddress', ...
Shihta/python-novaclient
refs/heads/shihta0
novaclient/v1_1/usage.py
5
# # 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 # ...
knxd/PyKNyX
refs/heads/master
pyknyx/proto/connection.py
2
""" """ import threading class BaseConnection(threading.Thread): """ """ def __init__(self, *args, **kwargs): """ """ super(BaseConnection, self).__init__(*args, **kwargs) self._run = False def stop(): """ """ self._run = True class KnxConne...
uwafsl/MissionPlanner
refs/heads/master
Lib/wave.py
53
"""Stuff to parse WAVE files. Usage. Reading WAVE files: f = wave.open(file, 'r') where file is either the name of a file or an open file pointer. The open file pointer must have methods read(), seek(), and close(). When the setpos() and rewind() methods are not used, the seek() method is not necessar...
1fabunicorn/resnix
refs/heads/master
mainmodules/IO.py
1
# -*- coding: utf-8 -*- from __future__ import print_function """ Input Output function reads from saves, writes plaintext on 'unlock' Copyright (C) 2017, Nova Trauben, noah.trauben@gmail.com This program is free software: you can redistribute it and/or modify it under the terms of the GNU General...
deepinsight/Deformable-ConvNets
refs/heads/master
lib/utils/PrefetchingIter.py
2
# -------------------------------------------------------- # Deformable Convolutional Networks # Copyright (c) 2016 by Contributors # Copyright (c) 2017 Microsoft # Licensed under The Apache-2.0 License [see LICENSE for details] # Modified by Yuwen Xiong # -------------------------------------------------------- impo...
rahuldhote/odoo
refs/heads/8.0
addons/calendar/contacts.py
389
# -*- coding: utf-8 -*- ############################################################################## # # OpenERP, Open Source Business Applications # Copyright (c) 2011 OpenERP S.A. <http://openerp.com> # # This program is free software: you can redistribute it and/or modify # it under the terms of the GN...
lparsons/bioconda-recipes
refs/heads/master
recipes/wtforms-components/setup.py
63
""" WTForms-Components ------------------ Additional fields, validators and widgets for WTForms. """ from setuptools import setup import os import re import sys HERE = os.path.dirname(os.path.abspath(__file__)) PY3 = sys.version_info[0] == 3 def get_version(): filename = os.path.join(HERE, 'wtforms_components...
mangadul/WhatsAppy
refs/heads/master
yowsup/layers/axolotl/store/sqlite/liteaxolotlstore.py
17
from axolotl.state.axolotlstore import AxolotlStore from .liteidentitykeystore import LiteIdentityKeyStore from .liteprekeystore import LitePreKeyStore from .litesessionstore import LiteSessionStore from .litesignedprekeystore import LiteSignedPreKeyStore from .litesenderkeystore import LiteSenderKeyStore import sqlite...
akosyakov/intellij-community
refs/heads/master
python/helpers/pydev/third_party/pep8/lib2to3/lib2to3/fixes/fix_methodattrs.py
326
"""Fix bound method attributes (method.im_? -> method.__?__). """ # Author: Christian Heimes # Local imports from .. import fixer_base from ..fixer_util import Name MAP = { "im_func" : "__func__", "im_self" : "__self__", "im_class" : "__self__.__class__" } class FixMethodattrs(fixer_base.BaseFix): ...
shreyasp/erpnext
refs/heads/develop
erpnext/stock/dashboard/__init__.py
12133432
kennethdecker/MagnePlane
refs/heads/master
src/__init__.py
12133432
JioCloud/nova_test_latest
refs/heads/master
nova/tests/unit/api/openstack/compute/test_plugins/__init__.py
12133432
neopenx/Dragon
refs/heads/master
examples/Seg-FCN/voc-fcn16s/test.py
1
# -------------------------------------------------------- # Seg-FCN for Dragon # Copyright (c) 2017 SeetaTech # Written by Ting Pan # -------------------------------------------------------- """ Test a FCN-16s(PASCAL VOC) network """ import dragon.vm.caffe as caffe import score import numpy as np weights = 'snapsho...
Tudorvr/metagoofil
refs/heads/master
hachoir_core/stream/__init__.py
95
from hachoir_core.endian import BIG_ENDIAN, LITTLE_ENDIAN from hachoir_core.stream.stream import StreamError from hachoir_core.stream.input import ( InputStreamError, InputStream, InputIOStream, StringInputStream, InputSubStream, InputFieldStream, FragmentedStream, ConcatStream) from hac...
OpenNetworkingFoundation/ONFOpenTransport
refs/heads/develop
RI/flask_server/tapi_server/models/tapi_common_getserviceinterfacepointlist_output_sip.py
4
# coding: utf-8 from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 from tapi_server.models.base_model_ import Model from tapi_server.models.tapi_common_administrative_state import TapiCommonAdministrativeState # noqa: F401,E501 from t...
smart-make/zxing
refs/heads/master
cpp/scons/scons-local-2.0.0.final.0/SCons/Platform/posix.py
34
"""SCons.Platform.posix Platform-specific initialization for POSIX (Linux, UNIX, etc.) systems. There normally shouldn't be any need to import this module directly. It will usually be imported through the generic SCons.Platform.Platform() selection method. """ # # Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006, 2...
abaditsegay/arangodb
refs/heads/devel
3rdParty/V8-4.3.61/third_party/python_26/Lib/test/test_pep352.py
51
import unittest import __builtin__ import exceptions import warnings from test.test_support import run_unittest import os from platform import system as platform_system def ignore_message_warning(): """Ignore the DeprecationWarning for BaseException.message.""" warnings.resetwarnings() warnings.filterwarni...
raphael0202/spaCy
refs/heads/master
spacy/tests/en/test_contractions.py
4
# coding: utf-8 """Test that tokens are created correctly for contractions.""" from __future__ import unicode_literals import pytest def test_tokenizer_handles_basic_contraction(en_tokenizer): text = "don't giggle" tokens = en_tokenizer(text) assert len(tokens) == 3 assert tokens[1].text == "n't" ...