text
stringlengths
6.04k
39.5k
"""Test template system with built-in plugins""" import locale import os import sys import platform import tempfile import pytest from freezegun import freeze_time import autofile from autofile.filetemplate import FileTemplate from autofile.mtlparser import SyntaxError from autofile.pathlibutil import PathlibUtil fr...
from logs import logDecorator as lD import jsonref, pprint, json import numpy as np import matplotlib.pyplot as plt import csv from psycopg2.sql import SQL, Identifier, Literal from lib.databaseIO import pgIO from collections import Counter from textwrap import wrap from tqdm import tqdm from multiprocessing import P...
import csv import json import logging import os import sys from collections import Sequence, Set, defaultdict from contextlib import contextmanager from datetime import datetime from itertools import chain from tempfile import NamedTemporaryFile from typing import Dict, Iterator, List, Optional, Set, Tuple, Union, cast...
from pathlib import Path import dash from dash.dependencies import ALL, Input, MATCH, Output, State from dash.exceptions import PreventUpdate import dash_bootstrap_components as dbc import dash_core_components as dcc import dash_html_components as html import numpy as np import pandas as pd # import dashboard from me...
############################################################################## # # Copyright (c) 2007 Zope Foundation and Contributors. # All Rights Reserved. # # This software is subject to the provisions of the Zope Public License, # Version 2.1 (ZPL). A copy of the ZPL should accompany this distribution. # THIS SOF...
from typing import Union from django.db.models import Q, Value from django.db.models.functions import Lower, Replace, Trim from .normalization import ( normalize_doi, normalize_funkcja_autora, normalize_grupa_pracownicza, normalize_isbn, normalize_kod_dyscypliny, normalize_nazwa_dyscypliny, ...
"""NCI NDR Stitcher Worker. This script will create 1 degree stitches of NDR results. """ import argparse import datetime import glob import logging import os import pathlib import queue import subprocess import sys import threading import time import traceback import zipfile from osgeo import gdal from osgeo import ...
"""Create citation files from a bib file.""" import bibtexparser import tempfile from bibtexparser.bparser import BibTexParser from bibtexparser.customization import homogenize_latex_encoding import os from pathlib import Path def makemycv(filename='cv.bib', silent=True, bibtex_types=('inbo...
#!/usr/bin/env python3 """Play a sine signal. You need sounddevice==0.4.3, which needs portaudio, seems tough on Windows, see doc: https://python-sounddevice.readthedocs.io/en/0.4.3/installation.html Also need moderngl and moderngl_window https://github.com/moderngl/moderngl-window """ import argparse import collect...
import os from labchain.datastructure.transaction import Transaction from labchain.network.networking import TransactionDoesNotExistException, BlockDoesNotExistException, NoPeersException from labchain.util.Menu import Menu def clear_screen(): os.system('cls' if os.name == 'nt' else 'clear') class Wallet: ...
#!/usr/bin/python # # Ensomniac 2022 <NAME>, <EMAIL> # <NAME>, <EMAIL> import os import sys from Dash import LocalStorage from datetime import datetime from traceback import format_exc from Dash.Utils import Memory, SendEmail class Users: def __init__(self, request_params, dash_context=None): ...
# -*- coding: utf-8 -*- import time import sys import traceback import xbmc import xbmcgui # Add JSON support for queries if sys.version_info < (2, 7): import simplejson else: import json as simplejson # Import the common settings from settings import Settings from settings import log from settings import os_...
import socket import ssl import os import re import gzip import time import tkinter import tkinter.font # DEFAULT_URL = "https://browser.engineering/http.html" # DEFAULT_URL = "https://mozz.us/" # DEFAULT_URL = "http://browser.engineering/redirect" DEFAULT_URL = "file://" + os.path.abspath(os.path.join(os.path.dirnam...
import random import itertools from typing import Optional constructor_to_drivers = { 'Mercedes': ['United Kingdom Lewis Hamilton', 'United Kingdom <NAME>'], 'Red Bull Racing-RBPT': ['Netherlands <NAME>', 'Mexico <NAME>'], 'Ferrari': ['<NAME>', 'Spain <NAME> Jr.'], 'McLaren-Mercedes': ['Australia <NAM...
import pygame from pygame.locals import * import plane import enemyplane import bullet #数量 enemyplane1_num=15 enemyplane2_num=8 enemyplane3_num=5 bullet_num=5 bomb_num=5 # 创建指定个数的小型敌机 并加入组内 def add_small_enemy(group1, group2, num, bg_rect): for i in range(num): each = enemyplane.EnemyPlane1(bg_rect) ...
"""Routines for rational functions.""" from __future__ import annotations import functools from fractions import Fraction from typing import Any, FrozenSet, Iterable, Sequence, Union, overload from .array import _create_raw_int_array, _create_raw_var_array from .jvm import jvm from .poly import Polynomial from .var ...
# -*- coding: utf-8 -*- import datetime import uuid import jwt from ariadne import load_schema_from_path, make_executable_schema, \ graphql_sync, snake_case_fallback_resolvers, ObjectType from ariadne.constants import PLAYGROUND_HTML from graphql_operations.queries import listProducts_resolver, getProduct_resolve...
#! /usr/bin/env python3 """ Commandline User Tools for Input Easification """ __version__ = "0.2.2" __author__ = "Hans / Kamik423" __license__ = "MIT" import getpass from typing import List, Optional from colorama import init import readchar import os, sys from getpass import getpass if sys.platf...
import os, sys, re, json, importlib, random, copy, argparse, pickle import numpy as np import pandas as pd from collections import OrderedDict from tqdm import tqdm import torch import torch.nn as nn import torch.nn.functional as F import matplotlib.pyplot as plt import logomaker as lm from util import * import warnin...
#coding: utf-8 r""" A **real-time polymerase chain reaction (real-time PCR)** is a laboratory technique of molecular biology based on the **polymerase chain reaction (PCR)**. It monitors the amplification of a targeted DNA molecule **during** the PCR (i.e., in real time), **not at its end**, as in conventional PCR. Rea...
# Copyright (c) 2021 ING Wholesale Banking Advanced Analytics # # 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, mo...
# -*- coding: utf-8 -*- """ This module provide utilities for converting from any complex format that we can read to SICD or SIO format. The same conversion utility can be used to subset data. """ import os import sys import pkgutil import numpy import logging from typing import Union, List, Tuple from . import __pat...
import requests import cv2 import numpy as np import pandas as pd import matplotlib.pyplot as plt import io import logging import logging.handlers #Needed for Syslog import sys from pathlib import Path #Use this to check for file existence import paho.mqtt.publish as publish import yaml #Get configuration parameters f...
""" Various classes and functions to model automated planning. Based on code from: - https://github.com/aimacode/aima-python/blob/c587f2c429b9dec199f190c3453cd269b6b6bbd1/planning.py - https://github.com/aimacode/aima-python/blob/c587f2c429b9dec199f190c3453cd269b6b6bbd1/utils.py - https://github.com/aimacode/aima-pyth...
import pathlib import time import heal.watch READ_CONFIGURATION_FILE_1 = """ --- - lorem - ipsum - dolor - sit - amet """.lstrip() READ_CONFIGURATION_FILE_2 = """ --- - consectetur - adipiscing - elit """.lstrip() READ_CONFIGURATION_OK_OUTPUT = """ reading configuration """.lstrip() def test_read_configuration_ok...
import inspect import re import itertools def _empty_func(): pass def set_signature(signature): def decorator(func): return wraps(_empty_func, expected=signature)(func) return decorator def get_function_body(func): source_lines = inspect.getsourcelines(func)[0] source_lines = itertools...
# <NAME> # EASY WALTON TRACKER DATABASE SIDE # # # #IT IS WEDNESDAY MY DUDES # # # #import Flask Library from flask import Flask, render_template, request, session, url_for, redirect, Response, jsonify from flask_paginate import Pagination, get_page_args from flask_bootstrap import Bootstrap import pymysql.cursors i...
""" This module contains all core classes required for drawing diagrams. Available Classes: - Graph - Cluster - Node - Edge - Flow Available Functions: - get_graph - set_graph - get_cluster - set_cluster - get_state - set_state - update_state - search_state - wrap_text - get_node_obj Details for each can be found in...
import typing import random import unicodedata from abc import ABC from dataclasses import dataclass from functools import cached_property from typing import Union from . import constants def deaccent(text): norm = unicodedata.normalize("NFD", text) result = "".join(ch for ch in norm if unicodedata.category(c...
# === imports ================================================================= #from flask import * from flask import flash, render_template, redirect, abort, jsonify, request, url_for from flask import send_file import os import sys import subprocess as sub import json from datetime import datetime from werkzeug.uti...
"""This module includes classes of matrices. """ from copy import deepcopy import math import numbers import itertools import operator class InappropriateDimensions(Exception): pass class Matrix: """This class represents a matrix of any type and shape. Methods should be implemented for this interface...
from multiprocessing import Pool import platform import numpy as np from mogp_emulator.GaussianProcess import ( GaussianProcessBase, GaussianProcess, PredictResult ) from mogp_emulator.Kernel import KernelBase from mogp_emulator.Priors import GPPriors class MultiOutputGP(object): """Implementation of a...
from __future__ import division from openmdao.api import Problem, Group, IndepVarComp, NewtonSolver, DirectSolver, BoundsEnforceLS from openmdao.api import ScipyOptimizeDriver, ExplicitComponent, ImplicitComponent import numpy as np import scipy.sparse as sp import sys, os sys.path.insert(0,os.getcwd()) from openconce...
from ctypes import ( addressof, c_short, c_uint, c_int, c_ulong, sizeof, POINTER, CDLL, ) from mmap import MAP_SHARED, PROT_READ, PROT_WRITE, mmap from select import * from typing import Any, List, Optional, Tuple, Union, overload from command_buffer import * from nvmap_header import ( ...
# coding=utf-8 import regex import number_homoglyphs from helpers import get_only_digits, remove_end_regex_comments # The NUMBER_REGEXes are used to obtain strings within a post which are considered to be a single "number". While # it would be nice to be able to just use a single regular expression like: # r'(?:...
from django.db import models from easy_thumbnails.fields import ThumbnailerImageField from django.db.models.signals import post_delete from mediaman.models import MediaFile import os from PIL import Image class Accession(models.Model): """ An accession, including source, taxonomic, and detailed descriptive informat...
import importlib import inspect from pathlib import Path import tkinter import re from typing import Type import yaml from yamlinclude import YamlIncludeConstructor from tksugar.tkmanager import TkManager from tksugar.localizer import Localizer from tksugar.widgets.generatorsupport import GeneratorSupport from tksuga...
# -*- coding: utf-8 -*- # Copyright (c) 2017-2020 <NAME> and contributors # See LICENSE.rst for details. import atexit import inspect import argparse import importlib from collections import OrderedDict from deprecated import deprecated def get_choices(module_name): """ Retrieve members from ``module_name``...
from random import shuffle, Random import cv2 from collections import defaultdict from vi3o import view import numpy as np import pickle import os from vi3o.image import imsave from ggdtrack.utils import parallel, save_json, save_pickle, load_json, save_graph class KltTrack: def __init__(self, idx, x, y): ...
# Copyright (C) 2020 Secure Systems Group, University of Waterloo and Aalto University # License: see LICENSE.txt # Author: <NAME> and <NAME> import os import pandas as pd import numpy as np from collections import deque import tqdm import joblib # contains subroutines for training, saving/loading pipeline import log...
import itertools import logging import json import operator import time from collections import defaultdict from typing import List, Tuple, Dict from mip import Model, minimize, CONTINUOUS, xsum, OptimizationStatus from rapidstream.BE.Utilities import isPairSLRCrossing from rapidstream.BE.Device.U250 import idx_of_le...
# -*- coding: utf-8 -*- from alive_progress import alive_bar import pandas as pd from logging import getLogger from tws_equities.data_files import get_japan_indices from tws_equities.helpers import read_json_file from tws_equities.helpers import save_data_as_json from tws_equities.helpers import make_dirs from tws_e...
# Copyright 2016 Hewlett Packard Enterprise Development LP # # 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...
""" Tests for functions in ensemble_tools.py. Authors: <NAME> & <NAME> Note that functions that start with an underscore (_) are designed for local use only by the primary functions within ensemble_tools.py. Therefore, testing of those local scripts does not include checking for irrational inputs that would cause me...
from __future__ import absolute_import, division, print_function, unicode_literals from warnings import simplefilter simplefilter(action='ignore', category=FutureWarning) import numpy as np import argparse import pandas as pd from tqdm.auto import tqdm from datetime import datetime, timedelta import lightgbm as lgb im...
'''Key proxies ''' __version__ = "0.14.0" # Copyright (c) 2020 Janky <<EMAIL>> # All right reserved. # # Redistribution and use in source and binary forms, with or without modification, # are permitted provided that the following conditions are met: # # 1. Redistributions of source code must retain the above copyright...
#from grounding import Grounder import grounding from pddl.parser import Parser from task import Operator from pddl.pddl import Type, Predicate, Effect, Action, Domain, Problem def assert_equal(result, expected): assert result == expected def get_action(name, signature, precondition, addlist, dellist): effe...
#!/usr/bin/env python import numpy as np import matplotlib.pyplot as plt import matplotlib.image as mpimg import matplotlib.gridspec as gridspec import glob import cv2 # ## Step 1: Callibration of the Camera # ### Step 1.1: Definition of Helper Routines # # :-) as I'm getting used to Python within this course I'm...
# Copyright (c) 2020, <NAME>, Honda Research Institute Europe GmbH, and # Technical University of Darmstadt. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: # 1. Redistributions of source code mus...
# Copyright (c) 2021 <NAME>. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. # pylint: disable=invalid-name import os import time import unittest from typing import List import pandas from matplotlib import pyplot as plt from ai.permutati...
from enum import Enum import os from threading import Thread from tkinter import ( Frame, Scrollbar, StringVar, Canvas, Event, VERTICAL, TRUE, FALSE, RIGHT, Y, NW, LEFT, BOTH, Listbox, SINGLE, Widget, END, TclError, ) from typing import Any, Option...
import numpy as np import torch from timm.models.layers import trunc_normal_ from torch import nn as nn from everything_at_once.model.utils.utils import normalize_embeddings from everything_at_once.model.utils.layers import get_projection from everything_at_once.model.utils.fusion_transformer import FusionTransformer ...
from __future__ import absolute_import, division, print_function import pickle import argparse import logging import os import random import wget import json import time import numpy as np import torch from torch.utils.data import (DataLoader, RandomSampler, SequentialSampler, TensorData...
# Image/Icon-Preview https://docs.blender.org/api/blender2.8/bpy.utils.previews.html?highlight=preview#module-bpy.utils.previews # UI-Layout 2.8: https://docs.blender.org/api/blender2.8/bpy.types.UILayout.html?highlight=uilayout bl_info = { "name": "JSON-Nodetree", "author": "<NAME>", "version": (0, 1, 0), ...
from __future__ import unicode_literals import json import os import tempfile from pydub import AudioSegment from pathlib import Path import glob from urllib.request import urlopen import geocoder from django.contrib.gis.db.models import PointField, Manager as GeoManager from django.contrib.gis.geos import Point fro...
# Copyright (c) SenseTime. All Rights Reserved. from __future__ import absolute_import from __future__ import division from __future__ import print_function from __future__ import unicode_literals import argparse import os import cv2 import torch import numpy as np from pysot.core.config import cfg from pysot.model...
import constants import gen import vis import math import cv2 from cv2 import xphoto import numpy as np from glob import glob # makes output match image, but internal processing is mirrored FLIP = True RES = 1080 # Options: None, ROTATE_TEE, ROTATE_BASE, TEE, BASE # Warping beyond rotation (TEE, BASE) is currently b...
import gym import ma_gym import random import datetime import numpy as np import tensorflow as tf def get_variable(name, shape): return tf.get_variable(name, shape, tf.float32, tf.initializers.truncated_normal(0,0.01)) def Qmix_mixer(agent_qs, state, state_dim, n_agents, n_h_mixer): ...
import logging from abc import ABC, abstractmethod from contextlib import ExitStack from typing import Any, Callable, Collection, Dict, List, Optional, Type, TypeVar, Union from puma.attribute import ProcessAction, ThreadAction, child_only, child_scope_value, copied, factory, manually_managed, per_scope_value, python_...
import discord from discord.ext import commands import aiohttp import yaml import re import logging TIMINGS_CHECK = None YAML_ERROR = None with open("cogs/timings_check.yml", 'r', encoding="utf8") as stream: try: TIMINGS_CHECK = yaml.safe_load(stream) except yaml.YAMLError as exc: logging.info(...
# Code for initialization of NMF, copied with little modification from scikit-learn # Original source: https://github.com/scikit-learn/scikit-learn/blob/7e1e6d09bcc2eaeba98f7e737aac2ac782f0e5f1/sklearn/decomposition/_nmf.py#L229 import numpy as np from scipy import linalg import warnings from math import sqrt import nu...
""" PointNet++ Layers Original Author: <NAME> Modified by <NAME> Date: July 2020 """ import os import sys BASE_DIR = os.path.dirname(os.path.abspath(__file__)) ROOT_DIR = os.path.dirname(BASE_DIR) sys.path.append(os.path.join(ROOT_DIR, 'utils')) sys.path.append(os.path.join(ROOT_DIR, 'tf_ops/sampling')) sys.path.appen...
# -*- coding: utf-8 -*- from pathlib import Path import click from ._version import get_versions from .utils import BarcodeType, AdapterType, MutuallyExclusiveOption, str2path __version__ = get_versions()['version'] CONTEXT_SETTINGS = dict(help_option_names=['-h', '--help']) @click.group(chain=True, context_settin...
""" Trust Region Policy Optimization (Schulman et al, 2017) """ import time import gym.wrappers.time_limit import numpy as np import scipy.signal import tensorflow as tf import tensorflow_probability as tfp from tqdm.auto import trange from envs.vector import SyncVectorEnv from utils.logx import EpochLogger tfl = t...
# -*- coding: utf-8 -*- ############################################################################# # # Copyright © <NAME> # contact: <EMAIL> # # This software is a collection of webservices designed to provide a secure # and scalable framework to build e-commerce websites. # # This software is governed by the CeCIL...
__author__ = '<NAME>' from matplotlib import pyplot as plt import numpy as np import scipy.interpolate import matplotlib as mpl #-------------------------------- # Functions #-------------------------------- # ------------------------------------------ # Radial Function Cos # ---------------------...
# standard library from builtins import super, object from functools import wraps try: # in case of rogue Python 2.7, use collections instead of collections.abc from collections.abc import Sequence except ImportError: from collections import Sequence try: # in case of rogue Python 2.7, use contextlib2 instead...
#!/usr/bin/python3 # Copyright (C) 2018-2022 Intel Corporation # SPDX-License-Identifier: Apache-2.0 from openvino.runtime import Core, Model, Tensor, PartialShape, Type from openvino.runtime import opset8 as opset from openvino.runtime.op import Constant, Parameter, tensor_iterator from openvino.runtime.passes impor...
import numpy as np import matplotlib.pyplot as plt from scipy.ndimage.filters import gaussian_filter from math import factorial from astar import astar, create_grid, Node from dijkstras import shortest_path_mat from scipy import ndimage def plot_fr_field_2d(f,delay=None): for i in range(len(f)): maxval = np.max...
# Copyright 2021, 2022 Cambridge Quantum Computing Ltd. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable la...
from collections import defaultdict import json from typing import Any, Dict, Iterable, List, Set, Tuple, Union from urllib.parse import urlencode import requests ARAX_QUERY_ARG_ID = 'id' ARAX_QUERY_ARG_SOURCE = 'source' ARAX_SOURCE_ARS = 'ARS' ARAX_URL = 'https://arax.ncats.io/' ARS_QUERY_ARG_TRACE = 'trace' ARS_...
import utils.init_multiprocessing # import before numpy import numpy as np import os import time from multiprocessing import cpu_count from singlecell.analysis_basin_plotting import plot_basin_grid, grid_video, plot_overlap_grid from singlecell.analysis_basin_transitions import \ ensemble_projection_timeseries, g...
""" Minewalker is a game where the player aims to cross a field without a mine. """ import msvcrt, random, os, time, ast, sys from random import randint from termcolor import colored class Main(): """ Minewalker """ def __init__(self, x=10, y=10, mines=15, player=' 0 ', colour=None, trail=' # ', wait=3...
import eff_min import pytest TOL = 6 # tolerance, compare to this number of decimal places MEAN_PER_CALL_DATA = ( # (maximum, minimum, per_minute, charge_interval, connection=0) (30, 60, 20, 60), (60, 60, 20, 60), (120, 60, 20, 60), (180, 60, 20, 60), (30, 60, 20, 1), (60, 60, 20, 1), (120, 60, 2...
''' @Description:yolov4_loss 损失计算 @Author:Zigar @Date:2021/03/11 11:32:42 ''' import torch import torch.nn as nn import math import numpy as np import torch.nn.functional as F from PIL import Image from utils.utils import box_iou, box_ciou, clip_by_tensor, smooth_labels #----------------------------------------------...
#!/usr/bin/env python3 # To change this license header, choose License Headers in Project Properties. # To change this template openFile, choose Tools | Templates # and open the template in the editor. __author__="dasmoep" __date__ ="$Jun 23, 2014 5:01:41 PM$" import os #will once contain the history leading to some...
import os from typing import List try: from typing import Literal except ImportError: from typing_extensions import Literal # type: ignore from typing import Optional import numpy as np import pandas as pd import scanpy as sc from anndata import AnnData from rich import print WORKING_DIRECTORY = os.path.di...
# coding=utf-8 # ============================================================================== # beelbe # Copyright © 2016 <NAME>. 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 L...
""" mathEX.py @author: <NAME> @email: <EMAIL> Math-related functions, extensions. """ import numpy as np from ml.utils.logger import get_logger LOGGER = get_logger(__name__) def change_to_multi_class(y): """ change the input prediction y to array-wise multi_class classifiers. @param y:input prediction ...
# -*- coding: utf-8 -*- """ @author: wi-ith """ import tensorflow as tf import crop_pad import os FLAGS = tf.app.flags.FLAGS def decode_jpeg(image_buffer, channels, scope=None): """Decode a JPEG string into one 3-D float image Tensor. Args: image_buffer: scalar string Tensor. scope: Optional ...
import logging import os import shutil import time import json import random import linecache import gc import numpy as np import torch from src.bayesian_summarization.bayesian import BayesianSummarizer from src.common.loaders import load_model, create_loader from src.bayesian_summarization.bleu import analyze_gener...
""" Implementation of Eccles, Tom, et al. "Biases for Emergent Communication in Multi-agent Reinforcement Learning." Advances in Neural Information Processing Systems. 2019. """ import gym import numpy as np from ray.rllib import SampleBatch from ray.rllib.agents.impala import vtrace from ray.rllib.agents.impala.vtra...
""" feature set <NAME>, University College Cork Started: 06-09-2019 last update: Time-stamp: <2019-12-17 18:01:52 (otoolej)> """ import numpy as np from matplotlib import pyplot as plt from numba import jit import math from scipy.signal import hilbert, resample_poly from burst_detector import utils, bd_parameters d...
import warnings import csv import collections from functools import reduce import itertools import pandas as pd import numpy as np import yfinance as yf import matplotlib.pyplot as plt import sklearn import pmdarima as pm import arch from arch.__future__ import reindexing from sklearn.decomposition import PCA from skl...
import torch import os import torch.nn as nn import torch.nn.functional as F import torch.optim as optim import time import sys import pandas as pd import numpy as np import keras from sklearn.preprocessing import LabelEncoder from sklearn.preprocessing import OneHotEncoder from Levenshtein import distan...
# coding=utf-8 # *** WARNING: this file was generated by the Pulumi SDK Generator. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** import warnings import pulumi import pulumi.runtime from typing import Any, Mapping, Optional, Sequence, Union, overload from .. import _utilities from...
#================================================================================ # <NAME> [marion dot neumann at uni-bonn dot de] # <NAME> [marthaler at ge dot com] # <NAME> [shan dot huang at iais dot fraunhofer dot de] # <NAME> [kristian dot kersting at cs dot tu-dortmund dot de] # # This file is part...
# -*- coding: utf-8 -*- # pylint: disable-msg=R0921,W0613 # pylint-version = 0.7.0 # # Copyright 2004-2005 <NAME> or his licensors, as applicable # # 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 ...
__version__ = '0.10.3' import matplotlib.pyplot as plt import tensorflow as tf import load_data import optimizers import data_preprocessing import keras from keras import layers from keras import losses from keras import backend as K from keras.models import Sequential, Input, Model from keras.models import load_mode...
# COMPARING ALGORITHM - MAIN FILE_V6 - ARCHITECTONIC - </> by ShivaReddy. import pandas as pd import openpyxl from openpyxl import load_workbook from openpyxl.styles import PatternFill # import pillow ##### # PART 1 - (START) - GET THE DATA, & CONVERT IT INTO DICTIONARIES # file_1 = pd.ExcelFile(r'C:\Users\sr...
import cv2 import numpy as np import torch import torch.nn as nn import torch.nn.functional as F import torch.optim as optim import config as cfg import networks.invresnet from datasets import ds_utils from utils import vis from networks.archs import D_net_gauss, Discriminator from networks import resnet_ae, archs fr...
import numpy as np import nlopt as nl from .types import Folds from dora.regressors.gp import predict from dora.regressors.gp import linalg from dora.regressors.gp import types import sklearn.cluster as skcluster import scipy.interpolate as interp from scipy.spatial import Delaunay import scipy.stats as stats from scip...
import sys import os import re import mxnet as mx import collections import math sys.path.append(os.path.join(os.path.dirname(__file__), '..')) from config import config ######################################################################## ############### HELPERS FUNCTIONS FOR MODEL ARCHITECTURE ############### #...
#!/usr/bin/env python2 """ Google Cloud Engine Dynamic Inventory ===================================== Before using: - Authentication: this script uses the same authentication as gcloud command line. So, set it up before according to: https://cloud.google.com/ml-engine/docs/quickstarts/command-line - Depen...
""" (C) Copyright 2019 IBM Corp. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software ...
from __future__ import print_function, division import sys import argparse # matplotlib.use('Agg') import torch.nn as nn import torch.optim as optim from model.eraft import ERAFT from torch.utils.data import DataLoader from torch.cuda.amp import GradScaler from torch.utils.tensorboard import SummaryWriter from loader....
#!/usr/bin/env python3 # # Copyright 2018 Red Hat, Inc. # # Authors: # <NAME> <<EMAIL>> # # This work is licensed under the MIT License. Please see the LICENSE file or # http://opensource.org/licenses/MIT. from collections import OrderedDict from django.contrib.auth.models import User from django.http import Http...
from collections import namedtuple import os import re from astropy import units as u from astropy.cosmology import FlatLambdaCDM import h5py import pandas as pd import numpy as np import numpy.ma as ma from numpy.random import default_rng from desc.skycatalogs.utils.common_utils import print_dated_msg __all__ = ['L...
# 2018/08/31 Initial to use pandas, matplotlib,TAlib # 2018/09/01 Using pandas to calculate MA # Calculate golden and dead MA # Add class PandasDataAnalysis # Slove matplotlib to show Chinese charter # 2018/09/02 Match '---' and '--' in close price by using regular express # ...
import os import shutil import sys import threading import _thread import time import channelpy import configparser from aga import Agave from auth import get_tenant_verify from channels import ActorMsgChannel, ClientsChannel, CommandChannel, WorkerChannel, SpawnerWorkerChannel from codes import ERROR, READY, BUSY, C...