text
stringlengths
0
27.1M
meta
dict
subroutine setaux(mbc,mx,my,xlower,ylower,dx,dy,maux,aux) ! Called at start of computation before calling qinit, and ! when AMR is used, also called every time a new grid patch is created. ! Use to set auxiliary arrays aux(1:maux, 1-mbc:mx+mbc, 1-mbc:my+mbc). ! Note that ghost cell values may need to b...
{ "alphanum_fraction": 0.6365187713, "author": null, "avg_line_length": 34.4705882353, "converted": null, "ext": "f90", "file": null, "hexsha": "6468d6eb469e77a5924daa2bd31c0ac7491197a4", "include": null, "lang": "FORTRAN", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_f...
import pygimli as pg import numpy as np from settings import fpm pd = pg.load("paraDomain_1.bms") resinv = np.loadtxt("res_conventional.dat") vest = np.loadtxt("vel_conventional.dat") fae, fie, fwe, maske = fpm.all(resinv, vest) print(np.min(fwe), np.max(fwe)) np.savez("conventional.npz", vel=np.array(vest), rho=np.a...
{ "alphanum_fraction": 0.709762533, "author": null, "avg_line_length": 29.1538461538, "converted": null, "ext": "py", "file": null, "hexsha": "28f0a36bcf106a153708f4ec25ed18179b50bbfc", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_fork...
import Teams import collections import datetime as dt import numpy as np import matplotlib.pyplot as plt from scipy.optimize import curve_fit from constants import _Const import dataLoader CONST = _Const() teams = {} fixtures = dataLoader.LoadAllData(dt.datetime.now()) output = open(CONST.OUTPUT_PATH + 'Parameters.tx...
{ "alphanum_fraction": 0.674863388, "author": null, "avg_line_length": 30.9295774648, "converted": null, "ext": "py", "file": null, "hexsha": "beb02ae7c1910ea0b8c9a11cbdc62c1260811004", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_fork...
import sys sys.path.append('../') import pytest import LMR_utils as Utils import numpy as np @pytest.mark.parametrize("doc", [ """This is class docstring""", None]) def test_class_doc_inherit(doc): class foo: __doc__ = doc pass @Utils.class_docs_fixer class bar(foo): pass...
{ "alphanum_fraction": 0.6276234259, "author": null, "avg_line_length": 29.2573099415, "converted": null, "ext": "py", "file": null, "hexsha": "71db5e744515b5e689ccb0374d96d8e0faac0702", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
program opkdemo7 c----------------------------------------------------------------------- c Demonstration program for the DLSODI package. c This is the version of 14 June 2001. c c This version is in double precision. c C this program solves a semi-discretized form of the Burgers equation, c c u = -(u*u/2) ...
{ "alphanum_fraction": 0.5435811327, "author": null, "avg_line_length": 32.592039801, "converted": null, "ext": "f", "file": null, "hexsha": "5cf007c9de780f24f3e4f1c8640b83fb8d041eb0", "include": null, "lang": "FORTRAN", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_fork...
# Copyright (c) Facebook, Inc. and its affiliates. # # This source code is licensed under the MIT license found in the # LICENSE file in the root directory of this source tree. import numpy as np import torch import os import sys from lib.utils import pc_util DUMP_CONF_THRESH = 0.5 # Dump boxes with obj prob larger ...
{ "alphanum_fraction": 0.6495245748, "author": null, "avg_line_length": 53.7194244604, "converted": null, "ext": "py", "file": null, "hexsha": "8a1bb7882ac47f0c13ead5b3bc500c0348d54b91", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
import os import random from typing import List import numpy as np import torch from nobos_commons.data_structures.constants.dataset_part import DatasetPart from nobos_commons.data_structures.dimension import ImageSize from nobos_torch_lib.configs.training_configs.training_config_base import TrainingConfigBase from no...
{ "alphanum_fraction": 0.591103307, "author": null, "avg_line_length": 51.1526946108, "converted": null, "ext": "py", "file": null, "hexsha": "a1fc74720ade7c49bc0d5ff8a98f49c7e45e0c19", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_fork...
""" Octree geometry handler """ #----------------------------------------------------------------------------- # Copyright (c) 2013, yt Development Team. # # Distributed under the terms of the Modified BSD License. # # The full license is in the file COPYING.txt, distributed with this software. #------------------...
{ "alphanum_fraction": 0.6805896806, "author": null, "avg_line_length": 30.1481481481, "converted": null, "ext": "py", "file": null, "hexsha": "7b27e471f181ac1b4af50a5718d9e57036437443", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
import config as cf import numpy as np import pygame as pg class Circle: """Make a times table calculation.""" def __init__(self, points): self.points = points self.radius = cf.RADIUS def draw(self, screen, factor, pt, lines, circle): if circle: pg.draw.circle( ...
{ "alphanum_fraction": 0.4928270042, "author": null, "avg_line_length": 34.8529411765, "converted": null, "ext": "py", "file": null, "hexsha": "1012fbac3c8905e8af44df58d58006ea92c3501a", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
function [all_bboxes_out] = localize_bboxes_of_all_imgs(... model, image_paths, all_bboxes_in, dst_directory, image_set_name, varargin) % localize_bboxes_of_all_imgs: given a bounding box localization model and % a set of images with their input candidate bounding boxes, for each % image it predicts new bounding ...
{ "alphanum_fraction": null, "author": "gidariss", "avg_line_length": null, "converted": null, "ext": null, "file": null, "hexsha": null, "include": null, "lang": null, "length": null, "llama_tokens": null, "mathlib_filename": null, "max_forks_count": null, "max_forks_repo_forks_event_max_da...
#!/usr/bin/env python # -*- coding: utf-8 -*- """ Usage: ./datprint <img> Options: -h --help Show this message """ from __future__ import print_function from dat2bmp import read if __name__ == '__main__': import numpy as np from docopt import docopt args = docopt(__doc__) img = np.array(re...
{ "alphanum_fraction": 0.5801687764, "author": null, "avg_line_length": 16.9285714286, "converted": null, "ext": "py", "file": null, "hexsha": "5310f498d7ee282ec72a2fb7d207f3c1e2bca4ed", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
# Introduction to Geometric Algebra Below I will try to motivate the case for Geometric Algebra (GA) using rotation of vectors in various spaces and compare to the other most common approaches. (Source: https://commons.wikimedia.org/wiki/File:Counterclockwise_rotation.png) Prerequisites - Rotation matrices: good to...
{ "alphanum_fraction": 0.6490641145, "author": null, "avg_line_length": 60.7043701799, "converted": true, "ext": "ipynb", "file": null, "hexsha": "ad2563ce43b6a3792ba01c70e94489651063bd7d", "include": null, "lang": "Jupyter Notebook", "length": null, "llama_tokens": null, "mathlib_filename": nul...
import cv2 as cv import sys import math import numpy as np from time import time import image_utils as imutils import Condensation as cons #OpenCV default trackers begin class boostingTracking: def __init__(self, frame, bbox): self.tracker = cv.TrackerBoosting_create() self.tracker.init(frame, bb...
{ "alphanum_fraction": 0.5790378876, "author": null, "avg_line_length": 36.6092592593, "converted": null, "ext": "py", "file": null, "hexsha": "0fd507ae5dd03912901e58a412480c2741f96a10", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
"""Module contains Methods used for figuring out which/how many factors to retain """ import numpy as np from fa_kit.broken_stick import BrokenStick def retain_top_n(vals, num_keep): """Retain the top N largest components""" if num_keep < 1: raise ValueError( "Must select num_keep >= 1 w...
{ "alphanum_fraction": 0.6446099912, "author": null, "avg_line_length": 26.2298850575, "converted": null, "ext": "py", "file": null, "hexsha": "6e6b7756b05a1e30c86e196d5881963d5c42d1c6", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
# This file is part of the OLD Sage notebook and is NOT actively developed, # maintained, or supported. As of Sage v4.1.2, all notebook development has # moved to the separate Sage Notebook project: # # http://nb.sagemath.org/ # # The new notebook is installed in Sage as an spkg (e.g., sagenb-0.3.spkg). # # Please vis...
{ "alphanum_fraction": 0.5203117144, "author": null, "avg_line_length": 32.7677100494, "converted": null, "ext": "py", "file": null, "hexsha": "5e62e452d4a4e16af58f6a31f526f74cb51e0153", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
#! /usr/bin/env python import os import argparse import json import cv2 from utils.utils import get_yolo_boxes from utils.colors import get_color from keras.models import load_model import numpy as np import glob from lxml import etree as ET def _main_(args): config_path = args.conf with open(...
{ "alphanum_fraction": 0.6092472512, "author": null, "avg_line_length": 37.3368421053, "converted": null, "ext": "py", "file": null, "hexsha": "b794303b7cedcd61e4c48ac4e8a2412bc3d49e1c", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
""" Collection of novelty-based metrics """ from collections import defaultdict import os import matplotlib.pyplot as plt import numpy as np from reclist.current import current def gini_index_at_k(y_preds, candidate_list, k: int=10, debug: bool=False) -> float: no_items = len(set(candidate_list)) all_preds ...
{ "alphanum_fraction": 0.6286554485, "author": null, "avg_line_length": 37.7839506173, "converted": null, "ext": "py", "file": null, "hexsha": "ae2cc565f697a3b61c185d45857a294e4d44aeb8", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
# !/usr/bin/python3 # -*-coding utf-8 -*- # @Time : 2021/06/11 10:59 # @Author : Francisco Muñoz # @Project : evolution_of_species # @File : validators.py # @Software : PyCharm from abc import ABC, abstractmethod import numpy as np _SET_A_COPY = False _GET_A_COPY = True def validate_index(item): """...
{ "alphanum_fraction": 0.5955522051, "author": null, "avg_line_length": 40.196969697, "converted": null, "ext": "py", "file": null, "hexsha": "2679a8227077ec84fdbe1fdab85b4b53b3b6a887", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_fork...
import os import json import numpy as np from keras.utils import Sequence from .utils import get_datetime_now from .utils import string2shape from .utils import shape2string from .utils import timesequence_generator from .utils import create_one_hots_from_labels from .utils import one_hot_encode from .waves import Wave...
{ "alphanum_fraction": 0.523393802, "author": null, "avg_line_length": 38.7976539589, "converted": null, "ext": "py", "file": null, "hexsha": "3569d8ab8e1c1bb81bf7bb5cf91cb436de66222d", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_fork...
#!/usr/bin/env python # -*- coding: utf-8 -*- # pylint: disable=missing-docstring import os import shutil import tqdm import numpy as np from pycocotools.coco import COCO from coco.label import coco91_labels def coco91_to_yolo_id(yolo_names_file, coco_labels=coco91_labels()): coco_names = np.array(coco_labels) y...
{ "alphanum_fraction": 0.6824592331, "author": null, "avg_line_length": 34.641221374, "converted": null, "ext": "py", "file": null, "hexsha": "85597fd3d033f2c18b68228b69bffeae7277b536", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_fork...
using Yao using QuDiffEq using LinearAlgebra using BitBasis using Random using Test using YaoBlocks using OrdinaryDiffEq #Linear Diff Equation Unitary M function f(du,u,p,t) du[1] = -3*u[1]^2 + u[2] du[2] = -u[2]^2 - u[1]*u[2] end @testset "QuNLDE_Test" begin Random.seed!(4) N = 2 k = 3 siz = n...
{ "alphanum_fraction": 0.5835777126, "author": null, "avg_line_length": 24.3571428571, "converted": null, "ext": "jl", "file": null, "hexsha": "62d3aeb321b262cf80c444cba7ecc0e664ee6f52", "include": null, "lang": "Julia", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_fork...
SUBROUTINE MF_INTROE c*********************************************************************** c This routine interpolates values of the elements of the magneto- c ionic reflection matrix. Entry INIT OE determines the coefficients c for the interpolation series if this kind of interpolation can be c ...
{ "alphanum_fraction": 0.5386081983, "author": null, "avg_line_length": 31.47, "converted": null, "ext": "for", "file": null, "hexsha": "db4f8753b8b78723345c732a32700009d5b43462", "include": null, "lang": "FORTRAN", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_forks_cou...
# Import only import pandas as pd import pdb from sklearn.model_selection import train_test_split import numpy as np import matplotlib.pyplot as plt from sklearn.externals import joblib import seaborn as sns from a_detection import AnomalyDetection from feature_analysis import FeatureAnalysis from sklearn.feature_extra...
{ "alphanum_fraction": 0.6327712056, "author": null, "avg_line_length": 38.2632423756, "converted": null, "ext": "py", "file": null, "hexsha": "3155d259ee5b87b790435d8cd2078a3ded9aeaea", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
from __future__ import division import mxnet as mx import numpy as np import cv2 __all__ = ['FaceGenderage', 'genderage_v1', 'get_genderage'] class FaceGenderage: def __init__(self, name, download, param_file): self.name = name self.download = download self.param_file = param_file ...
{ "alphanum_fraction": 0.5777426993, "author": null, "avg_line_length": 34.2432432432, "converted": null, "ext": "py", "file": null, "hexsha": "69f56e12696dd8cbc87bc66538c933bbe1794142", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
import os import numpy as np import pytest from napari_svg import napari_get_writer from napari.layers import Image, Labels, Points, Shapes, Vectors @pytest.fixture def layer_data_and_types(): np.random.seed(0) layers = [ Image(np.random.rand(20, 20)), Labels(np.random.randint(10, ...
{ "alphanum_fraction": 0.6821963394, "author": null, "avg_line_length": 26.4175824176, "converted": null, "ext": "py", "file": null, "hexsha": "f4f8ac48bcc18b69231760309200fe77cd389fd6", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
/*============================================================================= Copyright (c) 2009 Hartmut Kaiser Copyright (c) 2014 Joel de Guzman Distributed under the Boost Software License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) ...
{ "alphanum_fraction": 0.6033674709, "author": null, "avg_line_length": 35.5617283951, "converted": null, "ext": "hpp", "file": null, "hexsha": "ba4edf1ccb98e0b7c64a516a8bc52d561b42fcf4", "include": null, "lang": "C++", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_forks...
# -*- coding: utf-8 -*- # @version : Python3.6 # @Time : 2017/4/30 15:48 # @Author : Jianyang-Hu # @contact : jianyang1993@163.com # @File : optfit_0430.py # @Software: PyCharm from matplotlib.finance import _quotes_historical_yahoo import numpy as np import matplotlib.pyplot as plt from scipy import fftpack fr...
{ "alphanum_fraction": 0.6947477899, "author": null, "avg_line_length": 23.7407407407, "converted": null, "ext": "py", "file": null, "hexsha": "6eef6d0531f2e07224b71e2241dbd281f74df2a6", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
import math import typing import mesh_tensorflow as mtf import numpy as np import tensorflow as tf from .backend import normal_var, orthogonal_var from .. import tf_wrapper as tfw from ..dataclass import BlockArgs, ModelParameter from ..mtf_wrapper import einsum, reshape, multiply, zeros_like from ..utils_core import...
{ "alphanum_fraction": 0.6373693291, "author": null, "avg_line_length": 42.4698275862, "converted": null, "ext": "py", "file": null, "hexsha": "754a793ce62ab078ccaa0bf890c93e8f36715305", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
import os import sys import shutil import numpy as np import time, datetime import torch import glob import random import logging import argparse import torch.nn as nn import torch.utils import torchvision.datasets as dset import torchvision.transforms as transforms import torch.backends.cudnn as cudnn from torch.autog...
{ "alphanum_fraction": 0.6633445509, "author": null, "avg_line_length": 31.406504065, "converted": null, "ext": "py", "file": null, "hexsha": "d59ef3a6a3c46bc77cdb98a982e4ec2181c1c26e", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_fork...
theorem impNot {p q : Prop} : p → ¬ q ↔ ¬ (p ∧ q) := ⟨ λ hpq h => hpq h.1 h.2, λ h hp hq => h <| And.intro hp hq ⟩ theorem Exists.impNot {p q : α → Prop} : (∃ x, p x → ¬ q x) ↔ ∃ x, ¬ (p x ∧ q x) := by apply Iff.intro intro h cases h with | intro x hx => { exact ⟨ x, λ hs => hx hs.1 hs.2 ⟩ } intro h ...
{ "alphanum_fraction": null, "author": "kbuzzard", "avg_line_length": null, "converted": null, "ext": null, "file": null, "hexsha": null, "include": null, "lang": null, "length": null, "llama_tokens": null, "mathlib_filename": null, "max_forks_count": null, "max_forks_repo_forks_event_max_da...
# Possible operators to add if we use block object # On(x,y) means block x is on top of block y # OnTable(x) --- block x is on the table # Clear(x) --- nothing is on top of block x # Holding(x) --- robot arm is holding block x # ArmEmpty() --- robot arm/hand is not holding anything (block in this world) # How complex ...
{ "alphanum_fraction": 0.5225634771, "author": null, "avg_line_length": 38.0548523207, "converted": null, "ext": "py", "file": null, "hexsha": "19b423c27a796bcbd06dd408fd0763b96cd234df", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
[STATEMENT] lemma quotient_map_imp_continuous_closed: assumes T: "f ` S \<subseteq> T" and ope: "\<And>U. U \<subseteq> T \<Longrightarrow> (closedin (top_of_set S) (S \<inter> f -` U) \<longleftrightarrow> closedin (top_of_set T) U)" shows "continuous_on S f" [PROOF...
{ "alphanum_fraction": null, "author": null, "avg_line_length": null, "converted": null, "ext": null, "file": null, "hexsha": null, "include": null, "lang": null, "length": 6, "llama_tokens": 407, "mathlib_filename": null, "max_forks_count": null, "max_forks_repo_forks_event_max_datetime": n...
[STATEMENT] lemma infer_v_g_weakening: fixes e::e and \<Gamma>'::\<Gamma> and v::v assumes "\<Theta>; \<B> ; \<Gamma> \<turnstile> v \<Rightarrow> \<tau>" and "toSet \<Gamma> \<subseteq> toSet \<Gamma>'" and "\<Theta> ; \<B> \<turnstile>\<^sub>w\<^sub>f \<Gamma>'" shows "\<Theta>; \<B> ; \<Gamma>' \<turnstil...
{ "alphanum_fraction": null, "author": null, "avg_line_length": null, "converted": null, "ext": null, "file": "MiniSail_TypingL", "hexsha": null, "include": null, "lang": null, "length": 80, "llama_tokens": 30640, "mathlib_filename": null, "max_forks_count": null, "max_forks_repo_forks_event...
############## # # This example demonstrates the basics of using `equinox.jitf` and `equinox.gradf`. # # Here we'll use them to facilitate training a simple MLP: to automatically take gradients and jit with respect to # all the jnp.arrays constituting the parameters. (But not with respect to anything else, like the cho...
{ "alphanum_fraction": 0.676739062, "author": null, "avg_line_length": 35.6966292135, "converted": null, "ext": "py", "file": null, "hexsha": "0c67cb21221dc8493263e86fdb59bca698563e60", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_fork...
import operator import logging import numpy as np from ..core.slot import SlotDescriptor from .module import TableModule from ..core.bitmap import bitmap from .table import Table logger = logging.getLogger(__name__) ops = {"<": operator.__lt__, "<=": operator.__le__, ">": operator.__gt__, ...
{ "alphanum_fraction": 0.5683388405, "author": null, "avg_line_length": 32.0096153846, "converted": null, "ext": "py", "file": null, "hexsha": "5094c52c672d621252685e462e594bd5989cb50c", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
import torch import torch.nn as nn from attention import Attention, NewAttention from language_model import WordEmbedding, QuestionEmbedding from classifier import SimpleClassifier from fc import FCNet import torch.nn.functional as F import torchvision as tv import utils import numpy as np def l2norm(X): """L2-nor...
{ "alphanum_fraction": 0.6105371019, "author": null, "avg_line_length": 36.2569659443, "converted": null, "ext": "py", "file": null, "hexsha": "23a50de2d5ab6e4d22d51c0859a596cc6e93d534", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
import numpy as np import tensorflow as tf import cv2 def get_result(img): # tf.gfile = tf.io.gfile mnist_model = tf.saved_model.load(r'model\mnist') print(mnist_model.signatures['serving_default'].inputs) print(mnist_model.signatures['serving_default'].output_dtypes) print(mnist_model.signatu...
{ "alphanum_fraction": 0.6790557509, "author": null, "avg_line_length": 31.6031746032, "converted": null, "ext": "py", "file": null, "hexsha": "af441d059fdbebce1ba6bd6a72c77cf425e0d839", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
from PyQt5.QtGui import QImage, QColor import sympy as sp def tand(x): return sp.tan(x * sp.pi / 180) def sind(x): return sp.sin(x * sp.pi / 180) def cosd(x): return sp.cos(x * sp.pi / 180) def invert(qImage) : rgb_im_inverse = qImage.copy() width = qImage.width() y = 0 while y < qImage....
{ "alphanum_fraction": 0.5056241427, "author": null, "avg_line_length": 24.4630872483, "converted": null, "ext": "py", "file": null, "hexsha": "f1614cb030bd58eaffe84b1f4a46a5c0afe4f3ff", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
from kinematicEnv import KinematicEnv from QL import QL from upDDPG import DDPG as uDDPG import tensorflow as tf from bottomDDPG import DDPG as bDDPG import numpy as np env = KinematicEnv() s_dim = env.state_dim a_dim = env.action_dim a_bound = env.action_bound g1 = tf.Graph() isess1 = tf.Session(graph=g1) with g1.as_...
{ "alphanum_fraction": 0.5060542797, "author": null, "avg_line_length": 28.1764705882, "converted": null, "ext": "py", "file": null, "hexsha": "698c3a55f3e93af01a220eadcc30ea0f28d5392f", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
c bad-flag specified spectral regions in the array c blankoutsky2 takes out the B-band as well as 5577 and the A-band c could also blank locations of possible strong em lines, mostly c 3727 and 5007, if we are using this for abs line fits. Or use c selectabsregions to exclude those. c blankoutlines is directly fr...
{ "alphanum_fraction": 0.6304541407, "author": null, "avg_line_length": 26.7380952381, "converted": null, "ext": "f", "file": null, "hexsha": "d99d79b92d835db68337a3282be8a6113b101d47", "include": null, "lang": "FORTRAN", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
""" examples/pong.py Copyright (c) 2020, Nir Aides - nir@winpdb.org 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 ...
{ "alphanum_fraction": 0.5796319018, "author": null, "avg_line_length": 24.8475609756, "converted": null, "ext": "py", "file": null, "hexsha": "5d2835d5758a8546991302240270141d4e4e0502", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
C C $Id: mstrms.f,v 1.4 2008-07-27 00:17:31 haley Exp $ C C Copyright (C) 2000 C University Corporation for Atmospheric Research C All Rights Reserved C C The use of this Software is governed by a License Agreeme...
{ "alphanum_fraction": 0.4741784038, "author": null, "avg_line_length": 33.8095238095, "converted": null, "ext": "f", "file": null, "hexsha": "b93a712c659b15e32f935123d452c7f8dd2f73f2", "include": null, "lang": "FORTRAN", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
[STATEMENT] lemma COND_terms_hf: assumes "hf_valid ainfo uinfo hfs hf" and "HVF hf \<in> ik" and "no_oracle ainfo uinfo" and "hf \<in> set hfs" shows "\<exists>hfs. hf \<in> set hfs \<and> (\<exists>uinfo' . (ainfo, hfs) \<in> auth_seg2 uinfo')" [PROOF STATE] proof (prove) goal (1 subgoal): 1. \<exists>hfs. hf \<...
{ "alphanum_fraction": null, "author": null, "avg_line_length": null, "converted": null, "ext": null, "file": "IsaNet_instances_ICING", "hexsha": null, "include": null, "lang": null, "length": 7, "llama_tokens": 2984, "mathlib_filename": null, "max_forks_count": null, "max_forks_repo_forks_e...
Require Import List Arith. Import ListNotations. Require Import core. Notation eqdec := eq_nat_dec. Require Import Lia. Module renSubst. Notation upT vs := (0 :: vs). (* Inductive fin : list nat -> Type := *) (* | finO : fin [0] *) (* | finS : forall l, fin l -> fin (List.map S l) *) (* | finU : forall l, ...
{ "alphanum_fraction": null, "author": "addap", "avg_line_length": null, "converted": null, "ext": null, "file": null, "hexsha": null, "include": null, "lang": null, "length": null, "llama_tokens": null, "mathlib_filename": null, "max_forks_count": null, "max_forks_repo_forks_event_max_datet...
#include <iostream> #include <cstdlib> #include <boost/uuid/uuid.hpp> #include <boost/uuid/uuid_generators.hpp> #include <boost/uuid/uuid_io.hpp> #include <EditorWindow.hpp> #include <ApplicationController.hpp> #include <CRDTManager.hpp> #include <VersionVector.hpp> #include <CustomMessageException.hpp> std::string gen...
{ "alphanum_fraction": 0.6966442953, "author": null, "avg_line_length": 32.3913043478, "converted": null, "ext": "cpp", "file": null, "hexsha": "7b6cf76510bbccc728235300e8980d2c26ff33d2", "include": null, "lang": "C++", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_forks...
\chapter{B Chapter} \lipsum[1] \ref{fig:frogger}\ref{fig:froggerr}. \begin{figure} \centering \caption{\label{fig:frogger}Another instance of the frog.} \includegraphics[width=0.3\textwidth]{frog.jpg} \end{figure} \begin{figure} \centering \caption{\label{fig:froggerr}And a third one.} \includ...
{ "alphanum_fraction": 0.6741957563, "author": null, "avg_line_length": 24.7627118644, "converted": null, "ext": "tex", "file": null, "hexsha": "7b826b67d41e98d85a90c65b6730fe86f4de5243", "include": null, "lang": "TeX", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_forks...
Network Graphs in R We are using the well-known social network of Zachary's karate club. GML format file can be collected from here. read graph file and update layout library(igraph) library(plotly) G <- read.graph("karate.gml", format = c("gml")) L <- layout.circle(G) vertices and edges for the graph ...
{ "alphanum_fraction": 0.6137096774, "author": null, "avg_line_length": 22.1428571429, "converted": null, "ext": "r", "file": null, "hexsha": "2aff5b8ce3a21486144a0d9f7c853add20e6d1ba", "include": null, "lang": "R", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_forks_cou...
''' --------------------------- Licensing and Distribution --------------------------- Program name: Q2DTor Version : 2020.1 License : MIT/x11 Copyright (c) 2020, David Ferro Costas (david.ferro@usc.es) and Antonio Fernandez Ramos (qf.ramos@usc.es) Permission is hereby granted, free of charge, to any perso...
{ "alphanum_fraction": 0.5001033664, "author": null, "avg_line_length": 38.4389701208, "converted": null, "ext": "py", "file": null, "hexsha": "da53fa7d3f422fecd4fc6831e3aa2556fad623db", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
#!/usr/bin/env python3 # encoding: utf-8 """ Copyright (c) 2021, salesforce.com, inc. All rights reserved. SPDX-License-Identifier: BSD-3-Clause For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause """ # Copyright 2017 Johns Hopkins University (Shinji Watanabe) ...
{ "alphanum_fraction": 0.6107835781, "author": null, "avg_line_length": 47.3553299492, "converted": null, "ext": "py", "file": null, "hexsha": "98c6cd158a74690322254efed260ea2143833985", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
"""The goedesic datasets in this folder provide even coverage over a sphere. Sometimes a more dense coverage is required in some part of the sphere. In such a case a composite file with extracts from several of the geodesic data files can be made. For example, suppose more dense coverage is required in a cone around ...
{ "alphanum_fraction": 0.6494252874, "author": null, "avg_line_length": 35.5909090909, "converted": null, "ext": "py", "file": null, "hexsha": "f8a885e5aad084cf5f333bd5d4656b25a54d4439", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
#!/usr/bin/env python """Compute summary statistics of data files. Computes summary statistics of data files such as the number of samples or the mean and variance of output variables. Examples -------- .. code:: bash dcpg_data_stats.py ./data/*.h5 """ from __future__ import print_function from __futu...
{ "alphanum_fraction": 0.5888580792, "author": null, "avg_line_length": 28.9562043796, "converted": null, "ext": "py", "file": null, "hexsha": "5c17cab2dc462fdee6d07f64d8f00b8a8fdc4405", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
# -*- coding: utf-8 -*- """ Created on Tue May 26 14:23:18 2020 @author: Thaileng_GIC """ #import csv import pandas as pd #import numpy as np season = ['-dry-2017', '-wet-2017', '-dry-2018', '-wet-2018'] for b in season: for a in range (1,2): data1=pd.read_csv('../Extract_CSV/Parameteriz...
{ "alphanum_fraction": 0.5539443684, "author": null, "avg_line_length": 41.5340909091, "converted": null, "ext": "py", "file": null, "hexsha": "edf9689dfc49eed900a9c07dfccef04c49d76884", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
if (!interactive()) { suppressMessages(getPass:::readline_nomask("asdf", noblank=FALSE)) }
{ "alphanum_fraction": 0.7204301075, "author": null, "avg_line_length": 18.6, "converted": null, "ext": "r", "file": null, "hexsha": "2191a5571a347923ff2871bfcf2bd457d7819445", "include": null, "lang": "R", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_forks_count": 6, ...
module multibox use fft_work, only: fft_type implicit none public :: read_multibox_parameters public :: init_multibox public :: finish_multibox public :: multibox_communicate public :: init_mb_get_phi public :: mb_get_phi public :: communicate_multibox_parameters public :: add_multibox_krook pu...
{ "alphanum_fraction": 0.6126653307, "author": null, "avg_line_length": 32.0145423439, "converted": null, "ext": "fpp", "file": null, "hexsha": "4dfd1e9777416840338690c34ecdadff96858a6e", "include": null, "lang": "FORTRAN", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_f...
from astropy import units as u from astropy.coordinates import FK5, Galactic def fk52gal(ra, dec): c = FK5(ra * u.deg, dec * u.deg) out = c.transform_to(Galactic()) return out.l.degree, out.b.degree def gal2fk5(l, b): c = Galactic(l * u.deg, b * u.deg) out = c.transform_to(FK5()) return out....
{ "alphanum_fraction": 0.645232816, "author": null, "avg_line_length": 20.976744186, "converted": null, "ext": "py", "file": null, "hexsha": "6cf09dfa22047f2e765fd471a26ead5187da1818", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_forks...
# --- # title: 480. Sliding Window Median # id: problem480 # author: Indigo # date: 2021-02-03 # difficulty: Hard # categories: Sliding Window # link: <https://leetcode.com/problems/sliding-window-median/description/> # hidden: true # --- # # Median is the middle value in an ordered integer list. If the size of the li...
{ "alphanum_fraction": 0.5522540984, "author": null, "avg_line_length": 29.1343283582, "converted": null, "ext": "jl", "file": null, "hexsha": "33b16ce07cfb557ad2acce8ec32badaa10dd2036", "include": null, "lang": "Julia", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_fork...
from ms2ldaviz.celery_tasks import app from django.db import transaction import numpy as np import pandas as pd from keras.models import load_model from basicviz.models import Document, FeatureInstance from annotation.models import SubstituentTerm, SubstituentInstance @app.task def predict_substituent_terms(expe...
{ "alphanum_fraction": 0.6399322225, "author": null, "avg_line_length": 38.0752688172, "converted": null, "ext": "py", "file": null, "hexsha": "d73324bb7bd5ccfb69c328540279db0b080377fc", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
from src.vehicle import Vehicle from src.visualiser import Vis from src.track import TrackHandler from src.ga import GeneticAlgorithm from src.ga import IslandGA from src.lidar import Lidar from sandbox.game_pad_inputs import GamePad import numpy as np from time import sleep import time import multiprocessing from jobl...
{ "alphanum_fraction": 0.5642382731, "author": null, "avg_line_length": 37.3488372093, "converted": null, "ext": "py", "file": null, "hexsha": "e57a55a1efa926c7219f22ccb40305b9268487d9", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
#include "Cache.hpp" #include "Sha256.hpp" #include <fstream> #include <streambuf> #include <boost/filesystem/operations.hpp> SourceCache::SourceCache(std::string const & path, std::string const & targetName) : m_cacheFileName(path + "/" + targetName + ".gen_cache") { } SourceCache::~SourceCache() { } void Sourc...
{ "alphanum_fraction": 0.6504657756, "author": null, "avg_line_length": 23.7403846154, "converted": null, "ext": "cpp", "file": null, "hexsha": "61ddfd12ae25f721151b2402738b043c04eda486", "include": null, "lang": "C++", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_forks...
import pygame import datetime import numpy as np class Display: WHITE = (255, 255, 255) BLACK = (0, 0, 0) RED = (255, 0, 0) GREEN = (0, 255, 0) DARKGREEN = (0, 155, 0) DARKGRAY = (40, 40, 40) BGCOLOR = BLACK BLACK = (0,0,0) text_surface_height = 20 def __init__(self, window_wi...
{ "alphanum_fraction": 0.6260404281, "author": null, "avg_line_length": 38.8153846154, "converted": null, "ext": "py", "file": null, "hexsha": "92b42c47c1d93d9d1474a06a17a79426e6ff0d64", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
''' Code Author: Siyun WANG ''' from EMST import * # git repo: https://github.com/ChatCatKatzeNeko/EMST import numpy as np import scipy class EMSTBasedClustering(): def __init__(self, emst): ''' emst: EMST object ''' self.emst = emst self.nbVertices = self.emst.nbVertices...
{ "alphanum_fraction": 0.5554908001, "author": null, "avg_line_length": 34.2193732194, "converted": null, "ext": "py", "file": null, "hexsha": "a61a8a3933c5e5ac542725818cbe2e052c4847bd", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
import numpy as np import matplotlib.pyplot as plt import mplhep as hep plt.switch_backend("agg") plt.rcParams.update({"font.size": 16}) plt.style.use(hep.style.CMS) def plot_part_feats( jet_type, real_jets, gen_jets, real_mask=None, gen_mask=None, coords="polarrel", name=None, figs_p...
{ "alphanum_fraction": 0.5271223022, "author": null, "avg_line_length": 35.0125944584, "converted": null, "ext": "py", "file": null, "hexsha": "88e38aa829e442f8ca2442e6d77c8e94275a9d82", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
# import numpy as np # r= [1.0,1.0,1.0,-1.0,1.0,1.0] # gamma = 0.5 # # r = np.array(r) # discounted_r = np.zeros_like(r) # running_add = 0 # # we go from last reward to first one so we don't have to do exponentiations # for t in reversed(range(0, r.size)): # if r[t] != 0: # running_add = 0 # if the game end...
{ "alphanum_fraction": 0.6845915202, "author": null, "avg_line_length": 27.6285714286, "converted": null, "ext": "py", "file": null, "hexsha": "7db35a55817528e506a33793c2343caa2f6f0d96", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
[STATEMENT] lemma l2_inv2_init [iff]: "init l2 \<subseteq> l2_inv2" [PROOF STATE] proof (prove) goal (1 subgoal): 1. init l2 \<subseteq> l2_inv2 [PROOF STEP] by (auto simp add: l2_def l2_init_def l2_inv2_def)
{ "alphanum_fraction": null, "author": null, "avg_line_length": null, "converted": null, "ext": null, "file": "Key_Agreement_Strong_Adversaries_pfslvl2", "hexsha": null, "include": null, "lang": null, "length": 1, "llama_tokens": 99, "mathlib_filename": null, "max_forks_count": null, "max_fo...
# -*- coding: utf-8 -*- """ Created on Tue Jul 24 14:17:51 2018 def backward_calc(self,ic,num_compartments,target_conc = 1,target_emiss = 1): @author: Tim Rodgers """ import numpy as np import pandas as pd num_compartments = 7 target_emiss = 1 target_conc = 3 #Initialize outputs col_name = pd.Series(index = range(num_...
{ "alphanum_fraction": 0.6207799005, "author": null, "avg_line_length": 47.1728395062, "converted": null, "ext": "py", "file": null, "hexsha": "808f60e0521f71399bf1f99d8442640fb335b8b4", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
C C $Id: pcsetc.f,v 1.15 2008-07-27 00:17:20 haley Exp $ C C Copyright (C) 2000 C University Corporation for Atmospheric Research C All Rights Reserved C C The use of this Software is governed by a License Agreem...
{ "alphanum_fraction": 0.593539055, "author": null, "avg_line_length": 30.5, "converted": null, "ext": "f", "file": null, "hexsha": "d26ae5780cd6628da20d0d7e63cd69576cabe915", "include": null, "lang": "FORTRAN", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_forks_count":...
[STATEMENT] lemma unit_counit_G: assumes "C.ide x" shows "G x = G (\<epsilon>o x) \<cdot>\<^sub>D \<eta>o (G x)" [PROOF STATE] proof (prove) goal (1 subgoal): 1. G x = G (\<epsilon>o x) \<cdot>\<^sub>D \<eta>o (G x) [PROOF STEP] using assms \<phi>_in_terms_of_\<eta>o \<epsilon>o_def \<phi>_\<psi> \<epsilon>o_i...
{ "alphanum_fraction": null, "author": null, "avg_line_length": null, "converted": null, "ext": null, "file": "Category3_Adjunction", "hexsha": null, "include": null, "lang": null, "length": 2, "llama_tokens": 467, "mathlib_filename": null, "max_forks_count": null, "max_forks_repo_forks_even...
"""Embed text of list of tesxts.""" from typing import List, Union import more_itertools as mit # import numpy as np from logzero import logger from alive_progress import alive_bar from fetch_embed import fetch_embed # fmt: off def embed_text( text: Union[str, List[str]], chunk_size: int = 32, livepbar...
{ "alphanum_fraction": 0.5933884298, "author": null, "avg_line_length": 22.8301886792, "converted": null, "ext": "py", "file": null, "hexsha": "e5994a27a54c126ed3730f0f37ef4afb71dfa2d4", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
import os, sys, time import pandas as pd import matplotlib.pyplot as plt import seaborn as sns import math import sys import os import pickle import logging import coloredlogs import numpy as np from codetiming import Timer from datetime import datetime import inspect import json from ast import literal_eval import ma...
{ "alphanum_fraction": 0.5387814138, "author": null, "avg_line_length": 34.3540372671, "converted": null, "ext": "py", "file": null, "hexsha": "76d11a4a3a34b53ed75fbb0b006f37a519af2ebe", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # Description # ============================================================================== # # Functions to process and print the table title. # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # """ ...
{ "alphanum_fraction": 0.5943661972, "author": null, "avg_line_length": 29.2352941176, "converted": null, "ext": "jl", "file": null, "hexsha": "6127a74af987ee26b9e449fd2a8ba6118b3a39ed", "include": null, "lang": "Julia", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_fork...
import numpy as np import sys import os #import faiss import time from tsnecuda import TSNE from sklearn.datasets import make_classification num_points = int(sys.argv[1]) num_dims = int(sys.argv[2]) sep = int(sys.argv[3]) k = int(sys.argv[4]) option = int(sys.argv[5]) reorder = int(sys.argv[6]) num_clusters = int(s...
{ "alphanum_fraction": 0.6937965261, "author": null, "avg_line_length": 23.9880952381, "converted": null, "ext": "py", "file": null, "hexsha": "469d3af2d81c89aaac7d7452028b6a2c56171b50", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
# test neutral_models context("neutral model functions") test_that("calculating expected K for a population in a WFIA model works", { n <- 2000 t <- 20 observed <- expected_k_pop(n,t) expected <- 81.2528 expect_equal(expected, observed, tolerance=0.1) })
{ "alphanum_fraction": 0.6996336996, "author": null, "avg_line_length": 19.5, "converted": null, "ext": "r", "file": null, "hexsha": "003e9d50af972fced25910db02398f9c00ee2e36", "include": null, "lang": "R", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_forks_count": null...
[STATEMENT] lemma ivp_solsD: assumes "X \<in> Sols f U S t\<^sub>0 s" shows "D X = (\<lambda>t. f t (X t)) on U s" and "X t\<^sub>0 = s" and "X \<in> U s \<rightarrow> S" and "t\<^sub>0 \<in> U s" [PROOF STATE] proof (prove) goal (1 subgoal): 1. ( D X = (\<lambda>t. f t (X t)) on U s &&& X t\<^sub>0 = s) &&& ...
{ "alphanum_fraction": null, "author": null, "avg_line_length": null, "converted": null, "ext": null, "file": "Hybrid_Systems_VCs_HS_ODEs", "hexsha": null, "include": null, "lang": null, "length": 3, "llama_tokens": 454, "mathlib_filename": null, "max_forks_count": null, "max_forks_repo_fork...
#!/usr/bin/python from ctwc__common import * import numpy as np INITIALIZED = False PLOT_RAW_FILE = RESULTS_PATH+'plot_raw-{0}.pklz' PLOT_MAT_RAW_FILE = RESULTS_PATH+'plot_raw_mat-{0}.npz' PLOT_PNG_FILE = RESULTS_PATH+'plot-{0}.png' SHOW_ON_SCREEN = False def plot_mat(mat, xlabel=None, ylabel=None, header=None): ...
{ "alphanum_fraction": 0.633432172, "author": null, "avg_line_length": 28.4, "converted": null, "ext": "py", "file": null, "hexsha": "cc089f3db48e2b0f6b64f0e3ee50295f47901682", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_forks_count":...
import numpy as np from sklearn.manifold import Isomap from vx.com.py.projection.Projection import * class LDA(Projection): def __init__(self, X=None, p=2): super().__init__(X,p) def execute(self): #X = self.X X = np.array(self.X) X2 = Isomap(n_components=self.p).fit_transfo...
{ "alphanum_fraction": 0.6187845304, "author": null, "avg_line_length": 21.2941176471, "converted": null, "ext": "py", "file": null, "hexsha": "180db58b1752e66628b305b954db390b71238b1e", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
# Gross-Nevue ground state using DMRG include("Schollwock.jl") using DelimitedFiles using Plots using LsqFit using DataFrames using CSV function Hss(m₀::Float64,g₀::Float64,r::Float64,n::Int;ϵ=0.0) a = 1.0/(n+1) a⁺ = [0.0 0.0; 1.0 0.0] a⁻ = [0.0 1.0; 0.0 0.0] Z = [1.0 0.0; ...
{ "alphanum_fraction": 0.535748839, "author": null, "avg_line_length": 40.375, "converted": null, "ext": "jl", "file": null, "hexsha": "b6831efa2e90b005c9ba80ef7bf56b3a9b517497", "include": null, "lang": "Julia", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_forks_count"...
from flask import Blueprint, render_template, redirect, url_for, request, flash, abort, make_response, Response import os from .import db from .models import Iron from .models import User from werkzeug.utils import secure_filename from flask_login import login_required, current_user import pdfkit import numpy as np fro...
{ "alphanum_fraction": 0.6687657431, "author": null, "avg_line_length": 26.2479338843, "converted": null, "ext": "py", "file": null, "hexsha": "ebf3e37f1be4d23375c952be758df52d2cbcd0e5", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
c ======================================================= subroutine src2(maxmx,maxmy,meqn,mbc,mx,my,xlower,ylower, & dx,dy,q,maux,aux,t,dt,Rsphere) c ======================================================= c c c # Compute source term for Rossby-Haurwitz wave. c # The sourc...
{ "alphanum_fraction": 0.4527764594, "author": null, "avg_line_length": 28.472972973, "converted": null, "ext": "f", "file": null, "hexsha": "3bf392ad793369b130095976d029bf88e49401f7", "include": null, "lang": "FORTRAN", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_fork...
(* Copyright (c) 2012-2015, Robbert Krebbers. *) (* This file is distributed under the terms of the BSD license. *) Require Export types integer_operations. Local Open Scope ctype_scope. Local Unset Elimination Schemes. Class Env (K : iType) : iType := { env_type_env :> IntEnv K; size_of : env K → type K → nat; ...
{ "alphanum_fraction": null, "author": "robbertkrebbers", "avg_line_length": null, "converted": null, "ext": null, "file": null, "hexsha": null, "include": null, "lang": null, "length": null, "llama_tokens": null, "mathlib_filename": null, "max_forks_count": null, "max_forks_repo_forks_event...
! ********************************************************************* ! * * ! * function dcvaa3 * ! * * ! *********************...
{ "alphanum_fraction": 0.5199188759, "author": null, "avg_line_length": 41.3353293413, "converted": null, "ext": "f95", "file": null, "hexsha": "af46f7bb9f15990bec3d63fde82fe58d6ef31966", "include": null, "lang": "FORTRAN", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_f...
# 可视化中间输出 from keras.models import load_model import matplotlib.pyplot as plt from keras import models import numpy as np from keras.preprocessing import image model = load_model('cats_dogs.h5') # 加载之前保存的卷积模型 # 预处理单张图片 img = image.load_img('./cats.jpg', target_size=(150, 150)) img_tensor = image.img_to_array(img) im...
{ "alphanum_fraction": 0.6624671916, "author": null, "avg_line_length": 33.4210526316, "converted": null, "ext": "py", "file": null, "hexsha": "4c7d1affed73ea50bb56cde2ebe68f4df9c8dfc9", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
using Gtk, Cairo, ColorTypes function generategrays(n, screenwidth) verts = Vector{RGB}() hwidth = Int(ceil(screenwidth/n)) for x in 00:Int(floor(0xff/(n-1))):0xff rgbgray = RGB(x/255, x/255, x/255) for i in 1:hwidth push!(verts, rgbgray) end end verts end funct...
{ "alphanum_fraction": 0.6156417112, "author": null, "avg_line_length": 26.7142857143, "converted": null, "ext": "jl", "file": null, "hexsha": "44c0cbb968c54db94e6841a0c55604b5b27ab8df", "include": null, "lang": "Julia", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_fork...
[STATEMENT] lemma "\<exists>x. f x = g x \<longrightarrow> f = g" [PROOF STATE] proof (prove) goal (1 subgoal): 1. \<exists>x. f x = g x \<longrightarrow> f = g [PROOF STEP] refute [maxsize = 4, expect = none] [PROOF STATE] proof (prove) goal (1 subgoal): 1. \<exists>x. f x = g x \<longrightarrow> f = g [PROOF STEP] ...
{ "alphanum_fraction": null, "author": null, "avg_line_length": null, "converted": null, "ext": null, "file": null, "hexsha": null, "include": null, "lang": null, "length": 2, "llama_tokens": 142, "mathlib_filename": null, "max_forks_count": null, "max_forks_repo_forks_event_max_datetime": n...
[STATEMENT] lemma mem_val_w32_8_mem_equal: assumes a1: "mem_equal s1 s2 a" shows "mem_val_w32 8 a s1 = mem_val_w32 8 a s2" [PROOF STATE] proof (prove) goal (1 subgoal): 1. mem_val_w32 8 a s1 = mem_val_w32 8 a s2 [PROOF STEP] apply (simp add: mem_val_w32_def) [PROOF STATE] proof (prove) goal (1 subgoal): 1. (let addr...
{ "alphanum_fraction": null, "author": null, "avg_line_length": null, "converted": null, "ext": null, "file": "SPARCv8_SparcModel_MMU_Sparc_Properties", "hexsha": null, "include": null, "lang": null, "length": 13, "llama_tokens": 26421, "mathlib_filename": null, "max_forks_count": null, "max...
#include "utf.h" #define BOOST_UTF8_BEGIN_NAMESPACE namespace utf { namespace detail { #define BOOST_UTF8_END_NAMESPACE }} #define BOOST_UTF8_DECL #include "detail/utf8_codecvt_facet.hpp" #include "detail/utf8_codecvt_facet.cpp" #undef BOOST_UTF8_DECL #undef BOOST_UTF8_END_NAMESPACE #undef BOOST_UTF8_BEGIN_NAMESPACE...
{ "alphanum_fraction": 0.6235906331, "author": null, "avg_line_length": 33.6642335766, "converted": null, "ext": "cpp", "file": null, "hexsha": "bf637f71c7abdad60516ce18fd11fba8d7e8d426", "include": null, "lang": "C++", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_forks...
module caf_co_sum_test use caffeine_m, only : caf_co_sum, caf_num_images, caf_this_image use vegetables, only: result_t, test_item_t, assert_equals, describe, it, assert_that, assert_equals, succeed implicit none private public :: test_caf_co_sum contains function test_caf_co_sum() result(test...
{ "alphanum_fraction": 0.6536796537, "author": null, "avg_line_length": 37.95, "converted": null, "ext": "f90", "file": null, "hexsha": "8ab48df1495c1df89033dbc3f32527ea37d8adaf", "include": null, "lang": "FORTRAN", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_forks_cou...
{-# language FlexibleContexts #-} {-# language GADTs #-} {-# language ScopedTypeVariables #-} {-# language TypeApplications #-} module Verify where import Feldspar import Feldspar.Software import Feldspar.Software.Verify import Feldspar.Array.Vector import Feldspar.Array.Buffered import Data.Bits (Bits) import Data....
{ "alphanum_fraction": 0.5392438647, "author": null, "avg_line_length": 27.9197530864, "converted": null, "ext": "hs", "file": null, "hexsha": "15b3482c7c4460d72bffdc525a7af49c63e34f17", "include": null, "lang": "Haskell", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_fo...
[STATEMENT] lemma "e1.hf_valid ainfo uinfo hfBl (Some hfAl)" [PROOF STATE] proof (prove) goal (1 subgoal): 1. e1.hf_valid (Num 0) 1 hfBl (Some hfAl) [PROOF STEP] apply (auto simp add: e1.hf_valid_invert hfAl_def hfBl_def) [PROOF STATE] proof (prove) goal (2 subgoals): 1. Ex (d0.ASIF (Some nB)) 2. Ex (d0.ASIF None) [...
{ "alphanum_fraction": null, "author": null, "avg_line_length": null, "converted": null, "ext": null, "file": "IsaNet_instances_EPIC_L1_SA_Example", "hexsha": null, "include": null, "lang": null, "length": 3, "llama_tokens": 575, "mathlib_filename": null, "max_forks_count": null, "max_forks_...
\documentclass[12pt]{amsart} \usepackage{geometry} % see geometry.pdf on how to lay out the page. There's lots. \geometry{a4paper} % or letter or a5paper or ... etc % \geometry{landscape} % rotated page geometry \usepackage{listings} \usepackage{hyperref} \lstnewenvironment{code}{\lstset{language=Haskell,basicstyle=\sm...
{ "alphanum_fraction": 0.770755886, "author": null, "avg_line_length": 25.21875, "converted": null, "ext": "tex", "file": null, "hexsha": "e7763cbf9fa475bfcac587c43e0cce332aaed40c", "include": null, "lang": "TeX", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_forks_count...
function csqrt(z1) complex csqrt, z1, z2 dimension dummy(2) equivalence (a,z2,dummy(1)), (b,dummy(2)) z2 = z1 c = cabs(z2) c = sqrt(c) b = atan2(b, a)/2.0 a = c*cos(b) b = c*sin(b) csqrt = z2 return end
{ "alphanum_fraction": 0.5898617512, "author": null, "avg_line_length": 14.4666666667, "converted": null, "ext": "f", "file": null, "hexsha": "bdafe2833ab5913771e736c9ed42578f993d66b0", "include": null, "lang": "FORTRAN", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
(************************************************************************* * Copyright (C) * 2019-2022 The University of Exeter * 2018-2022 The University of Paris-Saclay * 2018 The University of Sheffield * * License: * This program can be redistributed and/or ...
{ "alphanum_fraction": null, "author": "logicalhacking", "avg_line_length": null, "converted": null, "ext": null, "file": null, "hexsha": null, "include": null, "lang": null, "length": null, "llama_tokens": null, "mathlib_filename": null, "max_forks_count": null, "max_forks_repo_forks_event_...
import sys import unittest import numpy import ideep4py from ideep4py import intVector, mdarrayVector, concat try: import testing except Exception as ex: print('*** testing directory is missing: %s' % ex) sys.exit(-1) @testing.parameterize(*testing.product_dict( [ {'shape': (7, 2, 3, 5), 'ax...
{ "alphanum_fraction": 0.5293107677, "author": null, "avg_line_length": 39.5825242718, "converted": null, "ext": "py", "file": null, "hexsha": "5eeeaf1039fd4866a1ae0d6ff80c70cf266eecb0", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
Require Import Fiat.BinEncoders.Env.Common.Notations Fiat.BinEncoders.Env.Common.Specs Fiat.BinEncoders.Env.Common.ComposeOpt. Require Export Coq.Lists.List. Notation "| ls |" := (Datatypes.length ls) : binencoders_scope. Section FixList. Context {A : Type}. Context {B : Type}. C...
{ "alphanum_fraction": null, "author": "proofskiddie", "avg_line_length": null, "converted": null, "ext": null, "file": null, "hexsha": null, "include": null, "lang": null, "length": null, "llama_tokens": null, "mathlib_filename": null, "max_forks_count": null, "max_forks_repo_forks_event_ma...
from grpc.beta import implementations import numpy as np import tensorflow as tf from tensorflow_serving.apis import predict_pb2 from tensorflow_serving.apis import prediction_service_pb2 hostport = 'localhost:9000' def do_prediction(hostport): # Create connection host, port = hostport.split(':') channel = im...
{ "alphanum_fraction": 0.7523012552, "author": null, "avg_line_length": 28.4523809524, "converted": null, "ext": "py", "file": null, "hexsha": "2b50f215c061a86dd2b4d380bdb87c2165c6c01d", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
#!/usr/bin/python ''' Learning Machines Taught by Patrick Hebron at NYU ITP MNIST dataset helpers. ''' import os import gzip import pickle import numpy as np def mnist_encode_one_hot_label(idx): '''MNIST one-hot encoder function''' enc = np.zeros( 10 ) enc[ idx ] = 1.0 return enc def mnist_decode_one_hot_label...
{ "alphanum_fraction": 0.7254261879, "author": null, "avg_line_length": 33.6219512195, "converted": null, "ext": "py", "file": null, "hexsha": "8133065176d9db57ef092d3746709a8e45af348a", "include": true, "lang": "Python", "length": null, "llama_tokens": null, "mathlib_filename": null, "max_for...
[STATEMENT] lemma mcont2mcont_tset [THEN lfp.mcont2mcont, cont_intro]: shows mcont_tset: "mcont tSup tllist_ord Union (\<subseteq>) tset" [PROOF STATE] proof (prove) goal (1 subgoal): 1. mcont local.tSup local.tllist_ord \<Union> (\<subseteq>) tset [PROOF STEP] including tllist.lifting [PROOF STATE] proof (prove) go...
{ "alphanum_fraction": null, "author": null, "avg_line_length": null, "converted": null, "ext": null, "file": "Coinductive_TLList_CCPO", "hexsha": null, "include": null, "lang": null, "length": 5, "llama_tokens": 719, "mathlib_filename": null, "max_forks_count": null, "max_forks_repo_forks_e...
function exportDVHData(command) %GUI to export a DVH data file starting with a DVH plot of one or more VOI's. %VOI's must be renamed to agree with a standard list stored in optS.defaultVOINames. %DVH data may then be exported to a delimited text file. % %KU 04/14/2006 % % Copyright 2010, Joseph O. Deasy, on behalf of ...
{ "alphanum_fraction": null, "author": "cerr", "avg_line_length": null, "converted": null, "ext": null, "file": null, "hexsha": null, "include": null, "lang": null, "length": null, "llama_tokens": null, "mathlib_filename": null, "max_forks_count": null, "max_forks_repo_forks_event_max_dateti...
[STATEMENT] lemma distinguished_bounded_support: assumes "x distinguishes P from Q" obtains y where "supp y \<subseteq> supp P" and "y distinguishes P from Q" [PROOF STATE] proof (prove) goal (1 subgoal): 1. (\<And>y. \<lbrakk>supp y \<subseteq> supp P; y distinguishes P from Q\<rbrakk> \<Longrightarrow> thesi...
{ "alphanum_fraction": null, "author": null, "avg_line_length": null, "converted": null, "ext": null, "file": "Modal_Logics_for_NTS_Equivalence_Implies_Bisimilarity", "hexsha": null, "include": null, "lang": null, "length": 92, "llama_tokens": 9705, "mathlib_filename": null, "max_forks_count":...
[STATEMENT] lemma not_ide_fromArr: shows "\<not> ide (fromArr x)" [PROOF STATE] proof (prove) goal (1 subgoal): 1. \<not> ide (fromArr x) [PROOF STEP] using fromArr_def ide_char ide_def Zero_def One_def [PROOF STATE] proof (prove) using this: fromArr ?x \<equiv> if ?x \<in> Arr then MkArr False True [?x] else null...
{ "alphanum_fraction": null, "author": null, "avg_line_length": null, "converted": null, "ext": null, "file": "Category3_FreeCategory", "hexsha": null, "include": null, "lang": null, "length": 2, "llama_tokens": 291, "mathlib_filename": null, "max_forks_count": null, "max_forks_repo_forks_ev...
theory "Ids" imports Complex_Main "HOL-Library.Code_Target_Int" "Syntax" begin (*Differential dynamic logic can be defined for any finite types, given a few elements of those types (so that we can generate axioms). *) (*locale ids = fixes vid1 :: ident fixes vid2 :: ident fixes vid3 :: ident fixes i...
{ "alphanum_fraction": null, "author": "LS-Lab", "avg_line_length": null, "converted": null, "ext": null, "file": null, "hexsha": null, "include": null, "lang": null, "length": null, "llama_tokens": null, "mathlib_filename": null, "max_forks_count": null, "max_forks_repo_forks_event_max_date...