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
synconics/odoo
addons/sale/wizard/sale_line_invoice.py
222
6126
# -*- 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
leiferikb/bitpop
src/native_client/src/untrusted/crash_dump/decode_dump.py
9
6629
#!/usr/bin/python # Copyright (c) 2012 The Native Client Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """Utility to decode a crash dump generated by untrusted_crash_dump.[ch] Currently this produces a simple stack trace. """ impor...
gpl-3.0
Vagab0nd/SiCKRAGE
lib3/twilio/rest/voice/v1/dialing_permissions/country/__init__.py
1
18104
# coding=utf-8 r""" This code was generated by \ / _ _ _| _ _ | (_)\/(_)(_|\/| |(/_ v1.0.0 / / """ from twilio.base import values from twilio.base.instance_context import InstanceContext from twilio.base.instance_resource import InstanceResource from twilio.base.list_resource import ListResource f...
gpl-3.0
Farious/PersonTracker
Source/LoadImageTextPrint_sample.py
1
4907
# import numpy as np import cv2 # import linecache import LoadImagePrintText as f # >>> import os # >>> os.chdir("C:\Users\dario\Desktop\Dropbox\Work\DemoHDA\git\Source\\") ## Input cam = 60 frame = 26 debugREID = 1 img = f.loadImagePrintText(cam, frame, debugREID=0, debugPD=1, PDthreshold=20) cv2.namedWindow("1", c...
apache-2.0
michaelcontento/whirlwind
whirlwind/view/filters.py
1
6750
from datetime import datetime import pytz, sys, re, locale from dateutil import parser try: import simplejson except ImportError: import json as simplejson class Filters(): ''' Checks whether the passed in value is considered useful otherwise will return None will return None on the f...
mit
cuemacro/chartpy
chartpy_examples/subplot_example.py
1
2359
__author__ = 'saeedamen' # Saeed Amen # # Copyright 2016 Cuemacro # # 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 ...
apache-2.0
aashish24/VTK-old
Examples/ImageProcessing/Python/Contours2D.py
27
2350
#!/usr/bin/env python # This example shows how to sample a mathematical function over a # volume. A slice from the volume is then extracted and then contoured # to produce 2D contour lines. # import vtk # Quadric definition. This is a type of implicit function. Here the # coefficients to the equations are set. quadri...
bsd-3-clause
bliz937/kivy
kivy/interactive.py
25
10122
''' Interactive launcher ==================== .. versionadded:: 1.3.0 The :class:`InteractiveLauncher` provides a user-friendly python shell interface to an :class:`App` so that it can be prototyped and debugged interactively. .. note:: The Kivy API intends for some functions to only be run once or before the ...
mit
luca76/QGIS
python/plugins/processing/tests/SagaTest.py
8
5593
# -*- coding: utf-8 -*- """ *************************************************************************** SagaTest.py --------------------- Date : March 2013 Copyright : (C) 2013 by Victor Olaya Email : volayaf at gmail dot com *******************************...
gpl-2.0
muku42/bokeh
bokeh/server/views/bbauth.py
13
3281
#----------------------------------------------------------------------------- # Copyright (c) 2012 - 2015, Continuum Analytics, Inc. All rights reserved. # # Powered by the Bokeh Development Team. # # The full license is in the file LICENSE.txt, distributed with this software. #----------------------------------------...
bsd-3-clause
xxd3vin/spp-sdk
opt/Python27/Lib/email/errors.py
468
1628
# Copyright (C) 2001-2006 Python Software Foundation # Author: Barry Warsaw # Contact: email-sig@python.org """email package exception classes.""" class MessageError(Exception): """Base class for errors in the email package.""" class MessageParseError(MessageError): """Base class for message parsing erro...
mit
ssaeger/scikit-learn
sklearn/feature_extraction/stop_words.py
166
3253
# This list of English stop words is taken from the "Glasgow Information # Retrieval Group". The original list can be found at # http://ir.dcs.gla.ac.uk/resources/linguistic_utils/stop_words ENGLISH_STOP_WORDS = frozenset([ "a", "about", "above", "across", "after", "afterwards", "again", "against", "all", "almo...
bsd-3-clause
nolanliou/tensorflow
tensorflow/python/debug/cli/profile_analyzer_cli_test.py
59
17966
# Copyright 2017 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
monokrome/django-drift
setup.py
1
1462
import os import sys try: from setuptools import setup except ImportError: from . import ez_setup from setuptools import setup parent_directory = os.path.abspath(os.path.dirname(__file__)) metafiles = { 'README.md': None, 'CHANGES.md': None, 'CLASSIFIERS.txt': None, } # The following bit w...
mit
michaelBenin/geonode
geonode/security/disabled_migrations/0001_initial.py
4
9813
# encoding: utf-8 import datetime from south.db import db from south.v2 import SchemaMigration from django.db import models class Migration(SchemaMigration): def forwards(self, orm): # Adding model 'ObjectRole' db.create_table('core_objectrole', ( ('id', self.gf('django.db.mod...
gpl-3.0
Smiljanic/Esspresso-Code
testsuite/python/nonBondedInteractions.py
6
4619
# # Copyright (C) 2013,2014 The ESPResSo project # # This file is part of ESPResSo. # # ESPResSo 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 l...
gpl-3.0
valexandersaulys/prudential_insurance_kaggle
venv/lib/python2.7/site-packages/sklearn/utils/sparsetools/_graph_validation.py
364
2407
from __future__ import division, print_function, absolute_import import numpy as np from scipy.sparse import csr_matrix, isspmatrix, isspmatrix_csc from ._graph_tools import csgraph_to_dense, csgraph_from_dense,\ csgraph_masked_from_dense, csgraph_from_masked DTYPE = np.float64 def validate_graph(csgraph, direc...
gpl-2.0
shoyer/numpy
numpy/f2py/tests/test_callback.py
6
3986
from __future__ import division, absolute_import, print_function import math import textwrap import sys import pytest import numpy as np from numpy.testing import assert_, assert_equal from . import util class TestF77Callback(util.F2PyTest): code = """ subroutine t(fun,a) integer a cf2py intent(o...
bsd-3-clause
zrzka/blackmamba
blackmamba/lib/pyflakes/test/test_undefined_names.py
12
23554
from _ast import PyCF_ONLY_AST from sys import version_info from pyflakes import messages as m, checker from pyflakes.test.harness import TestCase, skipIf, skip class Test(TestCase): def test_undefined(self): self.flakes('bar', m.UndefinedName) def test_definedInListComp(self): self.flakes(...
mit
ReachingOut/unisubs
libs/vidscraper/tests/test_youtube.py
7
5791
# Copyright 2009 - Participatory Culture Foundation # # This file is part of vidscraper. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # # 1. Redistributions of source code must retain the above copyright # notic...
agpl-3.0
davidhax0r/dojme
dojme/routes.py
1
2223
from dojme import app from flask import render_template, request, redirect from urlparse import urlparse import httplib2 import re def status_check(url): """ Get the headers of a web resource to check if it exists """ h = httplib2.Http() try: resp = h.request(url, 'HEAD') if resp[0...
mit
lhfei/spark-in-action
spark-2.x/src/main/python/ml/correlation_example.py
1
1843
# # 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 n...
apache-2.0
sunqb/oa_qian
flask/Lib/site-packages/flask/debughelpers.py
777
3508
# -*- coding: utf-8 -*- """ flask.debughelpers ~~~~~~~~~~~~~~~~~~ Various helpers to make the development experience better. :copyright: (c) 2011 by Armin Ronacher. :license: BSD, see LICENSE for more details. """ from ._compat import implements_to_string class UnexpectedUnicodeError(AssertionEr...
apache-2.0
barak066/python-chardet
chardet/euckrfreq.py
323
45962
######################## 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...
lgpl-2.1
lombritz/odoo
addons/sale_stock/sale_stock.py
3
24096
# -*- 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
markhaasjes/django-registration-py3
registration/admin.py
107
1624
from django.contrib import admin from django.contrib.sites.models import RequestSite from django.contrib.sites.models import Site from django.utils.translation import ugettext_lazy as _ from registration.models import RegistrationProfile class RegistrationAdmin(admin.ModelAdmin): actions = ['activate_users', 're...
mit
kyleabeauchamp/mdtraj
mdtraj/tests/test_dtr.py
1
11033
############################################################################## # MDTraj: A Python Library for Loading, Saving, and Manipulating # Molecular Dynamics Trajectories. # Copyright 2012-2013 Stanford University and the Authors # # Authors: Robert McGibbon # Contributors: Teng Lin # # MDTraj is free so...
lgpl-2.1
nvoron23/statsmodels
statsmodels/sandbox/examples/try_multiols.py
33
1243
# -*- coding: utf-8 -*- """ Created on Sun May 26 13:23:40 2013 Author: Josef Perktold, based on Enrico Giampieri's multiOLS """ #import numpy as np import pandas as pd import statsmodels.api as sm from statsmodels.sandbox.multilinear import multiOLS, multigroup data = sm.datasets.longley.load_pandas() df = data.e...
bsd-3-clause
MatthewWilkes/django
tests/postgres_tests/models.py
231
3562
from django.db import connection, models from .fields import ( ArrayField, BigIntegerRangeField, DateRangeField, DateTimeRangeField, FloatRangeField, HStoreField, IntegerRangeField, JSONField, ) class PostgreSQLModel(models.Model): class Meta: abstract = True required_db_vendor = 'postgre...
bsd-3-clause
tanglei528/horizon
openstack_dashboard/dashboards/project/database_backups/views.py
8
3854
# vim: tabstop=4 shiftwidth=4 softtabstop=4 # # Copyright 2013 Rackspace Hosting # # 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....
apache-2.0
idjaw/horizon
openstack_dashboard/test/api_tests/heat_rest_tests.py
11
1252
# 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
kxliugang/edx-platform
common/djangoapps/student/admin.py
11
6287
""" Django admin pages for student app """ from django import forms from django.contrib.auth.models import User from ratelimitbackend import admin from xmodule.modulestore.django import modulestore from opaque_keys import InvalidKeyError from opaque_keys.edx.keys import CourseKey from config_models.admin import Config...
agpl-3.0
csitarichie/boost_msm_bare_metal
boost/tools/build/v2/test/library_property.py
20
1105
#!/usr/bin/python # Copyright 2004 Vladimir Prus # 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 the <library> property has no effect on "obj" targets. Previously, # it affected all targets, so # # project : ...
gpl-2.0
matiasherranz/keyczar
cpp/src/tools/scons/scons-local-1.2.0.d20090223/SCons/SConf.py
19
39061
"""SCons.SConf Autoconf-like configuration support. """ # # Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 The SCons Foundation # # 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 ...
apache-2.0
40223119/2015w11
static/Brython3.1.1-20150328-091302/Lib/datetime.py
628
75044
"""Concrete date/time and related types. See http://www.iana.org/time-zones/repository/tz-link.html for time zone and DST data sources. """ import time as _time import math as _math def _cmp(x, y): return 0 if x == y else 1 if x > y else -1 MINYEAR = 1 MAXYEAR = 9999 _MAXORDINAL = 3652059 # date.max.toordinal()...
gpl-3.0
datenbetrieb/odoo
addons/sale/report/invoice_report.py
336
1680
# -*- 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
sigma-random/linux-source-3.13.2-cgc
tools/perf/scripts/python/Perf-Trace-Util/lib/Perf/Trace/Core.py
11088
3246
# Core.py - Python extension for perf script, core functions # # Copyright (C) 2010 by Tom Zanussi <tzanussi@gmail.com> # # This software may be distributed under the terms of the GNU General # Public License ("GPL") version 2 as published by the Free Software # Foundation. from collections import defaultdict def aut...
gpl-2.0
crimeofheart/n7000_tw_jb_kernel
arch/ia64/scripts/unwcheck.py
13143
1714
#!/usr/bin/python # # Usage: unwcheck.py FILE # # This script checks the unwind info of each function in file FILE # and verifies that the sum of the region-lengths matches the total # length of the function. # # Based on a shell/awk script originally written by Harish Patil, # which was converted to Perl by Matthew Ch...
gpl-2.0
chaowyc/youtube-dl
youtube_dl/extractor/playvid.py
115
2864
from __future__ import unicode_literals import re from .common import InfoExtractor from ..compat import ( compat_urllib_parse_unquote, compat_urllib_parse_unquote_plus, ) from ..utils import ( clean_html, ExtractorError, ) class PlayvidIE(InfoExtractor): _VALID_URL = r'https?://www\.playvid\.co...
unlicense
mfalcon/edujango
schedule/feeds/icalendar.py
3
1197
import vobject from django.http import HttpResponse EVENT_ITEMS = ( ('uid', 'uid'), ('dtstart', 'start'), ('dtend', 'end'), ('summary', 'summary'), ('location', 'location'), ('last_modified', 'last_modified'), ('created', 'created'), ) class ICalendarFeed(object): def __call__(self, ...
apache-2.0
anryko/ansible
lib/ansible/modules/cloud/amazon/iam_policy_info.py
13
5877
#!/usr/bin/python # This file is part of Ansible # 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', 'status': ['stablein...
gpl-3.0
PongPi/isl-odoo
openerp/addons/base/ir/ir_default.py
342
1883
# -*- coding: 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...
agpl-3.0
vipul-tm/DAG
dags-ttpl/test_mod.py
1
1158
from airflow import DAG from airflow.operators import TelradExtractor from datetime import datetime, timedelta from airflow.models import Variable #from airflow.telrad_extractor_operator import TelradExtractor default_args = { 'owner': 'wireless', 'depends_on_past': False, 'start_date': datetime.now(...
bsd-3-clause
evaschalde/odoo
addons/document/content_index.py
430
6619
# -*- 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
fcrozat/telepathy-haze
tests/twisted/presence/presence.py
1
2155
""" A simple smoke-test for C.I.SimplePresence """ import dbus from twisted.words.xish import domish, xpath from twisted.words.protocols.jabber.client import IQ from servicetest import assertEquals from hazetest import exec_test import constants as cs def test(q, bus, conn, stream): amy_handle = conn.RequestHan...
gpl-2.0
dh4nav/lammps
python/examples/pizza/gl.py
34
43711
# Pizza.py toolkit, www.cs.sandia.gov/~sjplimp/pizza.html # Steve Plimpton, sjplimp@sandia.gov, Sandia National Laboratories # # Copyright (2005) Sandia Corporation. Under the terms of Contract # DE-AC04-94AL85000 with Sandia Corporation, the U.S. Government retains # certain rights in this software. This software is...
gpl-2.0
f5devcentral/f5-cccl
f5_cccl/resource/ltm/internal_data_group.py
1
3015
"""Provides a class for managing BIG-IP iRule resources.""" # coding=utf-8 # # Copyright (c) 2017-2021 F5 Networks, 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.apac...
apache-2.0
maurofaccenda/ansible
lib/ansible/modules/cloud/lxd/lxd_container.py
42
21433
#!/usr/bin/python # -*- coding: utf-8 -*- # (c) 2016, Hiroaki Nakamura <hnakamur@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...
gpl-3.0
cnexus/kernel_d2spr_tw_44
build-all.py
75
10510
#! /usr/bin/env python # Copyright (c) 2009-2011, The Linux Foundation. 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 # ...
gpl-2.0
nanolearningllc/edx-platform-cypress-2
openedx/core/djangoapps/course_groups/management/commands/tests/test_remove_users_from_multiple_cohorts.py
91
3951
""" Tests for cleanup of users which are added in multiple cohorts of a course """ from django.core.exceptions import MultipleObjectsReturned from django.core.management import call_command from django.test.client import RequestFactory from openedx.core.djangoapps.course_groups.views import cohort_handler from openedx...
agpl-3.0
adisbladis/blues
blues/wowza.py
5
1394
""" Wowza Blueprint =============== **Fabric environment:** .. code-block:: yaml blueprints: - blues.wowza """ from fabric.decorators import task from refabric.api import run, info from refabric.context_managers import sudo from refabric.contrib import blueprints from . import debian __all__ = ['start'...
mit
mortonjt/scipy
scipy/io/harwell_boeing/hb.py
23
18482
""" Implementation of Harwell-Boeing read/write. At the moment not the full Harwell-Boeing format is supported. Supported features are: - assembled, non-symmetric, real matrices - integer for pointer/indices - exponential format for float values, and int format """ from __future__ import division, print_...
bsd-3-clause
elijahrockers/DCEMRI.jl
test/q6/prep6.py
3
2599
from pylab import * from scipy.io import loadmat, savemat import time import dicom Rel = 4.5 # assumed Relaxivity of Gd-DTPA at 3 T [s^-1 [mmol Gd-DTPA]^{-1}] flip_angle = 30 * pi / 180.0 # rad TR = 5e-3 # sec nx = 80 ny = 50 nt = 1321 noise_sigma = 0.2 random_seed = 1337 seed(random_seed) dx = 1 deltat = 1 data...
mit
saketkc/ribo-seq-snakemake
configs/config_Shalgi_et_al_Cell_2013.mouse.py
1
1460
GENOMES_DIR = '/home/cmb-panasas2/skchoudh/genomes' OUT_DIR = '/staging/as/skchoudh/rna/September_2017_Shalgi_et_al_Cell_2013' SRC_DIR = '/home/cmb-panasas2/skchoudh/github_projects/clip_seq_pipeline/scripts' RAWDATA_DIR = '/home/cmb-06/as/skchoudh/dna/September_2017_Shalgi_et_al_Cell_2013/sra_single_end_mouse' GENOME_...
bsd-3-clause
yonglehou/pybrain
docs/tutorials/networks.py
25
4239
from __future__ import print_function ############################################################################ # PyBrain Tutorial "Networks, Modules, Connections" # # Author: Tom Schaul, tom@idsia.ch ############################################################################ __author__ = 'Tom Schaul, tom@idsia.c...
bsd-3-clause
BAMitUp/Fantasy-Football-Shuffler
ENV/lib/python2.7/site-packages/wheel/paths.py
565
1130
""" Installation paths. Map the .data/ subdirectory names to install paths. """ import os.path import sys import distutils.dist as dist import distutils.command.install as install def get_install_command(name): # late binding due to potential monkeypatching d = dist.Distribution({'name':name}) i = instal...
gpl-3.0
irinabov/debian-qpid-cpp-1.35.0
src/tests/qpidd_qmfv2_tests.py
3
10754
#!/usr/bin/env python # 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 # "L...
apache-2.0
Fkawala/gcloud-python
pubsub/unit_tests/test_message.py
3
4542
# Copyright 2015 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, ...
apache-2.0
rhattersley/iris-grib
lib/iris/tests/unit/fileformats/grib/save_rules/test_grid_definition_section.py
13
2147
# (C) British Crown Copyright 2014 - 2015, Met Office # # This file is part of Iris. # # Iris 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 License, or # (at your option) any l...
gpl-3.0
DigitalSlideArchive/HistomicsTK
tests/test_color_normalization.py
1
2842
#!/usr/bin/env python ############################################################################### # Copyright Kitware 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 # # ht...
apache-2.0
kanishkarj/Rave
Qt_Designer_files/playlist_design.py
1
2791
# -*- coding: utf-8 -*- # Form implementation generated from reading ui file 'playlist.ui' # # Created by: PyQt4 UI code generator 4.12.1 # # WARNING! All changes made in this file will be lost! from PyQt4 import QtCore, QtGui try: _fromUtf8 = QtCore.QString.fromUtf8 except AttributeError: def _fromUtf8(s): ...
gpl-3.0
oudalab/fajita
pythonAPI/flask/lib/python3.5/site-packages/pip/__init__.py
328
11348
#!/usr/bin/env python from __future__ import absolute_import import locale import logging import os import optparse import warnings import sys import re # 2016-06-17 barry@debian.org: urllib3 1.14 added optional support for socks, # but if invoked (i.e. imported), it will issue a warning to stderr if socks # isn't a...
mit
cirosantilli/paimei
null_selector_mem_monitor_poc.py
6
2507
#!c:\\python\\python.exe """ Null Selector Mem-Monitor Proof of Concept Copyright (C) 2007 Pedram Amini <pedram.amini@gmail.com> $Id: null_selector_mem_monitor_poc.py 214 2007-08-23 05:48:44Z pedram $ Description: Pydbg implementation of skape's null selector mem-monitor technique: http://www...
gpl-2.0
renatogames2/namebench
libnamebench/geoip.py
171
4650
# Copyright 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/LICENSE-2.0 # # Unless required by applicable law or ...
apache-2.0
jensenbox/ansible
lib/ansible/runner/action_plugins/pause.py
12
5545
# Copyright 2012, Tim Bielawa <tbielawa@redhat.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) any later...
gpl-3.0
dsajkl/reqiop
common/djangoapps/student/migrations/0020_add_test_center_user.py
188
15924
# -*- coding: utf-8 -*- import datetime from south.db import db from south.v2 import SchemaMigration from django.db import models class Migration(SchemaMigration): def forwards(self, orm): # Adding model 'TestCenterUser' db.create_table('student_testcenteruser', ( ('id', self.gf('djan...
agpl-3.0
jstoxrocky/statsmodels
statsmodels/regression/tests/generate_lme.py
34
2060
""" Generate test data sets for lme. After running this script, run lme_results.R with R to update the output. """ import numpy as np import os np.random.seed(348491) # Number of groups ngroup = 100 # Sample size range per group n_min = 1 n_max = 5 dsix = 0 # Number of random effects for pr in 1,2: re_sd = ...
bsd-3-clause
Rob2B/Cherry-enseirb
app/node_modules/node-gyp/gyp/tools/graphviz.py
2679
2878
#!/usr/bin/env python # Copyright (c) 2011 Google Inc. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """Using the JSON dumped by the dump-dependency-json generator, generate input suitable for graphviz to render a dependency graph of targets...
gpl-3.0
cginternals/openll
ll-opengl/source/tests/googletest/googletest/test/gtest_xml_output_unittest.py
1815
14580
#!/usr/bin/env python # # Copyright 2006, Google Inc. # 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 list...
mit
imadkaf/PFE
ezpublish_legacy/vendor/zetacomponents/webdav/tests/sikuli/nautilus_auth.sikuli/nautilus_noauth.py
33
8892
# coding=utf-8 setThrowException(True) class Nautilus: REMOTE = 0 LOCAL = 1 _tab = None _dirs = {} def __init__(self): self._dirs = {self.LOCAL: [], self.REMOTE: []} self._startNautilus() self._initWebdav() sleep(1) self._initLocal() def _startNautilus(self): ...
gpl-2.0
anrl/gini
backend/src/gloader/xml/sax/drivers/pylibs.py
11
3388
""" Common code for the sgmllib, htmllib and xmllib parser drivers. $Id: pylibs.py,v 1.6 2002/08/13 09:28:52 afayolle Exp $ """ from xml.sax import saxlib,saxutils import urllib2 # --- LibParser class LibParser(saxlib.Parser,saxlib.Locator): "Common code for the sgmllib, htmllib and xmllib parser drivers." ...
mit
azumimuo/family-xbmc-addon
zips/plugin.video.youtube/resources/lib/youtube/helper/url_resolver.py
24
6617
import re __author__ = 'bromix' import urlparse from resources.lib.kodion.utils import FunctionCache import resources.lib.kodion.simple_requests as requests class AbstractResolver(object): def __init__(self): pass def supports_url(self, url, url_components): raise NotImplementedError() ...
gpl-2.0
japeto/Vigtech-Services
env/lib/python2.7/site-packages/django/db/backends/utils.py
430
6689
from __future__ import unicode_literals import datetime import decimal import hashlib import logging from time import time from django.conf import settings from django.utils.encoding import force_bytes from django.utils.timezone import utc logger = logging.getLogger('django.db.backends') class CursorWrapper(object...
lgpl-3.0
SnappleCap/oh-mainline
vendor/packages/gdata/tests/all_tests_clear_cache.py
128
1057
#!/usr/bin/env python # # Copyright (C) 2009 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...
agpl-3.0
belese/luciphone
Luciphone/modules/NFCmonitor.py
1
1642
import time from py532lib.i2c import * from py532lib.frame import * from py532lib.constants import * class NFCmonitor : def __init__(self) : self.cardIn = False self.UUID = [] self.stopped = False self.cbcardin = None self.cbcardout = None #Initialise NFC_re...
gpl-2.0
opinkerfi/adagios
adagios/contrib/urls.py
3
1310
# Adagios is a web based Nagios configuration interface # # Copyright (C) 2014, Pall Sigurdsson <palli@opensource.is> # # 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...
agpl-3.0
caspyyy/SCRAPY_DDS
dynamic_scraper/migrations/0003_auto__add_logmarker__add_field_log_type.py
10
8300
# -*- coding: utf-8 -*- import datetime from south.db import db from south.v2 import SchemaMigration from django.db import models class Migration(SchemaMigration): def forwards(self, orm): # Adding model 'LogMarker' db.create_table('dynamic_scraper_logmarker', ( ('id', self.gf('django...
bsd-3-clause
dmilith/SublimeText3-dmilith
Packages/python-jinja2/all/jinja2/idtracking.py
90
9197
from jinja2.visitor import NodeVisitor from jinja2._compat import iteritems VAR_LOAD_PARAMETER = 'param' VAR_LOAD_RESOLVE = 'resolve' VAR_LOAD_ALIAS = 'alias' VAR_LOAD_UNDEFINED = 'undefined' def find_symbols(nodes, parent_symbols=None): sym = Symbols(parent=parent_symbols) visitor = FrameSymbolVisitor(sym)...
mit
Dhivyap/ansible
test/units/modules/network/check_point/test_cp_mgmt_service_group.py
19
4015
# Ansible module to manage CheckPoint Firewall (c) 2019 # # 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 dist...
gpl-3.0
halberom/ansible
lib/ansible/modules/cloud/cloudstack/cs_ip_address.py
48
7197
#!/usr/bin/python # -*- coding: utf-8 -*- # # (c) 2015, Darren Worrall <darren@iweb.co.uk> # (c) 2015, René Moser <mail@renemoser.net> # # 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 So...
gpl-3.0
v-iam/azure-sdk-for-python
azure-mgmt-recoveryservicesbackup/azure/mgmt/recoveryservicesbackup/operations/job_details_operations.py
2
4386
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for # license information. # # Code generated by Microsoft (R) AutoRest Code Generator. # Changes ...
mit
ProfessorX/Config
.PyCharm30/system/python_stubs/-1247972723/gtk/gdk/__init__/Font.py
1
1926
# encoding: utf-8 # module gtk.gdk # from /usr/lib/python2.7/dist-packages/gtk-2.0/pynotify/_pynotify.so # by generator 1.135 # no doc # imports from exceptions import Warning import gio as __gio import gobject as __gobject import gobject._gobject as __gobject__gobject import pango as __pango import pangocairo as __p...
gpl-2.0
XBMC-Addons/plugin.library.node.editor
resources/lib/orderby.py
1
8285
# coding=utf-8 import os, sys import xbmc, xbmcaddon, xbmcplugin, xbmcgui, xbmcvfs import xml.etree.ElementTree as xmltree from traceback import print_exc from urllib.parse import unquote from resources.lib.common import * class OrderByFunctions(): def __init__(self, ltype): self.ltype = ltype def _l...
gpl-2.0
vismartltd/edx-platform
common/lib/xmodule/xmodule/randomize_module.py
54
3690
import logging import random from xmodule.x_module import XModule, STUDENT_VIEW from xmodule.seq_module import SequenceDescriptor from lxml import etree from xblock.fields import Scope, Integer from xblock.fragment import Fragment log = logging.getLogger('edx.' + __name__) class RandomizeFields(object): choic...
agpl-3.0
ScottWales/rose
lib/python/rose/scheme_handler.py
1
5051
# -*- coding: utf-8 -*- #----------------------------------------------------------------------------- # (C) British Crown Copyright 2012-5 Met Office. # # This file is part of Rose, a framework for meteorological suites. # # Rose is free software: you can redistribute it and/or modify # it under the terms of the GNU G...
gpl-3.0
peterfpeterson/mantid
scripts/Interface/ui/batchwidget/batch_widget_gui.py
3
6218
# Mantid Repository : https://github.com/mantidproject/mantid # # Copyright &copy; 2018 ISIS Rutherford Appleton Laboratory UKRI, # NScD Oak Ridge National Laboratory, European Spallation Source, # Institut Laue - Langevin & CSNS, Institute of High Energy Physics, CAS # SPDX - License - Identifier: GPL - 3.0 + from...
gpl-3.0
gnperumal/exscript
src/TkExscript/__init__.py
6
1250
# Copyright (C) 2007-2010 Samuel Abels. # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License version 2, as # published by the Free Software Foundation. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANT...
gpl-2.0
hocinebendou/bika.gsoc
bika/lims/utils/analysis.py
1
12208
# -*- coding: utf-8 -*- import math import zope.event from bika.lims.utils import formatDecimalMark from Products.Archetypes.event import ObjectInitializedEvent from Products.CMFCore.WorkflowCore import WorkflowException from Products.CMFPlone.utils import _createObjectByType def create_analysis(context, service, ke...
mit
VerstandInvictus/NachIOs
ifthentrack.py
1
1181
## Hook.io Nach tracker updater. ## This takes a query with parameters of ?val=<number>&tr=<Nach tracker ID>&sec=<secret word> ## and adds a data point to the Nach tracker with ID corresponding to the "tr" param. ## It is intended to be used with IFTTT's Maker channel action but could be triggered from anywhere. ## It ...
mit
mderomph-coolblue/dd-agent
utils/dockerutil.py
7
6857
# stdlib import logging import os # 3rd party from docker import Client from docker import tls class MountException(Exception): pass # Default docker client settings DEFAULT_TIMEOUT = 5 DEFAULT_VERSION = 'auto' CHECK_NAME = 'docker_daemon' log = logging.getLogger(__name__) _docker_client_settings = {"version": ...
bsd-3-clause
kansanmuisti/datavaalit
web/political/views.py
1
6227
import json import time from django.template import RequestContext from django.shortcuts import render_to_response from social.models import * from political.models import * from political.api import * from geo.models import Municipality from django.core.urlresolvers import reverse from django.core.mail import mail_ad...
agpl-3.0
dataDogma/Computer-Science
Django-MVP-page/venv/Lib/encodings/iso8859_16.py
272
13557
""" Python Character Mapping Codec iso8859_16 generated from 'MAPPINGS/ISO8859/8859-16.TXT' with gencodec.py. """#" import codecs ### Codec APIs class Codec(codecs.Codec): def encode(self,input,errors='strict'): return codecs.charmap_encode(input,errors,encoding_table) def decode(self,input,errors...
gpl-3.0
dinowernli/bazel
third_party/py/mock/setup.py
91
2134
#! /usr/bin/env python # Copyright (C) 2007-2012 Michael Foord & the mock team # E-mail: fuzzyman AT voidspace DOT org DOT uk # http://www.voidspace.org.uk/python/mock/ from mock import __version__ import os NAME = 'mock' MODULES = ['mock'] DESCRIPTION = 'A Python Mocking and Patching Library for Testing' URL = "...
apache-2.0
Hasimir/brython
www/src/Lib/unittest/mock.py
739
71473
# mock.py # Test tools for mocking and patching. # Maintained by Michael Foord # Backport for other versions of Python available from # http://pypi.python.org/pypi/mock __all__ = ( 'Mock', 'MagicMock', 'patch', 'sentinel', 'DEFAULT', 'ANY', 'call', 'create_autospec', 'FILTER_DIR', ...
bsd-3-clause
santegoeds/bfair
bfair/_types.py
1
7481
#!/usr/bin/env python # # Copyright 2011 Tjerk Santegoeds # # 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 applicabl...
apache-2.0
ishay2b/tensorflow
tensorflow/contrib/distributions/python/ops/bijectors/softplus.py
85
1144
# 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
KaranToor/MA450
google-cloud-sdk/lib/surface/billing/accounts/projects/describe.py
6
1863
# Copyright 2016 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 ag...
apache-2.0
Memeo/samba-unovero
python/examples/dnsserver.py
46
2757
#!/usr/bin/env python # script to test the dnsserver RPC protocol import sys from optparse import OptionParser sys.path.insert(0, "bin/python") import samba import samba.getopt as options from samba.dcerpc import dnsserver, security, dnsp ########### main code ########### if __name__ == "__main__": parser = O...
gpl-3.0
sss/calibre-at-bzr
src/calibre/utils/mreplace.py
22
1173
#multiple replace from dictionnary : http://code.activestate.com/recipes/81330/ __license__ = 'GPL v3' __copyright__ = '2010, sengian <sengian1 @ gmail.com>' __docformat__ = 'restructuredtext en' import re from UserDict import UserDict class MReplace(UserDict): def __init__(self, data=None, case_sensitive=True...
gpl-3.0
deadman96385/android_kernel_leeco_msm8996
tools/perf/scripts/python/Perf-Trace-Util/lib/Perf/Trace/EventClass.py
4653
3596
# EventClass.py # # This is a library defining some events types classes, which could # be used by other scripts to analyzing the perf samples. # # Currently there are just a few classes defined for examples, # PerfEvent is the base class for all perf event sample, PebsEvent # is a HW base Intel x86 PEBS event, and use...
gpl-2.0