text
stringlengths
8.04k
46.5k
# uncompyle6 version 3.7.4 # Python bytecode 3.7 (3394) # Decompiled from: Python 3.7.9 (tags/v3.7.9:13c94747c7, Aug 17 2020, 18:58:18) [MSC v.1900 64 bit (AMD64)] # Embedded file name: T:\InGame\Gameplay\Scripts\Server\objects\collection_manager.py # Compiled at: 2020-09-30 01:16:20 # Size of source mod 2**32: 38593 b...
from __future__ import print_function import os import pickle from functools import partial import cv2 import lmdb import matplotlib.pyplot as plt import numpy as np from mpl_toolkits.mplot3d import Axes3D from tqdm import tqdm import config_rf as cfg import config_rf as config from helpers.util import ensure_dir "...
""" File containing functions for plotting and calculating performance statistics """ import pandas as pd, numpy as np import matplotlib as mpl import matplotlib.pyplot as plt import seaborn as sn from matplotlib.ticker import MaxNLocator import os # Plot styling # mpl.rcParams['pdf.fonttype'] = 42 # sn.set_context('n...
import torch import torch.nn.functional as F import torch.utils.data as Data import argparse import numpy as np from pathlib import Path import json from transformers import BertForSequenceClassification from run_glue import basic_train from torch.utils.data import TensorDataset, DataLoader, RandomSampler, SequentialSa...
# -*- coding: utf-8 -*- """ Created on Tue Jan 12 12:47:32 2021 @author: ASUS """ import os from conv import * from relu import * from fc import * from Activation_Softmax import Activation_Softmax from loss import * from maxpool import * from Optimizernp import * import cv2 from einops import rearrange, reduce, repea...
import operator from enum import Enum from typing import Iterable import wx import wx.grid class Position(Enum): LEAD_ENGINEER = 0 SENIOR_RESEARCHER = 1 LEAD_RESEARCHER = 2 SECTOR_HEAD = 3 DEP_HEAD = 4 COMPLEX_HEAD = 5 DIRECTOR = 6 class Degree(Enum): SPECIALIST =...
'''The datasets module contains functions related to organizing datasets. ''' import numpy as np import random import collections import math import pathlib from scipy.io.wavfile import write, read from scipy.signal import resample import soundfile as sf import librosa import os, sys import inspect currentdir = os.pa...
import logging import os import time from dataclasses import dataclass from typing import Optional from wrapless import Device, decode_u32, FingerDetectionOperation from protocol import USBProtocol from tool import decode_image, write_pgm from Crypto.Hash import SHA256 VALID_FIRMWARE: str = "GF5288_HTSEC_APP_10020" ...
#!/usr/bin/python # -*- coding: UTF-8 -*- import sys import math import time import json import pigpio import urllib import random import datetime import threading import SocketServer import os from ButtonController import ButtonController from AlarmScriptController import AlarmScriptController from SpeakMessageCont...
import torch import torch.nn as nn import torch.nn.functional as F import torchvision import numpy as np from torch import optim import os import math import cv2 import albumentations as A from torch.utils.tensorboard import SummaryWriter activation_fn = nn.ELU() MAX_DEPTH = 81 DEPTH_OFFSET = 0.1 # T...
"""This contains tasks to be run using Django Q and Redis.""" # Import the shepherd application's models and settings from django.db.models import Q from django.conf import settings from django.core.files import File # from reporting.models import Report, Archive from .models import (Domain, History, DomainStatus, Hea...
""" Plot statistical distributions from the transaction graph. """ import os import sys import csv import json from collections import Counter, defaultdict import networkx as nx import powerlaw from datetime import datetime, timedelta import numpy as np import matplotlib import matplotlib.pyplot as plt import warning...
import struct import math import numpy as np import datetime import matplotlib.pyplot as plt import math import time import queue import threading import multiprocessing from mpl_toolkits import mplot3d from matplotlib.animation import FuncAnimation import sqlite3 import pandas as pd import sys sp = sys.platform if (s...
# import glob import re import numpy as np import os.path as osp from PIL import Image import random import struct from torch.utils import data import scipy.ndimage as ndimage import cv2 from skimage.measure import block_reduce import h5py import scipy.ndimage as ndimage import torch from tqdm import tqdm import torch...
import os import disnake from disnake.ext import commands, tasks from dotenv import load_dotenv from techTreeInfo import * class TechListCommand(commands.Cog): def __init__(self, bot: commands.Bot): self.bot = bot @commands.command(name="!units", aliases=["!unitlist", "!unit"], help="Returns an alp...
""" Implements some of the functionality of the DATAQ DI-2008 data acquisition module. """ from datetime import datetime, timedelta from enum import Enum import logging import threading from time import sleep from typing import List from serial import Serial from serial.tools import list_ports from serial.serialutil ...
# -*- coding: utf-8 -*- """MatConvNet Importer module The module contains methods to convert MatConvNet models (stored in the `dagnn` formats) into PyTorch models. The model conversion consists of two stages: (1) source code generation - a python file is generated containing the the network definition (2) st...
import csv import os import pickle import time import numpy as np import pandas as pd import torch import yaml from sklearn.metrics import roc_auc_score from sklearn.model_selection import KFold from result_analysis import make_and_write_catted_data from utils.BaselineParamsParser import BaselineParamsParser from bas...
#misc import numpy as np from collections import defaultdict import sys import random from tqdm import trange #torch import torch import torch.nn as nn import torch.nn.functional as F from torch import optim device = torch.device("cuda:0" if torch.cuda.is_available() else "cpu") #network and utility from solutions.ne...
#!/usr/bin/env python # -*- coding: utf-8 -*- from collections import namedtuple from copy import copy from functools import partial from operator import attrgetter import re try: from PyQt5 import QtGui, QtCore, QtWidgets # start qapplication app = QtWidgets.QApplication([]) except ImportError: from P...
#!/usr/bin/env python # -*- encoding: utf-8 -*- ''' @File : initialization.py @Time : 2021/12/11 17:21:18 @Author : <NAME> @Version : 1.0 @Desc : initialization class and function ''' #%% import import pandas as pd import numpy as np import matplotlib.pyplot as plt import scipy.io import timeit...
""" modeling """ from __future__ import absolute_import from __future__ import division from __future__ import print_function import os import time import shutil import numpy as np import tensorflow as tf from tensorflow.contrib import rnn from tensorflow.contrib import layers from utils import Norm class RNN_WGAN(o...
""" minecraftinstall """ from __future__ import absolute_import, division, print_function import hashlib import json import re import zipfile import time from PySide import QtGui, QtCore, QtNetwork import logging import os from PySide.QtCore import Qt from mcedit2.resourceloader import ResourceLoader from mcedit2....
''' Copyright [2020] Hahn-Schickard-Gesellschaft für angewandte Forschung e.V., <NAME> + <NAME> Copyright [2021] Karlsruhe Institute of Technology, <NAME> SPDX-License-Identifier: Apache-2.0 ============================================================================================================''' import s...
# this file contains the two fundamental class types (Trial and Experiment) needed to construct an experiment in packerlabimaging from __future__ import absolute_import from dataclasses import dataclass, field from typing import Optional, MutableMapping, Union, TypedDict, List, Dict, Any import numpy as np import pand...
# -*- coding: utf-8 -*- """ Utilities """ def shn_sessions(): """ Extend session to support: Multiple flash classes Settings Debug mode Security mode Restricted mode Theme Audit modes """ re...
import asyncio import uuid import traceback import jsonpickle from timeit import default_timer as timer from typing import List import logging from audioled import modulation from audioled import devices from audioled import effect from audioled import colors logger = logging.getLogger(__name__) class NodeException...
# Licensed under a MIT style license - see LICENSE """MUSE-PHANGS core module. This defines the main class (MusePipe) which can be used throughout this package. This module is a complete rewrite of a pipeline wrapper for the MUSE dataset. All classes and objects were refactored. However, the starting point of this p...
#!/bin/python3 import re import math import sys import time import numpy as np import o80 import franka_o80 def strtod(s, pos): m = re.match(r'[+-]?\d*[.]?\d*(?:[eE][+-]?\d+)?', s[pos:]) if m.group(0) == '': return 0, pos return float(m.group(0)), pos + m.end() def quaternion_multiply(quaternion1, quater...
import copy from liegroups import SO3, SE3 import transforms3d as tf3d from transforms3d.quaternions import mat2quat from numpy.linalg import lstsq import numpy as np TASK_DIM = 6 JOINT_NAMES = 1 JOINT_ACTIVE = 3 LINK_NAMES = 12 ZERO_DISP = [0, 0, 0] POS = range(0, 3) ROT = range(3, 6) KI = .01 # originally from ht...
# This file is the newest version of the program dedicated to preproces the raw typing dataset # Compared to the orgiginal version the following modifcations have been taken into account: ## We no longer need the function mark_entries ## We include native speakers in the dataset ## We keep punctuations in the dataset...
import pandas as pd import numpy as np import networkx as nx import matplotlib.pyplot as plt import random from math import sqrt from datetime import datetime,timedelta from pytz import timezone from time import time from collections import deque from IPython.display import clear_output from statsmodels.tools.eval_mea...
# Debian packaging tools: Trivial repository management. # # Author: <NAME> <<EMAIL>> # Last Change: April 18, 2020 # URL: https://github.com/xolox/python-deb-pkg-tools """ Create, update and activate trivial Debian package repositories. The functions in the :mod:`deb_pkg_tools.repo` module make it possible to transf...
from math import sqrt, pi import numpy as np from scipy.special import jv, struve from pulse.preprocessing.perforated_plate import Foks_function from pulse.preprocessing.node import distance DOF_PER_NODE = 1 NODES_PER_ELEMENT = 2 DOF_PER_ELEMENT = DOF_PER_NODE * NODES_PER_ELEMENT ENTRIES_PER_ELEMENT = DOF_PER_ELEMENT ...
import numpy as np import pandas as pd import sys from . import util from . import structs DEFAULT_CONFIG = { # For some price at date t, what difference must be exceeded between p_t-1 and p_t+1 # with respsect to p_t for t to be considered pivot "pivot_seperation_threshold": lambda candles: util.avg_candle_ran...
import cv2 import numpy as np from numpy.linalg import norm import os import json SZ = 20 PROVINCE_START = 1000 MAX_WIDTH = 2000 def point_limit(point): if point[0] < 0: point[0] = 0 if point[1] < 0: point[1] = 0 def deskew(img): m = cv2.moments(img) if abs(m['mu02']) < 1e-2: ...
import itertools import logging import os import wx from vistas.core.graphics.flythrough import Flythrough from vistas.core.graphics.scene import Scene from vistas.core.plugins.management import get_data_plugins, get_visualization_plugins, get_2d_visualization_plugins from vistas.core.plugins.visualization import Vis...
# -*- coding: utf-8 -*- from __future__ import unicode_literals import collections import re import unittest from datetime import date, datetime from decimal import Decimal from functools import partial, wraps import valideero as V from valideero.compat import long, xrange, string_types, int_types, text_type, binary_...
import json import random from collections import OrderedDict, Counter from itertools import groupby import copy import pandas as pd from django.shortcuts import render from django.db.models import Count from django.db.models.functions import Concat from django.http import JsonResponse from django.core.exceptions impo...
# pylint: disable=invalid-name """Module for symbolically finding python entities in python source code given their name. A thing in python can get its name in various ways: - it's defined as a function - it's defined as a class - it's assigned - it is imported - it's created in a with statement - it's created ...
#!/usr/bin/env python # -*- coding: utf-8 -*- """ @Author: <NAME> @Contact: <EMAIL> @File: main.py """ from __future__ import print_function import os import argparse import torch import torch.nn as nn import torch.nn.functional as F import torch.optim as optim from torch.optim.lr_scheduler import CosineAnnealingLR, ...
import copy import uuid from typing import Union from stepist.flow.steps.next_step import call_next_step as stepist_next_step from stepist.flow.utils import validate_handler_data from stairs.core.pipeline.pipeline_objects import (PipelineFlow, PipelineFlowProducer, ...
import argparse import tensorflow as tf from tensorflow.keras import layers, regularizers import numpy as np import matplotlib.pyplot as plt import tracks from tensorflow.keras.optimizers import Adam from VAE import VariationalAutoEncoder import os # The actor choose the move, given the state def get_ac...
#!/usr/bin/env python # -*- encoding: utf-8 -*- # <NAME>, <EMAIL> ''' Summary ------- Exports and converts *waf* project data, for C/C++ programs, static- and shared libraries, into **Code::Blocks** project files (.cbp) and workspaces (codeblock.workspace). **Code::Blocks** is an open source integrated deve...
import os # os.environ['TF_CPP_MIN_LOG_LEVEL']='3' from datasets.Dataset import TRAIN_LOOP, TRAIN, VALIDATION, TEST, \ TRAIN_SHUFFLED import tensorflow as tf import tensorflow_probability as tfp from argo.core.TFDeepLearningModel import load_model_without_session from argo.core.optimizers.LearningR...
from anynet import tls, util, xml, scheduler from multidict import MultiDict, CIMultiDict import urllib.parse import contextlib import datetime import anyio import json import logging logger = logging.getLogger(__name__) STATUS_NAMES = { 100: "Continue", 101: "Switching Protocols", 102: "Processing", 103: "Earl...
import warnings import matplotlib.pyplot as plt import matplotlib.patches as mpatches import numpy as np import pandas as pd import seaborn as sns from bdpy.fig import box_off def makeplots( df, x=None, y=None, x_list=None, subplot=None, subplot_list=None, figure=None, figur...
"""Admin definition for Smart Grid Game widget.""" from django.db import models from django.http import HttpResponseRedirect from django.shortcuts import render_to_response from django.template import RequestContext import markdown from apps.managers.cache_mgr import cache_mgr from apps.managers.challenge_mgr import ch...
# Copyright (c) 2015-2016, Danish Geodata Agency <<EMAIL>> # Copyright (c) 2016, Danish Agency for Data Supply and Efficiency <<EMAIL>> # # Permission to use, copy, modify, and/or distribute this software for any # purpose with or without fee is hereby granted, provided that the above # copyright notice and this p...
""" ========= structure ========= """ import numpy as np from pandas import DataFrame from javelin.unitcell import UnitCell from javelin.utils import (get_atomic_number_symbol, is_structure, get_unitcell, get_positions, get_atomic_numbers) class Structure: """The structure class is ma...
from typing import Tuple, List, Optional, Dict import sqlparse.sql from sqlparse.sql import IdentifierList, Identifier, Where, Parenthesis, TokenList, Function, Case, Operation import sqlparse.tokens from sqlparse.tokens import Keyword, DML, CTE, Whitespace, Newline, Punctuation, Number, Literal, Comment, Name, Operato...
import importlib import logging import math import os from collections import OrderedDict import numpy import tensorflow as tf from neurst.utils.compat import wrapper_var_name from neurst.utils.configurable import ModelConfigs enc_layer_mapping_dict = OrderedDict( { "multihead_norm_scale": "self_attentio...
from __future__ import annotations import numpy as np # type: ignore import numbers from collections.abc import Sequence from .np_array import NumpyArray from .time import TimeIndex, convert_string_to_seconds from itertools import compress from .timeseries_collection import TimeSeriesCollection from .time_chunk import...
import h5py import parmap import numpy as np import scipy.io as sio import os from tqdm import tqdm import scipy import scipy.io import scipy.optimize as opt from scipy.spatial.distance import cdist from scipy.ndimage import gaussian_filter import networkx as nx from pkg_resources import resource_filename from yass im...
import copy import io import os import sys import threading import time import traceback from time import sleep, perf_counter from threadpoolctl import threadpool_limits from typing import Callable from ..basic_typing import Batch import logging import numpy as np from queue import Queue as ThreadQueue, Empty # Mak...
# MIT License # # Copyright (c) 2020 Espressif Systems (Shanghai) Co. Ltd. # # 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 # ...
# !/usr/bin/env python3 # -*- coding: utf-8 -*- from transformers import BertConfig, BertForSequenceClassification, BertTokenizer from transformers import RobertaConfig, RobertaForSequenceClassification, RobertaTokenizer from transformers import AdamW, get_linear_schedule_with_warmup from data_utils import * import o...
# coding=utf-8 import os import sys import yaml import tempfile from bzt.engine import ScenarioExecutor, Configuration from bzt.jmx2yaml import JMX2YAML from bzt.utils import get_full_path, FileReader from tests import BZTestCase, RESOURCES_DIR class FakeOptions(object): def __init__(self, verbose=True, file_na...
try: import h5py except ImportError as ex: import warnings warnings.warn("could not load h5py, hdf5 files not supported", ImportWarning) h5py = None import numpy import pickle import os.path import sys from amuse.units import si from amuse.units import units from amuse.units import core from amuse...
# Copyright 2016 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, ...
# virial.py import matplotlib.pyplot as plt import numpy as np import yt import yt.units as yu import pandas as pd import astropy.units as au import astropy.constants as ac from ..load_sim import LoadSim # Static variable decorator def static_vars(**kwargs): def decorate(func): for k in kwargs: ...
""" Generic file input module, used in Phenix GUI and elsewhere. This trades some loss of efficiency for a simplified API for loading any file type more or less automatically. It will first try to guess the format based on the extension; if this fails, it will then try other formats. This is used on the command line...
from . import axis_instance from .._utilities import helper_functions import numpy as np import vispy.scene as vpscene import vispy.util as vputil class Camera_2D(vpscene.PanZoomCamera): def __init__(self, *args, **kwargs): self.movement_occurred = False self.resize_occurred = False ...
import unittest from sympy import sqrt, exp, I, pi, IndexedBase, symbols, factorial from qnet.algebra.core.abstract_algebra import _apply_rules from qnet.algebra.core.scalar_algebra import ( ScalarValue, KroneckerDelta, Zero, One) from qnet.algebra.toolbox.core import temporary_rules from qnet.algebra.core.operat...
""" script to carry out flare finding in Kepler LC's """ import pandas as pd import numpy as np import time as clock import datetime import glob import os.path import json import helper as help from version import __version__ from aflare import aflare1 import detrend from fake import ed6890, FlareSt...
from __future__ import print_function import sys, re, shutil, os def build_regex(repls): regex_els = [] for k in repls.keys(): if k.startswith('.'): regex_els.append( "%s\\b" % re.escape(k) ) elif k.endswith('_'): regex_els.append( "\\b%s" % re.escape(k) ) else: ...
# Copyright (c) 2018 MetPy Developers. # Distributed under the terms of the BSD 3-Clause License. # SPDX-License-Identifier: BSD-3-Clause """Test the operation of MetPy's XArray accessors.""" from __future__ import absolute_import from collections import OrderedDict import cartopy.crs as ccrs import numpy as np impor...
# Copyright (C) 2019 The Raphielscape Company LLC. # # Licensed under the Raphielscape Public License, Version 1.c (the "License"); # you may not use this file except in compliance with the License. # """ Userbot module containing various scrapers. """ import json import os import re import shutil import ti...
# coding=utf-8 # Copyright 2020 The Google Research 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 applicab...
# -*- coding: utf-8 -*- """ :Author: <NAME> <NAME> :Date: 2018. 7. 18 """ import os import platform import sys from copy import deepcopy as dc from datetime import datetime from warnings import warn import matplotlib import matplotlib.pyplot as plt import numpy as np import pandas as pd import pandas.core.com...
""" pysteps.io.exporters ==================== Methods for exporting forecasts of 2d precipitation fields into various file formats. Each exporter method in this module has its own initialization function that implements the following interface:: initialize_forecast_exporter_xxx(outpath, outfnprefix, startdate, tim...
import base64 import copy import logging import os import sys import time from cryptography.hazmat.backends import default_backend from cryptography.hazmat.primitives.ciphers import Cipher, algorithms, modes from .exceptions import * from .extendeddoubleratchet import make as make_ExtendedDoubleRatchet from .x3dhdoub...
import asyncio, discord, time, parsedatetime from discord.ext import commands from datetime import datetime from Cogs import Utils, DisplayName, ReadableTime def setup(bot): # Add the bot and deps settings = bot.get_cog("Settings") bot.add_cog(Mute(bot, settings)) class Mute(commands.Cog): ...
############################################################################### # ProteusLib Copyright (c) 2021, The Regents of the University of California, # through Lawrence Berkeley National Laboratory, Oak Ridge National # Laboratory, National Renewable Energy Laboratory, and National Energy # Technology Laborator...
from queue import Queue from collections import defaultdict from functools import partial, wraps import inspect import math import multiprocessing import itertools import os.path import platform import posixpath import re import types import orjson import pathos.pools from tqdm import tqdm import google.cloud.storage...
# SPDX-License-Identifier: BSD-3-Clause AND Apache-2.0 # Copyright 2018 Regents of the University of California # 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 2019 The Bazel 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 applicable la...
#coding:utf-8 # Copyright (c) 2019 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 req...
"""Utility classes and methods. Author: <NAME> (<EMAIL>) """ import logging import os import queue import re import shutil import string import torch import torch.nn.functional as F import torch.utils.data as data import tqdm import numpy as np import ujson as json from collections import Counter class SQuAD(da...
#!/usr/bin/env python # Copyright 2014 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. """Generates build.ninja that will build GN.""" import contextlib import errno import optparse import os import platform import re imp...
""" """ import asyncio import sys import logging import re import typing import pathlib import discord import discord.http as dhttp import pathlib import urllib.parse, urllib.request from . import factories as facts from . import state as dstate, callbacks, websocket class BackendState(typing.NamedTuple): mess...
# Copyright 2017 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing,...
# GPU import os os.environ["CUDA_VISIBLE_DEVICES"] = "0" import torch device = torch.device("cuda") # Main imports import collections import en_core_web_md import itertools import numpy as np import os import random import re import spacy import sys import time # Extern imports sys.path.append('sears') # noqa from...
import pygame import random from random import randint #============================================================================================================= NEGRO = ( 0, 0, 0) BLANCO = ( 255, 255, 255) AZUL = ( 0, 0, 255) ROJO = ( 255, 0, 0) VERDE = ( 0, 255, 0) var_global = 0...
# $Id$ # # Copyright (C) 2003-2006 <NAME> and Rational Discovery LLC # # @@ All Rights Reserved @@ # This file is part of the RDKit. # The contents are covered by the terms of the BSD license # which is included in the file license.txt, found at the root # of the RDKit source tree. # """ Calculation of topologica...
# https://www.kaggle.com/dlarionov/feature-engineering-xgboost/ import time import pickle import gc import sys from xgboost import plot_importance from xgboost import XGBRegressor import matplotlib.pyplot as plt import seaborn as sns from sklearn.preprocessing import LabelEncoder from itertools import product import n...
#!/usr/bin/env python3 from sklearn.preprocessing import StandardScaler from sklearn.linear_model import Ridge, Lasso import pickle import os import yaml import numpy as np import scipy.signal as signal import pandas as pd from scipy.stats import pearsonr from datetime import datetime from urllib import request from p...
#Module to define periodic subsystems # <NAME> from qsome import cluster_subsystem, subsystem class PeriodicEnvSubSystem(cluster_subsystem.ClusterEnvSubSystem): """ A base subsystem object for use in periodic projection embedding. """ def __init__(self, cell, env_method, kpoints=None, filename=None, ...
# -*- coding: utf-8 -*- from __future__ import unicode_literals import os import pkg_resources import platform import re import shutil import stat import subprocess import sys import tempfile import tokenize import json import time try: {}.iteritems iteritems = lambda x: x.iteritems() iterkeys = lambda x:...
import sublime import sublime_plugin import subprocess import os import platform import re import copy from .json_file import JsonFile SETTINGS_FILENAME = 'project_manager.sublime-settings' pm_settings = None def preferences_migrator(): projects_path = pm_settings.get("projects_path", []) if pm_settings.g...
# Authors: <NAME> <<EMAIL>> # # License: BSD (3-clause) import os.path as op import pytest import numpy as np from numpy.testing import assert_array_equal, assert_allclose, assert_equal from mne import io, pick_types from mne.fixes import einsum from mne.utils import requires_version, run_tests_if_main from mne.deco...
from numpy import all, any, array, arctan2, cos, sin, exp, dot, log, logical_and, roll, sqrt, stack, trace, unravel_index, pi, deg2rad, rad2deg, where, zeros, floor, full, nan, isnan, round, float32 from numpy.linalg import det, lstsq, norm from cv2 import resize, GaussianBlur, subtract, KeyPoint, INTER_LINEAR, INTER_N...
# -*- coding: utf-8 -*- import os import uuid import re import pickle import urllib import glob from gluon.admin import app_create, plugin_install from gluon.fileutils import abspath, read_file, write_file def reset(session): session.app = { 'name': '', 'params': [('title', 'My New App'), ...
# -*- encoding: utf-8 -*- ############################################################################## # # OpenERP, Open Source Management Solution # Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>). # # This program is free software: you can redistribute it and/or modify # it under the terms of the G...
# -*- coding: utf-8 -*- """ Created on Mon Oct 05 14:45:48 2015 @author: ryan """ import config as cfg import datamapfunctions as dmf import util import pandas as pd import pytz import datetime as DT # PyCharm complains about dateutil not being listed in the project requirements, but my understanding is that # it is ...
# coding: utf-8 """Test the contents webservice API.""" from contextlib import contextmanager from functools import partial import io import json import os import shutil from unicodedata import normalize pjoin = os.path.join import requests from ..filecheckpoints import GenericFileCheckpoints from traitlets.config...
#!/usr/bin/env python2 import json import os import csv from collections import defaultdict from datetime import datetime import glob import copy import string import shutil def write_html(in_file_name, out_file_name): input_file = open(in_file_name, 'r') output_file = open(out_file_name, 'w+') ...
import argh import os import json import re import subprocess import tempfile import sys import shutil import contextlib import logging import random import time import gzip import io import tarfile import threading import fnmatch import socket import ssl from datetime import datetime from hashlib import sha1 from path...
import warnings import numpy as np import theano import theano.tensor as tt import pymc3 as pm from .updates import adam from ..distributions.dist_math import rho2sd, log_normal from ..model import modelcontext, ArrayOrdering from ..theanof import tt_rng, memoize, change_flags, GradScale __all__ = [ 'ObjectiveFu...
# -*- coding: utf-8 -*- # # python-json-patch - An implementation of the JSON Patch format # https://github.com/stefankoegl/python-json-patch # # Copyright (c) 2011 <NAME> <<EMAIL>> # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that ...