text
stringlengths
0
1.25M
meta
stringlengths
47
1.89k
[STATEMENT] lemma poly_altdef': assumes gr: "k \<ge> degree p" shows "poly p (z::complex) = (\<Sum>i\<le>k. coeff p i * z ^ i)" [PROOF STATE] proof (prove) goal (1 subgoal): 1. poly p z = (\<Sum>i\<le>k. coeff p i * z ^ i) [PROOF STEP] proof - [PROOF STATE] proof (state) goal (1 subgoal): 1. poly p z = (\<Sum>i\<...
{"llama_tokens": 2467, "file": "Gauss_Sums_Finite_Fourier_Series", "length": 26}
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on %(date)s @author: %(username)s """ #%% import numpy as np from astropy.io import fits from laspec.normalization import normalize_spectrum_iter from scipy import signal from twodspec import extract from twodspec.aperture import Aperture from ...
{"hexsha": "76e1e829b4cbd2257cd98f24096ffaa69022405a", "size": 7167, "ext": "py", "lang": "Python", "max_stars_repo_path": "twodspec/deprecated/newtrace.py", "max_stars_repo_name": "hypergravity/songcn", "max_stars_repo_head_hexsha": "e2b071c932720d02e5f085884c83c46baba7802d", "max_stars_repo_licenses": ["MIT"], "max_s...
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Thu Apr 5 17:04:32 2018 @author: matteo """ import numpy as np import itertools from gym import spaces """Feature functions""" class RBF(object): def __init__(self, kernel_centers, std): self.kernel_centers = kernel_centers self.std ...
{"hexsha": "cf88fdf845ef4e980afe60473b291d5e67bb3381", "size": 1123, "ext": "py", "lang": "Python", "max_stars_repo_path": "baselines/interaction/features.py", "max_stars_repo_name": "T3p/baselines", "max_stars_repo_head_hexsha": "5623c9160d1e86ebca3e673f142fe6b14a1db06c", "max_stars_repo_licenses": ["MIT"], "max_stars...
# ------------------------------------------------------------------ # Licensed under the MIT License. See LICENSE in the project root. # ------------------------------------------------------------------ """ PoissonProcess(λ) A Poisson process with intensity `λ`. """ struct PoissonProcess{L<:Union{Real,Function}}...
{"hexsha": "7d78a0bfe6f97806dc4499fd57f9eade1cc98e7e", "size": 2078, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "src/processes/poisson.jl", "max_stars_repo_name": "PeetoomHeida/PointPatterns.jl", "max_stars_repo_head_hexsha": "4225b21a4724032cd83100c638733a63325e8fa6", "max_stars_repo_licenses": ["MIT"], "max...
def topsiscode(data, matrix, sign): import numpy as np import pandas as pd dataset = pd.read_csv('data') x = dataset.shape[0] y = dataset.shape[1] summ = sum(matrix) s = [] for j in range(y): s.append(0) for i in range(x): s[j] = s[j]+...
{"hexsha": "94877f55b222f02440809725a8584e6c3a9fcca9", "size": 1608, "ext": "py", "lang": "Python", "max_stars_repo_path": "Topsissss/as.py", "max_stars_repo_name": "deepak199922/Topsisss", "max_stars_repo_head_hexsha": "63436342d4327a9e018dff54f5b1f3d86d27ec96", "max_stars_repo_licenses": ["MIT"], "max_stars_count": n...
import pandas as pd import numpy as np from keras.models import load_model from sklearn.metrics import roc_curve, roc_auc_score, auc, precision_recall_curve, average_precision_score import os import pickle from scipy.special import softmax from prg import prg class MetricsGenerator(object): def __init__(self, data...
{"hexsha": "3e549ad1164dfec9640eaffc06582c10fc91d254", "size": 4839, "ext": "py", "lang": "Python", "max_stars_repo_path": "evaluation-approach/lib/metric.py", "max_stars_repo_name": "Bruno81930/EXIMB-SMDP", "max_stars_repo_head_hexsha": "9483b18d61dddab5fffe53b1419102e70dbe5499", "max_stars_repo_licenses": ["MIT"], "m...
[STATEMENT] lemma keys_to_list_MP_oalist [code]: "keys_to_list (MP_oalist xs) = OAlist_sorted_domain_ntm cmp_term xs" [PROOF STATE] proof (prove) goal (1 subgoal): 1. keys_to_list (MP_oalist xs) = OAlist_sorted_domain_ntm cmp_term xs [PROOF STEP] proof - [PROOF STATE] proof (state) goal (1 subgoal): 1. keys_to_list (...
{"llama_tokens": 3190, "file": "Polynomials_MPoly_Type_Class_OAlist", "length": 34}
[STATEMENT] lemma elementary_union_interval: fixes a b :: "'a::euclidean_space" assumes "p division_of \<Union>p" obtains q where "q division_of (cbox a b \<union> \<Union>p)" [PROOF STATE] proof (prove) goal (1 subgoal): 1. (\<And>q. q division_of cbox a b \<union> \<Union> p \<Longrightarrow> thesis) \<Longrig...
{"llama_tokens": 15423, "file": null, "length": 118}
import sys, skvideo.io, json, base64 import numpy as np from PIL import Image from io import BytesIO, StringIO import tensorflow as tf import scipy.misc import argparse import os import scipy file = sys.argv[-1] image_shape = (192, 256) if file == 'demo.py': print ("Error loading video") quit # Define encode...
{"hexsha": "7bd806bfc742263338a529cee581d0f94387d6d8", "size": 2336, "ext": "py", "lang": "Python", "max_stars_repo_path": "submit.py", "max_stars_repo_name": "xfqbuaa/Lyft_Challenge_Carla", "max_stars_repo_head_hexsha": "df32613cc203be3aa4b568da34994edf86b2ea15", "max_stars_repo_licenses": ["MIT"], "max_stars_count": ...
"""Utilities and definitions shared by reward-related code.""" from typing import Callable import numpy as np from stable_baselines3.common import vec_env RewardFn = Callable[[np.ndarray, np.ndarray, np.ndarray, np.ndarray], np.ndarray] def build_norm_reward_fn( *, reward_fn: RewardFn, vec_normalize: v...
{"hexsha": "e37b88b4f5b9748276b2605cc4347051133df49a", "size": 1710, "ext": "py", "lang": "Python", "max_stars_repo_path": "src/imitation/rewards/common.py", "max_stars_repo_name": "dreamfyrian/imitation", "max_stars_repo_head_hexsha": "682bc4b919baf57bdd959ac646caba21d92cdf71", "max_stars_repo_licenses": ["MIT"], "max...
import numpy as np import matplotlib.pyplot as plt from matplotlib import rc from mpl_toolkits.mplot3d import Axes3D from skimage.morphology import skeletonize_3d from pathlib import Path from typing import NamedTuple, Tuple from ptg.pixel_shape import PixelSphere as ps # utilities serialize = False latex = False if ...
{"hexsha": "6aef8da51a9354efff4e1d6e16d15b16b8341588", "size": 5069, "ext": "py", "lang": "Python", "max_stars_repo_path": "geo/examples/pixlet.py", "max_stars_repo_name": "sandialabs/sibl", "max_stars_repo_head_hexsha": "010cbc3fbbd14cdfa3742ec4c95100f05146dce8", "max_stars_repo_licenses": ["MIT"], "max_stars_count": ...
# -*- coding: utf-8 -*- """ Created on Sun Jan 17 22:38:43 2021 @author: stvyh this file is used to complete program with Qt Designer output C:\Users\stvyh\OneDrive\Desktop\ImageProcessing\ImageProcessing pyuic5 -x m1.ui -o elilik.py C:/Temp/Data/test/shapes.png ERROR: ImportError: QtWebEngineWidgets must be i...
{"hexsha": "da5f3f403ab5c445b17fc7f872cef1949833519b", "size": 15541, "ext": "py", "lang": "Python", "max_stars_repo_path": "MonkeyBusiness/m3Utils.py", "max_stars_repo_name": "svyhlidka/Python-Projects", "max_stars_repo_head_hexsha": "7c297bf7248a1e61699a69d62eb83f15cf90d352", "max_stars_repo_licenses": ["MIT"], "max_...
using GeometryTypes using ComputerVision using Test digital_camera = DigitalCamera() camera_model = get_model(digital_camera) pictures = get_pictures(digital_camera) @test typeof(camera_model) <: AbstractCameraModel @test isnothing(pictures) intrinsics = get_intrinsics(camera_model) @test typeof(intrinsics) <: Abstr...
{"hexsha": "f5b7642919aed414fd856c022adf28656da115ed", "size": 441, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "test/camera.jl", "max_stars_repo_name": "JuliaTagBot/ComputerVision.jl", "max_stars_repo_head_hexsha": "a83bd0d271217090798407de3aa8d40cc7adbdf1", "max_stars_repo_licenses": ["MIT"], "max_stars_coun...
# 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...
{"hexsha": "f17effa82beb565fd4a0efa09f42b8ba711b78a2", "size": 9610, "ext": "py", "lang": "Python", "max_stars_repo_path": "tensorflow/python/ops/signal/window_ops.py", "max_stars_repo_name": "EricRemmerswaal/tensorflow", "max_stars_repo_head_hexsha": "141ff27877579c81a213fa113bd1b474c1749aca", "max_stars_repo_licenses...
#!/usr/bin/env python3 import numpy as np import torch import torch.nn as nn import torch.nn.functional as F import torch.onnx.operators from fairseq import options, utils from fairseq.models import ( FairseqEncoder, FairseqEncoderDecoderModel, register_model, register_model_architecture, ) from fairseq...
{"hexsha": "e81539dae452dd15890673931b9b6f6ea44d266f", "size": 58155, "ext": "py", "lang": "Python", "max_stars_repo_path": "pytorch_translate/rnn.py", "max_stars_repo_name": "ROCmSoftwarePlatform/translate", "max_stars_repo_head_hexsha": "32a6380d914ebe1a6c38c4992aac9600ed3d9810", "max_stars_repo_licenses": ["BSD-3-Cl...
import os import numpy as np import torch.utils.data as data import torchvision from numpy.random import randint import transforms as t from .video_record import VideoRecord class VideoDataset(data.Dataset): """ A generic video dataset. Args: root_path: Full path to the dataset videos directory. ...
{"hexsha": "29de5538b6c852dde408be645d82c45fb2de9165", "size": 6762, "ext": "py", "lang": "Python", "max_stars_repo_path": "datasets/video_dataset.py", "max_stars_repo_name": "patykov/OnlineAction", "max_stars_repo_head_hexsha": "efab480382e9a2a14bfe7fceaf6ade35d22efc21", "max_stars_repo_licenses": ["MIT"], "max_stars_...
# 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...
{"hexsha": "13c1883af6184f2971d43c6bbd88496912c5ec67", "size": 4327, "ext": "py", "lang": "Python", "max_stars_repo_path": "python/paddle/fluid/tests/unittests/mkldnn/test_softmax_mkldnn_op.py", "max_stars_repo_name": "zmxdream/Paddle", "max_stars_repo_head_hexsha": "04f042a5d507ad98f7f2cfc3cbc44b06d7a7f45c", "max_star...
# coding=utf-8 # Copyright 2021 The Uncertainty Baselines 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 ap...
{"hexsha": "8c909fe5153b02745603c3ae61576fdf32f06ed8", "size": 8698, "ext": "py", "lang": "Python", "max_stars_repo_path": "uncertainty_baselines/models/bit_resnet.py", "max_stars_repo_name": "y0ast/uncertainty-baselines", "max_stars_repo_head_hexsha": "8d32c77ba0803ed715c1406378adf10ebd61ab74", "max_stars_repo_license...
""" Convert dataset to HDF5 This script preprocesses a dataset and saves it (images and labels) to an HDF5 file for improved I/O. """ import logging import os import sys from argparse import ArgumentParser from tqdm import tqdm, trange import h5py as h5 import numpy as np import torch import torchvision.datas...
{"hexsha": "8885d59cd367d60c64c70e238e158515edb6faaa", "size": 6567, "ext": "py", "lang": "Python", "max_stars_repo_path": "make_hdf5.py", "max_stars_repo_name": "PeterouZh/BigGAN-PyTorch-1", "max_stars_repo_head_hexsha": "722fe2e3b721f350c8e9b991d2839b0291f5cea7", "max_stars_repo_licenses": ["MIT"], "max_stars_count":...
C$Procedure ZZDAFNFR ( Private --- DAF write New File Record ) SUBROUTINE ZZDAFNFR ( LUN, . IDWORD, . ND, . NI, . IFNAME, . FWARD, . BWARD, . ...
{"hexsha": "62ef361e9ad7f426c2e38420772edf4737a6c7ad", "size": 10703, "ext": "f", "lang": "FORTRAN", "max_stars_repo_path": "source/nasa_f/zzdafnfr.f", "max_stars_repo_name": "agforero/FTFramework", "max_stars_repo_head_hexsha": "6caf0bc7bae8dc54a62da62df37e852625f0427d", "max_stars_repo_licenses": ["MIT"], "max_stars_...
#!/usr/bin/env python3 import unittest import warnings import matplotlib.pyplot as plt import numpy as np import numpy.testing as nptest import pandas as pd import pandas.testing as pdtest import scipy.sparse from scipy.spatial.distance import pdist, squareform from datafold.pcfold.distance import compute_distance_ma...
{"hexsha": "30c65f55a43eed8a8acd9091bde39e8d2ad436a2", "size": 21013, "ext": "py", "lang": "Python", "max_stars_repo_path": "Code/ModelSelection/datafold-master/datafold/pcfold/tests/test_kernels.py", "max_stars_repo_name": "sazio/SSVEP_IEEE_SMC_2021", "max_stars_repo_head_hexsha": "8cae603d04dd8d623f01cf1e8979cf8ac9e0...
import unittest import numpy as np import vnmrjpy as vj from scipy.ndimage.filters import convolve from scipy.signal import fftconvolve import matplotlib.pyplot as plt class Test_fftconvolve(unittest.TestCase): def test_fftconvolve(self): hankel = np.random.rand(50,20) kernel = np.fliplr(np.eye(h...
{"hexsha": "74ac0701fd1ec83e45037c7acc16947c07cba66f", "size": 922, "ext": "py", "lang": "Python", "max_stars_repo_path": "test/test_mathutils.py", "max_stars_repo_name": "hlatkydavid/vnmrjpy", "max_stars_repo_head_hexsha": "48707a1000dc87e646e37c8bd686e695bd31a61e", "max_stars_repo_licenses": ["MIT"], "max_stars_count...
module ApproxBayes using Distributions using ProgressMeter using StatsBase using RecipesBase using Printf using Distances using DelimitedFiles using Random using Statistics using Base.Threads import Base.show export # types ABCtype, Prior, Particle, abctype, ParticleRejection, ABCRejection, ABCSMC, ...
{"hexsha": "3ca75fc5ac99ddc7b9bb44a0aef94efb8a3d25fc", "size": 633, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "src/ApproxBayes.jl", "max_stars_repo_name": "wilwxk/ApproxBayes.jl", "max_stars_repo_head_hexsha": "8ca364c66a9f94ccd09910a4f73232909d91c399", "max_stars_repo_licenses": ["MIT"], "max_stars_count": ...
#References #https://stackoverflow.com/ #questions/47330812/find-the-longest-diagonal-of-an-element-in-a-matrix-python #https://codereview.stackexchange.com/questions/146935/find-diagonal-positions-for-bishop-movement import numpy as np import pandas as pd from itertools import chain import matplotlib.pyplot as plt # ...
{"hexsha": "c8f97e2fff6ad9f33aaeed9e87cf9d427a4c49ca", "size": 4742, "ext": "py", "lang": "Python", "max_stars_repo_path": "dtw_diag.py", "max_stars_repo_name": "kibol/data-analytics", "max_stars_repo_head_hexsha": "89228849e9897c753dfd95507a9148422735f4fb", "max_stars_repo_licenses": ["BSD-2-Clause"], "max_stars_count...
""" Image Cleaning Algorithms (identification of noisy pixels) """ __all__ = ['tailcuts_clean', 'dilate'] import numpy as np from scipy.sparse.csgraph import connected_components def tailcuts_clean(geom, image, picture_thresh=7, boundary_thresh=5, keep_isolated_pixels=False, mi...
{"hexsha": "0b3187ba9809390a735c2df1867c3c3383e49a06", "size": 4762, "ext": "py", "lang": "Python", "max_stars_repo_path": "ctapipe/image/cleaning.py", "max_stars_repo_name": "mpecimotika/ctapipe", "max_stars_repo_head_hexsha": "ffd7930921f7139b761fbf1208da16dd302e97a6", "max_stars_repo_licenses": ["BSD-3-Clause"], "ma...
(* * Copyright 2014, General Dynamics C4 Systems * * SPDX-License-Identifier: GPL-2.0-only *) theory EmptyFail_H imports Refine begin crunch_ignore (empty_fail) (add: handleE' getCTE getObject updateObject CSpaceDecls_H.resolveAddressBits doMachineOp suspend restart schedule) context begin inte...
{"author": "NICTA", "repo": "l4v", "sha": "3c3514fe99082f7b6a6fb8445b8dfc592ff7f02b", "save_path": "github-repos/isabelle/NICTA-l4v", "path": "github-repos/isabelle/NICTA-l4v/l4v-3c3514fe99082f7b6a6fb8445b8dfc592ff7f02b/proof/refine/X64/EmptyFail_H.thy"}
Fake Larry Vanderhoef, aka Larry Vanderhumpf, is an internet spoof version of Larry Vanderhoef, complete with blog. He was elected to the Office of the Channeler by the Minions of Mrak, and is serving his term of the eternal now. In His Own Words You are my connections. Email Mailto(greyseal AT att DOT net) with...
{"hexsha": "e218f171905d2951a787e29d58e1e08863a557e9", "size": 562, "ext": "f", "lang": "FORTRAN", "max_stars_repo_path": "lab/davisWiki/Fake_Larry_Vanderhoef_-_Dirt_at_UCD.f", "max_stars_repo_name": "voflo/Search", "max_stars_repo_head_hexsha": "55088b2fe6a9d6c90590f090542e0c0e3c188c7d", "max_stars_repo_licenses": ["M...
__precompile__() module ReadGlobal using DelimitedFiles export readglobal, getdimsize, readpadded, readpadded!, readfield, readfield!, checkinput, getnfilter, doinchunks, read_info, readcsv, testinput function findglobal() filename="global" if !isfile(filename) for i = 1:10 filename = ".....
{"hexsha": "3c64623b57f0184686a4243a0589acbfd9e195d2", "size": 6644, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "src/ReadGlobal.jl", "max_stars_repo_name": "favba/ReadGlobal.jl", "max_stars_repo_head_hexsha": "a9b69382f969471ba393eac83f09a283c8173e4b", "max_stars_repo_licenses": ["MIT"], "max_stars_count": nu...
SUBROUTINE ML5_0_MP_BORN_AMPS_AND_WFS(P) C C Generated by MadGraph5_aMC@NLO v. %(version)s, %(date)s C By the MadGraph5_aMC@NLO Development Team C Visit launchpad.net/madgraph5 and amcatnlo.web.cern.ch C C Computes all the AMP and WFS in quadruple precision for the C phase space poi...
{"hexsha": "3415f0cef1c5d40b513c9d395bd4820979e81d91", "size": 13499, "ext": "f", "lang": "FORTRAN", "max_stars_repo_path": "tests/input_files/IOTestsComparison/short_ML_SMQCD_default/gg_ttx/mp_born_amps_and_wfs.f", "max_stars_repo_name": "valassi/mg5amc_test", "max_stars_repo_head_hexsha": "2e04f23353051f64e1604b23105...
program p 1 variable = a .eqv. b .eqv. c == 0 variable = a .eqv. b .and. .not. c == 0 variable = 10._8 > 1 .and. 1.E+1_8 > 0 a(:) = 0 name_check = line(i)(1:pos-1) pressure = 949. + real(reshape( (/ (counter, counter = 1, numLats * numLons * numFrTimes) /), & ...
{"hexsha": "a56af779a8a93b7e43c326652ae40fd3db2d8609", "size": 382, "ext": "f95", "lang": "FORTRAN", "max_stars_repo_path": "src/test/resources/psi/Expressions.f95", "max_stars_repo_name": "LChernigovskaya/fortran-plugin", "max_stars_repo_head_hexsha": "6750933e79c5bf420937160aecedc39b142ca5f6", "max_stars_repo_license...
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ @author: peter csvtools.py: Tools for handling metadata CSV files **CSV types** Four types of CSV files are supported, differentiated by the presence of 'run' and 'probe columns. Experiment constants -> No runs column, no probe column. Data that applies to ...
{"hexsha": "c907e4f8591c1fa7a653f2d6fec0d218ada958ff", "size": 14501, "ext": "py", "lang": "Python", "max_stars_repo_path": "uclahedp/tools/csv.py", "max_stars_repo_name": "uclahedp/uclahedp", "max_stars_repo_head_hexsha": "122ecb180cc58c3aadb47de016427a46094cc8fa", "max_stars_repo_licenses": ["MIT"], "max_stars_count"...
from .__parser__ import Parser as _P from lxml import etree import numpy as np import pandas as pd import os.path as op class Parser(_P): def __init__(self, path, app): super().__init__(path, app) if not op.isfile(path):return if not path.endswith(".xml"):return rootxml = etree.pars...
{"hexsha": "cc51b2f80fdecb3212aa968a99b76eea672db309", "size": 4699, "ext": "py", "lang": "Python", "max_stars_repo_path": "plt.mk3/plugins/data/parsers/parser_visionxml.py", "max_stars_repo_name": "mb-89/plt.mk3", "max_stars_repo_head_hexsha": "45e06f608e6051c92b8e4718e4ef480fd9ca800b", "max_stars_repo_licenses": ["MI...
import numpy as np import cv2 class BackGroundSubtractor: # When constructing background subtractor, we # take in two arguments: # 1) alpha: The background learning factor, its value should # be between 0 and 1. The higher the value, the more quickly # your program learns the changes in the background. Therefore...
{"hexsha": "481c17fe4fcc1c94360f059d1c56cafaba624c47", "size": 2271, "ext": "py", "lang": "Python", "max_stars_repo_path": "hard-gists/7c3d01ad13b0e7e5985a/snippet.py", "max_stars_repo_name": "jjhenkel/dockerizeme", "max_stars_repo_head_hexsha": "eaa4fe5366f6b9adf74399eab01c712cacaeb279", "max_stars_repo_licenses": ["A...
""" Metrics for computing evalutation results Modified from vanilla PANet code by Wang et al. """ import numpy as np class Metric(object): """ Compute evaluation result Args: max_label: max label index in the data (0 denoting background) n_scans: number of test sca...
{"hexsha": "6d4f0241efc6e11f79f7781d137f395296683710", "size": 11243, "ext": "py", "lang": "Python", "max_stars_repo_path": "util/metric.py", "max_stars_repo_name": "tanghaotommy/Self-supervised-Fewshot-Medical-Image-Segmentation", "max_stars_repo_head_hexsha": "9ff8cd2421ee2f7c038d8eec15b0296b365e0c46", "max_stars_rep...
import argparse import json import os import sys import numpy as np import torch from PIL import Image from network import Network from train import initializeDevice device = None cat_to_name = [] def initializeCatgories(category_names_file): print(f"Loading category names from [{category_names_file}].") w...
{"hexsha": "80d67cacc540d957e34fb0ce746f851cc91d642f", "size": 4183, "ext": "py", "lang": "Python", "max_stars_repo_path": "predict.py", "max_stars_repo_name": "elfnews/image_classifier", "max_stars_repo_head_hexsha": "b5d0c46250c7793bbf0729895541078fd2626252", "max_stars_repo_licenses": ["MIT"], "max_stars_count": nul...
(* seplog (c) AIST 2005-2013. R. Affeldt, N. Marti, et al. GNU GPLv3. *) (* seplog (c) AIST 2014-2018. R. Affeldt et al. GNU GPLv3. *) Require Import Epsilon. From mathcomp Require Import ssreflect ssrfun ssrbool eqtype ssrnat seq. Require Import Init_ext ssrZ ZArith_ext seq_ext machine_int uniq_tac multi_int. Import M...
{"author": "affeldt-aist", "repo": "seplog", "sha": "b08516d34f5dedd0aafbe77d8ef270fa838e8f85", "save_path": "github-repos/coq/affeldt-aist-seplog", "path": "github-repos/coq/affeldt-aist-seplog/seplog-b08516d34f5dedd0aafbe77d8ef270fa838e8f85/begcd/multi_is_even_u_and_simu.v"}
import os import matplotlib.pyplot as plt import csv import numpy as np def map_visible(value): if value == 'True': return 1 elif value == 'False': return 0 else: return -1 def map_unsure3dBox(valuevisible, valueBox): if valuevisible == 'True' and valueBox>=0: return 1...
{"hexsha": "84845aba1d0af21a6eb5176c765a838d98cc9964", "size": 6359, "ext": "py", "lang": "Python", "max_stars_repo_path": "tools/DatasetStatisticsTools/lib_stats/util.py", "max_stars_repo_name": "ladt/SeeingThroughFog", "max_stars_repo_head_hexsha": "c714a4c3e8f8e604494b1db6e9eef529b0326405", "max_stars_repo_licenses"...
# This file implements a MultiVolumeVisual class that can be used to show # multiple volumes simultaneously. It is derived from the original VolumeVisual # class in vispy.visuals.volume, which is releaed under a BSD license included # here: # # ===========================================================================...
{"hexsha": "f38fff8af772102b9fdd89dc435573268164ea80", "size": 9740, "ext": "py", "lang": "Python", "max_stars_repo_path": "phathom/multivol/multi_volume_visual.py", "max_stars_repo_name": "chunglabmit/phathom", "max_stars_repo_head_hexsha": "304db7a95e898e9b03d6b2640172752d21a7e3ed", "max_stars_repo_licenses": ["MIT"]...
From hydras Require Import T1 E0. From Coq Require Import Lia. Open Scope E0_scope. Lemma ge_omega_iff (alpha : E0): E0omega o<= alpha <-> (forall i:nat, i + alpha = alpha). Proof. destruct alpha as [a Ha]; unfold E0le; cbn. destruct a; cbn; split; intros H. - rewrite Le_iff in H; destruct H as (H, (Hle, Hnf)...
{"author": "coq-community", "repo": "hydra-battles", "sha": "2d211e0b5030d5f77aaaf6366b01fc64ed998c61", "save_path": "github-repos/coq/coq-community-hydra-battles", "path": "github-repos/coq/coq-community-hydra-battles/hydra-battles-2d211e0b5030d5f77aaaf6366b01fc64ed998c61/theories/ordinals/solutions_exercises/ge_omega...
\chapter{Ordinary Least Squares for prediction}
{"hexsha": "eeb716b4014ada1a8df616b32a612be83ffe0fb1", "size": 50, "ext": "tex", "lang": "TeX", "max_stars_repo_path": "src/pug/theory/statistics/ols/00-00-Chapter_name.tex", "max_stars_repo_name": "adamdboult/nodeHomePage", "max_stars_repo_head_hexsha": "266bfc6865bb8f6b1530499dde3aa6206bb09b93", "max_stars_repo_licen...
"""Contains the highway with ramps network class.""" from flow.networks.base import Network from flow.core.params import InitialConfig, TrafficLightParams from collections import defaultdict from numpy import pi, sin, cos ADDITIONAL_NET_PARAMS = { # lengths of highway, on-ramps and off-ramps respectively "hi...
{"hexsha": "d2c004a914fa9fff3699096784328a95bc5ee01e", "size": 9460, "ext": "py", "lang": "Python", "max_stars_repo_path": "rl/net/highway_ramps.py", "max_stars_repo_name": "KarlRong/Safe-RL-for-Driving", "max_stars_repo_head_hexsha": "67484911ca8ad9f1476e96043c379c01cd5ced8c", "max_stars_repo_licenses": ["Apache-2.0"]...
import pandas as pd import numpy as np import asteval import sys from cytoolz.curried import map, curry from cytoolz.functoolz import thread_last from cytoolz.dicttoolz import assoc_in from dask import delayed import re from survey_stats import log from survey_stats.etl import download as dl from survey_stats import pd...
{"hexsha": "02bbae551f8b847322f27b31eff58c0af6cc4eae", "size": 8492, "ext": "py", "lang": "Python", "max_stars_repo_path": "src/survey_stats/etl/socrata.py", "max_stars_repo_name": "semanticbits/survey_stats", "max_stars_repo_head_hexsha": "10d74ea6f25f98e55aefc89cb612e1e668ab236e", "max_stars_repo_licenses": ["BSD-2-C...
import argparse import time import numpy as np import os import json import pickle import random import sklearn.metrics as metrics import torch from torch.utils import data from data_generator import Dataset from mlp_model import mlp_model torch.manual_seed(123) torch.cuda.manual_seed(123) np.random.seed(123) random.s...
{"hexsha": "db7f8a3d6f4e1a54183be1fdc00cd2970164a4e1", "size": 9448, "ext": "py", "lang": "Python", "max_stars_repo_path": "graph2vec_optimization/train_graph2vec.py", "max_stars_repo_name": "Guannan1900/GraphDTI_preprocess", "max_stars_repo_head_hexsha": "60bb448666e6922b2e3b80a3409b090014af86ce", "max_stars_repo_lice...
/*! @file Defines `boost::hana::convert` and `boost::hana::to`. @copyright Louis Dionne 2014 Distributed under the Boost Software License, Version 1.0. (See accompanying file LICENSE.md or copy at http://boost.org/LICENSE_1_0.txt) */ #ifndef BOOST_HANA_CORE_CONVERT_HPP #define BOOST_HANA_CORE_CONVERT_HPP #include <...
{"hexsha": "bed46bad1c08fdd726a60d76b4095bce3a30a30a", "size": 3334, "ext": "hpp", "lang": "C++", "max_stars_repo_path": "include/boost/hana/core/convert.hpp", "max_stars_repo_name": "rbock/hana", "max_stars_repo_head_hexsha": "2b76377f91a5ebe037dea444e4eaabba6498d3a8", "max_stars_repo_licenses": ["BSL-1.0"], "max_star...
/*! * @file * Contains unit tests for the intrinsics for Boost.Fusion sequences. */ #include <react/extension/fusion.hpp> #include <react/computation/implementing.hpp> #include <react/concept/assert.hpp> #include <react/concepts.hpp> #include <react/detail/dont_care.hpp> #include <react/intrinsic/augment.hpp> #inc...
{"hexsha": "4d6bd3c703f3b13141d82cbc0284cca34922c7f7", "size": 1770, "ext": "cpp", "lang": "C++", "max_stars_repo_path": "test/extension/fusion.cpp", "max_stars_repo_name": "ldionne/react", "max_stars_repo_head_hexsha": "57b51d179661a9c21bc1f987d124722ac36399ac", "max_stars_repo_licenses": ["BSL-1.0"], "max_stars_count...
from CHECLabPy.core.reducer import WaveformReducer, column import numpy as np from numba import njit, prange, float64, float32, int64 @njit([ (float64[:, :], int64, int64), (float32[:, :], int64, int64), ]) def obtain_pulse_timing(waveforms, window_start, window_end): n_pixels, n_samples = waveforms.shape...
{"hexsha": "ec6019c98ffb1aa7a9f0e98f49afe1e3f16b877f", "size": 7946, "ext": "py", "lang": "Python", "max_stars_repo_path": "CHECLabPy/waveform_reducers/timing.py", "max_stars_repo_name": "ConteFrancesco/CHECLabPy", "max_stars_repo_head_hexsha": "b2d0a12cae062603b618132957a555c404a4a4c9", "max_stars_repo_licenses": ["BS...
from typing import List, Optional, Type import gym import numpy as np import torch as T from gym import Env from pearll.agents.base_agents import BaseAgent from pearll.buffers import BaseBuffer, RolloutBuffer from pearll.callbacks.base_callback import BaseCallback from pearll.common.type_aliases import Log from pearl...
{"hexsha": "81fc9c82438f0ecfeab8a905446205c3c542631c", "size": 7403, "ext": "py", "lang": "Python", "max_stars_repo_path": "pearll/agents/a2c.py", "max_stars_repo_name": "LondonNode/Anvil", "max_stars_repo_head_hexsha": "bc50fd7b16af36051157814e2548a98e787b03de", "max_stars_repo_licenses": ["MIT"], "max_stars_count": 1...
""" ============= Unicode minus ============= You can use the proper typesetting `Unicode minus`__ or the ASCII hyphen for minus, which some people prefer. :rc:`axes.unicode_minus` controls the default behavior. __ https://en.wikipedia.org/wiki/Plus_and_minus_signs#Character_codes The default is to use the Unicode ...
{"hexsha": "4acfc07a58fb750cc98160a4418a9bb645cc4696", "size": 674, "ext": "py", "lang": "Python", "max_stars_repo_path": "extraPackages/matplotlib-3.0.3/examples/text_labels_and_annotations/unicode_minus.py", "max_stars_repo_name": "dolboBobo/python3_ios", "max_stars_repo_head_hexsha": "877f8c2c5890f26292ddd14909bea62...
import cv2 import numpy as np import os import mysql.connector import attendence from datetime import datetime def main(): n, d, r = "", "", "" cnt = 0 recognizer = cv2.face.LBPHFaceRecognizer_create() recognizer.read('trainer/trainer.yml') cascadePath = "haarcascade_frontalface_defau...
{"hexsha": "830c238d72101472e30d03cd9e5f4b848a113662", "size": 3756, "ext": "py", "lang": "Python", "max_stars_repo_path": "facerecog.py", "max_stars_repo_name": "nitishmishra617/Python-Face_Recognition_Attendance_System", "max_stars_repo_head_hexsha": "596e68a2100d212961096a17c2c3c17fc229647d", "max_stars_repo_license...
#!/usr/bin/env python3 import argparse import copy from collections import defaultdict from pathlib import Path import os import sys import time import numpy as np import pandas as pd from sklearn.metrics import f1_score, precision_recall_fscore_support, log_loss, average_precision_score import torch import torch.opt...
{"hexsha": "00ec1447dec7415200abb8866ebabc979cd65ddb", "size": 11629, "ext": "py", "lang": "Python", "max_stars_repo_path": "workdir/train.py", "max_stars_repo_name": "lisosia/kaggle-rsna-str", "max_stars_repo_head_hexsha": "262d3530158952587ec69e7a97f874e8cd34588b", "max_stars_repo_licenses": ["MIT"], "max_stars_count...
import pickle import shutil from pathlib import Path, PurePath from typing import Dict, List, Optional, Tuple, Union import matplotlib import matplotlib.pyplot as plt import numpy as np import pandas as pd import torch from skimage.color import label2rgb import inc.python_image_utilities.image_util as iutil import ut...
{"hexsha": "7c2475010ee4dff69443fe5f145043e6c64aa63b", "size": 13687, "ext": "py", "lang": "Python", "max_stars_repo_path": "utils.py", "max_stars_repo_name": "wwarriner/unsupervised_onh_histo", "max_stars_repo_head_hexsha": "48ec23781af203a14ff590f3074a2d3559957560", "max_stars_repo_licenses": ["MIT"], "max_stars_coun...
#include <fstream> #include <sstream> #include <iostream> #include <vector> #include <bits/stdc++.h> #include <boost/format.hpp> #include <boost/iostreams/filtering_stream.hpp> #include <boost/iostreams/filter/zlib.hpp> #include <boost/iostreams/copy.hpp> int main(int argc, char *argv[]){ if(argc!=3){ st...
{"hexsha": "8ff40ca28c39411f7333a51054019f5a4d9f772f", "size": 3274, "ext": "cpp", "lang": "C++", "max_stars_repo_path": "src/gaden/test_env/decompress/src/toASCII.cpp", "max_stars_repo_name": "chinaheyu/pydog_ws", "max_stars_repo_head_hexsha": "c5ff65647845e6c96901fb925a2357507dfeecf0", "max_stars_repo_licenses": ["MI...
Lemma LP12P13 : forall P1 P2 P3 P4 P5 P6 P7 P8 P9 P10 P11 P12 P13 , rk(P1 :: P2 :: P3 :: nil) = 3 -> rk(P4 :: P5 :: P6 :: nil) = 3 -> rk(P1 :: P2 :: P3 :: P4 :: P5 :: P6 :: nil) = 4 -> rk(P7 :: P8 :: P9 :: nil) = 3 -> rk(P1 :: P2 :: P3 :: P7 :: P8 :: P9 :: nil) = 4 -> rk(P4 :: P5 :: P6 :: P7 :: P8 :: P9 :: nil) =...
{"author": "pascalschreck", "repo": "MatroidIncidenceProver", "sha": "e492d375a2264e6c908c9c47fe719c39e3f847f8", "save_path": "github-repos/coq/pascalschreck-MatroidIncidenceProver", "path": "github-repos/coq/pascalschreck-MatroidIncidenceProver/MatroidIncidenceProver-e492d375a2264e6c908c9c47fe719c39e3f847f8/matroidbas...
import numpy as np import cv2 #red detection vid = cv2.VideoCapture(0) #Webcam=0 while True: _, frame = vid.read() #_ is used for those returned things whch are of no use # HSV = HUE, SATURATION, VALUE hsv = cv2.cvtColor(frame, cv2.COLOR_BGR2HSV) lower_red = np.array([0,70,50]) #provides a range u...
{"hexsha": "f7c40848ea0625c4ebf432aa880678459e3d8bbb", "size": 870, "ext": "py", "lang": "Python", "max_stars_repo_path": "PycharmProjects/OpenCV/Dhairya_OpenCV/6_VideoFilters.py", "max_stars_repo_name": "dhairyashah1/Eklavya20-CatchPracticeBot", "max_stars_repo_head_hexsha": "60434bf5e280d7495eab75b21566bd1eb3bbd14e",...
Primes <- read.csv("Primes.csv", header=F) avg <- (Primes[3]+Primes[4]+Primes[5]+Primes[6]+Primes[7]+Primes[8]+Primes[9]+Primes[10]+Primes[11]+Primes[12])/10 Data.name <- Primes[[1]] Data.val <- Primes[[2]] avg <- avg[[1]] pdf(file = "Primes.pdf", width = 6.25, height = 4.7, family = "Times", pointsize = 18) par(mai=...
{"hexsha": "7a132463b23f3762c7f47b1575f75c287ed5ddfd", "size": 5132, "ext": "r", "lang": "R", "max_stars_repo_path": "code/scripts/out3/MakeGraphs.r", "max_stars_repo_name": "joseproenca/ip-constraints", "max_stars_repo_head_hexsha": "0d478b44d696e2107e4c75e465b23ef4e677a6ba", "max_stars_repo_licenses": ["MIT"], "max_s...
#!/usr/bin/python2.7 # -*- coding:utf-8 -*- # Author: NetworkRanger # Date: 2018/11/5 下午9:40 # 4.2 线性支持向量机的使用 # 1. 导入必要的编程库,包括导入scikit learn的datasets库来访问iris数据集 import matplotlib.pyplot as plt import numpy as np import tensorflow as tf from sklearn import datasets """ 安装scikit learn可使用: $ pip install -U scikit-lear...
{"hexsha": "106ac67b7b6f92b5c42fc45d6b084cb35651992a", "size": 4526, "ext": "py", "lang": "Python", "max_stars_repo_path": "chapter04/demo_4.2.py", "max_stars_repo_name": "OsbornHu/tensorflow-ml", "max_stars_repo_head_hexsha": "56c3051e7085a919a603481709b63e4a6614192a", "max_stars_repo_licenses": ["MIT"], "max_stars_co...
import numpy as np import torch import logging from torch.utils.data import DataLoader from torch.utils.data.sampler import SubsetRandomSampler # from https://palikar.github.io/posts/pytorch_datasplit/ class DataSplit: def __init__(self, dataset, test_train_split=0.8, val_train_split=0.1, shuffle=False): ...
{"hexsha": "ae4512544a723002c0aba90dcf75b8c6c5bbefba", "size": 2898, "ext": "py", "lang": "Python", "max_stars_repo_path": "src/datasplit/datasplit.py", "max_stars_repo_name": "mcomunita/gfx_classifier", "max_stars_repo_head_hexsha": "94e5f09084837886990e05821da9ff4a55ed180a", "max_stars_repo_licenses": ["BSD-3-Clause"...
[STATEMENT] lemma bnds_cos: "\<forall>(x::real) lx ux. (l, u) = bnds_cos prec lx ux \<and> x \<in> {lx .. ux} \<longrightarrow> l \<le> cos x \<and> cos x \<le> u" [PROOF STATE] proof (prove) goal (1 subgoal): 1. \<forall>x lx ux. (l, u) = bnds_cos prec lx ux \<and> x \<in> {real_of_float lx..real_of_float ux} \<lon...
{"llama_tokens": 107162, "file": null, "length": 275}
"""" Copyright (c) 2018. All rights reserved. Created by Resnick Xing on 2018/5/10 """ import numpy as np import cv2 def get_test_patches(img, config,rl=False): """ 将待分割图预处理后,分割成patch :param img: 待分割图 :param config: 配置文件 :return: """ test_img = [] test_img.append(img) test_img=np...
{"hexsha": "97775d5d344420484a9b23a26ede019e637b0f5e", "size": 9253, "ext": "py", "lang": "Python", "max_stars_repo_path": "configs/utils/img_utils.py", "max_stars_repo_name": "kant/DL_Segmention_Template", "max_stars_repo_head_hexsha": "cd791d79fefb1f9a7ee4fbd691c09f1f23180a9a", "max_stars_repo_licenses": ["MIT"], "ma...
from .Custom_Legend import * from .set_Axes_Color import * from scipy.stats import spearmanr import matplotlib.pyplot as plt import numpy as np def _zero_to_nan(values): """Replace every 0 with 'nan' and return a copy.""" return [float('nan') if x==0 else x for x in values] def Pair_Plot(parameter_array, labe...
{"hexsha": "c0ed165fad24f3e476f4644503ce2146ef9ebe3c", "size": 10299, "ext": "py", "lang": "Python", "max_stars_repo_path": "data_visualization/Pair_Plot.py", "max_stars_repo_name": "CashabackLab/DataVisualization", "max_stars_repo_head_hexsha": "91b2a2d6020ae2fb5b8277f5c7bca69d620be1cb", "max_stars_repo_licenses": ["M...
[STATEMENT] lemma spectral_radius_max: assumes "eigen_value A v" shows "norm v \<le> spectral_radius A" [PROOF STATE] proof (prove) goal (1 subgoal): 1. cmod v \<le> HMA_Connect.spectral_radius A [PROOF STEP] proof - [PROOF STATE] proof (state) goal (1 subgoal): 1. cmod v \<le> HMA_Connect.spectral_radius A [PROOF ...
{"llama_tokens": 578, "file": "Perron_Frobenius_Perron_Frobenius_Aux", "length": 8}
// Copyright Gavin Band 2008 - 2012. // 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) #ifndef QCTOOL_CALLCOMPARER_COMPONENT_ACCEPT_ALL_CALL_MERGER_HPP #define QCTOOL_CALLCOMPARER_COMPONENT_A...
{"hexsha": "7c3f38d2e0381e9b3a06cd63d02838e98bbca8c5", "size": 1271, "ext": "hpp", "lang": "C++", "max_stars_repo_path": "components/SNPSummaryComponent/include/components/SNPSummaryComponent/AcceptAllCallMerger.hpp", "max_stars_repo_name": "CreRecombinase/qctool", "max_stars_repo_head_hexsha": "6dad3a15c461177bf6940ba...
[STATEMENT] lemma pfx_not_empty: "valid_prefix pfx \<Longrightarrow> prefix_to_wordset pfx \<noteq> {}" [PROOF STATE] proof (prove) goal (1 subgoal): 1. valid_prefix pfx \<Longrightarrow> prefix_to_wordset pfx \<noteq> {} [PROOF STEP] unfolding valid_prefix_def prefix_to_wordset_def [PROOF STATE] proof (prove) goal (1...
{"llama_tokens": 202, "file": "IP_Addresses_Prefix_Match", "length": 2}
import numpy as np from pyriemann.utils.test import ( is_square, is_sym, is_skew_sym, is_real, is_hermitian, is_pos_def, is_pos_semi_def, is_sym_pos_def, is_sym_pos_semi_def ) n_channels = 3 def test_is_square(): assert is_square(np.eye(n_channels)) assert not is_square(np.ones((n_channels, n_c...
{"hexsha": "b4b1e8c293dc9eb06ee00baa9aaff16e3a6f3c5d", "size": 2469, "ext": "py", "lang": "Python", "max_stars_repo_path": "tests/test_utils_test.py", "max_stars_repo_name": "c-cameron/pyRiemann", "max_stars_repo_head_hexsha": "11298a81d34b173dfca19f653329bd0c8bf5a534", "max_stars_repo_licenses": ["BSD-3-Clause"], "max...
/* Boost.MultiIndex example of use of rearrange facilities. * * Copyright 2003-2008 Joaquin M Lopez Munoz. * 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) * * See http://www.boost.org/libs/multi_index ...
{"hexsha": "593ac8d5a0c35f8c5ff78963f0c66361e74768ba", "size": 6649, "ext": "cpp", "lang": "C++", "max_stars_repo_path": "libs/multi_index/example/rearrange.cpp", "max_stars_repo_name": "zyiacas/boost-doc-zh", "max_stars_repo_head_hexsha": "689e5a3a0a4dbead1a960f7b039e3decda54aa2c", "max_stars_repo_licenses": ["BSL-1.0...
import meep as mp import math import cmath import numpy as np import pickle def run_nanodisk_simulation(name, empty, sx, sy, theta, resolution, heights_vector, materials_vector, geometries_vector, characteristic_vector, abs_layer, air_layer, lmin, lmax, coating_layer=None, magnetic_field=mp.Vector3(0,...
{"hexsha": "819f56b90f9f6adcb3730e0d1c0423f3544aa43a", "size": 7702, "ext": "py", "lang": "Python", "max_stars_repo_path": "src/multicore.py", "max_stars_repo_name": "oscarmunoz20/owlmPy", "max_stars_repo_head_hexsha": "c5a41bef431f86da213566dda4382afd13bd6883", "max_stars_repo_licenses": ["MIT"], "max_stars_count": nu...
"""A very simple animation.""" import numpy as np from pysketcher import Angle, Circle, Figure, Line, Point from pysketcher.backend.matplotlib import MatplotlibBackend from pysketcher.composition import Composition def main(): circle = Circle(Point(0, 0), 1) line = Line(Point(0, 0), Point(0, 1)) def fun...
{"hexsha": "c7b7efa78931291a6d36cfb3ed7bfdba2548fc9c", "size": 677, "ext": "py", "lang": "Python", "max_stars_repo_path": "examples/animation.py", "max_stars_repo_name": "rddaz2013/pysketcher", "max_stars_repo_head_hexsha": "9d4079baf0aa04f8fa80dc6edcf03bf1c14f70a4", "max_stars_repo_licenses": ["MIT"], "max_stars_count...
using Documenter, Hashpipe makedocs(sitename="Hashpipe Documentation", modules = [Hashpipe], ) deploydocs( repo = "github.com/max-Hawkins/Hashpipe.jl.git", devbranch = "main" )
{"hexsha": "894bb4bef3d01b7770fe84943aa2da0a2e68ee92", "size": 195, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "docs/make.jl", "max_stars_repo_name": "max-Hawkins/Hashpipe.jl", "max_stars_repo_head_hexsha": "cec9ec56830f094df05f6c98badaa8ea84612b87", "max_stars_repo_licenses": ["MIT"], "max_stars_count": 1, "...
module NamedIndexing export NamedAxisArray export axisnames struct NamedAxisArray{T, N, A<:AbstractArray{T, N}, Names} <: AbstractArray{T, N} data::A end function NamedAxisArray(data::A, names::NTuple{N, Symbol}) where {T, N, A<:AbstractArray{T, N}} NamedAxisArray{T, N, A, names}(data) end Base.size(AA::Nam...
{"hexsha": "0c0687067b95d9551d60eeb8886431fa5dbd979a", "size": 1055, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "src/NamedIndexing.jl", "max_stars_repo_name": "iamed2/NamedIndexing.jl", "max_stars_repo_head_hexsha": "043097ba4ad29591c7407b60a8a024c2bf6005a8", "max_stars_repo_licenses": ["MIT"], "max_stars_cou...
from math import fabs as fabs from math import floor as floor from math import sqrt as sqrt from scipy.special import erfc as erfc from scipy.special import gammaincc as gammaincc class FrequencyTest: @staticmethod def monobit_test(binary_data:str, verbose=False): """ The focus of the test is ...
{"hexsha": "c7cbcb99e05b0172a53e491c20ba5a4d7a568115", "size": 5258, "ext": "py", "lang": "Python", "max_stars_repo_path": "nist_randomness_testsuite/FrequencyTest.py", "max_stars_repo_name": "Goluck-Konuko/cellular_automata_prng", "max_stars_repo_head_hexsha": "da8bb374ff4c9f0b508c767e2787754f6de1e56a", "max_stars_rep...
__doc__ = \ """ ================================================================ Application Input/Output utilities (:mod:`mango.application.io`) ================================================================ .. currentmodule:: mango.application.io Application specific input/output utilities. Classes ======= .. a...
{"hexsha": "8d926162db1a577139cf18cf227dfe7d73b98a5d", "size": 11037, "ext": "py", "lang": "Python", "max_stars_repo_path": "misc/python/mango/application/io.py", "max_stars_repo_name": "pymango/pymango", "max_stars_repo_head_hexsha": "b55f831f0194b214e746b2dfb4d9c6671a1abc38", "max_stars_repo_licenses": ["BSD-2-Clause...
# Copyright (c) 2020 Jeff Irion and contributors # # This file originated from the `graphslam` package: # # https://github.com/JeffLIrion/python-graphslam r"""A ``Graph`` class that stores the edges and vertices required for Graph SLAM. """ from collections import defaultdict from functools import reduce import w...
{"hexsha": "83c181dc792c98a9b27a0b70b23dfd7072aa3b9d", "size": 8832, "ext": "py", "lang": "Python", "max_stars_repo_path": "SLAM/GraphBasedSLAM/graphslam/graph.py", "max_stars_repo_name": "pruidzeko/PythonRobotics", "max_stars_repo_head_hexsha": "5ff9b70d737121c2947d844ecfb1fa07abdd210c", "max_stars_repo_licenses": ["M...
struct Identity <: LocalOperator end kernelvals(biop::Identity, x) = nothing integrand(op::Identity, kernel, x, g, f) = dot(f[1], g[1]) scalartype(op::Identity) = Union{} struct NCross <: LocalOperator end kernelvals(op::NCross, mp) = nothing integrand(op::NCross, kernel, x, g, f) = dot(g[1], normal(x) × f[1]) scala...
{"hexsha": "ad362fb559554dce29615b25077e7a4ff5a048b7", "size": 4075, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "src/identityop.jl", "max_stars_repo_name": "paresula/BEAST.jl", "max_stars_repo_head_hexsha": "44be41a27c6ab2cb6b9ecf43a6a90a4ff8f3488a", "max_stars_repo_licenses": ["MIT"], "max_stars_count": null...
import torch import torch.nn import torch.nn.functional as nn import torch.autograd as autograd import torch.optim as optim import numpy as np import matplotlib.pyplot as plt import matplotlib.gridspec as gridspec import os from torch.autograd import Variable from tensorflow.examples.tutorials.mnist import in...
{"hexsha": "3f26844890a761f6fce3402749f35a3d21a617b1", "size": 4849, "ext": "py", "lang": "Python", "max_stars_repo_path": "GAN/dual_gan/dualgan_pytorch.py", "max_stars_repo_name": "vtabbott/generative-models", "max_stars_repo_head_hexsha": "c97ae1b396a32ef8908e27468aef78b758202d1c", "max_stars_repo_licenses": ["Unlice...
# http://hdfeos.org/zoo/index_openLAADS_Examples.php import os import matplotlib as mpl import matplotlib.pyplot as plt import cartopy.crs as ccrs import numpy as np from cartopy.mpl.gridliner import LONGITUDE_FORMATTER, LATITUDE_FORMATTER FILE_NAME = 'MOD08_D3.A2010001.006.2015041224130.hdf' DATAFIELD_NAME = 'Cloud_F...
{"hexsha": "86e3c91c800e2a5f8102c1044c5b8380fa7487fa", "size": 2064, "ext": "py", "lang": "Python", "max_stars_repo_path": "gis/hdf_tests/laads_example.py", "max_stars_repo_name": "natelowry/data_visualization", "max_stars_repo_head_hexsha": "8d01b6ae5337ff5c7a4eda59e657a53d19af5f32", "max_stars_repo_licenses": ["MIT"]...
#-*- coding:utf-8 -*- #''' # Created on 19-5-15 上午11:48 # # @Author: Greg Gao(laygin) #''' import numpy as np import cv2 import xml.etree.ElementTree as ET from skimage.draw import polygon as drawpoly from functools import reduce from utils import compute_distance_of_2pts, compute_angle_of_2pts from keras.applications....
{"hexsha": "4498dda7402455cc705174cf92198283483fab81", "size": 7583, "ext": "py", "lang": "Python", "max_stars_repo_path": "data/data_utils.py", "max_stars_repo_name": "opconty/keras_std_plus_plus", "max_stars_repo_head_hexsha": "36939047573c4c768e6008e9c475a62c5b23e5f6", "max_stars_repo_licenses": ["Apache-2.0"], "max...
SUBROUTINE SCHDC(A,LDA,P,WORK,JPVT,JOB,INFO) INTEGER LDA,P,JPVT(*),JOB,INFO REAL A(LDA,*),WORK(*) INTEGER PU,PL,PLP1,J,JP,JT,K,KB,KM1,KP1,L,MAXL REAL TEMP REAL MAXDIA LOGICAL SWAPK,NEGK PL=1 PU=0 INFO=P IF(JOB.EQ.0)GOTO160 DO70K=1,P SWAPK=JPV...
{"hexsha": "3c0a86517e00614d5e44a83587a083cf804a41e3", "size": 74183, "ext": "f", "lang": "FORTRAN", "max_stars_repo_path": "math/blas/sgeco.f", "max_stars_repo_name": "fluffynukeit/mdsplus", "max_stars_repo_head_hexsha": "a204d2e9d26554bb035945595210f2a57d187250", "max_stars_repo_licenses": ["BSD-2-Clause"], "max_star...
import numpy as np import tensorflow as tf import os import sys def fatal_error(message): tf.logging.log(tf.logging.ERROR, message) sys.exit(1) def init_logging(verbosity): tf.logging.set_verbosity(verbosity) tf.logging.log(tf.logging.INFO, "Using Python version %s" % sys.version) tf.logging.log...
{"hexsha": "772dcf0ab49998b10a783704e2d173b2e5b5e196", "size": 4880, "ext": "py", "lang": "Python", "max_stars_repo_path": "src/util.py", "max_stars_repo_name": "kleag/LISA", "max_stars_repo_head_hexsha": "7fa9812577a517d51d0c5006400d292292aefad6", "max_stars_repo_licenses": ["Apache-2.0"], "max_stars_count": null, "ma...
#!/usr/bin/env python # import sys # import os # # # Using https://stackoverflow.com/questions/51520/how-to-get-an-absolute-file-path-in-python # utils_path = os.path.abspath("utils") # # # Using https://askubuntu.com/questions/470982/how-to-add-a-python-module-to-syspath/471168 # sys.path.insert(0, utils_path) impo...
{"hexsha": "1d09d04ed22ed23ff0982d6a11a6d380345bb303", "size": 23722, "ext": "py", "lang": "Python", "max_stars_repo_path": "feature_extraction.py", "max_stars_repo_name": "varun-invent/feature-extractor", "max_stars_repo_head_hexsha": "82a4f2e0a0523e0e6bcd5d7cd0d434e6d76951f0", "max_stars_repo_licenses": ["MIT"], "max...
import numpy as np import matplotlib.pyplot as plt from matplotlib import style import datetime as dt import pandas as pd import bs4 as bs import pickle import requests import os import pandas_datareader.data as web import yfinance as yf style.use('ggplot') # Extract Current top 50 Stocks which are part of Nifty50 de...
{"hexsha": "008cfd303e6e6c99dd1c3b5b62bb56cbe33cc4ee", "size": 2958, "ext": "py", "lang": "Python", "max_stars_repo_path": "heatmap.py", "max_stars_repo_name": "vbyravarasu/Real-Time-Stock-Market-Prediction-using-Ensemble-DL-and-Rainbow-DQN", "max_stars_repo_head_hexsha": "4ed7fc2a3995c33cf7b009810c73d01223ea85e4", "ma...
using Test using ExportWebAssembly myfun(x) = sum((x, x, 1.0)) write_bitcode("myfun.bc", myfun, Tuple{Float64}) f() = @extern(:myfun, Int32, Tuple{Float64, Int64}, 1.1, 3) @code_llvm f()
{"hexsha": "a2de112dd7cfb46158d0503394545f50d07d5411", "size": 199, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "test/runtests.jl", "max_stars_repo_name": "tshort/ExportWebAssembly.jl", "max_stars_repo_head_hexsha": "da1b1c221510baa020b89dbfd2c3c9d321aa8869", "max_stars_repo_licenses": ["MIT"], "max_stars_coun...
import numpy as np def make_ngrams(tokens: list, n: int) -> list: """Creates n-grams for the given token sequence. Args: tokens (list): a list of tokens as strings n (int): the length of n-grams to create Returns: list: list of tuples of strings, each tuple being one of the individual n-grams...
{"hexsha": "b1219ad260df87d873413c14951392f7761d81c3", "size": 5115, "ext": "py", "lang": "Python", "max_stars_repo_path": "src/models/ngram.py", "max_stars_repo_name": "JohnnyWang1998/ukraineRussiaTweetsSentimentAnalysis", "max_stars_repo_head_hexsha": "80132e1b453b4439c1610fc6b073dcce76307fb5", "max_stars_repo_licens...
import math import numpy as np class Interval: def __init__(self, x): self.x = x.copy() def __repr__(self): """ Representation of the interval as [a, b] :return: rounded ends of the interval """ return "[" + str(round(self.x[0], 3)) + ", " + str(round(self.x[1...
{"hexsha": "0e54560849d4c32b4b8524a9858cd9bcba8d46f4", "size": 11226, "ext": "py", "lang": "Python", "max_stars_repo_path": "src/intervalpy/interval.py", "max_stars_repo_name": "artemmam/intervalpy", "max_stars_repo_head_hexsha": "bf550dc26457f3786fc52c3056b9c716588d03d7", "max_stars_repo_licenses": ["MIT"], "max_stars...
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not u...
{"hexsha": "d168af6b10aa64ce3c4d3bcc3cab32ecdbdf21fa", "size": 15197, "ext": "py", "lang": "Python", "max_stars_repo_path": "python/mxnet/numpy_extension/_op.py", "max_stars_repo_name": "blazej-wieliczko/incubator-mxnet", "max_stars_repo_head_hexsha": "66a65924f03e6e62ca0619afb02e2a674fcccbfd", "max_stars_repo_licenses...
import numpy as np import ipdb import torch import torch.nn as nn import numpy as np import random from model import Policy, StateGen from baselines.common.segment_tree import SumSegmentTree, MinSegmentTree from utils_bw import select_mj, evaluate_mj, zero_mean_unit_std class ReplayBuffer: """ Replay buffer......
{"hexsha": "ce17066850db0fa6384234b6c03273700d206de8", "size": 19160, "ext": "py", "lang": "Python", "max_stars_repo_path": "bw_module_mujoco.py", "max_stars_repo_name": "soumye/bwmodel", "max_stars_repo_head_hexsha": "d6e321f23145c653598c979c884ee1bc70aaefe2", "max_stars_repo_licenses": ["MIT"], "max_stars_count": 1, ...
# # Comparison with MathOptInterface on a Probability Simplex # In this example, we project a random point onto a probability simplex with the Frank-Wolfe algorithm using # either the specialized LMO defined in the package or a generic LP formulation using `MathOptInterface.jl` (MOI) and # `GLPK` as underlying LP solv...
{"hexsha": "4b40e832bcf88edbc45b8df06ac98a83296c829c", "size": 3797, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "examples/docs_1_mathopt_lmo.jl", "max_stars_repo_name": "gdalle/FrankWolfe.jl-2", "max_stars_repo_head_hexsha": "c3b3903c4808e24aa9e0f655aa2f8de0f2c1571c", "max_stars_repo_licenses": ["MIT"], "max_...
! @@name: target_update.2f ! @@type: F-free ! @@compilable: yes ! @@linkable: no ! @@expect: success subroutine vec_mult(p, v1, v2, N) interface logical function maybe_init_again (v1, N) real :: v1(N) integer :: N end function end interface real :: p(N), v1(N), v2(N) integer :: ...
{"hexsha": "38d44f39bc6c4aa2a426803a2ea3e02d5b5186e0", "size": 939, "ext": "f", "lang": "FORTRAN", "max_stars_repo_path": "test/openmp_examples/sources/Example_target_update.2f.f", "max_stars_repo_name": "kammerdienerb/flang", "max_stars_repo_head_hexsha": "8cc4a02b94713750f09fe6b756d33daced0b4a74", "max_stars_repo_lic...
from collections import namedtuple from numpy import std, zeros, cumsum, mean, r_, copy from numpy import sum as npsum, min as npmin, max as npmax def PnlStats(pnl_contr): # This function computes some Profit and loss (P&L) statistics # INPUT # pnl_contr :[matrix] (n_ x t_end) portfolio P&L contribu...
{"hexsha": "df1fc4de2d2c320ed0f170bb754fdbeefb0ad586", "size": 1441, "ext": "py", "lang": "Python", "max_stars_repo_path": "functions_legacy/PnlStats.py", "max_stars_repo_name": "dpopadic/arpmRes", "max_stars_repo_head_hexsha": "ddcc4de713b46e3e9dcb77cc08c502ce4df54f76", "max_stars_repo_licenses": ["MIT"], "max_stars_c...
from __future__ import division from __future__ import print_function import copy import csv import json import numpy as np import scipy.linalg import scipy.io as sio import os import os.path as osp import cPickle as pickle import cPickle as pkl import torch from torch.autograd import Variable from . import transformat...
{"hexsha": "cb08eb56217c26219e9f65d00ef8b74ae9a24d8f", "size": 3258, "ext": "py", "lang": "Python", "max_stars_repo_path": "acsm/utils/cub_parse.py", "max_stars_repo_name": "eldar/acsm", "max_stars_repo_head_hexsha": "04069e8bb4c12185473dc10c3355e5367fa98968", "max_stars_repo_licenses": ["Apache-2.0"], "max_stars_count...
from new_keras_rnn import _rnn_and_lstm from transformer import _transformer import numpy as np from tensorflow import keras from tensorflow.keras import layers from tensorflow.keras.utils import to_categorical import tensorflow as tf from data_process import load_text,load_label from data_process import histogram_bui...
{"hexsha": "e355f28b19f8c948f8748a46a98ca13e557e2832", "size": 2474, "ext": "py", "lang": "Python", "max_stars_repo_path": "src/DNN_Based_Classification.py", "max_stars_repo_name": "Adonis-galaxy/AI_Final_Project", "max_stars_repo_head_hexsha": "98b9a815a2053e85fd07ac47cb7fbac47d7b83a0", "max_stars_repo_licenses": ["MI...
SUBROUTINE CALHDMF ! *** CALDMF CALCULATES THE HORIZONTAL VISCOSITY AND ! *** DIFFUSIVE MOMENTUM FLUXES. THE VISCOSITY, AH IS CALCULATED USING ! *** SMAGORINSKY'S SUBGRID SCALE FORMULATION PLUS ...
{"hexsha": "22a2ee3dcd4db95f219f9ad831175e258b1c5550", "size": 11596, "ext": "f90", "lang": "FORTRAN", "max_stars_repo_path": "EFDC/calhdmf.f90", "max_stars_repo_name": "dsi-llc/EFDCPlus", "max_stars_repo_head_hexsha": "27ece1cd0bb9e02a46d1ad20f343bc5d109acfb3", "max_stars_repo_licenses": ["BSD-3-Clause"], "max_stars_c...
import operator import numpy as np import pandas as pd from typing import Any from typing import List from typing import Dict from typing import Tuple from typing import Union from typing import Optional from typing import Iterable from pyrobot.stock_frame import StockFrame class Indicators(): """ Represen...
{"hexsha": "43aa569d33cca72d3da7aa4de577a4d447ddc451", "size": 36546, "ext": "py", "lang": "Python", "max_stars_repo_path": "pyrobot/indicators.py", "max_stars_repo_name": "Saby-Bishops/Stock-Prediction-using-different-models", "max_stars_repo_head_hexsha": "123f1e26c417300829a8ccb1007995dfa574db65", "max_stars_repo_li...
/* * Software License Agreement (BSD License) * * Point Cloud Library (PCL) - www.pointclouds.org * Copyright (c) 2011, Willow Garage, Inc. * * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions ...
{"hexsha": "4400aa7dc5284b7113d34d6c8e2ccce1fa7d87ce", "size": 5442, "ext": "cpp", "lang": "C++", "max_stars_repo_path": "kfusion/src/color_volume.cpp", "max_stars_repo_name": "libin1987832/kinfu_remake", "max_stars_repo_head_hexsha": "7e44feba65daf67bb59447d5128f4a669b841ece", "max_stars_repo_licenses": ["BSD-3-Clause...
import numpy as np # linear algebra import pandas as pd # data processing, CSV file I/O (e.g. pd.read_csv) import matplotlib.pyplot as plt import os from sklearn.metrics import f1_score import graphviz from sklearn import tree import seaborn as sns import tensorflow as tf from sklearn.model_selection import train_test_...
{"hexsha": "91f68a51f6aee14d391c6c27b222d8f40dd4d351", "size": 3693, "ext": "py", "lang": "Python", "max_stars_repo_path": "ion/preproc.py", "max_stars_repo_name": "nizamphoenix/kaggle", "max_stars_repo_head_hexsha": "a9c993d0441a6d9260d605a630f95d938e6329db", "max_stars_repo_licenses": ["MIT"], "max_stars_count": null...
values_per = values_per + 1 indices(values_per) = insert_row values(values_per) = insert_value
{"hexsha": "22579a81b42fd4faf9f4d4f4f459e47c8e3ad465", "size": 101, "ext": "f90", "lang": "FORTRAN", "max_stars_repo_path": "Source/Fortran/solver_includes/AppendToVector.f90", "max_stars_repo_name": "Kokookster/NTPoly", "max_stars_repo_head_hexsha": "717b2e344e800ea6c2de7061b96dd51ffd089f36", "max_stars_repo_licenses"...
import numpy as np import pyomo.environ as pyo from pyomo.core.expr import numeric_expr from pyomo.opt import SolverFactory from sklearn.preprocessing import StandardScaler from penlm.base_estimators import BaseClassifier, BaseRegressor from abc import ABC, abstractmethod from typing import Dict, Tuple class BaseSmo...
{"hexsha": "81ffbc49c6aad9a7bb64df9f303d37e77565e1bb", "size": 6983, "ext": "py", "lang": "Python", "max_stars_repo_path": "penlm/smooth_linear_model.py", "max_stars_repo_name": "bellibot/penlm", "max_stars_repo_head_hexsha": "cd3e82c319ed221cfdbd6c566ee63be26b3aa6fb", "max_stars_repo_licenses": ["MIT"], "max_stars_cou...
from . import ZClient, UClient from .. import TRIGGER_SETUP_SEQ, START_DAQ, STOP_DAQ import numpy as np import curio class ZClientCurioBase(ZClient): def __init__(self, *args, max_events=None, **kwargs): super().__init__(*args, **kwargs) self.cmd_lock = curio.Lock() async def __cntrl_recv(sel...
{"hexsha": "74b490741027b4cc691ab112ca69a107cb7a6ed6", "size": 4085, "ext": "py", "lang": "Python", "max_stars_repo_path": "pygerm/client/curio_zmq.py", "max_stars_repo_name": "NSLS-II/GeRM", "max_stars_repo_head_hexsha": "b9251d171ca768b6a1a8d6af774afe5c670b6661", "max_stars_repo_licenses": ["BSD-3-Clause"], "max_star...
import numpy as np def intersection(line1, line2): """Finds the intersection of two lines given in Hesse normal form. Returns closest integer pixel locations. See https://stackoverflow.com/a/383527/5087436 """ rho1, theta1 = line1[0] rho2, theta2 = line2[0] A = np.array([ [np.cos(t...
{"hexsha": "a5d97a6992957fb11767d85eed4af4c723e3e2d5", "size": 992, "ext": "py", "lang": "Python", "max_stars_repo_path": "intersection.py", "max_stars_repo_name": "sahil2kuppal/sudoku", "max_stars_repo_head_hexsha": "7b81459d229efc494a67ea3b4077ed42dd6d81c1", "max_stars_repo_licenses": ["Apache-2.0"], "max_stars_count...
# Copyright 2020 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 a...
{"hexsha": "96ada060899917c90d9bd8b1baed8223bde5fb3e", "size": 15758, "ext": "py", "lang": "Python", "max_stars_repo_path": "mindspore/nn/probability/toolbox/uncertainty_evaluation.py", "max_stars_repo_name": "dongkcs/mindspore", "max_stars_repo_head_hexsha": "cd7df6dbf463ff3128e9181e9d0c779cecb81320", "max_stars_repo_...
import JuliaCLI @async JuliaCLI.serve() # TODO: don't let path = joinpath(DEPOT_PATH[1], "jlcli", "socket") for i in 1:100 isfile(path) && break sleep(0.1) end end include("cli_test.jl")
{"hexsha": "5de84195f00b4cd28f81e7d95804562a9c90dcfc", "size": 214, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "test/runtests.jl", "max_stars_repo_name": "tkf/JuliaCLI.jl", "max_stars_repo_head_hexsha": "34f519837af9e2706a44b7945c5e09f93b41f1de", "max_stars_repo_licenses": ["MIT"], "max_stars_count": 7, "max_...