gt
stringclasses
1 value
context
stringlengths
2.49k
119k
# 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...
# -*- coding: utf-8 -*- # <nbformat>3.0</nbformat> # <headingcell level=4> # rgdsnatch: script to get post data from RedditGetsDrawn and post to artcontroldrawsyou # <codecell> import os import random import requests import re import json import praw # <codecell> os.chdir('/home/pi/rgd') # <codecell> r = praw.R...
# coding=utf-8 # Copyright 2018 The Google AI Language Team 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 ...
# -*- coding: utf-8 -*- """ Created on Sun Jan 3 00:30:36 2016 @author: p """ from __future__ import absolute_import, division, print_function, unicode_literals import pandas as pd from datetime import datetime from pylab import rcParams import matplotlib.pyplot as plt import numpy as np import requests class nwis...
import logging import struct l = logging.getLogger(name=__name__) class ParseError(Exception): pass class CoreNote: """ This class is used when parsing the NOTES section of a core file. """ n_type_lookup = { 1: 'NT_PRSTATUS', 2: 'NT_PRFPREG', 3: 'NT_PRPSINFO'...
class TreeNode: def __init__(self,data): self.data = data self.left = None self.right = None class BSTree: def constructTree(self, preorder, inorder, length): if not inorder or not preorder or length < 0: return None return self.constructTree_private(preorder...
from types import * from functools import partial class Transducer: def __init__(self, f, xf): self.f = f self.xf = xf def init(self): return self.xf.init() def result(self, result): return self.xf.result(result) def step(self): pass class Wrap(Transducer): ...
# Licensed under a 3-clause BSD style license - see LICENSE.rst # This module implements the base CCDPROC functions from __future__ import (absolute_import, division, print_function, unicode_literals) import numbers import numpy as np from astropy.extern import six from astropy.units.quantity ...
#!/usr/bin/python import os import re import sys import MySQLdb as ms import numpy as np from sklearn.manifold import TSNE from sklearn.preprocessing import scale # Args assert len(sys.argv) == 7, "Usage:\n\tpython doc2vec.py path_docvec path_confer_vec, path_vocab, path_vector, path_cluster, path_cluster_mean" path_d...
from __future__ import division import unittest import threading import multiprocessing from time import time from random import seed, expovariate from math import log from pprint import pprint from collections import Counter from copy import deepcopy, copy from feemodel.txmempool import MemBlock from feemodel.simul ...
################################################################################################# # # A plugin to help identify common POSIX functions such as printf, sprintf, memcmp, strcpy, etc. # # This plugin will really only work with RISC architectures, as it assumes a fixed instruction # size, and that function ...
''' Created on May 21, 2015 @author: hsorby ''' from opencmiss.zinc.element import Element, Elementbasis def createFiniteElementField(region): ''' Create a finite element field of three dimensions called 'coordinates' and set the coordinate type true. ''' fieldmodule = region.getFieldmodule() ...
# Copyright 2010 United States Government as represented by the # Administrator of the National Aeronautics and Space Administration. # 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 ...
import collections from gym.spaces import Space import logging import math import numpy as np from typing import Any, Dict, List, Tuple, TYPE_CHECKING, Union from ray.rllib.env.base_env import _DUMMY_AGENT_ID from ray.rllib.evaluation.collectors.sample_collector import SampleCollector from ray.rllib.evaluation.episode...
# Lint as: python3 # Copyright 2020 Google 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 # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agr...
# -*- coding: utf-8 -*- """ tipfy.auth.openid ~~~~~~~~~~~~~~~~~ Implementation of OpenId authentication scheme. Ported from `tornado.auth`_. :copyright: 2009 Facebook. :copyright: 2011 tipfy.org. :license: Apache License Version 2.0, see LICENSE.txt for more details. """ from __future__ ...
# -*- coding: iso-8859-1 -*- """ MoinMoin - modern theme @copyright: 2003-2005 Nir Soffer, Thomas Waldmann @license: GNU GPL, see COPYING for details. """ from MoinMoin.theme import ThemeBase from MoinMoin import wikiutil from MoinMoin.Page import Page class Theme(ThemeBase): name = "modernized" ...
import copy from base64 import urlsafe_b64encode import pytest from saml2.config import SPConfig, Config from saml2.mdstore import InMemoryMetaData from saml2.metadata import entity_descriptor from saml2.sigver import security_context from saml2.time_util import in_a_while from satosa.metadata_creation.saml_metadata ...
#!/usr/bin/env python2.7 import sys import copy import string def needs_expand(bits): for i in bits: if i not in "01": return True return False def bit_to_int(bits): out = "" for i in bits: out += i return int(out, 2) r_table = ( ("111", "A"), ("000", "B"), ("001",...
#!/usr/bin/env python import binascii import datetime import glob import itertools import json import logging as log import os import sh import signal import stm32_crc import struct import threading import time import traceback import re import uuid import zipfile import WebSocketPebble from collections import Ordere...
"""Repository support for Bazaar.""" import os import dateutil.parser from django.utils.encoding import force_text from django.utils.timezone import utc from reviewboard.scmtools.core import SCMClient, SCMTool, HEAD, PRE_CREATION from reviewboard.scmtools.errors import (FileNotFoundError, ...
# Copyright 2021 Google 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 to in writing, ...
# :coding: utf-8 # :copyright: Copyright (c) 2013 Martin Pengelly-Phillips # :license: See LICENSE.txt. import abc import sys import re import functools from collections import defaultdict from . import error as lucidity_error # Type of a RegexObject for isinstance check. _RegexType = type(re.compile('')) class Te...
# Copyright 2015, 2016 IBM Corp. # # 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 require...
import os import sys from app.lookups import base as lookups from app.drivers.options import (shared_options, lookup_options, psmtable_options) from app.readers import tsv as tsvreader from app.readers import percolator as percoreaders from app.readers import xml from app.writers import tsv as tsvwriter from app.wri...
# -*- test-case-name: twisted.internet.test.test_endpoints -*- # Copyright (c) 2007-2010 Twisted Matrix Laboratories. # See LICENSE for details. """ Implementations of L{IStreamServerEndpoint} and L{IStreamClientEndpoint} that wrap the L{IReactorTCP}, L{IReactorSSL}, and L{IReactorUNIX} interfaces. This also implement...
import os import tempfile import pytest from rancher import ApiError from kubernetes.client import CoreV1Api from .common import auth_check, random_str, string_to_encoding from .conftest import wait_for, wait_for_condition import time def test_node_fields(admin_mc): cclient = admin_mc.client fields = { ...
# encoding=utf-8 ''' Copyright (C) 2015 luodichen 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...
from __future__ import (absolute_import, unicode_literals, division, print_function) import numpy as np import astropy.units as u import astropy.time as at from astropy.coordinates.baseframe import (BaseCoordinateFrame, RepresentationMapping, frame_transform_graph...
# -*- 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 'BlogUser' db.create_table('blogs_bloguser', ( ('id', self.gf('django.db.models.f...
"""mysqldump support""" import os import re import errno import logging import subprocess from tempfile import TemporaryFile LOG = logging.getLogger(__name__) ALL_DATABASES = object() def check_master_data(version, arg): """Validate --master-data against a mysqldump version""" if version < (4, 1, 8) and arg...
import sys import os import unittest from tempfile import mkdtemp, mkstemp import shutil from rdflib import URIRef, RDF, Graph, plugin from nose.exc import SkipTest class GraphTestCase(unittest.TestCase): store = 'default' tmppath = None def setUp(self): try: self.graph = Graph(sto...
# Copyright 2015 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
# # 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...
"""Test the entity helper.""" # pylint: disable=protected-access import asyncio from datetime import timedelta import threading from unittest.mock import MagicMock, PropertyMock, patch import pytest from homeassistant.const import ( ATTR_ATTRIBUTION, ATTR_DEVICE_CLASS, STATE_UNAVAILABLE, STATE_UNKNOWN...
# -*- coding: utf-8 -*- import json from django.core.urlresolvers import NoReverseMatch from django.core.urlresolvers import reverse from django.test.utils import override_settings import mock from nose.tools import eq_ import mkt from mkt.api.models import Access from mkt.api.tests.test_oauth import RestOAuth from ...
# coding: utf-8 from __future__ import unicode_literals from datetime import datetime import io import logging import os from jinja2.exceptions import TemplateNotFound import jinja2 import json from mkdocs import nav, search, utils from mkdocs.utils import filters from mkdocs.relative_path_ext import RelativePathExt...
""" Unit tests for vector functions """ import unittest import os try: from StringIO import StringIO except ImportError: from io import StringIO import json import picogeojson from test_helper import TESTDATA import karta.vector as vector import karta.vector._geojson as geojson from karta.vector.geometry im...
# -*- coding: utf-8 -*- """ gspread.client ~~~~~~~~~~~~~~ This module contains Client class responsible for communicating with Google Data API. """ import re import warnings from xml.etree import ElementTree from . import __version__ from . import urlencode from .ns import _ns from .httpsession import HTTPSession,...
# 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...
# Lint as: python3. # Copyright 2019 DeepMind Technologies Limited # # 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 a...
#!/usr/bin/python # -*- coding: utf-8 -*- """ Created on Mon Feb 14, 2011 @author:Isabel Restrepo Computes taylor coefficients. Each block is processed in a separate thread. """ import os; import bvpl_octree_batch import multiprocessing import Queue import time import random import optparse import sys from numpy imp...
# -*- coding: utf-8 -*- """ Created on Thu Aug 25 11:18:05 2011 @author: - """ import collections import math import numbers import re from typing import Union, Optional, SupportsFloat, Sequence import numpy as np from .arithmetic import ArithmeticBase __all__ = ['ErrorValue'] class ErrorValue(ArithmeticBase): ...
# coding: utf-8 """ Copyright 2015 SmartBear Software 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 capstone as _capstone import struct as _struct import platform as _platform try: import pyvex as _pyvex except ImportError: _pyvex = None try: import unicorn as _unicorn except ImportError: _unicorn = None import logging l = logging.getLogger('archinfo.arch') l.addHandler(logging.NullHandler()...
# vim: tabstop=4 shiftwidth=4 softtabstop=4 # Copyright 2012 United States Government as represented by the # Administrator of the National Aeronautics and Space Administration. # All Rights Reserved. # # Copyright 2012 Nebula, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # no...
"""Enables Docker software containers via the {dx-,u,}docker runtimes.""" from __future__ import absolute_import from distutils import spawn import datetime import os import re import shutil import sys import tempfile import threading from io import open # pylint: disable=redefined-builtin from typing import Dict, Li...
# Copyright 2012 United States Government as represented by the # Administrator of the National Aeronautics and Space Administration. # All Rights Reserved. # # Copyright 2012 Nebula, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the...
from __future__ import unicode_literals from functools import reduce import operator import threading import warnings from django.db import models from django.db.models.base import ModelBase from django.db.models.query import Q from django.utils import six from django.utils.translation import ugettext as _ from mptt...
"""Module which implements decoding functions using multiple attentions for RNN decoders. See http://arxiv.org/abs/1606.07481 The attention mechanisms used in Neural Monkey are inherited from the ``BaseAttention`` class defined in this module. Each attention object has the ``attention`` function which operates on th...
# 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...
""" This module provides more sophisticated flow tracking and provides filtering and interception facilities. """ from __future__ import absolute_import from abc import abstractmethod, ABCMeta import hashlib import Cookie import cookielib import os import re import urlparse from netlib import wsgi from netlib.exce...
import copy import inspect from importlib import import_module from django.db import router from django.db.models.query import QuerySet from django.utils import six from django.utils.encoding import python_2_unicode_compatible def ensure_default_manager(cls): """ Ensures that a Model subclass contains a defa...
import unittest from mock import Mock from docker.errors import APIError from compose import legacy from compose.project import Project from .testcases import DockerClientTestCase class UtilitiesTestCase(unittest.TestCase): def test_has_container(self): self.assertTrue( legacy.has_container(...
# 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...
# -*- coding: utf-8 -*- import os import sys import yaml import logging import json import re import argparse import datetime import salt.client import device42 from nodefilter import node_filter logger = logging.getLogger('log') logger.setLevel(logging.INFO) ch = logging.StreamHandler(sys.stdout) ch.setFormatter(lo...
# periodic_kdtree.py # # A wrapper around scipy.spatial.kdtree to implement periodic boundary # conditions # # Written by Patrick Varilly, 6 Jul 2012 # Released under the scipy license: # # Copyright 2001, 2002 Enthought, Inc. All rights reserved. # # Copyright 2003-2013 SciPy Developers. All rights reserved. Redist...
from django.contrib.contenttypes.fields import ( GenericForeignKey, GenericRelation, ) from django.contrib.contenttypes.models import ContentType from django.db import models from django.db.models.deletion import ProtectedError __all__ = ('Link', 'Place', 'Restaurant', 'Person', 'Address', 'CharLink', '...
# Copyright 2016 Capital One Services, 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 to in...
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Thu Apr 23 09:09:49 2020 @author: gtucker """ from numpy.testing import assert_array_almost_equal, assert_array_equal from landlab import RasterModelGrid from landlab.components import ErosionDeposition, FlowAccumulator def test_without_depression_handl...
# The following comment should be removed at some point in the future. # mypy: strict-optional=False # mypy: disallow-untyped-defs=False from __future__ import absolute_import, division import contextlib import itertools import logging import sys import time from signal import SIGINT, default_int_handler, signal fro...
# Copyright (c) 2012 NetApp, Inc. # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless require...
# Copyright 2010 United States Government as represented by the # Administrator of the National Aeronautics and Space Administration. # All Rights Reserved. # Copyright (c) 2010 Citrix Systems, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in complianc...
# Copyright 2015 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
import gevent import gevent.pool import gevent.queue import gevent.monkey; gevent.monkey.patch_all() import itertools import optparse import os import sys import time import traceback import random import yaml import realistic import common NANOSECOND = int(1e9) def writer(bucket, objname, fp, queue): key = buck...
#!/usr/bin/env python # -*- coding: utf-8 -*- """ test_eegfaster ---------------------------------- Tests for `eegfaster` module. """ import pytest import numpy as np from eegfaster import eegfaster @pytest.fixture(scope='module') def data(): """ Randomly generates data """ # Some direct accessed f...
# 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...
# Copyright (c) 2010-2012 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 agree...
############################################################################### ## ## Copyright (C) 2014-2016, New York University. ## Copyright (C) 2011-2014, NYU-Poly. ## Copyright (C) 2006-2011, University of Utah. ## All rights reserved. ## Contact: contact@vistrails.org ## ## This file is part of VisTrails. ## ## ...
# 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. #----------------------------------------------------------------------...
# -*- coding: utf-8 -*- import datetime from south.db import db from south.v2 import SchemaMigration from django.db import models from oscar.core.compat import AUTH_USER_MODEL, AUTH_USER_MODEL_NAME class Migration(SchemaMigration): def forwards(self, orm): # Changing field 'ProductAlert.email' ...
#!/usr/bin/env python import glob import subprocess import shutil import re import yaml import sys import os import argparse def main(package, version='default', image=None, dryrun=False, clone=False, quiet=False): parent_dir = os.path.dirname(os.path.abspath(__file__)) build_dir = os.path.join(parent_dir, pa...
import retrying __maintainer__ = 'mnaboka' __contact__ = 'dcos-cluster-ops@mesosphere.io' LATENCY = 60 def test_metrics_agents_ping(dcos_api_session): """ Test that the metrics service is up on masters. """ for agent in dcos_api_session.slaves: response = dcos_api_session.metrics.get('ping', no...
#!/usr/bin/env python # 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. """Unit tests for rietveld.py.""" import logging import os import socket import ssl import sys import time import traceback import...
""" Timer class for timing nested sections of code file: rasmus/timer.py author: Matt Rasmussen date: 2/4/2005 """ # python libs import os import sys import traceback import time # GLOBALS _RASMUS_TIMER = None _GLOBAL_NOTES = None class Timer: def __init__(self, stream=sys.stderr, maxdept...
# Django settings for site project. import os import logging from django.contrib.messages import constants as message_constants MESSAGE_TAGS = {message_constants.ERROR: 'danger'} BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) PROJECT_ROOT = os.path.abspath( os.path.join(os.path.dirname(__fi...
# coding: utf-8 """ Kubernetes No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) OpenAPI spec version: v1.6.1 Generated by: https://github.com/swagger-api/swagger-codegen.git """ from pprint import pformat from six import iteritems import re ...
# 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...
""" Defines arguments manipulation utilities, like checking if an argument is iterable, flattening a nested arguments list, etc. These utility functions can be used by other util modules and are imported in util's main namespace for use by other pymel modules """ from collections import deque as _deque import sys impo...
import sys import unittest from django.conf import settings from django.contrib.admindocs import utils from django.contrib.admindocs.views import get_return_data_type from django.contrib.auth.models import User from django.contrib.sites.models import Site from django.core.urlresolvers import reverse from django.test i...
# Copyright 2014 Objectif Libre # Copyright 2015 DotHill Systems # # 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 # # U...
# vim: tabstop=4 shiftwidth=4 softtabstop=4 # Copyright 2012 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 # # ...
# encoding: utf8 # # spyne - Copyright (C) Spyne contributors. # # 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, or (at your option) any later version...
# vim: tabstop=4 shiftwidth=4 softtabstop=4 # Copyright 2010 United States Government as represented by the # Administrator of the National Aeronautics and Space Administration. # All Rights Reserved. # # Copyright 2010 Anso Labs, LLC # # Licensed under the Apache License, Version 2.0 (the "License"); you may # ...
# Copyright 2019 Fortinet, Inc. # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # This program is distributed in the...
# -*- coding: utf-8 -*- # Copyright (c) 2015-2016 Ericsson AB # # 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 applic...
import os import pwd from osgtest.library import core from osgtest.library import files from osgtest.library.osgunittest import OSGTestCase from osgtest.library import service # These will end up as environment variables in the xrootd configs # as well core.config["stashcache.KEY"] = var # Xrootd config syntax doesn...
# -*- coding: utf-8 -*- import os import sys import re import subprocess import tarfile from contextlib import redirect_stdout from .utils import Color as c, run_and_print from .server import get_total_ram class Benchmark: def __init__(self, specs): self.specs = specs def download(self): ""...
# Copyright 2011 Isaku Yamahata # 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...
# # Copyright (c) 2015 Advanced Micro Devices, Inc. # All rights reserved. # # For use for simulation and test purposes only # # 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 mu...
# Copyright 2015 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
## Amazon S3 manager ## Author: Michal Ludvig <michal@logix.cz> ## http://www.logix.cz/michal ## License: GPL Version 2 import sys import os, os.path import time import httplib import logging import mimetypes import re from logging import debug, info, warning, error from stat import ST_SIZE try: from hash...
#!/usr/bin/env python """ Copyright 2015 The Trustees of Princeton University 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 Unle...
# 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...
# orm/interfaces.py # Copyright (C) 2005-2011 the SQLAlchemy authors and contributors <see AUTHORS file> # # This module is part of SQLAlchemy and is released under # the MIT License: http://www.opensource.org/licenses/mit-license.php """ Contains various base classes used throughout the ORM. Defines the now depreca...
from datetime import datetime from numpy.testing import assert_almost_equal, assert_equal, assert_allclose from numpy import array, column_stack from statsmodels.datasets import macrodata from statsmodels.tsa.base.datetools import dates_from_range from pandas import Series, Index, DataFrame from statsmodels.tsa.filter...
# 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 ...
from __future__ import unicode_literals import re import tempfile from django.contrib.gis import gdal from django.contrib.gis.db.models import Extent, MakeLine, Union from django.contrib.gis.geos import ( GeometryCollection, GEOSGeometry, LinearRing, LineString, Point, Polygon, fromstr, ) from django.core.man...
# Copyright (C) 2016-2018 Cuckoo Foundation. # This file is part of Cuckoo Sandbox - http://www.cuckoosandbox.org # See the file 'docs/LICENSE' for copying permission. import ctypes import mock import os import pytest import subprocess import sys import tempfile import time from cuckoo.common.exceptions import Cuckoo...
""" Contains tests for utils.test_helpers.fixture_factories. This might be bad form, but, our tests test the fixture_factories module by way of testing the actual test fixtures that implement those factories. It *is* circular, and a little indirect, but it means we don't have to duplicate those fixtures here to test t...