text
stringlengths
0
1.25M
meta
stringlengths
47
1.89k
// // $Id$ // // ------------------------------------------------------------------------- // This file is part of ZeroBugs, Copyright (c) 2010 Cristian L. Vlasceanu // // 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....
{"hexsha": "a6f784204472b8f0d2335fa1a5d03844eec19d0a", "size": 22981, "ext": "cpp", "lang": "C++", "max_stars_repo_path": "plugin/gui/variables_view.cpp", "max_stars_repo_name": "cristivlas/zerobugs", "max_stars_repo_head_hexsha": "5f080c8645b123d7887fd8a64f60e8d226e3b1d5", "max_stars_repo_licenses": ["BSL-1.0"], "max_...
/* Copyright 2007-2008 Christian Henning, Andreas Pokorny, Lubomir Bourdev Use, modification and distribution are subject to 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). */ /********************************************...
{"hexsha": "0dc0155515f0d9c97947458e145bcee56a09264e", "size": 17003, "ext": "hpp", "lang": "C++", "max_stars_repo_path": "extern/boost/gil/extension/io_new/formats/png/write.hpp", "max_stars_repo_name": "qc2105/librjmcmc", "max_stars_repo_head_hexsha": "6e031a9f6f3612394f8918c745700ae41d2aa586", "max_stars_repo_licens...
[STATEMENT] lemma P_inner_t0[simp]: "P_inner g t0 = x0" [PROOF STATE] proof (prove) goal (1 subgoal): 1. P_inner g t0 = x0 [PROOF STEP] by (simp add: P_inner_def)
{"llama_tokens": 79, "file": "Ordinary_Differential_Equations_IVP_Initial_Value_Problem", "length": 1}
import os import argparse from argparse import Namespace import logging import time import numpy as np import torch import torch.nn as nn import torch.optim as optim import copy from decimal import Decimal import wandb import sys sys.path.append('../../../../') from sopa.src.solvers.utils import create_solver from s...
{"hexsha": "df471018a4c3f81400f758c32be191fc187de7c8", "size": 11905, "ext": "py", "lang": "Python", "max_stars_repo_path": "sopa/src/models/odenet_mnist/runner_new.py", "max_stars_repo_name": "juliagusak/neural-ode-metasolver", "max_stars_repo_head_hexsha": "a5ca6ae0c00d2a8da3a5f4b77ee20fb151674d22", "max_stars_repo_l...
# File which contains helper method to visualize, process, predict for CNN models # Dt- 02.08.21 import os import random import pathlib import numpy as np import matplotlib.pyplot as plt import matplotlib.image as mpimg import tensorflow as tf #####3 ## Method 1 def get_class_names(path): ''' getting all the...
{"hexsha": "58792e47b3c073354a955cba253dc3a797932943", "size": 3341, "ext": "py", "lang": "Python", "max_stars_repo_path": "Computer-Vision/helper.py", "max_stars_repo_name": "teddcp2/Tensorflow-Deep-Learning-notes", "max_stars_repo_head_hexsha": "6b52cc32338695052256852879dc383c581fbf7f", "max_stars_repo_licenses": ["...
# Copyright (c) 2019-2020, NVIDIA CORPORATION. # # 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 agre...
{"hexsha": "0781606810839912910f846b554bb464e94b31ca", "size": 8589, "ext": "py", "lang": "Python", "max_stars_repo_path": "python/cuml/dask/cluster/kmeans.py", "max_stars_repo_name": "harrism/cuml", "max_stars_repo_head_hexsha": "060dcd94138deed2ac692031cfe70a674b15c6f0", "max_stars_repo_licenses": ["Apache-2.0"], "ma...
# -*- coding: utf-8 -*- """ Created on Wed Jun 2 13:14:32 2021 @author: ali_d """ import matplotlib.pyplot as plt import numpy as np x = np.linspace(-10,9,20) #-9 ile 10 arasında esıt aralıklarda 20 tane deger olusturdum y = x ** 3 z = x**2 figure = plt.figure() #bos bir figur olusturuyorum axes_cube = figure....
{"hexsha": "ab891fee163e0e78db9cae560e8118a1517c7340", "size": 1495, "ext": "py", "lang": "Python", "max_stars_repo_path": "Data Visualization/Matplotlib/3 Matplotlib.py", "max_stars_repo_name": "ALDOR99/Python", "max_stars_repo_head_hexsha": "a76f37bb3e573cd3fdcfc19f4f73494cafa9140e", "max_stars_repo_licenses": ["MIT...
\chapter{Chain Database} \label{chaindb} TODO\todo{TODO}: This is currently a disjoint collection of snippets. \section{Union of the Volatile DB and the Immutable DB} \label{chaindb:union} As discussed in \cref{storage:components}, the blocks in the Chain DB are divided between the Volatile DB (\cref{volatile}) and ...
{"hexsha": "8d794bc13600d5fbabb730659650cedd457b9447", "size": 18976, "ext": "tex", "lang": "TeX", "max_stars_repo_path": "ouroboros-consensus/docs/report/chapters/storage/chaindb.tex", "max_stars_repo_name": "RyanGlScott/ouroboros-network", "max_stars_repo_head_hexsha": "85b06a74c7b895c5412ba2ac8a43b9c264ad7957", "max...
import pretty_midi import numpy as np def extract_label(label_path, m_beat_arr): """Extract drum label notes. Process ground-truth midi into numpy array representation. Parameters ---------- label_path: Path Path to the midi file. m_beat_arr: Extracted mini-beat array of the ...
{"hexsha": "ce6049dc2958bd2bbe76d473f2f8c9036a8c64ad", "size": 3522, "ext": "py", "lang": "Python", "max_stars_repo_path": "omnizart/drum/labels.py", "max_stars_repo_name": "nicolasanjoran/omnizart", "max_stars_repo_head_hexsha": "b0e74af39b2e3a312ef32dbf0837626b2e043cb6", "max_stars_repo_licenses": ["MIT"], "max_stars...
#imports import tensorflow as tf from tensorflow import layers import numpy as np import cv2 from os import listdir from os.path import join, isfile #standard of numpy randomness np.random.seed(7) #use matplotlib to read and process images def getImages(directory, name): images = [] tfImages = [] allImage...
{"hexsha": "b183257d048aabb8721410fabaf5fd47589c138b", "size": 2014, "ext": "py", "lang": "Python", "max_stars_repo_path": "src/Obsolete-UsedDCGAN/ops.py", "max_stars_repo_name": "esslushy/AbstractArtGenerator", "max_stars_repo_head_hexsha": "48ebfee04673bc109fc202c3368dbbc80f0e7021", "max_stars_repo_licenses": ["MIT"]...
# Test of reduction on scalar backend # Unit testing for element-wise expressions on scalar backend import Devectorize import Devectorize.@devec import Devectorize.@inspect_devec import Devectorize.dump_devec import Devectorize.sqr using Base.Test # data a = [3., 4., 5., 6., 8., 7., 6., 5.] b = [9., 8., 7., 6., 4...
{"hexsha": "58d53dddd3e458435a9793784817f803fdb7d107", "size": 2100, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "test/test_scalar_reduc.jl", "max_stars_repo_name": "jakebolewski/Devectorize.jl", "max_stars_repo_head_hexsha": "6e28d48cfdb70c0fe9622ac5a79942decdc73460", "max_stars_repo_licenses": ["MIT"], "max_...
# -*- coding: utf-8 -*- # ***************************************************************************** # ufit, a universal scattering fitting suite # # Copyright (c) 2013-2019, Georg Brandl and contributors. All rights reserved. # Licensed under a 2-clause BSD license, see LICENSE. # ********************************...
{"hexsha": "4c2577a98a7ce9d52c332b8742023397d1b7cd65", "size": 2028, "ext": "py", "lang": "Python", "max_stars_repo_path": "ufit/backends/scipy.py", "max_stars_repo_name": "McStasMcXtrace/ufit", "max_stars_repo_head_hexsha": "02640e2b802bf6d42ae6829a1c1852b21c6fa9f7", "max_stars_repo_licenses": ["BSD-2-Clause"], "max_s...
#!/usr/bin/env python # -*- coding: utf8 from __future__ import division, print_function import numpy as np import os import pandas as pd import plac import tables def get_above(time_series): pops = time_series[:, 0] dups = time_series[:, 1] audi = time_series[:, 2] dups = dups[pops >= 20] a...
{"hexsha": "d2ecd7d1a16d94cd59990aa3ca8f08b7afecd5c7", "size": 2256, "ext": "py", "lang": "Python", "max_stars_repo_path": "scripts/revisits_over_time.py", "max_stars_repo_name": "flaviovdf/phoenix", "max_stars_repo_head_hexsha": "59177657f13337b14d1fe27527a9b09c2c1c1419", "max_stars_repo_licenses": ["BSD-3-Clause"], "...
#!/usr/bin/env python """SimPEG: Simulation and Parameter Estimation in Geophysics SimPEG is a python package for simulation and gradient based parameter estimation in the context of geophysical applications. """ import numpy as np import os import sys import subprocess from distutils.core import setup from setupto...
{"hexsha": "bcb5b8e364009b2572c9670aa5e4674d6ba1b521", "size": 3218, "ext": "py", "lang": "Python", "max_stars_repo_path": "setup.py", "max_stars_repo_name": "KyuboNoh/HY", "max_stars_repo_head_hexsha": "8ba9815137c2cff2f1931a1940e1b762e8df0b02", "max_stars_repo_licenses": ["MIT"], "max_stars_count": 1, "max_stars_repo...
import os import glob import random import time import h5py import numpy as np import torch import torch.nn.functional as F from torchvision import transforms as T from torch.utils.data import Dataset import torchvision.transforms.functional as tf def data_augmentation(images): mode = np.random.randint(0, 5) ...
{"hexsha": "7782a17bb51979df4e358a6ef69ef34b68eaa65a", "size": 8370, "ext": "py", "lang": "Python", "max_stars_repo_path": "train_mpi/datasets/realestate.py", "max_stars_repo_name": "ken2576/deep-3dmask", "max_stars_repo_head_hexsha": "00c12af81ee48b5d0e612fa0f17395284d23fcc2", "max_stars_repo_licenses": ["MIT"], "max_...
module Test.FmtTest import IdrTest.Test import IdrTest.Expectation import Fmt simpleTest : Test simpleTest = test "Simple test" (\_ => assertEq (fmt "Hello") "Hello" ) stringTest : Test stringTest = test "String test" (\_ => assertEq (fmt "Hello %s" "world") "Hello world" ) intTest : Test i...
{"hexsha": "05a4c811ad71de6b765bd43adc9713a122c64d08", "size": 668, "ext": "idr", "lang": "Idris", "max_stars_repo_path": "Base/Fmt/Test/FmtTest.idr", "max_stars_repo_name": "Z-snails/inigo", "max_stars_repo_head_hexsha": "57f5b5c051222d8c630010a0a3cf7d7138910127", "max_stars_repo_licenses": ["MIT"], "max_stars_count":...
import copy import json import numpy import cepton_sdk.common.transform from cepton_sdk.common import * _all_builder = AllBuilder(__name__) def _convert_keys_to_int(d, ignore_invalid=False): d_int = {} for key, value in d.items(): try: key = int(key) except: if ignor...
{"hexsha": "ffb1b066119712f4df04846c2b225ad40eebb3a7", "size": 7420, "ext": "py", "lang": "Python", "max_stars_repo_path": "python/cepton_sdk/settings.py", "max_stars_repo_name": "Ly0n/cepton_sdk_redist", "max_stars_repo_head_hexsha": "5b4bf24edadb4fdaf9b8149a70c60d207922a1ad", "max_stars_repo_licenses": ["BSD-3-Clause...
from __future__ import absolute_import from copy import deepcopy import torch import numpy as np import pandas as pd from .utils import get_transform from .random_noise import label_noise, image_noise from .datasets import CIFAR10, CIFAR100, Nexperia, Nexperia_eval from myImageFolder import MyImageFolder from concat...
{"hexsha": "5c52fdc3378dbf2fca2ae7d5ad17ccd715579251", "size": 11192, "ext": "py", "lang": "Python", "max_stars_repo_path": "datasets/loaders.py", "max_stars_repo_name": "huangkaiyikatherine/nexperia_new", "max_stars_repo_head_hexsha": "b9b5c35d989883f8b29280726bfbb0fc84e62b10", "max_stars_repo_licenses": ["MIT"], "max...
import unittest import pickle import time import sys import numpy as np import mrestimator as mre from mrestimator.utility import log def test_similarity(value1, value2, ratio_different=1e-10): print('ratio difference: {:.3e}'.format(np.max(np.fabs(value1 - value2)/((value1 + value2)/2)))) return np.all(np....
{"hexsha": "b34133bf4c7666e8424ac698638430f11f3042d8", "size": 6745, "ext": "py", "lang": "Python", "max_stars_repo_path": "mrestimator/test_suite/test_coefficients.py", "max_stars_repo_name": "balajisriram/mrestimator", "max_stars_repo_head_hexsha": "62a17ed8b101362862364850bb93991dd7e3893a", "max_stars_repo_licenses"...
# ############################################################################ # cpgd.py # ======= # Authors : Adrien Besson [adribesson@gmail.com] and Matthieu Simeoni [matthieu.simeoni@gmail.com] # ############################################################################ """ Class for the CPGD algorithm. Descripti...
{"hexsha": "5a1b5fdb3355525cedc0d5c99ceb79ba4ddd0b82", "size": 12364, "ext": "py", "lang": "Python", "max_stars_repo_path": "pyoneer/algorithms/cpgd.py", "max_stars_repo_name": "matthieumeo/pyoneer", "max_stars_repo_head_hexsha": "fb7ee05c5319248f9180c10068235ff311b844b0", "max_stars_repo_licenses": ["MIT"], "max_stars...
## Transforms take values at Chebyshev points of the first and second kinds and produce Chebyshev coefficients abstract type ChebyshevPlan{T} <: Plan{T} end size(P::ChebyshevPlan) = isdefined(P, :plan) ? size(P.plan) : (0,) length(P::ChebyshevPlan) = isdefined(P, :plan) ? length(P.plan) : 0 const FIRSTKIND = FFTW.R...
{"hexsha": "0563f26bed5b28df98b6ff8a57f841dcca8afcc7", "size": 24831, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "src/chebyshevtransform.jl", "max_stars_repo_name": "JuliaApproximation/FastTransforms.jl", "max_stars_repo_head_hexsha": "4199ae9ac7970390da2546aef7f290f4cf675c65", "max_stars_repo_licenses": ["MI...
Set Implicit Arguments. Require Import Coq.Setoids.Setoid. Require Import Coq.Arith.EqNat. Local Open Scope bool_scope. Definition pk : Set := (nat * nat * nat * nat) %type. Inductive trace : Set := | tr_single : pk -> trace | tr_cons : pk -> trace -> trace. Inductive hdr := | sw : hdr | pt : hdr | src : hdr | dst...
{"author": "frenetic-lang", "repo": "featherweight-openflow", "sha": "4470518794e3ed867919d30500be2d0128b1de1c", "save_path": "github-repos/coq/frenetic-lang-featherweight-openflow", "path": "github-repos/coq/frenetic-lang-featherweight-openflow/featherweight-openflow-4470518794e3ed867919d30500be2d0128b1de1c/coq/Netkat...
# This file is auto-generated by AWSMetadata.jl using AWS using AWS.AWSServices: database_migration_service using AWS.Compat using AWS.UUIDs """ AddTagsToResource() Adds metadata tags to an AWS DMS resource, including replication instance, endpoint, security group, and migration task. These tags can also be used w...
{"hexsha": "5d703f036ed123e1882ef2e9f8cc9695ac2de86d", "size": 91969, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "src/services/database_migration_service.jl", "max_stars_repo_name": "ExpandingMan/AWS.jl", "max_stars_repo_head_hexsha": "8e6e61eb9dcd84fb1e148ff2afe093b3010d9edb", "max_stars_repo_licenses": ["MI...
//================================================================================================== /*! @file @copyright 2016 NumScale SAS Distributed under the Boost Software License, Version 1.0. (See accompanying file LICENSE.md or copy at http://boost.org/LICENSE_1_0.txt) **/ //==========================...
{"hexsha": "11b2a290a787beb6f90e28febd5050ae2105a0e8", "size": 4926, "ext": "hpp", "lang": "C++", "max_stars_repo_path": "third_party/boost/simd/algorithm/reduce.hpp", "max_stars_repo_name": "xmar/pythran", "max_stars_repo_head_hexsha": "dbf2e8b70ed1e4d4ac6b5f26ead4add940a72592", "max_stars_repo_licenses": ["BSD-3-Clau...
using SuiteSparseMatrixCollection using MatrixMarket using SuiteSparseGraphBLAS using BenchmarkTools using SparseArrays include("tc.jl") include("pr.jl") graphs = [ "karate", "com-Youtube", "as-Skitter", "com-LiveJournal", "com-Orkut", "com-Friendster", ] ssmc = ssmc_db() matrices = filter(row ...
{"hexsha": "9cc2389465d6373d2929db0426efe63021943d12", "size": 962, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "julia/script.jl", "max_stars_repo_name": "Wimmerer/HPEC21-TriangleCentrality", "max_stars_repo_head_hexsha": "dd65a7d1571670b70e444bf46e8c280ae35b754f", "max_stars_repo_licenses": ["Apache-2.0"], "m...
module UNet using Flux, Images using Flux: @treelike # model export unet # utilities export img2array, array2img, unet_tiling include("model.jl") include("utils.jl") end # module
{"hexsha": "3f2408761cac59243cdf935547dba7e0eeafa512", "size": 184, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "src/UNet.jl", "max_stars_repo_name": "CDonnerer/UNet.jl", "max_stars_repo_head_hexsha": "8d34190944f52f7d0beb44140fc32e9259b52db6", "max_stars_repo_licenses": ["MIT"], "max_stars_count": null, "max_...
[STATEMENT] lemma Trgs_are_ide: shows "Trgs T \<subseteq> Collect R.ide" [PROOF STATE] proof (prove) goal (1 subgoal): 1. Trgs T \<subseteq> Collect R.ide [PROOF STEP] apply (induct T) [PROOF STATE] proof (prove) goal (2 subgoals): 1. Trgs [] \<subseteq> Collect R.ide 2. \<And>a T. Trgs T \<subseteq> Collect R.i...
{"llama_tokens": 288, "file": "ResiduatedTransitionSystem_ResiduatedTransitionSystem", "length": 3}
import numpy as np import matplotlib.pyplot as plt import shutil import argparse import os import json import random import warnings from termcolor import colored import pandas as pd from sklearn.metrics import confusion_matrix import cv2 import importlib import torch import torch.nn as nn import torch.nn.functional ...
{"hexsha": "202ec67999b3abd915bf1dd48c8d109a1cd0c26d", "size": 14439, "ext": "py", "lang": "Python", "max_stars_repo_path": "trainer.py", "max_stars_repo_name": "timmyvg/MSBP_Net", "max_stars_repo_head_hexsha": "e2ee6d57ccfc17cd5e5c64e399cbc245281e878d", "max_stars_repo_licenses": ["MIT"], "max_stars_count": 4, "max_st...
function serverStarted = mrmCheckServer(host) %Test whether the server has been started. % % serverStarted = mrmCheckServer(host) % % There should be a way to test without creating a new window. But I am % not sure how. % % (c) Stanford Vista Team, 2008 if ieNotDefined('host'), host = 'localhost'; end % Try op...
{"author": "vistalab", "repo": "vistasoft", "sha": "7f0102c696c091c858233340cc7e1ab02f064d4c", "save_path": "github-repos/MATLAB/vistalab-vistasoft", "path": "github-repos/MATLAB/vistalab-vistasoft/vistasoft-7f0102c696c091c858233340cc7e1ab02f064d4c/mrMesh/mrm/mrmCheckServer.m"}
import Base: ==, copy, size, convert import SparseArrays: sparse # # bm: SymmetricBandedMatrix # bmat: Banded matrix (the field in a SymmetricBandedMatrix object) # m: Regular matix # sbm: Semi-banded matrix, e.g. # sbm = [0 0 1; 0 2 3; 4 5 6] # hbw: Half bandwidth, h...
{"hexsha": "eee57f033278c3219e15b086d9e713391ba46133", "size": 2882, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "src/nmlib/SymmetricBandedMatrices.jl", "max_stars_repo_name": "PtFEM/NumericalMethodsforEngineers.jl", "max_stars_repo_head_hexsha": "e4a997a14adbb86b7efe1586962df39eb9285ebb", "max_stars_repo_lice...
# Maze Navigation. Originally proposed in # Backpropamine: differentiable neuromdulated plasticity. # # This code implements the "Grid Maze" task. See Section 4.5 in Miconi et al. # ICML 2018 ( https://arxiv.org/abs/1804.02464 ), or Section 4.2 in # Miconi et al. ICLR 2019 ( https://openreview.net/pdf?id=r1lrAiA5Ym ) #...
{"hexsha": "cc711b85d615a221b71e1a017fccdba933f54b98", "size": 6648, "ext": "py", "lang": "Python", "max_stars_repo_path": "src/maze_navigation/maze.py", "max_stars_repo_name": "rcmalli/warpgrad", "max_stars_repo_head_hexsha": "d9ef72af10eec62ae92bc24595cb1a4a0207e319", "max_stars_repo_licenses": ["Apache-2.0"], "max_s...
import abc from typing import List import numpy as np import pandas as pd # abstract base class class TransformationStrategy(): @abc.abstractclassmethod def transform(self, df: pd.DataFrame) -> pd.DataFrame: pass @abc.abstractclassmethod def get_code(self, df_name: str) -> str: pass ...
{"hexsha": "ca249b61f93d9968a1155ead8cd906d293685255", "size": 11214, "ext": "py", "lang": "Python", "max_stars_repo_path": "src/BPMN/TransformationStrategy.py", "max_stars_repo_name": "oilyshelf/AutomaModela", "max_stars_repo_head_hexsha": "690bbc51bb21cccf07457d9e5f7bce504800db19", "max_stars_repo_licenses": ["MIT"],...
// node #include <node.h> // for NODE_SET_PROTOTYPE_METHOD, etc #include <node_object_wrap.h> // for ObjectWrap #include <v8.h> #include <uv.h> #include <node_buffer.h> #include <node_version.h> // mapnik #include <mapnik/color.hpp> // for color #include <mapnik/image_view....
{"hexsha": "e6825324d8d7d46406bdfc8512a91fe01621666b", "size": 16434, "ext": "cpp", "lang": "C++", "max_stars_repo_path": "src/mapnik_image_view.cpp", "max_stars_repo_name": "calvinmetcalf/node-mapnik", "max_stars_repo_head_hexsha": "3d26f2089dee3cfc901965f6646d50004a0e0e56", "max_stars_repo_licenses": ["BSD-3-Clause"]...
import time import numpy as np from datetime import datetime from Recon import SensorReader, Recon class Env(object): def cap(self,x, down, up, ninter): if x<=down: x=down if up<=x: x=up-1 step=(up-down)/ninter #print x return (x-down)//step d...
{"hexsha": "19f609685e2a2649c0b28a27da87f2da6d1f6327", "size": 3993, "ext": "py", "lang": "Python", "max_stars_repo_path": "Strawry/control/Env.py", "max_stars_repo_name": "Bossabossy/Strawry", "max_stars_repo_head_hexsha": "8ee28138599d258eaa48a625ea929a8b4ccbd639", "max_stars_repo_licenses": ["BSD-2-Clause"], "max_st...
import os import george import pandas as pd import matplotlib.pyplot as plt import numpy as np from sklearn import gaussian_process data_dir = '/home/ilya/Dropbox/petya' data_file = 'Total_rate_vs_Years_v2.txt' df = pd.read_table(os.path.join(data_dir, data_file), delim_whitespace=True, names=['exp...
{"hexsha": "2c8b27754088c20c01704ed1c0359c9151a39094", "size": 2698, "ext": "py", "lang": "Python", "max_stars_repo_path": "gp.py", "max_stars_repo_name": "ipashchenko/ra_orbit", "max_stars_repo_head_hexsha": "d58a920b6b185450012770cc4468be9399f2ea5f", "max_stars_repo_licenses": ["MIT"], "max_stars_count": null, "max_s...
# Linear Algebra, Handling of Arrays and more Python Features ## Introduction The aim of this set of lectures is to review some central linear algebra algorithms that we will need in our data analysis part and in the construction of Machine Learning algorithms (ML). This will allow us to introduce some central prog...
{"hexsha": "729fa16cd7b47b4d580bd65a3830aee8bed70d39", "size": 26602, "ext": "py", "lang": "Python", "max_stars_repo_path": "doc/LectureNotes/_build/jupyter_execute/linalg.py", "max_stars_repo_name": "marlgryd/MachineLearning", "max_stars_repo_head_hexsha": "e07439cee1f9e3042aec765754116dccdf8bcf01", "max_stars_repo_li...
import numpy as np import argparse import json def get_argument_parser(): parser = argparse.ArgumentParser(); parser.add_argument('--data_type', type=str, default='iid', help='the type of data that needs to be generated') parser.add_argument('--num_samples', type=int, default=100000...
{"hexsha": "07d393d2f2df9baae4997c1526ca3d956166c2f3", "size": 3042, "ext": "py", "lang": "Python", "max_stars_repo_path": "src/data_generation_scripts/generate_sequence_data.py", "max_stars_repo_name": "rajatdiptabiswas/NN_compression", "max_stars_repo_head_hexsha": "1a2650ad897bcc1f32f3b63d0a6477b8f6be6e29", "max_sta...
#!/usr/bin/env python # coding: utf-8 # In[4]: from numpy import sin, pi, sqrt, arccos, log from pandas import read_excel e = 1.602e-19 # [C] electron charge r_p = 0.15e-3 # [m] probe radius l_p = 1e-3 # [m] probe length h = 0.5e-3 # [m] Hole radius s = 0.7e-3 # [m] Rotation center to Hole edge R = 0.6e-3 # [m] Rot...
{"hexsha": "f65a5260d81742e10ab591a0c83d700dd4d7de7a", "size": 1595, "ext": "py", "lang": "Python", "max_stars_repo_path": "Python_Projects/Mach_Probe/Untitled.py", "max_stars_repo_name": "GUNU-GO/SNUPI", "max_stars_repo_head_hexsha": "a73137699d9fc6ae8fa3d1522f341c04d8d43052", "max_stars_repo_licenses": ["MIT"], "max_...
import time import numpy as np start = time.perf_counter() def get_input(): with open('inputs/test7.txt') as f: temp = f.readlines() init = temp[0].split(",") init[-1] = init[-1].strip("\n") for i, val in enumerate(init): init[i] = int(val) return init def day7part1(init): med = np.m...
{"hexsha": "def65e2b4f9c62fd01f370d19512e46394132215", "size": 901, "ext": "py", "lang": "Python", "max_stars_repo_path": "day7.py", "max_stars_repo_name": "gitkoogie/AdventOfCode2021", "max_stars_repo_head_hexsha": "416408c22bc704abc95ed46105d086d08e116e1d", "max_stars_repo_licenses": ["Apache-2.0"], "max_stars_count"...
from typing import Dict, Tuple import numpy as np def pad( img: np.ndarray, target_size: Tuple, pad_value: float = 0.0, targets: Dict = None ): targets = dict() if targets is None else targets h, w, c = img.shape tw, th = target_size pad_left = int((tw - w) // 2) + (tw - w) % 2 pad_right = i...
{"hexsha": "f54ed3ef55454769cc593cbda83988a6dd9babad", "size": 1017, "ext": "py", "lang": "Python", "max_stars_repo_path": "fastface/transforms/functional/pad.py", "max_stars_repo_name": "mdornseif/fastface", "max_stars_repo_head_hexsha": "72772db1fae4af17e829cd5479c4848fe5eb8948", "max_stars_repo_licenses": ["MIT"], "...
source("../power_priors_aux.r") source("../data_Gaussian.r") gs.data <- list( N0 = N_0, y0 = y_0, mu0 = mu_0, kappa0 = kappa_0, alpha0 = alpha_0, beta0 = beta_0, a_0 = 1 ) ### get_l_a0_gaussian <- function(y0, n0, alpha0, beta0, m0, k0, a_0){ nstar <- a_0 * n0 ybar <- mean(y0) s <- mean( (y0-ybar)...
{"hexsha": "f4c74be7be65d7f8bfce867e02e3bf2e7af1f968", "size": 2092, "ext": "r", "lang": "R", "max_stars_repo_path": "code/extra/test_Gaussian_derivative.r", "max_stars_repo_name": "maxbiostat/propriety_power_priors", "max_stars_repo_head_hexsha": "43a9dc7bd007d5647bc453cd8a875e82c16ad6eb", "max_stars_repo_licenses": [...
#include <yaml-cpp/yaml.h> #include <boost/filesystem.hpp> #include "imgui.h" #include "imgui-SFML.h" #include <SFML/Graphics.hpp> #include "tinyfiledialogs.h" #include "scene/Scene.hpp" scene::Scene* parseSceneFromFile(const std::string &path) { try { return new scene::Scene(YAML::LoadFile(path)); }...
{"hexsha": "b411064f8dc5b1f2b04e2cad84917882141d40d8", "size": 11399, "ext": "cpp", "lang": "C++", "max_stars_repo_path": "src/main.cpp", "max_stars_repo_name": "r-o-b-o-t-o/cpp-raytracer", "max_stars_repo_head_hexsha": "23f7e483a786f760c8663d9fcaf0ec1627902e38", "max_stars_repo_licenses": ["MIT"], "max_stars_count": 4...
program lonlat_dist implicit none c character*240 cfilea,cfileb,cline integer ios,l logical lsum,skip_new,skip_old real lat1,lat2,lon1,lon2,dist,distmax real*8 dist_sum real*4 spherdist c c lonlat_dist - Usage: lonlat_dist in.txt out.t...
{"hexsha": "d6295ca0ad776c257e6d8373ab823b8737622cff", "size": 6647, "ext": "f", "lang": "FORTRAN", "max_stars_repo_path": "bin/lonlat_dist.f", "max_stars_repo_name": "TillRasmussen/HYCOM-tools", "max_stars_repo_head_hexsha": "7d26b60ce65ac9d785e0e36add36aca05c0f496d", "max_stars_repo_licenses": ["MIT"], "max_stars_cou...
Require Import StateType SmallStepRelations Divergence. Require Import Classical_Prop Coq.Logic.Epsilon. Set Implicit Arguments. Lemma three_possibilities S `{StateType S} (σ:S) : (exists σ', star2 step σ nil σ' /\ normal2 step σ') \/ (exists σ', star2 step σ nil σ' /\ activated σ') \/ diverges σ. Proof. destruc...
{"author": "sigurdschneider", "repo": "lvc", "sha": "be41194f16495d283fe7bbc982c3393ac554dd5b", "save_path": "github-repos/coq/sigurdschneider-lvc", "path": "github-repos/coq/sigurdschneider-lvc/lvc-be41194f16495d283fe7bbc982c3393ac554dd5b/theories/Equiv/StateTypeProperties.v"}
#classes and subclasses to import import cv2 import numpy as np def blend_transparent(face_img, overlay_t_img): # Split out the transparency mask from the colour info overlay_img = overlay_t_img[:,:,:3] # Grab the BRG planes overlay_mask = overlay_t_img[:,:,3:] # And the alpha plane # Again calculat...
{"hexsha": "362f2c9978b3b02f595499ad518b85d9529d463a", "size": 3366, "ext": "py", "lang": "Python", "max_stars_repo_path": "snappy_lips.py", "max_stars_repo_name": "ninjakx/Snappy", "max_stars_repo_head_hexsha": "b0289ae7d79d86c875c010972744e06d75f5575d", "max_stars_repo_licenses": ["MIT"], "max_stars_count": 1, "max_s...
# coding=utf-8 import numpy as np import scipy.stats from .cobsampler import ChangeOfBasisSampler class Test(object): """ Super class implementing tests for CoBSampler. Sub-classes should specify target distribution. """ def __init__(self, ndim, target, nsteps, cobparams={}): self.ndim = ...
{"hexsha": "6ff64929cc4dd7af2b28f398df524a10cf507044", "size": 4799, "ext": "py", "lang": "Python", "max_stars_repo_path": "cobmcmc/tests.py", "max_stars_repo_name": "exord/cobmcmc", "max_stars_repo_head_hexsha": "162ba8d4fab35aa44bc8a4828eb51e25df13c4e2", "max_stars_repo_licenses": ["MIT"], "max_stars_count": null, "m...
\section{UTxO} \label{sec:utxo} \begin{figure*}[htb] \emph{Derived types} % \begin{equation*} \begin{array}{r@{~\in~}l@{\qquad=\qquad}lr} \var{uin} & \UTxOIn & \TxId \times \Ix % & \text{transaction output preference} \\ \var{uout} & \UTxOOut & (\TxOutND \union...
{"hexsha": "5d45206e919e0e19320f9c4607ad6dc34e4daadd", "size": 40872, "ext": "tex", "lang": "TeX", "max_stars_repo_path": "goguen/formal-spec/utxo.tex", "max_stars_repo_name": "michaelpj/cardano-ledger-specs", "max_stars_repo_head_hexsha": "d371ad2ebf5d1ddff93776fac2dfd1045aa6b06c", "max_stars_repo_licenses": ["Apache-...
Require Import PV.Types. Require Import PV.Nat. Require Import Coq.Lists.List. Require Import Coq.Arith.PeanoNat. Lemma remove_not_in : forall (a : Type) (xs : list a) (x : a), forall (dec : DecidableEq a), ~In x xs -> xs = remove dec x xs. Proof. intros. induction xs. compute. auto. unfold remove. ...
{"author": "MichaelBurge", "repo": "pornview", "sha": "b4aefdc0e49504aa88345b96710bd86645ab2477", "save_path": "github-repos/coq/MichaelBurge-pornview", "path": "github-repos/coq/MichaelBurge-pornview/pornview-b4aefdc0e49504aa88345b96710bd86645ab2477/PV/Lists.v"}
from ektelo.dataset import DatasetFromRelation import numpy as np from ektelo import support from ektelo.operators import TransformationOperator class Vectorize(TransformationOperator): stability = 1 def __init__(self, name, normed=False, weights=None, reduced_domain=None): self.name = name ...
{"hexsha": "8caf1406bf79f7d51f58d9a56e3adf62757f78ea", "size": 2598, "ext": "py", "lang": "Python", "max_stars_repo_path": "ektelo/private/transformation.py", "max_stars_repo_name": "dpcomp-org/ektelo", "max_stars_repo_head_hexsha": "7629fbf106f9b9568c66a0b97f6005280022c3d8", "max_stars_repo_licenses": ["Apache-2.0"], ...
import numpy as np logistic = lambda z: 1.0 / (1.0 + np.exp(-z)) tanh = lambda z: (np.exp(z) - np.exp(-z)) / (np.exp(z) + np.exp(-z)) rectifier = lambda z: np.maximum(0.0, z)
{"hexsha": "c6ffd7fba07289bb52f9d4f59a68af4d9adbf44e", "size": 175, "ext": "py", "lang": "Python", "max_stars_repo_path": "titanium/activation.py", "max_stars_repo_name": "MaxNoe/titanium", "max_stars_repo_head_hexsha": "ace635604d29a5607b5005653ef486b5f2fb6b9f", "max_stars_repo_licenses": ["MIT"], "max_stars_count": 4...
import numpy as np from math import pi import os from src import RDModes, Config, list_tl_files import matplotlib.pyplot as plt plt.style.use('elr') plt.ion() fc = 400 z_int = 150. cf = Config(fc=fc) tl_files = list_tl_files(fc) tl_data = np.load(tl_files[23]) r_a = tl_data['rplot'] rd_modes = RDModes(tl_data['c_...
{"hexsha": "8836dee62a94a1afd038d3a528c224f6d078537c", "size": 2194, "ext": "py", "lang": "Python", "max_stars_repo_path": "reports/jasa/mode_shapes.py", "max_stars_repo_name": "nedlrichards/tau_decomp", "max_stars_repo_head_hexsha": "77560307836f67ae68f3571fb6cd0fd9d831398d", "max_stars_repo_licenses": ["MIT"], "max_s...
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Fri Oct 12 12:35:01 2018 @author: abhijay """ import numpy as np import pandas as pd #import os #import pickle import copy from sklearn import preprocessing from sklearn import tree #os.chdir('/home/abhijay/Documents/ML/hw_2/Q10') class tree_node(): ...
{"hexsha": "05f2e7331cb9a34641aecd991068062164844130", "size": 16024, "ext": "py", "lang": "Python", "max_stars_repo_path": "id3.py", "max_stars_repo_name": "abhijayghildyal/id3DecisionTree", "max_stars_repo_head_hexsha": "e6e126b91db6b086af748c34a058a937b74f4b72", "max_stars_repo_licenses": ["MIT"], "max_stars_count":...
/*============================================================================= Copyright (c) 2001-2011 Joel de Guzman Distributed under the Boost Software License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) ====================================...
{"hexsha": "a3b29dabffaa5eb52c77182bf41655c5cb8f7104", "size": 2014, "ext": "hpp", "lang": "C++", "max_stars_repo_path": "ios/Pods/boost-for-react-native/boost/fusion/container/list/convert.hpp", "max_stars_repo_name": "rudylee/expo", "max_stars_repo_head_hexsha": "b3e65a7a5b205f14a3eb6cd6fa8d13c8d663b1cc", "max_stars_...
# coding=utf-8 # Copyright 2021 The Google Research 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 applicab...
{"hexsha": "06d4a3ce2dd778daad5c8fbb19588bd35c1713b6", "size": 5510, "ext": "py", "lang": "Python", "max_stars_repo_path": "epistasis_selection.py", "max_stars_repo_name": "captaincapsaicin/slip", "max_stars_repo_head_hexsha": "3c112f51cd11118f1e11c0c6fdd8c3d31d304d9b", "max_stars_repo_licenses": ["Apache-2.0"], "max_s...
""" Extended kalman filter (EKF) localization sample author: Atsushi Sakai (@Atsushi_twi) """ import math import matplotlib.pyplot as plt import numpy as np # Covariance for EKF simulation Q = np.diag([ 0.01, # variance of location on x-axis 0.01, # variance of location on y-axis np.deg2rad(1.0), #...
{"hexsha": "fc599e63fb4a8ff1c1c5578d6d44ae5325de4344", "size": 5405, "ext": "py", "lang": "Python", "max_stars_repo_path": "Localization/extended_kalman_filter_6_state/extended_kalman_filter.py", "max_stars_repo_name": "MC9529/PythonRobotics", "max_stars_repo_head_hexsha": "e8aef156ccb32186e502576bdf6875475181742b", "m...
import numpy as np import pywcs # **** check that rotang we are using agrees with telescope definition! **** # -- set geometry for RSS (and write region file) # should probably have some smarter way of storing these global parameters pxscale=0.2507/2. # unbinned dcr=4./60. # radius of field (deg) #dcr=3.9/60. # ...
{"hexsha": "e50b1ad0c4697a95841d589cd990d358b9b899a9", "size": 9819, "ext": "py", "lang": "Python", "max_stars_repo_path": "proptools/RSS_geom.py", "max_stars_repo_name": "Richard-Tarbell/pysalt", "max_stars_repo_head_hexsha": "2815d5533c7e60b7042f2bc3cf46cecdd38fc609", "max_stars_repo_licenses": ["BSD-3-Clause"], "max...
#pragma once #include <Python.h> #include <boost/python.hpp> #include <sys/inotify.h> #include <blackboard/Adapter.hpp> #include <types/BehaviourRequest.hpp> #include <utils/Timer.hpp> class Blackboard; #define INBUF_LEN 32 * (sizeof(struct inotify_event) + 16) class PythonSkill : Adapter { public: static...
{"hexsha": "d78f0df8f00e4a25909e3ea49d7777c164469dde", "size": 2015, "ext": "hpp", "lang": "C++", "max_stars_repo_path": "src/Core/External/unsw/unsw/perception/behaviour/python/PythonSkill.hpp", "max_stars_repo_name": "pedrohsreis/boulos", "max_stars_repo_head_hexsha": "a5b68a32cad8cc1fb9f6fbf47fc487ef99d3166e", "max_...
include("$(pwd())/startup.jl") #fp = "./ExampleFiles/STOFDATA/" # All files in this path will be processed fp = "/media/wiebke/Extreme SSD/PSM_vs_PTR3/Data/apiTOFdata/CLOUD10/run1734_02/" filefilterRegexp = r"\.h5$" #rf = "./ExampleFiles/STOFDATA/2017-05-24_12h50m39_NH4.h5" # The mass scale from this file defines ...
{"hexsha": "4ca2e1eb5863c711f7f03f21e2b0984d3f33a43e", "size": 1815, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "processingProjects/processingProject-example_STOF.jl", "max_stars_repo_name": "weikou/TOF-Tracer2", "max_stars_repo_head_hexsha": "78406cc829d9903aece2d848960344aa09a263f9", "max_stars_repo_license...
% !TeX root = article.tex \section{Description of plasticity in the framework of physics engines} In this section, key concepts related to the introduced model are explained. The main differences between traditional structural analysis and physics engines based approaches are reviewed and discussed. Velocity-based f...
{"hexsha": "5d238740e4b5a484233187b66593d0ee9b5fd7cc", "size": 17549, "ext": "tex", "lang": "TeX", "max_stars_repo_path": "pdocs/thesis/article-section-2.tex", "max_stars_repo_name": "simo-11/bullet3", "max_stars_repo_head_hexsha": "af7753f5d7fbc0030a3abbe43356d9a9ea784a62", "max_stars_repo_licenses": ["Zlib"], "max_st...
""" Utility functions for COOT model """ import ctypes import datetime import logging import multiprocessing as mp import os from pathlib import Path import random import sys from typing import Tuple, Dict import numpy as np import torch import torch.backends.cudnn as cudnn from torch import cuda import torch.nn.funct...
{"hexsha": "5d0095cfb0e4086db7918fa3f2a637440e53c9a7", "size": 11745, "ext": "py", "lang": "Python", "max_stars_repo_path": "gluoncv/torch/utils/coot_utils.py", "max_stars_repo_name": "RafLit/gluon-cv", "max_stars_repo_head_hexsha": "dae504a4de8fff1421fd4fe398accbe396c504cc", "max_stars_repo_licenses": ["Apache-2.0"], ...
library(data.table) library(hyperSpec) source("~/Repositories/PHESANT/summarise_phenotypes.r") root_file <- "pharma_exomes_parsed_output_100k_chunk" number_of_chunks <- 10 # Old phenotype_info_file <- "../variable-info/outcome_info_final_round2.tsv" # Latest pharma firm variable info file phenotype_info_file <- ".....
{"hexsha": "1bc8d91f055ad87fd8cfdf6d8cdc406f3e113863", "size": 15751, "ext": "r", "lang": "R", "max_stars_repo_path": "post_PHESANT_exome_pipeline/03_run_summarise_exomes_phenotypes_cloud.r", "max_stars_repo_name": "lganel/PHESANT", "max_stars_repo_head_hexsha": "0f94a3683986b18ca90e20bff0d8bf723bd80211", "max_stars_re...
(* Copyright (c) 2011. Greg Morrisett, Gang Tan, Joseph Tassarotti, Jean-Baptiste Tristan, and Edward Gan. This file is part of RockSalt. This file 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;...
{"author": "mpettersson", "repo": "reins-verifier-proof", "sha": "44d0b8e0c29b07eb71b1d6d44b020648783409fb", "save_path": "github-repos/coq/mpettersson-reins-verifier-proof", "path": "github-repos/coq/mpettersson-reins-verifier-proof/reins-verifier-proof-44d0b8e0c29b07eb71b1d6d44b020648783409fb/Model/Decode.v"}
subroutine system_setup use systemparams implicit none open(3,file = parameter_path, status='unknown') read(3,*) nx read(3,*) star_mass read(3,*) star_lum read(3,*) a read(3,*) e read(3,*) phi_peri read(3,*) angular_position read(3,*) period ...
{"hexsha": "317a9414ceb338c950660889c9cd4c336c714951", "size": 1836, "ext": "f90", "lang": "FORTRAN", "max_stars_repo_path": "src/system_setup.f90", "max_stars_repo_name": "mjdbahram/exoClimate", "max_stars_repo_head_hexsha": "48ae1ea333d8ca117dd736da575fd1f2a55012f4", "max_stars_repo_licenses": ["MIT"], "max_stars_cou...
# -*- coding: utf-8 -*- """ This script works for foam phantom. """ import numpy as np import glob import dxchange import matplotlib.pyplot as plt import scipy.interpolate import tomopy from scipy.interpolate import Rbf from mpl_toolkits.mplot3d.axes3d import Axes3D from matplotlib import cm from project import * fro...
{"hexsha": "286679f84960e6ae0f9492ba15fa6e49685d30ea", "size": 916, "ext": "py", "lang": "Python", "max_stars_repo_path": "sampling_demo.py", "max_stars_repo_name": "mdw771/tomosim", "max_stars_repo_head_hexsha": "7736031aee861cd0ac995d83c2231a7df4fc3365", "max_stars_repo_licenses": ["Apache-2.0"], "max_stars_count": 1...
import numpy as np import torch from lamp.optimization import LearningScheduleWrapper from bottleneck.components import PredictionEnsemble, Analysis from bottleneck.VirtualObservables import QuerryPointEnsemble, QuerryEnsemble, VirtualObservablesEnsemble, EnergyVirtualObservablesEnsemble from torch.utils.tensorboard im...
{"hexsha": "cd53c7598ac16f9139d44000fd288d304f6644fa", "size": 22506, "ext": "py", "lang": "Python", "max_stars_repo_path": "training.py", "max_stars_repo_name": "bdevl/PGMCPC", "max_stars_repo_head_hexsha": "cac2fe4304ae42ef2a0d94219b4349d51e86ab2d", "max_stars_repo_licenses": ["MIT"], "max_stars_count": 3, "max_stars...
from collections import OrderedDict import numpy as np import megengine.functional as F import megengine.module as M from megengine import Tensor from megengine.core._imperative_rt.core2 import apply from megengine.core.ops import builtin from megengine.module import Module from megengine.traced_module import TracedM...
{"hexsha": "43d3f492eb4782364ae0a8cdf347342b5543c20b", "size": 4653, "ext": "py", "lang": "Python", "max_stars_repo_path": "imperative/python/test/unit/traced_module/test_trace_module.py", "max_stars_repo_name": "bealwang/MegEngine", "max_stars_repo_head_hexsha": "df4153dc718b4544e720c58e439a0623c018cee2", "max_stars_r...
include("../src/QPnorm.jl") include("../examples/subproblems.jl") using Main.QPnorm using Random, Test function optimality_metrics(P, q, A, b, r_min, r_max, x, λ) m, n = size(A) f = dot(x, P*x)/2 + dot(x, q) grad_residual = norm(P*x + q + A'*λ[1:end-1] + λ[end]*x, Inf) infeasibility = max(maximum(A*x...
{"hexsha": "5b0669c2647172c63d75f9af23a8f79f4db960ed", "size": 1675, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "test/test_solver.jl", "max_stars_repo_name": "oxfordcontrol/QPnorm.jl", "max_stars_repo_head_hexsha": "746eaed3901b47622c0337cde615e82321707eba", "max_stars_repo_licenses": ["MIT"], "max_stars_coun...
from numpy import exp, array, random, dot class NeuronLayer(): def __init__(self, number_of_neurons, number_of_inputs_per_neuron): self.synaptic_weights = 2 * random.random((number_of_inputs_per_neuron, number_of_neurons)) - 1 class NeuralNetwork(): def __init__(self, neural_layers): self.ne...
{"hexsha": "3a489554b2dbcd153d7bbca7b3912d6fc109646b", "size": 4859, "ext": "py", "lang": "Python", "max_stars_repo_path": "talks-articles/machine-learning/toolbox/numpy/multi-layer-neural-network.py", "max_stars_repo_name": "abhishekkr/tutorials_as_code", "max_stars_repo_head_hexsha": "f355dc62a5025b710ac6d4a6ac2f9610...
[STATEMENT] lemma b_least2_less_impl_eq: "b_least2 f x y < y \<Longrightarrow> (b_least2 f x y) = (Least (%z. (f x z) \<noteq> 0))" [PROOF STATE] proof (prove) goal (1 subgoal): 1. b_least2 f x y < y \<Longrightarrow> b_least2 f x y = (LEAST z. f x z \<noteq> 0) [PROOF STEP] proof - [PROOF STATE] proof (state) goal (1...
{"llama_tokens": 1675, "file": "Recursion-Theory-I_PRecFun", "length": 19}
C File: test_module_11.f C Purpose: Illustrates the use of multiple Fortran modules to define values C for several variables that are used in the program. This program C differs from test_module_03.f in having modules that have "USE MODULE"s C inside them , as well as some variables that are declared to be ...
{"hexsha": "cd3d130a57bde8cbb1fb55d9c4b0b0b3bb1473de", "size": 2771, "ext": "f", "lang": "FORTRAN", "max_stars_repo_path": "tests/data/program_analysis/modules/test_module_11.f", "max_stars_repo_name": "mikiec84/delphi", "max_stars_repo_head_hexsha": "2e517f21e76e334c7dfb14325d25879ddf26d10d", "max_stars_repo_licenses"...
using Clang GAGE_INCLUDE = raw"C:\Program Files (x86)\Gage\CompuScope\include" clang_includes = String[] push!(clang_includes, GAGE_INCLUDE) push!(clang_includes, raw"C:\Program Files\LLVM\include\clang-c",raw"C:\Program Files\LLVM\include\llvm-c" ) clang_extraargs = ["-v"] clang_extraargs = ["-D", "__STDC_CONSTANT_M...
{"hexsha": "b2cb3670ab17ada559cbc64525999e42315e8e36", "size": 966, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "gage_clang_gen.jl", "max_stars_repo_name": "jarrison/Gage.jl", "max_stars_repo_head_hexsha": "b8f05666721210e272aea9737136066a59c4d65d", "max_stars_repo_licenses": ["Apache-2.0"], "max_stars_count":...
/*** Copyright (c), The Regents of the University of California *** *** For more information please refer to files in the COPYRIGHT directory ***/ /* ICAT test program. */ #include "rodsClient.h" #include "parseCommandLine.h" #include "readServerConfig.hpp" #include "irods_server_properties.hpp" #includ...
{"hexsha": "9c8f8046b8d59ac6019029487b7fef8c8a40fd18", "size": 35651, "ext": "cpp", "lang": "C++", "max_stars_repo_path": "iRODS/server/test/src/test_chl.cpp", "max_stars_repo_name": "iychoi/cyverse-irods", "max_stars_repo_head_hexsha": "0070b8677a82e763f1d940ae6537b1c8839a628a", "max_stars_repo_licenses": ["BSD-3-Clau...
[STATEMENT] lemma connected_trans: assumes u_v: "u \<rightarrow>\<^sup>* v" and v_w: "v \<rightarrow>\<^sup>* w" shows "u \<rightarrow>\<^sup>* w" [PROOF STATE] proof (prove) goal (1 subgoal): 1. u \<rightarrow>\<^sup>* w [PROOF STEP] proof- [PROOF STATE] proof (state) goal (1 subgoal): 1. u \<rightarrow>\<^sup>*...
{"llama_tokens": 1799, "file": "Tree_Decomposition_Graph", "length": 22}
-makelib ies_lib/xilinx_vip -sv \ "B:/Xilinx/Vivado/2018.3/data/xilinx_vip/hdl/axi4stream_vip_axi4streampc.sv" \ "B:/Xilinx/Vivado/2018.3/data/xilinx_vip/hdl/axi_vip_axi4pc.sv" \ "B:/Xilinx/Vivado/2018.3/data/xilinx_vip/hdl/xil_common_vip_pkg.sv" \ "B:/Xilinx/Vivado/2018.3/data/xilinx_vip/hdl/axi4stream_vip_pkg...
{"hexsha": "28944f8b0b48a6b06fe06baa23491a991a8ae68e", "size": 3470, "ext": "f", "lang": "FORTRAN", "max_stars_repo_path": "CNN_HW.ip_user_files/sim_scripts/CNN_top_module/ies/run.f", "max_stars_repo_name": "awe777/CNN_HW", "max_stars_repo_head_hexsha": "c677e5969c235aa8f5f9cf34da71a5fbe61dcd90", "max_stars_repo_licens...
from __future__ import print_function from asdl.transition_system import GenTokenAction, TransitionSystem, ApplyRuleAction, ReduceAction,score_acts import sys, traceback import numpy as np from common.registerable import Registrable import tqdm cachepredict=[] cachetrue=[] from dependency import nlp from nltk.tree impo...
{"hexsha": "08a6035c2219b4f1db6b7180acba5e960978d7f4", "size": 5862, "ext": "py", "lang": "Python", "max_stars_repo_path": "components/evaluator.py", "max_stars_repo_name": "tomsonsgs/TRAN-MMA-master", "max_stars_repo_head_hexsha": "91bf927c64a8d813ba60ae12e61e8f44830a82cc", "max_stars_repo_licenses": ["Apache-2.0"], "...
## Import the required modules # Check time required import time time_start = time.time() import sys import os import argparse as ap import math import imageio from moviepy.editor import * import numpy as np sys.path.append(os.path.dirname(__file__) + "/../") from scipy.misc import imread, imsave, imresize from s...
{"hexsha": "3ddc11ef37d843205813df5fc7a5913a0a68982e", "size": 12910, "ext": "py", "lang": "Python", "max_stars_repo_path": "video_tracking_sort.py", "max_stars_repo_name": "hiepnth/people-counting-pose", "max_stars_repo_head_hexsha": "8cdaab5281847c296b305643842053d496e2e4e8", "max_stars_repo_licenses": ["Apache-2.0"]...
#!/usr/bin/env python3 """ 2D Ising simulator using Metropolis algorithm Author: Akhlak Mahmood License: MIT Last update: April 18, 2019 """ ## Import modules # ------------------------------------------- import sys import numpy as np import matplotlib.pyplot as plt from matplotlib import animation from...
{"hexsha": "a51625211ec86631f5232753a03b2bbd22be3764", "size": 9026, "ext": "py", "lang": "Python", "max_stars_repo_path": "ising/ising.py", "max_stars_repo_name": "akhlak-mahmood/ising-model-2d", "max_stars_repo_head_hexsha": "69739ef250e5719a6d3f8dccf49e4d81828aaa80", "max_stars_repo_licenses": ["MIT"], "max_stars_co...
import os import json import time import random import warnings from typing import Union, Callable, Tuple, Any from types import MethodType try: import h5py except ModuleNotFoundError: h5py = None import joblib import matplotlib # for version info import numpy as np import pandas as pd try: from scipy.s...
{"hexsha": "a1e0fb4188617c3fd337d5335d7314541708898f", "size": 67256, "ext": "py", "lang": "Python", "max_stars_repo_path": "ai4water/_main.py", "max_stars_repo_name": "csiro-hydroinformatics/AI4Water", "max_stars_repo_head_hexsha": "cdb18bd4bf298f77b381f1829045a1e790146985", "max_stars_repo_licenses": ["MIT"], "max_st...
# File to check that the two different action-value functions (MC estimate and the action-value function in the # estimated MDP) are actually different functions, see Section 3.2.2 in "Evaluation of Safe Policy Improvement with # Soft Baseline Bootstrapping" by Philipp Scholl. import os import sys import numpy as np im...
{"hexsha": "6ac2e55f4721af50cd9966b7c2a9c848e1a0bd45", "size": 3356, "ext": "py", "lang": "Python", "max_stars_repo_path": "auxiliary_tests/difference_in_action_value_functions.py", "max_stars_repo_name": "Philipp238/Safe-Policy-Improvement-Approaches-on-Discrete-Markov-Decision-Processes", "max_stars_repo_head_hexsha"...
#include <boost/asio.hpp> #include <string> #include <sstream> using namespace std; namespace net { namespace { boost::asio::ip::tcp::iostream net; } void connect(const string& addr, int port) { ostringstream oss; oss<<addr<<':'<<port; net.connect(oss.str()); } void sendRaw(const string& data) { net<<data; net....
{"hexsha": "f42aaf5f70a02e4ba32e302b1e82b7076ea17d8e", "size": 413, "ext": "cpp", "lang": "C++", "max_stars_repo_path": "net.cpp", "max_stars_repo_name": "sisu/lib24", "max_stars_repo_head_hexsha": "b1aefdfa37a2e3d9b0b7adf9154a86afbde5f461", "max_stars_repo_licenses": ["WTFPL"], "max_stars_count": 1.0, "max_stars_repo_...
from datetime import datetime import os from urllib.request import urlopen from PIL import Image import tensorflow as tf import numpy as np import matplotlib.pyplot as plt filename = 'model.pb' labels_filename = 'labels.txt' output_layer = 'loss:0' input_node = 'Placeholder:0' graph_def = tf.GraphDef() labels = []...
{"hexsha": "bbd53ce61e904fcbf979a216317965a1cb54b52b", "size": 4353, "ext": "py", "lang": "Python", "max_stars_repo_path": "predict_helpers.py", "max_stars_repo_name": "anthonychu/hackthenorth-ml-workshop", "max_stars_repo_head_hexsha": "849cbbac34cd9e9c0ec1b14d39ca8e598c8b14ce", "max_stars_repo_licenses": ["MIT"], "ma...
! Copyright (c) 2015-2021, the ELSI team. ! All rights reserved. ! ! This file is part of ELSI and is distributed under the BSD 3-clause license, ! which may be found in the LICENSE file in the ELSI root directory. !> !! Determine occupation numbers, chemical potential, and electronic entropy. !! module ELSI_OCC u...
{"hexsha": "2b61c6dcb37dd9a03879a64da0ead195980bd231", "size": 23275, "ext": "f90", "lang": "FORTRAN", "max_stars_repo_path": "src/elsi_occ.f90", "max_stars_repo_name": "ElectronicStructureLibrary/elsi-interface", "max_stars_repo_head_hexsha": "95d2b02ca627e08eea52eea8358fdb44ab0e67e3", "max_stars_repo_licenses": ["BSD...
from ctypes import * import numpy as np import numpy.ctypeslib as npct import os import sys import glob version = str(sys.version_info.major)+str(sys.version_info.minor) class Pos(Structure): _fields_ = [('x', c_float), ('y', c_float), ('z', c_float)] # load the library, using numpy mechanisms _libdir = os.path....
{"hexsha": "acb441f05e46f267025bcaef2daa36d67bb93a07", "size": 2697, "ext": "py", "lang": "Python", "max_stars_repo_path": "CosmAna/Ext_C/libgrid/Loadlibgrid.py", "max_stars_repo_name": "POFK/CosmAna", "max_stars_repo_head_hexsha": "153af155d243e38f64b8bdf79abc496163269219", "max_stars_repo_licenses": ["MIT"], "max_sta...
import numpy as np import numpy.linalg as LA import control class KalmanFilter: """ Kalman Filter for a linear system Parameters ---------- F: State Transition (A matrix) H: Observation Model (B matrix) Q: Process Covariance R: Observation Covariance B: Input Model (Optional) ...
{"hexsha": "180f289c032f22659f65e17153c51c4359a2fe1f", "size": 2202, "ext": "py", "lang": "Python", "max_stars_repo_path": "estimation/KalmanFilter.py", "max_stars_repo_name": "andrelimzs/state-estimation", "max_stars_repo_head_hexsha": "57fa0682bb0933200510ed5dc27d09851d39f3b1", "max_stars_repo_licenses": ["MIT"], "ma...
#include <rem_tree/rem_tree.h> #include <iostream> #include <chrono> #include <NTL/ZZ.h> #include <NTL/vector.h> using namespace std; using namespace NTL; ZZ startFunc(ZZ modProd); int main(){ int startBound = 10; int endBound = 20; Vec<ZZ> A; A.setLength(endBound); Vec<ZZ> m; m.setLength(startBound); for(i...
{"hexsha": "48b80de7463a3bfa6e64ac2fec9159cffda3b339", "size": 779, "ext": "cpp", "lang": "C++", "max_stars_repo_path": "archives/cppfiles/rem_tree/main.cpp", "max_stars_repo_name": "adienes/remainder-tree", "max_stars_repo_head_hexsha": "0aa76214ab6f2a4389ec45a239ea660749989a90", "max_stars_repo_licenses": ["MIT"], "m...
# coding: utf-8 # # Time Optimal Velocity Profiles # # When the maze solver commands that the robot go forward, it can say that it must go forward one or more squares depending on what it knows about the maze. When we don't know what is after the square we pass through, we must be going slow enough to handle any sce...
{"hexsha": "72a46ee4fc3d7611f74be024ef511b2bdc07056c", "size": 7998, "ext": "py", "lang": "Python", "max_stars_repo_path": "docs/ipynb_gen_py/time optimal velocity profiles.py", "max_stars_repo_name": "keionbis/SmartMouse_2018", "max_stars_repo_head_hexsha": "26d548a93c282bca8d550b58609f22ea1910fc78", "max_stars_repo_l...
! RUN: bbc -emit-fir %s -o - | FileCheck %s ! CHECK-LABEL: func @_QPtest1( ! CHECK-SAME: %[[VAL_0:.*]]: !fir.ref<!fir.array<100xf32>>{{.*}}, %[[VAL_1:.*]]: !fir.ref<i32>{{.*}}, %[[VAL_2:.*]]: !fir.ref<i32>{{.*}}, %[[VAL_3:.*]]: !fir.ref<i32>{{.*}}) { ! CHECK: %[[VAL_4:.*]] = arith.constant 100 : index ! CH...
{"hexsha": "3fb34b39ea35367d2bf00409ddb248976bf813f4", "size": 2274, "ext": "f90", "lang": "FORTRAN", "max_stars_repo_path": "flang/test/Lower/associate-construct-2.f90", "max_stars_repo_name": "akashhansda/llvm-project", "max_stars_repo_head_hexsha": "32f146010968ded160f54af464673451ad574135", "max_stars_repo_licenses...
# NMF for dense matrices using NMF function run(algname) # prepare data p = 8 k = 5 n = 100 Wg = abs(randn(p, k)) Hg = abs(randn(k, n)) X = Wg * Hg + 0.1 * randn(p, n) # run NNMF println("Algorithm: $(algname)") println("---------------------------------") r = nnmf(X, k...
{"hexsha": "ac6b1824c0e48a5f910bc15fa0867a617259cb2b", "size": 1461, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "examples/densenmf.jl", "max_stars_repo_name": "UnofficialJuliaMirror/NMF.jl-6ef6ca0d-6ad7-5ff6-b225-e928bfa0a386", "max_stars_repo_head_hexsha": "d753312f4686578879fdeae009ba1250102b1e1f", "max_sta...
""" Code for "Invertible Residual Networks" http://proceedings.mlr.press/v97/behrmann19a.html ICML, 2019 """ import threading import logging import contextlib import numpy import torch import termcolor import torch.backends.cudnn as cudnn import torch.optim as optim from torch.autograd import Variable from torch.utils...
{"hexsha": "37c1174626f8417520492303350131821f7a3921", "size": 22819, "ext": "py", "lang": "Python", "max_stars_repo_path": "CIFAR_main.py", "max_stars_repo_name": "ohadoh-math/invertible-resnet", "max_stars_repo_head_hexsha": "4f05b9d1761c2d46cc05d9748ef3e690f8b9c0b2", "max_stars_repo_licenses": ["MIT"], "max_stars_co...
import os import cv2 import numpy as np import pandas as pd from torchvision.transforms import transforms from torch.utils.data import Dataset from datasets.base_dataset import BaseDataset from utils.augmenters.augment import seg import xml.etree.ElementTree as ET from PIL import Image import matplotlib.pyplot as plt ...
{"hexsha": "5ddc9b6b9f37f411ee3ce8dae34f97bf191bb248", "size": 3065, "ext": "py", "lang": "Python", "max_stars_repo_path": "datasets/CARLA_dataset.py", "max_stars_repo_name": "And1210/AutoencoderTransformer", "max_stars_repo_head_hexsha": "9c6142421d311d34f6a00cb90dd49388e5f1cdff", "max_stars_repo_licenses": ["MIT"], "...
from decimal import Decimal import argparse import matplotlib matplotlib.use('Agg') import matplotlib.pyplot as plt import graph_utils import numpy as np import graph_utils import process_csv import sys def main(args): parser = argparse.ArgumentParser() parser.add_argument('--input-file', dest='input_files', ...
{"hexsha": "786d97d2ef18ac0971363c4909806a1a5ff8fb51", "size": 7252, "ext": "py", "lang": "Python", "max_stars_repo_path": "ipg_distribution_graph.py", "max_stars_repo_name": "j-c-w/EXPCAP_Process", "max_stars_repo_head_hexsha": "33ec7f6fdc8e794261a293d7bba0225b76606012", "max_stars_repo_licenses": ["Apache-2.0"], "max...
import numpy as np from pymongo.errors import DuplicateKeyError from huntsman.drp.utils import mongo from huntsman.drp.utils.ingest import METRIC_SUCCESS_FLAG from huntsman.drp.utils.date import parse_date from huntsman.drp.utils.fits import read_fits_data, read_fits_header, parse_fits_header from huntsman.drp.collec...
{"hexsha": "37869bfc04280b9092a0054512078913663a0db5", "size": 10335, "ext": "py", "lang": "Python", "max_stars_repo_path": "src/huntsman/drp/collection/exposure.py", "max_stars_repo_name": "AstroHuntsman/huntsman-drp", "max_stars_repo_head_hexsha": "00f045ccccc1f7545da491457a2b17b9aabea89a", "max_stars_repo_licenses":...
################################################################## #--------------- Error stats for saved data --------------- # (T. Kent: amttk@leeds.ac.uk) ################################################################## ## generic modules import os import errno import numpy as np import matplot...
{"hexsha": "9c9c2abd255d8b07967ea55699497eaf29ff141b", "size": 10395, "ext": "py", "lang": "Python", "max_stars_repo_path": "analysis_diag_stats.py", "max_stars_repo_name": "tkent198/modRSW_EnKF", "max_stars_repo_head_hexsha": "fc9f0bcc6f753a05fed245d4d2987cd3a34078ad", "max_stars_repo_licenses": ["MIT"], "max_stars_co...
import numpy as np from lassolver.matrices.base import Base class iidGaussian(Base): def __init__(self, M, N, m=0, v=1): super().__init__(M, N) self.A = self.set_matrix(M, N, m, v) def set_matrix(self, row, column, mean, var): """ Return i.i.d(independent and identically distri...
{"hexsha": "d7289c2aa7f58733a0aed36a4f86d9c75f3e89ba", "size": 418, "ext": "py", "lang": "Python", "max_stars_repo_path": "lassolver/matrices/iid_gauss.py", "max_stars_repo_name": "Ken529n/Lassolver", "max_stars_repo_head_hexsha": "f9f6997bf065622fe462b329c5cc99bd20f7d68b", "max_stars_repo_licenses": ["MIT"], "max_star...
''' Script for training DFN on self-driving data... TODO: iterative pruning method proposed by Han 2015 ''' import os import numpy as np import argparse from keras.models import Model, load_model from keras import optimizers from keras.callbacks import EarlyStopping, ModelCheckpoint, Callback from DataGenerator import ...
{"hexsha": "824201cbbe0665b08f16d90041853fcb63b4790f", "size": 3845, "ext": "py", "lang": "Python", "max_stars_repo_path": "transfer/train-dfn.py", "max_stars_repo_name": "paulaksm/feature-transfer", "max_stars_repo_head_hexsha": "0814d1e38691f67d6aa1637235df0b152d0a4b05", "max_stars_repo_licenses": ["MIT"], "max_stars...
using Libdl, Test, OpenBLAS_jll, OpenBLAS32_jll, MKL_jll include("utils.jl") function unpack_loaded_libraries(config::lbt_config_t) libs = LBTLibraryInfo[] idx = 1 lib_ptr = unsafe_load(config.loaded_libs, idx) while lib_ptr != C_NULL push!(libs, LBTLibraryInfo(unsafe_load(lib_ptr), config.num...
{"hexsha": "401a3273e50363095db2c5db5f7248bf2dc9fcb8", "size": 11629, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "test/direct.jl", "max_stars_repo_name": "JuliaLinearAlgebra/libblastrampoline", "max_stars_repo_head_hexsha": "145bb64256c441d11b0a742e38f9ef3f08921e8e", "max_stars_repo_licenses": ["MIT"], "max_s...
####################################################################### import JSON, Conda using Compat using Compat.Unicode: lowercase jupyter="" # remove deps.jl at exit if it exists, in case build.jl fails try ####################################################################### # Make sure Python uses UTF-8 ou...
{"hexsha": "4769e8e506ec1b0f8ec453a9ba309c8260cfc7bb", "size": 4835, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "deps/build.jl", "max_stars_repo_name": "jordancluts/IJulia.jl", "max_stars_repo_head_hexsha": "2211a9c9b6821429254e88c60c6bb1d3c357e863", "max_stars_repo_licenses": ["MIT"], "max_stars_count": null...
""" KorQuAD open 형 데이터 processor 본 스크립트는 다음의 파일을 바탕으로 작성 됨 https://github.com/huggingface/transformers/blob/master/src/transformers/data/processors/squad.py """ import json import logging import os import sys from functools import partial from multiprocessing import Pool, cpu_count import numpy as np from tqdm impo...
{"hexsha": "8a20e48b98a3915cafdd612d4439d5db6d41d3fc", "size": 31335, "ext": "py", "lang": "Python", "max_stars_repo_path": "open_squad_multihead.py", "max_stars_repo_name": "JongSuk1/KorQuad", "max_stars_repo_head_hexsha": "757dccb3cfee887692ec9ee7eec5b9d91b0af5d1", "max_stars_repo_licenses": ["Apache-2.0"], "max_star...
import numpy as np import unittest import networkx as nx from numpy.testing import assert_allclose from graphik.graphs import ProblemGraphRevolute from graphik.robots.robot_base import Robot from graphik.robots import RobotRevolute from graphik.solvers.constraints import get_full_revolute_nearest_point from graphik.so...
{"hexsha": "655b6260d48553e89ec4487bf28f6010af183ba7", "size": 9444, "ext": "py", "lang": "Python", "max_stars_repo_path": "tests/test_sdp_snl.py", "max_stars_repo_name": "utiasSTARS/GraphIK", "max_stars_repo_head_hexsha": "c2d05386bf9f9baf8ad146125bfebc3b73fccd14", "max_stars_repo_licenses": ["MIT"], "max_stars_count"...
module TestTUI #= Remaining problems: - bug in TerminalUserInterfaces.terminal_size() - printing of outputs is cut off. See `paragraph.jl` in TerminalUserInterfaces ToDo: - also track files in `test` directory =# using Glob using Revise using Parameters using Pkg using Suppressor using TerminalUserInterfaces const TU...
{"hexsha": "0cafe92d9939861400c561f003951f99aa957c3b", "size": 2232, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "src/TestTUI.jl", "max_stars_repo_name": "lorenzoh/TestTUI.jl", "max_stars_repo_head_hexsha": "071577764a32d5dad0160dc13307d39582c123e8", "max_stars_repo_licenses": ["MIT"], "max_stars_count": 2, "m...