repo_name
stringlengths
6
130
hexsha
list
file_path
list
code
list
apis
list
Jerryxiaoyu/my_baselines
[ "c0163328e33dd05713e2139d2c1703fc5f661be3" ]
[ "my_envs/mujoco/cellrobotFull.py" ]
[ "import numpy as np\nfrom gym import utils\nfrom my_envs.mujoco import mujoco_env\nfrom math import pi,sin,cos\nfrom transformations import quaternion_inverse, quaternion_multiply, euler_from_quaternion\nimport os\n\nstate_M =np.array([[1., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.],\n ...
[ [ "numpy.square", "numpy.isfinite", "numpy.clip", "numpy.linalg.norm", "numpy.concatenate", "numpy.append", "numpy.exp", "numpy.array", "numpy.zeros" ] ]
Astroua/M33_NOEMA
[ "872b72fc06804d3dbfcb45c6b927c1e34c55a667" ]
[ "analysis/flux_recovery.py" ]
[ "\n'''\nCompare the flux in the masked NOEMA and 30-m data.\n'''\n\nfrom spectral_cube import SpectralCube\nfrom astropy.io import fits\nimport numpy as np\nimport astropy.units as u\n\nfrom cube_analysis.feather_cubes import flux_recovery\n\nfrom paths import noema_co21_file_dict, iram_matched_data_path\nfrom cons...
[ [ "numpy.nansum" ] ]
haiwangyang/PP
[ "0c470c39adc8453ecfb336e1374e2ac1fcc1ad80" ]
[ "Parse.Pico.Ribo.Reads.py" ]
[ "#!/usr/bin/env python\n'''\nParse PicoGreen/RiboGreen results from from Gemini XPS Microplate Reader\nConvert 384 well plate format to 96 well plate format\nWrite to different excel spreadsheets\n\nexample:\npython Parse.Pico.Ribo.Reads.py -f data/pico.reads.txt -s data/standards.txt -a1 1st_plate -a2 2nd_plate -b...
[ [ "numpy.array" ] ]
AliengirlLiv/dreamer-pytorch-1
[ "33979d7c61d0406d27ea46b9dcbbd823f765a518" ]
[ "utils.py" ]
[ "import os\nimport cv2\nimport numpy as np\nimport plotly\nfrom plotly.graph_objs import Scatter\nfrom plotly.graph_objs.scatter import Line\nimport torch\nfrom torch.nn import functional as F\nfrom typing import Iterable\nfrom torch.nn import Module\n\n\n# Plots min, max and mean + standard deviation bars of a pop...
[ [ "torch.randn_like", "torch.empty", "torch.cat", "numpy.asarray", "numpy.median", "numpy.stack", "torch.nn.functional.softplus", "torch.stack", "torch.ones_like" ] ]
ArenBabikian/Scenic
[ "5687d9a70c0e6588ee0cda81b4a4a6731bcd2d91" ]
[ "src/scenic/formats/opendrive/xodr_parser.py" ]
[ "\"\"\"Parser for OpenDRIVE (.xodr) files.\"\"\"\n\nimport math\nimport itertools\nimport warnings\nimport xml.etree.ElementTree as ET\nimport numpy as np\nfrom scipy.integrate import quad\nfrom scipy.integrate import solve_ivp\nfrom pynverse import inversefunc\nfrom shapely.geometry import Polygon, MultiPolygon, G...
[ [ "numpy.sqrt", "numpy.linspace", "scipy.integrate.solve_ivp", "scipy.integrate.quad", "numpy.array" ] ]
velvetThunder25/Feature-based-Monocular-Visual-Odometry
[ "a7602edab934419c1ec73618ee655e18026f834f", "a7602edab934419c1ec73618ee655e18026f834f" ]
[ "pyslam/keyframe.py", "pyslam/feature_manager_adaptors.py" ]
[ "\"\"\"\n* This file is part of PYSLAM \n*\n* Copyright (C) 2016-present Luigi Freda <luigi dot freda at gmail dot com> \n*\n* PYSLAM is free software: you can redistribute it and/or modify\n* it under the terms of the GNU General Public License as published by\n* the Free Software Foundation, either version 3 of t...
[ [ "scipy.spatial.cKDTree", "numpy.full" ], [ "numpy.array", "numpy.zeros", "numpy.vstack" ] ]
christina-aigner/midnite
[ "a042ec775dc66ca68291ebaf0eb1a3be9ef28cf6" ]
[ "tests/unit/compound_methods_test.py" ]
[ "\"\"\"Unit test for the compound methods.\"\"\"\nimport pytest\nimport torch\nfrom assertpy import assert_that\nfrom numpy.testing import assert_array_equal\nfrom torch.nn import functional\nfrom torch.nn import Module\n\nfrom midnite.visualization import compound_methods\nfrom midnite.visualization.compound_metho...
[ [ "torch.ones", "torch.zeros", "torch.tensor", "numpy.testing.assert_array_equal", "torch.nn.functional.interpolate.assert_called_with" ] ]
Calychas/peap-project
[ "14eb75cdaa60842dd9b530c10c47985aa77f8ff7" ]
[ "src/visualization/tweets_data_visualizer.py" ]
[ "import pandas as pd\nimport seaborn as sns\nimport matplotlib.pyplot as plt\n\nimport sys\n\n\ndef plot_tweets_counts(accounts: pd.DataFrame) -> None:\n plt.figure(figsize=(12, 12))\n sns.histplot(data=accounts, x=\"tweets_count\", binwidth=500)\n plt.title(\"Twitter activity (tweets, retweets, replies) f...
[ [ "pandas.read_csv", "matplotlib.pyplot.title", "matplotlib.pyplot.figure", "matplotlib.pyplot.savefig", "matplotlib.pyplot.close", "matplotlib.pyplot.xlabel", "matplotlib.pyplot.ylabel" ] ]
vsocrates/medtype
[ "16c6f39d38a73c4c44258bbdf78074a81e07b1c7" ]
[ "medtype-trainer/medtype.py" ]
[ "from helper import *\nfrom models import BertPlain, BertCombined\nfrom dataloader import MedTypeDataset\n\nfrom torch.utils.data import DataLoader\nfrom transformers.optimization import AdamW\nfrom transformers import get_linear_schedule_with_warmup, BertTokenizer\nfrom sklearn.metrics import average_precision_sco...
[ [ "torch.utils.data.DataLoader" ] ]
ekmixon/gamechanger-ml
[ "e7967261a4b2f21b06347020cd7e6a010538eb8f", "e7967261a4b2f21b06347020cd7e6a010538eb8f" ]
[ "gamechangerml/src/search/evaluation/evaltool.py", "gamechangerml/src/utilities/np_utils.py" ]
[ "import os\nimport json\nimport logging\nimport mlflow\n\nimport matplotlib.pyplot as plt\n\nimport argparse\n\nlogger = logging.getLogger(__name__)\n\n\nclass EvalTool(object):\n \"\"\"\n Object class that holds all functions for evaluating and\n plotting score metrics for ranked retrieval.\n\n The pre...
[ [ "matplotlib.pyplot.legend", "matplotlib.pyplot.tight_layout", "matplotlib.pyplot.figure", "matplotlib.pyplot.ylim", "matplotlib.pyplot.savefig", "matplotlib.pyplot.plot", "matplotlib.pyplot.clf", "matplotlib.pyplot.grid", "matplotlib.pyplot.xlabel", "matplotlib.pyplot.ylabe...
shan18/Caption-Generation-from-Images
[ "6917ddfcac661684171663f6cb06b17e5b858def" ]
[ "capsnet_create_dataset.py" ]
[ "import os\nimport random\nimport h5py\nimport pickle\nimport argparse\nimport numpy as np\n\nfrom utils import load_image, print_progress_bar\n\n\ndef load_data(input_path):\n \"\"\" Load coco dataset \"\"\"\n with open(input_path, 'rb') as file:\n coco_raw = pickle.load(file)\n image_categories = ...
[ [ "numpy.array" ] ]
UKA-SHA/3D_Appearance_SR
[ "0e4d3a4476afe1ccf16f0e8fee3d697c0d204395", "0e4d3a4476afe1ccf16f0e8fee3d697c0d204395" ]
[ "code/utils/myssim.py", "code/data/srdata.py" ]
[ "from __future__ import division, absolute_import, print_function\n\n\n\nimport numpy as np\nfrom numpy.lib.arraypad import _validate_lengths\nfrom scipy.ndimage import uniform_filter, gaussian_filter\n\ndtype_range = {np.bool_: (False, True),\n np.bool8: (False, True),\n np.uint8: (0, 2...
[ [ "numpy.asarray", "numpy.array", "numpy.empty", "numpy.lib.arraypad._validate_lengths" ], [ "numpy.load", "scipy.misc.imread", "numpy.save" ] ]
elhananby/flydra
[ "09b86859b1863700cdea0bbcdd4758da6c83930b", "09b86859b1863700cdea0bbcdd4758da6c83930b" ]
[ "flydra_analysis/flydra_analysis/a2/flydra_textlog2csv.py", "flydra_analysis/flydra_analysis/analysis/reconstruct_orientation.py" ]
[ "from __future__ import print_function\n\nif 1:\n # deal with old files, forcing to numpy\n import tables.flavor\n\n tables.flavor.restrict_flavors(keep=[\"numpy\"])\n\nimport numpy\nimport sys, os, time\nfrom optparse import OptionParser\nimport tables\nimport matplotlib.mlab as mlab\n\n\ndef convert(\n ...
[ [ "matplotlib.mlab.rec2csv" ], [ "numpy.array", "numpy.allclose" ] ]
zxhhh97/GLM
[ "2c35d245d76dd01c854a34004172d5aa8bcb26a1" ]
[ "tasks/seq2seq/finetune.py" ]
[ "# coding=utf-8\n# Copyright (c) 2020, NVIDIA CORPORATION. All rights reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0...
[ [ "torch.nn.functional.log_softmax" ] ]
ubco-mds-2020-labs/WineVison
[ "93778bf055c3c59913718f802a652c47ec6a849a" ]
[ "pages/Wine_type.py" ]
[ "import numpy as np\nimport pandas as pd\nimport altair as alt\n\nimport dash\nimport dash_html_components as html\nimport dash_core_components as dcc\nfrom dash.dependencies import Input, Output\nimport dash_bootstrap_components as dbc\n\nfrom utils import Header, make_dash_table,Header2\n\n\n# Allow large data se...
[ [ "pandas.read_csv", "numpy.argwhere" ] ]
poodarchu/SelfSup
[ "29f7d338bef20f927bb0898f2c98da4f14b60ab1" ]
[ "examples/barlowtwins/BarlowTwins.res50.imagenet.256bs.224size.300e/net.py" ]
[ "from torch import nn\n\nfrom cvpods.layers import ShapeSpec\nfrom cvpods.modeling.backbone import Backbone\nfrom cvpods.modeling.backbone import build_resnet_backbone\n\nfrom cvpods.utils import comm\n\nfrom barlow_twins import BarlowTwins\n\n\ndef build_backbone(cfg, input_shape=None):\n \"\"\"\n Build a ba...
[ [ "torch.nn.SyncBatchNorm.convert_sync_batchnorm" ] ]
LTTM/LSR
[ "ab204895a86160a5d278fe3cee14c11532251218" ]
[ "datasets/crosscity_Dataset.py" ]
[ "# -*- coding: utf-8 -*-\nimport random\nimport scipy.io\nfrom PIL import Image, ImageOps, ImageFilter, ImageFile\nimport numpy as np\nimport copy\nimport os\nimport torch\nimport torch.utils.data as data\nimport torchvision.transforms as ttransforms\n\nfrom datasets.cityscapes_Dataset import City_Dataset, City_Dat...
[ [ "torch.utils.data.DataLoader" ] ]
mikita95/tensor2tensor
[ "7bb67a18e1e4a0cddd1d61c65c937f14c1c124e3", "7bb67a18e1e4a0cddd1d61c65c937f14c1c124e3", "7bb67a18e1e4a0cddd1d61c65c937f14c1c124e3" ]
[ "tensor2tensor/data_generators/gym_problems_test.py", "tensor2tensor/data_generators/text_encoder_test.py", "tensor2tensor/utils/trainer_lib_test.py" ]
[ "# coding=utf-8\n# Copyright 2018 The Tensor2Tensor Authors.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless requir...
[ [ "tensorflow.test.main", "tensorflow.test.get_temp_dir" ], [ "tensorflow.gfile.MakeDirs", "tensorflow.test.main", "tensorflow.test.get_temp_dir" ], [ "tensorflow.global_variables_initializer", "tensorflow.test.main", "tensorflow.test.get_temp_dir" ] ]
jvanhoefer/PEtab
[ "3f1d7be6402a889b255036ad158e38b0d5f78c5e", "3f1d7be6402a889b255036ad158e38b0d5f78c5e" ]
[ "petab/parameters.py", "petab/visualize/helper_functions.py" ]
[ "\"\"\"Functions operating on the PEtab parameter table\"\"\"\n\nimport numbers\nimport pandas as pd\nimport numpy as np\nfrom collections import OrderedDict\nfrom typing import Iterable, Set, List, Tuple, Dict, Union\n\nimport libsbml\n\nfrom . import lint, core, measurements, conditions, observables\nfrom .C impo...
[ [ "numpy.log", "pandas.read_csv", "pandas.DataFrame", "numpy.log10", "numpy.exp" ], [ "numpy.sqrt", "numpy.unique", "numpy.isnan", "matplotlib.pyplot.subplots", "pandas.DataFrame", "numpy.ceil", "numpy.std", "numpy.mean", "numpy.argsort" ] ]
G-AshwinKumar/experiment-notebook
[ "aae1c5fb9ef8f84dce5d75989ed8975797282f37" ]
[ "plugins/plugin_mcalic/mcalic_codecs.py" ]
[ "#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\n\"\"\"Wrappers for E. Maglis's M-CALIC implementation\n\"\"\"\n__author__ = \"Miguel Hernández Cabronero <miguel.hernandez@uab.cat>\"\n__date__ = \"30/04/2020\"\n\nimport os\nimport sortedcontainers\nimport tempfile\nimport numpy as np\nimport glob\nimport copy\nimp...
[ [ "numpy.fromfile" ] ]
luizsantos-1/tf-keras-vis
[ "4d26dc9c65270f738987b653d5956ea082c35c2b", "4d26dc9c65270f738987b653d5956ea082c35c2b" ]
[ "tf_keras_vis/utils/regularizers.py", "tf_keras_vis/utils/model_modifiers.py" ]
[ "import warnings\nfrom abc import ABC, abstractmethod\n\nimport numpy as np\nimport tensorflow as tf\nfrom deprecated import deprecated\n\nwarnings.warn(('`tf_keras_vis.utils.regularizers` module is deprecated. '\n 'Please use `tf_keras_vis.activation_maximization.regularizers` instead.'),\n ...
[ [ "tensorflow.norm", "tensorflow.reshape", "numpy.prod", "tensorflow.image.total_variation" ], [ "tensorflow.cast", "tensorflow.keras.Model" ] ]
chalmersplasmatheory/DREAM
[ "715637ada94f5e35db16f23c2fd49bb7401f4a27" ]
[ "py/DREAM/Settings/Equations/DistributionFunction.py" ]
[ "\nimport numpy as np\nfrom . EquationException import EquationException\nfrom . UnknownQuantity import UnknownQuantity\nfrom .. import AdvectionInterpolation\nfrom .. TransportSettings import TransportSettings\n\n\n# BOUNDARY CONDITIONS (WHEN f_re IS DISABLED)\nBC_F_0 = 1\nBC_PHI_CONST = 2\nBC_DPHI_CONST =...
[ [ "numpy.asarray", "numpy.array", "numpy.isscalar", "numpy.ones" ] ]
janilbols-w/examples
[ "8df8e747857261ea481e0b2492413d52bf7cc3a8" ]
[ "super_resolution/model.py" ]
[ "import torch\nimport torch.nn as nn\nimport torch.nn.init as init\n\n\nclass Net(nn.Module):\n def __init__(self, upscale_factor):\n super(Net, self).__init__()\n\n self.relu = nn.ReLU()\n self.conv1 = nn.Conv2d(1, 64, (5, 5), (1, 1), (2, 2))\n self.conv2 = nn.Conv2d(64, 64, (3, 3), ...
[ [ "torch.nn.init.calculate_gain", "torch.nn.Conv2d", "torch.nn.PixelShuffle", "torch.nn.init.orthogonal_", "torch.nn.ReLU" ] ]
vfonsecad/transfertools
[ "df2b25cd59c0cc55b0d41304ed346ba7607506b3" ]
[ "transfertools/models/locit.py" ]
[ "# -*- coding: UTF-8 -*-\n\"\"\"\n\nLocalized instance transfer.\n\nReference:\n V. Vercruyssen, W. Meert, J. Davis.\n Transfer Learning for Anomaly Detection through Localized and Unsupervised Instance Selection.\n In AAAI Conference on Artificial Intelligence, New York, 2020.\n\n:author: Vincent Vercruys...
[ [ "sklearn.model_selection.GridSearchCV", "sklearn.neighbors.BallTree", "numpy.arange", "numpy.nan_to_num", "numpy.random.shuffle", "numpy.linalg.norm", "numpy.cov", "numpy.mean", "sklearn.svm.SVC", "sklearn.preprocessing.StandardScaler", "numpy.zeros", "numpy.where" ...
FabioRosado/arviz
[ "6b958cc5abeb0cc3a1186f4a3dbeeaba73b899ee", "6b958cc5abeb0cc3a1186f4a3dbeeaba73b899ee", "6b958cc5abeb0cc3a1186f4a3dbeeaba73b899ee" ]
[ "arviz/plots/separationplot.py", "arviz/data/io_numpyro.py", "arviz/plots/backends/matplotlib/traceplot.py" ]
[ "\"\"\"Separation plot for discrete outcome models.\"\"\"\nimport warnings\n\nimport numpy as np\nimport xarray as xr\n\nfrom ..data import InferenceData\nfrom ..rcparams import rcParams\nfrom .plot_utils import get_plotting_function\n\n\ndef plot_separation(\n idata=None,\n y=None,\n y_hat=None,\n y_ha...
[ [ "numpy.diff" ], [ "numpy.log2" ], [ "numpy.issubdtype", "numpy.rad2deg", "numpy.atleast_1d", "numpy.atleast_2d", "numpy.zeros_like", "matplotlib.ticker.FixedLocator", "numpy.array", "matplotlib.pyplot.show", "matplotlib.pyplot.figure" ] ]
dan-1d/ev_solar_models
[ "59f9da0122f1d83a663152744c9b3f8c13fad181" ]
[ "vehicles.py" ]
[ "import numpy as np\nimport pandas as pd\n\n\nclass vehicle_ice:\n def __init__(self, name, mpg_hwy, mpg_city, average_override=None):\n self.mpg_hwy = mpg_hwy\n self.mpg_city = mpg_city\n self.name = name\n if average_override != None:\n self.mpg_hwy = average_override\n ...
[ [ "numpy.arange", "numpy.zeros", "pandas.DataFrame" ] ]
joseluisvelasco/STELLOPT
[ "e064ebb96414d5afc4e205f43b44766558dca2af" ]
[ "BENCHMARKS/DIAGNO_TEST/compare_bigtok.py" ]
[ "#!/usr/bin/env python3\nimport numpy as np #For Arrays\nfrom math import sqrt\n\nlfail = 0\nfailtol = 1.0\nfileext='bigtok'\nfilename='diagno_bench.'+fileext\ndata = np.loadtxt(filename)\n\nprint('===== B-Field ======')\nfor i in range(0, 75):\n cal = sqrt(data[i][6]*data[i][6] + data[i][7]*d...
[ [ "numpy.loadtxt" ] ]
Andrewnar/ReChorus
[ "55ceb37beb7b9967a4d18d9899075a8d88d11ddb" ]
[ "src/models/developing/TiMiRecLight.py" ]
[ "# -*- coding: UTF-8 -*-\n# @Author : Chenyang Wang\n# @Email : THUwangcy@gmail.com\n\nimport os\nimport logging\nimport torch\nimport torch.nn as nn\nimport numpy as np\nimport torch.nn.functional as F\nfrom datetime import datetime\n\nfrom models.BaseModel import SequentialModel\n\n\nclass TiMiRecLight(Sequent...
[ [ "torch.nn.functional.normalize", "torch.nn.Sequential", "torch.nn.functional.softmax", "torch.nn.KLDivLoss", "torch.nn.Dropout", "torch.isnan", "torch.load", "torch.nn.functional.log_softmax", "numpy.arange", "torch.nn.GRU", "torch.nn.Embedding", "torch.nn.Linear", ...
igorFNegrizoli/3D-modeller-and-viewer
[ "35bcc0f2d291244785f77ad1ac6798f3849edd90" ]
[ "GUI.py" ]
[ "from tkinter import *\nfrom tkinter import messagebox\n\nfrom numpy.core.arrayprint import BoolFormat\nfrom transformations import escalate, rotX, rotY, rotZ, translate\nfrom pipeline import convertMesh2SRT, perspProj, sru2src\nfrom pipeline import isMeshVisible\nfrom savePoly import salvaPoligono\nimport numpy as...
[ [ "numpy.dot", "numpy.array" ] ]
mark-koren/flow
[ "f3f6d7e9c64f6b641a464a716c7f38ca00388805" ]
[ "flow/envs/loop_accel.py" ]
[ "from flow.envs.base_env import SumoEnvironment\nfrom flow.core import rewards\nfrom flow.core import multi_agent_rewards\n\nfrom gym.spaces.box import Box\nfrom gym.spaces.tuple_space import Tuple\n\nimport numpy as np\n\nclass SimpleAccelerationEnvironment(SumoEnvironment):\n \"\"\"\n Fully functional envir...
[ [ "numpy.array", "numpy.abs" ] ]
samuelyu2002/ImVisible
[ "d0027ff803bd8ad4e6121d0aeeed2642a586b68d" ]
[ "Model/dataset.py" ]
[ "import torch\nfrom torch.utils.data import Dataset\nimport pandas as pd\nimport os\nimport numpy as np\nfrom PIL import ImageFile, Image, ImageDraw\nfrom torchvision import transforms\nfrom torchvision.transforms import functional as F\nimport random\n\nclass TrafficLightDataset(Dataset):\n \n def __init__(s...
[ [ "numpy.errstate", "torch.tensor", "pandas.read_csv", "numpy.transpose" ] ]
jereliu/GPflow-Slim
[ "3b6a9eaa4967b7285cbd188b44f670bfda6f12c6" ]
[ "gpflowSlim/models/gpmc.py" ]
[ "# Copyright 2018 Shengyang Sun\n# Copyright 2016 James Hensman, alexggmatthews\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n...
[ [ "tensorflow.variable_scope", "tensorflow.matmul", "numpy.zeros", "tensorflow.shape" ] ]
m0n0l0c0/PokerRL
[ "fa07ddf66fd0da9688bd871ae55fc1ceb863476e" ]
[ "PokerRL/rl/buffers/CircularBufferRNN.py" ]
[ "# Copyright (c) 2019 Eric Steinberger\n\n\nimport numpy as np\nimport torch\n\nfrom PokerRL.rl.buffers._circular_base import CircularBufferBase\n\n\nclass CircularBufferRNN(CircularBufferBase):\n \"\"\"\n self.games stores references to Game subclass objects. One Game instance might be referenced multiple ti...
[ [ "torch.tensor", "numpy.array", "numpy.random.randint" ] ]
abhilshit/aerial-lidar-classification
[ "d182300308bc31f6127bec1488ddcb7e25f0f4e3" ]
[ "app/experimenntal/scikit-dbscan-new.py" ]
[ "from app.PointCloudReader import PointCloudReader\nimport numpy as np\nfrom sklearn.cluster import DBSCAN, SpectralClustering\nfrom multiprocessing.dummy import Pool\nimport scipy\nfrom itertools import repeat\nfrom math import sqrt\nfrom sklearn.cluster import AgglomerativeClustering\n\n\ndef calculate_svd(cluste...
[ [ "numpy.array", "scipy.linalg.svd", "numpy.unique", "numpy.random.choice", "sklearn.cluster.DBSCAN", "numpy.append", "sklearn.cluster.AgglomerativeClustering", "numpy.logical_and", "numpy.sum", "numpy.vstack" ] ]
jpmaterial/trimesh
[ "4f493ff0a96a14e62eb7c748964fd8f4e44064c5", "4f493ff0a96a14e62eb7c748964fd8f4e44064c5", "4f493ff0a96a14e62eb7c748964fd8f4e44064c5" ]
[ "trimesh/exchange/binvox.py", "trimesh/graph.py", "trimesh/grouping.py" ]
[ "\"\"\"Parsing functions for Binvox files.\n\nhttps://www.patrickmin.com/binvox/binvox.html\n\nExporting meshes as binvox files requires binvox CL tool to be on your path.\n\"\"\"\nimport os\nimport subprocess\nimport numpy as np\nimport collections\n\nfrom distutils.spawn import find_executable\n\nfrom .. import u...
[ [ "numpy.log2", "numpy.abs", "numpy.frombuffer", "numpy.array", "numpy.where" ], [ "numpy.hstack", "numpy.radians", "numpy.abs", "numpy.unique", "numpy.reshape", "numpy.arange", "numpy.in1d", "numpy.sort", "numpy.sin", "numpy.max", "numpy.append", ...
abcxs/maskrcnn-benchmark
[ "05b10d12aa68eba525a31d0fe1159eded7aef457" ]
[ "maskrcnn_benchmark/modeling/roi_heads/box_head/loss.py" ]
[ "# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved.\nimport torch\nfrom torch.nn import functional as F\n\nfrom maskrcnn_benchmark.layers import smooth_l1_loss\nfrom maskrcnn_benchmark.modeling.box_coder import BoxCoder\nfrom maskrcnn_benchmark.modeling.matcher import Matcher\nfrom maskrcnn_ben...
[ [ "torch.nn.functional.cross_entropy", "torch.zeros_like", "torch.tensor", "torch.nonzero", "torch.stack" ] ]
konstantgr/genetic-acoustic
[ "d5ebdeba03f390a247bfbd249b2997cdc6793942" ]
[ "examples/Comsol2dAcoustics/Comsol2dAcoustics.py" ]
[ "from hpctool import ComsolModel, Task, Solver\nimport numpy as np\nfrom utils import grid, pretty_print_individual, get_multipoles_from_res\nimport os\nimport sys\nfrom loguru import logger\nfrom typing import List, Dict\nfrom scipy.optimize import differential_evolution\nimport logging\n\n\nclass SquaresModel(Com...
[ [ "numpy.max", "numpy.array", "scipy.optimize.differential_evolution", "numpy.nonzero" ] ]
keshav11/s-index
[ "9e8b123c32bbb1fc3fa92d9bca46f364d8057d54" ]
[ "code/flatten_authors_j_indx.py" ]
[ "import numpy as np\nimport pandas as pd\nimport matplotlib\nmatplotlib.use('Agg')\nimport matplotlib.pyplot as plt\nimport os\nimport sys\nimport math\n\nranked_papers = pd.read_pickle('dblp_final_paper_rankings.pickle')\n\nkeep_cols = ['authors', 'year', 'normalized_citation_score_scaled','SJR_Normalized','reach_...
[ [ "matplotlib.use", "pandas.read_pickle" ] ]
veneres/gef
[ "07912d01040ca0169977ddd49839050c81ec2349" ]
[ "examples/real-world-data/census/feat_selection.py" ]
[ "import numpy as np\nfrom tqdm import tqdm\nfrom math import comb\nfrom gamexplainer import GamExplainer\nimport lightgbm as lgbm\nimport json\n\n\ndef main():\n with open(\"config.json\") as f:\n config_dict = json.load(f)\n model_path = config_dict[\"model_path\"]\n feat_sel_out = config_d...
[ [ "numpy.save" ] ]
gancho-ivanov/pandas
[ "3cbbb96f0514f872bbf154f1ed418c7aa7300e9e", "3cbbb96f0514f872bbf154f1ed418c7aa7300e9e" ]
[ "pandas/core/indexes/interval.py", "pandas/tests/arrays/masked/test_arithmetic.py" ]
[ "\"\"\" define the IntervalIndex \"\"\"\nfrom __future__ import annotations\n\nfrom functools import wraps\nfrom operator import (\n le,\n lt,\n)\nimport textwrap\nfrom typing import (\n TYPE_CHECKING,\n Any,\n Hashable,\n cast,\n)\n\nimport numpy as np\n\nfrom pandas._config import get_option\n\n...
[ [ "numpy.linspace", "pandas.core.dtypes.common.is_dtype_equal", "pandas.core.dtypes.cast.maybe_box_datetimelike", "pandas.core.dtypes.common.is_datetime64tz_dtype", "pandas._libs.interval.IntervalTree", "pandas.core.indexes.base.Index", "numpy.concatenate", "numpy.dtype", "pandas...
data4help/shiny-bassoon
[ "a240f4b5ec3ad8642e206b582266dc79125eba58", "a240f4b5ec3ad8642e206b582266dc79125eba58" ]
[ "src/utils/callbacks.py", "src/tasks/ml/train_clf_multilabel.py" ]
[ "# %% Packages\n\nimport os\nimport tensorflow as tf\nfrom typing import Tuple\nfrom tensorflow.keras.callbacks import TensorBoard, EarlyStopping\n\n# %% Callbacks\n\n\n# Loading callbacks\ndef load_callbacks(\n name: str, monitor: str, patience: int\n) -> Tuple[TensorBoard, EarlyStopping]:\n tensorboard = lo...
[ [ "tensorflow.keras.callbacks.TensorBoard", "tensorflow.keras.callbacks.EarlyStopping" ], [ "pandas.concat", "sklearn.preprocessing.MultiLabelBinarizer", "pandas.DataFrame" ] ]
adbull/pandas
[ "a6e43a43f2cb1b4b7d46b262be2efb825d033eb8" ]
[ "pandas/tests/io/parser/test_common.py" ]
[ "\"\"\"\nTests that work on both the Python and C engines but do not have a\nspecific classification into the other test modules.\n\"\"\"\n\nimport codecs\nfrom collections import OrderedDict\nimport csv\nfrom datetime import datetime\nfrom io import BytesIO, StringIO\nimport os\nimport platform\nfrom tempfile impo...
[ [ "pandas.concat", "pandas.util.testing.ensure_clean", "pandas.Series", "pandas.compat.is_platform_windows", "pandas.util.testing.assert_produces_warning", "pandas.util.testing.assert_series_equal", "pandas.Index", "pandas.DataFrame", "pandas.util.testing.assert_frame_equal", ...
mekkianes/detectron2
[ "0d72f4397f4e49e4f7c093906600c97810079f1d", "0d72f4397f4e49e4f7c093906600c97810079f1d" ]
[ "detectron2/export/torchscript.py", "projects/DensePose/densepose/data/structures.py" ]
[ "# Copyright (c) Facebook, Inc. and its affiliates.\n\nimport os\nimport torch\n\nfrom detectron2.utils.env import TORCH_VERSION\nfrom detectron2.utils.file_io import PathManager\n\nfrom .torchscript_patch import freeze_training_mode, patch_instances\n\n\ndef export_torchscript_with_instances(model, fields):\n \...
[ [ "torch.jit.script" ], [ "torch.zeros", "torch.from_numpy", "numpy.stack", "torch.tensor", "torch.as_tensor", "torch.nn.functional.interpolate", "torch.device", "torch.flip", "numpy.array", "torch.stack" ] ]
ForexAndBeyond/FinRL
[ "a4050c54a0f4680ba0a7cd899534077583aa1332" ]
[ "finrl/finrl_meta/env_fx_trading/env_fx.py" ]
[ "import datetime\nimport math\nimport random\nimport pandas as pd\n\nimport gym\nimport numpy as np\nfrom gym import spaces\nfrom stable_baselines3.common.vec_env import DummyVecEnv\n\nfrom .util.log_render import render_to_file\nfrom .util.plot_chart import TradingChart\n\n\n\nclass tgym(gym.Env):\n \"\"\"forex...
[ [ "numpy.array", "pandas.DataFrame" ] ]
kco4776/Self_Explaining_Structures_Improve_NLP_Models
[ "dbc2d852cbe8bffd22b18425e9a4bac00d557eeb" ]
[ "explain/model.py" ]
[ "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n\"\"\"\n@file : model.py\n@author: zijun\n@contact : zijun_sun@shannonai.com\n@date : 2020/11/17 14:57\n@version: 1.0\n@desc : \n\"\"\"\nimport torch\nfrom torch import nn\nfrom transformers import AutoModel, AutoConfig\n\nfrom datasets.collate_functions import co...
[ [ "torch.nn.functional.softmax", "torch.tanh", "torch.nn.Linear", "torch.mul", "torch.index_select" ] ]
dpstart/slowdl
[ "c90d56f9272b791bc2dfcc785100d0a6e2a72bff" ]
[ "slowgrad/utils.py" ]
[ "import numpy as np\n\n\ndef layer_init_uniform(*x):\n ret = np.random.uniform(-1., 1., size=x) / np.sqrt(np.prod(x))\n return ret.astype(np.float32)\n\n\ndef fetch(url):\n import requests, os, hashlib, tempfile\n fp = os.path.join(tempfile.gettempdir(),\n hashlib.md5(url.encode('ut...
[ [ "numpy.random.uniform", "numpy.prod" ] ]
H2O-YT/manim
[ "ae65662823a95b1110536fae34e06d5c540cc424" ]
[ "manimlib/mobject/coordinate_systems.py" ]
[ "import numpy as np\nimport numbers\n\nfrom manimlib.constants import *\nfrom manimlib.mobject.functions import ParametricCurve\nfrom manimlib.mobject.geometry import Arrow\nfrom manimlib.mobject.geometry import Line\nfrom manimlib.mobject.geometry import DashedLine\nfrom manimlib.mobject.geometry import Rectangle\...
[ [ "numpy.arange", "numpy.array" ] ]
aligholami/kepler
[ "a272ac427e09892cd44ade70e910272c4f69c638" ]
[ "lib/models/ScanRefer2D/cap_satnt.py" ]
[ "# Show, Attend and Tell Captioning Lightning Module\n# Author: Ali Gholami (https://aligholami.github.io)\nimport torch.nn as nn\nfrom itertools import chain\nimport torch.optim as optim\nfrom torchvision import transforms\nfrom lib.data.vocab import VocabTools\nfrom torch.utils.data import DataLoader\nfrom lib.ca...
[ [ "torch.optim.Adam", "torch.nn.CrossEntropyLoss", "torch.utils.data.DataLoader", "torch.optim.lr_scheduler.MultiStepLR" ] ]
Exlsunshine/mlprodict
[ "9ea1a0fc85726822cae82c0b27b23b46f9ef351a", "9ea1a0fc85726822cae82c0b27b23b46f9ef351a", "9ea1a0fc85726822cae82c0b27b23b46f9ef351a", "9ea1a0fc85726822cae82c0b27b23b46f9ef351a", "9ea1a0fc85726822cae82c0b27b23b46f9ef351a" ]
[ "_unittests/ut_onnxrt/test_onnxrt_validate_benchmark.py", "mlprodict/onnxrt/ops_cpu/op_min.py", "_unittests/ut_onnxrt/test_onnxrt_side_by_side.py", "mlprodict/sklapi/onnx_transformer.py", "_unittests/ut_onnxrt/test_rt_valid_model_labels.py" ]
[ "\"\"\"\n@brief test log(time=65s)\n\"\"\"\nimport os\nimport unittest\nfrom logging import getLogger\nfrom pandas import DataFrame\nfrom pyquickhelper.loghelper import fLOG\nfrom pyquickhelper.pycode import get_temp_folder, ExtTestCase\nfrom sklearn.exceptions import ConvergenceWarning\nfrom sklearn.utils.tes...
[ [ "sklearn.utils.testing.ignore_warnings", "pandas.DataFrame" ], [ "numpy.minimum" ], [ "sklearn.gaussian_process.kernels.ConstantKernel", "sklearn.gaussian_process.kernels.RBF" ], [ "numpy.array", "sklearn.base.BaseEstimator.__init__", "sklearn.base.TransformerMixin.__in...
Enyokid/keras-gan-style
[ "956072649be0b4ef39a3c18c2c2f2510db87a445" ]
[ "train-gan.py" ]
[ "import os, sys\r\nos.environ['CUDA_VISIBLE_DEVICES'] = '0'\r\nimport numpy as np\r\nimport cv2 as cv\r\nimport tensorflow as tf\r\nfrom tensorflow.keras import layers\r\nfrom tensorflow.keras.callbacks import ModelCheckpoint, LearningRateScheduler, EarlyStopping, TensorBoard\r\nfrom net import *\r\nfrom tensorflow...
[ [ "tensorflow.device", "tensorflow.keras.models.Model", "sklearn.utils.shuffle", "tensorflow.keras.layers.concatenate", "numpy.ones", "tensorflow.keras.optimizers.Adam", "numpy.zeros", "tensorflow.keras.layers.Input" ] ]
brendancol/xarray-spatial
[ "36d53b75086b760cab5100a12fcbda946dd85a25", "36d53b75086b760cab5100a12fcbda946dd85a25" ]
[ "xrspatial/gpu_rtx/mesh_utils.py", "xrspatial/tests/test_zonal.py" ]
[ "import numba as nb\nimport numpy as np\nimport cupy\n\n\n@nb.cuda.jit\ndef _triangulate_terrain_kernel(verts, triangles, data, H, W, scale, stride):\n global_id = stride + nb.cuda.grid(1)\n if global_id < W*H:\n h = global_id // W\n w = global_id % W\n mesh_map_index = h * W + w\n\n ...
[ [ "numpy.int32", "numpy.zeros", "numpy.empty" ], [ "numpy.array_equal", "numpy.linspace", "numpy.asarray", "numpy.unique", "numpy.ones", "numpy.array", "numpy.zeros", "numpy.isclose" ] ]
Joshuawadd/rlcard
[ "de2da05a9b32a39e0d8bbfc1cd589d88a6580c56" ]
[ "rlcard/utils/logger.py" ]
[ "import os\nimport csv\n\n\nclass Logger(object):\n ''' Logger saves the running results and helps make plots from the results\n '''\n\n def __init__(self, log_dir):\n ''' Initialize the labels, legend and paths of the plot and log file.\n\n Args:\n log_path (str): The path the log...
[ [ "matplotlib.pyplot.subplots", "matplotlib.pyplot.close" ] ]
mwcraig/pyspeckit
[ "6d6c09aac29549a8c094d97fb385c9283422bb82", "6d6c09aac29549a8c094d97fb385c9283422bb82" ]
[ "pyspeckit/cubes/mapplot.py", "pyspeckit/cubes/cubes.py" ]
[ "\"\"\"\nMapPlot\n-------\n\nMake plots of the cube and interactively connect them to spectrum plotting.\nThis is really an interactive component of the package; nothing in here is\nmeant for publication-quality plots, but more for user interactive analysis.\n\nThat said, the plotter makes use of `APLpy <https://gi...
[ [ "numpy.abs", "numpy.isfinite", "matplotlib.patches.Circle", "numpy.round", "matplotlib.pyplot.colorbar", "numpy.concatenate", "numpy.array", "matplotlib.pyplot.figure" ], [ "numpy.polyfit", "scipy.interpolate.UnivariateSpline", "numpy.sqrt", "numpy.isfinite", ...
hsjoe/violentpython
[ "e4ecaa29088a0bfc205e3339ae88410d831766ee" ]
[ "stock/test.py" ]
[ "# coding=utf-8\nimport pandas as pd\nimport numpy as np\nimport sys\nimport os\nimport tushare as ts\nimport matplotlib.pyplot as plt\n\nts = pd.Series(np.random.randn(1000), index=pd.date_range('1/1/2000', periods=1000))\n\nts = ts.cumsum()\nts.plot()\nts.figure()" ]
[ [ "numpy.random.randn", "pandas.date_range" ] ]
HansjoergW/Deep-Reinforcement-Learning-Hands-On-Second-Edition
[ "5d27d6f9057bb5526e944274fb803dc8a3a8395b", "5d27d6f9057bb5526e944274fb803dc8a3a8395b" ]
[ "Chapter04/01_cartpole.py", "Chapter08/lib/dqn_model.py" ]
[ "#!/usr/bin/env python3\nimport gym\nfrom collections import namedtuple\nimport numpy as np\nfrom tensorboardX import SummaryWriter\n\nimport torch\nimport torch.nn as nn\nimport torch.optim as optim\n\n\nHIDDEN_SIZE = 128\nBATCH_SIZE = 16\nPERCENTILE = 70\n\n\nclass Net(nn.Module):\n def __init__(self, obs_size...
[ [ "torch.nn.Softmax", "torch.nn.CrossEntropyLoss", "torch.LongTensor", "numpy.percentile", "torch.nn.Linear", "torch.FloatTensor", "numpy.mean", "torch.nn.ReLU" ], [ "torch.nn.Linear", "torch.nn.ReLU", "torch.nn.Conv2d", "torch.zeros" ] ]
Yuanhang8605/CNN-fro-cifar10
[ "296ecf39579cfae541af83159bc2c9403027d95a" ]
[ "network/inception.py" ]
[ "\"\"\" Inception model.\n\"\"\"\n\nimport numpy as np\nimport tensorflow as tf\nimport six\nfrom net import Net\nimport ops\n\nclass Inception(Net):\n \"\"\" Inception model. \"\"\"\n\n def __init__(self, cfgs, images, labels, mode='train', multi_gpu_mode=False):\n \"\"\" ResNet constructor. \"\"\"\n ...
[ [ "tensorflow.variable_scope", "tensorflow.nn.softmax_cross_entropy_with_logits", "tensorflow.reduce_mean" ] ]
Gaurav3963/AGS-intern-files
[ "ee4db12755cf680c0575b3c1a6a6146ee415743a", "ee4db12755cf680c0575b3c1a6a6146ee415743a" ]
[ "Nikhil/assignment6.py", "Gaurav/Assignment 7/faster thread.py" ]
[ "import pandas as pd\nimport pyodbc\n\ndata = pd.read_csv (r'C:\\Users\\Nikhil\\Desktop\\ags_intern\\dataset.csv')\nstudio = pyodbc.connect('Driver={SQL Server};''Server=DESKTOP-9T4GEVI;''Database=patil;''Trusted_Connection=yes;')\n\ncursor = studio.cursor()\n\n#data = pd.DataFrame(data, columns= ['ID','Name'] )\n\...
[ [ "pandas.read_csv" ], [ "pandas.read_csv" ] ]
eribean/GIRTH
[ "daf22773aa9cd1c819bf732e1061ebf5cc4dc40e" ]
[ "common/polyserial.py" ]
[ "import numpy as np\nfrom scipy.stats import norm\nfrom scipy.optimize import fminbound\n\n\n__all__ = [\"polyserial_correlation\"]\n\n\ndef polyserial_correlation(continuous, ordinal):\n \"\"\"Computes the polyserial correlation.\n \n Estimates the correlation value based on a bivariate\n normal distri...
[ [ "numpy.log", "scipy.stats.norm.cdf", "numpy.sqrt", "numpy.unique", "scipy.optimize.fminbound" ] ]
cbeiraod/grafica
[ "6f47a47f47625b4bdb83dd15e2fcbaa9c8ca2d05" ]
[ "grafica/PlotlyFigure.py" ]
[ "from .figure import Figure\nfrom .traces import Scatter, ErrorBand, Histogram, Heatmap, Contour, KDE\nimport plotly.graph_objects as go\nimport plotly\nimport numpy as np\nimport warnings\n\nclass PlotlyFigure(Figure):\n\tdef __init__(self):\n\t\tsuper().__init__()\n\t\tself.plotly_figure = go.Figure()\n\t\n\t# Me...
[ [ "numpy.log", "numpy.array", "numpy.random.rand" ] ]
Dorcoh4/BARTScore
[ "e24fd22b80a01ef142ce43e24ec585f1ee8c1ff2" ]
[ "train/eli5.py" ]
[ "print(\"importing\")\n\nfrom datasets import load_dataset\nfrom datasets import load_metric\nfrom transformers import AutoTokenizer, AutoModelForSequenceClassification\nfrom transformers import TrainingArguments, DefaultFlowCallback, PrinterCallback\nfrom transformers import Trainer\nimport torch\nfrom torch impor...
[ [ "torch.tensor" ] ]
alexis-thual/audio-signal-analysis
[ "226e654d7482869c0976199babebac1c67c3803a" ]
[ "test.py" ]
[ "import numpy as np\n\na = np.array([1,2,3,4,5])\nb = np.argmax(a[1:2])\nb\n" ]
[ [ "numpy.array", "numpy.argmax" ] ]
Pedestrian1671022/keras_yolov3
[ "1d66375f67d87ed7d3967364373ec8cdea776ef1" ]
[ "yolo.py" ]
[ "# -*- coding: utf-8 -*-\n\"\"\"\nClass definition of YOLO_v3 style detection model on image and video\n\"\"\"\n\nimport colorsys\nimport os\nfrom timeit import default_timer as timer\n\nimport numpy as np\nfrom keras import backend as K\nfrom keras.models import load_model\nfrom keras.layers import Input\nfrom PIL...
[ [ "numpy.expand_dims", "numpy.random.seed", "numpy.asarray", "numpy.random.shuffle", "numpy.floor", "numpy.array" ] ]
pbotros/TRACER
[ "269e17ca27fe0fb78c30484d8685d119caab5dbb", "269e17ca27fe0fb78c30484d8685d119caab5dbb" ]
[ "tracer/index_tracker.py", "tracer/probes_insertion.py" ]
[ "#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\n\"\"\"\nCreated on Mon Dec 14 13:31:04 2020\n\n@author: jacopop\n\"\"\"\n\n# Class to scroll the atlas slices (coronal, sagittal and horizontal) \nclass IndexTracker(object):\n def __init__(self, ax, X, pixdim, p, S=None):\n self.ax = ax\n self.p...
[ [ "numpy.polyfit", "matplotlib.colors.to_rgb", "matplotlib.pyplot.scatter" ], [ "matplotlib.pyplot.subplots", "numpy.linalg.norm", "matplotlib.pyplot.draw", "scipy.spatial.distance.euclidean", "matplotlib.pyplot.get_current_fig_manager", "numpy.array", "numpy.where", ...
google-research/pathdreamer
[ "dc607faf3a6d3011ddd2e4723d53122235774167" ]
[ "utils/utils_test.py" ]
[ "# Copyright 2021 Google LLC.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable law or agreed ...
[ [ "tensorflow.zeros", "tensorflow.cast", "tensorflow.random.uniform", "tensorflow.test.main", "tensorflow.zeros_like", "tensorflow.one_hot", "tensorflow.random.normal" ] ]
Shetty4L/malware_classification
[ "3a71f257011efd1eca96696d79202040857f909d" ]
[ "model.py" ]
[ "from __future__ import absolute_import\nfrom __future__ import division\nfrom __future__ import print_function\n\nimport numpy as np\nimport tensorflow as tf\n\nNUM_CLASSES = 6\n\nIMAGE_SIZE = 144\nIMAGE_PIXELS = 500\n\ndef _variable_summaries(var, name):\n\twith tf.variable_scope('summaries'):\n\t\tmean = tf.redu...
[ [ "tensorflow.to_int64", "tensorflow.matmul", "tensorflow.nn.softmax", "tensorflow.Variable", "tensorflow.reduce_mean", "tensorflow.scalar_summary", "tensorflow.cast", "tensorflow.constant_initializer", "tensorflow.nn.sparse_softmax_cross_entropy_with_logits", "tensorflow.nam...
GindaChen/MLOS
[ "342d321bd4e15ca3bfb29be00d5a19ccd618b217" ]
[ "source/Mlos.Python/mlos/Optimizers/BayesianOptimizer.py" ]
[ "#\r\n# Copyright (c) Microsoft Corporation.\r\n# Licensed under the MIT License.\r\n#\r\nimport pandas as pd\r\n\r\nfrom mlos.Logger import create_logger\r\n\r\nfrom mlos.Optimizers.BayesianOptimizerConfigStore import bayesian_optimizer_config_store\r\nfrom mlos.Optimizers.BayesianOptimizerConvergenceState import ...
[ [ "pandas.DataFrame" ] ]
hohe12ly/inundation-mapping
[ "d133addd4d730b5c468dcf1a8f7dfab35c55cbd7", "dcf414f5655ecafbf8bb62cd219aef405e55f0a2" ]
[ "tools/gms_tools/compile_computational_stats.py", "tools/generate_categorical_fim_mapping.py" ]
[ "#!/usr/bin/env python3\n\nimport argparse\nimport pandas as pd\nimport numpy as np\nfrom glob import iglob\nfrom os.path import join\n\n# desired output for branches\n# dataframe columns: HUC, branch_id, exit status, ,time, ram, \n\ndef compile_summary(gms_output_dir,ouput=None):\n\n unit_summary = join(gms_out...
[ [ "pandas.read_csv" ], [ "pandas.read_csv" ] ]
drewrisinger/pyGSTi
[ "dd4ad669931c7f75e026456470cf33ac5b682d0d", "dd4ad669931c7f75e026456470cf33ac5b682d0d", "dd4ad669931c7f75e026456470cf33ac5b682d0d", "dd4ad669931c7f75e026456470cf33ac5b682d0d", "dd4ad669931c7f75e026456470cf33ac5b682d0d" ]
[ "test/unit/util.py", "pygsti/report/workspace.py", "test/test_packages/mpi/testmpiMain.py", "pygsti/report/plothelpers.py", "test/unit/objects/test_spamvec.py" ]
[ "\"\"\"Utilities shared by unit tests\"\"\"\nimport sys\nimport numpy as np\nimport numbers\nimport functools\nimport types\nfrom contextlib import contextmanager\nimport os\nimport warnings\nfrom pathlib import Path\nfrom unittest import mock\nfrom tempfile import TemporaryDirectory\nimport unittest\n\n\ndef needs...
[ [ "numpy.set_printoptions", "numpy.linalg.norm", "numpy.array_equal" ], [ "numpy.array", "numpy.empty" ], [ "numpy.arange", "numpy.linalg.norm", "numpy.concatenate", "numpy.zeros", "numpy.empty" ], [ "numpy.linalg.eigvals", "numpy.sqrt", "numpy.abs", ...
qwsae10/pygemini
[ "adc6b2401ac9fc8b7cb1fc8870322f730a3383a3", "adc6b2401ac9fc8b7cb1fc8870322f730a3383a3", "adc6b2401ac9fc8b7cb1fc8870322f730a3383a3" ]
[ "src/gemini3d/compare/input.py", "src/gemini3d/grid/cartesian.py", "src/gemini3d/raw/read.py" ]
[ "from __future__ import annotations\nfrom pathlib import Path\nimport logging\n\nimport numpy as np\n\nfrom .. import read\n\nfrom .plot import plotdiff\nfrom .utils import err_pct, load_tol\nfrom .precip import compare_precip\nfrom .efield import compare_Efield\n\n\ndef compare_input(\n new_dir: Path,\n refd...
[ [ "numpy.allclose" ], [ "numpy.linspace", "numpy.empty_like", "numpy.cos", "numpy.ones", "numpy.sin", "numpy.concatenate", "numpy.append", "numpy.broadcast_to", "numpy.insert", "numpy.array", "numpy.zeros", "numpy.empty" ], [ "numpy.fromfile", "num...
rsoren/limetr
[ "d1145e6811bc492e5641fd04108d4d342f904284" ]
[ "tests/izmat_lsvd.py" ]
[ "# check utils lsvd\n\n\ndef izmat_lsvd():\n import numpy as np\n from limetr.special_mat import izmat\n\n ok = True\n tol = 1e-10\n # problem 1, tall matrix\n # -------------------------------------------------------------------------\n n, k = 6, 3\n z = np.random.randn(n, k)\n tr_u, tr_...
[ [ "numpy.linalg.svd", "numpy.random.randn", "numpy.zeros" ] ]
serge2016/deepvariant
[ "07dc4bedd0d124fff6386dcfa5fd88c6b200362c", "07dc4bedd0d124fff6386dcfa5fd88c6b200362c" ]
[ "deepvariant/vcf_stats.py", "deepvariant/variant_caller_test.py" ]
[ "# Copyright 2019 Google LLC.\n#\n# Redistribution and use in source and binary forms, with or without\n# modification, are permitted provided that the following conditions\n# are met:\n#\n# 1. Redistributions of source code must retain the above copyright notice,\n# this list of conditions and the following dis...
[ [ "numpy.histogram", "numpy.bincount" ], [ "numpy.array", "numpy.log10", "numpy.isfinite", "numpy.testing.assert_allclose" ] ]
barronh/MONET
[ "acd72487c7aeff66d89f87fa663a9c96fa9b7bb0" ]
[ "monet/models/hysplit.py" ]
[ "from __future__ import division, print_function\n\nfrom builtins import object, zip\n\nimport pandas as pd\nimport xarray as xr\nfrom dask.diagnostics import ProgressBar\nfrom numpy import array\nfrom past.utils import old_div\n\n# This file is to deal with CAMx code - try to make it general for CAMx 4.7.1 --> 5.1...
[ [ "numpy.array", "pandas.Series" ] ]
aprilpear/holdout-sgd
[ "fa81bce57fb98aef262536fb2d7a26567d3143f7" ]
[ "holdout_sgd/train_decentralized.py" ]
[ "import argparse \nimport numpy as np\nimport json\nimport torch\nfrom torchvision import datasets, transforms\n\nfrom _params import add_common_params, add_decentralized_params\nfrom _train_utils import test, plot_learning_curve\nfrom _node import Node\nfrom _byzantine_node import ByzantineNode\nfrom _data_utils i...
[ [ "torch.manual_seed", "torch.from_numpy", "numpy.ceil", "numpy.mean", "torch.cuda.is_available", "numpy.array", "numpy.where" ] ]
Dangzilla/BiorbdOptim
[ "adb1898b86282c87b3fd186b13e00a8202ceb21c", "adb1898b86282c87b3fd186b13e00a8202ceb21c" ]
[ "tests/test_torque_driven_with_contact_ocp.py", "biorbd_optim/path_conditions.py" ]
[ "\"\"\"\nTest for file IO.\nIt tests the results of an optimal control problem with torque_driven_with_contact problem type regarding the proper functioning of :\n- the maximize/minimize_predicted_height_CoM objective\n- the contact_forces_inequality constraint\n- the non_slipping constraint\n\"\"\"\nimport importl...
[ [ "numpy.testing.assert_equal", "numpy.testing.assert_array_less", "numpy.testing.assert_almost_equal", "numpy.array", "numpy.zeros" ], [ "numpy.asarray", "numpy.repeat", "numpy.concatenate" ] ]
johnson7788/TextBrewer
[ "fa7fa4d4a2a8debde5b148d448238f3b4fa1aa9a", "fa7fa4d4a2a8debde5b148d448238f3b4fa1aa9a" ]
[ "examples/mnli_example/main.distill.py", "huazhuang/main.trainer_predict_api.py" ]
[ "import logging\nimport time\nlogging.basicConfig(\n format='%(asctime)s - %(levelname)s - %(name)s - %(message)s',\n datefmt='%Y/%m/%d %H:%M:%S',\n level=logging.INFO,\n )\nlogger = logging.getLogger(\"Main\")\n\nimport os,random\nimport numpy as np\nimport torch\nfrom utils_glue import output_modes, ...
[ [ "torch.utils.data.DistributedSampler", "torch.distributed.init_process_group", "numpy.random.seed", "torch.load", "torch.manual_seed", "torch.utils.data.SequentialSampler", "numpy.squeeze", "torch.utils.data.DataLoader", "torch.utils.data.RandomSampler", "torch.utils.data.C...
mf-zhang/flownet2-pytorch
[ "aba5bb57e9b9c145be909f61cd9212a59fdfa737" ]
[ "zmf_main_py37_2resume.py" ]
[ "#!/usr/bin/env python\n\nimport torch\nimport torch.nn as nn\nfrom torch.utils.data import DataLoader\nfrom torch.autograd import Variable\nfrom tensorboardX import SummaryWriter\n\nimport argparse, os, sys, subprocess\nimport setproctitle, colorama\nimport numpy as np\nfrom tqdm import tqdm\nfrom glob import glob...
[ [ "torch.mean", "torch.cuda.manual_seed", "torch.load", "numpy.isnan", "torch.manual_seed", "torch.utils.data.DataLoader", "torch.no_grad", "torch.cuda.is_available", "torch.cuda.device_count", "numpy.array", "torch.autograd.Variable" ] ]
gchure/diauxic_evolution
[ "5917d3ae5f9a3a5db0f037e9f7b5768cd1ffe92f", "5917d3ae5f9a3a5db0f037e9f7b5768cd1ffe92f" ]
[ "code/processing/2021-02-25_NCM3722_RNA_isolation/growth_processing.py", "code/processing/plate_reader/2021-04-15_NCM3722_glucose_acetate_tecan_comparison/analysis.py" ]
[ "#%%\nimport numpy as np \nimport pandas as pd \nimport diaux.viz \nimport arviz as az\nimport cmdstanpy\nimport altair as alt\nfrom altair_saver import save\ncolors, _ = diaux.viz.altair_style()\nalt.data_transformers.disable_max_rows()\n\n# Define constants of the experiment \nDATE = '2021-02-25'\nSTRAIN = 'NCM3...
[ [ "pandas.read_csv", "pandas.to_datetime", "numpy.linspace", "numpy.percentile", "pandas.DataFrame", "numpy.exp" ], [ "pandas.concat", "pandas.read_csv", "numpy.log", "numpy.linspace", "pandas.DataFrame", "numpy.exp" ] ]
siagholami/aws-documentation
[ "2d06ee9011f3192b2ff38c09f04e01f1ea9e0191" ]
[ "documents/aws-deep-learning-amis/examples/keras-mxnet/cifar10_resnet_multi_gpu.py" ]
[ "\"\"\"Trains a ResNet on the CIFAR10 dataset.\n\nResNet v1\n[a] Deep Residual Learning for Image Recognition\nhttps://arxiv.org/pdf/1512.03385.pdf\n\nResNet v2\n[b] Identity Mappings in Deep Residual Networks\nhttps://arxiv.org/pdf/1603.05027.pdf\n\"\"\"\n\nfrom __future__ import print_function\nimport keras\nfrom...
[ [ "numpy.mean", "numpy.sqrt" ] ]
ianmcook/strata-ny-2019
[ "715d1db65ed64f5be700790fef938802375159e2" ]
[ "2_machine_learning/61_tf_confusion_matrix.py" ]
[ "# Copyright 2019 Cloudera, Inc.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable law or agreed t...
[ [ "sklearn.metrics.confusion_matrix" ] ]
aasseman/pytorchpipe
[ "9cb17271666061cb19fe24197ecd5e4c8d32c5da", "9cb17271666061cb19fe24197ecd5e4c8d32c5da" ]
[ "ptp/components/models/vision/lenet5.py", "ptp/workers/trainer.py" ]
[ "#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\n#\n# Copyright (C) IBM Corporation 2019\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/L...
[ [ "torch.nn.functional.log_softmax", "torch.nn.Conv2d", "torch.nn.Linear", "torch.nn.MaxPool2d", "torch.nn.functional.relu" ], [ "torch.cuda.device_count", "torch.no_grad" ] ]
CamHolman/spiketools
[ "56c37a50413a015cfa9c75725cbe7d4ef54968a5", "56c37a50413a015cfa9c75725cbe7d4ef54968a5" ]
[ "spiketools/stats/generators.py", "spiketools/plts/space.py" ]
[ "\"\"\"Generators for drawing data from statistical distributions.\"\"\"\n\nimport numpy as np\n\n###################################################################################################\n###################################################################################################\n\ndef poisson_tr...
[ [ "numpy.random.exponential" ], [ "numpy.isnan", "matplotlib.pyplot.colorbar", "scipy.ndimage.gaussian_filter" ] ]
kslin/miRNA_models
[ "5b034b036e5aa10ab62f91f8adccec473e29ec34", "5b034b036e5aa10ab62f91f8adccec473e29ec34" ]
[ "get_features/tf_utils.py", "get_features/write_tfrecords_utr.py" ]
[ "import numpy as np\nimport pandas as pd\nfrom scipy import stats\nimport tensorflow as tf\n\n\n### TFRecords Functions ###\ndef _float_feature(value):\n \"\"\"Returns a float_list from a float / double.\"\"\"\n return tf.train.Feature(float_list=tf.train.FloatList(value=value))\n\ndef _int64_feature(value):\...
[ [ "tensorflow.train.BytesList", "tensorflow.train.FloatList", "tensorflow.train.Int64List" ], [ "pandas.concat", "pandas.read_csv", "numpy.set_printoptions", "tensorflow.python_io.TFRecordWriter", "numpy.nanmean", "tensorflow.train.Features" ] ]
dewloosh/dewloosh-solid
[ "dbd6757ddd1373df870ccd99f5ee791c08d342cb", "dbd6757ddd1373df870ccd99f5ee791c08d342cb" ]
[ "src/dewloosh/solid/fourier/preproc.py", "src/dewloosh/solid/fem/structure/linemesh.py" ]
[ "# -*- coding: utf-8 -*-\nimport numpy as np\nfrom numba import njit, prange\nfrom numpy import ndarray, pi as PI\n\nfrom dewloosh.math import squeeze\nfrom dewloosh.math.array import atleast3d\n\n\n@squeeze(True)\ndef lhs_Navier(size: tuple, shape: tuple, *args, D: ndarray,\n S: ndarray = None, model...
[ [ "numpy.zeros" ], [ "numpy.ones" ] ]
13060923171/Crawl-Project2
[ "effab1bf31979635756fc272a7bcc666bb499be2", "effab1bf31979635756fc272a7bcc666bb499be2" ]
[ "土流网/雷达图.py", "台海舆论-数据分析(可视化系统)/demo/Terrace_Line.py" ]
[ "import pandas as pd\nfrom pyecharts.charts import Radar\nfrom pyecharts import options as opts\nfrom pyecharts.globals import CurrentConfig,ThemeType\n\ndf = pd.read_excel('real_estate_info.xlsx')['规划用途']\ndatas = df.value_counts()\nitems = datas.index.tolist()\ncolors = ['#FF0000', '#FF4500', '#00FA9A', '#FFFFF0'...
[ [ "pandas.read_excel" ], [ "pandas.read_excel" ] ]
ybayle/SMC2017
[ "c3131872d86d03abdd954c23e6d3cc224d9bc5f2" ]
[ "src/bayle.py" ]
[ "# -*- coding: utf-8 -*-\n#!/usr/bin/python\n#\n# Author Yann Bayle\n# E-mail bayle.yann@live.fr\n# License MIT\n# Created 01/12/2016\n# Updated 01/12/2016\n# Version 1.0.0\n#\n\n\"\"\"\nDescription of bayle.py\n======================\n\n0 Input the local extracted features from YAAFE\n 13 MFCC per...
[ [ "sklearn.metrics.recall_score", "sklearn.metrics.precision_score", "sklearn.tree.DecisionTreeClassifier", "sklearn.ensemble.AdaBoostClassifier", "numpy.append", "numpy.mean", "sklearn.metrics.f1_score", "numpy.array", "numpy.histogram", "sklearn.metrics.accuracy_score" ] ...
pjchungmd/StemmlerProject
[ "bffcfbf5dc9171f0d62160f058306a2bb6cce2eb" ]
[ "outputs.py" ]
[ "import re\nimport pickle\nimport matplotlib.pyplot as plt\n\nfrom icd9cms.icd9 import search\n\nwith open(\"../data/pcode_dict.txt\", \"rb\") as fp: \n icd9_pcode_dict = pickle.load(fp)\n\ndef plot_scores(score_df, model, bins=100, ft='X_scores'):\n \n #rng = [score_df[ft].min(), score_df[ft].mean() + 2*s...
[ [ "matplotlib.pyplot.legend", "matplotlib.pyplot.axvline", "matplotlib.pyplot.hist", "matplotlib.pyplot.show" ] ]
kwadwo00/ceviche
[ "a1ee155304c4679b262e4fdf8c8a28bc4d060ec8" ]
[ "ceviche/utils.py" ]
[ "import numpy as np\nimport scipy.sparse as sp\nimport copy\nimport autograd.numpy as npa\nimport matplotlib.pylab as plt\nfrom autograd.extend import primitive, vspace, defvjp, defjvp\n\n\"\"\" Useful functions \"\"\"\n\n\n\"\"\" ==================== SPARSE MATRIX UTILITIES ==================== \"\"\"\n\ndef make_...
[ [ "numpy.flipud", "scipy.sparse.random", "numpy.hamming", "scipy.sparse.vstack", "scipy.sparse.coo_matrix", "matplotlib.pylab.xlim", "numpy.arange", "numpy.argmax", "matplotlib.pylab.plot", "numpy.zeros", "numpy.fft.fftfreq", "scipy.sparse.hstack", "numpy.array", ...
BarracudaPff/code-golf-data-pythpn
[ "42e8858c2ebc6a061012bcadb167d29cebb85c5e", "42e8858c2ebc6a061012bcadb167d29cebb85c5e", "42e8858c2ebc6a061012bcadb167d29cebb85c5e" ]
[ "parallax/parallax/examples/skip_thoughts/skip_distributed_driver.py", "models/research/syntaxnet/dragnn/tools/parser_trainer.py", "models/research/object_detection/dataset_tools/create_oid_tf_record.py" ]
[ "import sys\nimport os\nimport json\nimport time\nimport tensorflow as tf\nfrom tensorflow.core.protobuf import config_pb2\nimport parallax\nimport parallax_config\nimport configuration\nimport skip_thoughts_model\nFLAGS = tf.app.flags.FLAGS\ntf.app.flags.DEFINE_string(\"data_path\", None, \"\"\"Where to training/t...
[ [ "tensorflow.contrib.slim.learning.create_train_op", "tensorflow.Graph", "tensorflow.constant", "tensorflow.app.flags.DEFINE_integer", "tensorflow.app.flags.DEFINE_string", "tensorflow.logging.set_verbosity", "tensorflow.train.AdamOptimizer", "tensorflow.app.flags.DEFINE_boolean", ...
AHaryanto/azure-automl-mlops
[ "4448ce0733ca45dab3bf47907ed264536b45a453" ]
[ "src/deployment/consume.py" ]
[ "import json\nimport os\nimport sys\n\nimport pandas as pd\nfrom azureml.core.webservice import AksWebservice\nfrom loguru import logger\n\nsys.path.append(os.getcwd())\nimport config as f # noqa: E402\n\n# Load test data\ndata_path = os.path.join('data', 'regression_kaggle_retail_data_analytics',\n ...
[ [ "pandas.read_csv", "pandas.DataFrame.from_dict" ] ]
jorgimello/meta-learning-fer
[ "793610ae8471f794a6837930d8bb51866c1f7c02", "793610ae8471f794a6837930d8bb51866c1f7c02" ]
[ "data/ck/check_data.py", "data/generate_training_data.py" ]
[ "import numpy as np\nimport os, cv2\n\nimgs = np.load('test_set_ck_extended_no_resize.npy')\nlbls = np.load('test_labels_ck_extended_no_resize.npy')\n\nfor i in range(imgs.shape[0]):\n\tprint (lbls[i])\n\tcv2.imshow('img', imgs[i])\n\tcv2.waitKey(0)\n", "# Source: https://github.com/Microsoft/FERPlus\n\n#\n# Copy...
[ [ "numpy.load" ], [ "numpy.asarray" ] ]
Mithril-NTU/reco-gym
[ "5b494eb719d528096751c886b9ab21b1dbcab20f" ]
[ "recogym/envs/abstract.py" ]
[ "from abc import ABC\n\nimport gym\nimport numpy as np\nimport pandas as pd\nfrom gym.spaces import Discrete\nfrom numpy.random.mtrand import RandomState\nfrom scipy.special import expit as sigmoid\nfrom tqdm import trange\n\nfrom .configuration import Configuration\nfrom .context import DefaultContext\nfrom .featu...
[ [ "scipy.special.expit", "numpy.arange", "pandas.UInt32Dtype", "pandas.DataFrame", "numpy.ones", "numpy.array", "numpy.zeros", "numpy.random.mtrand.RandomState", "numpy.random.randint" ] ]
AyrtonB/National-Grid-Data-Portal
[ "b70cc684ecb92b82ba3de63fadfbf0caee30c943" ]
[ "build/lib/NGDataPortal/NGDataPortal.py" ]
[ "\"\"\"\nImports\n\"\"\"\nimport pandas as pd\nimport warnings\nimport requests\nimport json\nimport os\n\n\"\"\"\nMain Scripts\n\"\"\"\n## Loading static files\nresource_filepath = os.path.join(os.path.dirname(__file__), 'stream_to_resource_id.json')\nwith open(resource_filepath, 'r') as fp:\n stream_to_id_map ...
[ [ "pandas.DataFrame" ] ]
sergiopasra/glue
[ "c25a217a122a11818382672c99cb21f57a30636f", "c25a217a122a11818382672c99cb21f57a30636f", "c25a217a122a11818382672c99cb21f57a30636f" ]
[ "glue/app/qt/tests/test_preferences.py", "glue/core/data_exporters/tests/test_gridded_fits.py", "glue/dialogs/component_arithmetic/qt/component_arithmetic.py" ]
[ "from __future__ import absolute_import, division, print_function\n\nimport os\n\nimport pytest\nimport numpy as np\nfrom mock import patch, MagicMock\nfrom matplotlib.colors import ColorConverter\n\nfrom glue import custom_viewer\nfrom glue.tests.helpers import PYSIDE2_INSTALLED # noqa\nfrom glue.core import HubL...
[ [ "numpy.random.random", "matplotlib.colors.ColorConverter" ], [ "numpy.isnan", "numpy.testing.assert_equal", "numpy.arange" ], [ "numpy.random.random" ] ]
Quandela/Perceval
[ "677f03808f9fbd3b4390aa4ef8cf6a5e4ec9f83a" ]
[ "perceval/backends/cliffords2017.py" ]
[ "# MIT License\n#\n# Copyright (c) 2022 Quandela\n#\n# Permission is hereby granted, free of charge, to any person obtaining a copy\n# of this software and associated documentation files (the \"Software\"), to deal\n# in the Software without restriction, including without limitation the rights\n# to use, copy, modi...
[ [ "numpy.reshape", "numpy.arange", "numpy.random.permutation", "numpy.zeros" ] ]
gorogoroumaru/optuna
[ "2d27f9086eae6b839fcddea061d848b12f5adf46" ]
[ "optuna/samplers/tpe/sampler.py" ]
[ "import math\n\nimport numpy as np\nimport scipy.special\n\nfrom optuna import distributions\nfrom optuna.pruners import HyperbandPruner\nfrom optuna.samplers import base\nfrom optuna.samplers import random\nfrom optuna.samplers.tpe.parzen_estimator import _ParzenEstimator\nfrom optuna.samplers.tpe.parzen_estimator...
[ [ "numpy.minimum", "numpy.sqrt", "numpy.linspace", "numpy.asarray", "numpy.concatenate", "numpy.round", "numpy.exp", "numpy.reshape", "numpy.arange", "numpy.ceil", "numpy.argmax", "numpy.zeros", "numpy.log", "numpy.append", "numpy.argsort", "numpy.rand...
warner-benjamin/fastai
[ "ceeba805f43e6258e7131d78706859f45c342575" ]
[ "fastai/layers.py" ]
[ "# AUTOGENERATED! DO NOT EDIT! File to edit: nbs/01_layers.ipynb (unless otherwise specified).\n\n\nfrom __future__ import annotations\n\n\n__all__ = ['module', 'Identity', 'Lambda', 'PartialLambda', 'Flatten', 'ToTensorBase', 'View', 'ResizeBatch',\n 'Debugger', 'sigmoid_range', 'SigmoidRange', 'Adaptive...
[ [ "torch.nn.utils.weight_norm", "torch.nn.utils.spectral_norm", "torch.nn.init.normal_" ] ]
Ian-Goodall-Halliwell/projected_gan
[ "cf7d61c44cc6a48de7c1ea1d90ba9fff4d55d8f2" ]
[ "training/training_loop.py" ]
[ "# Copyright (c) 2021, NVIDIA CORPORATION & AFFILIATES. All rights reserved.\n#\n# NVIDIA CORPORATION and its licensors retain all intellectual property\n# and proprietary rights in and to this software, related documentation\n# and any modifications thereto. Any use, reproduction, disclosure or\n# distribution o...
[ [ "torch.autograd.profiler.record_function", "torch.distributed.broadcast", "torch.zeros", "numpy.asarray", "torch.utils.data.DataLoader", "torch.utils.tensorboard.SummaryWriter", "torch.device", "torch.cuda.max_memory_reserved", "torch.cuda.memory_reserved", "numpy.clip", ...
QuatZo/HideNSeek-DeepReinforcementLearning-PyGame
[ "fa20ae1c518a3f72e9e37dafea33697ef82e2557" ]
[ "hidenseek/ext/engine.py" ]
[ "import pygame\nimport math\nimport copy\nfrom objects.controllable import Hiding, Seeker\nfrom objects.fixed import Wall\nfrom ext.supportive import Point, Collision, MapGenerator\nimport random\nfrom ext.loggers import LOGGING_DASHES, logger_engine, logger_hiding, logger_seeker\nimport numpy as np\nfrom ext.confi...
[ [ "numpy.sqrt" ] ]
PyTorchRL/pytorchrl
[ "055843ab58a06ba1f77da73082be6f23cf453ddd", "055843ab58a06ba1f77da73082be6f23cf453ddd" ]
[ "pytorchrl/agent/env/openai_baselines_dependencies/vec_env/dummy_vec_env.py", "pytorchrl/agent/env/openai_baselines_dependencies/Monitor.py" ]
[ "import numpy as np\nfrom pytorchrl.agent.env.openai_baselines_dependencies.vec_env.vec_env import VecEnv\nfrom pytorchrl.agent.env.openai_baselines_dependencies.vec_env.util import copy_obs_dict, dict_to_obs, obs_space_info\n\n\nclass DummyVecEnv(VecEnv):\n \"\"\"\n VecEnv that does runs multiple environment...
[ [ "numpy.copy", "numpy.zeros" ], [ "pandas.concat", "pandas.read_csv", "pandas.DataFrame" ] ]
sfwyly/NVAE
[ "e944d375945fa50fd71ef5ddfbc97b3159e68aec" ]
[ "encoder.py" ]
[ "\r\nimport tensorflow as tf\r\nimport tensorflow.keras.models as models\r\nimport tensorflow.keras.layers as layers\r\n\r\nfrom common import EncoderResidualBlock, Swish\r\n\r\n\r\nclass ConvBlock(layers.Layer):\r\n\r\n def __init__(self, in_channels, out_channels):\r\n\r\n super(ConvBlock, self).__init_...
[ [ "tensorflow.keras.layers.Conv2D", "tensorflow.keras.layers.BatchNormalization" ] ]