repo_name stringlengths 5 100 | ref stringlengths 12 67 | path stringlengths 4 244 | copies stringlengths 1 8 | content stringlengths 0 1.05M ⌀ |
|---|---|---|---|---|
usersource/anno | refs/heads/master | anno_gec_server/lib/requests/compat.py | 1038 | # -*- coding: utf-8 -*-
"""
pythoncompat
"""
from .packages import chardet
import sys
# -------
# Pythons
# -------
# Syntax sugar.
_ver = sys.version_info
#: Python 2.x?
is_py2 = (_ver[0] == 2)
#: Python 3.x?
is_py3 = (_ver[0] == 3)
try:
import simplejson as json
except (ImportError, SyntaxError):
# si... |
kurazu/bridge | refs/heads/master | setup.py | 1 | import os
from setuptools import find_packages, setup, Extension
SPIDER_MONKEY_PREFIX = os.environ.get('SPIDER_MONKEY_PREFIX', '/usr/local')
SPIDER_MONKEY_VERSION = os.environ.get('SPIDER_MONKEY_VERSION', 'mozjs-')
runjs = Extension(
'runjs',
sources=['src/runjs_sm.cpp', 'src/runjs_type.cpp', 'src/runjs_modul... |
crepererum/invenio | refs/heads/master | invenio/modules/uploader/api.py | 13 | # -*- coding: utf-8 -*-
#
# This file is part of Invenio.
# Copyright (C) 2014 CERN.
#
# Invenio is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License as
# published by the Free Software Foundation; either version 2 of the
# License, or (at your option) any later... |
Jimdo/beeswithmachineguns | refs/heads/master | setup.py | 4 | #!/usr/bin/env python
from distutils.core import setup
setup(name='beeswithmachineguns',
version='0.1.4',
description='A utility for arming (creating) many bees (micro EC2 instances) to attack (load test) targets (web applications).',
author='Christopher Groskopf',
author_email='cgroskopf@trib... |
simbs/edx-platform | refs/heads/master | common/djangoapps/geoinfo/tests/__init__.py | 12133432 | |
ammaradil/fibonacci | refs/heads/master | Lib/site-packages/django/contrib/staticfiles/management/commands/__init__.py | 12133432 | |
xflr6/fileconfig | refs/heads/master | fileconfig/tools.py | 1 | # tools.py - runtime path inspection
import inspect
import os
import sys
__all__ = ['class_path', 'caller_path']
def class_path(cls):
"""Return the path to the source file of the given class."""
if cls.__module__ == '__main__':
path = None
else:
path = os.path.dirname(inspect.getfile(cls... |
jakobwilm/pcl | refs/heads/master | geometry/include/pcl/geometry/mesh_circulators.py | 69 | ##
# Software License Agreement (BSD License)
#
# Point Cloud Library (PCL) - www.pointclouds.org
# Copyright (c) 2009-2012, Willow Garage, Inc.
# Copyright (c) 2012-, Open Perception, Inc.
#
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitt... |
GetSomeBlocks/Score_Soccer | refs/heads/master | resources/lib/mockito/mockito/__init__.py | 7 | from mockito import * |
ammaritiz/pulp_puppet | refs/heads/master | pulp_puppet_common/test/__init__.py | 12133432 | |
zzzombat/lucid-python-django | refs/heads/master | tests/regressiontests/admin_filterspecs/__init__.py | 12133432 | |
epfl-cosmo/lammps | refs/heads/master | tools/moltemplate/moltemplate/nbody_alt_symmetry/dihedrals_nosym.py | 13 | try:
from ..nbody_graph_search import Ugraph
except:
# not installed as a module
from nbody_graph_search import Ugraph
# To find 4-body "dihedral" interactions, we would use this subgraph:
#
# 1st bond connects atoms 0 and 1
# *---*---*---* => 2nd bond connects ... |
Sinkmanu/auth-system-chronos | refs/heads/master | Chronos Auth System/tools/tools/urwid/text_layout.py | 8 | #!/usr/bin/python
#
# Urwid Text Layout classes
# Copyright (C) 2004-2007 Ian Ward
#
# This library 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 2.1 of the License, o... |
fighterCui/L4ReFiascoOC | refs/heads/master | l4/pkg/python/contrib/Lib/plat-mac/appletrunner.py | 33 | #!/usr/bin/env python
# This file is meant as an executable script for running applets.
# BuildApplet will use it as the main executable in the .app bundle if
# we are not running in a framework build.
from warnings import warnpy3k
warnpy3k("In 3.x, appletrunner is removed.", stacklevel=2)
import os
import sys
for na... |
marqh/iris | refs/heads/master | lib/iris/tests/integration/plot/test_colorbar.py | 6 | # (C) British Crown Copyright 2014 - 2016, 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... |
odoousers2014/odoo | refs/heads/master | addons/web/__init__.py | 435 | import sys
# Mock deprecated openerp.addons.web.http module
import openerp.http
sys.modules['openerp.addons.web.http'] = openerp.http
http = openerp.http
import controllers
|
eefriedman/servo | refs/heads/master | tests/wpt/web-platform-tests/tools/webdriver/webdriver/keys.py | 263 | """Constants for special keys."""
class Keys:
"""Constants for special keys."""
NULL = '\uE000'
CANCEL = '\uE001'
HELP = '\uE002'
BACK_SPACE = '\uE003'
TAB = '\uE004'
CLEAR = '\uE005'
RETURN = '\uE006'
ENTER = '\uE007'
SHIFT = '\uE008'
LEFT_SHIFT = '\uE008'
CONTROL = '\u... |
rsnakamura/iperflexer | refs/heads/master | iperflexer/tests/environment.py | 3 | from distutils.util import strtobool as _bool
import os
BEHAVE_DEBUG_ON_ERROR = _bool(os.environ.get("BEHAVE_DEBUG_ON_ERROR",
"no"))
def after_step(context, step):
if BEHAVE_DEBUG_ON_ERROR and step.status == 'failed':
import pudb
pudb.post_mortem(tb=step... |
unnikrishnankgs/va | refs/heads/master | venv/lib/python3.5/site-packages/numpy/doc/creation.py | 52 | """
==============
Array Creation
==============
Introduction
============
There are 5 general mechanisms for creating arrays:
1) Conversion from other Python structures (e.g., lists, tuples)
2) Intrinsic numpy array array creation objects (e.g., arange, ones, zeros,
etc.)
3) Reading arrays from disk, either from... |
schwehr/gdal-autotest2 | refs/heads/master | python/gcore/geoloc_test.py | 1 | #!/usr/bin/env python
# Copyright 2014 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 ... |
nylas/sync-engine | refs/heads/master | inbox/test/system/conftest.py | 3 | # This file contains pytest fixtures as well as some config
import os
import platform
API_BASE = "http://%s:%s" % (os.getenv("API_PORT_5555_TCP_ADDR", "localhost"), os.getenv("API_PORT_5555_TCP_PORT", "5555"))
TEST_MAX_DURATION_SECS = 360
TEST_GRANULARITY_CHECK_SECS = 0.1
from time import time, sleep
from client impo... |
antoine-de/navitia | refs/heads/dev | source/sql/alembic/versions/11b1fb5bd523_add_boarding_and_alighting_time_to_stop_.py | 8 | """Add boarding and alighting time to stop_time
Revision ID: 11b1fb5bd523
Revises: 4429fe91ac94
Create Date: 2017-02-14 10:46:14.819580
"""
# revision identifiers, used by Alembic.
revision = '11b1fb5bd523'
down_revision = '4429fe91ac94'
from alembic import op
import sqlalchemy as sa
import geoalchemy2 as ga
def ... |
mariosky/evo-drawings | refs/heads/master | venv/lib/python2.7/site-packages/django/contrib/gis/db/backends/spatialite/introspection.py | 221 | from django.contrib.gis.gdal import OGRGeomType
from django.db.backends.sqlite3.introspection import DatabaseIntrospection, FlexibleFieldLookupDict
from django.utils import six
class GeoFlexibleFieldLookupDict(FlexibleFieldLookupDict):
"""
Sublcass that includes updates the `base_data_types_reverse` dict
f... |
timmygee/investorservitude | refs/heads/master | investorservitude/core/urls.py | 1 | from django.conf.urls import url, include
from rest_framework import routers
from rest_framework.authtoken.views import obtain_auth_token
from . import views
router = routers.DefaultRouter()
router.register(r'holdings', views.HoldingViewSet)
# Wire up our API using automatic URL routing.
# Additionally, we include l... |
jaraco/paramiko | refs/heads/master | paramiko/kex_group14.py | 6 | # Copyright (C) 2013 Torsten Landschoff <torsten@debian.org>
#
# This file is part of paramiko.
#
# Paramiko 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 2.1 of the License, or (at yo... |
svn2github/gyp | refs/heads/master | pylib/gyp/win_tool.py | 6 | #!/usr/bin/env python
# Copyright (c) 2012 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.
"""Utility functions for Windows builds.
These functions are executed via gyp-win-tool when using the ninja generator.
"""
import os
impor... |
alex/warehouse | refs/heads/master | warehouse/xml.py | 3 | # 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 Li... |
mancoast/CPythonPyc_test | refs/heads/master | cpython/221_test_sax.py | 3 | # regression test for SAX 2.0
# $Id: test_sax.py,v 1.19 2001/10/24 20:32:02 gvanrossum Exp $
from xml.sax import make_parser, ContentHandler, \
SAXException, SAXReaderNotAvailable, SAXParseException
try:
make_parser()
except SAXReaderNotAvailable:
# don't try to test this module if we canno... |
pymango/pymango | refs/heads/master | misc/python/mango/math/_rotation.py | 1 |
import scipy as sp
import numpy as np
import mango.mpi as mpi
import math
logger, rootLogger = mpi.getLoggers(__name__)
def rotation_matrix(angle, axis, dim=3, dtype="float64"):
"""
Returns rotation matrix for specified degree angle and
coordinate axis of rotation.
:type angle: :obj:`float`
... |
Ecotrust/marineplanner-core | refs/heads/master | marineplanner/core/tests.py | 24123 | from django.test import TestCase
# Create your tests here.
|
gclenaghan/scikit-learn | refs/heads/master | sklearn/grid_search.py | 4 | """
The :mod:`sklearn.grid_search` includes utilities to fine-tune the parameters
of an estimator.
"""
from __future__ import print_function
# Author: Alexandre Gramfort <alexandre.gramfort@inria.fr>,
# Gael Varoquaux <gael.varoquaux@normalesup.org>
# Andreas Mueller <amueller@ais.uni-bonn.de>
# ... |
hashems/Mobile-Cloud-Development-Projects | refs/heads/master | appengine/standard/images/api/main.py | 9 | # Copyright 2015 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 a... |
hashamali/pyScss | refs/heads/master | scss/grammar/expression.py | 3 | """Grammar for parsing Sass expressions."""
# This is a GENERATED FILE -- DO NOT EDIT DIRECTLY!
# Edit scss/grammar/expression.g, then run:
#
# python2 yapps2.py scss/grammar/expression.g
from __future__ import absolute_import
from __future__ import print_function
from __future__ import unicode_literals
from __futu... |
aspidites/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):
"""
... |
creasyw/IMTAphy | refs/heads/master | documentation/doctools/tags/0.3/sphinx/ext/autodoc.py | 2 | # -*- coding: utf-8 -*-
"""
sphinx.ext.autodoc
~~~~~~~~~~~~~~~~~~
Automatically insert docstrings for functions, classes or whole modules into
the doctree, thus avoiding duplication between docstrings and documentation
for those who like elaborate docstrings.
:copyright: 2008 by Georg Brandl.
... |
obulpathi/poppy | refs/heads/master | poppy/storage/mockdb/flavors.py | 3 | # Copyright (c) 2014 Rackspace, 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 wr... |
plotly/python-api | refs/heads/master | packages/python/plotly/plotly/validators/volume/colorbar/tickfont/__init__.py | 293 | import sys
if sys.version_info < (3, 7):
from ._size import SizeValidator
from ._family import FamilyValidator
from ._color import ColorValidator
else:
from _plotly_utils.importers import relative_import
__all__, __getattr__, __dir__ = relative_import(
__name__,
[],
["._siz... |
mickp/microscope | refs/heads/master | microscope/testsuite/deviceserver_test.py | 1 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
## Copyright (C) 2017 David Pinto <david.pinto@bioch.ox.ac.uk>
##
## This file is part of Microscope.
##
## Microscope 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 Found... |
bringingheavendown/numpy | refs/heads/master | numpy/testing/__init__.py | 11 | """Common test support for all numpy test scripts.
This single module should provide all the common functionality for numpy tests
in a single location, so that test scripts can just import it and work right
away.
"""
from __future__ import division, absolute_import, print_function
from unittest import TestCase
from... |
flyfax/huawei_metis | refs/heads/master | app/tcm/tcm_views.py | 1 | # -*- coding: utf-8 -*-
import logging
import time
from flask import request, jsonify
from app import multiauth, errHandler, models, mysqlhandler, aws_s3Handler
from . import tcm_rank
from .. import mysql
redis_logger = logging.getLogger('redis')
runMySQL = mysqlhandler.MySQLHandler(mysql)
tcmPointHandler = mysqlhan... |
mindnervestech/mnrp | refs/heads/master | addons/base_import/tests/__init__.py | 179 | from . import test_cases
checks = [test_cases]
|
oihane/odoo | refs/heads/8.0 | addons/l10n_ch/account_wizard.py | 424 | # -*- coding: utf-8 -*-
##############################################################################
#
# Author: Nicolas Bessi. Copyright Camptocamp SA
# Financial contributors: Hasa SA, Open Net SA,
# Prisme Solutions Informatique SA, Quod SA
#
# Translation contributors: brain-te... |
caioserra/apiAdwords | refs/heads/master | examples/adspygoogle/dfp/v201311/team_service/update_teams.py | 2 | #!/usr/bin/python
#
# Copyright 2013 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 b... |
akretion/multi-company | refs/heads/8.0 | __unported__/product_autocompany/__openerp__.py | 1 | # -*- encoding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2013 Savoir-faire Linux (<http://www.savoirfairelinux.com>).
#
# This program is free software: you can redistribute it and/or modify
# it un... |
aschiweck/mutt-atlassian | refs/heads/master | mutt/atlassian/scripts/__init__.py | 1 | # -*- coding: utf-8 -*-
'''
@author: Andreas Schiweck
'''
|
harlequin/sickbeard | refs/heads/master | sickbeard/image_cache.py | 27 | # Author: Nic Wolfe <nic@wolfeden.ca>
# URL: http://code.google.com/p/sickbeard/
#
# This file is part of Sick Beard.
#
# Sick Beard 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 t... |
heke123/chromium-crosswalk | refs/heads/master | third_party/WebKit/Tools/Scripts/webkitpy/layout_tests/lint_test_expectations.py | 6 | # Copyright (C) 2012 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 of conditions and the ... |
djphan/c410-Repo | refs/heads/master | c410-Lab4_5_Flask/env-lab4/lib/python2.7/site-packages/flask/app.py | 427 | # -*- coding: utf-8 -*-
"""
flask.app
~~~~~~~~~
This module implements the central WSGI application object.
:copyright: (c) 2011 by Armin Ronacher.
:license: BSD, see LICENSE for more details.
"""
import os
import sys
from threading import Lock
from datetime import timedelta
from itertools import... |
SambitAcharya/coala | refs/heads/master | bears/coffee_script/__init__.py | 12133432 | |
burzillibus/RobHome | refs/heads/master | venv/lib/python2.7/site-packages/django/conf/locale/nb/__init__.py | 12133432 | |
kharkevich/molecule | refs/heads/master | test/functional/__init__.py | 12133432 | |
hashems/Mobile-Cloud-Development-Projects | refs/heads/master | appengine/flexible/static_files/main_test.py | 9 | # Copyright 2015 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 a... |
remap/ndn-flow | refs/heads/master | framework/ndn_iot_js/.waf-1.7.9-ce9b2a6d663b32d9a89df143dad45f99/waflib/Tools/intltool.py | 330 | #! /usr/bin/env python
# encoding: utf-8
# WARNING! Do not edit! http://waf.googlecode.com/git/docs/wafbook/single.html#_obtaining_the_waf_file
import os,re
from waflib import Configure,TaskGen,Task,Utils,Runner,Options,Build,Logs
import waflib.Tools.ccroot
from waflib.TaskGen import feature,before_method
from waflib.... |
wfxiang08/django185 | refs/heads/master | django/core/cache/backends/locmem.py | 586 | "Thread-safe in-memory cache backend."
import time
from contextlib import contextmanager
from django.core.cache.backends.base import DEFAULT_TIMEOUT, BaseCache
from django.utils.synch import RWLock
try:
from django.utils.six.moves import cPickle as pickle
except ImportError:
import pickle
# Global in-memor... |
omprakasha/odoo | refs/heads/8.0 | addons/website_blog/controllers/__init__.py | 7372 | import main
|
mehdisadeghi/saga-python | refs/heads/master | tests/adaptors/irods/irods_test.py | 5 | #!/usr/bin/env python2.4
# -*- coding: utf-8 -*-
'''This example runs some iRODS commands
If something doesn't work as expected, try to set
SAGA_VERBOSE=3 in your environment before you run the
script in order to get some debug output.
If you think you have encountered a defect, please
report it at... |
JavML/django | refs/heads/master | tests/serializers/tests.py | 61 | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
import importlib
import json
import re
import unittest
from datetime import datetime
from xml.dom import minidom
from django.core import management, serializers
from django.core.serializers.base import ProgressBar
from django.db import connection, transa... |
aduric/crossfit | refs/heads/master | nonrel/django/utils/formats.py | 159 | import decimal
import datetime
from django.conf import settings
from django.utils.translation import get_language, to_locale, check_for_language
from django.utils.importlib import import_module
from django.utils.encoding import smart_str
from django.utils import dateformat, numberformat, datetime_safe
from django.util... |
sm0svx/asciidoc | refs/heads/master | filters/graphviz/graphviz2png.py | 29 | #!/usr/bin/env python
import os, sys, subprocess
from optparse import *
__AUTHOR__ = "Gouichi Iisaka <iisaka51@gmail.com>"
__VERSION__ = '1.1.4'
class EApp(Exception):
'''Application specific exception.'''
pass
class Application():
'''
NAME
graphviz2png - Converts textual graphviz notation to PNG fi... |
vicky2135/lucious | refs/heads/master | oscar/lib/python2.7/site-packages/IPython/utils/tz.py | 42 | # encoding: utf-8
"""
Timezone utilities
Just UTC-awareness right now
"""
#-----------------------------------------------------------------------------
# Copyright (C) 2013 The IPython Development Team
#
# Distributed under the terms of the BSD License. The full license is in
# the file COPYING, distributed as p... |
esmoyon1/GeonodeV1 | refs/heads/Branch1 | geonode/base/migrations/26_to_27.py | 3 | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('base', '24_to_26'),
]
operations = [
migrations.AlterField(
model_name='resourcebase',
name='tkeywor... |
jjlee3/openthread | refs/heads/master | tools/harness-automation/cases/leader_5_6_5.py | 16 | #!/usr/bin/env python
#
# Copyright (c) 2016, The OpenThread Authors.
# All rights reserved.
#
# 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... |
damirda/ansible-modules-core | refs/heads/devel | cloud/azure/azure_rm_securitygroup.py | 46 | #!/usr/bin/python
#
# Copyright (c) 2016 Matt Davis, <mdavis@ansible.com>
# Chris Houseknecht, <house@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 Soft... |
edxnercel/edx-platform | refs/heads/master | lms/djangoapps/instructor_analytics/tests/__init__.py | 12133432 | |
tjlaboss/openmc | refs/heads/develop | tests/regression_tests/energy_grid/__init__.py | 12133432 | |
lipis/hurry-app | refs/heads/master | main/lib/wtforms/ext/__init__.py | 12133432 | |
mjirayu/sit_academy | refs/heads/master | lms/djangoapps/ccx/plugins.py | 110 | """
Registers the CCX feature for the edX platform.
"""
from django.conf import settings
from django.utils.translation import ugettext_noop
from xmodule.tabs import CourseTab
from student.roles import CourseCcxCoachRole
class CcxCourseTab(CourseTab):
"""
The representation of the CCX course tab
"""
... |
jamesblunt/sublime-evernote | refs/heads/master | lib/pygments/styles/vim.py | 135 | # -*- coding: utf-8 -*-
"""
pygments.styles.vim
~~~~~~~~~~~~~~~~~~~
A highlighting style for Pygments, inspired by vim.
:copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS.
:license: BSD, see LICENSE for details.
"""
from pygments.style import Style
from pygments.token import Keywor... |
marshallmcdonnell/interactive_plotting | refs/heads/master | TraitsUI/matplotlib/demo_group_size_matplotlib.py | 1 | """
Control the height and width of a Group
TraitsUI does not permit explicit specification of the height or width of a
Group (or its descendants). The workaround is to put each Group whose size you
wish to control into its own View class, which can be an Item (hence can be
size-controlled) in the larger View. Sometim... |
benjschiller/seriesoftubes | refs/heads/master | scripts/subtract_bam.py | 1 | #!/usr/bin/env python
'''
subtracts BAM (or SAM) files based on sequence names
(for example, use to remove reads that also map rRNA)
outputs to alignments_filtered.BAM
by default, looks in alignments.BAM for .bam files
and expects corresponding files in mapped/alignments.BAM
ignores the species folder name i.e. mappe... |
fedesanchez/suite-3.1 | refs/heads/master | geoexplorer/app/static/externals/proj4js/tools/pjjs.py | 250 | #!/usr/bin/env python
#
# TODO explain
#
# -- Copyright 2007 IGN France / Geoportail project --
#
import sys
import os
import re
SUFFIX_JAVASCRIPT = ".js"
def _pjcat2js_remove(rezDirectory,catName,targetDirectory):
pjCatFilename = os.path.join(rezDirectory, catName)
pjCat = open(pjCatFilename,'r')
commen... |
openprocurement/openprocurement.auctions.flash | refs/heads/master | openprocurement/auctions/flash/tests/__init__.py | 12133432 | |
webgeodatavore/django | refs/heads/master | tests/sitemaps_tests/__init__.py | 12133432 | |
arju88nair/projectCulminate | refs/heads/master | venv/lib/python3.5/site-packages/pymongo/ssl_match_hostname.py | 21 | # Backport of the match_hostname logic from python 3.5, with small
# changes to support IP address matching on python 2.6, 2.7, 3.3, and 3.4.
import re
import sys
try:
# Python 3.3+, or the ipaddress module from pypi.
from ipaddress import ip_address
except ImportError:
ip_address = lambda address: None
... |
OSSESAC/odoopubarquiluz | refs/heads/7.0 | addons/crm_claim/__init__.py | 53 | # -*- 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... |
phoebusliang/parallel-lettuce | refs/heads/master | tests/integration/lib/Django-1.2.5/tests/regressiontests/extra_regress/__init__.py | 12133432 | |
vladryk/horizon | refs/heads/master | openstack_dashboard/management/__init__.py | 12133432 | |
kenshay/ImageScript | refs/heads/master | ProgramData/SystemFiles/Python/Lib/site-packages/django/template/loaders/__init__.py | 12133432 | |
hotpoor-for-Liwei/hj_hackathon_201607 | refs/heads/master | tornado/platform/__init__.py | 12133432 | |
yoer/hue | refs/heads/master | desktop/core/ext-py/Django-1.6.10/tests/app_loading/models.py | 12133432 | |
mohamedhagag/community-addons | refs/heads/8.0 | price_security/__init__.py | 119 | # -*- coding: utf-8 -*-
##############################################################################
# For copyright and license notices, see __openerp__.py file in module root
# directory
##############################################################################
from . import models
|
menardorama/ReadyNAS-Add-ons | refs/heads/master | headphones-1.0.0/files/apps/headphones/lib/mutagen/_tags.py | 31 | # Copyright (C) 2005 Michael Urman
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of version 2 of the GNU General Public License as
# published by the Free Software Foundation.
class Metadata(object):
"""An abstract dict-like object.
Metadata is the base class ... |
apixandru/intellij-community | refs/heads/master | python/testData/copyPaste/Indent2.dst.py | 83 | def bar():
<caret>
var = "string" |
dkillick/iris | refs/heads/master | lib/iris/tests/integration/plot/test_colorbar.py | 6 | # (C) British Crown Copyright 2014 - 2016, 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... |
richardcs/ansible | refs/heads/devel | lib/ansible/modules/network/eos/eos_l2_interface.py | 30 | #!/usr/bin/python
# -*- coding: utf-8 -*-
# (c) 2017, Ansible by Red Hat, 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_version': '1.1',
... |
vipul-sharma20/oh-mainline | refs/heads/master | vendor/packages/python-social-auth/social/tests/models.py | 34 | import base64
from social.storage.base import UserMixin, NonceMixin, AssociationMixin, \
CodeMixin, BaseStorage
class BaseModel(object):
@classmethod
def next_id(cls):
cls.NEXT_ID += 1
return cls.NEXT_ID - 1
@classmethod
def get(cls, key):
retu... |
juselius/hindarot | refs/heads/master | config/mkdep90.py | 1 | #!/usr/bin/env python
#
# $Id$
#
import sys, string, re
use=re.compile('\s*use\s+(\w+)', re.I)
mod=re.compile('\s*module(?!\s+procedure)\s+(\w+)', re.I)
class depfile:
def __init__(self, name):
self.name=name
self.oname=name[:-3]+'o'
self.uses={}
def adduses(self, u):
self.uses[u]=''
def main():
allm... |
StrellaGroup/frappe | refs/heads/develop | frappe/contacts/doctype/address_template/address_template.py | 17 | # -*- coding: utf-8 -*-
# Copyright (c) 2015, Frappe Technologies and contributors
# For license information, please see license.txt
from __future__ import unicode_literals
import frappe
from frappe.model.document import Document
from frappe.utils.jinja import validate_template
from frappe import _
class AddressTempl... |
endlessm/chromium-browser | refs/heads/master | third_party/angle/third_party/glmark2/src/waflib/Task.py | 4 | #! /usr/bin/env python
# encoding: utf-8
# WARNING! Do not edit! https://waf.io/book/index.html#_obtaining_the_waf_file
import os,re,sys,tempfile
from waflib import Utils,Logs,Errors
NOT_RUN=0
MISSING=1
CRASHED=2
EXCEPTION=3
SKIPPED=8
SUCCESS=9
ASK_LATER=-1
SKIP_ME=-2
RUN_ME=-3
COMPILE_TEMPLATE_SHELL='''
def f(tsk):
... |
iCarto/siga | refs/heads/master | extScripting/scripts/jython/Lib/xml/dom/Entity.py | 3 | ########################################################################
#
# File Name: Entity.py
#
# Documentation: http://docs.4suite.com/4DOM/Entity.py.html
#
"""
Implementation of DOM Level 2 Entity interface
WWW: http://4suite.com/4DOM e-mail: support@4suite.com
Copyright (c) 2000 Fourth... |
drglove/SickRage | refs/heads/master | lib/requests/packages/urllib3/util/retry.py | 699 | import time
import logging
from ..exceptions import (
ConnectTimeoutError,
MaxRetryError,
ProtocolError,
ReadTimeoutError,
ResponseError,
)
from ..packages import six
log = logging.getLogger(__name__)
class Retry(object):
""" Retry configuration.
Each retry attempt will create a new Re... |
edhuckle/statsmodels | refs/heads/master | statsmodels/nonparametric/_kernel_base.py | 29 | """
Module containing the base object for multivariate kernel density and
regression, plus some utilities.
"""
from statsmodels.compat.python import range, string_types
import copy
import numpy as np
from scipy import optimize
from scipy.stats.mstats import mquantiles
try:
import joblib
has_joblib = True
exce... |
tedelhourani/ansible | refs/heads/devel | lib/ansible/modules/cloud/azure/azure_rm_functionapp_facts.py | 44 | #!/usr/bin/python
#
# Copyright (c) 2016 Thomas Stringer, <tomstr@microsoft.com>
# 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',
... |
chongtianfeiyu/kbengine | refs/heads/master | kbe/res/scripts/common/Lib/ctypes/test/__init__.py | 101 | import os
import unittest
from test import support
# skip tests if _ctypes was not built
ctypes = support.import_module('ctypes')
ctypes_symbols = dir(ctypes)
def need_symbol(name):
return unittest.skipUnless(name in ctypes_symbols,
'{!r} is required'.format(name))
def load_tests(*... |
jaysonsantos/servo | refs/heads/master | tests/wpt/css-tests/tools/manifest/vcs.py | 287 | import os
import subprocess
def get_git_func(repo_path):
def git(cmd, *args):
full_cmd = ["git", cmd] + list(args)
return subprocess.check_output(full_cmd, cwd=repo_path, stderr=subprocess.STDOUT)
return git
def is_git_repo(tests_root):
return os.path.exists(os.path.join(tests_root, ".git... |
Canpio/Paddle | refs/heads/develop | python/paddle/fluid/tests/unittests/test_recordio_reader.py | 3 | # Copyright (c) 2018 PaddlePaddle 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 app... |
antotodd/project2 | refs/heads/master | lib/flask/testsuite/test_apps/path/installed_package/__init__.py | 1799 | import flask
app = flask.Flask(__name__)
|
jdcc2/campussearch | refs/heads/master | venv/lib/python3.4/site-packages/pip/_vendor/requests/packages/chardet/chardistribution.py | 2754 | ######################## 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... |
utecuy/edx-platform | refs/heads/master | openedx/core/lib/logsettings.py | 127 | """Get log settings."""
import os
import platform
import sys
from logging.handlers import SysLogHandler
LOG_LEVELS = ['DEBUG', 'INFO', 'WARNING', 'ERROR', 'CRITICAL']
def get_logger_config(log_dir,
logging_env="no_env",
tracking_filename="tracking.log",
... |
lz1988/django-web | refs/heads/master | build/lib/django/contrib/staticfiles/handlers.py | 106 | try:
from urllib.parse import urlparse
from urllib.request import url2pathname
except ImportError: # Python 2
from urllib import url2pathname
from urlparse import urlparse
from django.conf import settings
from django.core.handlers.base import get_path_info
from django.core.handlers.wsgi import WSGI... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.