gt
stringclasses
1 value
context
stringlengths
2.49k
119k
# -*- coding: utf-8 -*- # # Copyright (C) 2006-2010 Edgewall Software # All rights reserved. # # This software is licensed as described in the file COPYING, which # you should have received as part of this distribution. The terms # are also available at http://genshi.edgewall.org/wiki/License. # # This software consist...
import hashlib import logging import math import os import pickle import re import requests from retrying import retry import xdg.BaseDirectory from lobster.core.dataset import DatasetInfo from lobster.util import Configurable from dbs.apis.dbsClient import DbsApi from WMCore.Credential.Proxy import Proxy from WMCore...
"""Logic Gate Classes. Multiple inheritance practice.""" class LogicGate: """Logic Gate Class.""" def __init__(self, n): """Initialization for Logic Gate.""" self.label = n self.output = None def getLabel(self): """Getter gate name.""" return self.label def g...
# # 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 # Copyright 2014 The Swarming Authors. All rights reserved. # Use of this source code is governed by the Apache v2.0 license that can be # found in the LICENSE file. import datetime import inspect import logging import os import random import sys import unittest ROOT_DIR = os.path.dirname(os.pat...
import numpy, itertools import scipy.signal as signal from scipy.interpolate import griddata, bisplev, bisplrep import Shadow from wofry.propagator.wavefront2D.generic_wavefront import GenericWavefront2D from wofry.propagator.decorators import WavefrontDecorator from wofry.propagator.wavefront import WavefrontDimensio...
import os import re import json import base64 import logging import datetime import time import copy import decimal import cgi import numpy import pymongo from lib import config, util, util_bitcoin D = decimal.Decimal def get_market_price(price_data, vol_data): assert len(price_data) == len(vol_data) assert...
import sys import numpy as np import os import itertools import pickle import multiprocessing as mp import timeit import getopt #This is created while running Zeisel_wrapper.py file_list='./SRR_in_3005.txt' cell_files=sorted(np.loadtxt(file_list,dtype=str)) try: opts, args = getopt.getopt(sys.argv[1:],"k:s:r:h:...
from pymeta.builder import TreeBuilder, writePython as writePython_orig from textwrap import dedent import unittest def dd(txt): return dedent(txt).strip() def writePython(tree): return writePython_orig(tree).strip() class PythonWriterTests(unittest.TestCase): """ Tests for generating Python source f...
# # 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 # ...
# 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...
from __future__ import absolute_import import math import os import unittest from pychron.core.geometry.affine import transform_point, itransform_point from pychron.stage.maps.laser_stage_map import LaserStageMap class StageMapTestCase(unittest.TestCase): def setUp(self): p = 'pychron/stage/tests/data/22...
# Copyright 2013-2015 DataStax, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writi...
# -*- coding: utf-8 -*- from __future__ import unicode_literals import logging if __name__ == '__main__': logging.basicConfig() _log = logging.getLogger(__name__) from pyxb.utils import unicode, xmlre import re import unittest class TestXMLRE (unittest.TestCase): def assertMatches(self, xml_pattern, value): ...
# coding=utf-8 # 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 copy of the License at # # http://www.apache.org/li...
#!/usr/bin/env python """The MySQL database methods for flow handling.""" from __future__ import absolute_import from __future__ import division from __future__ import unicode_literals import MySQLdb from grr_response_core.lib import rdfvalue from grr_response_core.lib.rdfvalues import client_stats as rdf_client_stat...
# # discord.py documentation build configuration file, created by # sphinx-quickstart on Fri Aug 21 05:43:30 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 # autogenerated file. # # All configuration valu...
import discord from discord.ext import commands import json from sqlalchemy import create_engine, and_ from sqlalchemy.orm import sessionmaker from db import Movelist, Base, Database_Location, Country from contextlib import contextmanager import datetime description = '''Bot for receiving diplomacy commands''' bot = c...
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """Aqueous Helgeson Equation of State with Bromley activity model This file implements an aqueous equation of state (EOS) named the Helgeson EOS with Bromley activity model. It is specifically the version of the that EOS that is described in Jager et. al. (2003), which is...
from __future__ import absolute_import import mock import pytest import six from sentry.integrations.example.integration import ExampleIntegration from sentry.models import ( GroupAssignee, Activity, Integration, GroupLink, ExternalIssue, OrganizationIntegration, sync_group_assignee_inbound ) from sentry.test...
import math import os import pickle from collections import defaultdict import matplotlib import matplotlib.pyplot as plt import numpy as np import pandas as pd import plotnine as p9 import typer from pedroai.io import read_json, write_json from pedroai.plot import theme_pedroai from rich.console import Console from r...
# Copyright 2014: Mirantis Inc. # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required b...
# Copyright (c) 2013, RedJack, LLC. # All rights reserved. # # Please see the COPYING file in this distribution for license details. from __future__ import print_function import argparse import codecs import os.path from pkg_resources import resource_listdir, resource_string import re import select import sys EXIT_SU...
# 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 ...
# coding: utf-8 # # Copyright 2021 The Oppia 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 requi...
""" Visualize function realted to the sensors """ import matplotlib.pyplot as plt from mpl_toolkits.axes_grid1 import make_axes_locatable import seaborn as sns import numpy as np import nexa.loading as load sns.set(style='white') def visualize_STDM(nexa_object, ax=None): """ Routine which plots using seaborn...
""" Tests for various Pyflakes behavior. """ from sys import version_info from pyflakes import messages as m from pyflakes.test.harness import TestCase, skip, skipIf class Test(TestCase): def test_duplicateArgs(self): self.flakes('def fu(bar, bar): pass', m.DuplicateArgument) def test_localReferen...
import os import types import sys import codecs import tempfile import tkinter.filedialog as tkFileDialog import tkinter.messagebox as tkMessageBox import re from tkinter import * from tkinter.simpledialog import SimpleDialog from idlelib.configHandler import idleConf from codecs import BOM_UTF8 # Try setting the lo...
# emacs: -*- mode: python; py-indent-offset: 4; indent-tabs-mode: nil -*- # vi: set ft=python sts=4 ts=4 sw=4 et: from nipype.interfaces.spm.base import SPMCommandInputSpec, SPMCommand, Info, scans_for_fnames, scans_for_fname from nipype.interfaces.matlab import MatlabCommand from nipype.interfaces.base import (Traited...
from __future__ import division import base64 import hmac import re import requests import os.path from binascii import unhexlify from hashlib import sha256 from io import BytesIO, IOBase from math import ceil from threading import Thread, Timer from time import time from .stream import Stream from .wrappers import ...
from tcunittest import TeamcityTestRunner, TeamcityTestResult from tcmessages import TeamcityServiceMessages import sys from pycharm_run_utils import adjust_django_sys_path from django.test.utils import get_runner adjust_django_sys_path() from django.conf import settings def _is_nosetest(settings): """ Checks if...
"""This pipeline is intended to make the classification of ALL modality features.""" from __future__ import division import os import numpy as np from sklearn.externals import joblib from sklearn.preprocessing import label_binarize from sklearn.ensemble import RandomForestClassifier from sklearn.ensemble import AdaB...
#!/usr/bin/env python2.5 import sys import unittest from mappinglib import * def lst_dump(lst, fp=sys.stdout): its = [(' FORWARD ', lst_iter(lst_head(lst))), (' REVERSE ', lst_iter(lst_tail(lst), reverse=True))] high = idx = 0 for title, it in its: print >>fp, title.center(70, '-') ...
"""Bayesian Generalized Linear Model implementation. Implementation of Bayesian GLMs using a mixture of Gaussians posterior approximation with the reparameterization trick and variational inference. See [1]_ for the posterior mixture idea, and [2]_ for the inference scheme. .. [1] Gershman, S., Hoffman, M., & Blei, D...
# -*- coding: utf-8 -*- """ Evalutaion for energy regression models Take a model that predicts energy of events and do the evaluation for that, both in the form of a 2d histogramm (mc energy vs reco energy), and as a 1d histogram (mc_energy vs mean absolute error). Looks for saved arr_energ_corrects to load,...
import inspect import random from myriad.world.base import Tile class GeographicalFeature(Tile): desc = "" allowedTransitions = [] allowedTransforms = { "increased temperature": [], "decreased temperature": [], } canHaveTown = True isPassable = True # human adult walki...
# Copyright 2020 The TensorFlow Probability 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 law o...
""" Functions for converting spherical harmonic coefficients to a different normalization conventions. """ import numpy as _np import warnings as _warnings from scipy.special import factorial as _factorial def convert(coeffs_in, normalization_in=None, normalization_out=None, csphase_in=None, cspha...
# coding: spec from bespin.option_spec import stack_specs as specs, stack_objs as objs from bespin.option_spec import artifact_objs from bespin.errors import BadSpecValue from tests.helpers import BespinCase from noseOfYeti.tokeniser.support import noy_sup_setUp from input_algorithms.meta import Meta from option_mer...
# -*- coding: utf-8 -*- import datetime import json import logging LOG = logging.getLogger(__name__) def hpo_terms(case_obj): """Extract all phenotype-associated terms for a case. Drawback of this method is that it returns the same phenotype terms for each affected individual of the case. Args: ...
""" Bernie's L System demo in Python. This program implements a simple context free L System, and renders two dimensional images in a window. It needs (at least) python 2.6, and uses the turtle graphics library, which is based on TK graphics. To try it out, either load into Python and run the demo functions, or run...
#!/usr/bin/env python3 # Copyright (c) 2014-2018 The Bitcoin Core developers # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. """Test mining RPCs - getmininginfo - getblocktemplate proposal mode - submitblock""" import copy from d...
# 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 -*- """ Copyright (c) 2015-2020 Raj Patel(raj454raj@gmail.com), StopStalk 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 withou...
# # Copyright (c) 2013 Juniper Networks, Inc. All rights reserved. # import sys import gevent import itertools from time import sleep sys.path.append("../common/tests") from test_utils import * from vnc_api.vnc_api import * from device_api.juniper_common_xsd import * from device_manager.dm_utils import DMUtils from tes...
import collections import json as jsonlib import random import re from operator import attrgetter from urlparse import urljoin from django.conf import settings from django.core.exceptions import ObjectDoesNotExist from django.forms import CheckboxInput from django.utils import translation from django.utils.encoding im...
# 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...
from __future__ import division from __evp_system__ import * # ============================================================= # # SIMULATION META PARAMETERS, VARIABLES # # ============================================================= # ARGS = None RESTART_WITH_ITER = None RESTART_FROM_TIME...
""" The outputs.py module represents some form of all outputs from the Automater program to include all variation of output files. Any addition to the Automater that brings any other output requirement should be programmed in this module. Class(es): SiteDetailOutput -- Wrapper class around all functions that print out...
#!/usr/bin/python # -*- coding: utf-8 -*- # (c) 2017, Ansible by Red Hat, inc # # This file is part of Ansible by Red Hat # # Ansible is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the Li...
import datetime from dateutil.relativedelta import relativedelta from decimal import Decimal import factory from factory.fuzzy import FuzzyDate, FuzzyInteger import random import six from django.contrib.auth import models as auth from timepiece.contracts import models as contracts from timepiece.crm import models as...
# Copyright (c) 2012 Rackspace Hosting # 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...
#!/usr/bin/env python # -*- coding: utf-8 -*- """ engine ~~~~~~~ Core functionality. """ import sys import types import time from functools import wraps from concurrent import futures from .tasks import Task, MultiTask, ProcessTask, MultiProcessTask try: # needed for type checks for list of tasks ...
import logging import os from typing import List, Dict import numpy as np import pymc3 as pm from . import io_commons from . import io_consts from .. import types from ..models import commons as model_commons from ..models.model_ploidy import PloidyModelConfig from ..models.model_ploidy import PloidyWorkspace, Ploidy...
# This source file is part of the Swift.org open source project # # Copyright (c) 2014 - 2020 Apple Inc. and the Swift project authors # Licensed under Apache License v2.0 with Runtime Library Exception # # See https://swift.org/LICENSE.txt for license information # See https://swift.org/CONTRIBUTORS.txt for the list o...
import unittest from jarn.mkrelease.mkrelease import ReleaseMaker from jarn.mkrelease.testing import JailSetup from jarn.mkrelease.testing import quiet class serverinfo: sign = None identity = None register = None def __init__(self, sign=None, identity=None, register=None): self.sign = sign...
# -*- 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...
#!/usr/bin/python # -*- coding: utf-8 -*- # Copyright: (c) 2019, Ansible Project # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) from __future__ import absolute_import, division, print_function __metaclass__ = type ANSIBLE_METADATA = {'metadata_version': '1.1', ...
from __future__ import print_function import copy #import logging import sys import math import numpy as np from sas.sascalc.dataloader.data_info import Data1D from sas.sascalc.dataloader.data_info import Data2D _SMALLVALUE = 1.0e-10 class FitHandler(object): """ Abstract interface for fit thread handler. ...
from confess import app from confess.utils import * from confess.constants import * from confess.models.user import * from confess.models.post import * from confess.models.vote import * from confess.models.comment import * from confess.controllers.comment import get_comment_dict import os import json from flask impo...
import json import sys from glob import glob from os import environ, remove, listdir from os.path import exists from time import sleep from socket import gethostbyname from shutil import copytree, rmtree, ignore_patterns from multiprocessing import Value from fabric.api import task, serial, parallel, runs_once, \ ...
# art3d.py, original mplot3d version by John Porter # Parts rewritten by Reinier Heeres <reinier@heeres.eu> # Minor additions by Ben Axelrod <baxelrod@coroware.com> ''' Module containing 3D artist code and functions to convert 2D artists into 3D versions which can be added to an Axes3D. ''' from __future__ import (abs...
#!/usr/bin/env python # # Copyright 2007 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law o...
# The MIT License (MIT) # Copyright (c) 2017 Levak Borok <levak92@gmail.com> # # 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...
import os import time import socket import atexit import signal import pprint import logging import cPickle import subprocess import json import numpy import theano from theano import tensor import blocks from blocks.initialization import Uniform, Constant from blocks.algorithms import ( Adam, GradientDescent, Ad...
import multiprocessing import numpy as np from .model import Model from ..grid import SphericalPolarGrid from ..util.interpolate import interp1d_fast from .analytical_yso_model import AnalyticalYSOModel def find_last_iteration(file_handle): max_iteration = 0 for group_name in file_handle: if "iterati...
"""Module implementing StandardRunner.""" from __future__ import print_function import argparse import os import json import importlib import tensorflow as tf from .. import config from .. import testproblems from . import runner_utils class StandardRunner(object): """Provides functionality to run optimizers o...
# -*- coding: utf-8 -*- # 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 # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law o...
""" Internal module for the plugin system, the API is exposed via __init__.py """ import django.contrib.auth.context_processors import django.contrib.messages.context_processors from django.conf import settings from django.contrib import admin from django.contrib.contenttypes.models import ContentType from django.contr...
#!/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. """Script that reads omahaproxy and gsutil to determine version of SDK to put in manifest. """ # pylint is convinced the email mod...
from .buffer import Buffer from .delay import DelayObservable, DelaySubscription, DelayTime from .generate import Generate from .sample import SampleWithObservable, SampleWithTime from .throttle import ThrottleObservable, ThrottleTime from .timeInterval import TimeInterval from .timeout import TimeoutAbsolute, TimeoutR...
#!/usr/bin/env python # -*- coding: utf8 -*- # ============================================================================ # Copyright (c) 2014 nexB Inc. http://www.nexb.com/ - All rights reserved. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance wi...
# -*- coding: utf-8 -*- ############################################################################## # # OpenERP, Open Source Business Applications # Copyright (c) 2011-2012 OpenERP S.A. <http://openerp.com> # # This program is free software: you can redistribute it and/or modify # it under the terms of t...
import numpy as np import matplotlib as mpl mpl.use('Agg') import matplotlib.pyplot as plt import glob import deepdish as dd import sys import os # some general plot styles for consistency from galaxy_analysis.plot import plot_styles as ps from galaxy_analysis.utilities import utilities colors = {'Disk' : ps.black, ...
# Copyright 2017 The Abseil 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 law or agreed to in ...
"""Support for LG webOS Smart TV.""" from __future__ import annotations import asyncio from collections.abc import Callable from contextlib import suppress import json import logging import os from pickle import loads from typing import Any from aiowebostv import WebOsClient, WebOsTvPairError import sqlalchemy as db ...
#!/usr/bin/env python # deltafy # - a simple library that keeps track of modified/created/removed files and directories in a file tree # # Author: Marshall Culpepper # Licensed under the Apache Public License v2 (see LICENSE.txt) import os, sys, platform, sqlite3, time, stat from datetime import datetime, timedelta ...
import mock import pytest import urllib from django.core.exceptions import MultipleObjectsReturned from osf.models import Guid, NodeLicenseRecord, OSFUser from osf_tests.factories import AuthUserFactory, UserFactory, NodeFactory, NodeLicenseRecordFactory, \ RegistrationFactory, PreprintFactory, PreprintProviderFac...
from pyrep.robots.mobiles.mobile_base import MobileBase from pyrep.robots.configuration_paths.holonomic_configuration_path import ( HolonomicConfigurationPath) from pyrep.backend import utils from pyrep.const import PYREP_SCRIPT_TYPE from pyrep.const import ConfigurationPathAlgorithms as Algos from pyrep.errors imp...
import os import numpy as np from discretize.utils import mkvc from discretize.utils.code_utils import deprecate_method import warnings try: from discretize.mixins.vtk_mod import InterfaceTensorread_vtk except ImportError: InterfaceTensorread_vtk = object class TensorMeshIO(InterfaceTensorread_vtk): """...
#!/usr/bin/env impala-python # Copyright 2012 Cloudera Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable la...
# Copyright 2012 Cloudbase Solutions Srl # # 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 __future__ import division from __future__ import print_function from __future__ import unicode_literals from __future__ import absolute_import from pylab import * from numpy import fft from numpy import linalg from scipy import integrate from scipy import interpolate from numpy.polynomial import chebyshev from ...
import itertools import time from math import floor from level import FakeChunk, MCLevel import logging from materials import pocketMaterials import os from mclevelbase import ChunkNotPresent, ChunkMalformed import nbt import numpy import struct from infiniteworld import ChunkedLevelMixin, SessionLockLost, AnvilChunk...
# Copyright 2014-2015 Canonical 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 applicable law or agreed to in ...
#!/usr/bin/env python # -*- coding: utf-8 -*- import csv import random import glob import os import sys import numpy import pylab import theano import theano.tensor as T from theano.tensor.shared_randomstreams import RandomStreams from svmutil import * N_MONTH = 4 N_DAY_PER_MONTH = 31 BASE_MONTH = 4 TYPE_LENGTH ...
# Copyright 2013, Nachi Ueno, NTT I3, 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...
import kivy from clueless.help import help kivy.require('1.1.3') from kivy.app import App from kivy.clock import Clock from kivy.properties import ObjectProperty from kivy.uix.widget import Widget from kivy.uix.screenmanager import ScreenManager, Screen, WipeTransition from kivy.uix.button import Button from kivy.uix...
# Copyright 2021 Google Research. 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...
""" Sphinx plugins for Django documentation. """ import json import os import re from sphinx import addnodes, __version__ as sphinx_ver from sphinx.builders.html import StandaloneHTMLBuilder from sphinx.writers.html import SmartyPantsHTMLTranslator from sphinx.util.console import bold from sphinx.util.compat import Di...
import networkx import logging from ..errors import AngrCFGError l = logging.getLogger(name="angr.cfg_base") class CFGBase(object): """ The base class for control flow graphs. """ def __init__(self, project, context_sensitivity_level): self._project = project # Initialization ...
#!/usr/bin/env python # -*- coding: utf-8 -*- # # Generated from FHIR 4.0.0-a53ec6ee1b on 2019-05-07. # 2019, SMART Health IT. import os import io import unittest import json from . import coverageeligibilityresponse from .fhirdate import FHIRDate class CoverageEligibilityResponseTests(unittest.TestCase): def...
# Copyright 2013 Red Hat, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agre...
# 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...
# 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...
""" Utilities ============== Rate limiter classes. These are basically callables that when called register that a request was issued. Depending on how they are configured that may cause a pause or exception if a rate limit has been exceeded. Obviously it is up to the calling code to ensure that these callables are 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...
#!/usr/bin/env python # -*- coding: utf-8 -*- # vim: ai ts=4 sts=4 et sw=4 nu """ (c) 2014 - Ronan Delacroix FTP utils :author: Ronan Delacroix """ import sys try: import logging import pyftpdlib.servers import pyftpdlib.handlers from . import text try: from pyftpdlib.handlers import TLS_FT...
# Copyright 2014-2016 Ivan Kravets <me@ikravets.com> # # 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...
#!/usr/bin/python # # remap.py import sys from math import * verbose = False # Use fast vec3 implementation if Numpy is available import numpy as N class vec3(N.ndarray): """A simple 3D vector class, using Numpy for fast array operations.""" def __new__(cls, *args): a = N.ndarray.__new__(vec3, (3,), float) ...