gt
stringclasses
1 value
context
stringlengths
2.49k
119k
from toontown.estate import DistributedPlantBase from direct.interval.IntervalGlobal import * from direct.directnotify import DirectNotifyGlobal from direct.showbase import PythonUtil from toontown.toonbase import ToontownBattleGlobals from toontown.toontowngui import TTDialog from toontown.toontowngui.TeaserPanel impo...
#!/usr/bin/env python # # spiffsgen is a tool used to generate a spiffs image from a directory # # Copyright 2019 Espressif Systems (Shanghai) PTE LTD # # 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 Lic...
# Use of this source code is governed by the MIT license. __license__ = "MIT" from collections import defaultdict import itertools import sys from bs4.element import ( CharsetMetaAttributeValue, ContentMetaAttributeValue, nonwhitespace_re ) __all__ = [ 'HTMLTreeBuilder', 'SAXTreeBuilder', ...
#!/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...
from trac.core import * from pkg_resources import resource_filename from trac.config import Option, IntOption, ListOption, BoolOption from trac.web.api import IRequestHandler, Href from trac.util.translation import _ from trac.web.chrome import add_stylesheet, add_script, INavigationContributor, ITemplateProvider impor...
import ast import re from collections import deque from typing import Any, Generator, Iterable, List, Optional, Tuple, TypeVar from .keywords import ABBREVIATED_KEYWORDS, ROOT_KEYWORD_DESCRIPTORS from .parser import Parser __version__ = '0.4.0' SQL_RE = re.compile( r'(select\s.*from\s|' r'delete\s+from\s|' ...
#!/usr/bin/python # -*- coding: utf-8 -*- # # Copyright © 2014-2016 NetApp, Inc. All Rights Reserved. # # DO NOT EDIT THIS CODE BY HAND! It has been generated with jsvcgen. # import click from element.cli import utils as cli_utils from element.cli import parser from element.cli.cli import pass_context from eleme...
from __future__ import unicode_literals, absolute_import, print_function import click import sys import frappe from frappe.utils import cint from frappe.commands import pass_context, get_site from frappe.exceptions import SiteNotSpecifiedError def _is_scheduler_enabled(): enable_scheduler = False try: frappe.conne...
# 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 ...
#!/usr/bin/env python # -*- coding: utf-8 -*- # pylint: disable=no-self-use, pointless-statement, missing-docstring, unbalanced-tuple-unpacking, len-as-condition, no-member import re import pytest from ..pattern import StringPattern, RePattern, FunctionalPattern, REGEX_ENABLED from ..match import Match class TestStr...
# 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 agreed to in writing, sof...
import time import pytz import json import datetime import math import serial from datetime import datetime from threading import Thread class Logging: """ An object to log data from the arduino and to convert data to the JSON-format. """ def __init__(self, arduino, omtrek_wiel, trip_name): self.ardui...
# Copyright (c) 2011, SD Elements. See LICENSE.txt for details. import datetime import json import time # We monkeypatch this. from django.conf import settings from django.contrib.auth.models import User from django.contrib.auth import logout from django.core.cache import cache from django.core.exceptions import Imp...
# Log Parser for RTI Connext. # # Copyright 2016 Real-Time Innovations, 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 # # ...
import numpy as np from numpy.random import randn import pytest from pandas._libs import join as libjoin import pandas as pd from pandas import DataFrame, Index, MultiIndex, Series, concat, merge from pandas.tests.reshape.merge.test_merge import NGROUPS, N, get_test_data import pandas.util.testing as tm from pandas.u...
''' Created on 2015/7/20/ :author: hubo ''' from __future__ import print_function import unittest from misc.openflow import common, openflow10, openflow13 from namedstruct import nstruct, dump import json import misc.ethernet as ethernet class Test(unittest.TestCase): exclude = [common.ofp_error_experimenter_msg,...
#!/usr/bin/env python # -*- coding: utf-8 -*- import cherrypy import htpc from urllib import quote, urlencode import requests import logging from cherrypy.lib.auth2 import require, member_of from htpc.helpers import fix_basepath, get_image, striphttp class Sickrage(object): def __init__(self): self.logge...
# Copyright (c) 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 ...
# Copyright 2016-2017 Nitor Creations Oy # # 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 ...
import array import sys import fabric import math import BaseHTTPServer import urlparse import MathExt # shutdown server after maxRequests requests maxRequests = 20 useFabric = False debug = False fabricClients = [] numRequests = 0 if len( sys.argv ) > 1: if sys.argv[1] == '-f': useFabric = True else: pr...
from __future__ import absolute_import, print_function, division import mailcap import mimetypes import os import os.path import shlex import signal import stat import subprocess import sys import tempfile import traceback import weakref import six import urwid from typing import Optional # noqa from mitmproxy impo...
## # pytibrv/events.py # TIBRV Library for PYTHON # tibrvEvent_XXX # # LAST MODIFIED : V1.1 20170220 ARIEN arien.chen@gmail.com # # DESCRIPTIONS # --------------------------------------------------- # 1. Callback cause Segment Fault in OSX # for detail: http://osdir.com/ml/python.ctypes/2008-05/msg00010.html # ...
from django.conf import settings from django.core.exceptions import ObjectDoesNotExist from django.http import Http404 from django.views.generic import DetailView from django_filters.rest_framework import DjangoFilterBackend from guardian.mixins import ( LoginRequiredMixin, PermissionListMixin, PermissionRe...
"""Support for the Netatmo cameras.""" from __future__ import annotations import logging from typing import Any, cast import aiohttp import pyatmo import voluptuous as vol from homeassistant.components.camera import SUPPORT_STREAM, Camera from homeassistant.config_entries import ConfigEntry from homeassistant.core i...
"""Test script for ftplib module.""" # Modified by Giampaolo Rodola' to test FTP class, IPv6 and TLS # environment import ftplib import asyncore import asynchat import socket import io import errno import os import time try: import ssl except ImportError: ssl = None from unittest import TestCase from test im...
import functools import sys from toolz.functoolz import curry, is_valid_args, is_partial_args from toolz._signatures import has_unknown_args from toolz.compatibility import PY3 from toolz.utils import raises def make_func(param_string, raise_if_called=True): if not param_string.startswith('('): param_stri...
# vim:ts=4:sw=4:et: # Copyright 2012-present Facebook, Inc. # Licensed under the Apache License, Version 2.0 from __future__ import absolute_import from __future__ import division from __future__ import print_function # no unicode literals import tempfile import json import os import subprocess import signal try: ...
# Copyright 2013 OpenStack Foundation # Copyright 2013 Rackspace Hosting # Copyright 2013 Hewlett-Packard Development Company, L.P. # 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 co...
import json import math import os import shutil import sys import time import unittest from multiprocessing import Process import requests from app import configs from app import generator from common import posts ec = configs.EnjoliverConfig(importer=__file__) ec.api_uri = "http://127.0.0.1:5000" class TestAPIGun...
import docker import json import requests import subprocess import synapseclient from synapseclient import File, Folder import synapseutils as synu import zipfile import os import base64 import time #Synapse Id of Challenge CHALLENGE_SYN_ID = "syn1235" #Synapse Id of directory that you want the log files to go into CH...
import pytest import pytz import numpy as np import pandas as pd from pandas import (merge_asof, read_csv, to_datetime, Timedelta) from pandas.core.reshape.merge import MergeError from pandas.util import testing as tm from pandas.util.testing import assert_frame_equal class TestAsOfMerge(object):...
# Author: Alexandre Gramfort <alexandre.gramfort@inria.fr> # Daniel Strohmeier <daniel.strohmeier@gmail.com> # # License: Simplified BSD import pytest import numpy as np from numpy.testing import (assert_array_equal, assert_array_almost_equal, assert_allclose, assert_array_less) fro...
from contextlib import contextmanager import numpy as np from matplotlib.colors import ColorConverter from vispy import scene from vispy.scene.visuals import Arrow class MultiColorScatter(scene.visuals.Markers): """ This is a helper class to make it easier to show multiple markers at specific positions...
# 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...
#! /usr/bin/env python # Copyright (c) 2014, OpenCog Foundation # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: # # * Redistributions of source code must retain the above copyright notice, this #...
# Copyright (c) 2012 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...
import sys from functools import update_wrapper from django.conf import settings from django.core.exceptions import ImproperlyConfigured from django.db.models.base import ModelBase from django.views.decorators.cache import never_cache reload(sys) sys.setdefaultencoding("utf-8") class AlreadyRegistered(Exception): ...
# This file helps to compute a version number in source trees obtained from # git-archive tarball (such as those provided by githubs download-from-tag # feature). Distribution tarballs (built by setup.py sdist) and build # directories (produced by setup.py build) will contain a much shorter file # that just contains t...
# 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 (t...
# Copyright (C) 2017 Google Inc. # Licensed under http://www.apache.org/licenses/LICENSE-2.0 <see LICENSE file> """Custom attribute definition module""" import flask from sqlalchemy.ext.declarative import declared_attr from sqlalchemy.orm import validates from sqlalchemy.sql.schema import UniqueConstraint import ggr...
""" Autopsy Forensic Browser Copyright 2019-2020 Basis Technology Corp. Contact: carrier <at> sleuthkit <dot> org 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...
from __future__ import (absolute_import, division, print_function, unicode_literals) from matplotlib.externals import six import matplotlib import matplotlib.artist as martist from matplotlib.artist import allow_rasterization from matplotlib import docstring import matplotlib.transforms as mt...
#!/Users/Alex/MHacks9/FoodStickersMessages/bin/python3.5 """PILdriver, an image-processing calculator using PIL. An instance of class PILDriver is essentially a software stack machine (Polish-notation interpreter) for sequencing PIL image transformations. The state of the instance is the interpreter stack. The only ...
import flask import pymysql from donut.modules.courses import blueprint, helpers YEARS = {1: 'Freshman', 2: 'Sophomore', 3: 'Junior', 4: 'Senior'} WEEK_DAYS = ['Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday'] SCHEDULER_START_HOUR = 8 # 8 AM SCHEDULER_END_HOUR = 23 # 11 PM SCHEDULER_HOUR_HEIGHT = 50 # px @...
""" hook specifications for pytest plugins, invoked from main.py and builtin plugins. """ from _pytest._pluggy import HookspecMarker hookspec = HookspecMarker("pytest") # ------------------------------------------------------------------------- # Initialization hooks called for every plugin # ----------------------...
from ray.rllib.policy.sample_batch import SampleBatch from ray.rllib.models.model import restore_original_dimensions, flatten from ray.rllib.utils.annotations import PublicAPI @PublicAPI class ModelV2: """Defines a Keras-style abstract network model for use with RLlib. Custom models should extend either TFMo...
import datetime import threading import time import cherrypy from cherrypy.lib import cptools, http class MemoryCache: maxobjects = 1000 maxobj_size = 100000 maxsize = 10000000 delay = 600 def __init__(self): self.clear() t = threading.Thread(target=self.expire_cache, na...
# 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...
# 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...
# mininode.py - Bitcoin P2P network half-a-node # # Distributed under the MIT/X11 software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. # # This python code was modified from ArtForz' public domain half-a-node, as # found in the mini-node branch of http://github.c...
# -*- coding:utf-8 -*- # Transform given Active Display Coordinate (ADC) to Media Coordinate (MC). # raw/pororo*.tsv -> data/pororo*.tsv # # @date 2014-03-30 # @author Jin-Hwa Kim (jhkim@bi.snu.ac.kr) import os, sys, getopt, glob, re import numpy as np from sets import Set import common # default options verbose =...
import sys import numpy as np import matplotlib as mpl mpl.use('Agg') import matplotlib.pyplot as plt plt.ioff() import random from scipy import sparse from scipy.special import comb from scipy.special import gammaln from scipy.special import erfcx from scipy.stats import norm import scipy.stats import seaborn import c...
# 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 -*- """ Sahana Eden Transport Model @copyright: 2012-15 (c) Sahana Software Foundation @license: MIT 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 witho...
import re from livestreamer.plugin import Plugin, PluginError from livestreamer.plugin.api import http, validate from livestreamer.plugin.api.utils import parse_query from livestreamer.stream import HTTPStream, HLSStream API_KEY = "AIzaSyBDBi-4roGzWJN4du9TuDMLd_jVTcVkKz4" API_BASE = "https://www.googleapis.com/youtub...
import numpy as np import pytest import pandas as pd import pandas._testing as tm from pandas.core.arrays import FloatingArray @pytest.mark.parametrize("ufunc", [np.abs, np.sign]) # np.sign emits a warning with nans, <https://github.com/numpy/numpy/issues/15127> @pytest.mark.filterwarnings("ignore:invalid value enco...
# 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 use ...
""" Trains an agent with Deep Q Learning or Double DQN on Breakout. Uses OpenAI Gym. """ import sys import os sys.path.insert(0,os.path.expanduser('~/Library/Python/2.7/lib/python/site-packages/')) import numpy as np import cPickle as pickle import gym from optparse import OptionParser import itertools import random ...
# 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...
# -*- coding: utf-8 -*- # # This file is part of Invenio. # Copyright (C) 2015-2018 CERN. # # Invenio is free software; you can redistribute it and/or modify it # under the terms of the MIT License; see LICENSE file for more details. """Model tests.""" from __future__ import absolute_import, print_function import p...
# 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...
import codecs from datetime import datetime from textwrap import dedent import pytest import pandas as pd from pandas import ( DataFrame, Series, ) import pandas._testing as tm from pandas.io.formats.format import DataFrameFormatter from pandas.io.formats.latex import ( RegularTableBuilder, RowBodyIt...
""" Distribution specific override class for CentOS family (RHEL, Fedora) """ import logging from typing import Any from typing import cast from typing import List from certbot_apache._internal import apache_util from certbot_apache._internal import configurator from certbot_apache._internal import parser from certbot...
# -*- coding: utf-8 -*- import urlparse from nose.tools import * # flake8: noqa from website.models import Node from website.util.sanitize import strip_html from tests.base import ApiTestCase from tests.factories import AuthUserFactory, DashboardFactory, FolderFactory, ProjectFactory from api.base.settings.defaults...
# 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 2010 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 requ...
from sympy import ( symbols, log, ln, Float, nan, oo, zoo, I, pi, E, exp, Symbol, LambertW, sqrt, Rational, expand_log, S, sign, conjugate, sin, cos, sinh, cosh, tanh, exp_polar, re, Function, simplify) def test_exp_values(): x, y = symbols('x,y') k = Symbol('k', integer=True) assert exp(na...
# vim: tabstop=4 shiftwidth=4 softtabstop=4 # # Copyright (c) 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...
from django import forms from django.core.exceptions import PermissionDenied from django.db import router from django.http import HttpResponse, HttpResponseRedirect from django.template import loader from django.template.response import TemplateResponse from django.utils.datastructures import SortedDict from django.uti...
# -*- coding: utf-8 -*- # Copyright 2022 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...
from __future__ import absolute_import import unittest import caasp_nodes from caasp_nodes import (get_expr_affected_by, get_from_args_or_with_expr, get_replacement_for, get_with_prio) from _utils import caasp_log from . import Utils try: from mock import patch, MagicMock except ImportEr...
""" **** GEXF **** Read and write graphs in GEXF format. GEXF (Graph Exchange XML Format) is a language for describing complex network structures, their associated data and dynamics. This implementation does not support mixed graphs (directed and unidirected edges together). Format ------ GEXF is an XML format. See...
#!/usr/bin/env python """html2text: Turn HTML into equivalent Markdown-structured text.""" __version__ = "2.37" __author__ = "Aaron Swartz (me@aaronsw.com)" __copyright__ = "(C) 2004-2008 Aaron Swartz. GNU GPL 3." __contributors__ = ["Martin 'Joey' Schulze", "Ricardo Reyes", "Kevin Jay North"] # TODO: # Support deco...
# # Copyright (C) 2008 The Android Open Source Project # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable la...
#!/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...
#!/usr/bin/env python # # Copyright 2017 Robot Garden, 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 applicab...
from textwrap import dedent from .. import base from ..exceptions import NotEnoughSpace from ..utils import FormattersTestCase from . import (CallFormatterWithLinebreakingFallback, LinebreakingAttributeFormatter, ListOfExpressionsWithSingleLineContinuationsFormatter, UnbreakableTupleForm...
# Copyright 2014 ARM Limited # # Licensed under the Apache License, Version 2.0 # See LICENSE file for details. # standard library modules, , , import os import subprocess import tempfile import logging import errno git_logger = logging.getLogger('git') hg_logger = logging.getLogger('hg') class VCSError(Exception): ...
from django.http import HttpResponse, HttpResponseForbidden, HttpResponseRedirect from django.http import HttpResponseBadRequest from django.urls import reverse from django.views.decorators.csrf import ensure_csrf_cookie from django.shortcuts import render from lab01_authserver_app.models import * import json import l...
# Copyright (C) 2017 Google Inc. # Licensed under http://www.apache.org/licenses/LICENSE-2.0 <see LICENSE file> """Utilties to deal with introspecting GGRC models for publishing, creation, and update from resource format representations, such as JSON.""" from sqlalchemy.sql.schema import UniqueConstraint from ggrc.u...
# Brick Breaker Pygame Version 2.0.1 import sys import pygame SCREEN_SIZE = 640,480 # Object dimensions BRICK_WIDTH = 60 BRICK_HEIGHT = 15 PADDLE_WIDTH = 60 PADDLE_HEIGHT = 12 BALL_DIAMETER = 16 BALL_RADIUS = BALL_DIAMETER / 2 MAX_PADDLE_X = SCREEN_SIZE[0] - PADDLE_WIDTH MAX_BALL_X = SCREEN_SIZE[0] - BALL...
#!/usr/bin/python # -*- coding: utf-8; -*- # # 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 # # Unles...
# ---------------------------------------------------------------------------- # Copyright (c) 2016-2022, QIIME 2 development team. # # Distributed under the terms of the Modified BSD License. # # The full license is in the file LICENSE, distributed with this software. # ------------------------------------------------...
from django.db import models from django.contrib.auth.models import User import random import string import plistlib from xml.parsers.expat import ExpatError import base64 import bz2 from datetime import datetime def GenerateKey(): key = ''.join(random.choice(string.ascii_lowercase + string.digits) for x in range...
import logging logger = logging.getLogger(__name__) import itertools import struct import math from .noise import white_noise from .noise import white_noise_samples from .noise import red_noise import sampler def crop(gens, seconds=5, cropper=None): ''' Crop the generator to a finite number of frames Return ...
# 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 by applicable law or ...
# 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 tests that need to update the policies enforced by Chrome. Subclasses can call SetUserPolicy (ChromeOS, Linux, Windows) and SetDeviceP...
# 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...
# Univesity of Chicago, # Feb 2, 2008 # Eric Olson # adapted from home version written by Eric. from OpenGL.GL import * from flapp.pmath.vec3 import * class ScreenClearer: def __init__(self, color=None, clearDepth=True): if color == None: self.color = (.8, .8, .8, 0.0) else: ...
# Copyright 2010 United States Government as represented by the # Administrator of the National Aeronautics and Space Administration. # Copyright 2014 NetApp, Inc. # Copyright 2014 Mirantis, Inc. # # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this fi...
# 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 t...
# microperi.py # Part of MicroPeri https://github.com/c0d3st0rm/microperi # # See LICENSE file for copyright and license details # MicroPeri is a library for using the BBC micro:bit with MicroPython as an # external peripheral device or sensor, using an API which closely replicates # the micro:bit's MicroPython API. ...
""" Copyright (c) 2014 High-Performance Computing and GIS (HPCGIS) Laboratory. All rights reserved. Use of this source code is governed by a BSD-style license that can be found in the LICENSE file. Authors and contributors: Eric Shook (eshook@kent.edu); Zhengliang Feng (odayfans@gmail.com, zfeng2@kent.edu) """ from ..u...
# -*- coding: utf-8 -*- from reportlab.lib.enums import TA_LEFT from reportlab.lib.fonts import addMapping from reportlab.lib.pagesizes import landscape, A4 from reportlab.lib.styles import ParagraphStyle from reportlab.pdfbase import pdfmetrics from reportlab.pdfbase.ttfonts import TTFont from reportlab.platypus.frame...
#!/usr/bin/env python """ @package ion.services.mi.test.test_port_agent_client @file ion/services/mi/test/test_port_agent_client.py @author David Everett @brief Some unit tests for R2 port agent client """ __author__ = 'David Everett' __license__ = 'Apache 2.0' # Ensure the test class is monkey patched for gevent fr...
# 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 ...
# coding=utf-8 # Copyright 2022 The Tensor2Tensor 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 applicable...
from functools import partial from itertools import permutations import numpy as np import unittest from numba.core.compiler import compile_isolated, Flags from numba import jit, njit, from_dtype, typeof from numba.core.errors import TypingError from numba.core import types, errors from numba.tests.support import (Te...
#!/usr/bin/env python import sys import argparse import logging import time import config import netcon # Global variables TENSOR_NAMES = [] TENSOR_MATH_NAMES = [] BOND_NAMES = [] BOND_DIMS = [] VECTORS = [] FINAL_ORDER = None class Tensor: def __init__(self,name=None,bonds=[]): if name==None: ...
"""Creates ACME accounts for server.""" import logging import os import re import configobj import zope.component from letsencrypt.acme import messages2 from letsencrypt.client import crypto_util from letsencrypt.client import errors from letsencrypt.client import interfaces from letsencrypt.client import le_util f...