text
stringlengths
0
1.25M
meta
stringlengths
47
1.89k
from pandas import Series,concat import pandas as pd from matplotlib import pyplot from pandas.plotting import lag_plot from statsmodels.tsa.ar_model import AR from sklearn.metrics import mean_squared_error,mean_absolute_error from IPython.core.pylabtools import figsize import numpy as np #series = Series.from_...
{"hexsha": "b90b8799709665b15a8cfc5f28987eefd95e056e", "size": 6286, "ext": "py", "lang": "Python", "max_stars_repo_path": "compare_model/AM_model/AM.py", "max_stars_repo_name": "syrGitHub/TDAM", "max_stars_repo_head_hexsha": "c66a45a9383681e3a001bacefbbf04b3c471ac47", "max_stars_repo_licenses": ["MIT"], "max_stars_cou...
""" DISTRIBUTION STATEMENT A. Approved for public release. Distribution is unlimited. This material is based upon work supported by the United States Air Force under Air Force Contract No. FA8702-15-D-0001. Any opinions, findings, conclusions or recommendations expressed in this material are those of the autho...
{"hexsha": "857774211862aaedefa15c045f7004d8fc824c6a", "size": 4174, "ext": "py", "lang": "Python", "max_stars_repo_path": "analysis/experiment.py", "max_stars_repo_name": "mit-ll/pact-echo", "max_stars_repo_head_hexsha": "df9a4b53e97b6ed0ccd90dbffe3853850fc28730", "max_stars_repo_licenses": ["MIT"], "max_stars_count":...
// // eigen_utils.hpp // // Created By Davis Blalock on 3/2/16. // Copyright (c) 2016 Davis Blalock. All rights reserved. // #ifndef __EIGEN_UTILS_HPP #define __EIGEN_UTILS_HPP #define EIGEN_DONT_PARALLELIZE // ensure no multithreading #include <Eigen/Dense> #include <unsupported/Eigen/CXX11/Tensor> // =========...
{"hexsha": "1c56cfc709e125c6d404f2a45b94c2aa63fe8825", "size": 912, "ext": "hpp", "lang": "C++", "max_stars_repo_path": "maddness/cpp/src/include/eigen_utils.hpp", "max_stars_repo_name": "joennlae/halutmatmul", "max_stars_repo_head_hexsha": "69340d3386298401d421b0e67dcb0649534b0c12", "max_stars_repo_licenses": ["MIT"],...
# Copyright (c) 2020 The Regents of the University of Michigan # All rights reserved. # This software is licensed under the BSD 3-Clause License. import json import os from collections.abc import Collection, MutableSequence import pytest from signac.synced_collections import SyncedList from signac.synced_collections....
{"hexsha": "3df1774ba5f258761c7d756cd9c2c8fecf29c701", "size": 2662, "ext": "py", "lang": "Python", "max_stars_repo_path": "tests/test_synced_collections/test_utils.py", "max_stars_repo_name": "rohanbabbar04/signac", "max_stars_repo_head_hexsha": "dfc28cbfdd11ea2f2e226f87719f323595e0f4ff", "max_stars_repo_licenses": ["...
********************************************************************** ********************************************************************** integer function poslc(ndum,indlc,lcmax,index) * * used to find actual number of lens OR cell * with index 'ndum' ( searches with ...
{"hexsha": "74ed6cc86e1f4fdaae27a3d9d56cb3cb10d503c3", "size": 3175, "ext": "f", "lang": "FORTRAN", "max_stars_repo_path": "sntd/microlens/poslc.f", "max_stars_repo_name": "srodney/sntd", "max_stars_repo_head_hexsha": "c091e3ce76fcb6a73d31eb2a719bbb4fc649016c", "max_stars_repo_licenses": ["BSD-3-Clause"], "max_stars_co...
from __future__ import annotations import warnings import numpy as np import pandas as pd import pytest from pandas.tseries.frequencies import to_offset import xarray as xr from xarray import DataArray, Dataset, Variable from xarray.core.groupby import _consolidate_slices from . import ( assert_allclose, as...
{"hexsha": "f0b16bc42c76131d820d5092eb512b2f12675d3f", "size": 71007, "ext": "py", "lang": "Python", "max_stars_repo_path": "xarray/tests/test_groupby.py", "max_stars_repo_name": "ianthomas23/xarray", "max_stars_repo_head_hexsha": "aa1d1d19b822897399c8ed2cf346afbac71f45b3", "max_stars_repo_licenses": ["Apache-2.0"], "m...
from typing import Optional from copy import copy import numpy as np import torch import torch.nn as nn from torch.utils.data import DataLoader, TensorDataset from scipy import stats from scipy.special import inv_boxcox, boxcox from statsmodels.tsa.api import STLForecast from statsmodels.tsa.ar_model import AutoReg fr...
{"hexsha": "27bc831133614dcba1b95fd285942d75c4d91634", "size": 23180, "ext": "py", "lang": "Python", "max_stars_repo_path": "fedot/core/operations/evaluation/operation_implementations/models/ts_implementations.py", "max_stars_repo_name": "rozlana-g/FEDOT", "max_stars_repo_head_hexsha": "a909d6c0ef481cc1cf7a5f10f7b1292d...
import numpy as np import urllib.request import os.path class Dataset: # TODO test def normalize(self, x, train_min=None, train_max=None): if train_min is None: train_min = np.min(x) if train_min > 0: x -= train_min if train_max is None: train_max ...
{"hexsha": "a7a46e32d8dade9c2510f4f8857dd52568de1974", "size": 3392, "ext": "py", "lang": "Python", "max_stars_repo_path": "implementations-from-scratch/dataset/dataset.py", "max_stars_repo_name": "georgepachitariu/machine-learning-portfolio", "max_stars_repo_head_hexsha": "47452524b0f2ccf409ba12e6a717157e569d62e1", "m...
[STATEMENT] lemma update_arg_wf_tuples' [elim]: "\<And>n hops nhip pre. Suc 0 \<le> n \<Longrightarrow> update_arg_wf (n, kno, val, hops, nhip, pre)" [PROOF STATE] proof (prove) goal (1 subgoal): 1. \<And>n hops nhip pre. Suc 0 \<le> n \<Longrightarrow> update_arg_wf (n, kno, val, hops, nhip, pre) [PROOF STEP] unfo...
{"llama_tokens": 346, "file": "AODV_variants_a_norreqid_A_Aodv_Data", "length": 2}
from pydicom import dcmread from numpy import zeros from matplotlib.pyplot import figure, imshow, show, subplot from sys import argv from glob import glob # load the DICOM files def read_slices(paths): files = [dcmread(fname) for fname in paths] print("file c...
{"hexsha": "4a2e185893e81e202f614ae17d82034fc3bc9279", "size": 1589, "ext": "py", "lang": "Python", "max_stars_repo_path": "reslice.py", "max_stars_repo_name": "weka511/rsna", "max_stars_repo_head_hexsha": "3414137e8373d8e1614921e2e1f416aaec8abd82", "max_stars_repo_licenses": ["MIT"], "max_stars_count": null, "max_star...
SUBROUTINE RDFIL (UNIT,INST,CLEN,NCOL,NOFILE) C IMPLICIT INTEGER(A-Z) LOGICAL NOFILE DIMENSION BUF(128) C CALL XVUNIT (UNIT,'INP',INST,STATUS,' ') NOFILE = STATUS.NE.1 IF (.NOT.NOFILE) THEN CALL XVOPEN (UNIT,STATUS,'OP','UPDATE', + 'OPEN_ACT','SA', 'IO_ACT','SA',' ') CALL XVREAD (UNIT,BUF,STATUS,' ...
{"hexsha": "c86df59e2dad8957f18e9dea57f4326c6368a4f9", "size": 3134, "ext": "f", "lang": "FORTRAN", "max_stars_repo_path": "vos/p3/sub/ibisfil/ibisfil.f", "max_stars_repo_name": "NASA-AMMOS/VICAR", "max_stars_repo_head_hexsha": "4504c1f558855d9c6eaef89f4460217aa4909f8e", "max_stars_repo_licenses": ["BSD-3-Clause"], "ma...
""" utilities functions for dcase submission format """ import numpy as np def load_output_format_file(_output_format_file, version='2021'): """ copy from cls_feature_class: remove class params Loads DCASE output format csv file and returns it in dictionary format can load both polar and xyz format ...
{"hexsha": "f1894fa691aec26f0eb5b01f84f1b54600e66c99", "size": 14512, "ext": "py", "lang": "Python", "max_stars_repo_path": "metrics/dcase_utils.py", "max_stars_repo_name": "thomeou/SALSA", "max_stars_repo_head_hexsha": "30bc6b8c758fc7355a2649ec695db44da22e7feb", "max_stars_repo_licenses": ["MIT"], "max_stars_count": 2...
c********************************************************************* c c molecular matching program c c copyright daresbury laboratory c author w.smith march 2004 c c********************************************************************* implicit none integer, parameter :: npass=10 ...
{"hexsha": "506c6b5b269bce8f136ccdf609ed08fab646c1dc", "size": 12279, "ext": "f", "lang": "FORTRAN", "max_stars_repo_path": "utility/matchup.f", "max_stars_repo_name": "zzalscv2/DL_POLY_Classic", "max_stars_repo_head_hexsha": "f2712ca1cdddd154f621f9f5a3c2abac94e41e58", "max_stars_repo_licenses": ["BSD-3-Clause"], "max_...
import numpy def histogram(image, bitDepth=8): """ title:: histogram_where description:: This method will generate the histogram, probability density funciton, and the cumulative density funciton of an image. It will use the numpy.where function from the numpy library to ...
{"hexsha": "5df13004d941fba2d8cbe521fb1cf777d8e61bef", "size": 6348, "ext": "py", "lang": "Python", "max_stars_repo_path": "computing_and_control/ipcv/histogram_where.py", "max_stars_repo_name": "aap5869/RIT", "max_stars_repo_head_hexsha": "d8a408e59a94b0edde56a207592fd7b803172119", "max_stars_repo_licenses": ["MIT"], ...
% PURPOSE: demo of chowlin() % Temporal disaggregation with indicators. % Chow-Lin method %--------------------------------------------------- % USAGE: chowlin_d %--------------------------------------------------- close all; clear all; clc; % Low-frequency data: Spain's Exports of Goods. 1995 prices Y...
{"author": "Sable", "repo": "mcbench-benchmarks", "sha": "ba13b2f0296ef49491b95e3f984c7c41fccdb6d8", "save_path": "github-repos/MATLAB/Sable-mcbench-benchmarks", "path": "github-repos/MATLAB/Sable-mcbench-benchmarks/mcbench-benchmarks-ba13b2f0296ef49491b95e3f984c7c41fccdb6d8/39770-temporal-disaggregation-library/chowli...
# Copyright (C) 2020. Huawei Technologies Co., Ltd. All rights reserved. # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to us...
{"hexsha": "d495c87d565221e477cd4c9b6a5b79a424392c55", "size": 8573, "ext": "py", "lang": "Python", "max_stars_repo_path": "zoo/policies/cross-rl-agent/cross_rl_agent/train/run_test.py", "max_stars_repo_name": "idsc-frazzoli/SMARTS", "max_stars_repo_head_hexsha": "bae0a6ea160330921edc94a7161a4e8cf72a1974", "max_stars_r...
from .rules import Rules from .player import Player from .plot import Plotter import pickle import networkx as nx import pandas as pd from enum import Enum class Metrics(Enum): # warning round_number > 0 macro_degree_assortativity_coefficient = "macro_degree_assortativity_coefficient" # macro_rich_club...
{"hexsha": "f44688fd958a28ae07efad9cdafc957f1d6688a6", "size": 9174, "ext": "py", "lang": "Python", "max_stars_repo_path": "centrality/game.py", "max_stars_repo_name": "halsabah/Betweeness_Centality_Competition", "max_stars_repo_head_hexsha": "4ebbd11c30f704e2ccd4dd0d1b9baf52a877cfeb", "max_stars_repo_licenses": ["BSD-...
# Importing the required packages import numpy as np import pandas as pd from sklearn.metrics import confusion_matrix from sklearn.model_selection import train_test_split from sklearn.tree import DecisionTreeClassifier from sklearn import tree from sklearn.metrics import accuracy_score from sklearn.metrics import...
{"hexsha": "d45d41889a134f43991921ae4f00e4cc562bfd42", "size": 3582, "ext": "py", "lang": "Python", "max_stars_repo_path": "Daily Python/23_DecisionTree/23_DecisionTree.py", "max_stars_repo_name": "Harjiwan/Python", "max_stars_repo_head_hexsha": "5f8e0b7f4f2323c64161541075636eefc41043b9", "max_stars_repo_licenses": ["M...
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not u...
{"hexsha": "533174059e66049453c78e0d4c3e263fece64d25", "size": 38475, "ext": "py", "lang": "Python", "max_stars_repo_path": "python/tvm/contrib/target/onnx.py", "max_stars_repo_name": "ZihengJiang/relax", "max_stars_repo_head_hexsha": "5676ffa4c423adf2b3f1920c5fdaca43369e9855", "max_stars_repo_licenses": ["Apache-2.0"]...
// Copyright (C) 2007, 2008, 2009 Tim Blechmann & Thomas Grill // // 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) // Disclaimer: Not a Boost library. #ifndef BOOST_LOCKFREE_CAS_HPP_INCLUDED #define BOOST_L...
{"hexsha": "567358473f9cf3ea8e9059e93f0e2fcc19768a6b", "size": 5850, "ext": "hpp", "lang": "C++", "max_stars_repo_path": "common/include/boost/lockfree/detail/cas.hpp", "max_stars_repo_name": "marshallmcmullen/pion", "max_stars_repo_head_hexsha": "7dcbe769e7076f5cc983bb4a5b5d2bc83cadb3a2", "max_stars_repo_licenses": ["...
""" omg: Omics Mock Generator Generates a mock dataset of omics data (importable in EDD): transcriptomics, proteomics, and metabolomics Requirements: Python 3.7.2, cobra, numpy, pandas. """ __author__ = 'LBL-QMM' __copyright__ = 'Copyright (C) 2019 Berkeley Lab' __license__ = '' __status__ = 'Alpha' __date__ = 'Dec ...
{"hexsha": "b4899439dac98fbdd0e9a91d0e9d4b1d91f6f4d9", "size": 52007, "ext": "py", "lang": "Python", "max_stars_repo_path": "omg.py", "max_stars_repo_name": "somtirtharoy/generate_test_omics_data", "max_stars_repo_head_hexsha": "efc22faaf98faf92f2a96e4a2dc93f4204015044", "max_stars_repo_licenses": ["BSD-3-Clause-LBNL"]...
#include <iostream> #include <boost/bind.hpp> #include <boost/asio.hpp> #include <boost/date_time/posix_time/posix_time.hpp> void expireCallback(const boost::system::error_code& /*e*/) { std::cout << "Hello from expireCallback" << std::endl; } void printCallback(const boost::system::error_code& /*e*/, ...
{"hexsha": "1fe690fcec614a5045cb237bb2a5f5792db87973", "size": 1777, "ext": "cpp", "lang": "C++", "max_stars_repo_path": "Networking/testBoostAsio.cpp", "max_stars_repo_name": "drbenmorgan/codingtools", "max_stars_repo_head_hexsha": "65040e7ecc1276a8d8a74f09cd0344160130bd48", "max_stars_repo_licenses": ["BSD-3-Clause"]...
# USAGE # python convert_winco_receipt.py --image images/page.jpg --scanned images/page_scanned.jpg # import the necessary packages from pyimagesearch.transform import four_point_transform from pyimagesearch import imutils from skimage.filters import threshold_adaptive import numpy as np import argparse import cv2 fr...
{"hexsha": "da0ec82becf348dde4d79e9e65fcf9f7cbf596e7", "size": 3882, "ext": "py", "lang": "Python", "max_stars_repo_path": "ReceiPy/document-scanner/scan_bkp.py", "max_stars_repo_name": "philipguedes/tocapopy", "max_stars_repo_head_hexsha": "79e58aafbb606d883d3c2b0df098ecfdecc35931", "max_stars_repo_licenses": ["MIT"],...
from dash import Dash, dcc, html from dash.dependencies import Input, Output import dash_bootstrap_components as dbc import pandas as pd import numpy as np from src.SideBar import sidebar import src.SummaryTab as SummaryTab import src.CountTab as CountTab import src.TimesTab as TimesTab # Load data # Data for first ...
{"hexsha": "93254183eb6ec229e44b12d2ec2f5ed1e0920200", "size": 5676, "ext": "py", "lang": "Python", "max_stars_repo_path": "src/app.py", "max_stars_repo_name": "ubco-mds-2021-labs/dashboard1-group-f", "max_stars_repo_head_hexsha": "9de5ffc12974ff0f2f1b0585e3c81410578ed41d", "max_stars_repo_licenses": ["MIT"], "max_star...
{-# OPTIONS --without-K --safe #-} open import Relation.Binary using (Rel) module Algebra.Structures.Field {a ℓ} {A : Set a} (_≈_ : Rel A ℓ) where open import Algebra.Linear.Core open import Relation.Nullary using (¬_) open import Algebra.Structures _≈_ open import Algebra.FunctionProperties _≈_ open import...
{"hexsha": "9de497b077e85ca77fd2819d7a9a975d7002ab1d", "size": 1053, "ext": "agda", "lang": "Agda", "max_stars_repo_path": "src/Algebra/Structures/Field.agda", "max_stars_repo_name": "felko/linear-algebra", "max_stars_repo_head_hexsha": "d87c5a1eb5dd0569238272e67bce1899616b789a", "max_stars_repo_licenses": ["MIT"], "ma...
import matplotlib.pyplot as plt import numpy as np from comb_step_ramp import comb_step_ramp t = np.arange(-10, 10,0.01) 'TIME SCALING BY t/2' x=[] comb_step_ramp(t/2,x) plt.subplot(2,2,1) plt.step(t,x) plt.axhline(0, color='black') plt.axvline(0, color='black') plt.xlabel('time') plt.ylabel('function ...
{"hexsha": "88c45c52fa04aa9d037be5ec798d4045fdeddebd", "size": 974, "ext": "py", "lang": "Python", "max_stars_repo_path": "Signal Processing/CODES/5th.6th.7th.py", "max_stars_repo_name": "Pavan1199/Python-Signal-Processing", "max_stars_repo_head_hexsha": "9164bb76305a149d65d32ea89abebf368a1e6d65", "max_stars_repo_licen...
import numpy as np import pandas as pd from collections import defaultdict import math from sklearn.cluster import KMeans, AgglomerativeClustering SORTED_GROUP = ['Consensus', 'BPS-C', 'BPS-NC', 'UNI', 'PPM', 'Bandit-0', 'Bandit-1'] def sort_kernel_matrix(df, feature_kernel, kmeans_based_on='label_distance'): gro...
{"hexsha": "9c9d866405994823e36c1abd05a0841eadaa69fe", "size": 3934, "ext": "py", "lang": "Python", "max_stars_repo_path": "synbio_rbs/src/sort_seq.py", "max_stars_repo_name": "mholowko/Solaris", "max_stars_repo_head_hexsha": "25f65e72667f1e92e0d5c26bc9cbe159a6a15ace", "max_stars_repo_licenses": ["Apache-2.0"], "max_st...
# =============================================================================== # Copyright 2012 Jake Ross # # 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/licens...
{"hexsha": "ab0f972bf6b6de2e1dda7786098b1d331f790c7a", "size": 24596, "ext": "py", "lang": "Python", "max_stars_repo_path": "pychron/graph/regression_graph.py", "max_stars_repo_name": "UManPychron/pychron", "max_stars_repo_head_hexsha": "b84c9fd70072f9cbda30abe2c471e64fe3dd75d8", "max_stars_repo_licenses": ["Apache-2.0...
"""Test cases for SaveDetectionSamples.""" import json import logging import os import shutil import numpy as np from ambianic.pipeline.store import JsonEncoder, SaveDetectionSamples from ambianic.pipeline.timeline_event import PipelineContext from PIL import Image log = logging.getLogger(__name__) def test_json_en...
{"hexsha": "bcebff4fef2575448155fff75679555cf4a95819", "size": 13800, "ext": "py", "lang": "Python", "max_stars_repo_path": "tests/pipeline/test_store.py", "max_stars_repo_name": "vickywane/ambianic-edge", "max_stars_repo_head_hexsha": "45505eb42f27690646535206a1fb92624b9264c7", "max_stars_repo_licenses": ["Apache-2.0"...
using ArgParse include("clustering.jl") include("datasets.jl") settings = ArgParseSettings() @add_arg_table settings begin "--problem" arg_type = String default = "iris" "--fname" arg_type = String default = "lif" "--seed" arg_type = Int default = 0 "--logfile" arg_type = St...
{"hexsha": "bd0d38b5604d2eaf6ea785a0b70176dbad2aeb93", "size": 1828, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "src/run_cluster.jl", "max_stars_repo_name": "d9w/rm-stdp", "max_stars_repo_head_hexsha": "d62916feadbb450c5462c488a03e009aa164199f", "max_stars_repo_licenses": ["Apache-2.0"], "max_stars_count": 1,...
[STATEMENT] lemma filterlim_tendsto_pos_mult_at_bot: fixes c :: real assumes "(f \<longlongrightarrow> c) F" "0 < c" "filterlim g at_bot F" shows "LIM x F. f x * g x :> at_bot" [PROOF STATE] proof (prove) goal (1 subgoal): 1. LIM x F. f x * g x :> at_bot [PROOF STEP] using filterlim_tendsto_pos_mult_at_top[OF as...
{"llama_tokens": 367, "file": null, "length": 3}
import argparse import json import logging import os import os.path as osp import random import sys import time from collections import Counter from collections import defaultdict from collections import namedtuple import cvxpy as cp import matplotlib.pyplot as plt import numpy as np import torch from scipy.sparse imp...
{"hexsha": "03531c6f65e952a72752cf019b160d1059ac2400", "size": 12898, "ext": "py", "lang": "Python", "max_stars_repo_path": "latency.py", "max_stars_repo_name": "bermanmaxim/AOWS", "max_stars_repo_head_hexsha": "2b9efefd426eebfcefb4b0c09f2683d3a0700951", "max_stars_repo_licenses": ["MIT"], "max_stars_count": 38, "max_s...
import numpy as np def insert(x, n): x[0] = 3 x = np.concatenate([x, [1]], axis = 0) n = 3 print(x) return def a(): n = 1 x = np.array([0, 1, 2]) insert(x,n) print(x, n) if __name__ == "__main__": a()
{"hexsha": "38dfedb431ca533f2bd3af9e84e9948b0bac6cee", "size": 242, "ext": "py", "lang": "Python", "max_stars_repo_path": "model_raisim/Dribble_Control/DRMpc_Arm/test.py", "max_stars_repo_name": "Stylite-Y/XArm-Simulation", "max_stars_repo_head_hexsha": "654dca390e635b6294a8b5066727d0f4d6736eb1", "max_stars_repo_licens...
#%% import numpy as np import pandas as pd data = pd.read_csv('./processed/IUCN_class_order_extinctions.csv') bg_rate = 2 # E / MSY years = 520 # since 1500 expected_per_10k_per_c = bg_rate * years/100 # Melt on kingdom and name melted = data.melt(['kingdom', 'class_order'], var_name='assessment', value_name='number')...
{"hexsha": "91838772e2657c43368337c10f3ea6beccdd7714", "size": 2108, "ext": "py", "lang": "Python", "max_stars_repo_path": "data/flora_fauna/IUCN_species_extinction/calculate_extinction_rates.py", "max_stars_repo_name": "ilopezgp/human_impacts", "max_stars_repo_head_hexsha": "b2758245edac0946080a647f1dbfd1098c0f0b27", ...
// Copyright (C) 2009-2020 Christian@Schladetsch.com // // Distributed under the Boost Software License, Version 1.0. (See accompanying // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #ifndef BOOST_MONOTONIC_RECLAIMABLE_STORAGE_HPP #define BOOST_MONOTONIC_RECLAIMABLE_STORAGE_HPP #include <a...
{"hexsha": "a15fb65794016ed5d962d1ac316429567a3eb046", "size": 6263, "ext": "hpp", "lang": "C++", "max_stars_repo_path": "boost/monotonic/reclaimable_storage.hpp", "max_stars_repo_name": "cschladetsch/Monotonic", "max_stars_repo_head_hexsha": "ec37c3743862475719fdc8d2c3820fc0ab43c55a", "max_stars_repo_licenses": ["BSL-...
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Sat Dec 1 20:27:19 2018 @author: jiahan """ import scipy as sc from scipy.fftpack import fft2, ifft2 import matplotlib.pyplot as plt def Spectral_Gradient(nx, ny, lx, ly): # Create wavenumber vector for x-direction tmp1 = sc.linspace(0, nx/2, in...
{"hexsha": "9404003c2f16e3cee3ed8ac4520f9006553b176b", "size": 5170, "ext": "py", "lang": "Python", "max_stars_repo_path": "IncompNST_Tools/Pseudospectral.py", "max_stars_repo_name": "JiahanBro/DMD_Test", "max_stars_repo_head_hexsha": "f3bac6a63c61e99a2504ed7886c2ea5d8ebd8a8d", "max_stars_repo_licenses": ["MIT"], "max_...
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved. # # This source code is licensed under the MIT license found in the # LICENSE file in the root directory of this source tree. from dataclasses import dataclass from typing import Callable, Optional, Tuple, Union import numpy as np import torch Re...
{"hexsha": "636a8d8a5d0603aeb051e59d784d6d7f368e7df8", "size": 1396, "ext": "py", "lang": "Python", "max_stars_repo_path": "mbrl/types.py", "max_stars_repo_name": "KevinHuang8/CEMGD", "max_stars_repo_head_hexsha": "9c7668264e40904d679e4f22f214a4d7951ce3a4", "max_stars_repo_licenses": ["MIT"], "max_stars_count": 3, "max...
#!/usr/bin/env python # Copyright (c) 2019 Computer Vision Center (CVC) at the Universitat Autonoma de # Barcelona (UAB). # # Copyright (c) 2021 FrostBit Software Lab # This work is licensed under the terms of the MIT license. # For a copy, see <https://opensource.org/licenses/MIT>. import glob import os import sys...
{"hexsha": "d6ac914868180e20871164d170ba0f630bc45c0e", "size": 9366, "ext": "py", "lang": "Python", "max_stars_repo_path": "PythonAPI/wintersim_examples/sensors/open3d_lidar_window.py", "max_stars_repo_name": "FrostBit-Software-Lab-Lapland-UAS/carla", "max_stars_repo_head_hexsha": "079d7c4057d4787568b2e1d3a4fd427c38177...
import matplotlib.pyplot as plt import numpy as np import pandas as pd from skimage import measure from skimage.measure import compare_ssim import seaborn as sns import os import datetime import json working_dir = os.getcwd() try: os.mkdir(working_dir+"/plots") except: pass plot_dir = working_dir+"/plots/" d...
{"hexsha": "5dd4c6c8637a67da1e39bc707a005cfc18a33176", "size": 6675, "ext": "py", "lang": "Python", "max_stars_repo_path": "Source Code/Back-end/visualizer.py", "max_stars_repo_name": "Arrow023/D6", "max_stars_repo_head_hexsha": "42468664c4568abb5c6135a6c4425e0aa63df4e2", "max_stars_repo_licenses": ["MIT"], "max_stars_...
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % Wilson Resume/CV % XeLaTeX Template % Version 1.0 (22/1/2015) % % This template has been downloaded from: % http://www.LaTeXTemplates.com % % Original author: % Howard Wilson (https://github.com/watsonbox/cv_template_2004) with % extensive modifications by Vel (vel@latextempl...
{"hexsha": "7978e3ec25b860f9402a086280223b6d05bcd5fb", "size": 12951, "ext": "tex", "lang": "TeX", "max_stars_repo_path": "resume.tex", "max_stars_repo_name": "r-ballard/r-ballard.github.io", "max_stars_repo_head_hexsha": "55b3a750db1ea61b2414f328706f67efb29ec39a", "max_stars_repo_licenses": ["MIT"], "max_stars_count":...
from ..common.event import EventDispatcher from ..common.events import * from ..engine.vector import Vector from ..input.image_input import ImageInput from multiprocessing import Process, Pipe, Pool import copy import time import operator import numpy as np import math import time def processYImage(img): results ...
{"hexsha": "9c488797e2e806780635fdd0dd42a31bbc872fb1", "size": 11883, "ext": "py", "lang": "Python", "max_stars_repo_path": "core/input/image_process.py", "max_stars_repo_name": "yuwilbur/birthday29", "max_stars_repo_head_hexsha": "7a2c8069639b27b20bc0903d2cf6c212b398b4d9", "max_stars_repo_licenses": ["MIT"], "max_star...
''' Created on @author: Mark ''' import random import numpy from scipy import linalg def uniformPoints(size): return [(random.uniform(-1., 1.), random.uniform(-1., 1.)) for i in range(size)] class Coin(object): def __init__(self, p=.5): self.p = p def flip(self): return random.random() >= self...
{"hexsha": "52242fa5e7e356aeb079f873c74f6438299910a6", "size": 3972, "ext": "py", "lang": "Python", "max_stars_repo_path": "Final/Python/by_Mark_B2/hw2.py", "max_stars_repo_name": "freeernest/edX-Learning-From-Data-Solutions", "max_stars_repo_head_hexsha": "5cbcf0885b5fdb00c3658d230fc7bb7e20b5cf44", "max_stars_repo_lic...
\documentclass{article} \usepackage{a4wide} \usepackage{amsmath} \usepackage[colorlinks=true,linkcolor=blue,citecolor=blue]{hyperref} \usepackage[sort&compress,comma,authoryear]{natbib} \newcommand{\Prob}[0]{\mbox{Prob}} \newcommand{\ul}[1]{\underline{#1}} \newcommand{\ol}[1]{\overline{#1}} \usepackage{bm} \usepackage{...
{"hexsha": "942c7303379e3be8cbed8e5f5f0bd1dbde36b58f", "size": 2798, "ext": "tex", "lang": "TeX", "max_stars_repo_path": "docs/models/hex.tex", "max_stars_repo_name": "add-my-pet/AmPtool-new", "max_stars_repo_head_hexsha": "f60cdd10c65c0190ca41ba6fbd4d5018c5aea771", "max_stars_repo_licenses": ["0BSD"], "max_stars_count...
[STATEMENT] lemma line_through_K2_intersect_S_again: assumes "p \<in> K2" and "proj2_incident p l" shows "\<exists> r. r \<noteq> q \<and> r \<in> S \<and> proj2_incident r l" [PROOF STATE] proof (prove) goal (1 subgoal): 1. \<exists>r. r \<noteq> q \<and> r \<in> S \<and> proj2_incident r l [PROOF STEP] proof - [...
{"llama_tokens": 2350, "file": "Tarskis_Geometry_Hyperbolic_Tarski", "length": 21}
import numpy as np import random from bokeh.layouts import column, row from bokeh.models import CustomJS, Slider from bokeh.plotting import ColumnDataSource, figure, output_file, show def behroozi10(logmstar, theta): """ This function calculates the B10 stellar to halo mass relation using the functional ...
{"hexsha": "cc8a23766add72765de9015a19900d1e8943e43a", "size": 3012, "ext": "py", "lang": "Python", "max_stars_repo_path": "src/tutorials/smhm_widget.py", "max_stars_repo_name": "MehnaazAsad/RESOLVE_Statistics", "max_stars_repo_head_hexsha": "a7bdcc896ca2c51ab3417c46f07efe8c16825597", "max_stars_repo_licenses": ["MIT"]...
import moderngl import numpy as np from pyrr import Matrix44 class Renderer: def __init__(self, ctx): self.program = ctx.program(vertex_shader=""" #version 330 uniform mat4 model; in vec2 in_vert; in vec3 in_color; out vec3 color; vo...
{"hexsha": "7689aac072df1802ec5e3ebce396a86dffe7f9bc", "size": 1639, "ext": "py", "lang": "Python", "max_stars_repo_path": "Vtuber-breadcrumbs/handsTracking/renderer.py", "max_stars_repo_name": "kirinokirino/Github-cleanup", "max_stars_repo_head_hexsha": "f1e5239536d4233aa86b1427420ec0a9915aada1", "max_stars_repo_licen...
from __future__ import annotations import networkx as nx from .node import VNode, CNode import numpy as np import numpy.typing as npt from typing import Callable class TannerGraph: def __init__(self): self.v_nodes: dict[int, VNode] = {} self.c_nodes: dict[int, CNode] = {} self.edges = set(...
{"hexsha": "578027071ae029687f838e65685370ec36d5b050", "size": 4630, "ext": "py", "lang": "Python", "max_stars_repo_path": "belief_propagation/graph.py", "max_stars_repo_name": "YairMZ/belief_propagation", "max_stars_repo_head_hexsha": "a8a6ed2821772c5792cf28e60d19c8b7055ec3c8", "max_stars_repo_licenses": ["MIT"], "max...
[STATEMENT] lemma "steps0 (1, [], []) tm_semi_id_eq0 3 = (1, [], [Bk])" [PROOF STATE] proof (prove) goal (1 subgoal): 1. steps0 (1, [], []) tm_semi_id_eq0 3 = (1, [], [Bk]) [PROOF STEP] by (simp add: step.simps steps.simps numeral_eqs_upto_12 tm_semi_id_eq0_def)
{"llama_tokens": 133, "file": "Universal_Turing_Machine_SemiIdTM", "length": 1}
# Copyright (c) 2020 PaddlePaddle Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by appli...
{"hexsha": "0bb1c8adbc80d75ecc15a2d59531ccf07a2424db", "size": 4801, "ext": "py", "lang": "Python", "max_stars_repo_path": "model_zoo/gpt/deploy/python/inference.py", "max_stars_repo_name": "mukaiu/PaddleNLP", "max_stars_repo_head_hexsha": "0315365dbafa6e3b1c7147121ba85e05884125a5", "max_stars_repo_licenses": ["Apache-...
import timeit import pandas as pd import matplotlib.pyplot from sklearn.linear_model import base from sklearn.linear_model import LinearRegression import matplotlib.pyplot as plt from line_profiler import LineProfiler import numpy as np from utility import ols_lstsq, ols_sklearn # We learn that #https://github.com/sc...
{"hexsha": "ef854e8c8c5120433d11a1b255f3e701dc701f2b", "size": 1851, "ext": "py", "lang": "Python", "max_stars_repo_path": "06. Chapter_6/pandas/sklearn_line_profiler.py", "max_stars_repo_name": "Mikma03/High-performance-Python", "max_stars_repo_head_hexsha": "b7720377bc967e856e16678ae91b37c2503b49e0", "max_stars_repo_...
import numpy as np from sklearn.model_selection import train_test_split x_noraml = np.loadtxt(r'Samples\x_normal') y_normal = np.loadtxt(r'Samples\y_normal') x_inner = np.loadtxt(r'Samples\x_inner') y_inner = np.loadtxt(r'Samples\y_inner') x_roll = np.loadtxt(r'Samples\x_roll') y_roll = np.loadtxt(r'Sample...
{"hexsha": "72d05e8fc0eeb6f1398737a01cb29374ad5c835c", "size": 1309, "ext": "py", "lang": "Python", "max_stars_repo_path": "train_test_split.py", "max_stars_repo_name": "littlelittlewhite09/Bearing_Fault_recognition", "max_stars_repo_head_hexsha": "e33713005f632c356e859f9828fcfeff76dc8320", "max_stars_repo_licenses": [...
vis = Visualizer() open(vis) # ## model include("trajopt_model_v2.jl") # ## horizon h = 0.05 T = 135 Tm = 15 # mid point for a swing / stance change # ## centroidal_quadruped s = get_simulation("centroidal_quadruped", "flat_3D_lc", "flat") model = s.model env = s.env nx = 2 * model.nq nc = 4 #model.nc nu = model.n...
{"hexsha": "61bcaea345d4ee25a2c8c0440f77ee2b3706bd99", "size": 10067, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "examples/centroidal_quadruped_box/reference/step_over_box.jl", "max_stars_repo_name": "thowell/ContactImplicitMPC.jl", "max_stars_repo_head_hexsha": "6226c93521362b32235a53bc22e573a27f28fda8", "ma...
# from tensorflow import logging as tf_logging from argo.core.hooks.EveryNEpochsTFModelImagesHook import EveryNEpochsTFModelImagesHook from argo.core.argoLogging import get_logger tf_logging = get_logger() import numpy as np from argo.core.utils.ImagesSaver import ImagesSaver from datasets.Dataset import check_data...
{"hexsha": "a151bfa6afcba76105eb588bec9e4359825f27a5", "size": 3867, "ext": "py", "lang": "Python", "max_stars_repo_path": "core/LatentTraversalsHook.py", "max_stars_repo_name": "rist-ro/argo", "max_stars_repo_head_hexsha": "a10c33346803239db8a64c104db7f22ec4e05bef", "max_stars_repo_licenses": ["MIT"], "max_stars_count...
import json import os import pathlib import networkx as nx import numpy as np from itertools import product, permutations, combinations from functools import reduce import operator from tqdm import tqdm from core.variable import Variable from core.constraint import Constraint from core.agent import Agent class DCOPIn...
{"hexsha": "1e1418311c828a53a2beea258300b4cbe24f9249", "size": 8633, "ext": "py", "lang": "Python", "max_stars_repo_path": "src/core/dcop_instance.py", "max_stars_repo_name": "nandofioretto/py_dcop", "max_stars_repo_head_hexsha": "fb2dbc97b69360f5d1fb67d84749e44afcdf48c3", "max_stars_repo_licenses": ["Apache-2.0"], "ma...
// // Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) // // 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) // // Official repository: https://github.com/boostorg/beast // // Test that header ...
{"hexsha": "11bb263857f20ac7d7bbcaff794bb4aefd30ef9a", "size": 5123, "ext": "cpp", "lang": "C++", "max_stars_repo_path": "deps/boost/libs/beast/test/beast/core/buffers_prefix.cpp", "max_stars_repo_name": "alexhenrie/poedit", "max_stars_repo_head_hexsha": "b9b31a111d9e8a84cf1e698aff2c922a79bdd859", "max_stars_repo_licen...
import numpy as _np # TODO: Documentation! def Get_CLVD_DC(Full_Moment): M = Full_Moment # isotropic part M_iso = _np.diag( _np.array([1.0 / 3 * _np.trace(M), 1.0 / 3 * _np.trace(M), 1.0 / 3 * _np.trace(M)]) ) M0_iso = abs(1.0 / 3 * _np.trace(M)) # deviatoric part M_devi = M - M_...
{"hexsha": "6c2a6741f7a2c900644a9b3137988cc11dd50388", "size": 4326, "ext": "py", "lang": "Python", "max_stars_repo_path": "SS_MTI/MTDecompose.py", "max_stars_repo_name": "nienkebrinkman/SS_MTI", "max_stars_repo_head_hexsha": "2632214f7df9caaa53d33432193ba0602470d21a", "max_stars_repo_licenses": ["BSD-3-Clause"], "max_...
[STATEMENT] theorem dist_nearest_neighbors: assumes "invar kdt" "nns = nearest_neighbors n p kdt" shows "\<forall>q \<in> (set_kdt kdt - set nns). \<forall>r \<in> set nns. dist r p \<le> dist q p" [PROOF STATE] proof (prove) goal (1 subgoal): 1. \<forall>q\<in>set_kdt kdt - set nns. \<forall>r\<in>set nns. dist r...
{"llama_tokens": 2547, "file": "KD_Tree_Nearest_Neighbors", "length": 20}
# -*- coding: utf-8 """ Functions for determining best-fit template parameters by convolution with a grid """ import numexpr import numpy as np import multiprocessing as mp import matplotlib import matplotlib.pyplot as plt import pyfftw from pyfftw.interfaces.numpy_fft import fft2, ifft2, fftshift from functools im...
{"hexsha": "e0678551cec8fe20d0270d6b821eb18ce2f8eb19", "size": 12891, "ext": "py", "lang": "Python", "max_stars_repo_path": "scarplet/core.py", "max_stars_repo_name": "vickielee333/scarplet", "max_stars_repo_head_hexsha": "8cf8cee2c9b808c550c0645f7836cda6d809872e", "max_stars_repo_licenses": ["MIT"], "max_stars_count":...
# Copyright (c) Ryan Kingsbury # This source code is licensed under the BSD-style license found in the # LICENSE file in the root directory of this source tree. """ Donnan exclusion module """ def donnan_equilibrium( C_bulk: float, C_fix: float, z_counter: int = 1, z_co: int = -1, nu_counter: int...
{"hexsha": "2fdd42a62afbc74417f6b189a00232f902b23675", "size": 5710, "ext": "py", "lang": "Python", "max_stars_repo_path": "membrane_toolkit/core/donnan.py", "max_stars_repo_name": "rkingsbury/membrane-toolk", "max_stars_repo_head_hexsha": "09c3ef026ddb0dcb35fb234e70a54ffa5c2be73c", "max_stars_repo_licenses": ["BSD-3-C...
import numpy as np from math import floor class TwoTarget: """ Ref: Two-target algorithms for infinite-armed bandits with bernoulli rewards. Bonald, T., & Proutiere, A. (2013). """ def __init__(self, horizon, m, alpha=1, beta=1): self.horizon = horizon self.m = m self....
{"hexsha": "caa7d1b10df1831133b5bae3ada7a3f751ec1df4", "size": 1295, "ext": "py", "lang": "Python", "max_stars_repo_path": "algorithm/TwoTarget.py", "max_stars_repo_name": "mjedor/greedy-bandits", "max_stars_repo_head_hexsha": "5ca57a50c76e036c2f7fed167fe27a61225886a9", "max_stars_repo_licenses": ["MIT"], "max_stars_co...
"""Lambda - A collection of Data Science helper functions""" import pandas as pd import numpy as np favorite_animals = ['cat', 'dog', 'bird', 'iguana'] print('This is executed as lambdata is imported')
{"hexsha": "e60b876fb466106672588adc56b2feb8b954625e", "size": 206, "ext": "py", "lang": "Python", "max_stars_repo_path": "lambdata/__init__.py", "max_stars_repo_name": "joanRVAllen/lambdata", "max_stars_repo_head_hexsha": "f9474d0ea7ebf5025e87c56576d431056a81f5b0", "max_stars_repo_licenses": ["MIT"], "max_stars_count"...
module NewTests using Test, UUIDs, Dates, TOML import ..Pkg, LibGit2 using Pkg.Types: PkgError using Pkg.Resolve: ResolverError import Pkg.Artifacts: artifact_meta, artifact_path using ..Utils general_uuid = UUID("23338594-aafe-5451-b93e-139f81909106") # UUID for `General` exuuid = UUID("7876af07-990d-54b4-ab0e-2...
{"hexsha": "a62509fc8a82e3faf0262aba00b0db8440198c14", "size": 121104, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "test/new.jl", "max_stars_repo_name": "barucden/Pkg.jl", "max_stars_repo_head_hexsha": "1c84da1a29b35f2ab0b2715a45a3b8644461a45c", "max_stars_repo_licenses": ["MIT"], "max_stars_count": null, "max...
// Copyright Sebastian Ramacher, 2007. // Distributed under the Boost Software License, Version 1.0. (See // accompanying file LICENSE_1_0.txt or copy at // http://www.boost.org/LICENSE_1_0.txt) #ifndef BOOST_PTR_CONTAINER_DETAIL_SERIALIZE_PTR_MAP_ADAPTER_HPP #define BOOST_PTR_CONTAINER_DETAIL_SERIALIZE_PTR_MAP_ADAPTE...
{"hexsha": "a7b10d22adb12cda0ec0244aa82745338fc652bd", "size": 3448, "ext": "hpp", "lang": "C++", "max_stars_repo_path": "src/lib/boost/ptr_container/detail/serialize_ptr_map_adapter.hpp", "max_stars_repo_name": "EricBoittier/vina-carb-docker", "max_stars_repo_head_hexsha": "e8730d1ef90395e3d7ed3ad00264702313b0766a", "...
# Image Display module import matplotlib.pyplot as plt import matplotlib.gridspec as gridspec from matplotlib.widgets import SpanSelector from matplotlib.colors import LinearSegmentedColormap from skimage import transform import numpy as np class GUIDisplayOverlap(object): def __init__(self, data_em): #...
{"hexsha": "642013ed2eed3443f4f43374af1c94ca71f779bd", "size": 11907, "ext": "py", "lang": "Python", "max_stars_repo_path": "guidisplay.py", "max_stars_repo_name": "slimpotatoes/Holo_EM_2_keVs", "max_stars_repo_head_hexsha": "e17a773092ff18b429ebd46ca380478d9fb3b819", "max_stars_repo_licenses": ["BSD-3-Clause"], "max_s...
import setup setup.deal_with_path() import numpy as np import math import linreg_qr import linreg_setup def test_accuracy(qrMthd="HouseHolder", colTrunc=False): print("*"*120) if colTrunc: print("Test the accuracy of federated QR implemented by ", qrMthd, " method with column pivoting") else: ...
{"hexsha": "d27b6e224f53a820caf4848cc76fd64d0f4c7d64", "size": 9262, "ext": "py", "lang": "Python", "max_stars_repo_path": "demos/linear_regression/test_qr.py", "max_stars_repo_name": "flyingcat047/fedlearn-algo", "max_stars_repo_head_hexsha": "4f7a9012f49720744a502aa9a192a285694bd415", "max_stars_repo_licenses": ["Apa...
# -*- coding: utf-8 -*- """ Defines unit tests for :mod:`colour.models.hdr_ipt` module. """ import numpy as np import unittest from itertools import permutations from colour.models import XYZ_to_hdr_IPT, hdr_IPT_to_XYZ from colour.models.hdr_ipt import exponent_hdr_IPT from colour.utilities import domain_range_scale,...
{"hexsha": "e03ff5e4259124c1c9d3de60611b3773baa988b8", "size": 9950, "ext": "py", "lang": "Python", "max_stars_repo_path": "colour/models/tests/test_hdr_ipt.py", "max_stars_repo_name": "gutenzwerg/colour", "max_stars_repo_head_hexsha": "299eceb57483213e2544d532a6d3727887e49426", "max_stars_repo_licenses": ["BSD-3-Claus...
[STATEMENT] lemma equalOn_UnD: "equalOn (A Un B) f g ==> equalOn A f g & equalOn B f g" [PROOF STATE] proof (prove) goal (1 subgoal): 1. equalOn (A \<union> B) f g \<Longrightarrow> equalOn A f g \<and> equalOn B f g [PROOF STEP] by(auto simp: equalOn_def) \<comment> \<open>FIXME move following elsewhere?\<close...
{"llama_tokens": 124, "file": "Completeness_Base", "length": 1}
[STATEMENT] lemma SET025_4: "EQU001_0_ax equal & (\<forall>Y X. member(X::'a,Y) --> little_set(X)) & (\<forall>X Y. little_set(f1(X::'a,Y)) | equal(X::'a,Y)) & (\<forall>X Y. member(f1(X::'a,Y),X) | member(f1(X::'a,Y),Y) | equal(X::'a,Y)) & (\<forall>X Y. member(f1(X::'a,Y),X) & member(f1(X::'a,Y),Y) --> equa...
{"llama_tokens": 25269, "file": null, "length": 1}
[STATEMENT] lemma has_prod_mult: assumes f: "f has_prod a" and g: "g has_prod b" shows "(\<lambda>n. f n * g n) has_prod (a * b)" [PROOF STATE] proof (prove) goal (1 subgoal): 1. (\<lambda>n. f n * g n) has_prod (a * b) [PROOF STEP] using f [unfolded has_prod_def] [PROOF STATE] proof (prove) using this: raw_has_pr...
{"llama_tokens": 6504, "file": null, "length": 57}
"""Kuramoto-Sivashinsky (KS) system: the simplest (?) PDE admitting chaos. Defined by: u_t = -u*u_x - u_xx - u_xxxx - See compare_schemes.py for a comparison of time-step integration schemes. - See demo.py for further description. """ import functools import numpy as np from dapper.dpr_config import DotDict f...
{"hexsha": "ec29c478f1ad1d85d7890d9b4c5f4a9ef05286a2", "size": 5051, "ext": "py", "lang": "Python", "max_stars_repo_path": "dapper/mods/KS/__init__.py", "max_stars_repo_name": "yoavfreund/DAPPER", "max_stars_repo_head_hexsha": "c2fa5cc446a2b22a1efc174afc7e091363c9375d", "max_stars_repo_licenses": ["MIT"], "max_stars_co...
# coding: utf-8 # /*########################################################################## # # Copyright (c) 2017 European Synchrotron Radiation Facility # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal #...
{"hexsha": "d33bb8f801c823658b4bd2adf6c778637013b65b", "size": 3868, "ext": "py", "lang": "Python", "max_stars_repo_path": "examples/plot3dContextMenu.py", "max_stars_repo_name": "vincefn/silx", "max_stars_repo_head_hexsha": "4b239abfc90d2fa7d6ab61425f8bfc7b83c0f444", "max_stars_repo_licenses": ["CC0-1.0", "MIT"], "max...
################# # IMPORTS ################# import torch import torch.nn as nn from torchvision import models import numpy as np import torch.utils.data as dataset import sys from torch.autograd import Variable import torchvision.transforms as transforms sys.path.append('') ################# # CLASSES ###############...
{"hexsha": "d299db302c4671d55387a98da1ba140b326d555a", "size": 8937, "ext": "py", "lang": "Python", "max_stars_repo_path": "withoutNoise/module_split.py", "max_stars_repo_name": "lelynn/RF_GANsynth", "max_stars_repo_head_hexsha": "d1e58f2756c66e06ec7ec8544f0a7456f58e2055", "max_stars_repo_licenses": ["MIT"], "max_stars...
#define BOOST_TEST_MODULE pcraster dal space step mapper #include <boost/test/unit_test.hpp> #include "dal_MathUtils.h" #include "dal_SpaceStepMapper.h" BOOST_AUTO_TEST_CASE(test) { using namespace dal; { SpaceStepMapper mapper; BOOST_CHECK(!mapper.isValid()); } { SpaceStepMapper mapper(0, 5.0, ...
{"hexsha": "5929a8e435e65ac32af499844d3449e21ba0b8ef", "size": 1769, "ext": "cc", "lang": "C++", "max_stars_repo_path": "pcraster/pcraster-4.2.0/pcraster-4.2.0/source/pcraster_dal/dal_SpaceStepMapperTest.cc", "max_stars_repo_name": "quanpands/wflow", "max_stars_repo_head_hexsha": "b454a55e4a63556eaac3fbabd97f8a0b80901e...
try: import unzip_requirements except ImportError: pass import torch import torch.nn as nn import torch.nn.functional as F import os import io import boto3 import requests from distil_bilstm_pos_tagger.distilbert_utils.tokenization_distilbert import DistilBertTokenizer import nltk import numpy as np class BiLS...
{"hexsha": "24666fbced5065a1ecf988843dbc8fc2453adafb", "size": 4558, "ext": "py", "lang": "Python", "max_stars_repo_path": "pkg/distil_bilstm_pos_tagger/distil_bilstm_pos_tagger.py", "max_stars_repo_name": "etherlabsio/ai-engine", "max_stars_repo_head_hexsha": "e73a4419a34db42a410e2a7e7629eb946b86f2c2", "max_stars_repo...
''' This script uses the SCOPUS data on ERNIE to generate data expected in the Abt tables This script is revised to use an updated version of the documents table, cci_s_documents_jeroen_updated, that uses document citation counts from a frozen dataset ''' import psycopg2 import argparse import pandas as pd import nump...
{"hexsha": "74f8e51d5af5f02091231b5b93b197e09b0f1e41", "size": 13529, "ext": "py", "lang": "Python", "max_stars_repo_path": "Scopus/Abt_Analysis/Analysis_scripts/sponsored_pubs_summary_statistics.py", "max_stars_repo_name": "chackoge/ERNIE_Plus", "max_stars_repo_head_hexsha": "7e480c47a69fc2f736ac7fb55ece35dbff919938",...
import argparse import os,sys import numpy as np import datetime from train import get_symbol, data_loader import mxnet as mx from mxnet import ndarray as nd import ipdb def softmax(x): exp = np.exp(x) partition = exp.sum(axis=1,keepdims=True) return exp / partition parser = argparse.ArgumentParser(desc...
{"hexsha": "79fa9a197efdfd42f16953a8f9534c4b79708442", "size": 1855, "ext": "py", "lang": "Python", "max_stars_repo_path": "stranger/test.py", "max_stars_repo_name": "hudmgy/insightface", "max_stars_repo_head_hexsha": "2ebc87e1bde3d4ef04bc0d4498038a0bc01b0ddc", "max_stars_repo_licenses": ["MIT"], "max_stars_count": 1, ...
import Compat: @static, is_windows, is_apple @static if is_windows() error("The shoco C library doesn't support Windows") end using BinDeps @BinDeps.setup shoco = library_dependency("shoco") if isdir(srcdir(shoco)) rm(srcdir(shoco), recursive=true) mkdir(srcdir(shoco)) end if isdir(BinDeps.downloadsdi...
{"hexsha": "0d6c583647b3cbd3cd2f00a44edff8d49ab3234a", "size": 1269, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "deps/build.jl", "max_stars_repo_name": "JuliaPackageMirrors/Shoco.jl", "max_stars_repo_head_hexsha": "37931aac0afe4e669283d2282ffde2f0f3de757f", "max_stars_repo_licenses": ["MIT"], "max_stars_count...
SUBROUTINE cast_shadow_main( & dem_data, solar_data, sazi_data, & dresx, dresy, spheroid, alat1, alon1, & Aoff_x1, Aoff_x2, Aoff_y1, Aoff_y2, & nlA_ori, nsA_ori, & is_utm, & nrow, ncol, nl, ns, dem_nr, dem_nc, & a, solar, sazi, dem, alat, alon, mask, & ierr, mask_all) implicit none ...
{"hexsha": "cec33bf722af55b7b1ebd7655f23acdd04d07472", "size": 18270, "ext": "f90", "lang": "FORTRAN", "max_stars_repo_path": "wagl/f90_sources/cast_shadow_main.f90", "max_stars_repo_name": "Oceancolour-RG/wagl", "max_stars_repo_head_hexsha": "f002a1c0a373d21758d44d2a808bdfd755d90226", "max_stars_repo_licenses": ["Apac...
""" Module report ================ A module with helper functions for computing pre-defined plots for the analysis of fragment combinations. """ import warnings import logging import argparse import sys from shutil import rmtree from datetime import datetime import re from pathlib import Path from collections import ...
{"hexsha": "62b3838c10149d00d3030d186d99b63fdf3343ca", "size": 11627, "ext": "py", "lang": "Python", "max_stars_repo_path": "npfc/report.py", "max_stars_repo_name": "mpimp-comas/npfc", "max_stars_repo_head_hexsha": "316156a8826759d767ef16833cd4f0670868693e", "max_stars_repo_licenses": ["MIT"], "max_stars_count": 6, "ma...
[STATEMENT] lemma ACI_norm_PLUS: "list_all2 (\<lambda>r s. \<guillemotleft>r\<guillemotright> = \<guillemotleft>s\<guillemotright>) xs ys \<Longrightarrow> \<guillemotleft>PLUS xs\<guillemotright> = \<guillemotleft>PLUS ys\<guillemotright>" [PROOF STATE] proof (prove) goal (1 subgoal): 1. list_all2 (\<lambda>r s. \<...
{"llama_tokens": 1597, "file": "MSO_Regex_Equivalence_Pi_Derivatives", "length": 8}
#!/usr/bin/env python # coding: utf8 # # Copyright (c) 2020 Centre National d'Etudes Spatiales (CNES). # # This file is part of CARS # (see https://github.com/CNES/cars). # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obta...
{"hexsha": "5322fc0ca4ad05ce1f6a140480be0473f49eaddb", "size": 3889, "ext": "py", "lang": "Python", "max_stars_repo_path": "tests/steps/matching/test_sparse_matching.py", "max_stars_repo_name": "fchapoton/cars", "max_stars_repo_head_hexsha": "c145e12c8b984d5c496c29cff474628044f6216e", "max_stars_repo_licenses": ["Apach...
import numpy as np import random from cfDNA_Fragment import Fragment class FragmentCopies: """ A class used to represent and run the assay process ... Attributes ---------- fragment_copies : list A storage of Fragment objects that is used for each step of the process Methods ------- cfDNA_convert(input = 15,...
{"hexsha": "f6790b670d26686b684c9b9d24272e50cca94980", "size": 4393, "ext": "py", "lang": "Python", "max_stars_repo_path": "fragment_copies.py", "max_stars_repo_name": "shen-y-eric/Genomic-Recovery-Simulation", "max_stars_repo_head_hexsha": "31e32e659c4e706bd9245b15f0181eee919d32e8", "max_stars_repo_licenses": ["Apache...
import collections import warnings import cv2 import matplotlib.pyplot as plt import numpy as np from matplotlib import patches as plt_patches from DLBio.helpers import safe_division class IRectangle(object): """Abstract base class for a rectagle. Intended to specify the positions of each dimension to reduc...
{"hexsha": "3a3f7eeb0c8125aad0296704e4e38198b196b8b9", "size": 7507, "ext": "py", "lang": "Python", "max_stars_repo_path": "ssd/rectangles.py", "max_stars_repo_name": "pgruening/dlbio", "max_stars_repo_head_hexsha": "0c4e468bcd5d7e298fbecba13003bcae36889486", "max_stars_repo_licenses": ["MIT"], "max_stars_count": 1, "m...
(* Title: Tarski's geometry Author: Tim Makarios <tjm1983 at gmail.com>, 2012 Maintainer: Tim Makarios <tjm1983 at gmail.com> *) header "Tarski's geometry" theory Tarski imports Complex_Main Miscellany Metric begin subsection "The axioms" text {* The axioms, and all theorems beginning with \em...
{"author": "Josh-Tilles", "repo": "AFP", "sha": "f4bf1d502bde2a3469d482b62c531f1c3af3e881", "save_path": "github-repos/isabelle/Josh-Tilles-AFP", "path": "github-repos/isabelle/Josh-Tilles-AFP/AFP-f4bf1d502bde2a3469d482b62c531f1c3af3e881/thys/Tarskis_Geometry/Tarski.thy"}
{-# OPTIONS --cubical --safe --no-sized-types --no-guardedness #-} module Agda.Builtin.Cubical.Glue where open import Agda.Primitive open import Agda.Builtin.Sigma open import Agda.Primitive.Cubical renaming (primINeg to ~_; primIMax to _∨_; primIMin to _∧_; primHComp to hc...
{"hexsha": "c7ed5e75ae186911881b15dc4df408ad918d67f7", "size": 5286, "ext": "agda", "lang": "Agda", "max_stars_repo_path": "src/data/lib/prim/Agda/Builtin/Cubical/Glue.agda", "max_stars_repo_name": "phadej/agda", "max_stars_repo_head_hexsha": "2fa8ede09451d43647f918dbfb24ff7b27c52edc", "max_stars_repo_licenses": ["BSD-...
/****************************************************************** * * uEcho for C * * Copyright (C) Satoshi Konno 2015 * * This is licensed under BSD-style license, see file COPYING. * ******************************************************************/ #include <boost/test/unit_test.hpp> #include <uecho/_nod...
{"hexsha": "c32973f42e3c1b10309f8de9ec4e47a0b09c5b33", "size": 4086, "ext": "cpp", "lang": "C++", "max_stars_repo_path": "test/NodeTest.cpp", "max_stars_repo_name": "cybergarage/uecho4c", "max_stars_repo_head_hexsha": "d92633d556602c8ffa917525a241350ac10a9ff2", "max_stars_repo_licenses": ["BSD-3-Clause"], "max_stars_co...
import unittest import numpy as np from polyhedral_analysis.polyhedra_recipe import (PolyhedraRecipe, matching_sites, polyhedra_from_distance_cutoff) from pymatgen.core import Structure, Lattice from polyhedral_analysis....
{"hexsha": "43e2bd44fc923057f3d0217d2264a19a34cb58f9", "size": 4519, "ext": "py", "lang": "Python", "max_stars_repo_path": "tests/test_polyhedra_recipe.py", "max_stars_repo_name": "bjmorgan/polyhedral-analysis", "max_stars_repo_head_hexsha": "1f594032f68596b7622bf15b95f7e2ac1183a169", "max_stars_repo_licenses": ["MIT"]...
[STATEMENT] lemma i_shrink_i_take_mult: "0 < k \<Longrightarrow> f \<Down> (n * k) \<div>\<^sub>f k = f \<div>\<^sub>i k \<Down> n" [PROOF STATE] proof (prove) goal (1 subgoal): 1. 0 < k \<Longrightarrow> f \<Down> (n * k) \<div> k = f \<div> k \<Down> n [PROOF STEP] by (simp add: f_shrink_def i_shrink_def i_aggregate...
{"llama_tokens": 148, "file": "AutoFocus-Stream_AF_Stream", "length": 1}
#include "st_ydl.hpp" #include "ydl_data.hpp" #include <fstream> #include <iostream> #include <thread> #include <queue> #include <boost/thread.hpp> using namespace std; STydl::STydl(string _file) : file_name(_file) { try { read_file(); } catch(const runtime_error &run_err) { cerr...
{"hexsha": "33ba22d5fdb42ce1da5175c49b67f960db5123f7", "size": 6299, "ext": "cpp", "lang": "C++", "max_stars_repo_path": "src/st_ydl.cpp", "max_stars_repo_name": "SoujiThenria/st_ydl", "max_stars_repo_head_hexsha": "4bd47dcf9b909ec6172e6e1cd41fdb34ba90210f", "max_stars_repo_licenses": ["MIT"], "max_stars_count": 1.0, "...
module mod_monolis_precond_mf use mod_monolis_prm use mod_monolis_com use mod_monolis_mat use mod_monolis_fact_mf use mod_monolis_matrix_fillin implicit none contains subroutine monolis_precond_mf_setup(monoPRM, monoCOM, monoMAT) implicit none type(monolis_prm) :: monoPRM type(monolis_com)...
{"hexsha": "55cd3bbe2279fbbc172e94ee40a136122c4d9972", "size": 2350, "ext": "f90", "lang": "FORTRAN", "max_stars_repo_path": "src/solver/precond/MF.f90", "max_stars_repo_name": "nqomorita/monolis", "max_stars_repo_head_hexsha": "55d746a480fd7b9639216be19e0a253e6137dfe9", "max_stars_repo_licenses": ["MIT"], "max_stars_c...
# # File: # NUG_unstructured_ICON_triangles_PyNGL.py # # Synopsis: # Illustrates using polygon fill for triangular mesh data. # # Categories: # contour plots # # Author: # Karin Meier-Fleischer # # Date of initial publication: # February 2016 # # Description: # This example shows how to create...
{"hexsha": "b46e354001fae975fd183c25730da3703cec77ca", "size": 8463, "ext": "py", "lang": "Python", "max_stars_repo_path": "examples/NUG_unstructured_ICON_triangles_PyNGL.py", "max_stars_repo_name": "yang69can/pyngl", "max_stars_repo_head_hexsha": "78a7040ce9de4b7a442b0c3b5faecccab2f01426", "max_stars_repo_licenses": [...
[STATEMENT] lemma dep3_nonspray: assumes "dep3_event Q R S x" shows "\<exists>P\<in>\<P>. P \<notin> SPRAY x" [PROOF STATE] proof (prove) goal (1 subgoal): 1. \<exists>P\<in>\<P>. P \<notin> SPRAY x [PROOF STEP] by (metis assms dep3_event_def)
{"llama_tokens": 109, "file": "Schutz_Spacetime_Minkowski", "length": 1}
from ..gui.main_window import Ui_EditorMainWindow from PySide.QtGui import QApplication, QMainWindow, QPixmap from PySide import QtGui, QtCore from PySide.QtCore import QObject import sys import numpy as np from .. import util from .brush_dialog import BrushDialog from .about_dialog import AboutDialog from .new_image_d...
{"hexsha": "5c2927be7fd796dc0da9eae2ae4657bc05193d7e", "size": 16609, "ext": "py", "lang": "Python", "max_stars_repo_path": "fredo/editor/main.py", "max_stars_repo_name": "yasiupl/FreDo", "max_stars_repo_head_hexsha": "73bdc380dd82df171fe63998f0affa092e30759a", "max_stars_repo_licenses": ["BSD-3-Clause"], "max_stars_co...
""" This module deals with controlling what is displayed on the screen. The two major features of this module are switching to the alernative screen and clearing the what is currenlty on the screen. The [alternative screen](https://invisible-island.net/xterm/ctlseqs/ctlseqs.html#h2-The-Alternate-Screen-Buffer) is a f...
{"hexsha": "e6213ed2dea457542b8e4007d6864d8334c95698", "size": 5353, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "src/Screen.jl", "max_stars_repo_name": "Sean1708/Ansillary.jl", "max_stars_repo_head_hexsha": "999eba97593350ab23abb74ebff3ab8f44e356e7", "max_stars_repo_licenses": ["MIT"], "max_stars_count": 1, "...
""" Example demonstrating the usage for the linear-fit scenario. """ import numpy as np import matplotlib.pyplot as plt import sys sys.path.insert(0,'../src') from mcmc import MCMC import matplotlib matplotlib.rc('xtick', labelsize=14) matplotlib.rc('ytick', labelsize=14) #-------------------------------------------...
{"hexsha": "de66933c75708c9269eb026b37a3bb21f8dcaf0c", "size": 5757, "ext": "py", "lang": "Python", "max_stars_repo_path": "animation/anim.py", "max_stars_repo_name": "creativeishu/pychain", "max_stars_repo_head_hexsha": "c9b6a90510af6c8456bc0611117f4bc8e7661940", "max_stars_repo_licenses": ["MIT"], "max_stars_count": ...
#!/usr/bin/env python """ Example: inductive conformal regression using DecisionTreeRegressor """ # Authors: Henrik Linusson import numpy as np import pandas as pd from sklearn.tree import DecisionTreeRegressor from sklearn.neighbors import KNeighborsRegressor from sklearn.datasets import load_boston from nonconfo...
{"hexsha": "96018e7d8f87b16d44b78d402b9f336f049f5839", "size": 3015, "ext": "py", "lang": "Python", "max_stars_repo_path": "examples/icp_regression_tree.py", "max_stars_repo_name": "smazzanti/nonconformist", "max_stars_repo_head_hexsha": "5ed072c82ae6d923eb6063a6a5c8fa664fbf729c", "max_stars_repo_licenses": ["MIT"], "m...
using LinearAlgebra # degenerate cases (x₁ + x₂ + ⋯ + xₘ)¹ @test [multiexponents(1,1)...] == [[1]] @test [multiexponents(2,1)...] == [[1,0],[0,1]] @test [multiexponents(3,1)...] == [[1,0,0],[0,1,0],[0,0,1]] @test hcat([multiexponents(10,1)...]...) == Matrix{Float64}(I, 10, 10) # degenerate cases (x₁ + x₂ + ⋯ + xₘ)⁰ @...
{"hexsha": "141f72bf1127ca08a70b667546aeca6e8b8e3902", "size": 1016, "ext": "jl", "lang": "Julia", "max_stars_repo_path": "test/multinomials.jl", "max_stars_repo_name": "Sedictious/Combinatorics.jl", "max_stars_repo_head_hexsha": "fa6c6a893ad5a419ffa56b3aacf64c1053cbc507", "max_stars_repo_licenses": ["MIT"], "max_stars...
/* MIT License Copyright (c) 2020 Group of Electronic Technology and Communications. University of A Coruna. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without...
{"hexsha": "d69e1c10e137997b05fbeb104903b5855b8dc8f5", "size": 7124, "ext": "cpp", "lang": "C++", "max_stars_repo_path": "src/publishers/GazeboGuideRTLS.cpp", "max_stars_repo_name": "valentinbarral/gazebo2ros", "max_stars_repo_head_hexsha": "8b1db92056af1009cf60daf44503e695d6465532", "max_stars_repo_licenses": ["MIT"],...
// Copyright (C) 2018 Thejaka Amila Kanewala, Marcin Zalewski, Andrew Lumsdaine. // Boost Software License - Version 1.0 - August 17th, 2003 // Permission is hereby granted, free of charge, to any person or organization // obtaining a copy of the software and accompanying documentation covered by // this license (the...
{"hexsha": "5db8e2de42f6b7708a23ba2fd03b134af1b83605", "size": 42175, "ext": "cpp", "lang": "C++", "max_stars_repo_path": "libs/graph_parallel/drivers/tests/static_eagm_tests.cpp", "max_stars_repo_name": "thejkane/AGM", "max_stars_repo_head_hexsha": "4d5cfe9522461d207ceaef7d90c1cd10ce9b469c", "max_stars_repo_licenses":...
(*-------------Description ------------------------------------------------------ This file implements maps on lists. Here we define functions to calculate range of a function on list l. We also define one-one function predicate and its boolean counterpart. Following are the notions defined in this file: s_m...
{"author": "Abhishek-TIFR", "repo": "List-Set", "sha": "f22e828ca348c8317a5235491e7e1dac848a691f", "save_path": "github-repos/coq/Abhishek-TIFR-List-Set", "path": "github-repos/coq/Abhishek-TIFR-List-Set/List-Set-f22e828ca348c8317a5235491e7e1dac848a691f/SetMaps.v"}