gt
stringclasses
1 value
context
stringlengths
2.49k
119k
import unittest import numpy import pytest from cupy import testing from cupy_tests.core_tests.fusion_tests import fusion_utils class FusionUnaryUfuncTestBase(unittest.TestCase): def generate_inputs(self, xp, dtype): x = testing.shaped_random((3, 4), xp, dtype, scale=10, seed=0) return (x,), {}...
# 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...
# # 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...
#!/usr/bin/env python ###################################################################### # Software License Agreement (BSD License) # # Copyright (c) 2010, Rice University # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that t...
from __future__ import print_function from __future__ import unicode_literals from builtins import range from django.test import TestCase from django.utils.timezone import now from django.core.urlresolvers import reverse from pttrack.models import Patient, ProviderType from pttrack.test_views import build_provider, l...
# -*- coding: utf-8 -*- from __future__ import print_function, division, absolute_import import numpy as np import warnings import CoolProp from CoolProp.Plots.Common import IsoLine, BasePlot, interpolate_values_1d from CoolProp.Plots.SimpleCycles import StateContainer class PropertyPlot(BasePlot): def __init__...
#(C) Copyright Syd Logan 2020 #(C) Copyright Thousand Smiles Foundation 2020 # #Licensed under the Apache License, Version 2.0 (the "License"); #you may not use this file except in compliance with the License. # #You may obtain a copy of the License at #http://www.apache.org/licenses/LICENSE-2.0 # #Unless required by a...
# Copyright (c) 2013 Intel, Inc. # 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/li...
# ###################################################################### # Copyright (c) 2014, Brookhaven Science Associates, Brookhaven # # National Laboratory. All rights reserved. # # # # Redistribution and use in ...
#! /opt/local/bin/pythonw2.7 # # 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 ...
import pandas as pd import warnings warnings.simplefilter(action='ignore', category=FutureWarning) warnings.simplefilter(action='ignore', category=DeprecationWarning) # The Dataset comes from: # https://archive.ics.uci.edu/ml/datasets/Optical+Recognition+of+Handwritten+Digits # At face value, this looks like an easy ...
################################################################### # Numexpr - Fast numerical array expression evaluator for NumPy. # # License: MIT # Author: See AUTHORS.txt # # See LICENSE.txt and LICENSES/*.txt for details about copyright and # rights to use. ##########################################...
# -*- coding: utf-8 -*- # _____________________________________________________________________________ # # Copyright (c) 2012 Berlin Institute of Technology # All rights reserved. # # Developed by: Neural Information Processing Group (NI) # School for Electrical Engineering and Computer Science # ...
# -*- coding: utf-8 -*- """ flask.testsuite.reqctx ~~~~~~~~~~~~~~~~~~~~~~ Tests the request context. :copyright: (c) 2012 by Armin Ronacher. :license: BSD, see LICENSE for more details. """ import flask import unittest try: from greenlet import greenlet except ImportError: greenlet = None...
import copy import datetime import pytest from anchore_engine.common.models.policy_engine import ( Artifact, FixedArtifact, Match, NVDReference, Vulnerability, VulnerabilityMatch, ) from anchore_engine.services.policy_engine.engine.vulns.dedup import ( FeedGroupRank, ImageVulnerabiliti...
# 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 # distribu...
# # Copyright 2019 Benjamin Kiessling # # 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 writ...
# -*- coding: utf-8 -*- # (c) 2009-2022 Martin Wendt and contributors; see WsgiDAV https://github.com/mar10/wsgidav # Original PyFileServer (c) 2005 Ho Chun Wei. # Licensed under the MIT license: http://www.opensource.org/licenses/mit-license.php """ Implementation of a WebDAV provider that provides a very basic, read-...
#!/usr/bin/python3 """Set up a GCC repository. Download and configure a GCC repository. There are many options available for downloading GCC -- there is subversion, GCC git (from git://gcc.gnu.org/git/gcc.git), and github GCC (https://github.com/gcc-mirror/gcc.git). """ import getopt import os import sys import scr...
# Copyright (c) 2012 NTT DOCOMO, 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 requ...
# 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 # d...
# 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 # distrib...
# # 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 -*- from bottle import template, redirect, abort import utils import time from datetime import datetime import json import LogicaNegocios def GET(**params): return template('entrada_materiales_index.html') def consultar_asociados_GET(**params): db = utils.Conne...
# Copyright 2013 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 require...
from Visitor import VisitorTransform, CythonTransform from ModuleNode import ModuleNode from Nodes import * from ExprNodes import * from StringEncoding import EncodedString from Errors import CompileError from Code import UtilityCode import Interpreter import PyrexTypes try: set except NameError: from sets imp...
#!/usr/bin/python # coding: utf-8 -*- # (c) 2017, Wayne Witzel III <[email protected]> # 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...
#!/usr/bin/env python # Copyright (c) 2018 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 triggers and waits for tasks on android-compile.skia.org""" import base64 import hashlib import json import math im...
import numpy as np import matplotlib.pyplot as plt import matplotlib as mpl class Confusion(object): '''Confusion matrix class including incremental confusion computation. Instances of this class can be used to compute the confusion matrix and other typical scores for semantic segmentation problems. Eith...
# Copyright 2016 Bridgewater Associates # # 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 appli...
# vim: tabstop=4 shiftwidth=4 softtabstop=4 # Copyright 2011 United States Government as represented by the # Administrator of the National Aeronautics and Space Administration. # All Rights Reserved. # # Copyright 2011 Nebula, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # no...
# 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 u...
import re from cast.Lexer import PatternMatchingLexer, StatelessPatternMatchingLexer from cast.Token import cToken, TokenList from cast.c_Parser import c_Parser def parseIdentifier( string, lineno, colno, terminalId, lexer ): addedToken = token( string, lineno, colno, terminalId, lexer) if addedToken.source_string...
# 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 ...
# 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 unde...
from bs4 import BeautifulSoup from flask import current_app from flask import request, make_response, render_template, url_for, Blueprint from redwind import hooks from redwind import util from redwind.extensions import db from redwind.models import Post, Mention, get_settings from redwind.tasks import get_queue, async...
"""SCons.Tool.JavaCommon Stuff for processing Java. """ # # Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 The SCons Foundation # # 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...
from __future__ import unicode_literals import hashlib import json import os import posixpath import re from collections import OrderedDict from django.conf import settings from django.contrib.staticfiles.utils import check_settings, matches_patterns from django.core.cache import ( InvalidCacheBackendError, cache...
# 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 ...
# Copyright (c) 2012 OpenStack Foundation. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to...
""" Container for different advection schemes for grids and particles. Examples: * semi_lagrangian (grid) * mac_cormack (grid) * runge_kutta_4 (particle) """ import warnings from phi import math from phi.field import SampledField, ConstantField, Field, PointCloud, extrapolate_valid, Grid, sample, reduce_sample from ...
#! /usr/bin/env python # License: 3-clause BSD import sys import os import platform import shutil import tempfile from distutils.command.build_py import build_py from distutils.command.sdist import sdist from distutils.command.clean import clean as Clean from distutils.errors import CompileError, LinkError from pkg_re...
# Software License Agreement (BSD License) # # Copyright (c) 2009-2014, Eucalyptus Systems, Inc. # All rights reserved. # # Redistribution and use of this software in source and binary forms, with or # without modification, are permitted provided that the following conditions # are met: # # Redistributions of source ...
import hashlib import unittest from mock import patch import pytest @patch('fabtools.require.files._mode') @patch('fabtools.require.files._owner') @patch('fabtools.require.files.umask') @patch('fabtools.require.files.put') @patch('fabtools.require.files.md5sum') @patch('fabtools.require.files.is_file') class FilesTe...
# Software License Agreement (BSD License) # # Copyright (c) 2015 Hewlett-Packard Development Company, L.P. # 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 ...
# This file is part of beets. # Copyright 2015, Adrian Sampson. # # 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 to use, copy, ...
# Copyright (c) 2014 OpenStack Foundation. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed ...
# Copyright 2016 Battelle Energy Alliance, LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agr...
import imdb from colorama import Fore, Style from plugin import plugin, require from functools import lru_cache app = imdb.IMDb() def main(jarvis, movie): movie_id = search_movie(jarvis, movie) if movie_id is None: return None return get_movie_by_id(movie_id) @lru_cache(maxsize=50, typed=False...
import MySQLdb import time import logging from mysql_basic_c import mysql_basic_c as database from ..check.PortCheck import check_port logger = logging.getLogger(__name__) class tab_container_runtime(object): ''' Manage tab_container_runtime db table. ''' def __init__(self, host, user, passwd, db): ...
#!/usr/bin/env python # -*- cpy-indent-level: 4; indent-tabs-mode: nil -*- # ex: set expandtab softtabstop=4 shiftwidth=4: # # Copyright (C) 2008,2009,2010,2011,2012,2013,2014,2015,2016 Contributor # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with...
# coding=utf-8 # Copyright 2020 The Google Research Team Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by app...
#!/usr/bin/env python from __future__ import absolute_import, division, print_function from datetime import datetime, timedelta from functools import partial from hashlib import sha256 import hmac import awssig.sigv4 as sigv4 from os import walk from os.path import basename, dirname, splitext from re import sub from si...
import json from nose.tools import eq_, ok_ from django.core.urlresolvers import reverse from airmozilla.main.models import Event from airmozilla.surveys.models import Survey, Question, next_question_order from .base import ManageTestCase class TestCase(ManageTestCase): def test_event_survey(self): su...
import h2.exceptions import time import enum from mitmproxy import connections # noqa from mitmproxy import exceptions from mitmproxy import http from mitmproxy import flow from mitmproxy.proxy.protocol import base from mitmproxy.proxy.protocol.websocket import WebSocketLayer from mitmproxy.net import websockets cl...
""" AMAK: 20050515: This module is a brand new test_select module, which gives much wider coverage. """ import errno import time from test import test_support import unittest import socket import select SERVER_ADDRESS = ("localhost", 0) DATA_CHUNK_SIZE = 1000 DATA_CHUNK = "." * DATA_CHUNK_SIZE # # The timing of th...
# -*- 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 'Alert.status' db.add_column('sentry_alert', 'status', self.gf('django....
#!/usr/bin/env python # # Copyright 2014 Knowledge Economy Developments Ltd # Copyright 2014 David Wells # # Henry Gomersall # [email protected] # # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions ar...
#!/usr/bin/env python3 # Copyright (c) 2016-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 the bumpfee RPC. Verifies that the bumpfee RPC creates replacement transactions successfully when...
# Copyright 2011 Justin Santa Barbara # 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...
#!/usr/bin/env python # -*- coding: utf-8 -*- """Program: Update Dashboard Programmer: Michael Fryar, Research Fellow, EPoD Date created: January 5, 2017 Purpose: Establish SSH tunnel to edX Analytics API, download learner data, and write data to Google Sheets via Sheets API. First time: Must run get_credentials.py ...
#!/usr/bin/env python # # 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 # "...
# Copyright (c) 2013 Mattias Svala # Copyright (c) 2013 Tao Sauvage # Copyright (c) 2014 ramnes # Copyright (c) 2014 Sean Vig # Copyright (c) 2014 dmpayton # Copyright (c) 2014 dequis # Copyright (c) 2014 Tycho Andersen # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software ...
from functools import partial from django.db import connections, models, router from django.db.models.deletion import Collector import bleach import olympia.core.logger from olympia.amo.fields import PositiveAutoField from olympia.amo.models import ManagerBase, ModelBase from olympia.amo.urlresolvers import linkify...
# Copyright (c) 2012 NetApp, Inc. # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required...
# vim: tabstop=4 shiftwidth=4 softtabstop=4 # Copyright (c) 2012 NetApp, Inc. # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.or...
import sys import os home = os.path.expanduser("~") sys.path.append(os.path.join(home, 'gnumpy')) import gnumpy as gp import numpy as np #import scipy import scipy.optimize #import deepnet class NeuralNet(object): ''' Implementation of a Multi-Layer Perception trained by backprop. This class accepts pre-t...
from __future__ import print_function, division, absolute_import from contextlib import contextmanager from glob import glob import logging from multiprocessing import Process, Queue import os import shutil import signal import socket from subprocess import Popen, PIPE import sys from time import time, sleep import uu...
# 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 ...
""" PatientFinders are used to find OpenMRS patients that correspond to CommCare cases if none of the patient identifiers listed in OpenmrsCaseConfig.match_on_ids have successfully matched a patient. See `README.md`__ for more context. """ import logging from collections import namedtuple from functools import partial...
# Copyright (c) 2014, Andre Severo Pereira Gomes # 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 condi...
#!/usr/bin/env python3 # Copyright (c) 2014-2017 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 fee estimation code.""" from decimal import Decimal import random from test_framework.mininode im...
import numpy as np import scipy.sparse as sp import pytest from sklearn.utils._testing import (assert_array_almost_equal, assert_allclose) from sklearn.decomposition import PCA, KernelPCA from sklearn.datasets import make_circles from sklearn.datasets import make_blobs from sklearn....
# -*- coding: utf8 -*- """Contains the tools to produce a wavelength solution This module gets the extracted data to produce a wavelength solution, linearize the spectrum and write the solution to the image's header following the FITS standard. """ from __future__ import (absolute_import, division, print_function, ...
#!/usr/bin/env python # -- Content-Encoding: UTF-8 -- """ Utility methods and decorators :author: Thomas Calmant :copyright: Copyright 2016, Thomas Calmant :license: Apache License 2.0 :version: 0.6.4 .. Copyright 2016 Thomas Calmant Licensed under the Apache License, Version 2.0 (the "License"); you ma...
#!/usr/bin/env python # Software License Agreement (BSD License) # # Copyright (c) 2012, Willow Garage, 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...
# Copyright (c) 2016 Uber Technologies, Inc. # # 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 # to use, copy, modify, merge, publ...
"""Renewer tool. Renewer tool handles autorenewal and autodeployment of renewed certs within lineages of successor certificates, according to configuration. .. todo:: Sanity checking consistency, validity, freshness? .. todo:: Call new installer API to restart servers after deployment """ from __future__ import prin...
""" Django settings for open_humans project. For more information on this file, see https://docs.djangoproject.com/en/dev/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/dev/ref/settings/ """ import logging import os import sys from distutils import util # pyl...
import atexit from ctypes import * from ctypes.util import find_library import sys import os import threading # Determine the library path: libredisLibPath = os.environ.get('LIBREDIS_SO_PATH') if libredisLibPath is None: libredisLibPath = find_library('redis') if libredisLibPath is None: raise Import...
#! /usr/bin/env python """ @file coi-services/ion/idk/data_set_agent/unit_test.py @author Bill French @brief Base classes for data set agent tests. """ import os import time import gevent import shutil import hashlib from mi.core.log import get_logger ; log = get_logger() import unittest import re from pprint import...
# Copyright (C) 2011 Nick Johnson <nickbjohnson4224 at gmail.com> # # Permission to use, copy, modify, and distribute this software for any # purpose with or without fee is hereby granted, provided that the above # copyright notice and this permission notice appear in all copies. # # THE SOFTWARE IS PROVIDED "AS IS" A...
# # Copyright (c) 2005 Conectiva, Inc. # # Written by Gustavo Niemeyer <[email protected]> # # This file is part of Smart Package Manager. # # Smart Package Manager 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 Fou...
# 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 ...
# 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...
import petsc4py import sys petsc4py.init(sys.argv) from petsc4py import PETSc import numpy as np from dolfin import tic, toc import HiptmairSetup import PETScIO as IO import scipy.sparse as sp import matplotlib.pylab as plt import MatrixOperations as MO import HiptmairSetup class BaseMyPC(object): def setup(self,...
#!/usr/bin/python # Copyright (c) 2014 Wladimir J. van der Laan # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. ''' Run this script from the root of the repository to update all translations from transifex. It will do the following...
import logging import json import copy import operator import os import pprint import shlex import datetime import glob class NxConfig(): """ Simple configuration loader """ cfg = {} def __init__(self, fname): try: self.cfg = (json.loads(open(fname).read())) except: ...
""" Mean log loss from 5-fold CV: 0.480065955962 """ import copy import itertools import numpy as np import lasagne import math import os import theano import theano.tensor as T import time from lasagne.layers import DenseLayer, DropoutLayer, InputLayer, get_all_params from lasagne.nonlinearities import rectify, softm...
# Copyright 2020 Netflix, 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...
import binascii import datetime import io import os import hashlib from PIL import Image from shutil import copyfile from django.db import models from django.core.files.base import ContentFile from django.core.files.storage import get_storage_class from django.utils.module_loading import import_string from django.utils...
#!/usr/bin/env python # Copyright 2015 ARM Limited # # Licensed under the Apache License, Version 2.0 # See LICENSE file for details. # standard library modules, , , import unittest import os import tempfile import subprocess import copy import re import datetime # internal modules: from yotta.lib.fsutils import mkDi...
# Copyright 2016, 2017 IBM Corp. # # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless require...
"""Copyright 2010 Phidgets Inc. This work is licensed under the Creative Commons Attribution 2.5 Canada License. To view a copy of this license, visit http://creativecommons.org/licenses/by/2.5/ca/ """ __author__ = 'Adam Stelmack' __version__ = '2.1.8' __date__ = 'May 17 2010' import threading from ctypes import * f...
from __future__ import absolute_import from __future__ import division from __future__ import print_function from __future__ import unicode_literals import os import StringIO from pytest import raises from aspen.website import Website from aspen.http.response import Response from aspen.exceptions import BadLocation ...
############################################################################### # copyright 2012, Marouen Mechtri ([email protected]) # # Institut Mines-Telecom - TELECOM & Management SudParis # # Licensed under the Apache License, Version 2.0 (the "License"); # ...
# 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...
#!/usr/bin/env python # -*- coding: utf-8 -*- # This file is part of convertdate. # http://github.com/fitnr/convertdate # Licensed under the GPL-v3.0 license: # http://opensource.org/licenses/MIT # Copyright (c) 2016, fitnr <fitnr@fakeisthenewreal> from math import trunc import itertools from .utils import amod from ...
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # astrotess.py - Luke Bouma ([email protected]) - 09/2018 ''' Contains various tools for analyzing TESS light curves. ''' ############# ## LOGGING ## ############# import logging from astrobase import log_sub, log_fmt, log_date_fmt DEBUG = False if DEBUG: l...
""" Load an analysis file and redo the predictions on the validation set / test set, this time with augmented data and averaging. Store them as numpy files. """ import numpy as np # import pandas as pd import theano import theano.tensor as T import layers import cc_layers import custom import load_data import realtime...