text stringlengths 8.04k 46.5k |
|---|
#!/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.0OA
#
# Authors:
# - <NAME>, <<EMAIL>>, 2019 - 2020
"""
SQLAlchemy models fo... |
# multivariate multihead multistep
from keras.layers import Flatten
from keras.layers import ConvLSTM2D
from keras.layers.merge import concatenate
from numpy import array
from numpy import hstack
from keras.models import Model
from keras.layers import Input
from keras.layers import Dense
from keras.layers import Reshap... |
#!/usr/bin/env python3
import collections
import functools
import importlib
import multiprocessing
import os
import sys
import json
import qtutil
from PyQt4.QtCore import *
from PyQt4.QtGui import *
from PyQt4.QtGui import QApplication
from datadialog import DataDialog
from pipeconf import PipeconfDialog, PipelineMod... |
"""
Adapter finding and trimming classes
The ...Adapter classes are responsible for finding adapters.
The ...Match classes trim the reads.
"""
import logging
from enum import Enum
from collections import defaultdict
from . import align
logger = logging.getLogger()
class Where(Enum):
# Constants for the Aligner... |
import contextlib
import itertools
import math
import operator
import random
import sys
import time
import warnings
from collections.abc import MutableSet
from functools import reduce
from numbers import Number
import matplotlib.pyplot as plt
import numpy as np
import seaborn as sns
import torch
from matplotlib.cbook ... |
import os,sys
import shutil
import natsort
import threading
import posixpath
from .drives import get_drives
import stat
import traceback
import time
import calendar
from fnmatch import fnmatch
from collections import defaultdict
# for windows, the dummy path lists all available drive letters
if sys.platform == "win32... |
#!/usr/bin/python
from __future__ import (absolute_import, division, print_function)
# Copyright 2019 Fortinet, Inc.
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the Lic... |
#!/usr/bin/python
# Classification (U)
"""Program: merge_repo.py
Description: Merge a non-local Git repository into an existing local and
remote Git repository. The merge process will clean up the non-local
Git repository of dirty and untracked files by either reverting or
commiting the... |
#!/usr/bin/env python
import logging
import os
import importlib
import sys
import pickle
import numpy as np
import pandas as pd
from keras.callbacks import ModelCheckpoint, LearningRateScheduler
from keras.models import load_model
from scipy.stats import spearmanr
from keras.layers import Input
import tensorflow as tf... |
# Copyright(c) 2019-2020 Association of Universities for Research in Astronomy, Inc.
#
# astromodels.py
#
# This module contains classes and function to interface with the
# astropy.modeling module.
#
# New Model classes to aid with image transformations:
# Pix2Sky: allows modification of a WCS object as a FittableMode... |
from abc import ABC, abstractmethod
from enum import Enum, auto
from typing import Dict, List, Union, cast, Any, Optional, Tuple, TYPE_CHECKING, Callable
try:
from typing import Literal
except ImportError: # py<3.8
from typing_extensions import Literal
from .util import DefaultEnum, list_get
from .validators... |
"""Tests for legendre module.
"""
import numpy as np
import numpy.polynomial.legendre as leg
import numpy.polynomial.polynomial as poly
from numpy.testing import *
P0 = np.array([ 1])
P1 = np.array([ 0, 1])
P2 = np.array([-1, 0, 3])/2
P3 = np.array([ 0, -3, 0, 5])/2
P4 = np.array([ 3, 0, -30, 0, 35... |
from keras.preprocessing.image import *
from keras.applications.imagenet_utils import preprocess_input
from keras import backend as K
from PIL import Image
import numpy as np
import os
#import cv2
def center_crop(x, center_crop_size, data_format, **kwargs):
if data_format == 'channels_first':
centerh, cen... |
"""Project module."""
####################################################################################################
# IMPORTS ################################################################################ IMPORTS #
###############################################################################################... |
# UQpy is distributed under the MIT license.
#
# Copyright (C) 2018 -- <NAME>
#
# 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 t... |
"""This is the main file that handles the working of the individual modules
by using them in a proper sequence . It is responsible for all the GUI operations
and acts as a bridge between the __GA__ modules and the geometry modules"""
from root_folder.program_data.variable_parameters_data.vector_parameters import Vect... |
# -*- coding: utf-8 -*-
"""
Created on Thu Mar 11 22:14:51 2021
@author: Allectus
"""
import os
import re
import copy
import pandas as pd
import tkinter as tk
import plotly.io as pio
import plotly.express as px
from tkinter import filedialog
from lxml import etree
#=================================================... |
"""
This was the original implementation of the GUI.
It doesn't allow for multiple ROIs to be selected.
It is in an unfinished and unknown state.
"""
import os
import math
import time
import numpy as np
from msl.qt import (
utils,
QtCore,
QtGui,
QtWidgets,
prompt,
Thread,
Worker
)
from oc... |
# Copyright (c) Facebook, Inc. and its affiliates.
# Copyright (c) 2020, <NAME> (@e-bug).
# This source code is licensed under the MIT license found in the
# LICENSE file in the root directory of this source tree.
import os
import logging
import jsonlines
import _pickle as cPickle
import base64
import numpy as np
im... |
import json
from flask import Flask
from flask import request
# import tensorflow as tf
# from bert import modeling
# from bert import optimization
# from bert import tokenization
import est_cls
from loader import create_session
from loader_seq import create_seq_session
from loader import string_tokenizer
from loader_s... |
#!/usr/bin/env python3
# Copyright 2019 <NAME>
#
# 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 agree... |
# (c) 2021 <NAME>
############################################################################
# robosoc2d states log player
############################################################################
import os
import math
import tkinter as tk
from tkinter import font as tkfont
from tkinter import filedialog
import ... |
import lark
import logging
import pprint
import stix2
from stix2generator.exceptions import (
CircularVariableDependenciesError, LanguageError, RedeclaredVariableError,
UndeclaredVariableError
)
from stix2generator.utils import (
is_token, is_tree
)
import stix2generator.generation.semantics
import stix2ge... |
# Software License Agreement (BSD License)
#
# Copyright (c) 2012, Fraunhofer FKIE/US, <NAME>
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
# are met:
#
# * Redistributions of source code must retain th... |
#
# Copyright 2018 Analytics Zoo 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... |
from copy import deepcopy
import math
import numpy as np
import pandas as pd
from torch.autograd import Variable
import torch as th
from types import SimpleNamespace as SN
from .transforms import TRANSFORMS, _has_gradient, _onehot
from .scheme import Scheme
def is_iterable(obj):
try:
iter(obj)
re... |
from universal_tools import return_data,delete_row,return_column,add_row,search_for, edit_row,check_file
from management import RadioManager,EmptyObject
from playlist import Playlist
import management
import tkinter as tk
from tkinter import ttk
import time
from PIL import ImageTk, Image
from tkinter import... |
#!/usr/bin/python
# Wflow is Free software, see below:
#
# Copyright (c) <NAME>/Deltares 2005-2014
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at you... |
"""
Capstone Project. Code to run on a LAPTOP (NOT the robot).
Constructs and returns Frame objects for the basics:
-- teleoperation
-- arm movement
-- stopping the robot program
This code is SHARED by all team members. It contains both:
-- High-level, general-purpose methods for a Snatch3r EV3 robot... |
from enum import Enum
from operator import itemgetter
from typing import List, Optional, TYPE_CHECKING, Union
from pandas.core.frame import DataFrame
import requests
from tqdm.auto import tqdm
from mstrio import config
from mstrio.api import cubes, datasets
from mstrio.project_objects.datasets import cube_cache
from ... |
import asyncio
import collections
import contextlib
import enum
import json
import logging
import operator
import random
import re
from datetime import datetime, timedelta
from functools import partial, reduce
import discord
from discord.ext import commands
from utils import cache, db
from utils.colors import random_... |
import pytest
import os
import numpy as np
try:
import pymake
except:
msg = "Error. Pymake package is not available.\n"
msg += "Try installing using the following command:\n"
msg += " pip install https://github.com/modflowpy/pymake/zipball/master"
raise Exception(msg)
try:
import flopy
except:... |
# Copyright 2017 The TensorFlow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applica... |
import os
import copy
import re
from intent_recognition_predict import IntentRecognition
intent = IntentRecognition()
file_path = os.path.dirname(__file__)
# file_path = r'F:\workspace_dl_env\02_tf1.14\QA-kesou-demo\Project-QA-kesou-demo'
path_candidate_common = os.path.join(file_path, 'answer_candidate/candidate_... |
# ===============================================================================
# Copyright 2013 <NAME>
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LI... |
# Copyright 2019 Huawei Technologies Co., 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 to... |
import itertools
import pickle
from functools import partial
from multiprocessing.pool import Pool
from pathlib import Path
import matplotlib
import matplotlib.pyplot as plt
import numpy as np
import pandas as pd
from sklearn import metrics
from sklearn.metrics import accuracy_score
import Resources.training as tr_re... |
import json
import time
import os
import glob
import smtplib
from collections import OrderedDict
from provider import (
ejp,
email_provider,
lax_provider,
outbox_provider,
templates,
utils,
)
import provider.article as articlelib
from activity.objects import Activity
# Article types for which ... |
# Princeton University licenses this file to You 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 writin... |
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
# BCDI: tools for pre(post)-processing Bragg coherent X-ray diffraction imaging data
# (c) 07/2017-06/2019 : CNRS UMR 7344 IM2NP
# (c) 07/2019-present : DESY PHOTON SCIENCE
# authors:
# <NAME>, <EMAIL>
import numpy as np
import matplotlib.pyplot as plt
i... |
#----------------------------------------------train CNN using classic data augmentation+WGAN-gp-LSR--------------------------------
from __future__ import print_function, division
import sklearn as sk
from keras import backend as K
import matplotlib.gridspec as gridspec
from sklearn.metrics import classification_repor... |
# -*- coding: utf-8 -*-
"""Application Compatibility Cache collector."""
import logging
from dtfabric.runtime import data_maps as dtfabric_data_maps
from winregrc import data_format
from winregrc import errors
from winregrc import interface
class AppCompatCacheHeader(object):
"""Application Compatibility Cache h... |
import sys
from PyQt5.QtWidgets import *
from PyQt5.QtCore import *
from PyQt5.QtGui import *
from CustomPopup import CustomPopup
from Flag import Flag
from CustomButton import CustomButton
from Table_3_2 import table_3_2
from Table_3_3 import table_3_3
from Table_3_4 import table_3_4
from Table_3_5 import table_3_5... |
# Copyright 2018 Google Inc. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or a... |
import json, os, sys, select, time, io
from contextlib import contextmanager
plugin_id = os.environ.get("PLUGIN_ID")
try:
input=raw_input
except:
pass
def ellipsis_str(str, maxs=50):
if len(str)<maxs:
return str
else:
firsth=int(maxs*3/4)
lasth=maxs-firsth
return "%s...%s"%(str[:firsth], ... |
#!/usr/bin/env python
# coding: utf-8
# - In this notebook -
# -
#
#
# In[1]:
import pickle
from typing import Dict, Tuple, List
import os
import numpy as np
import json
import torch
import logging
import argparse
import math
from pprint import pprint
import pandas as pd
import errno
from sklearn.clus... |
from pickle import FALSE
from torch.utils.data.sampler import RandomSampler
from transformers.configuration_utils import PretrainedConfig
from transformers.generation_utils import GenerationMixin
import torch
import torch.nn as nn
from torch.utils.data import Dataset
from typing import *
from openprompt.data_utils impo... |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
Estimate the mass of a galaxy cluster given an observable, for several scaling
relations found by different studies.
Needs the uncertainties package.
When the observable is not given at the radius where the scaling relation was
calculated...
"""
from __future__ impor... |
from typing import Callable
from tqdm import tqdm
# from anndata._core.views import ArrayView
import numpy as np
from scipy import interpolate
from scipy.integrate import solve_ivp
# import scipy.sparse as sp
from ..vectorfield.topography import dup_osc_idx_iter
from ..tools.utils import log1p_
from ..utils import i... |
"""
I have appended FIX to areas that need attention.
I have added DEV to areas which are added on a whim to casually implement quickly desired functionality with little regard for precise mechanics/visual appeal.
"""
from tkinter import *
import string
from constants import Constants
from grid import populateWithI... |
"""
Module: kalman_filters
File: base.py
Remarks:
Base kalman filter, and basic functions frequently used
"""
import sys
import numpy as np
from scipy import linalg
from scipy import stats as ss
from copy import deepcopy
from typing import Union, Optional, Any, Callable, Tuple, List
from numbers import Real
__all_... |
# 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 required by app... |
import discord,spotipy,sqlite3,asyncio,time,youtube_dl,random
from discord.ext import commands
from discord.ext.commands.core import command
from spotipy.oauth2 import SpotifyClientCredentials
from googleapiclient.discovery import build
from datetime import datetime
youtube_dl.utils.bug_reports_message = lambda: ''
yd... |
#!/home/yangz6/Software/Python-2.7.5/python-2.7.5
# Programmer : <NAME>
# Contact: <EMAIL>
# Last-modified: 12 Sep 2018 07:46:14 PM
import os,sys,argparse
import math
import numpy as np
import tempfile
from operator import attrgetter
import pysam
import pyfasta
import pybedtools
from itertools import product
#######... |
from collections import OrderedDict
import warnings
from matplotlib.image import _ImageBase
from matplotlib.patches import Patch
from matplotlib.transforms import Bbox, TransformedBbox, BboxTransform
import matplotlib as mpl
import numpy as np
from . import reductions
from . import transfer_functions as tf
from .colo... |
# Copyright Least Authority Enterprises.
# See LICENSE for details.
"""
An interface to Swagger specifications.
This module provides the ability to automatically derive somewhat sensible
Python type definitions from definitions in a Swagger specification. The
Python types enforce the constraints defined by the Swagg... |
#
# Goal is eventually to translate a file like ../etc/exampleRES.xml into standard GCAM XML.
#
from copy import deepcopy
import re
from lxml import etree as ET
from lxml.etree import Element, SubElement
from .config import pathjoin, getParam
from .log import getLogger
from .XMLFile import XMLFile
_logger = getLogger(... |
# Copyright (c) 2015, <NAME> and <NAME> 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 must retain the above copyright notice, this
# list of conditions and ... |
import os
import numpy as np
from .TGN_data_obj import Data as TGNData
from torch_geometric.data import Data as PGData
import warnings
import torch
import bisect
default_node_features_dim = 172
def drop_duplicates_keep_last(arr):
rev_ix = np.unique(arr[::-1], return_index=True)
ix = len(arr)-rev_ix[-1]-1
... |
#####################################################################
# #
# dragdroptab.py #
# #
# Copyright 2013, Monash University ... |
'''This module contains the elements needed to set up the listen attend and
spell network.'''
from __future__ import absolute_import, division, print_function
from copy import copy
import collections
import numpy as np
import tensorflow as tf
from tensorflow.python.ops import rnn_cell
from tensorflow.python.ops.rnn_ce... |
from datetime import datetime, timedelta
from typing import Optional, Tuple
from concurrent.futures import ThreadPoolExecutor
from collections import defaultdict
from pandas import DataFrame
import pandas as pd
from pymongo.collection import Collection
from pymongo import MongoClient, UpdateOne
from .manager import ... |
import math
from datetime import datetime, timedelta
from django.shortcuts import get_object_or_404
from django.http import Http404, HttpResponse, HttpResponseRedirect, HttpResponseForbidden
from django.contrib.auth.models import User
from django.contrib.auth.decorators import login_required
from django.contrib.sites... |
# Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, ... |
# Copyright (c) OpenMMLab. All rights reserved.
import warnings
import numpy as np
import torch
import torch.nn as nn
import torch.nn.functional as F
from mmcv.cnn import build_norm_layer
from mmcv.cnn.bricks.drop import build_dropout
from mmcv.cnn.utils.weight_init import (constant_init, kaiming_init,
... |
# Copyright 2022 Huawei Technologies Co., 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 to... |
# Copyright 2019-2022 Cambridge Quantum Computing
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or a... |
from string import ascii_uppercase
import statistics as st
import numpy as np
import matplotlib.pyplot as plt
from matmov import funcoesmod as fm
def verificaObrig(modelo, t, nome):
"""
Verifica se a turma ```t``` com nome ```nome``` é uma turma que deve ser ativada
obrigatoriamente ou se e uma turma opc... |
# new_user()
# show_global_para()
# run_pdf()
# read_calib_file_new()
# check_latest_scan_id(init_guess=60000, search_size=100)
###################################
def load_xanes_ref(*arg):
"""
load reference spectrum, use it as: ref = load_xanes_ref(Ni, Ni2, Ni3)
each spectrum is two-column array, con... |
#!/usr/bin/env python3
from __future__ import annotations
import time
from typing import Optional, Iterable, Callable, Union
import pygame
from .constants import UL
from .mathf import clamp, Pos, Size
from .type_hints import _pos, _size, _col_type
pygame.init()
_point_to_rect_point = {
"ul": "topleft",
"dl... |
#!/usr/bin/env python
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
# jit_test.py -- Python harness for JavaScript trace tests.
from __future__ import print_functio... |
import networkx as nx
import numpy as np
import sklearn.metrics as metrics
import torch
import torch.nn as nn
from torch.autograd import Variable
import argparse
import os
import pickle
import random
import time
import encoders as encoders
import gen.feat as featgen
from graph_sampler import GraphSampler
... |
# Copyright DataStax, 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, softwa... |
from __future__ import unicode_literals
import configparser
import hashlib
import itertools
import json
import optparse
import os
import re
import shlex
import time
import urllib
from collections import defaultdict
from typing import IO, BinaryIO, Dict, Optional, Set
from xml.dom.minidom import parseString
from ._att... |
"""
PyDetex
https://github.com/ppizarror/PyDetex
GUI SETTINGS
Provides settings for the gui.
"""
__all__ = ['Settings']
import os
from typing import Callable, Tuple, Dict, Any, List, Type, Union
from warnings import warn
import datetime
import pydetex.pipelines as pip
import pydetex.utils as ut
import pydetex.vers... |
"""Statistics that are used in hnet."""
import df2onehot as df2onehot
from ismember import ismember
import numpy as np
import pandas as pd
from scipy.stats import hypergeom, ranksums
import statsmodels.stats.multitest as multitest
from sklearn.preprocessing import MinMaxScaler
import os
import tempfile
from pathlib ... |
from collections import OrderedDict
from p4z3.state import LocalContext
from p4z3.base import z3, log, copy, merge_attrs, OptionalExpression
from p4z3.base import z3_cast, handle_mux, StructInstance
from p4z3.base import P4Z3Class, P4Mask, P4ComplexType, UNDEF_LABEL
from p4z3.base import DefaultExpression, propagate_va... |
"""Helper to execute actions on the database independantly from the interface
and output format."""
import logging, datetime, sys, re
from slam import generator, models
from slam.log import DbLogHandler
# set-up logging to the database
LOGGER = logging.getLogger(__name__)
LOGGER.setLevel(logging.INFO)
DBLOGHANDLER =... |
#execute plotBA function to plot all Bland-Altman plots (one per parameter per format of image)
#figures are saved in the folder where path2savefolder leads
import matplotlib.pyplot as plt
def generateType1(title, titleX, titleY):
fig, ax = plt.subplots(1,1,sharex = False, sharey = False, figsize =(25,25))
fi... |
import os
import numpy as np
import pandas as pd
import pytest
from featuretools import list_primitives
from featuretools.primitives import (
Age,
Count,
Day,
GreaterThan,
Haversine,
Last,
Max,
Mean,
Min,
Mode,
Month,
NumCharacters,
NumUnique,
NumWords,
Perc... |
from functools import lru_cache
import operator
import six
import re
import uuid
from django.core.exceptions import ImproperlyConfigured
from django.utils.functional import partition
from django.utils.functional import SimpleLazyObject
from django_elasticsearch_dsl_drf.constants import MATCHING_OPTION_MUST, MATCHING_O... |
# coding : UTF-8
"""
File Name: class_play_game.py
Description: Hit&Blowの自動通信対戦の主要なクラス
Created on october 13,2021
Created by <NAME>, <NAME>, <NAME>
"""
import random
import time
import itertools
import streamlit as st
import requests
# st.set_page_config(layout="wide")
import pygame
from PIL import Image
session = requ... |
#!/usr/bin/env python
# Version: 1.0
# Author: <NAME> (updated by <NAME>)
from __future__ import division, print_function
import argparse
from collections import deque
import glob
import os
import sys
from subprocess import check_call
import astropy.units as u
from astropy import log
from astropy.io import fits
from ... |
"""
Asset Management - Assets: Validate required fields based on asset type.
"""
__author__ = '<NAME>'
from ooiservices.app.uframe.common_tools import (get_supported_asset_types, asset_edit_phase_values, verify_action)
from ooiservices.app.uframe.common_convert import convert_ui_data
def assets_validate_required_fi... |
#!/usr/bin/env python
# coding: utf-8
from urllib import robotparser
from urllib.parse import urljoin, urlparse
import lxml.html as lh
import requests
import re
from itertools import chain
import time
import bibmatch.clean_data as clean_data
from bibmatch.authorclass import author
from langdetect import detect
from ... |
"""
Utility functions for data processing.
"""
from typing import Optional, List
import h5py
import numpy as np
from typeguard import typechecked
from scipy.interpolate import griddata
def update_sptype(sptypes):
"""
Function to update a list with spectral types to two characters (e.g., M8, L3, or T1).
... |
#!/usr/bin/python3
#
# Copyright (C) 2020-2021 <NAME> <<EMAIL>>
# https://github.com/laroche/tastyworks-pnl
#
# Generate data for a German tax income statement from Tastyworks trade history.
#
#
# Download your trade history as csv file from
# https://trade.tastyworks.com/index.html#/transactionHistoryPage
# (Choose 'A... |
## @file vm.py
## @brief Virtual Machine Management Operations
##
## Detailed description (for Doxygen goes here)
"""
Virtual Machine Management Operations
Detailed description (for [e]pydoc goes here)
"""
__author__ = "VMware, Inc"
import traceback
from pyVmomi import Vim, Vmodl
from .task import WaitForTask
from... |
#!/usr/bin/python3
#
# Control GUI for high and low level controls. Useful for debugging.
# Connect to irises on the network and override its control settings.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
# INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNES... |
# coding: utf-8
# /*##########################################################################
#
# Copyright (c) 2004-2017 European Synchrotron Radiation Facility
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to d... |
# -*- coding: utf-8 -*-
"""
Calculation of output impedance across frequency
- Set up ltspice simulation for transient analysis
- Use sinusoidal voltage source for :math:`V_{I,set}`, measure output current
- Set up parameter sweep across input frequency; modify total simulation time to match
- Do this for t... |
#!/usr/bin/env python3
import argparse
import datetime
import functools
import logging
import matplotlib.pyplot as plt
import numpy as np
import pprint
from sgp4.api import Satrec
from sgp4.api import jday
import sys
"""See the help message for more information.
"""
# Earth constants -- km, kg, s
Re_max = 6378 # k... |
"""
Definition of the Lattice class and related routines
"""
__all__ = [
"default_lattice",
"Lattice",
]
import re
import random
from types import MappingProxyType
from functools import partial, wraps
from typing import Callable
from inspect import signature
from lyncs_utils import default_repr_pretty, isiter... |
#!/usr/bin/python3
"""
The radii and slope parameter optimization mode command-line interface
Optimizes radii and b-factor slopes using a given set of PDB IDs.
A simple steepest decent optimization approach is utilized.
This approach is justified by testing and the use of median differences that smooths the error... |
"""
PrepareData
===========
Filter signals using PCA decomposition of their fast-fourier transform
#. Identify outliers in fft-transformed signal
#. Identify clusters in fft - i.e. signals with simmilar features
"""
import sys
sys.path.insert(0, '/Users/ryszardcetnarski/Desktop/pySeries')
import numpy as n... |
import torch
import torch.nn as nn
import itertools
from math import sqrt
import numpy as np
import torch
import torch.nn.functional as F
from torchvision.models.resnet import resnet18, resnet34, resnet50, resnet101, resnet152
#SSD 모델 저장할때
#ssd_model = torch.hub.load('NVIDIA/DeepLearningExamples:torchhub', '... |
"""
MIT License
mift - Copyright (c) 2021 Control-F
Author: <NAME> (Control-F)
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software, 'mift', and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation t... |
from scapy.all import *
from scipy import interpolate
import matplotlib.pyplot as plt
import numpy as np
import itertools
import pandas as pd
import support_functions as SUP
from collections import defaultdict
from scipy.spatial import distance
from sklearn.linear_model import LinearRegression
from numpy import array
i... |
#!/usr/bin/python
# -*- coding: utf-8 -*-
""" Main class
This module contains the abstract base class :py:class:`Escpos`.
:author: `<NAME> <<EMAIL>>`_ and others
:organization: Bashlinux and `python-escpos <https://github.com/python-escpos>`_
:copyright: Copyright (c) 2012 Bashlinux
:license: GNU GPL v3
"""
from __... |
# -*- coding: utf-8 -*-
#
# Licensed under the terms of the Qwt License
# Copyright (c) 2002 <NAME>, for the original C++ code
# Copyright (c) 2015 <NAME>, for the Python translation/optimization
# (see LICENSE file for more details)
"""
QwtLegend
---------
.. autoclass:: QwtLegendData
:members:
.. autoclass:: Qw... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.