text
stringlengths
8.04k
46.5k
import math import numbers import random import warnings import numpy as np import torch import torchvision from torchvision.transforms import functional as F # from torchvision.transforms import functional_pil as F_pil # available in future version of torchvision # from torchvision.transforms import functional_tenso...
#!/usr/bin/env python3 import sys import datetime timeout_time = 600.0 algorithms = ["se2gis", "segis", "cegis"] versions = ["all", "ini", "st", "d", "off"] fields = ["synt", "verif", "#i", "last"] show_benchmarks = [ ["tree", [ ["sumtree", ["", "sum", "no", "sum"]], ["maxtree", ["", "max", "no"...
# -*- coding: utf-8 -*- import h5py import numpy as np import fabio import os from matplotlib import cm import matplotlib.pyplot as plt import matplotlib.gridspec as gridspec import matplotlib.animation as animation import warnings from ..math.utils import logscale from ..io.spec import spec from ..utils import insta...
#!/usr/bin/env python # -*- coding: utf-8 -*- from functools import partial from objectpath.core.interpreter import * from objectpath.core import ProgrammingError, ExecutionError from random import randint, choice #from bson.objectid import ObjectId import sys, unittest, os sys.setrecursionlimit(20000) object1 = { ...
#!/bin/python3 # ultron-server-beta import socket import shutil import sys import random from datetime import datetime import threading import hashlib import os from os import scandir import time from cryptography.fernet import Fernet class colors: GREEN = '\033[92m' RED = '\033[91m' WHITE = '\033[97m' ...
import logging, sys, os from src.tokenizer import java_lexer import config.config_handler as cf logging.basicConfig( filename=os.path.join(os.path.split(sys.argv[0])[0], 'output', 'app.log'), filemode='w', format='%(name)s - %(levelname)s - %(message)s' ) class FormatterError(Exception): p...
''' root/codes/block_definitions/utilities/operators... Overview: This file has operators for PyTorch nueral network layers Rules: There are several unique features to building and then running a NN with PyTorch. It is expected that you would instantiate various nn.Module objects in the __init__ method of your graph...
# vim: set et sw=4 sts=4 fileencoding=utf-8: # # Copyright (c) 2013-2017 <NAME> <<EMAIL>> # Copyright (c) 2013 Mime Consulting Ltd. <<EMAIL>> # All rights reserved. # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to...
""" TODO description. Author: <NAME> Autonomous Systems Lab (ASL), Stanford (GitHub: spenrich) """ import jax import jax.numpy as jnp from jax.scipy.linalg import block_diag import numpy as np from functools import partial from jax.flatten_util import ravel_pytree def mat_to_svec_dim(n): """Comp...
from keras import Input, Model, Sequential from keras.layers import Flatten, Conv2D, Concatenate, Dense, Activation from keras.optimizers import Adam from rl.agents import DDPGAgent, CEMAgent from rl.memory import SequentialMemory, EpisodeParameterMemory from rl.policy import EpsGreedyQPolicy from hexagon_agent import...
# Copyright 2020 Declarative Systems Pty 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 law or agreed...
import os os.chdir("/home/tomo/densefusion") import torch import numpy as np import copy from PIL import Image from torch.autograd import Variable import pyrealsense2 as rs import cv2 from utils import posenet_deploy from lib.transformations import euler_matrix, quaternion_matrix, quaternion_from_matrix import numpy.ma...
'''Train CIFAR10 with PyTorch.''' import torch import logging import datasets import numpy as np import torch.nn as nn import torch.optim as optim import torch.nn.functional as F import torchvision from torch.optim.lr_scheduler import MultiStepLR from torch.utils.tensorboard import SummaryWriter from torchsummary impor...
#!/usr/bin/env python # -*- coding: utf-8 -*- """ # CODE NAME HERE # CODE DESCRIPTION HERE Created on 2020-05-07 @author: cook """ from astropy.io import fits from astropy.table import Table from astropy import units as uu from astropy.time import Time import numpy as np import sys import os import argparse from sci...
# -*- coding: utf-8 -*- """ A module and library that assists in organizing document data previously obtained from static files and Python module/class doc strings. This data is stored in a way that facilitates viewing documentation. As with reading in data, viewing extracted document information is documentation test...
from xml.dom import minidom from enum import Enum import numpy as np ############################################################################### # Cards # triadCardDB = [] triadCardDB_Limited = [] triadCardDB_LimitedBest = [] triadCardDB_Common = [] triadCardDB_CommonBest = [] class TriadCard: def __init__(s...
import torch from torch import nn import numpy as np from torch.utils.data import Dataset from torch.autograd import Variable from torchvision import transforms import PIL import pandas as pd from PIL import Image import torchvision.transforms as transforms from torch.utils.data import random_split from to...
# ------------------------------------------------------------------------------------------ # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License (MIT). See LICENSE in the repo root for license information. # -------------------------------------------------------------------...
from tqdm import tqdm from scoop import futures import rouge_functions from absl import flags from absl import app import convert_data import time import subprocess import itertools import glob import numpy as np import data import os import sys from collections import defaultdict import util from scipy...
# SPDX-FileCopyrightText: 2021 Division of Intelligent Medical Systems, DKFZ # SPDX-FileCopyrightText: 2021 <NAME> # SPDX-License-Identifier: MIT from typing import Tuple from simpa.log.file_logger import Logger from simpa.core.device_digital_twins import DetectionGeometryBase from simpa.utils.settings import Settings...
# 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 wr...
import renderdoc as rd import rdtest from typing import List, Tuple import time import os def srgb2linear(f): if f <= 0.04045: return f / 12.92 else: return ((f + 0.055) / 1.055) ** 2.4 def linear2srgb(f): if f <= 0.0031308: return f * 12.92 else: return 1.055 * (f **...
from __future__ import print_function, division, absolute_import __all__ = ['splrep', 'splprep', 'splev', 'splint', 'sproot', 'spalde', 'bisplrep', 'bisplev', 'insert', 'splder', 'splantider'] import warnings import numpy as np from ._fitpack_impl import bisplrep, bisplev, dblint from . import _fitpack_i...
# type: ignore """ test_cases.py Tests for Greynir module Copyright (C) 2021 <NAME>. Original author: <NAME> This software is licensed under the MIT License: Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentatio...
################################################################################ # 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...
#! /usr/bin/env python # -*- coding: utf-8 -*- # ############################################################# # # # Copyright @ 2013 - 2017 Dashingsoft corp. # # All rights reserved. # # ...
import json import logging import os import time from subprocess import DEVNULL, PIPE from typing import TYPE_CHECKING, Any, Dict, List, Optional, Set import boto3 from botocore.config import Config from botocore.exceptions import ClientError from google.api_core.exceptions import ClientError as GoogleClientError from...
# Copyright (c) 2020 PaddlePaddle 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 appli...
# Copyright (c) 2020 PaddlePaddle 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 appli...
# This file is part of Indico. # Copyright (C) 2002 - 2020 CERN # # Indico is free software; you can redistribute it and/or # modify it under the terms of the MIT License; see the # LICENSE file for more details. from __future__ import unicode_literals import itertools from enum import Enum from operator import attrg...
# 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 configparser import re import collections import pyparsing from ._common import PotentialFormSignatureTuple, \ PotentialFormTuple, \ SpeciesTuple, \ PairPotentialTuple, \ PotentialFormInstanceTuple, \ MultiRangeDefinitionTuple, \ PotentialModifierTuple, \ EAMFSDensitySpeciesTuple, \ EAMEmbedTup...
# Copyright 2015-2017 Capital One Services, 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 agreed ...
""" Twins A PyTorch impl of : `Twins: Revisiting the Design of Spatial Attention in Vision Transformers` - https://arxiv.org/pdf/2104.13840.pdf Code/weights from https://github.com/Meituan-AutoML/Twins, original copyright/license info below """ # -------------------------------------------------------- # Twins # ...
"""This package defines two classes: * `subrange` -- continuous subrange of integers as a ``min..max`` object * `subrangef` -- annotated `subrange` with reach formatting capabilities If you are new to this package, start with the `subrange`. It implements the core features of subranges:: from subrange import su...
from typing import List, Dict, TYPE_CHECKING, Optional, Union, Tuple from gym import spaces import numpy as np import pandas as pd from highway_env import utils from highway_env.envs.common.finite_mdp import compute_ttc_grid from highway_env.envs.common.graphics import EnvViewer from highway_env.road.lane import Abstr...
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # __coconut_hash__ = 0xf2dce4b8 # Compiled with Coconut version 1.2.3 [Colonel] # Coconut Header: -------------------------------------------------------- from __future__ import generator_stop import sys as _coconut_sys py_chr, py_filter, py_hex, py_input, py_int, py_ma...
import torch from torch.nn import functional as F import torch.nn as nn import math from ..model_utils.weight_process import _fill_fc_weights, _HEAD_NORM_SPECS from ..model_utils.center_based_utils import sigmoid_hm, select_point_of_interest, nms_hm, select_topk def get_channel_spec(reg_channels, name): if name =...
""" mslib.mswms.gallery_builder ~~~~~~~~~~~~~~~~~~~ This module contains functions for generating the plots.html file, aka the gallery. This file is part of mss. :copyright: Copyright 2021 <NAME> :copyright: Copyright 2021 by the mss team, see AUTHORS. :license: APACHE-2.0, see LICENSE fo...
""" Parse a Lowrance .USR file. We define a recursive data structure that defines fields. It must be traversed in order to correctly locate dependencies among field definitions. This approach will capture repeat factors and lengths. The :py:class:`Lowrance_USR` class contians the field definitions. Once loaded, it be...
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # @Author:FelixFu # @Date: 2021.12.17 # @GitHub:https://github.com/felixfu520 # @Copy From:https://github.com/Megvii-BaseDetection/YOLOX/blob/main/yolox/core/trainer.py import os import time import random import datetime import numpy as np from PIL import Image from logur...
import logging from http import HTTPStatus from typing import Any, Dict, List, Optional, Tuple, Union from uuid import uuid4 import requests from flask import current_app as app from sqlalchemy.sql.expression import and_, bindparam from lighthouse.constants.events import PLATE_EVENT_DESTINATION_CREATED, PLATE_EVENT_D...
import pickle import time import torch import torch.nn as nn import torch.nn.functional as F import numpy as np from tqdm import tqdm import Utils from deep_lagrangian_networks.replay_memory import PyTorchReplayMemory from pytorchtools import EarlyStopping class LowTri: def __init__(self, m): # Calcu...
import os import unittest from __main__ import vtk, qt, ctk, slicer from slicer.ScriptedLoadableModule import * import logging # # PyDevRemoteDebug # class PyDevRemoteDebug(ScriptedLoadableModule): """Uses ScriptedLoadableModule base class, available at: https://github.com/Slicer/Slicer/blob/master/Base/Python/sl...
""" Module for exporting and importing flopy model attributes """ import copy import shutil import json import numpy as np import os import warnings from collections import OrderedDict from ..datbase import DataType, DataInterface from ..utils import Util3d, SpatialReference # web address of spatial reference dot org...
""" Reduction routines proposed in http://theinf1.informatik.uni-jena.de/publications/wernicke-da.pdf Section 6.3.2, Page 79. All reduction routines take in and return a NetworkX Graph. Some reduction rules may add to the OCT set, in which case they will also take in and return a list oct_set. If vertices are marked...
# This code is part of Qiskit. # # (C) Copyright IBM 2020. # # This code is licensed under the Apache License, Version 2.0. You may # obtain a copy of this license in the LICENSE.txt file in the root directory # of this source tree or at http://www.apache.org/licenses/LICENSE-2.0. # # Any modifications or derivative wo...
import torch import torch.distributed as dist import numpy as np import torch import torch.nn as nn import torch.nn.functional as F import time import torch.utils.checkpoint as checkpoint import sparse import sys import os import socket import util import construct_model def hard_aggregate(V, V_up, lower=True): '...
# -*- coding: utf-8 -*- # # Licensed under the terms of the BSD 3-Clause or the CeCILL-B License # (see codraft/__init__.py for details) """ CodraFT Panel widgets (core.gui.panel) Signal and Image Panel widgets relie on components: * `ObjectProp`: widget handling signal/image properties using a guidata DataSet ...
# Python import unittest from unittest.mock import Mock # Genie from genie.metaparser.util.exceptions import SchemaEmptyParserError # iosxr show_controllers from genie.libs.parser.iosxr.show_controllers import (ShowControllersCoherentDSP, ShowControllersOptics, ...
""" The Purpose of the PrivateBinance Arbitrage Bot (based on RoibalBot) Python Program is to create an automated trading bot (functionality) on Binance Utilized Python-Binance ( https://github.com/sammchardy/python-binance ) Advanced-Version capable of all exchanges, all coins (using cctx) This 'bot' will run a ...
import logging import os import numpy as np import random import zipfile import zlib from flarestack.shared import band_mask_cache_name from flarestack.core.energy_pdf import EnergyPDF, read_e_pdf_dict from flarestack.core.time_pdf import TimePDF, read_t_pdf_dict from flarestack.core.spatial_pdf import SpatialPDF from ...
# Copyright (C) The Arvados Authors. All rights reserved. # # SPDX-License-Identifier: Apache-2.0 from __future__ import division from builtins import next from builtins import object from builtins import str from future.utils import viewvalues, viewitems import argparse import logging import os import sys import thr...
""" views.py for our content app Purpose: define the views for this app Author: <NAME> Date: Winter, 2017. Copyright: (c) 2017 <NAME>, Groja.com, and JooMoo Websites LLC. Reference: (none) """ import json import textwrap from django.contrib import messages from django.http import HttpResponse, HttpResponseRedirect...
from __future__ import unicode_literals, division, absolute_import from builtins import * # noqa pylint: disable=unused-import, redefined-builtin import logging from datetime import datetime, timedelta from sqlalchemy import Table, Column, Integer, Float, Unicode, Boolean, DateTime from sqlalchemy.ext.associationpro...
# -*- coding: utf-8 -*- # <nbformat>3.0</nbformat> # <codecell> import numpy as np import pandas as pd from scipy.optimize import fsolve import scipy.integrate as integrate # <codecell> # Thesis astrodynamics functions def FindOrbitCenter(x, y, z): # identify x-coordinate corresponding to maximum y...
import os import torch import cv2 import glob from fishnet import coco_api import ubelt as ub import pandas as pd import numpy as np import imgaug.augmenters as iaa import torch.utils.data as torch_data import torch.utils.data.sampler as torch_sampler import netharn as nh from os.path import join from netharn.models.yo...
import copy import time import torch from torch.autograd import Variable import logging from typing import Optional, List, Dict, Union import traceback from .distributed_define import BucketType from .communication import ( is_initialized, allreduce, broadcast, _get_global_state, get_bagua_hyperpara...
# -*- coding: utf-8 -*- """ GUI for 3D adaptive fractionation with minimum and maximum dose """ import tkinter as tk import numpy as np from scipy.stats import invgamma from tkinter import filedialog as fd from tkinter.messagebox import showinfo import tkinter.ttk as ttk import pandas as pd import interpol3D_tdist as ...
from typing import List, Text, Dict from dataclasses import dataclass import ssl import urllib.request from io import BytesIO from zipfile import ZipFile from urllib.parse import urljoin from logging import exception import os from re import findall from datetime import datetime, timedelta import lxml.html...
import difflib import glob import html import random import re import bz2 import io import codecs import collections import logging import numpy as np import mwparserfromhell ## Re-enable when using spacy! #import spacy #nlp = spacy.load('en_core_web_sm') # was: 'en' from tqdm import tqdm import nltk nltk.data.path....
""" Module containing utilities for the data. """ import importlib import numpy as np import scipy.stats as stats import xarray as xr import pint import warnings spec = importlib.util.find_spec('pyart') if spec is not None: PYART_AVAILABLE = True else: PYART_AVAILABLE = False try: from pkg_resources imp...
import random import sys import copy import os import pygame from pygame.locals import * from sokoban.asset import * # constants FPS = 30 # font sizes BASIC_FONT_SIZE = 18 BIG_FONT_SIZE = 100 # pixel sizes WINDOW_WIDTH = 640 WINDOW_HEIGHT = 480 WINDOW_CENTER = (int(WINDOW_WIDTH / 2), int(WINDOW_HEIGHT / 2)) # tile...
#! /usr/bin/env python # Copyright 2016 <NAME> # Apache 2.0. """This module aligns a hypothesis (CTM or text) with a reference to find the best matching sub-sequence in the reference for the hypothesis using Smith-Waterman like alignment. e.g.: align_ctm_ref.py --hyp-format=CTM --ref=data/train/text --hyp=foo/ctm...
import json from typing import Optional, Type, Union from pycc.lexer import ( Add, Assign, Char, Chr, Comma, Div, Else, Float, Id, If, Int, Lcurbrak, Lexer, Lparbrak, Mul, Mod, Num, Rcurbrak, Return, Rparbrak, Semi, Sub, Token,...
# # Copyright (c) 2018 ISP RAS (http://www.ispras.ru) # Ivannikov Institute for System Programming of the Russian Academy of Sciences # # 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 # # h...
import copy import json import logging import os.path as osp import sys from typing import Union, Dict, AnyStr, Optional, Tuple import numpy as np from pgdrive.constants import DEFAULT_AGENT, TerminationState from pgdrive.envs.base_env import BasePGDriveEnv from pgdrive.obs import LidarStateObservation, ImageStateObse...
## osu_player_stats_watcher.py ## Author: Daniel "Albinohat" Mercado ## ## This script creates a text file containing some quick user statistics to display on a Twitch stream. ## TODO ## == GUI Preparations == ## ## Update verification of config file to more strictly limit accepted values. ## ## Git Gud @ TK/Tcl (Uuu...
import logging import math from typing import List import torch from torch import nn import torch.nn.functional as F import torch.distributed as dist from cvpods.layers import ShapeSpec, batched_nms, cat from cvpods.structures import Boxes, ImageList, Instances from cvpods.utils import log_first_n from cvpods.modeling...
# This file is Copyright (c) 2020 <NAME> <<EMAIL>> # License: BSD import os from migen import * from litex.soc.interconnect.csr import * from litepcie.common import * # AXISRX128BAligner -------------------------------------------------------------------------------- class AXISRX128BAligner(Module): def __ini...
''' TO DO: * rr:language in pom * functions ''' import pandas import sys import os import shutil import go_template import json import argparse import re import pkgutil import tempfile #from mapeathor import gdrive_api import requests import copy tmpDir = tempfile.TemporaryDirectory(prefix="mapeathor").name+"...
import shutil import json import os import asyncio import signal import logging from typing import Optional, Tuple from indy import pool, wallet, did, ledger from perf_load.perf_client_msgs import ClientReady, ClientRun, ClientStop, ClientGetStat, ClientSend from perf_load.perf_clientstaistic import ClientStatistic f...
#!/usr/bin/env python # # Copyright (C) 2016 The Android Open Source Project # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless req...
import genet.utils.simplification as simplification import pytest import networkx as nx from shapely.geometry import LineString from tests.fixtures import assert_semantically_equal def assert_correct_edge_groups(edge_groups_1, edge_groups_2): assert len(edge_groups_1) == len(edge_groups_2) for edge_group_1 in...
# Copyright (c) <NAME> & <NAME>. Licensed under the Apache License 2.0. All Rights Reserved # Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved import argparse import datetime import json import os import random import time from collections import namedtuple from copy import deepcopy from functools i...
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ ;;############################################################################# ;; ;; two_legged_metric.py ;; Author: <NAME> (<EMAIL>) ;; LAPSE project, part of CSSP Brazil ;; University of Leeds, UK ;; ;;################################################################...
""" Cinema Spec D utility functions for reading and validating databases. """ import sqlite3 import os import logging as log import csv from functools import reduce import hashlib import time SPEC_D_CSV_FILENAME = "data.csv" FILE_HEADER_KEYWORD = "FILE" TYPE_INTEGER = "INTEGER" TYPE_FLOAT = "FLOAT" TYPE_STRING = "STR...
""" Implementation of Transformer Model using TensorFlow 2.0. References: <NAME> and <NAME> and <NAME> and <NAME> and <NAME> and <NAME> and <NAME> and <NAME>. "Attention Is All You Need", 2017 arXiv, URL: https://arxiv.org/abs/1706.03762 """ import os import logging try: os.environ['TF_CPP_MIN_LO...
# -*- coding: utf-8 -*- # # Copyright © 2012 <NAME> # Licensed under the terms of the MIT License # (see winpython/__init__.py for details) """ WinPython utilities Created on Tue Aug 14 14:08:40 2012 """ from __future__ import print_function import os import os.path as osp import subprocess import re import tarfile...
import copy import ethereum.opcodes as opcodes # ####### dev hack flags ############### verify_stack_after_op = False # ###################################### import sys from ethereum import utils import copy from ethereum import opcodes import time from ethereum.slogging import get_logger from rlp.utils import as...
from .common import ( Chat, BaseChatDownloader, Remapper as r, Image ) from ..utils.core import ( remove_prefixes, multi_get, seconds_to_time, camel_case_split, ensure_seconds, attempts, regex_search, base64_encode, ) from ..utils.timed_utils import interruptible_sleep f...
''' Created on Jun 24, 2017 @author: cef Library of custom hp functions for pythons builtin librarires #=============================================================================== # # PHILOSOPHY --------------------------------------------------------------- #=====================================================...
from dassl.engine import TRAINER_REGISTRY,TrainerMultiAdaptation from dassl.data import DataManager from dassl.utils import MetricMeter from torch.utils.data import Dataset as TorchDataset from dassl.optim import build_optimizer, build_lr_scheduler from dassl.utils import count_num_param import torch import torch.nn as...
#!/usr/bin/env python #!/usr/bin/env python # 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...
"""Remote worker pool module.""" import os import sys import time import signal import socket import getpass import platform import subprocess import six import itertools from schema import Or import testplan from testplan.common.utils.logger import TESTPLAN_LOGGER from testplan.common.config import ConfigOption fro...
#!/usr/bin/env python # coding: utf-8 # In[1]: import numpy as np import pickle, os, sys import matplotlib.pyplot as plt from scipy.stats import chisquare from astropy.io import ascii import time from numpy.linalg import lstsq from astropy.stats import mad_std import pickle, glob, re import numpy as np import pandas...
import time import math import ENTF ######################################### #### ECSM Implementations #### ######################################### ############################################################### #### Affine Coordinate: y^2 = x^3 + ax + b #### #### Projective ...
# MODERATION FOR TUXEDO # (c) ry000001 2017 # This code will *only* work on Tuxedo Discord bot. # This code is free and open source software. Feel free to leak. import discord from discord.ext import commands from discord import utils as dutils from utils import switches from utils import permissions import asyncio imp...
import collections.abc as collections_abc import inspect import warnings from abc import ABC, abstractmethod from dataclasses import dataclass, fields, is_dataclass from datetime import date, datetime from enum import Enum, IntEnum from typing import Any, Dict, List, Mapping, Optional, Tuple, Type, Union from typing im...
import pytest import json import numpy as np from keras.layers import Dense, Dropout, InputLayer from keras.engine import merge, Input, get_source_inputs from keras.models import Model, Sequential from keras import backend as K from keras.models import model_from_json, model_from_yaml from keras.utils.test_ut...
"""STOCHASTIC ROSS Module. This module creates random rotor instances and run stochastic analysis. """ # fmt: off from collections.abc import Iterable import numpy as np from ross.rotor_assembly import Rotor from ross.stochastic.st_bearing_seal_element import ST_BearingElement from ross.stochastic.st_disk_element im...
import os import shutil import warnings import subprocess import torch import atomium import tempfile import numpy as np import pandas as pd import concurrent.futures from Bio.SeqUtils import seq1 from transformers import logging logging.set_verbosity_warning() from rossmann_toolbox.utils import postprocess_crf, corr...
""" Author: <NAME> Department of Psychiatry, University of Arizona Correspondance: <EMAIL> This script runs the Active Maintenance Offloading Task investigating the combined effect of peer influence and visual working memory capacity on delayed visual discrimination. """ from psychopy.visual import * from ...
from __future__ import division from __future__ import print_function # -*- coding: utf-8 -*- # Copyright 2020 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License") # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.a...
# -*- coding: utf-8 -*- """ Classes for representing individual constraints. """ from __future__ import division from __future__ import print_function from __future__ import absolute_import import datetime import json import os import re import sys from collections import OrderedDict PRECISIONS = ('open', 'closed',...
import numpy as np import lib.utils as utils import tensorflow as tf import sys import math import scipy import scipy.io import logging class Params: """Parameters for DMF """ def __init__(self): self.a = 1 self.b = 0.01 self.lambda_u = 0.1 self.lambda_v = 10 self.la...
# import sys # sys.path.append(r'/home/felix/git/gym-jsbsim-eee/') #TODO: Is this a good idea? Dunno! It works! import gym import numpy as np import math import os import json import pickle from collections import namedtuple import types from typing import Type, Tuple, Dict, List, Sequence, NamedTuple, O...
################################################################################ # # MIT License # # Copyright (c) 2020-2021 Advanced Micro Devices, Inc. # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to dea...
# -*- coding: utf-8 -*- """ Created on Fri Jul 3 09:45:58 2020 @author: Bry #module containing several functions created to simulate and modelate the gen expression of cell populations FUNCTIONS: 1) HOGexpr: Computes the input system in pulses shape. 2) simbODE: Determines simbolic ODEs tha...
''' This module provides the API for usage in custom openCypher procedures. ''' # C API using `mgp_memory` is not exposed in Python, instead the usage of such # API is hidden behind Python API. Any function requiring an instance of # `mgp_memory` should go through a `ProcCtx` instance. # # `mgp_value` does not exist a...