text
stringlengths
6.04k
39.5k
# # radarbeam.py # # module for calculating geometry parameters and magnetic aspect # angle of radar targets monitored by any radar # # use aspect_elaz or aspect_txty to calculate aspect angles of targets # specified by (el,az) or (tx,ty) angles # # Created by <NAME> on 11/29/08 as jrobeam.py # Copyright (c) 2008 EC...
#!/usr/bin/env python """Make big QUOCKA cubes""" from IPython import embed import schwimmbad import sys from glob import glob from tqdm import tqdm import matplotlib.pyplot as plt from radio_beam import Beam, Beams from radio_beam.utils import BeamError from astropy import units as u from astropy.io import fits from ...
# Copyright 2020 Curtin University # # 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 writi...
import sys import warnings from copy import deepcopy import itertools import numpy as np from scipy.stats import entropy, multivariate_normal from sklearn.cluster import KMeans from sklearn.mixture import GaussianMixture from sklearn.mixture.gaussian_mixture import _compute_precision_cholesky,\ _check_precision_mat...
from tensorflow.keras.layers import Input from tensorflow.keras.layers import Conv2D from tensorflow.keras.layers import BatchNormalization from tensorflow.keras.layers import Activation from tensorflow.keras.layers import MaxPooling2D from tensorflow.keras.layers import AveragePooling2D from tensorflow.keras.layers im...
import torch from torch.utils.data import Dataset import glob import tifffile as T from libtiff import TIFF import numpy as np def range_normalize(v): v = (v - v.mean(axis=(1, 2), keepdims=True)) / (v.std(axis=(1, 2), keepdims=True) + 1e-12) v_min, v_max = v.min(axis=(1, 2), keepdims=True), v.max(axis=(1, 2),...
# -*- coding: utf-8 -*- from __future__ import unicode_literals, print_function, division from io import open import unicodedata import string import re import random import torch import torch.nn as nn from torch.autograd import Variable from torch import optim import torch.nn.functional as F use_cuda = torch.cuda.i...
import gym import itertools import matplotlib import numpy as np import sys import tensorflow as tf import collections from time import time import os.path from fourInARowWrapper import FourInARowWrapper if "../" not in sys.path: sys.path.append("../") from lib import plotting matplotlib.style....
#!/usr/bin/env python # -*- coding: utf-8 -*- # 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, V...
import argparse import os from os import path import time import shutil from random import sample import pickle import ast from model.discriminator import Discriminator from model.generator import Generator from lib.utils.avgmeter import AverageMeter from lib.dataloader import CelebADataset def arg_as_list(s): v ...
import argparse import gc import glob import logging import math import os import sys import time import numpy as np import torch import torch.backends.cudnn as cudnn import torch.nn as nn import torch.nn.functional as F import data import model_search_rnn as model from architect_rnn import Architect from utils_rnn i...
# -*- coding: utf-8 -*- # Copyright (c) 2019, <EMAIL> and contributors # For license information, please see license.txt from __future__ import unicode_literals import frappe import json import datetime from frappe.model.document import Document from frappe import _ from six.moves.urllib.parse import urlencode from fra...
# # Copyright (c), 2018-2021, SISSA (International School for Advanced Studies). # All rights reserved. # This file is distributed under the terms of the MIT License. # See the file 'LICENSE' in the root directory of the present # distribution, or http://opensource.org/licenses/MIT. # # @author <NAME> <<EMAIL>> # """ H...
import time import logging from enum import Enum, unique from copy import deepcopy from collections import defaultdict from termcolor import cprint, colored from pybullet_planning import set_random_seed, set_numpy_seed, elapsed_time, get_random_seed from pybullet_planning import wait_if_gui, wait_for_user, WorldSaver ...
# coding=utf-8 # Author: <NAME> # Date: Aug 06, 2019 # # Description: Plots results of screened DM genes # # Instructions: # import numpy as np import pandas as pd pd.set_option('display.max_rows', 100) pd.set_option('display.max_columns', 500) pd.set_option('display.width', 1000) import matplotlib as mpl from matplotl...
import tkinter as tk from tkinter import ttk import json import subprocess from PIL import ImageTk, Image import zipfile import io import os import sys PER_LINE = int(sys.argv[1]) LINES = int(sys.argv[2]) TMPFILE = sys.argv[5] SHOWID = str(10214655) class VerticalScrolledFrame(tk.Frame): """A pure Tkinter scrolla...
import os import torch import segmentation_models_pytorch as smp import pandas as pd from abc import abstractmethod from pathlib import Path from catalyst.dl.callbacks import AccuracyCallback, EarlyStoppingCallback, \ CheckpointCallback, PrecisionRecallF1ScoreCallback from catalyst.dl...
import requests import csv import logging from requests.auth import HTTPBasicAuth import time from primeapidata import PI_ADDRESS, USERNAME, PASSWORD requests.packages.urllib3.disable_warnings() ''' Call one of those from the main function or put one out of comments here, be carefull of the different filenames. It sh...
from typing import Optional, Tuple, Sequence, Type, Union, Dict import numpy as np from anndata import AnnData import scipy.stats from scipy import sparse from scanpy import logging as logg import graph_tool.all as gt import pandas as pd from .._utils import get_cell_loglikelihood, get_cell_back_p, state_from_blocks ...
#!/usr/bin/env python3 # -*- encoding: utf8 -*- """ This is an python implementation of preprocessing of the SEAME Mandarin-English code-switching corpus. We follow original papers [1, 2] and the official github repository [3] to make this code produces the same amount of training and testing data....
"""Functions to read from and write to misc sources """ import os import json import pickle import csv import gzip from io import StringIO from py2store.stores.local_store import LocalBinaryStore from py2store.slib.s_zipfile import FilesOfZip from py2store.slib.s_configparser import ConfigReader, ConfigStore from py2...
# -*- coding: utf-8 -*- from __future__ import unicode_literals import sys if sys.version_info >= (3, 0, 0): from urllib.parse import urlparse else: from urlparse import urlparse if sys.version_info >= (3, 5, 0): def isclose(a, b, rel_tol=1e-09, abs_tol=0.0): return abs(a - b) <= max(rel_tol * ma...
import sublime import sublime_plugin import datetime import re import os import fnmatch import OrgExtended.orgparse.node as node import OrgExtended.orgutil.util as util import OrgExtended.orgutil.navigation as nav import OrgExtended.orgutil.template as templateEngine import logging import sys import traceback import O...
# -*- coding: utf-8 -*- import sys, re, clean reload(sys) sys.setdefaultencoding('utf-8') from collections import OrderedDict ############################################################################## # Categorized letters and digraphs # ###################################...
# -*- coding: utf-8 -*- from random import choice, randint from json import dumps, loads from time import time, sleep, strftime, gmtime import requests URL = 'https://api.telegram.org/bot' TOKEN = 'TOKEN_HERE' offset = int(0) logAPIError = True def record(text, toConsole = False, end = '\n'): file = open("data/bot....
#!/usr/bin/env python3.5 import time e = time.time() import sys debug = False fileWrite = True if fileWrite: fWPath = "processed/" + sys.argv[1] + "-processed.jpg" displayProcessed = False import cv2 import numpy as np import pickle if debug: print ("imports: " + str(format(time.time() - e, '.5f'))) star...
import json import logging import os import time from pprint import pformat import requests from flask import abort, make_response from config import db, executor from config.db_lib import db_session from models import ( Activator, ActivatorMetadata, ActivatorMetadataVariable, Applicati...
from __future__ import division, print_function # confidence high import astropy from stsciutils.tools import parseinput, fileutil, convertwaiveredfits, readgeis from astropy.io import fits import os import sys from distutils.version import LooseVersion PY3K = sys.version_info[0] > 2 if PY3K: string_types = str ...
import numpy as np from matplotlib import pyplot as plt import pickle as pkl import starry import celerite2.jax from celerite2.jax import terms as jax_terms from celerite2 import terms, GaussianProcess from exoplanet.distributions import estimate_inverse_gamma_parameters from matplotlib import colors import matplotli...
import numpy as np import pandas as pd from vimms.old_unused_experimental.PythonMzmine import get_base_scoring_df from vimms.Roi import make_roi QCB_MZML2CHEMS_DICT = {'min_ms1_intensity': 1.75E5, 'mz_tol': 2, 'mz_units': 'ppm', 'min_length': 1, ...
# 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 ...
# pylint: disable=C0111 #!/usr/bin/python from kickstart_salt_imports import * # Borrowed some code from # https://github.com/facebook/IT-CPE/blob/master/chef/tools/chef_bootstrap.py class GCEMetadataWrapper: '''Wrapper class for retrieving Instance & Project Metadata''' @staticmethod def retur...
""" The `methods` script contains functions for estimating the period of a star. """ import lightkurve as lk import astropy.units as u import numpy as np from scipy.signal import find_peaks from scipy import interpolate from scipy.optimize import curve_fit from scipy.ndimage import gaussian_filter1d import warnings i...
#!/usr/bin/python # Copyright (c) 2020, 2022 Oracle and/or its affiliates. # This software is made available to you under the terms of the GPL 3.0 license or the Apache 2.0 license. # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) # Apache License v2.0 # See LICENSE.TXT for d...
import json import os import matplotlib.pyplot as plt import networkx as nx import pandas as pd import redis from bs4 import BeautifulSoup from stellargraph import StellarGraph from dataprep.alexa_scrapper import ScrapeAlexa from dataprep.scrape_all_alexa_information import main from dataprep.load_annotated_data impo...
"""Random select substitution; save substituted structure and JSON info""" import warnings warnings.simplefilter('ignore') import errno import functools import glob import math import os import random import re import signal import sys import numpy as np import pandas as pd import pymatgen import shry from ase import...
from __future__ import print_function from stompy.grid import unstructured_grid import numpy as np import logging log=logging.getLogger(__name__) from shapely import geometry import xarray as xr # TODO: migrate to xarray from ...io import qnc from ... import utils # for now, only supports 2D/3D grid - no mix with 1D...
import os import time import tkinter.messagebox from tkinter import * from tkinter import filedialog, scrolledtext import pandas as pd import psycopg2 """ NEED TO CHANGE THE SIZING FOR THIS WINDOW BECAUSE IT THE TEXT BOXES ARE TOO BIG BUT I CAN SHRINK THE SECTIONS FOR THE TEXT. """ tb = "inv_testing3" con_path = r"...
"""Intervals are a generalization of several file formats: GFF ==== All GFF formats (GFF2, GFF3 and GTF) are tabular files with 9 fields per line, separated by tabs. They all share the same structure for the first 7 fields, while differing in the definition of the eighth field and in the content and format of the nin...
#!/usr/bin/env python # You may need to edit the above to point to your version of Python 2.0 """ psize.py Get dimensions and other interesting information from a PQR file Originally written by <NAME> Additional APBS-specific features added by <NAME> Ported to Python/Psize class by <NAME> and subsequently hacked by <N...
""" All interactions with KLEE """ import json import operator import re import shutil import subprocess import tempfile import signal import time import os from collections import OrderedDict from os import listdir, path, makedirs, killpg, getpgid, setsid from .config import KLEEBIN from .constants import ERRORFILE...
from builtins import str from builtins import zip #!/usr/bin/env python from nipype.interfaces.base import ( CommandLine, CommandLineInputSpec, TraitedSpec, File, Directory, ) from nipype.interfaces.base import traits, isdefined, BaseInterface from nipype.interfaces.utility import Merge, Split, Fu...
# Copyright (C) 2021 The Xaya developers # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. """ Utilities for running Xaya X connected to an Ethereum node from Python, e.g. for integration tests. """ from xayagametest import xaya ...
from typing import Optional, Union import numpy as np from scipy.spatial import cKDTree import bbknn from scipy.sparse import csr_matrix import scanpy as sc from numpy.testing import assert_array_equal, assert_array_compare import operator import numpy as np from anndata import AnnData from sklearn.utils import che...
# Copyright 2018 The Batfish 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 required by applicab...
# -*- coding: utf-8 -*- from quartical.config.external import Gain from quartical.config.internal import yield_from from loguru import logger # noqa import numpy as np import dask.array as da from pathlib import Path import shutil from daskms.experimental.zarr import xds_to_zarr from quartical.gains import TERM_TYPES ...
######################################################################### # Dicomifier - Copyright (C) Universite de Strasbourg # Distributed under the terms of the CeCILL-B license, as published by # the CEA-CNRS-INRIA. Refer to the LICENSE file or to # http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html # for...
import numpy as np import pandas as pd import matplotlib.pyplot as plt import seaborn as sns import io import warnings from sklearn.model_selection import cross_validate from sklearn.model_selection import cross_val_score from sklearn.model_selection import KFold from sklearn.metrics import accuracy_score, precision_...
import random import numpy import simpy from file_manager import SharedFile def new_inter_session_time(): """ Ritorna un valore per l'istanza di "inter-session time" """ return numpy.random.lognormal(mean=7.971, sigma=1.308) def new_session_duration(): """ Ritorna un valore per l'istanza di ...
#!/usr/bin/env python # # # # Autor: <NAME>, GSFC/CRESST/UMBC . # # # # T...
# Copyright 2015 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...
"quantify shape and depth diversity of FHIR data" # conda create -n py39 python=3.9 # conda activate py39 # pip install rich, numpy # python fhir.py from dataclasses import dataclass from itertools import chain from typing import Dict, List, Optional, Tuple import json import os from plotly.subplots import make_subpl...
#!/usr/bin/env python3 # # SPDX-License-Identifier: MIT """Generate the FSF license API JSON data from the FSF license list page.""" import argparse import glob import html import io import json import os import re import urllib.parse import urllib.request import lxml.etree SOURCE_URI = 'https://www.gnu.org/licens...
#! /usr/bin/env python # encoding: utf-8 # WARNING! Do not edit! https://waf.io/book/index.html#_obtaining_the_waf_file from __future__ import with_statement import atexit, os, sys, errno, inspect, re, datetime, platform, base64, signal, functools, time try: import cPickle except ImportError: import pickle as ...
from aiogram import Bot, Dispatcher, executor, types from aiogram.utils import exceptions import mysql.connector import time import asyncio import config import logging import datetime import traceback import re from apscheduler.schedulers.asyncio import AsyncIOScheduler # Init main classes db = mysql.c...
#!/usr/bin/python # # Copyright 2020 DeepMind Technologies Limited # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by a...
#!/usr/bin/python ''' Detects the start and end trimpoints of an audio file. ''' import sys import numpy import sklearn.cluster import time import scipy import os import ConfigParser from pyAudioAnalysis import audioFeatureExtraction as aF from pyAudioAnalysis import audioTrainTest as aT from pyAudioAnalysis import aud...
# ------------------------------------------------------------------------------ # BSD 2-Clause License # # Copyright (c) 2019, <NAME> # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions...
import curses import os import re import time from collections import namedtuple from operator import itemgetter from pg_view import flags from pg_view.meta import __appname__, __version__, __license__ from pg_view.utils import enum COLSTATUS = enum(cs_ok=0, cs_warning=1, cs_critical=2) COLALIGN = enum(ca_none=0, c...
import os import sys import importlib.util import pdb import time import random import re from copy import deepcopy import numpy as np from functools import reduce from collections import defaultdict import arrow import scipy from scipy.cluster.vq import * from scipy.cluster.hierarchy import linkage, dendrogram import...
# -*- coding: utf-8 -*- """ Created on Wed Jun 3 12:20:34 2020 @author: Patrick """ #Make sure current working directory is the folder before DiscordBot import os cwd = os.getcwd() import numpy as np import duden import discord from dotenv import load_dotenv import nest_asyncio import asyncio nest_asyn...
""" the module to parse format strings and construct format trees この module はフォーマット文字列を構文解析しフォーマット木を作ります。 たとえば :: N P_0 P_1 \cdots P_{N-1} Q_0 Q_1 \cdots Q_{N-1} という入力フォーマット文字列が与えられれば :: sequence([ item("N"), newline(), loop(counter="i", size="N", item("P", indice...
""" Please find copyright information at the end of this document Por favor encuentra la información de derechos de autor al final de este documento Este fue el código más estable que encontré en línea, gracias a Jim Term por todo su trabajo. Mi nombre es <NAME>. ¡Colaboremos juntos! Redes Sociales / Social Network...
import numpy as np # Unit prefixes for val and lst unitPrefixes = "kMGTPEZYyzafpnμm" # Table chars singleFrameChars = ['│', '─', '┼', '┌', '┐', '└', '┘', '├', '┬', '┤' ,'┴'] doubleFrameChars = ['║', '═', '╬', '╔', '╗', '╚', '╝', '╠', '╦', '╣', '╩'] tableChars = singleFrameChars def sigval(val, err, fix_mul3=True, fi...
# ElectrumSV - lightweight Bitcoin client # Copyright (C) 2015 <NAME> # Copyright (C) 2019-2020 The ElectrumSV Developers # # 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...
#!/usr/bin/python # (c) 2019, NetApp, Inc # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) from __future__ import absolute_import, division, print_function __metaclass__ = type ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['preview'], ...
import logging from kafka import KafkaProducer import pandas as pd from datetime import datetime as dt, timedelta as td import json import re import os import time import requests from sched import scheduler from typing import List, Tuple # Initialize log log = logging.getLogger(__name__) def extract_forecast(filepa...
# Copyright (C) 2018 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, ...
''' <NAME>, <NAME> and <NAME> ''' from flask import Flask, render_template, url_for, request, redirect, abort, flash, jsonify, session, make_response from flask_session import Session from pprint import pprint as pp from werkzeug.utils import secure_filename from werkzeug.exceptions import HTTPException, default_excep...
# -*- coding: utf-8 -*- """---------------------------------------------------------------------------- Author: fengfan <EMAIL> Date: 2017/1/10 Description: Sunshine RPC Module History: 2017/1/10, create file. ----------------------------------------------------------------------------""" import sys import uuid i...
#!/usr/bin/env python # -*- coding: utf-8 -*- # # @Author: <NAME> (<EMAIL>) # @Date: 2019-02-19 # @Filename: target.py # @License: BSD 3-clause (http://www.opensource.org/licenses/BSD-3-Clause) # # @Last modified by: <NAME> (<EMAIL>) # @Last modified time: 2019-09-25 15:20:31 import os import pathlib from copy import ...
# Tutorial "Regresion Basica: Predecir eficiencia de gasolina" # https://www.tensorflow.org/tutorials/keras/regression?hl=es-419 import os import sys os.environ['TF_CPP_MIN_LOG_LEVEL'] = '3' import numpy as np # noqa: E402 # from scipy import stats # noqa: E402 import matplotlib.pyplot as plt # noqa: E402 import p...
__author__ = 'Dante' import os import math import machines import density_weight as dw from structures.isozyme import BrendaIsozyme as bi from databases import db_queries as dbq from structures import fingerprinter as fptr import numpy as np import routines import pybel CHEMPATH = os.path.join(os.path.di...
from __future__ import print_function from fenics import * from mshr import * import numpy as np from scipy import integrate set_log_level(LogLevel.INFO) T = 500.0 # final time num_steps = 1000 # number of time steps dt = T / num_steps # time step size mu = 16 # dynamic viscosity rho = 1 ...
import ast from functools import wraps from typing import Optional from op_code import _ENV from compiler.func_state import FuncState class Context: def __init__(self, fs: FuncState, r: Optional[int] = None, n: int = 0): self.fs = fs self.r = r self.n = n class ClassBody(Context): de...
# A device image plotter import sys import os import json import glob import PyQt5.QtWidgets as qt import PyQt5.QtGui as gui import PyQt5.QtCore as core from shutil import copyfile import copy from qcodes.instrument.channel import ChannelList from qcodes.utils.helpers import foreground_qt_window class MakeDeviceImag...
# -*- encoding:utf-8 -*- import torch.nn.functional as F import torch.optim.lr_scheduler import numpy as np from uer.models.model import Model from uer.model_builder import build_model from uer.layers.layer_norm import LayerNorm from uer.utils.act_fun import gelu import torch.nn as nn from torch.autograd import Variab...
# MIT License # Copyright (c) 2020 Dr. <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 # to use, copy, modify, merge, pub...
"""Roughness helper functions""" import os import contextlib from pathlib import Path import numpy as np import numpy.f2py import xarray as xr import jupytext from . import config as cfg from . import __version__ # Line of sight helpers def lookup2xarray(lookups): """ Convert list of default lookups to xarray....
from __future__ import absolute_import from logging import getLogger logger = getLogger("gui_builder.fields") import traceback from .widgets import wx_widgets as widgets try: unicode except NameError: unicode = str class UnboundField(object): creation_counter = 0 _GUI_FIELD = Tr...
# moosic.server.support.py - classes and functions that support moosicd # # This is free and unencumbered software released into the public domain. # # Anyone is free to copy, modify, publish, use, compile, sell, or # distribute this software, either in source code form or as a compiled # binary, for any purpose, comm...
""" A simple Game using the kivy framework. """ import sys import random from kivy.config import Config # Config.set('graphics', 'width', '1366') # Config.set('graphics', 'fullscreen', 'auto') # Config.set('graphics', 'window_state', 'maximized') # Config.set('graphics', 'height', '768') Config.set('kivy', 'window_ic...
# -*- coding: utf-8 -*- import argparse import json import logging import os import re import sys import xml.etree.ElementTree as ET from xml.etree.ElementTree import Element from xml.etree.ElementTree import ElementTree # From .js keyboard files, creats LDML for CLDR keyboards # http://unicode.org/Public/cldr/37/...
import time from typing import List from typing import Tuple from starks.merkle_tree import blake from starks.merkle_tree import verify_branch from starks.merkle_tree import mk_branch from starks.merkle_tree import merkelize from starks.merkle_tree import merkelize_polynomial_evaluations from starks.merkle_tree import ...
# ------------------------------------------------------------------ # _________ ______________________________ # / _____/__.__. ______ \_____ \__ ___/\__ ___/ # \_____ < | |/ ___/ _____/ / \ \| | | | # / \___ |\___ \ |Sys-QTT|/ \_/....
import pymbar from fe import endpoint_correction from collections import namedtuple import pickle import dataclasses import time import functools import copy import jax import numpy as np from md import minimizer from typing import Tuple, List, Any import os from fe import standard_state from fe.utils import sanitiz...
#!/usr/bin/env python3 import random def main(): """Terminal上でポーカーを再現。ダブルアップはなし。 """ poker = Poker() # test() """ 標準入出力を利用して、ゲームを行う ループで回せばいい 終了の文字も指定する ゲームの流れは、 スタート->dealされた札が5枚表示される->holdする札を選択する-> ->再びdealする->役を判定->ゲームの結果処理->スタートに戻る ユーザーができることは、 holdする札を選ぶ。結果表示後...
#!/usr/bin/env python # -*- coding: UTF-8 -*- """Return residual from pyccd model using Google Earth Engine Usage: GE_pyccd_residual.py [options] --path=PATH path --row=ROW row --lon=LON longitude --lat=LAT latitude --date=DATE date to compare (%Y%j) --count=COUNT ...
#PARSER import ply.yacc as yacc import lexico import nodo as grammer import graficas as generar tokens = lexico.tokens precedence = ( ('left', 'mas', 'menos'), ('left', 'por', 'div'), ('nonassoc','between', 'like'), ('left', 'menor', 'mayor', 'igual', 'menorigual', 'mayorigual', 'diferente'), ('ri...
#!python from collections import deque class User(object): def __init__(self, age, testscore): self.age = age self.testscore = testscore def getAge(self): return self.age def getTestScore(self): return self.testscore class BinaryTreeNode(object): def __init__(self,...
#! /usr/bin/env python3 # A hacky script to convert a directory of images into an OCR'd DJVU file import argparse import logging import os import shutil import multiprocessing import concurrent.futures import subprocess import traceback import sexpdata import tempfile import utils.djvu_utils as DJVU import utils.t...
import os import time import numpy as np import pandas as pd from oplrareg.solvers import get_solver_definition from modSAR.dataset import QSARDatasetIO from modSAR.graph import GraphUtils from copy import deepcopy from sklearn.externals.joblib import Parallel, delayed from sklearn.metrics import mean_absolute_error,...
"""Test sets translate the specifications of which tests to run (with which options), into a set of ready to run tests. They are ephemeral, and are not tracked between Pavilion runs.""" import threading import time from collections import defaultdict from io import StringIO from typing import List, Dict, TextIO, Union,...
# Copyright 2022 DeepMind Technologies Limited. 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 ...
# Copyright (c) 2016-present, Facebook, Inc. # # This source code is licensed under the MIT license found in the # LICENSE file in the root directory of this source tree. import argparse import enum import json import logging import os import re import resource import signal import subprocess import threading from ab...
import logging from typing import List, Dict, Set, Union, cast, Type import pandas as pd from genomics_data_index.storage.SampleSet import SampleSet from genomics_data_index.storage.model.NucleotideMutationTranslater import NucleotideMutationTranslater from genomics_data_index.storage.model.QueryFeature import QueryF...
import json from django.core.urlresolvers import reverse from django.shortcuts import render, get_object_or_404 from django.conf import settings from django.contrib import messages from django.core.exceptions import ValidationError from django.http import HttpResponseRedirect, HttpResponse, Http404, JsonResponse from d...
import json import os import socket import sys import time import subprocess import re import html from collections import deque from ipykernel.kernelbase import Kernel from dyalog_kernel import __version__ from notebook.services.config import ConfigManager if sys.platform.lower().startswith('win'): from winreg...
import numpy as np import json from importlib import reload import os from models.core.tf_models.cae_model import CAE import pickle import tensorflow as tf import dill from collections import deque from models.core.tf_models import utils from scipy.interpolate import CubicSpline import time from models.core...
"""Failure theories for ductile materials - principal stress example # -*- coding: utf-8 -*- This module provides and example explaining the failure theorie for ductile materials in a plane. The user can set the principal stresses and the yield stress for a material. The class show a plot with the two envelopes and t...