text
stringlengths
0
1.25M
meta
stringlengths
47
1.89k
from util import read_file import random import time import numpy import sys def generate_set(adj_list, threshold, start): queue = [(start, 0)] visited = set() visited.add(start) while len(queue) > 0: front = queue.pop(0) if front[1] > threshold: return visited for...
{"hexsha": "f4fe84eee97d22fca548dcc03a7eccaa535a3af8", "size": 2617, "ext": "py", "lang": "Python", "max_stars_repo_path": "PYTHON/tim.py", "max_stars_repo_name": "simp1eton/CS224W_Final_Project", "max_stars_repo_head_hexsha": "fc125c1e46598a22f9e9c6e0fe081682a7476cdc", "max_stars_repo_licenses": ["MIT"], "max_stars_co...
from copy import copy import numpy as np from matplotlib import pyplot as plt # based on # https://github.com/anujgupta82/Musings # https://matplotlib.org/gallery/images_contours_and_fields/image_annotated_heatmap.html # to make the dynamic figure updates work one needs to cast # "%matplotlib notebook" magic in the ...
{"hexsha": "c1d42327b260e6a45b2440c446876a7b8e86e206", "size": 3471, "ext": "py", "lang": "Python", "max_stars_repo_path": "two048/display.py", "max_stars_repo_name": "0xb0b/a0", "max_stars_repo_head_hexsha": "53792065bb48d814572988710324d28b66f4bf34", "max_stars_repo_licenses": ["MIT"], "max_stars_count": null, "max_s...
# -*- coding: utf-8 -*- # lib_bb_analyzer # Jose Alfredo Martin 2020 version = 'lib_bb_analyzer.v.9.0.0' # Python modules import os import pickle as pic import copy import time import argparse # Local modules from classes.bbt import BBT from classes.design import Design from classes.libdesign import Li...
{"hexsha": "23b3586a59d22bdf6626cc9d6052a5d5ad3dc12c", "size": 12689, "ext": "py", "lang": "Python", "max_stars_repo_path": "edesigner/lib_bb_analyzer.py", "max_stars_repo_name": "jamflcgh/edesigner_core", "max_stars_repo_head_hexsha": "2d17fe40d24ab4b440986a6814dbcc618beae78e", "max_stars_repo_licenses": ["Apache-2.0"...
#!/usr/bin/env python # coding: utf-8 """ ============================================== Para usar o script digite no terminal: python3 mari_filter_reciprocal_hits.py arquivo_entrada_multihit.tsv arquivo_saida.tsv ============================================== """ import pandas as pd import numpy as np import sys #...
{"hexsha": "8b18bc8a79f7a0f72c77867ba9a4919e22ded446", "size": 1058, "ext": "py", "lang": "Python", "max_stars_repo_path": "for_colleagues/M07_filter_reciprocal_hits.py", "max_stars_repo_name": "Tiago-Minuzzi/lab-stuff", "max_stars_repo_head_hexsha": "b4cbca8c578e3cc4035df5686254d9254a876413", "max_stars_repo_licenses"...
""" Name: Danesh Badlani Test 2 Implementation of KNN Classifier """ # import statements from sklearn.model_selection import train_test_split import pandas as pd import numpy as np from matplotlib.colors import ListedColormap import matplotlib.pyplot as plt from mlxtend.plotting import plot_decision_regions import t...
{"hexsha": "92720267ae459ed0f23eac75899e851c6ca79e31", "size": 4748, "ext": "py", "lang": "Python", "max_stars_repo_path": "KNN.py", "max_stars_repo_name": "daneshbadlani/Graduate-Admission-Prediction", "max_stars_repo_head_hexsha": "f96cda1983242cac8cc9fea34feb08cf854ce454", "max_stars_repo_licenses": ["MIT"], "max_st...
import os import threading import logging import time import sys import csv from datetime import datetime from collections import deque import cv2 import numpy as np from IPython.display import display, Image, clear_output import ipywidgets from .utils import OutputWidgetHandler, wrapper,scan_camera_settings clas...
{"hexsha": "d392fc8a256f7ddec62ebf05dc9337491670cd8e", "size": 14594, "ext": "py", "lang": "Python", "max_stars_repo_path": "pme/core.py", "max_stars_repo_name": "totti0223/onsite_stomata_platform", "max_stars_repo_head_hexsha": "fc71aa72754325a84b95046b49bfd32c94c71f1b", "max_stars_repo_licenses": ["Unlicense"], "max_...
import networkx as nx import pickle import os import networkx as nx from collections import Counter import sys print(sys.argv) # DATA_PATH = '/data/split_name_hr/' DATA_PATH = sys.argv[1] # city, name, phone # VARIABLE = 'city' VARIABLE = sys.argv[2] # hp or hr # TYPE = 'hp' TYPE = sys.argv[3] total_degree = None fo...
{"hexsha": "edcff031a0501a0aba3b758ad3ce7a90cf5befea", "size": 1058, "ext": "py", "lang": "Python", "max_stars_repo_path": "combine_degrees_subscript.py", "max_stars_repo_name": "r-kapoor/dig-network", "max_stars_repo_head_hexsha": "1e17132140d28cc1e302d4749833700c86927c9b", "max_stars_repo_licenses": ["MIT"], "max_sta...
#include <iostream> #include <fstream> #include <vector> #include <random> #include <Eigen/Dense> #include "../include/GaussianHMM.h" using namespace Eigen; int main() { std::cout << "Start ...\n"; double var = 1.0; std::random_device seed; std::mt19937 random_number_generator(seed()); std::normal_distributi...
{"hexsha": "61e47e600a681cfe661a1643ec58484af0e5d8b7", "size": 1492, "ext": "cpp", "lang": "C++", "max_stars_repo_path": "unit_test/hmm_test.cpp", "max_stars_repo_name": "zixuanweeei/FAT", "max_stars_repo_head_hexsha": "a4100dc152fba2e2d1dbb46cfdd3ab0ee4264830", "max_stars_repo_licenses": ["MIT"], "max_stars_count": nu...
theory T81 imports Main begin lemma "( (\<forall> x::nat. \<forall> y::nat. meet(x, y) = meet(y, x)) & (\<forall> x::nat. \<forall> y::nat. join(x, y) = join(y, x)) & (\<forall> x::nat. \<forall> y::nat. \<forall> z::nat. meet(x, meet(y, z)) = meet(meet(x, y), z)) & (\<forall> x::nat. \<forall> y::nat. \<forall> z::nat...
{"author": "inpefess", "repo": "residuated-binars", "sha": "330aaa51b6dbcaa06f8a6d15fe17c1ce58ae2a59", "save_path": "github-repos/isabelle/inpefess-residuated-binars", "path": "github-repos/isabelle/inpefess-residuated-binars/residuated-binars-330aaa51b6dbcaa06f8a6d15fe17c1ce58ae2a59/involution/task7/T81.thy"}
import numpy as np import matplotlib.pyplot as plt from gym_flock.envs.spatial.utils import _get_pos_diff from scipy.spatial import Delaunay from pathlib import Path def in_obstacle(obstacles, px, py): """ Check if query point is within any of the rectangular obstacles :param obstacles: list of rectangula...
{"hexsha": "058d4bddce231e36351a47ee85bbfc171b832215", "size": 9524, "ext": "py", "lang": "Python", "max_stars_repo_path": "gym_flock/envs/spatial/make_map.py", "max_stars_repo_name": "katetolstaya/gym-flock", "max_stars_repo_head_hexsha": "3236d1dafcb1b9be0cf78b471672e8becb2d37af", "max_stars_repo_licenses": ["MIT"], ...
! ################################################################################################################################## ! Begin MIT license text. ! ___________________________________________________________________________...
{"hexsha": "9135bf70851c4cc3a218894b27cc7b86bcf8a3d9", "size": 14916, "ext": "f90", "lang": "FORTRAN", "max_stars_repo_path": "Source/LK9/L91/WRITE_ELEM_NODE_FORCE.f90", "max_stars_repo_name": "JohnDN90/MYSTRAN", "max_stars_repo_head_hexsha": "1dd7dc19e54c1bb2b5235244af65115950e21488", "max_stars_repo_licenses": ["MIT"...
[GOAL] 𝕜 : Type u_1 m : Type u_2 n : Type u_3 E : Type u_4 inst✝² : IsROrC 𝕜 inst✝¹ : Fintype n inst✝ : DecidableEq n U : Matrix n n 𝕜 hU : U ∈ Matrix.unitaryGroup n 𝕜 i j : n ⊢ ‖U i j‖ ≤ 1 [PROOFSTEP] have norm_sum : ‖U i j‖ ^ 2 ≤ ∑ x, ‖U i x‖ ^ 2 := by apply Multiset.single_le_sum · intro x h_x rw [Mult...
{"mathlib_filename": "Mathlib.Analysis.NormedSpace.Star.Matrix", "llama_tokens": 6349}
import os import pickle import numpy as np import pandas as pd from allennlp.predictors import Predictor # from models.customization_package.model.custom_bimpm_predictor import CustomBiMPMPredictor # from models.customization_package.dataset_readers.custom_reader import CustomDataReader from models.bimpm_custom_packag...
{"hexsha": "d70974964d86e7772077a5afd3f8d0a3ff9a3f02", "size": 24636, "ext": "py", "lang": "Python", "max_stars_repo_path": "src/isanlp_rst/classifier_wrappers.py", "max_stars_repo_name": "tchewik/isanlp_rst", "max_stars_repo_head_hexsha": "459864b3daeeb702acf5e65543181068439ce12c", "max_stars_repo_licenses": ["MIT"], ...
import numpy as np def sliding_window_avg(data, i_window): avg = np.empty(data.shape) n_samples = data.shape[1] for i_sample in range(n_samples): if i_sample % 10000 == 0: print('{}/{} samples'.format(i_sample + 1, n_samples)) if i_sample < i_window//2: i_low = 0 ...
{"hexsha": "9003429c9d319786e94b03de6070fbd01acd391b", "size": 1884, "ext": "py", "lang": "Python", "max_stars_repo_path": "AWERA/eval/eval_utils.py", "max_stars_repo_name": "lthUniBonn/AWERA", "max_stars_repo_head_hexsha": "fa7f210516318bcfcbe1c99abbb5954b0cbaf682", "max_stars_repo_licenses": ["MIT"], "max_stars_count...
[STATEMENT] lemma skl1_refines_trans_a0i_i [iff]: "{R0sk1iai \<inter> (UNIV \<times> (skl1_inv1 \<inter> skl1_inv2))} trans a0i, trans skl1 {> R0sk1iai}" [PROOF STATE] proof (prove) goal (1 subgoal): 1. {R0sk1iai \<inter> UNIV \<times> (skl1_inv1 \<inter> skl1_inv2)} TS.trans a0i, TS.trans skl1 {> R0sk1iai} [PROOF S...
{"llama_tokens": 5067, "file": "Key_Agreement_Strong_Adversaries_sklvl1", "length": 20}
from pathlib import Path import itk from itkwasm import Image from dataclasses import asdict import numpy as np def test_image(): data = Path(__file__).absolute().parent / "input" / "cthead1.png" itk_image = itk.imread(data, itk.UC) itk_image_dict = itk.dict_from_image(itk_image) itkwasm_image = Imag...
{"hexsha": "77265bc10d053bae907d04408dd620a336c9f9b8", "size": 566, "ext": "py", "lang": "Python", "max_stars_repo_path": "src/python/test/test_image.py", "max_stars_repo_name": "thewtex/itk-wasm", "max_stars_repo_head_hexsha": "9b02b685bb3eea5fb479dc8a39a4cdc853b6e88e", "max_stars_repo_licenses": ["Apache-2.0"], "max_...
[STATEMENT] lemma lhopital: "(f \<longlongrightarrow> 0) (at x) \<Longrightarrow> (g \<longlongrightarrow> 0) (at x) \<Longrightarrow> eventually (\<lambda>x. g x \<noteq> 0) (at x) \<Longrightarrow> eventually (\<lambda>x. g' x \<noteq> 0) (at x) \<Longrightarrow> eventually (\<lambda>x. DERIV f x :> f' ...
{"llama_tokens": 858, "file": null, "length": 2}
import numpy as np import numpy from simphony import Model from simphony.pins import Pin from simphony.models import Subcircuit from emepy.mode import EigenMode from emepy.fd import ModeSolver from copy import deepcopy class Layer(object): """Layer objects form the building blocks inside of an EME or PeriodicEME....
{"hexsha": "d9ea65cd9fad9b0a211726e4451ca1bc1e190825", "size": 35845, "ext": "py", "lang": "Python", "max_stars_repo_path": "emepy/models.py", "max_stars_repo_name": "joamatab/emepy", "max_stars_repo_head_hexsha": "6b3119a4355ff70d7cfd3fdf18224920c22be937", "max_stars_repo_licenses": ["MIT"], "max_stars_count": null, "...
from keras.datasets import cifar10, cifar100 from keras.utils import np_utils import keras.backend as K import numpy as np import PIL.Image as im def get_cifar(p, append_test, use_c10): # The raw data, shuffled and split between training and test sets (X_train, y_train), (X_test, y_test) = cifar10.load_data() ...
{"hexsha": "1efd1207b9b8638e647d6cad951b410b2f31badd", "size": 2891, "ext": "py", "lang": "Python", "max_stars_repo_path": "data.py", "max_stars_repo_name": "karazijal/xsertion", "max_stars_repo_head_hexsha": "102c1a4f07b049647064a968257d56b00a064d6c", "max_stars_repo_licenses": ["MIT"], "max_stars_count": null, "max_s...
# Basic Neural Network from Scratch >## Objective: To understand and build a basic one hidden layer Neutral Network from scratch > ## Approach : - **Getting the Dataset** - **Logistic Regression** - **Neural Network : Understanding** - Neural Network structure - Activation functions : Softmax...
{"hexsha": "7273c9247943f40caf1bbd39f1327a1d33942ec4", "size": 77923, "ext": "ipynb", "lang": "Jupyter Notebook", "max_stars_repo_path": "Basic Neural Network from Scratch/Basic Neural Network from Scratch (To-Do Template).ipynb", "max_stars_repo_name": "abhisngh/Data-Science", "max_stars_repo_head_hexsha": "c7fa9e4d81...
import os import time import math from PIL import Image import numpy as np import requests import urllib.parse from io import BytesIO import IPython import moviepy.editor as mpe from .utils import downloads Image.MAX_IMAGE_PIXELS = 1e9 sample_images = { 'escher_sphere.jpg': '1pXYUSTfVDhJSOES0L0LEhf8A1lB28S4t', ...
{"hexsha": "fb7e1f4f3bd5d962dba8408a53054b3fb0a854ba", "size": 9526, "ext": "py", "lang": "Python", "max_stars_repo_path": "ml4a/image.py", "max_stars_repo_name": "KushGabani/ml4a-guides", "max_stars_repo_head_hexsha": "d71b61a99c417b9ace3404420b37d22f6da06153", "max_stars_repo_licenses": ["MIT"], "max_stars_count": 11...
#!/usr/bin/env python3 # -*- coding: utf-8 -*- ''' Created on Mon Jun 1 09:11:26 2020 Probe Geometry Plots Functions to plot slices of histology data along defined probes, and add probe trajectories or channel coords to these plots. Following functions are defined: @author: stevenwest ''' def plot_probe_traje...
{"hexsha": "887faac474dd098aec09dc75610e4e92c7363866", "size": 3936, "ext": "py", "lang": "Python", "max_stars_repo_path": "probe_geometry_analysis/probe_geometry_plots.py", "max_stars_repo_name": "int-brain-lab/analysis", "max_stars_repo_head_hexsha": "a8bf474815cb6ed690b3da07ff2f501459375b75", "max_stars_repo_license...
module PointProcess # Write your package code here. # install necessary packages (open source) using Statistics, Plots, Distributions , LinearAlgebra # install necessary packages (original) using .FundamentalStats export EmpiricalFireRate export MakeWindow export FanoFactor functio...
{"hexsha": "1e794df13b80f688f4cb1a4e4670267ba481cafa", "size": 1389, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "src/PointProcess.jl", "max_stars_repo_name": "yukki-jpn/JuliaTSA", "max_stars_repo_head_hexsha": "ee6a65b5854be4eb33690c6ff509ae7954cdad3a", "max_stars_repo_licenses": ["MIT"], "max_stars_count": n...
let parser = AnnotaionParser("$testdir/data/gene_association.goa_human") annots = Array(AnnotationRecord, 0) for annot in eachannot(parser) push!(annots, annot) end @test isa(annots[1], AnnotationRecord) @test string(annots[1]) == "AnnotationRecord(\"UniProtKB\", \"A0A183\", \"GO:0031424...
{"hexsha": "dee3aa1aaca7f4d89afa36376c4cd389ddce7ccd", "size": 329, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "test/test_annotation.jl", "max_stars_repo_name": "bicycle1885/GeneOntology.jl", "max_stars_repo_head_hexsha": "537883a354386e3b85794ff81b45a31da4ed5be5", "max_stars_repo_licenses": ["MIT"], "max_sta...
function [zgrid,xgrid,ygrid] = gridfit(x,y,z,xnodes,ynodes,varargin) % gridfit: estimates a surface on a 2d grid, based on scattered data % Replicates are allowed. All methods extrapolate to the grid % boundaries. Gridfit uses a modified ridge estimator to % generate the surface, where the bi...
{"author": "vistalab", "repo": "vistasoft", "sha": "7f0102c696c091c858233340cc7e1ab02f064d4c", "save_path": "github-repos/MATLAB/vistalab-vistasoft", "path": "github-repos/MATLAB/vistalab-vistasoft/vistasoft-7f0102c696c091c858233340cc7e1ab02f064d4c/mrAnatomy/hydrationLayer/gridfit.m"}
""" Deep-Q model class incorporates the DeepQNetwork class from deep_q_network.py as a component of the model. """ import random from collections import deque from pathlib import Path from typing import Dict, Union, List, Deque, NamedTuple, Optional import gym import numpy as np import tensorflow as tf from losing_co...
{"hexsha": "5782a03dce5a21049b934ebce6983471f9dd0928", "size": 7380, "ext": "py", "lang": "Python", "max_stars_repo_path": "losing_connect_four/deep_q_model.py", "max_stars_repo_name": "nicolas-chan-42/COMP-3359-Project-Deep-Q-RL", "max_stars_repo_head_hexsha": "6e9098e6d55b8a813b27efc871f179ffeb2cfa9c", "max_stars_rep...
import matplotlib import matplotlib.pyplot as plt import pandas as pd import seaborn as sns import numpy as np import numbers def radarplot(data, file_name, title=None, exclude=None, label=None, show_plots=False, figsize=(5, 3.4)): matplotlib.rcParams['pdf.fonttype'] = 42 matplotlib.rcParams['ps.fonttype'] = ...
{"hexsha": "ce1874b7e6fb8aba79737602fdb2d8b7a1dd70e3", "size": 7590, "ext": "py", "lang": "Python", "max_stars_repo_path": "pipeline/modules/plots.py", "max_stars_repo_name": "gaabrielfranco/ia-moba-tcc", "max_stars_repo_head_hexsha": "3f4b4e5be3e09619d1e893ee9234c835f21ecb83", "max_stars_repo_licenses": ["MIT"], "max_...
# -*- coding: utf-8 -*- from __future__ import absolute_import import tensorflow as tf import numpy as np from chainer.links import caffe class Conv(object): def __init__(self, chainer_conv): W = chainer_conv.W.data b = chainer_conv.b.data self.W = tf.constant(np.transpose(W, [2, 3, 1, 0])) self.b =...
{"hexsha": "2a8a803cd5e6ef07b8643ff613270907d29200fc", "size": 737, "ext": "py", "lang": "Python", "max_stars_repo_path": "_py2/caffe_to_tf.py", "max_stars_repo_name": "mitsusawa/tf-gogh", "max_stars_repo_head_hexsha": "231026f7aa80381d5edb9ce684bf2ae3b3f1dea5", "max_stars_repo_licenses": ["MIT"], "max_stars_count": nu...
[STATEMENT] lemma sum_invert: "N \<le> n \<Longrightarrow> (\<Sum>i = Suc (n - N)..n. f (n - i)) = (\<Sum>j<N. f j)" [PROOF STATE] proof (prove) goal (1 subgoal): 1. N \<le> n \<Longrightarrow> (\<Sum>i = Suc (n - N)..n. f (n - i)) = sum f {..<N} [PROOF STEP] proof (induction N) [PROOF STATE] proof (state) goal (2 sub...
{"llama_tokens": 977, "file": "Khovanskii_Theorem_Khovanskii", "length": 7}
#include <unordered_map> #include <nlohmann/json.hpp> #include <libcommon/PipelineConfig.h> #include <libcommon/config_exceptions.h> #include <boost/format.hpp> #include <libcommon/config_factory.h> //#include <iostream> //#include <iomanip> namespace { bool operator<( const tmk::common::configuration::PipelineNo...
{"hexsha": "08fc52b2a555c965301f84c1bf28ebfddc0e9e2c", "size": 12697, "ext": "cpp", "lang": "C++", "max_stars_repo_path": "libcommon/src/configuration/PipelineConfig.cpp", "max_stars_repo_name": "OlegZhavoronkov/tnk_certification", "max_stars_repo_head_hexsha": "9ef3544f3fd27073b78e38bba26af76e79f55a78", "max_stars_rep...
[STATEMENT] lemma V01_not_in_R_cons: "\<not> learn_cons \<phi> V\<^sub>0\<^sub>1 s" [PROOF STATE] proof (prove) goal (1 subgoal): 1. \<not> learn_cons \<phi> V\<^sub>0\<^sub>1 s [PROOF STEP] proof - [PROOF STATE] proof (state) goal (1 subgoal): 1. \<not> learn_cons \<phi> V\<^sub>0\<^sub>1 s [PROOF STEP] obtain m n w...
{"llama_tokens": 5361, "file": "Inductive_Inference_Lemma_R", "length": 30}
def image_plot(filename): import numpy as np from astropy.io import fits from astropy.wcs import WCS wcs = WCS(image[0].header) import matplotlib.pyplot as plt ax = plt.subplot(projection=wcs) #normally has a projection=... keyword ax.imshow(image[0].data, origin='lower') ax.coords.gri...
{"hexsha": "8264a7bd8068e2a3788db84a9d59bcead0ec413c", "size": 437, "ext": "py", "lang": "Python", "max_stars_repo_path": "final_exercise/final_exercise.py", "max_stars_repo_name": "DannyHorta/rcsc18_lessons", "max_stars_repo_head_hexsha": "a2da959037caa344f20ff8f5eea5dba710b4d66a", "max_stars_repo_licenses": ["CC-BY-4...
import sys import matplotlib.pyplot as plt import numpy as np def tcks(ax): start, stop = ax.get_ylim() yres=(stop-start)//4 ticks = np.arange(start, stop + yres, yres) ax.set_yticks(ticks) lengths=[] for idx,line in enumerate(sys.stdin): score,eng,fin=line.strip().split("\t") lengths.append(...
{"hexsha": "4f5bae2d907c59b9f3853afe103ea5c3d1cee6bf", "size": 798, "ext": "py", "lang": "Python", "max_stars_repo_path": "len_histogram.py", "max_stars_repo_name": "TurkuNLP/SRNNMT", "max_stars_repo_head_hexsha": "c972dc868f461de06a8fe1abd48303c2282f8ee6", "max_stars_repo_licenses": ["Apache-2.0"], "max_stars_count": ...
""" Modules performing small, commonly used tasks throughout the package. """ import numpy as np from astropy.utils.misc import NumpyRNGContext from ..custom_exceptions import HalotoolsError __all__ = ('custom_len', 'find_idx_nearest_val', 'randomly_downsample_data', 'array_is_monotonic', 'unsorting_indic...
{"hexsha": "ea618b0bbeef51d306e59e6f23167a54625306ee", "size": 5919, "ext": "py", "lang": "Python", "max_stars_repo_path": "halotools/utils/array_utils.py", "max_stars_repo_name": "pllim/halotools", "max_stars_repo_head_hexsha": "6499cff09e7e0f169e4f425ee265403f6be816e8", "max_stars_repo_licenses": ["BSD-3-Clause"], "m...
@testset "Affine series simulation" begin y = collect(1.:30) model = structural(y, 2) @test isa(model, StateSpaceModel) @test model.mode == "time-invariant" ss = statespace(model) @test ss.filter_type <: KalmanFilter sim = simulate(ss, 20, 100) media_sim = mean(sim, dims = 3)[:, 1...
{"hexsha": "e620a54c892dd591ff2f843ff93e0a3cd8bdf190", "size": 501, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "test/test_simulate.jl", "max_stars_repo_name": "juliohm/StateSpaceModels.jl", "max_stars_repo_head_hexsha": "951e6018691f52c8c2d41b601d69d3d59d73f27b", "max_stars_repo_licenses": ["MIT"], "max_stars...
import torch import torchvision from torch.utils.data import Dataset import torchvision.transforms as transforms import numpy as np from tqdm import tqdm import matplotlib.pyplot as plt from sklearn.gaussian_process import GaussianProcessRegressor from sklearn.gaussian_process.kernels import RBF, ConstantKernel as C fr...
{"hexsha": "f15242ee696031f0bccd1af53214a092880a4f27", "size": 5468, "ext": "py", "lang": "Python", "max_stars_repo_path": "main.py", "max_stars_repo_name": "robfiras/Tutorial_Bayesian_Optimization_for_optimal_Learning_Rate", "max_stars_repo_head_hexsha": "c46019f66798e6bb625702551afa60906c782199", "max_stars_repo_lice...
import rclpy from rclpy.node import Node from sensor_msgs.msg import Joy from nav_msgs.msg import Odometry from waypoint_interfaces.srv import TerminateWaypointLogging, ToggleWaypointLogging, GetWaypointLogState from .wp_logging import WaypointLogger, LogState from rclpy.qos import qos_profile_sensor_data import numpy...
{"hexsha": "12e2939bcf19b74dcd37b3c3caed79f1459d08f5", "size": 5397, "ext": "py", "lang": "Python", "max_stars_repo_path": "src/navigation/waypoint_logger/waypoint_logger/wp_logging_node.py", "max_stars_repo_name": "Triton-AI/Triton-AI-Racer-ROS2", "max_stars_repo_head_hexsha": "96c5d9303b7f1d88dabf7ae9ceb214741d41f20d...
#!/usr/bin/env python # -*- coding: utf-8 -*- # # Copyright (c) 2021 Idiap Research Institute, http://www.idiap.ch/ # Written by Bastian Schnell <bastian.schnell@idiap.ch> # from enum import Enum from functools import partial import logging import os from types import MethodType from typing import Callable, Dict, List,...
{"hexsha": "b03db33eb68e3e9768d247d288fb310a948c8f69", "size": 17529, "ext": "py", "lang": "Python", "max_stars_repo_path": "idiaptts/src/data_preparation/NpzDataReader.py", "max_stars_repo_name": "idiap/IdiapTTS", "max_stars_repo_head_hexsha": "60413d6847508e269d44aa41885e668db7dfd440", "max_stars_repo_licenses": ["MI...
function part1(input) dims = parse_line.(eachline(input)) return sum(required_paper.(dims)) end function part2(input) dims = parse_line.(eachline(input)) return sum(required_ribbon.(dims)) end parse_line(line) = sort(parse.(Int, split(line, 'x'))) required_paper(dims) = 3 * dims[1] * dims[2] + 2 * dim...
{"hexsha": "4304c1cbeed768f8dc8831ddd22d3466849fdbab", "size": 408, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "2015/day2.jl", "max_stars_repo_name": "GunnarFarneback/AdventOfCode.jl", "max_stars_repo_head_hexsha": "2f60011747bfe5d27e954f914f39b4ea2f7b0722", "max_stars_repo_licenses": ["MIT"], "max_stars_coun...
#!/usr/bin/env python def configuration(parent_package='',top_path=None): from numpy.distutils.misc_util import Configuration config = Configuration('climlab_rrtmg', parent_package, top_path) config.add_subpackage('rrtmg_sw') config.add_subpackage('rrtmg_lw') config.add_subpackage('tests') #conf...
{"hexsha": "dfc8c8dfdbad8fffce441826ce20de1e987aceb2", "size": 463, "ext": "py", "lang": "Python", "max_stars_repo_path": "climlab_rrtmg/setup.py", "max_stars_repo_name": "brian-rose/climlab-rrtmg", "max_stars_repo_head_hexsha": "070471d2a2a93bf0a8fcb5c5dacb94e5075b79a7", "max_stars_repo_licenses": ["MIT"], "max_stars_...
[STATEMENT] lemma nxt_many_calls[simp]: "nxt (many_calls x) x' = (if x' = x then many_calls x else empty)" [PROOF STATE] proof (prove) goal (1 subgoal): 1. nxt (many_calls x) x' = (if x' = x then many_calls x else TTree.empty) [PROOF STEP] by transfer (force simp add: Cons_replicate_eq)
{"llama_tokens": 122, "file": "Call_Arity_TTree", "length": 1}
#!/usr/bin/env python # -*- coding: utf-8 -*- ############################################################################### # # # RMG - Reaction Mechanism Generator # # ...
{"hexsha": "fc33b286e54d75e19a6525fdf16f71a6a0cb9c3b", "size": 11008, "ext": "py", "lang": "Python", "max_stars_repo_path": "rmgpy/statmech/vibrationTest.py", "max_stars_repo_name": "speth/RMG-Py", "max_stars_repo_head_hexsha": "1d2c2b684580396e984459d9347628a5ceb80e2e", "max_stars_repo_licenses": ["MIT"], "max_stars_c...
import unittest import torch import numpy as np from program_synthesis.naps.examples.seq2seq import pointer_seq2seq from torch.autograd import Variable class TestPointerSeq2Seq(unittest.TestCase): def test_pointer_seq2seq(self): padded_texts = Variable(torch.LongTensor( [[0, 4, 5, 4, 1, -1],...
{"hexsha": "93f0ca6444b5732d6294f2887bdbd72a4f004f0d", "size": 2570, "ext": "py", "lang": "Python", "max_stars_repo_path": "program_synthesis/naps/examples/seq2seq/test_pointer_seq2seq.py", "max_stars_repo_name": "kavigupta/program_synthesis", "max_stars_repo_head_hexsha": "0b04b1d3b63954ba3d404a8d96c4da18667a1b02", "m...
# NLP functions # # this file contains reusable Natural Language Processing functions # the file is separate to prevent unnecessary loading of NLP packages and isolate issues when they occur #from static import PATH_START, PATH_START_PERSONAL #from static import PATH_START_SERVER , PATH_START_PERSONAL_SERVER import p...
{"hexsha": "d2cdeabd5850ed1fda6dec2a973d53ba8edf8515", "size": 39208, "ext": "py", "lang": "Python", "max_stars_repo_path": "nlp_functions.py", "max_stars_repo_name": "Yasin-VU/simple-python-bibliometrics", "max_stars_repo_head_hexsha": "2491043516e7f3ee42a2bc370efedf1a8ceffd6f", "max_stars_repo_licenses": ["BSD-3-Clau...
#Download the DNA features Viewer library #linear view with legend import matplotlib.pyplot as plt from dna_features_viewer import BiopythonTranslator from Bio import SeqIO import numpy as np from dna_features_viewer import BiopythonTranslator import matplotlib.pyplot as plt from dna_features_viewer import BiopythonT...
{"hexsha": "405ad38628e490df8658549d08905649a4bda745", "size": 1873, "ext": "py", "lang": "Python", "max_stars_repo_path": "Archive/LinearView.py", "max_stars_repo_name": "DrValkaryon/BIOT-670-Spring2020-GenBank", "max_stars_repo_head_hexsha": "ab76a30e272f6647128e89657a39037000cd069e", "max_stars_repo_licenses": ["MIT...
import numpy as np import hmc params = hmc.HMCParams( tau = 0.15, tau_g = 0.25, L = 5, eta = 0.00045, mass = 1, r_clip = 5.0, grad_clip = 2.8, )
{"hexsha": "c06bca76979257a06d0ec71ffd5a89f5acf0244c", "size": 174, "ext": "py", "lang": "Python", "max_stars_repo_path": "code/params/hmc_hard-2d.py", "max_stars_repo_name": "oraisa/masters-thesis", "max_stars_repo_head_hexsha": "f859f560b8a8c7b535bd2a70c406f3b571ff6b9c", "max_stars_repo_licenses": ["MIT"], "max_stars...
\section{Ultracold atoms}\label{sec:coldatoms} \subsection{Cooling of atomic gases}\label{sub:cooling} One of the major advances in experimental physics towards creating matter in extreme situations has been the cooling of trapped atoms to temperatures near absolute zero. This feat resulted from the pioneering work of ...
{"hexsha": "d1ca78948b46fac97012642dc6ec42c265c1006b", "size": 24223, "ext": "tex", "lang": "TeX", "max_stars_repo_path": "MainText/ch2_litrev/litrev_coldatoms.tex", "max_stars_repo_name": "mlxd/PhDThesis", "max_stars_repo_head_hexsha": "1b5c6bfd1bfd073b47aa0b1b5abbc7bff5cd521e", "max_stars_repo_licenses": ["MIT"], "ma...
import json import codecs import os, sys import numpy as np import argparse from multiprocessing import cpu_count from concurrent.futures import ProcessPoolExecutor from functools import partial from tqdm import tqdm from local.preprocess.logpowerspec import logpowspec_multichannel import kaldi_io def build_from_p...
{"hexsha": "61071ab80bc2004bb1495876eb20cfa34f6cd145", "size": 3982, "ext": "py", "lang": "Python", "max_stars_repo_path": "i-vector-lpms/extract_lps.py", "max_stars_repo_name": "dendisuhubdy/adversarial-attack-on-GMM-i-vector-based-speaker-verification-systems", "max_stars_repo_head_hexsha": "0aa9c0fc9bb224acc508d07cf...
using Oceananigans.Advection using Oceananigans.Coriolis using Oceananigans.Operators """ Compute the tendency for the x-directional transport, uh """ @inline function uh_solution_tendency(i, j, k, grid, advection, coriolis, ...
{"hexsha": "debd6eac13c03088fc128068783eccaa0ad6f81a", "size": 2277, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "src/Models/ShallowWaterModels/solution_and_tracer_tendencies.jl", "max_stars_repo_name": "ssghost/Oceananigans.jl", "max_stars_repo_head_hexsha": "a8ea2555c36bdc7a29161d6cb692d8bdf6290156", "max_st...
from genetic_tree import GeneticTree from tree.tree import Tree import numpy as np from timeit import timeit from functools import partial import multiprocessing from enum import Enum class ThreadType(Enum): multiprocessing = 1, nogil = 2, nogil_multi = 3, single = 4, multiprocessing_with_less_th...
{"hexsha": "6cf56f05ad96cd90f0c3f1082321a7dbcbf7cd19", "size": 2465, "ext": "py", "lang": "Python", "max_stars_repo_path": "tests/multithreading.py", "max_stars_repo_name": "MakowToms/GeneticTree", "max_stars_repo_head_hexsha": "c39288c7689a41e169bb876b1ee0aa7fac43d8ec", "max_stars_repo_licenses": ["MIT"], "max_stars_c...
// Copyright (c) Jeremy Siek 2001, Marc Wintermantel 2002 // // Permission to use, copy, modify, distribute and sell this software // and its documentation for any purpose is hereby granted without fee, // provided that the above copyright notice appears in all copies and // that both that copyright notice and thi...
{"hexsha": "4dd257797ba4b29150d09dc10d6f189f0d901d5d", "size": 2988, "ext": "hpp", "lang": "C++", "max_stars_repo_path": "sdk/boost_1_30_0/boost/graph/bandwidth.hpp", "max_stars_repo_name": "acidicMercury8/xray-1.0", "max_stars_repo_head_hexsha": "65e85c0e31e82d612c793d980dc4b73fa186c76c", "max_stars_repo_licenses": ["...
import numpy as np def foo(i): x = np.random.permutation(1000000) x.sort() print 'RUNED JOB! ', i
{"hexsha": "f0d094c4a1ab84c7ada1cdac94e33bbe3c8ff79b", "size": 109, "ext": "py", "lang": "Python", "max_stars_repo_path": "vislab/tests/testrqaux.py", "max_stars_repo_name": "asanakoy/vislab", "max_stars_repo_head_hexsha": "052a80718d688246db9ba561199f728e138a8c12", "max_stars_repo_licenses": ["BSD-2-Clause"], "max_sta...
#! /usr/bin/env python ''' concat_audio.py Author: Scott Hawley Joins a bunch of audio files into one big file. Filename of output is whatever the last filename is + "_Long" Works on mono, stereo,...arbitrary numbers of channels ''' from __future__ import print_function import numpy as np import librosa import os ...
{"hexsha": "65d600ffae01e81cfb10c07b614d9a85da5a6273", "size": 1409, "ext": "py", "lang": "Python", "max_stars_repo_path": "utils/concat_audio.py", "max_stars_repo_name": "jdormuth1/panotti", "max_stars_repo_head_hexsha": "ef167e99eb99105419b3b40a853c6b3f0b41ca49", "max_stars_repo_licenses": ["MIT"], "max_stars_count":...
import onnx from onnx import helper from onnx import numpy_helper from onnx import AttributeProto, TensorProto, GraphProto import numpy as np from Compare_output import compare # Create one Input (ValueInfoProto) X1 = helper.make_tensor_value_info('X1', TensorProto.FLOAT, [3, 4, 5]) X2 = helper.make_tensor_value_info(...
{"hexsha": "fec628ed5df36f48917dd2b5bd87500745c2ad48", "size": 2020, "ext": "py", "lang": "Python", "max_stars_repo_path": "operators/Add.py", "max_stars_repo_name": "MaajidKhan/ONNX-1.6.0-OP-Library", "max_stars_repo_head_hexsha": "df26621fa225485849853f5e11180600be71d11d", "max_stars_repo_licenses": ["MIT"], "max_sta...
import pandas as pd import numpy as np import os import glob def get_csv_files_list(csv_dir): """Return a list containing all found csv files within a given directory.""" return glob.glob(f"{csv_dir}/*.csv") def load_single_csv_file_as_df(csv_file): """Returns the contents of a csv file as a DataFrame."...
{"hexsha": "7594e2056acad4751b1ce35069cfbbc77c7a0521", "size": 366, "ext": "py", "lang": "Python", "max_stars_repo_path": "azimuthal_average/data_loading.py", "max_stars_repo_name": "ric-95/azimuthal-average", "max_stars_repo_head_hexsha": "a955ff4c6904c8f15d062d08cd83b59655f64db0", "max_stars_repo_licenses": ["MIT"], ...
#!/usr/bin/env python # -*- coding: utf-8 -*- # # Copyright 2020 DSPIRA. # # This is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3, or (at your option) # any later version. # # This software is...
{"hexsha": "7ecb30faaaccbfca0b971d7bc84f4035c258e4c8", "size": 5451, "ext": "py", "lang": "Python", "max_stars_repo_path": "radio_astro/python/csv_filesink.py", "max_stars_repo_name": "interstellarmedium/HI_telescope", "max_stars_repo_head_hexsha": "728b6427dea3b472d9669c39f202f740b91edf6a", "max_stars_repo_licenses": ...
import tensorflow as tf import numpy as np import json import six import tensorflow as tf try: import bert_utils except: from . import bert_utils class BertConfig(object): """Configuration for `BertModel`.""" def __init__(self, vocab_size=None, emb_size=None, cnn_num_layers=None, cnn_dilation_...
{"hexsha": "477c2a9ee44af180bbbb4e9a58cc8a8d1f05a82e", "size": 14401, "ext": "py", "lang": "Python", "max_stars_repo_path": "PyCLUE/utils/classifier_utils/lightdgcnn_modeling.py", "max_stars_repo_name": "yyht/PyCLUE_albert", "max_stars_repo_head_hexsha": "71143d797e967a4215f3a8c1664b56369da4e58e", "max_stars_repo_licen...
= BRIX11 generate idl command == Collection taox11 == Usage brix11 generate idl [options] [NAME] === options NAME := name to use for IDL file; default 'test' -i, --interface=NAME Defines name to use for interface. Use scoped name (i.e. <name>::[<name>::]::<na...
{"hexsha": "cf45ccef7242d7cedb9178466d3b5a2b4cb8bf64", "size": 1888, "ext": "rd", "lang": "R", "max_stars_repo_path": "brix/taox11/docs/generate_idl.rd", "max_stars_repo_name": "ClausKlein/taox11", "max_stars_repo_head_hexsha": "669cfd2d0be258722c7ee32b23f2e5cb83e4520f", "max_stars_repo_licenses": ["MIT"], "max_stars_c...
data_spec = [ (:name, AbstractString, "table"), (:format, VegaFormat, nothing), (:values, Union{Vector{Dict{Any, Any}}, Vector}, nothing), (:source, AbstractString, nothing), (:url, AbstractString, nothing), (:transform, Vector{VegaTransform}, nothing), (:modify, Vector{VegaStream}, nothing) ] primitivefactory...
{"hexsha": "89c83c70dbe4f93c08e3516beee84c0e2830b79b", "size": 343, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "src/primitives/data.jl", "max_stars_repo_name": "jpthor/vega", "max_stars_repo_head_hexsha": "c7052baf130ae31f69691d24f00a9151aceef630", "max_stars_repo_licenses": ["MIT"], "max_stars_count": 1, "ma...
# Copyright (c) Microsoft. All rights reserved. # Licensed under the MIT license. See LICENSE.md file in the project root # for full license information. # ============================================================================== from .. import cntk_py from ..tensor import ArrayMixin from ..utils import typemap...
{"hexsha": "fbff145ea64cecf62342886ff432f966953dc01d", "size": 25048, "ext": "py", "lang": "Python", "max_stars_repo_path": "bindings/python/cntk/io/__init__.py", "max_stars_repo_name": "digimatronics/MS_Deep_Learning_Cognitive", "max_stars_repo_head_hexsha": "4a6e8488fb5f3111151431289bbb72707f8c9c13", "max_stars_repo_...
!> the problem is to determine the values of x(1), x(2), ..., x(9), !> which solve the system of tridiagonal equations. !> !> (3-2*x(1))*x(1) -2*x(2) = -1 !> -x(i-1) + (3-2*x(i))*x(i) -2*x(i+1) = -1, i=2-8 !> -x(8) + (3-2*x(9))*x(9) = -1 progra...
{"hexsha": "bd5beb4e32b568e7c5fef82700d7c2f606927b4a", "size": 2431, "ext": "f90", "lang": "FORTRAN", "max_stars_repo_path": "examples/example_hybrd1.f90", "max_stars_repo_name": "awvwgk/minpack", "max_stars_repo_head_hexsha": "dc14d611af8d9c16d08039d6e5a6d45b766b8022", "max_stars_repo_licenses": ["MIT"], "max_stars_co...
#!/usr/bin/env python # -*- coding: utf-8 -*- import pygimli as g from pygimli.viewer import showMesh import pylab as P import numpy as np def testCreateTriPrismMesh(): poly = g.Mesh( 2 ) n0 = poly.createNode( 0.0, 0.0, 0. ) n1 = poly.createNode( 1.0, 0.0, 0. ) n2 = poly.createNode( 0.0, 1.0, 0. ) ...
{"hexsha": "c0d7b2e387046cce6013dd496befe9d610b08229", "size": 2643, "ext": "py", "lang": "Python", "max_stars_repo_path": "tests/basics/testTriPrism.py", "max_stars_repo_name": "mjziebarth/gimli", "max_stars_repo_head_hexsha": "196ac4d6dd67e0326cccc44a87b367f64051e490", "max_stars_repo_licenses": ["Apache-2.0"], "max_...
# Copyright (c) 2020, Huawei Technologies.All rights reserved. # # Licensed under the BSD 3-Clause License (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://opensource.org/licenses/BSD-3-Clause # # Unless required by applicable law...
{"hexsha": "6eb03210b6689527445364d7760b003fcf65206c", "size": 3735, "ext": "py", "lang": "Python", "max_stars_repo_path": "test/test_npu/test_log2.py", "max_stars_repo_name": "Ascend/pytorch", "max_stars_repo_head_hexsha": "39849cf72dafe8d2fb68bd1679d8fd54ad60fcfc", "max_stars_repo_licenses": ["BSD-3-Clause"], "max_st...
#!/usr/bin/env python3 # coding: utf-8 import SimpleITK as sitk import numpy as np import copy import glob import pandas import datetime path="/home/alicja/" def obtainDCEimages(pat_no="04",timept="1",path=path): folder="PET_LAB_PROCESSED/WES_0"+pat_no+"/IMAGES/" baseline_image=sitk.ReadImage(path+folder+"WE...
{"hexsha": "c06a1364d15bd0cacc6cf2bcd282bb970544e694", "size": 5051, "ext": "py", "lang": "Python", "max_stars_repo_path": "DCE images/MPE and TTP generation.py", "max_stars_repo_name": "akac0297/PETLAB", "max_stars_repo_head_hexsha": "950cc153ce230d12d752ad0d11111e7fc22d9e7d", "max_stars_repo_licenses": ["MIT"], "max_...
import os os.environ["CUDA_VISIBLE_DEVICES"]="0" import socket import sys import tensorflow as tf import numpy as np from data_loaders.zhangfeats_loader import zhangfeats_loader from arch.layer_factory import layer_factory flags = tf.flags #MDN Params flags.DEFINE_integer("feats_height", 28, "") flags.DEFINE_integ...
{"hexsha": "5d777485d8d0f84395520ff69ff8b37d4d9ec52e", "size": 7969, "ext": "py", "lang": "Python", "max_stars_repo_path": "mdn/save_mdn_gmm.py", "max_stars_repo_name": "aditya12agd5/divcolor", "max_stars_repo_head_hexsha": "570155a062bcb6428353ec0e80343badbc290caf", "max_stars_repo_licenses": ["Apache-2.0"], "max_star...
''' ===================================== Author : Muhan Zhao Date : Feb. 11, 2020 Location: UC San Diego, La Jolla, CA ===================================== ''' import sympy as sp from sympy.utilities.lambdify import lambdify import numpy as np class ControlAffineSystem: ''' This class defines the dy...
{"hexsha": "0cfc79e06c7411b335b122d0ee20721891a035ec", "size": 5212, "ext": "py", "lang": "Python", "max_stars_repo_path": "define_system.py", "max_stars_repo_name": "kimukook/CLF-CBF-python", "max_stars_repo_head_hexsha": "28a46a4f9abf095e1f1b92e6cc056956caab5374", "max_stars_repo_licenses": ["MIT"], "max_stars_count"...
import numpy as np import pytest from packaging import version import qcodes as qc from qcodes import load_or_create_experiment, initialise_or_create_database_at from plottr.data.datadict import DataDict from plottr.utils import testdata from plottr.node.tools import linearFlowchart from plottr.data.qcodes_dataset im...
{"hexsha": "18e6c3bae40372c5957820f40b3903129f5c697f", "size": 10044, "ext": "py", "lang": "Python", "max_stars_repo_path": "test/pytest/test_qcodes_data.py", "max_stars_repo_name": "MdKquantum/plottr_linecuts", "max_stars_repo_head_hexsha": "f322e777a7e71ca900229ef555306b7a5cd080f7", "max_stars_repo_licenses": ["MIT"]...
# -*- coding: utf-8 -*- """ Created on Fri Jun 8 14:52:57 2018 @author: anish """ import numpy as np import csv import matplotlib.pyplot as plt def sigmoid(z): s=1/(1+np.exp(-z)) return s def loaddata(): with open("set.csv",newline='') as csvfile: lines=csv.reader(csvfile,delimiter=",",quoting=...
{"hexsha": "a589583ca6418a6a82eb2bf5c0dfffa1c12fb789", "size": 4611, "ext": "py", "lang": "Python", "max_stars_repo_path": "NN2.py", "max_stars_repo_name": "nitrawf/Shallow-Neural-Network", "max_stars_repo_head_hexsha": "01fac602b4a7311783846161bdc4ada73cf5e980", "max_stars_repo_licenses": ["MIT"], "max_stars_count": n...
import time import os from cv2 import cv2 import numpy as np import pyautogui import pynput class UserInputListener: def start_listening(self): """ listen keyboard input """ listener = pynput.keyboard.Listener(on_press=self.check_input) listener.start() @staticmethod ...
{"hexsha": "4f370b52d0dfb135eeee4609aaa905525692a960", "size": 2633, "ext": "py", "lang": "Python", "max_stars_repo_path": "main.py", "max_stars_repo_name": "DogsonPl/online-piano-tiles-bot", "max_stars_repo_head_hexsha": "b8449ca6caa0ec54ce4e3cb6b0b3e5d289787add", "max_stars_repo_licenses": ["MIT"], "max_stars_count":...
# -*- coding: utf-8 -*- from __future__ import division from __future__ import absolute_import import os import numpy as np import scipy.interpolate as si from ..api.channel import DecayChannel _srcdir = os.path.dirname(__file__) # Load the table containing the normalized S -> π π decay width. # Source: # ...
{"hexsha": "f23bdc124371c41b4c2440d05988388ca1e504d1", "size": 2410, "ext": "py", "lang": "Python", "max_stars_repo_path": "decay/two_pions.py", "max_stars_repo_name": "JLTastet/scalar_portal", "max_stars_repo_head_hexsha": "8d444d72e4c5d31b237a59621935757790c5a0e7", "max_stars_repo_licenses": ["MIT"], "max_stars_count...
# Decision Lens API # # No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) # # OpenAPI spec version: 1.0 # # Generated by: https://github.com/swagger-api/swagger-codegen.git #' ProjectPortfolioPlanDeletedEvent Class #' #' @field id #' @field name #' @field portfol...
{"hexsha": "79ed2dd13ac3491c5827e0f4024267e0e667261d", "size": 3733, "ext": "r", "lang": "R", "max_stars_repo_path": "R/R/ProjectPortfolioPlanDeletedEvent.r", "max_stars_repo_name": "dlens/dlxapi", "max_stars_repo_head_hexsha": "189a6519240ce625d7a9cdb89e305a335d2aa045", "max_stars_repo_licenses": ["MIT"], "max_stars_c...
#!/usr/bin/env python3 """Calculates flow velocities through a valley glacier cross-section. Description: This script calculates and plots the solution for dimensional velocity as a function of dimensional distance from the base of a valley glacier. It also loads and plots observed flow velocities from a f...
{"hexsha": "83c34331e066a0baa5befe1f2b45fa23c298501d", "size": 1953, "ext": "py", "lang": "Python", "max_stars_repo_path": "atha_glacier_prob2.py", "max_stars_repo_name": "IntroQG-2017/Exercise-12", "max_stars_repo_head_hexsha": "cc7add4c73a01a650d3b533cce300b4f9b10e528", "max_stars_repo_licenses": ["MIT"], "max_stars_...
import numpy as np import nibabel as nib import pandas as pd from glob import glob import os, sys currentdir = os.path.dirname(os.path.realpath(__file__)) parentdir = os.path.dirname(currentdir) sys.path.append(parentdir) import settings as s source_dir=s.projectfolder+'7NETS_vertex/4_estimatedModels' #entagled #sour...
{"hexsha": "7b0e6afd8bb7c1b92eb9929ff584e2171da8f273", "size": 1089, "ext": "py", "lang": "Python", "max_stars_repo_path": "Code/Models/find_nonzero_status.py", "max_stars_repo_name": "cirmuw/functional-twin-analysis", "max_stars_repo_head_hexsha": "b6730f09f2143d5372f1a90d5fac47e3385e54fb", "max_stars_repo_licenses": ...
subroutine hgstfb (hgs,s) c implicit double precision (a-h,o-z) dp use mod_parameters common/range/mft,mlt,lft,llt,nftm1 common/vect13/ 1 x1112(nelemg),x1314(nelemg),x1114(nelemg),x1213(nelemg), 2 x2122(nelemg),x2324(nelemg),x2124(nelemg),x2223(n...
{"hexsha": "e00c4d81d4107dd925e2bbc6f3032f09a820fa8c", "size": 1783, "ext": "f", "lang": "FORTRAN", "max_stars_repo_path": "src/hgstfb.f", "max_stars_repo_name": "imohame/LabCode", "max_stars_repo_head_hexsha": "b7fca6e58f6c26917ff4a8862ab473da282d027d", "max_stars_repo_licenses": ["MIT"], "max_stars_count": null, "max...
#include "ros/ros.h" #include <rlss_ros/OccupancyGrid.h> #include <rlss/OccupancyGrid.hpp> #include <fstream> #include <boost/filesystem/operations.hpp> #include <boost/filesystem.hpp> namespace fs = boost::filesystem; constexpr unsigned int DIM = DIMENSION; using OccupancyGrid = rlss::OccupancyGrid<double, DIM>; usi...
{"hexsha": "d92142842be0f7289631045893d93b57caa61cd8", "size": 3129, "ext": "cpp", "lang": "C++", "max_stars_repo_path": "src/static_occupancy_grid_feeder.cpp", "max_stars_repo_name": "sieniven/rlss_ros", "max_stars_repo_head_hexsha": "a505b39f7080a0665211e76a5030aa700b3cce12", "max_stars_repo_licenses": ["MIT"], "max_...
import datetime import numpy as np from vessel_drift_analysis.ais import AIS, AISSet AIS_PATH = '/mnt/store/data/assets/nps-vessel-spills/ais-data/ais-data-2010-2013/processed/rescaled_25km_sum/wgs84/total/' # noqa AIS_FILE = '/mnt/store/data/assets/nps-vessel-spills/ais-data/ais-data-2010-2013/processed/rescaled_2...
{"hexsha": "2157cc8a7cacd2076cec1da46d64a9ba051f6429", "size": 1762, "ext": "py", "lang": "Python", "max_stars_repo_path": "src/vessel-drift-analysis/tests/test_ais.py", "max_stars_repo_name": "yosoyjay/project-nps-vessel-drift", "max_stars_repo_head_hexsha": "1cdc14ef87db31fa03b0c3bdc1d60c332727ef57", "max_stars_repo_...
export TimeSeries export hourly_to_monthly export monthly_to_hourly """ TimeSeries """ mutable struct TimeSeries{T <: Real} name::String timestamps::Vector{DateTime} vals::Vector{T} function TimeSeries(name::String, timestamps::Vector{DateTime}, vals...
{"hexsha": "ce7b89b4187d4c9f7a62fd0efde2737407feaca0", "size": 7355, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "src/timeseries.jl", "max_stars_repo_name": "LAMPSPUC/TimeSeriesInterface.jl", "max_stars_repo_head_hexsha": "c9ca9e385db11d90595715101228e281fdb3bdd1", "max_stars_repo_licenses": ["MIT"], "max_star...
""" Tests for functions in the base tables file. """ import os from unittest import TestCase, mock import numpy as np from fitbenchmarking.cost_func.weighted_nlls_cost_func import \ WeightedNLLSCostFunc from fitbenchmarking.jacobian.default_jacobian import \ Default as DefaultJacobian from fitbenchmarking.ja...
{"hexsha": "d2a03a862b379c9dbffbb1461eaad2db6cae5e7c", "size": 11058, "ext": "py", "lang": "Python", "max_stars_repo_path": "fitbenchmarking/results_processing/tests/test_base_table.py", "max_stars_repo_name": "fitbenchmarking/fitbenchmarking", "max_stars_repo_head_hexsha": "ea398efa61f071dc64fe7c3b484d5bb4e1897856", "...
from tkinter import * from scipy.io import wavfile from matplotlib import pyplot as plt from tkinter import filedialog import tkinter.messagebox import os import wave import numpy as np import _thread import time import visualization.dcb as dcb import ffmpeg from pydub import AudioSegment import jointly.DCHMM from cor...
{"hexsha": "0c98fb95caf1173206b3fe67b235450edea909a0", "size": 11849, "ext": "py", "lang": "Python", "max_stars_repo_path": "visualization/voicev.py", "max_stars_repo_name": "sailist/ASRFrame", "max_stars_repo_head_hexsha": "2fd022c3c00af1d5178dee4b367b2269241bc73c", "max_stars_repo_licenses": ["Apache-2.0"], "max_star...
[STATEMENT] lemma supp_PTuple [simp]: "((supp \<langle>\<langle>p, q\<rangle>\<rangle>)::name set) = supp p \<union> supp q" [PROOF STATE] proof (prove) goal (1 subgoal): 1. supp \<langle>\<langle>p, q\<rangle>\<rangle> = supp p \<union> supp q [PROOF STEP] by (simp add: supp_def Collect_disj_eq del: disj_not1)
{"llama_tokens": 120, "file": null, "length": 1}
module MocosSimLauncher using ArgParse using Base.Threads using DataFrames using FileIO using JLD2 using JSON using ProgressMeter using Random import MocosSim import MocosSim: ContactKind, NoContact, contactkind, time const OptTimePoint = Union{Missing, MocosSim.TimePoint} optreal2float32(optreal::Union{Missing,T} w...
{"hexsha": "2f9f290b4d18e8bbfae47b1ddda80d9a244a3578", "size": 2382, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "src/MocosSimLauncher.jl", "max_stars_repo_name": "Novirmor/MocosSimLauncher", "max_stars_repo_head_hexsha": "de402e075f59759c8702d5f548afdeebe650dafa", "max_stars_repo_licenses": ["MIT"], "max_star...
import tensorflow as tf from captcha import inference from PIL import Image import numpy as np IMG_HEIGHT = 60 IMG_WIDTH = 140 INPUT_NODE = IMG_HEIGHT * IMG_WIDTH MODEL_PATH_NAME = 'model/model.ckpt' CAPTCHA_CHARS = ['a', 'b', 'c', 'd', 'e', 'f', 'g', 'k', 'm', 'n', 'p', 'q', 's', 'u', 'w', 'x', 'y', ...
{"hexsha": "21b1d6d7481f5d290792a7dde8b2af32b803a6f2", "size": 3201, "ext": "py", "lang": "Python", "max_stars_repo_path": "captcha/killer.py", "max_stars_repo_name": "ZSAIm/TakeTheCourse_GDUT", "max_stars_repo_head_hexsha": "bfca8210f9b613acccba607a55ca5fa015a24dd1", "max_stars_repo_licenses": ["Apache-2.0"], "max_sta...
import matplotlib.pyplot as plt import numpy as np np.random.seed(123) def bar_and_data_plot(x, y, output_path, tick_labels, bar_width=0.5, bar_colors=['#FC8D62','#65C2A5'], edge_colors=None): fig, ax = plt.subplots() ax.bar(x, height=[np.mean(yi) for yi in y], yerr=[np.std(yi) for yi in...
{"hexsha": "c1abd346f2535ea02faafc472c6ef9fcee42d65f", "size": 847, "ext": "py", "lang": "Python", "max_stars_repo_path": "plots/bar_and_datapoints_plot.py", "max_stars_repo_name": "TheRincon/gallimaufry", "max_stars_repo_head_hexsha": "dc25519f04db69b6c28130f85397c621cfde9521", "max_stars_repo_licenses": ["CC-BY-2.0"]...
/********************************************************************* * Software License Agreement (BSD License) * * Copyright (c) 2011, Rice University * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following con...
{"hexsha": "3e63b4ae9e00960793779ca31048ae96ef3a1904", "size": 28280, "ext": "cpp", "lang": "C++", "max_stars_repo_path": "src/ompl/geometric/planners/prm/src/PRM.cpp", "max_stars_repo_name": "ericpairet/ompl", "max_stars_repo_head_hexsha": "25c76431cef25f0100ed74d09dd88944ecca5ee1", "max_stars_repo_licenses": ["BSD-3-...
#include "OutputManager.hpp" #include "ParamResponsePair.hpp" #include "SimulationResponse.hpp" #ifdef _WIN32 #include "dakota_windows.h" #endif #include <Teuchos_UnitTestHarness.hpp> #include <boost/filesystem/operations.hpp> #include <cmath> #ifndef M_PI #define M_PI 3.14159265358979323846 #endif #ifndef M_LOG2E ...
{"hexsha": "9b7a35c2be95500487b08bb58b3c414aa0d65b6e", "size": 5388, "ext": "cpp", "lang": "C++", "max_stars_repo_path": "src/unit_test/restart_test.cpp", "max_stars_repo_name": "jnnccc/Dakota-orb", "max_stars_repo_head_hexsha": "96488e723be9c67f0f85be8162b7af52c312b770", "max_stars_repo_licenses": ["MIT"], "max_stars_...
import cv2 import numpy as np import uno_contrl import time import threading from threading import Timer thread_lock = threading.Lock() cap = cv2.VideoCapture(0) kernel = np.ones((3, 3), dtype=np.uint8) class revised_route_thread(threading.Thread): def __init__(self, start, end,reverse): threading.Threa...
{"hexsha": "39deac43eae7e4f159f80471c46db358501174cc", "size": 8136, "ext": "py", "lang": "Python", "max_stars_repo_path": "code/Vision_threshold.py", "max_stars_repo_name": "YanggeLiu/pytruck", "max_stars_repo_head_hexsha": "b33d6d7c880b04d6aa1a99837f8e5f278b5301d9", "max_stars_repo_licenses": ["MIT"], "max_stars_coun...
"mask with all false columns should produce an error" let mask = transpose([false false false; true false true; false true false]) @test_throws ErrorException MDPs.Examples.random(size(mask, 1), 2, mask) end "mask sizes that do not match the states and actions arguments should throw error" let mask = tran...
{"hexsha": "31385c89a76f01b98fab5b380bbd3ecd3f60a243", "size": 2067, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "test/random.jl", "max_stars_repo_name": "UnofficialJuliaMirror/MDPs.jl-1407db8f-3b7b-5b59-abc8-36200bfa8e15", "max_stars_repo_head_hexsha": "c920600acb966b76acce76370a627d5179f4caf1", "max_stars_re...
from django.shortcuts import render,redirect from django.core.files.storage import FileSystemStorage import PIL from PIL import Image import os from .models import Document from django.conf import settings from django.contrib.auth.models import User from allauth.account.decorators import login_required,verified_email_r...
{"hexsha": "c12b9865a979141c640a0086f90da21cf793b3e2", "size": 2363, "ext": "py", "lang": "Python", "max_stars_repo_path": "tooth_fracture_generator/views.py", "max_stars_repo_name": "The-ML-Hero/HealthCare-Dental-AI-Toolkit", "max_stars_repo_head_hexsha": "b790a94306769baeed25dec6863d987408d2815c", "max_stars_repo_lic...
""" Diagnostic Maps. Diagnostic to produce images of a map with coastlines from a cube. These plost show latitude vs longitude and the cube value is used as the colour scale. Note that this diagnostic assumes that the preprocessors do the bulk of the hard work, and that the cube received by this diagnostic (via the s...
{"hexsha": "9662b929f687f27a68957c4d42b4aac7b6cc9f4e", "size": 17241, "ext": "py", "lang": "Python", "max_stars_repo_path": "esmvaltool/diag_scripts/ocean/diagnostic_seaice.py", "max_stars_repo_name": "RCHG/ESMValTool", "max_stars_repo_head_hexsha": "c6458c72777f22b52b2dcde73749a47e407b77f0", "max_stars_repo_licenses":...
open import Prelude open import core module grounding where grounding : ∀{ τ1 τ2} → τ1 ▸gnd τ2 → ((τ2 ground) × (τ1 ~ τ2) × (τ1 ≠ τ2)) grounding (MGArr x) = GHole , TCArr TCHole1 TCHole1 , x
{"hexsha": "67b06979db80cc8a144c6616a6e7d1451284ec5e", "size": 254, "ext": "agda", "lang": "Agda", "max_stars_repo_path": "grounding.agda", "max_stars_repo_name": "hazelgrove/hazelnut-dynamics-agda", "max_stars_repo_head_hexsha": "229dfb06ea51ebe91cb3b1c973c2f2792e66797c", "max_stars_repo_licenses": ["MIT"], "max_stars...
\documentclass[10pt,letterpaper]{article} \usepackage[default]{sourcecodepro} % Set default font to Source Code Pro. \usepackage[T1]{fontenc} % Set font encoding to T1. \usepackage[utf8]{inputenc} % Set input encoding to UTF-8. \usepackage[english]{babel} % This document is in English. \usepackage[yyyymmdd]{d...
{"hexsha": "4edf3dd4beebc3bba4c94064656be116a7f94975", "size": 5863, "ext": "tex", "lang": "TeX", "max_stars_repo_path": "resume.tex", "max_stars_repo_name": "jrouly/resume", "max_stars_repo_head_hexsha": "a30921498c42d7135a0255c0dafd41d320e54244", "max_stars_repo_licenses": ["WTFPL"], "max_stars_count": 1, "max_stars_...
\chapter{Diseño e Implementación} % Main chapter title \label{Chapter3} % Change X to a consecutive number; for referencing this chapter elsewhere, use \ref{ChapterX} \definecolor{mygreen}{rgb}{0,0.6,0} \definecolor{mygray}{rgb}{0.5,0.5,0.5} \definecolor{mymauve}{rgb}{0.58,0,0.82} \lstset{ % backgroundcolor=\color{...
{"hexsha": "49b85b23852d21084371ca95c8f63e261fbfe569", "size": 3853, "ext": "tex", "lang": "TeX", "max_stars_repo_path": "Chapters/Chapter3.tex", "max_stars_repo_name": "alesuarez/MSE", "max_stars_repo_head_hexsha": "7e0d8bd53483805b06217a8f37b1d3134308e9e2", "max_stars_repo_licenses": ["BSD-3-Clause"], "max_stars_coun...
\subsection{Model Configuration} Diskmodel uses libparam to input the following blocks of parameter data: \begin{verbatim} dm_disk dm_layout_g1 dm_layout_g1_zone dm_mech_g1 dm_layout_g2 dm_layout_g2_zone dm_layout_g4 \end{verbatim} \subsubsection{dm\_disk} The outer \texttt{dm\_disk} block contains the top-level pa...
{"hexsha": "7d1616a1875415525aa978af7bca2e14c95400e6", "size": 3580, "ext": "tex", "lang": "TeX", "max_stars_repo_path": "src/disksim/diskmodel/doc/dm_param.tex", "max_stars_repo_name": "paolofrb/cotson", "max_stars_repo_head_hexsha": "1289b58ecc5d8279bc1124495ca0042f9586af11", "max_stars_repo_licenses": ["MIT"], "max_...
import cv2 import numpy as np from geosolver.diagram.computational_geometry import cartesian_angle, line_length from geosolver.ontology.instantiator_definitions import instantiators from geosolver.utils.num import round_vector __author__ = 'minjoon' def draw_instance(image, instance, **kwargs): for key, instant...
{"hexsha": "5ad7d62abbfc309f35985d1d2d0e675750af9697", "size": 2926, "ext": "py", "lang": "Python", "max_stars_repo_path": "diagram_parser/parser/geosolver/diagram/draw_on_image.py", "max_stars_repo_name": "lupantech/InterGPS", "max_stars_repo_head_hexsha": "0f326027d16d7d50a9c189f897739dfb95085021", "max_stars_repo_li...
program t print '(f4.1)',3.14e1 end program t
{"hexsha": "8fe84af1cdb4395253a60cba9589e61af70c9b00", "size": 64, "ext": "f", "lang": "FORTRAN", "max_stars_repo_path": "tests/t0032x/t.f", "max_stars_repo_name": "maddenp/ppp", "max_stars_repo_head_hexsha": "81956c0fc66ff742531817ac9028c4df940cc13e", "max_stars_repo_licenses": ["Apache-2.0"], "max_stars_count": 2, "m...
#ifndef _RandomHistObject_H #define _RandomHistObject_H #include <gsl/gsl_histogram.h> #include <QObject> #include <QVector> #include "src_config.h" class RandomNumberGen; class _HIST_EXPORT_ RandomHistObject : public QObject { public: static RandomHistObject * getRandomHistObject (QObject * parent=0); void ...
{"hexsha": "3d64ddfaa7da5fb00ddc5e5ce1415530ff912962", "size": 1012, "ext": "h", "lang": "C", "max_stars_repo_path": "src/gui/RandomHistObj.h", "max_stars_repo_name": "YuriyRusinov/Histogram", "max_stars_repo_head_hexsha": "76aff0621acf6d43449cabd5c54c950c77ba7c2c", "max_stars_repo_licenses": ["0BSD"], "max_stars_count...
import os import time import scipy.io import json import warnings warnings.filterwarnings("ignore") from utils import * from MeshPly import MeshPly # Create new directory def makedirs(path): if not os.path.exists( path ): os.makedirs( path ) def find_betapose_entry(betas, image_id): f...
{"hexsha": "7c768b3d625682907fe0cd1b638f836283c45c81", "size": 7521, "ext": "py", "lang": "Python", "max_stars_repo_path": "tools/evaluators/betapose/validateBetapose.py", "max_stars_repo_name": "lee4138/6d-pose-estimation-with-ml-in-ar", "max_stars_repo_head_hexsha": "e29162c82c867d4a8177322d7d49a55c5fd90639", "max_st...
### A Pluto.jl notebook ### # v0.14.4 using Markdown using InteractiveUtils # This Pluto notebook uses @bind for interactivity. When running this notebook outside of Pluto, the following 'mock version' of @bind gives bound variables a default value (instead of an error). macro bind(def, element) quote loc...
{"hexsha": "0c5f7360e458413e0a66974d1e6e5785adf393f5", "size": 11422, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "sample/test_embed_display.jl", "max_stars_repo_name": "Mechachleopteryx/Pluto.jl", "max_stars_repo_head_hexsha": "78fbd9f00a3323208a6df9a4ff0ecbdcf2d9845a", "max_stars_repo_licenses": ["MIT"], "ma...
import torch import pygsp import numpy as np from torch.nn import Conv1d from torch.nn import functional as F from torch.nn import BatchNorm1d, Conv1d, Identity from modules import layers from modules.layers import ConvCheb, PoolMaxHealpix, UnpoolMaxHealpix def _compute_laplacian_healpix(nodes, laplacian_type="no...
{"hexsha": "540484e56878e31670363ac1740b12cb3e1ffa21", "size": 52969, "ext": "py", "lang": "Python", "max_stars_repo_path": "modules/architectures.py", "max_stars_repo_name": "natbolon/weather_prediction", "max_stars_repo_head_hexsha": "f3a18264e5e642cf366e7d181e6e081ab7f21eab", "max_stars_repo_licenses": ["MIT"], "max...
// // Copyright (c) 2010 Dariusz Gadomski <dgadomski@gmail.com> // All rights reserved. // // Redistribution and use in source and binary forms, with or without modification, // are permitted provided that the following conditions are met: // // * Redistributions of source code must retain the above copyright notice, ...
{"hexsha": "54f029fab89737d16d3d6726beb1053a973392b6", "size": 6348, "ext": "cpp", "lang": "C++", "max_stars_repo_path": "client/src/main.cpp", "max_stars_repo_name": "dargad/network-traffic-prediction", "max_stars_repo_head_hexsha": "a7b503acd70a444ad0e4fd34572e6479b75a9b6a", "max_stars_repo_licenses": ["BSD-3-Clause"...