gt
stringclasses
1 value
context
stringlengths
2.49k
119k
""" Disjoint set data structure """ import collections class DisjointSet: """ Disjoint set data structure for incremental connectivity queries. .. versionadded: 1.6.0 Attributes ---------- n_subsets : int The number of subsets. Methods ------- add merge connected ...
# Natural Language Toolkit: Shift-Reduce Parser # # Copyright (C) 2001-2012 NLTK Project # Author: Edward Loper <edloper@gradient.cis.upenn.edu> # Steven Bird <sb@csse.unimelb.edu.au> # URL: <http://www.nltk.org/> # For license information, see LICENSE.TXT from nltk.grammar import Nonterminal from nltk.tree im...
#! /usr/bin/env python # -*- coding: utf-8 -*- """Creates ERTs and convergence figures for multiple algorithms.""" from __future__ import absolute_import import os import matplotlib.pyplot as plt import numpy from pdb import set_trace from .. import toolsdivers, toolsstats, bestalg, pproc, genericsettings, htmldesc, p...
"""The tests for the Proximity component.""" import unittest from homeassistant.components import proximity from homeassistant.components.proximity import DOMAIN from homeassistant.bootstrap import setup_component from tests.common import get_test_home_assistant class TestProximity(unittest.TestCase): """Test t...
#!/usr/bin/env python # -*- coding: utf-8 -*- import logging import datetime import random from flask import url_for, current_app, redirect, request from flask.ext.mistune import markdown from quokka.core import TEXT_FORMATS from quokka.core.db import db from quokka.core.fields import MultipleObjectsReturned from quo...
# Copyright (c) 2014 NetApp, Inc. All rights reserved. # Copyright (c) 2014 Navneet Singh. 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://w...
""" Written by Matthew Cook Created August 9, 2016 mattheworion.cook@gmail.com Script to do basic sytax conversion between R and Python 3 syntax. What it does convert: -assignment operator -function definitions -filename -'{' to ':' -'!' to 'not' -if statments -remove ';' line endings What i...
# Copyright 2020 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...
from __future__ import print_function import functools import numpy import cupy from cupy import internal from cupy.testing import array def numpy_cupy_allclose(rtol=1e-7, atol=0, err_msg='', verbose=True, name='xp', type_check=True): def decorator(impl): @functools.wraps(impl) ...
# # 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...
# 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...
# coding: utf-8 from __future__ import unicode_literals from collections import Iterable from time import time from django.db.backends.utils import CursorWrapper from django.db.models.query import EmptyResultSet from django.db.models.signals import post_migrate from django.db.models.sql.compiler import ( SQLCompi...
#!/usr/bin/env python """ Common utility functions """ import os import re import sys import gzip import bz2 import numpy def init_gene(): """ Initializing the gene structure """ gene_det = [('id', 'f8'), ('anno_id', numpy.dtype), ('confgenes_id', numpy.dtype), ...
"""Component to manage a shopping list.""" import asyncio import logging import uuid import voluptuous as vol from homeassistant.const import HTTP_NOT_FOUND, HTTP_BAD_REQUEST from homeassistant.core import callback from homeassistant.components import http from homeassistant.components.http.data_validator import ( ...
import math import numpy as np def angle_finder(grid, dn, cn, rn): xcoord = grid.node_axis_coordinates(axis=0) ycoord = grid.node_axis_coordinates(axis=1) sl1 = (ycoord[cn] - ycoord[dn]) / (xcoord[cn] - xcoord[dn]) sl2 = (ycoord[rn] - ycoord[cn]) / (xcoord[rn] - xcoord[cn]) angle1 = math.degrees(...
""" Some utility functions used by chronometer. """ import os import numpy as np import pandas as pd from isochrones import StarModel from isochrones.mist import MIST_Isochrone import h5py def get_n_things(mods, params): """ Figure out number of stars, number of global params, etc. """ N, nind = len(...
import pandas import numpy as np import scipy import statsmodels.api as sm import traceback import logging from time import time from msgpack import unpackb, packb from redis import StrictRedis from settings import ( ALGORITHMS, CONSENSUS, FULL_DURATION, MAX_TOLERABLE_BOREDOM, MIN_TOLERABLE_LENGTH,...
from collections import ( abc, deque, ) from decimal import Decimal from warnings import catch_warnings import numpy as np import pytest import pandas as pd from pandas import ( DataFrame, Index, MultiIndex, PeriodIndex, Series, concat, date_range, ) import pandas._testing as tm fr...
""" Basic functions for manipulating 2d arrays """ __all__ = ['diag','diagflat','eye','fliplr','flipud','rot90','tri','triu', 'tril','vander','histogram2d'] from numpy.core.numeric import asanyarray, equal, subtract, arange, \ zeros, greater_equal, multiply, ones, asarray def fliplr(m): """ ...
import time import threading import uuid from nose.tools import eq_ from nose.tools import raises from kazoo.exceptions import KazooException from kazoo.protocol.states import EventType from kazoo.testing import KazooTestCase class KazooDataWatcherTests(KazooTestCase): def setUp(self): super(KazooDataWa...
# 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 may ...
#!/usr/bin/python # # Copyright (c) 2011 The Bitcoin developers # Distributed under the MIT/X11 software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. # import time import json import pprint import hashlib import struct import re import base64 import httplib import...
# # Copyright (c) 2009-2017, Novartis Institutes for BioMedical Research 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 cop...
# Copyright 2014 - Rackspace # # 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, ...
import re from datetime import datetime from email.utils import formataddr from html import unescape from django.conf import settings from django.forms import ValidationError from django.template import loader from django.urls import reverse from django.utils import translation import waffle from email_reply_parser...
# Copyright IBM Corp. 2016 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...
# GloVe model from the NLP lab at Stanford: # http://nlp.stanford.edu/projects/glove/. import collections try: # Python 2 compat import cPickle as pickle except ImportError: import pickle import numpy as np import scipy.sparse as sp from .glove_cython import fit_vectors, transform_paragraph class Glove...
# Authors: Alexandre Gramfort <alexandre.gramfort@inria.fr> # Mathieu Blondel <mathieu@mblondel.org> # Olivier Grisel <olivier.grisel@ensta.org> # Andreas Mueller <amueller@ais.uni-bonn.de> # Joel Nothman <joel.nothman@gmail.com> # Hamzeh Alsalhi <ha258@cornell.edu> # Licens...
#!/usr/bin/env python """This tool builds or repacks the client binaries.""" from __future__ import absolute_import from __future__ import division from __future__ import print_function from __future__ import unicode_literals import getpass import glob import logging import multiprocessing import os import platform im...
# Copyright (c) 2012 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """Base class for generating wrapper functions for PPAPI methods. """ from datetime import datetime import os import sys from idl_c_proto import CGen f...
from django.utils.translation import ugettext_lazy as _, ugettext_noop from custom.succeed.utils import CONFIG from dimagi.utils.parsing import ISO_DATE_FORMAT PM1 = 'http://openrosa.org/formdesigner/111B09EB-DFFA-4613-9A16-A19BA6ED7D04' PM2 = 'http://openrosa.org/formdesigner/4B52ADB2-AA79-4056-A13E-BB34871876A1' PM_...
""" All logic concerning ES-HyperNEAT resides here. """ import copy import neat import numpy as np from pureples.hyperneat.hyperneat import query_cppn from pureples.shared.visualize import draw_es class ESNetwork: """ The evolvable substrate network. """ def __init__(self, substrate, cppn, params): ...
import urllib.request from tkinter import * numSchedules = 0 def processTime(courseClass, courseName): timeString = courseClass[2] dayString = timeString[:3] # gets day from timeString timeString = timeString[timeString.find(":")-2:] beginString = timeString[:5] #gets begining of class timeString ...
from pandac.PandaModules import * from direct.fsm.FSM import FSM from direct.interval.IntervalGlobal import * from direct.distributed.DistributedObject import DistributedObject class Fixture(NodePath, FSM): def __init__(self, id, parent, pos, hpr, fov): NodePath.__init__(self, 'cam-%s' % id) FSM._...
"""Generative Adversarial Network. Creative Applications of Deep Learning w/ Tensorflow. Kadenze, Inc. Copyright Parag K. Mital, June 2016. """ import tensorflow as tf import numpy as np import matplotlib.pyplot as plt import os import libs.batch_norm as bn from libs.utils import * def encoder(x, phase_train, dimens...
# IDLSave - a python module to read IDL 'save' files # Copyright (c) 2010 Thomas P. Robitaille # Many thanks to Craig Markwardt for publishing the Unofficial Format # Specification for IDL .sav files, without which this Python module would not # exist (http://cow.physics.wisc.edu/~craigm/idl/savefmt). # This code was...
# This file is automatically created, never edit it directly. from wrapper import deepy_tensor, deepy_nnet def absolute_import(*args, **kwargs): return deepy_nnet.absolute_import(*args, **kwargs) def abstract_conv(*args, **kwargs): return deepy_nnet.abstract_conv(*args, **kwargs) def abstrac...
# -*- coding: utf-8 -*- from operator import attrgetter from pyangbind.lib.yangtypes import RestrictedPrecisionDecimalType from pyangbind.lib.yangtypes import RestrictedClassType from pyangbind.lib.yangtypes import TypedListType from pyangbind.lib.yangtypes import YANGBool from pyangbind.lib.yangtypes import YANGListTy...
#!/usr/bin/env python #MIT License #Copyright (c) 2017 Massimiliano Patacchiola # #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 #t...
"""This module reports and handles subsequences of a fixed length (words, k-mers) in biological sequences. The word patterns are stored in the class `Pattern` that provides information about positions of the words in full-length sequences and number of times the particular word appears in each sequence. Word pattern ...
''' Created on 02/11/2015 @author: ''' import httplib import os import urlparse import subprocess import time from common.test_bed import TBTestBed from common.project import TBProject from common.node import TBTestNode from common.suite import TBTestSuite from common.smart_suite import TBSmartTestSuite from commo...
__author__ = 'Erik' import pygame import os from pygame import * from PlayerWeapons import * class Drawable: def draw(self): pass class PlayerSpaceShip(Drawable, pygame.sprite.Sprite): max_left_acceleration = -20 max_right_acceleration = 20 max_up_acceleration = -20 max_down_accelerat...
# Copyright 2018 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...
# coding=utf-8 # Copyright 2022 The Google Research Authors. # # 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 applicab...
# # 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 by applicable law ...
## Copyright (c) 2010, Coptix, Inc. All rights reserved. ## See the LICENSE file for license terms and warranty disclaimer. """features -- XMPP stream features""" from __future__ import absolute_import import sasl, weakref, random, hashlib, base64 from . import plugin, xml, interfaces as i from .prelude import * __...
#!/usr/bin/env python """ Name : docs/apigen.py Created : Apr 19, 2017 Author : Will Pittman Contact : willjpittman@gmail.com ________________________________________________________________________________ Description : Alternative to `sphinx-apidoc`, that walks sourcetree, ...
#!/usr/bin/python # # SAVI Portal to take GENI certs and create SAVI users from them # # Use Flask as the REST server # from flask import Flask, request, render_template # # Crypto libraries to read the certs. OpenSSL.crypto has a richer interface # but M2Crypto.X509 has simpler verification, whch is what we use now #...
import builtins import contextlib import copy import gc import pickle from random import randrange, shuffle import struct import sys import unittest import weakref from collections.abc import MutableMapping from test import mapping_tests, support py_coll = support.import_fresh_module('collections', blocked=['_collect...
from datetime import date, datetime from django.template.defaultfilters import slugify from mock import patch from rapidsms.contrib.locations.models import Location, LocationType from survey.models import Batch, Investigator, Household, Question, Backend, Survey, HouseholdMemberBatchCompletion, EnumerationArea from sur...
#!/usr/bin/env python # encoding: utf-8 import cmd import json import os import pipes import shlex import sys from tabulate import tabulate import talus_client.utils as utils from talus_client.utils import Colors from talus_client.models import * from talus_client.cmds import TalusCmdBase def nice_string(val): if i...
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not u...
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not u...
# 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 a...
# Copyright 2013 OpenStack Foundation. # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless req...
# Copyright 2013 IBM Corp. # # 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...
""" Tests outwardly observable behaviour of fields This test suite attempts to cover the interactions between several orthogonal attributes that affect the behaviour of xblock fields. 1) Whether the field is mutable or immutable 2) Whether the field is in one of 3 different states a) The field has no stored value...
# -*- coding: utf-8 -*- ''' This package contains the loader modules for the salt streams system ''' # Import Python libs from __future__ import absolute_import import logging import copy import re # Import Salt libs import salt.loader import salt.utils import salt.utils.minion log = logging.getLogger(__name__) cla...
# Copyright 2017 Battelle Energy Alliance, LLC # # 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 t...
from django.contrib.auth.decorators import user_passes_test from django.contrib.auth.mixins import UserPassesTestMixin from django.core.exceptions import PermissionDenied class IsHackerMixin(UserPassesTestMixin): raise_exception = True def test_func(self): if not self.request.user.is_authenticated: ...
# -------------------------------------------------------- # Deformable Convolutional Networks # Copyright (c) 2017 Microsoft # Licensed under The MIT License [see LICENSE for details] # Written by Zheng Zhang # -------------------------------------------------------- import cPickle import os import cv2 import numpy a...
# -*- coding: utf-8 -*- """ Jinja template utilties """ from datetime import datetime, date import itertools import os import re import sys from urllib import quote, unquote from hyde.exceptions import HydeException from hyde.model import Expando from hyde.template import HtmlWrap, Template from operator import attrg...
# !/usr/bin/env python import sys sys.path.append('/opt/lib/python2.7/site-packages/') import math import numpy as np import pylab import nest import nest.raster_plot import nest.topology as tp import logging as log from network_params import * from sim_params import * from user_params import * # Implementation of ...
# Copyright (C) 2018 Henrique Pereira Coutada Miranda # All rights reserved. # # This file is part of yambopy # """ This file contains classes and methods to generate input files The FiniteDifferencesPhononFlow """ from qepy.pw import PwIn from qepy.ph import PhIn from qepy.pwxml import PwXML from qepy.lattice import...
from .Exporter import Exporter from ..python2_3 import asUnicode from ..parametertree import Parameter from ..Qt import QtGui, QtCore, QtSvg from .. import debug from .. import functions as fn import re import xml.dom.minidom as xml import numpy as np __all__ = ['SVGExporter'] class SVGExporter(Exporter): Name =...
# -*- coding: utf-8 -*- """ HMS Hospital Status Assessment and Request Management System """ if not settings.has_module(c): raise HTTP(404, body="Module disabled: %s" % c) # ----------------------------------------------------------------------------- #def s3_menu_postp(): # # @todo: rewrite this for new ...
# Copyright (c) 2014 OpenStack Foundation # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to ...
# # Licensed to the Apache Software Foundation (ASF) under one or more # contributor license agreements. See the NOTICE file distributed with # this work for additional information regarding copyright ownership. # The ASF licenses this file to You under the Apache License, Version 2.0 # (the "License"); you may not us...
""" Process seismic waveform data in win32 format. """ import glob import logging import math import os import subprocess import tempfile from fnmatch import fnmatch from multiprocessing import Pool from subprocess import DEVNULL, PIPE, Popen # Setup the logger FORMAT = "[%(asctime)s] %(levelname)s: %(message)s" loggi...
""" Unit tests for the Task class """ import sys if sys.version_info > (3,): long = int from gbdxtools.simpleworkflows import Task, Workflow, InvalidInputPort, WorkflowError from gbdxtools.workflow import Workflow as WorkflowAPI from auth_mock import get_mock_gbdx_session from gbdxtools import Interface import vcr...
import collections import contextlib import blinker import blinker._saferef import pprint import copy import functools import os import typing import textwrap import ruamel.yaml from mitmproxy import exceptions from mitmproxy.utils import typecheck """ The base implementation for Options. """ unset = object() ...
# 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...
import sys import os import pickle import tarfile import theano import numpy as np from scipy.ndimage import convolve try: from sklearn import datasets from sklearn.cross_validation import train_test_split except ImportError: print "Warning: Couldn't load scikit-learn" # ----------------------------------------...
# -*- coding: utf-8 -*- # # 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 ...
#!/usr/bin/env python # -*- coding: utf-8 -*- from __future__ import division from django.conf import settings from django.core.exceptions import ObjectDoesNotExist from django.utils.timezone import localtime from ballot_box.models import * from election_registrar.models import * from ballot_box.utils_data import Fram...
import unittest from stream_framework.storage.redis.structures.hash import RedisHashCache, \ ShardedHashCache, FallbackHashCache from stream_framework.storage.redis.structures.list import RedisListCache, \ FallbackRedisListCache from stream_framework.storage.redis.connection import get_redis_connection from fun...
#!/usr/bin/env python3 # # Copyright (c) 2015-2017 Nest Labs, 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/lic...
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # pygeoutil documentation build configuration file, created by # sphinx-quickstart on Tue Apr 14 10:29:06 2015. # # This file is execfile()d with the current directory set to its # containing dir. # # Note that not all possible configuration values are present in this # ...
import abc from datetime import datetime import os.path import threading import zipfile from Quality.AtomicComputation.cp_qoi_system import CpQoiSystem from virtualisation.annotation.observationidgenerator import ObservationIDGenerator from virtualisation.misc.jsonobject import JSONObject from virtualisation.misc.log ...
# -*- coding: utf-8 -*- """ SolveBio Python Client ~~~~~~~~~~~~~~~~~~~~~~ This is the Python client & library for the SolveBio API. Have questions or comments? email us at: support@solvebio.com """ from __future__ import absolute_import from __future__ import print_function __docformat__ = 'restructuredtext' import ...
# Copyright (c) 2015 OpenStack Foundation # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable ...
## # Copyright (c) 2005-2014 Apple 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 l...
from datetime import datetime import hashlib from werkzeug.security import generate_password_hash, check_password_hash from itsdangerous import TimedJSONWebSignatureSerializer as Serializer from markdown import markdown import bleach from flask import current_app, request, url_for from flask.ext.login import UserMixin,...
import re from collections import OrderedDict from itertools import zip_longest from string import Template from typing import List, Optional, Union from packaging.version import Version from commitizen.defaults import MAJOR, MINOR, PATCH, bump_message from commitizen.exceptions import CurrentVersionNotFoundError fro...
# Bacteria, a program to test natural selection on cybernetic bacteria # License: MIT # Author: Stefano Borini # Website : http://forthescience.org import copy import random import sys def floatrange(start, stop, n_intervals): diff = stop - start for i in xrange(n_intervals+1): yield start + (i*diff)/...
"""Base class for sparse matrix formats using compressed storage.""" __all__ = [] from warnings import warn import operator import numpy as np from scipy._lib._util import _prune_array from .base import spmatrix, isspmatrix, SparseEfficiencyWarning from .data import _data_matrix, _minmax_mixin from .dia import dia_m...
import requests import json import os import time import threading from appium import webdriver class Connector: def __init__(self, url): self.base_url = url self.auth_key = None self.headers = { 'Content-Type': 'application/json', } def authenticateUser(self, emai...
# -*- coding: utf-8 -*- ''' Package support for openSUSE via the zypper package manager ''' # Import python libs import copy import logging import re # Import salt libs import salt.utils log = logging.getLogger(__name__) # Define the module's virtual name __virtualname__ = 'pkg' def __virtual__(): ''' Set...
"""Implementation of :class:`Domain` class. """ from sympy.core import Basic, sympify from sympy.polys.polyerrors import ( UnificationFailed, CoercionFailed, DomainError, ) class Domain(object): """Represents an abstract domain. """ dtype = None zero = None one = None has_Ring =...
from ddapp import lcmUtils from ddapp import objectmodel as om from ddapp import visualization as vis from ddapp.utime import getUtime from ddapp import transformUtils from ddapp.debugVis import DebugData from ddapp import ioUtils from ddapp import robotstate from ddapp import applogic as app from ddapp import vtkAll a...
# # pandas documentation build configuration file, created by # # This file is execfile()d with the current directory set to its containing # dir. # # Note that not all possible configuration values are present in this # autogenerated file. # # All configuration values have a default; values that are commented out # se...
from __future__ import unicode_literals import copy # Ensure 'assert_raises' context manager support for Python 2.6 import tests.backport_assert_raises # noqa from nose.tools import assert_raises import boto3 import boto from botocore.exceptions import ClientError from boto.exception import EC2ResponseError import ...
""" Collect the various splitting strategies in one place """ import numpy as np from scipy.ndimage import generic_filter from scipy.spatial.distance import cdist from numpy.random import rand import tools #################### # C99 #################### def rankkern(x): """ The kernel for the rank transformatio...
import collections import math from collections import OrderedDict from concurrent import futures from ordered_set import OrderedSet from miniworld.Scenario import scenario_config from miniworld.model.singletons.Resetable import Resetable from miniworld.model.singletons.Singletons import singletons from miniworld.uti...
# Copyright [2015] Hewlett-Packard Development Company, L.P. # 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...
# Copyright (c) 2014 - 2015, David Bothe # 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 notice, # this list of conditions and t...
from pathlib import Path import utils from websocket_client import server import pickle import shutil import asyncio import constants import contextlib import requests import os import shelve import ctypes from watchdog.events import FileSystemEventHandler, DirModifiedEvent,\ FileModifiedEvent from watchdog.observe...
from copy import copy, deepcopy import pytest import marshmallow as ma from umongo.data_proxy import data_proxy_factory from umongo import Document, EmbeddedDocument, MixinDocument, fields, exceptions, ExposeMissing from .common import BaseTest class TestEmbeddedDocument(BaseTest): def test_embedded_inherita...
# Copyright 2014 Rackspace # 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...
# Copyright 2014 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """Finds perf trybots that can run telemetry tests.""" import json import logging import os import re import subprocess import sys import urllib2 from tele...