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...
"""Import CLTK corpora. TODO: ? Fix so ``import_corpora()`` can take relative path. TODO: ? Add https://github.com/cltk/pos_latin TODO: Consider renaming all "import" to "clone" """ import errno import os import shutil import sys from urllib.parse import urljoin import yaml from git import RemoteProgress, Repo from ...
'''author Xinwei Ding''' # [START imports] import os import time import urllib import datetime import calendar from google.appengine.api import users from google.appengine.api import mail from google.appengine.ext import ndb from google.appengine.ext import db import jinja2 import webapp2 DEFAULT_ADMIN='test@example....
# Copyright 2018 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
import uuid from django.conf.urls import url as conf_url from django.core.exceptions import ImproperlyConfigured from django.test import SimpleTestCase from django.test.utils import override_settings from django.urls import NoReverseMatch, Resolver404, path, resolve, reverse from django.utils.deprecation import Remove...
# (C) Datadog, Inc. 2010-2017 # All rights reserved # Licensed under Simplified BSD License (see LICENSE) # stdlib import logging import mock # 3p from docker import Client from nose.plugins.attrib import attr # project from checks import AgentCheck from tests.checks.common import AgentCheckTest from tests.checks.co...
# Copyright (c) 2012-2014 ARM Limited # All rights reserved. # # The license below extends only to copyright in the software and shall # not be construed as granting a license to any other intellectual # property including but not limited to intellectual property relating # to a hardware implementation of the functiona...
# pylint: disable=missing-function-docstring,line-too-long """Test for diff_cover.violationsreporters.java_violations_reporter""" from io import BytesIO from textwrap import dedent import pytest from diff_cover.command_runner import CommandError from diff_cover.violationsreporters import base from diff_cover.violat...
from fuzzysearch.common import group_matches, Match, get_best_match_in_group, \ count_differences_with_maximum, consolidate_overlapping_matches from fuzzysearch.substitutions_only import \ has_near_match_substitutions as hnm_subs, \ find_near_matches_substitutions as fnm_subs, \ find_near_matches_substi...
# -*- coding: utf-8 -*- # # # This source file is part of the FabSim software toolkit, which is distributed under the BSD 3-Clause license. # Please refer to LICENSE for detailed information regarding the licensing. # # fab.py contains general-purpose FabSim routines. from templates import * from machines import * ...
""".. http:get:: /family List the families A successful response returns a JSON aray of :ref:`model-family` objects. :param id: The user id. :query filter: Filter the array of families against a property on the :ref:`model-family` object. :reqheader Authorization: Basic auth with (id, access_token) ...
# Copyright 2021 The QHBM Library 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 # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by appl...
# Windows Azure Linux Agent # # Copyright 2016 Microsoft Corporation # # 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 -*- # Open Source Initiative OSI - The MIT License (MIT):Licensing # # The MIT License (MIT) # Copyright (c) 2012 DotCloud Inc (opensource@dotcloud.com) # # Permission is hereby granted, free of charge, to any person obtaining a copy of # this software and associated documentation files (the "Softwa...
from __future__ import absolute_import import mock import django_dynamic_fixture as fixture from django.contrib.auth.models import User from django.test import TestCase from django.test.utils import override_settings from readthedocs.projects.forms import ProjectRelationshipForm from readthedocs.projects.models impor...
# -*- 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...
# 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 (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 ...
# This file was generated automatically by generate_protocols.py from nintendo.nex import notification, rmc, common, streams import logging logger = logging.getLogger(__name__) class ConnectionData(common.Structure): def __init__(self): super().__init__() self.station = None self.connection_id = None def...
""" Module containing MPG Ranch nocturnal flight call (NFC) detector. The detector looks for NFCs in a single audio input channel by scoring a sequence of input records, producing a clip when the score rises above a threshold. The input records typically overlap. For each input record, the detector computes a spectrog...
# -*- coding: utf-8 -*- # Copyright (c) 2015-2016 MIT Probabilistic Computing 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 # Unles...
# # 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 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...
# 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...
import decimal import numpy as np from numpy import iinfo import pytest import pandas as pd from pandas import DataFrame, Index, Series, to_numeric import pandas._testing as tm @pytest.fixture(params=[None, "ignore", "raise", "coerce"]) def errors(request): return request.param @pytest.fixture(params=[True, 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 2016 Sean Dague # # 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, so...
__author__ = 'waziz' import re from os.path import isfile, basename, splitext import logging from chisel.smt import Yield, Derivation, Tree, SVector import math from glob import glob from collections import defaultdict, deque from wmap import WMap import gzip from io import TextIOWrapper def smart_ropen(path): "...
from .ast_node import AstNode from .errors import AstBuilderException class AstBuilder: def __init__(self): self.reset() def reset(self): self.stack = [AstNode('None')] self.comments = [] def start_rule(self, rule_type): self.stack.append(AstNode(rule_type)) def end_...
################################################################################ # Home page. ################################################################################ # Import Statements. import sys from PyQt4 import QtGui, QtCore from core.repository import MovieRepository from core.repository import Wait f...
"""Mean shift clustering algorithm. Mean shift clustering aims to discover *blobs* in a smooth density of samples. It is a centroid based algorithm, which works by updating candidates for centroids to be the mean of the points within a given region. These candidates are then filtered in a post-processing stage to elim...
import acm import ael import datetime from datetime import date import re import time import HTI_Util import HTI_ExcelReport2 import csv import os import win32com.client import HTI_FeedTrade_EDD_Util ttSaveToFile = "Check this to save the report instead of showing it. Much faster than excel." ttCSV = "Check this to ex...
from copy import deepcopy import inspect import pydoc import numpy as np import pytest import pandas.util._test_decorators as td from pandas.util._test_decorators import ( async_mark, skip_if_no, ) import pandas as pd from pandas import ( DataFrame, Series, date_range, timedelta_range, ) impo...
"""Setup script for Bokeh.""" #----------------------------------------------------------------------------- # Copyright (c) 2012 - 2014, Continuum Analytics, Inc. All rights reserved. # # Powered by the Bokeh Development Team. # # The full license is in the file LICENCE.txt, distributed with this software. #---------...
# coding=utf-8 # Copyright 2014 Pants project contributors (see CONTRIBUTORS.md). # Licensed under the Apache License, Version 2.0 (see LICENSE). from __future__ import (absolute_import, division, generators, nested_scopes, print_function, unicode_literals, with_statement) from contextlib impo...
import tempfile import os.path from stat import S_IXUSR from os import makedirs, stat, symlink, chmod, environ from shutil import rmtree from galaxy.tools.deps import DependencyManager, INDETERMINATE_DEPENDENCY from galaxy.tools.deps.resolvers.galaxy_packages import GalaxyPackageDependency from galaxy.tools.deps.resolv...
# 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 ...
# Licensed to Elasticsearch under one or more contributor # license agreements. See the NOTICE file distributed with # this work for additional information regarding copyright # ownership. Elasticsearch licenses this file to you under # the Apache License, Version 2.0 (the "License"); you may # not use this file except...
import numpy as np import pytest import pandas as pd from pandas import MultiIndex, Series import pandas.util.testing as tm @pytest.mark.parametrize("case", [0.5, "xxx"]) @pytest.mark.parametrize("sort", [None, False]) @pytest.mark.parametrize( "method", ["intersection", "union", "difference", "symmetric_differe...
""" class to use as a general purpose GUI input widget and a few convenience functions for validating data inputs """ """ Copyright (c) <2014>, <Neil Thomas>, <NeilT-UK>, <dc_fm@hotmail.com> All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided th...
# -*- coding: utf-8 -*- from time import time import matplotlib.pyplot as plt import numpy as np from matplotlib import cm # Default configuration contourParams = dict( zdir='z', alpha=0.5, zorder=1, antialiased=True, cmap=cm.PuRd_r ) surfaceParams = dict( rstride=1, cstride=1, linewi...
#!/usr/bin/env python """Test classes for ACL-related testing.""" from typing import Optional from grr_response_core.lib import rdfvalue from grr_response_server import data_store from grr_response_server.gui import api_call_context from grr_response_server.gui.api_plugins import user as api_user from grr_response_se...
"""Carrot compatibility interface. See http://packages.python.org/pypi/carrot for documentation. """ from __future__ import absolute_import, unicode_literals from itertools import count from . import messaging from .entity import Exchange, Queue from .five import items __all__ = ['Publisher', 'Consumer'] # XXX com...
""" Module of library functions, to perform core scaling operations on reflection tables and experiment lists. Some functions, such as create_scaling_model and merging statistics calculations are called from the main dials.scale script, whereas others are provided as library functions for calling from custom scripts. T...
#!/usr/bin/env python """ Artificial Intelligence for Humans Volume 2: Nature-Inspired Algorithms Python Version http://www.aifh.org http://www.jeffheaton.com Code repository: https://github.com/jeffheaton/aifh Copyright 2014 by Jeff Heaton Licensed under the Apache License, Versi...
# Copyright 2016 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...
from decimal import Decimal from django.conf import settings as django_settings # TODO: ensure all values can be overridden from django_settings PAYPAL_MODE = getattr(django_settings, 'PAYPAL_MODE', 'DEV') PAYPAL_USER = getattr(django_settings, 'PAYPAL_USER', False) PAYP...
# # Copyright (c) 2016 NEC Corporation. # 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 re...
# Copyright (C) 2013 Google Inc. All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are # met: # # * Redistributions of source code must retain the above copyright # notice, this list of conditions and the ...
# Copyright 2013 Canonical Ltd. # 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 2011 Justin Santa Barbara # Copyright 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/l...
# Copyright 2015, Google Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are # met: # # * Redistributions of source code must retain the above copyright # notice, this list of conditions and the f...
# # 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...
# # 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...
#!/usr/bin/env python3 # 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. from __future__ import print_function import itertools import json import os.path import pprint import re import sys if sys.vers...
# Copyright 2011, Google Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are # met: # # * Redistributions of source code must retain the above copyright # notice, this list of conditions and the f...
# -*- 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 field 'Event.notify_on_registration' db.add_column(u'events_event', 'notify_on_registration', ...
# Copyright (c) 2020 DDN. All rights reserved. # Use of this source code is governed by a MIT-style # license that can be found in the LICENSE file. import json import django.db.models from chroma_core.services import log_register from chroma_core.lib.util import invoke_rust_agent, invoke_rust_local_action, RustAgent...
# -*- coding: utf-8 -*- # Generated by Django 1.11 on 2017-04-21 16:18 from __future__ import unicode_literals import django.core.validators from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): initial = True dependencies = [ ] operations...
""" sentry.quotas.redis ~~~~~~~~~~~~~~~~~~~ :copyright: (c) 2010-2014 by the Sentry Team, see AUTHORS for more details. :license: BSD, see LICENSE for more details. """ from __future__ import absolute_import import functools import six from time import time from sentry.exceptions import InvalidConfiguration from se...
#=========================================================================== # # Copyright (c) 2014, California Institute of Technology. # U.S. Government Sponsorship under NASA Contract NAS7-03001 is # acknowledged. All rights reserved. # # Redistribution and use in source and binary forms, with or without # modific...
import sqlparse from flask import jsonify, request, url_for from flask_login import login_required from flask_restful import abort from sqlalchemy.orm.exc import StaleDataError from funcy import rpartial from redash import models from redash.authentication.org_resolving import current_org from redash.handlers.base imp...
#!/usr/bin/env python """ MCNPX Model for Cylindrical RPM8 """ import sys sys.path.append('../MCNPTools/') sys.path.append('../') from MCNPMaterial import Materials import subprocess import math import mctal import numpy as np import itertools import os class CylinderRPM(object): # Material Dictionaries cell...
# Copyright 2020, The TensorFlow Federated 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...
# Natural Language Toolkit: Utility functions # # Copyright (C) 2001-2017 NLTK Project # Author: Steven Bird <stevenbird1@gmail.com> # URL: <http://nltk.org/> # For license information, see LICENSE.TXT from __future__ import print_function import locale import re import types import textwrap import pydoc import bisect...
# -*- coding: utf-8 -*- # # Copyright (c) 2015, Alcatel-Lucent Inc, 2017 Nokia # 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 copyrigh...
from collections import namedtuple from posixpath import basename from random import randint, shuffle, uniform from time import time from urllib.parse import urlsplit from discord import User from bot import HahaNoUR from core.argument_parser import parse_arguments from core.image_generator import create_image, get_o...
from abc import abstractmethod, ABCMeta from ._compat import Sequence, Hashable from numbers import Integral import operator import six from pyrsistent._transformations import transform def _bitcount(val): return bin(val).count("1") BRANCH_FACTOR = 32 BIT_MASK = BRANCH_FACTOR - 1 SHIFT = _bitcount(BIT_MASK) de...
from __future__ import absolute_import import abc import pytest from django.core.exceptions import ValidationError from django.utils import timezone from nose.tools import assert_equal, assert_in, assert_raises import mock from framework.auth import Auth from tests.base import DbTestCase from osf_tests.factories im...
#!/usr/bin/env python from __future__ import division import logging import requests import datetime import ConfigParser import argparse import os import yara import re import sys import json import time try: import pygal from pygal.style import Style pygal_available = True except ImportError: raise...
# Authors: Alex Li <7Alex7Li@gmail.com> # Siyuan Ma <Siyuan.ma9@gmail.com> import numpy as np from scipy.linalg import eigh, LinAlgError from sklearn.base import BaseEstimator, ClassifierMixin, RegressorMixin from sklearn.metrics.pairwise import pairwise_kernels, euclidean_distances from sklearn.utils import ...
# # 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...
# -*- coding: utf-8 -*- # # Copyright (C) 2004-2009 Edgewall Software # Copyright (C) 2004 Oliver Rutherfurd # 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://trac.edgewall.org/wi...
""" Test the numpy pickler as a replacement of the standard pickler. """ from tempfile import mkdtemp import copy import shutil import os import random import nose from .common import np, with_numpy # numpy_pickle is not a drop-in replacement of pickle, as it takes # filenames instead of open files as arguments. f...
""" ---------------------------------------- Copyright 2015 Felix Woodhead 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 -------------------------------...
# -*- coding: utf-8 -*- """ Utilities for generating histograms from pandas DataFrames. .. deprecated:: 0.18.0 With the deprecation of :meth:`~verta.tracking.entities._deployable_entity._DeployableEntity.log_training_data`, this module is effectively defunct and remains solely for reference. """ from ..exter...
# This file is part of the MapProxy project. # Copyright (C) 2011-2013 Omniscale <http://omniscale.de> # # 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/LI...
from collections import namedtuple from decimal import Decimal as D from . import availability, prices # A container for policies PurchaseInfo = namedtuple( 'PurchaseInfo', ['price', 'availability', 'stockrecord']) class Selector(object): """ Responsible for returning the appropriate strategy class for...
#!/usr/bin/env python from __future__ import print_function import argparse import json import re import subprocess import sys from pycoin import encoding from pycoin.ecdsa import is_public_pair_valid, generator_secp256k1, public_pair_for_x, secp256k1 from pycoin.serialize import b2h, h2b from pycoin.key import Key ...
# coding: utf-8 from devito import Function, TimeFunction, warning from devito.tools import memoized_meth from examples.seismic.tti.operators import ForwardOperator, AdjointOperator from examples.seismic.tti.operators import JacobianOperator, JacobianAdjOperator from examples.seismic.tti.operators import particle_veloc...
# # 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...
"""Encoding PDUs for use in testing.""" ############################# A-ASSOCIATE-RQ PDU ############################# # Called AET: ANY-SCP # Calling AET: ECHOSCU # Application Context Name: 1.2.840.10008.3.1.1.1 # Presentation Context Items: # Presentation Context ID: 1 # Abstract Syntax: 1.2.840.10008.1.1 Verifi...
# Copyright (c) 2010-2012 ARM Limited # All rights reserved. # # The license below extends only to copyright in the software and shall # not be construed as granting a license to any other intellectual # property including but not limited to intellectual property relating # to a hardware implementation of the functiona...
import unittest from time import time from nose.tools import eq_ from amon.apps.servers.models import ( ServerModel, cloud_server_model ) from amon.apps.devices.models import interfaces_model, volumes_model from amon.apps.processes.models import process_model from amon.apps.system.models import system_model fr...
# coding: utf-8 # # Copyright 2019 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...
import re import sys import urllib if sys.version < '2.4': from sets import ImmutableSet as frozenset from routes.util import _url_quote as url_quote class Route(object): """The Route object holds a route recognition and generation routine. See Route.__init__ docs for usage. """ de...
# ed25519.py - Optimized version of the reference implementation of Ed25519 # # Written in 2011? by Daniel J. Bernstein <djb@cr.yp.to> # 2013 by Donald Stufft <donald@stufft.io> # 2013 by Alex Gaynor <alex.gaynor@gmail.com> # 2013 by Greg Price <price@mit.edu> # # To the extent possible...
# ============================================================================== # Copyright 2019 - Philip Paquette # # NOTICE: 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 rest...
from . import AWSObject, AWSProperty from .validators import ( boolean, integer, network_port, positive_integer, ecs_proxy_type ) LAUNCH_TYPE_EC2 = 'EC2' LAUNCH_TYPE_FARGATE = 'FARGATE' SCHEDULING_STRATEGY_REPLICA = 'REPLICA' SCHEDULING_STRATEGY_DAEMON = 'DAEMON' class Cluster(AWSObject): resource_type = "...
# Copyright 2016 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
# coding=utf-8 r""" This code was generated by \ / _ _ _| _ _ | (_)\/(_)(_|\/| |(/_ v1.0.0 / / """ from twilio.base import deserialize from twilio.base import values from twilio.base.instance_context import InstanceContext from twilio.base.instance_resource import InstanceResource from twilio.base...
import math import multiprocessing import os from abaqus import mdb, session import part, mesh from abaqusConstants import * import regionToolset class ImpactTestKernel(): # Initialize impact test kernel basing on configuration passed def __init__(self, config, modelName="Model-1"): # Model name - u...
import hashlib import json import logging import os import re import shutil import stat import StringIO import tempfile import zipfile from django import forms from django.conf import settings from django.core.files.storage import default_storage as storage from django.utils.translation import trans_real as translatio...
#!/usr/bin/env python '''Train a simple deep CNN on the CIFAR10 small images dataset. Distributed training. run: salloc -N2 -p hsw_p40 --comment=docker --qos=short --time=04:00:00 srun -l --ntasks-per-node=2 \ python examples/cifar/cifar10_cnn_distrib_v2_slurm.py --epochs=5 --rdma # rdma default ...
from __future__ import print_function, division from sympy import (Basic, exp, pi, Lambda, Trace, S, MatrixSymbol, Integral, gamma, Product, Dummy, Sum, Abs, IndexedBase, I) from sympy.core.sympify import _sympify from sympy.stats.rv import (_symbol_converter, Density, RandomMatrixSymbol, ...
#!/usr/bin/env python # # Copyright 2008 the V8 project authors. All rights reserved. # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are # met: # # * Redistributions of source code must retain the above copyright # noti...
""" Syndication feed generation library -- used for generating RSS, etc. Sample usage: >>> from django.utils import feedgenerator >>> feed = feedgenerator.Rss201rev2Feed( ... title="Poynter E-Media Tidbits", ... link="http://www.poynter.org/column.asp?id=31", ... description="A group Weblog by the sharpes...
""" Oracle database backend for Django. Requires cx_Oracle: http://cx-oracle.sourceforge.net/ """ import datetime import decimal import os import platform from django.conf import settings from django.core.exceptions import ImproperlyConfigured from django.db import utils from django.db.backends.base.base import BaseD...
# # Copyright 2016 The BigDL 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 ...
"""The f90nml namelist parser. The ``Parser`` object converts the contents of a Fortran namelist into a hierarchy of Python dicts containing equivalent intrinsic Python data types. :copyright: Copyright 2014 Marshall Ward, see AUTHORS for details. :license: Apache License, Version 2.0, see LICENSE for details. """ fr...