repo_name stringlengths 6 130 | hexsha list | file_path list | code list | apis list | possible_versions list |
|---|---|---|---|---|---|
zequeira/Turbofan-Engine-Lifetime-Prediction- | [
"a7f1b2df12a3f7dfca54d6ddf235fcd082d7f5ec"
] | [
"RUL_BiLSTM_CMAPSS_PL.py"
] | [
"import numpy as np\nimport pandas as pd\nfrom matplotlib import pyplot as plt\nfrom pickle import load\nfrom sklearn.metrics import mean_squared_error\n\nimport torch\nimport torch.nn as nn\nfrom torch.utils.data import Dataset, DataLoader\n\n\nimport pytorch_lightning as pl\nfrom pytorch_lightning import Trainer,... | [
[
"matplotlib.pyplot.legend",
"pandas.read_csv",
"matplotlib.pyplot.title",
"torch.nn.LSTM",
"matplotlib.pyplot.figure",
"torch.utils.data.DataLoader",
"matplotlib.pyplot.savefig",
"torch.tensor",
"numpy.concatenate",
"torch.nn.Linear",
"sklearn.metrics.mean_squared_error... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
capo-urjc/HILAND | [
"c53eeb9856324e6cb9ecf820ca35f56ee7a561a7"
] | [
"main.py"
] | [
"import gc\nimport json\nimport os\nimport random\nimport sys\nimport time\nimport uuid\nfrom pathlib import Path\nimport numpy as np\nimport torch\nfrom config.parser import Configuration\nfrom data.datasets import DatasetClass, DataSourceClass\nfrom log.logger import ConsoleLogger\nfrom model.transfer_learning im... | [
[
"torch.cuda.manual_seed",
"numpy.random.seed",
"torch.manual_seed",
"torch.set_num_threads",
"torch.set_deterministic",
"torch.cuda.is_available",
"torch.device"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
jon-chuang/robocup_rescue_hazardmap | [
"e533ca27bfd639a7231f567e60ccb68952cbc41a"
] | [
"yolo3/utils.py"
] | [
"\"\"\"Miscellaneous utility functions.\"\"\"\n\nfrom functools import reduce\n\nfrom PIL import Image\nimport numpy as np\nfrom matplotlib.colors import rgb_to_hsv, hsv_to_rgb\n\ndef compose(*funcs):\n \"\"\"Compose arbitrarily many functions, evaluated left to right.\n\n Reference: https://mathieularose.com... | [
[
"numpy.logical_and",
"matplotlib.colors.hsv_to_rgb",
"numpy.random.shuffle",
"numpy.random.rand",
"numpy.array",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
wizdom13/DenseNets-Pytorch | [
"071a448364a2c8165fcbeae5caa41dd69f22ad91"
] | [
"train.py"
] | [
"import argparse\nimport os\nimport shutil\nimport time\n\nimport torch\nimport torch.nn as nn\nimport torch.nn.parallel\nimport torch.backends.cudnn as cudnn\nimport torch.optim\nimport torch.utils.data\nimport torchvision.transforms as transforms\nimport torchvision.datasets as datasets\n\nfrom densenet import De... | [
[
"torch.optim.lr_scheduler.MultiStepLR",
"torch.nn.CrossEntropyLoss",
"torch.load",
"torch.device",
"torch.save"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
lukepolson/qmsolve | [
"373dbc6349509984139a59746acb140b48414fdf"
] | [
"examples/1D_harmonic_oscillator.py"
] | [
"import numpy as np\nfrom qmsolve import Hamiltonian, SingleParticle, init_visualization, Å\n\n\n#interaction potential\ndef harmonic_oscillator(particle):\n\n\tk = 1.029\n\treturn 0.5 * k * particle.x**2\n\n\nH = Hamiltonian(particles = SingleParticle(), \n\t\t\t\tpotential = harmonic_oscillator, \n\t\t\t\tspatia... | [
[
"numpy.dot",
"numpy.exp"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
CandyHuiZhang/Semantic-Segmentation-for-Aerial-Satellite-Images-with-Convolutional-Neural-Networks-including-an- | [
"fa8d21bc04e50c3cda8888916cc1c7a0e839f561"
] | [
"scripts/train.py"
] | [
"#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n\nimport argparse\nimport imp\nimport logging\nimport os\nimport re\nimport shutil\nimport time\nfrom multiprocessing import Process\nfrom multiprocessing import Queue\n\nimport chainer\nimport numpy as np\nimport six\nfrom chainer import Variable\nfrom chainer impor... | [
[
"numpy.asarray",
"numpy.fromstring",
"numpy.random.seed",
"numpy.random.randint"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
hal2001/pandas | [
"5771612634e23dbaf4aa4cb42d79d19c458851fa"
] | [
"pandas/tseries/tests/test_resample.py"
] | [
"# pylint: disable=E1101\n\nfrom datetime import datetime, timedelta\n\nimport numpy as np\n\nfrom pandas import Series, TimeSeries, DataFrame, Panel, isnull, notnull\n\nfrom pandas.tseries.index import date_range\nfrom pandas.tseries.offsets import Minute, BDay\nfrom pandas.tseries.period import period_range, Peri... | [
[
"pandas.tseries.offsets.Hour",
"pandas.Series",
"pandas.util.compat.product",
"pandas.DataFrame",
"pandas.util.testing.assert_frame_equal",
"numpy.random.randn",
"pandas.tseries.offsets.BDay",
"pandas.util.testing.makeTimeDataFrame",
"numpy.arange",
"pandas.Panel",
"pan... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"0.19"
],
"scipy": [],
"tensorflow": []
}
] |
Kaintels/pid-optimizer-tf | [
"f7f68dc806535f3e40f98dbf96d11856a04023bb"
] | [
"main.py"
] | [
"import tensorflow as tf\nfrom tensorflow import keras\nfrom PIDOptimizer.pidoptimizer import PIDOptimizer\nfrom tensorflow.keras.optimizers import Adam, SGD, RMSprop\nimport math\nimport numpy as np\nimport os\n\n\nx_train = np.array([1, 2, 3, 4])\nx_train = np.expand_dims(x_train, 1)\ny_train = np.array([60, 70, ... | [
[
"numpy.expand_dims",
"numpy.random.seed",
"tensorflow.keras.layers.Dense",
"tensorflow.data.Dataset.from_tensor_slices",
"tensorflow.keras.backend.clear_session",
"tensorflow.keras.losses.mean_squared_error",
"numpy.array",
"tensorflow.keras.metrics.Mean",
"tensorflow.random.se... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10",
"2.7",
"1.12",
"2.6",
"2.2",
"1.13",
"2.3",
"2.4",
"2.9",
"2.5",
"2.8",
"2.10"
]
}
] |
ryanrygg/oview | [
"35c10440cef8950ced28069d0a5059a2c8674ee7"
] | [
"oview/io/read_hdf.py"
] | [
"\"\"\"\nRead and parse hdf4 files produced at Omega-60 and Omega-EP.\n\nauthor: J. R. Rygg\nhistory:\n 2017-05-19 basic support for p510_data summary hdf\n 2017-04-13 created\n\"\"\"\n\nimport os.path as osp\nimport sys\n\nimport numpy as np\nimport pyhdf.SD as sd\n\n# lazy import: won't import until needed ... | [
[
"numpy.convolve",
"numpy.rot90",
"numpy.nanmax",
"numpy.isnan",
"numpy.nanmin",
"numpy.ones",
"numpy.std",
"numpy.nansum",
"numpy.argmin",
"numpy.shape",
"numpy.mean",
"numpy.size",
"numpy.argmax",
"numpy.array",
"numpy.zeros",
"numpy.where",
"ma... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ZPLai/pysindy | [
"d5acecbd252cdcfaf4e3a15306f47730b35aa8eb"
] | [
"pysindy/optimizers/stlsq.py"
] | [
"import warnings\n\nimport numpy as np\nfrom sklearn.exceptions import ConvergenceWarning\nfrom sklearn.linear_model import ridge_regression\nfrom sklearn.utils.validation import check_is_fitted\n\nfrom pysindy.optimizers import BaseOptimizer\n\n\nclass STLSQ(BaseOptimizer):\n \"\"\"\n Sequentially thresholde... | [
[
"sklearn.utils.validation.check_is_fitted",
"numpy.abs",
"numpy.zeros_like",
"numpy.count_nonzero",
"numpy.zeros",
"numpy.sum",
"sklearn.linear_model.ridge_regression"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
wcgcyx/nebula-crawler | [
"b71d52512d5aa8d9b050594e126a60c2aae0f7c9"
] | [
"analysis/mixed/plot_map.py"
] | [
"import matplotlib.pyplot as plt\n\nloc_map = {\"DE\": [737,407],\"CZ\": [734,433],\"NL\": [721,402],\"GB\": [693,398],\"BE\": [720,412],\"CN\": [1183,487],\"FR\": [709,431],\"US\": [281,468],\"PL\": [779,401],\n \"TR\": [847,469],\"IE\": [666,399],\"CH\": [733,432],\"MY\": [1120,623],\"SE\": [764,338],\"AT\": [... | [
[
"matplotlib.pyplot.imshow",
"matplotlib.pyplot.title",
"matplotlib.pyplot.imread",
"matplotlib.pyplot.savefig",
"matplotlib.pyplot.plot"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
dheera/rosstorm | [
"463f6065c481ed1dfae2dc5c9b66a00356eb6fe9"
] | [
"rosshow/viewers/nav_msgs/PathViewer.py"
] | [
"import numpy as np\nimport time\n\nimport rosshow.termgraphics as termgraphics\nfrom rosshow.viewers.generic.Space2DViewer import Space2DViewer\n\nclass PathViewer(Space2DViewer):\n def __init__(self, canvas, title = \"\"):\n def msg_decoder(msg):\n \"\"\"\n Calculates (x,y) coordin... | [
[
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
atbenmurray/NiftyNet | [
"3a4d54544c0886751bacfdbddb42eb90fe0d5b54"
] | [
"tests/rgb_histogram_equilisation_test.py"
] | [
"import numpy as np\nimport tensorflow as tf\n\nfrom niftynet.layer.rgb_histogram_equilisation import \\\n RGBHistogramEquilisationLayer\nfrom niftynet.utilities.util_import import require_module\n\nIMAGE_DATA = \\\n np.array([[[0.49803922, 0.19215687, 0.3529412 ],\n [0.49411765, 0.16862746, 0.3... | [
[
"numpy.array",
"numpy.histogram",
"tensorflow.test.main"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ufal/neuralmonkey | [
"8b1465270f6bb28d5417a85cec492f7179036ede",
"8b1465270f6bb28d5417a85cec492f7179036ede",
"8b1465270f6bb28d5417a85cec492f7179036ede"
] | [
"neuralmonkey/model/gradient_reversal.py",
"neuralmonkey/decoders/output_projection.py",
"neuralmonkey/runners/regression_runner.py"
] | [
"\"\"\"Module for reverting grandients when passing a model part.\"\"\"\n\nfrom typing import List\nimport tensorflow as tf\n# pylint: disable=no-name-in-module\nfrom tensorflow.python.framework import ops\n# pylint: disable=no-name-in-module\nfrom typeguard import check_argument_types\n\nfrom neuralmonkey.decorato... | [
[
"tensorflow.negative",
"tensorflow.identity",
"tensorflow.python.framework.ops.RegisterGradient"
],
[
"tensorflow.concat",
"tensorflow.layers.dense"
],
[
"numpy.zeros_like"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10",
"1.12",
"1.4",
"1.5",
"1.7",
"1.0",
"1.2"
]
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
... |
GCY190811/gluon-cv | [
"dffcf4d5ded123a347f5ff77d4ad8e5d6eb2d7d6"
] | [
"gluoncv/data/pascal_voc/detection.py"
] | [
"\"\"\"Pascal VOC object detection dataset.\"\"\"\nfrom __future__ import absolute_import\nfrom __future__ import division\nimport os\nimport logging\nimport warnings\nimport numpy as np\ntry:\n import xml.etree.cElementTree as ET\nexcept ImportError:\n import xml.etree.ElementTree as ET\nimport mxnet as mx\n... | [
[
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ctorney/uavTracker | [
"79271b89a881f538e301faa7bbabf41daedd1be8"
] | [
"utils/utils.py"
] | [
"import cv2\nimport numpy as np\nimport sys\nimport os\nfrom .bbox import BoundBox, bbox_iou\nfrom scipy.special import expit\nimport hashlib, math\n\ndef md5check(md5sum,weights_file):\n if md5sum != \"\":\n read_file_hex = hashlib.md5(open(weights_file,'rb').read()).hexdigest()\n if read_file_hex... | [
[
"numpy.expand_dims",
"numpy.maximum",
"scipy.special.expit",
"numpy.cumsum",
"numpy.ones",
"numpy.concatenate",
"numpy.finfo",
"numpy.append",
"numpy.argmax",
"numpy.where",
"numpy.exp",
"numpy.argsort",
"numpy.array",
"numpy.zeros",
"numpy.sum"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
qqaatw/TensorQQ | [
"64924f955e82362da173c2bbb4a18db8a24a60d5"
] | [
"src/tests/QQTest.py"
] | [
"# TODO: Check RMSProp optimizer\n#\n\nimport numpy as np\n\nimport TensorQQ\n\nw_1 = TensorQQ.QQTensor.QQParameter([[0.2358, 0.2746], \n [0.2789, 0.3586],\n [0.1357, 0.0458]], name='w_1')\nb_1 = TensorQQ.QQTensor.QQParameter([[0.1],\n ... | [
[
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
casassg/tfx-addons | [
"845047274ea0d900cdc3604644453e5d345f301a"
] | [
"examples/sklearn_penguins/sklearn_predict_extractor_test.py"
] | [
"# Copyright 2021 Google LLC. 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\n#\n# Unless required by appl... | [
[
"sklearn.neural_network.MLPClassifier"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Slienteagle-wyb/rlpyt | [
"fee14b1c28481f6751a7a1a6ce9b8cbac1e001f0"
] | [
"rlpyt/ul/algos/ul_for_rl/mstc.py"
] | [
"import torch\nfrom collections import namedtuple\nimport copy\nimport wandb\nfrom rlpyt.utils.tensor import valid_mean\nfrom rlpyt.ul.algos.ul_for_rl.base import BaseUlAlgorithm\nfrom rlpyt.utils.quick_args import save__init__args\nfrom rlpyt.utils.logging import logger\nfrom rlpyt.ul.replays.offline_ul_replay imp... | [
[
"torch.nn.functional.normalize",
"torch.nn.CrossEntropyLoss",
"torch.max",
"torch.cat",
"torch.nn.ModuleList",
"torch.eye",
"torch.tensor",
"torch.matmul",
"torch.nn.Linear",
"torch.no_grad",
"torch.arange",
"torch.device",
"torch.get_default_dtype",
"torch.... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
AndresOtero/TensorDecompositionMachineLearning | [
"455f16b405ec9d031999b0ebf9c5a68d3c20b233"
] | [
"Utils/PreProcessText.py"
] | [
"import torch\nfrom torchtext import data\nimport Utils.Constant as C\nfrom Utils.DataLoaderUtil import DataLoaderUtil\n\n\nclass PreProcessText:\n _instance = None\n\n def __init__(self):\n if not self._instance:\n self.text = None\n self.label = None\n self.train_data... | [
[
"torch.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
mjirik/bodynavigation | [
"99db34cd4b8d9508784746df27356dda31468fe4"
] | [
"bodynavigation/tools.py"
] | [
"#! /usr/bin/env python\n# -*- coding: utf-8 -*-\n\n# Enable Python3 code in Python2 - Must be first in file!\nfrom __future__ import print_function # print(\"text\")\nfrom __future__ import division # 2/3 == 0.666; 2//3 == 0\nfrom __future__ import (\n absolute_import,\n) # 'import submodule2' turns into 'fr... | [
[
"numpy.polyfit",
"numpy.poly1d",
"numpy.asarray",
"numpy.all",
"numpy.max",
"numpy.round",
"numpy.any",
"scipy.ndimage.morphology.binary_fill_holes",
"numpy.unique",
"scipy.ndimage.zoom",
"numpy.argmax",
"numpy.load",
"numpy.zeros",
"numpy.min",
"numpy.m... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [
"0.13",
"1.6",
"0.14",
"0.15",
"1.4",
"0.10",
"1.3",
"0.19",
"1.5",
"0.18",
"1.2",
"1.7",
"0.12",
"1.0",
"0.17",
"0.16"
],
"tensorflow": [... |
zbzhu99/malib | [
"5be07ac00761a34fb095adb2b3018a798ceea256",
"5be07ac00761a34fb095adb2b3018a798ceea256",
"5be07ac00761a34fb095adb2b3018a798ceea256"
] | [
"malib/envs/gr_football/wrappers.py",
"malib/envs/smarts/metrics/basic_handler.py",
"malib/backend/datapool/offline_dataset_server.py"
] | [
"import gym\nimport numpy as np\n\nfrom malib.utils.typing import Callable, AgentID, Any, Dict\n\nfrom malib.envs.env import GroupWrapper\n\n\ndef GroupedGFBall(base_env, parameter_sharing_func: Callable):\n class PSGFootBall(GroupWrapper):\n def __init__(self, env):\n super().__init__(env)\n ... | [
[
"numpy.vstack"
],
[
"numpy.asarray",
"scipy.spatial.distance.euclidean"
],
[
"numpy.arange",
"numpy.zeros",
"numpy.random.shuffle",
"numpy.random.choice"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [
"0.13",
"1.6",
"0.14",
"1.10",
"0.15",
"1.4",
"0.16",
"1.9",
"0.19",
"1.5",
... |
Windaway/tensorlayer | [
"c5def14c4d66d150863f975d9001a5e1891d003f",
"c5def14c4d66d150863f975d9001a5e1891d003f"
] | [
"tests/pending/test_logging.py",
"tests/pending/test_layers_importer.py"
] | [
"#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n\nimport os\nimport unittest\n\nos.environ['TF_CPP_MIN_LOG_LEVEL'] = '3'\n\nimport tensorflow as tf\nimport tensorlayer as tl\n\nfrom tests.utils import CustomTestCase\n\n\nclass TL_Logger_Test(CustomTestCase):\n\n def test_debug(self):\n with self.assertNo... | [
[
"tensorflow.logging.set_verbosity"
],
[
"tensorflow.reset_default_graph",
"tensorflow.placeholder",
"tensorflow.logging.set_verbosity",
"tensorflow.contrib.slim.python.slim.nets.inception_v3.inception_v3_arg_scope"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
adam-dziedzic/ASL | [
"cc063f5e7eda1498544ad2c3b224985203b0774a"
] | [
"validate.py"
] | [
"# Adopted from: https://github.com/allenai/elastic/blob/master/multilabel_classify.py\r\n# special thanks to @hellbell\r\n\r\nimport argparse\r\nimport time\r\nimport torch\r\nimport torch.nn.parallel\r\nimport torch.optim\r\nimport torch.utils.data.distributed\r\nimport torchvision.transforms as transforms\r\nimp... | [
[
"torch.cat",
"torch.load",
"torch.utils.data.DataLoader",
"torch.nn.Sigmoid",
"torch.no_grad"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ParthibHW19/Deep-Learning-with-Tensorflow | [
"fe2a4b9a925ec349a2ba7ddf0ba0953b5d2658f0"
] | [
"govtech_data_helper.py"
] | [
"import os\nimport re\nimport sys\nimport json\nimport pickle\nimport logging\nimport itertools\nimport numpy as np\nimport pandas as pd\nimport gensim as gs\nfrom pprint import pprint\nfrom collections import Counter\nfrom tensorflow.contrib import learn\n\nlogging.getLogger().setLevel(logging.INFO)\n\ndef clean_s... | [
[
"pandas.read_csv",
"numpy.arange",
"numpy.random.permutation",
"numpy.fill_diagonal",
"numpy.random.uniform",
"numpy.array",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
icobro/PyHMA | [
"49a2d8fc4aeee2a3e2a9fb7c08e5d969d57dcdf4"
] | [
"PyHMA/__init__.py"
] | [
"import copy\nimport warnings\nimport bottleneck as bn\nimport numpy as np\nimport pandas as pd\nimport matplotlib.pyplot as plt\nfrom scipy.sparse import dia_matrix\n\n\nclass HMA:\n\n def __init__(self, q_obs, q_sim, b=4, max_lag=3, max_lead=3, measure='nse',\n keep_internals=False, calc_rays=F... | [
[
"numpy.hstack",
"numpy.abs",
"numpy.min",
"numpy.arange",
"numpy.nanmin",
"matplotlib.pyplot.subplots",
"pandas.Timedelta",
"numpy.ones",
"numpy.full",
"numpy.nanargmin",
"pandas.Timestamp.now",
"scipy.sparse.dia_matrix"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [
"1.7",
"1.0",
"0.10",
"1.2",
"0.14",
"0.19",
"1.5",
"0.12",
"0.17",
"0.13",
"1.6",
"1.4",
"1.9",
"1.3",
"1.10",
"0.15",
"0.18",
"0.16"... |
jleni/EPG | [
"bb73d774d1afbd12613b07db418b14ea5e057df4"
] | [
"epg/utils.py"
] | [
"import random\nimport time\n\nimport chainer.functions as F\nimport gym\nimport numpy as np\n\n\ndef reseed(env, pool_rank):\n np.random.seed(pool_rank + get_time_seed())\n random.seed(pool_rank + get_time_seed())\n env.seed(pool_rank + get_time_seed())\n\n\ndef sym_mean(x):\n return F.sum(x) / x.size\... | [
[
"numpy.square",
"numpy.sqrt",
"numpy.min",
"numpy.asarray",
"numpy.median",
"numpy.full",
"numpy.max",
"numpy.std",
"numpy.zeros_like",
"numpy.mean",
"numpy.where",
"numpy.zeros",
"numpy.sum"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
davidjamesknight/NimData | [
"74bdd397a55b04d99d5ac3a17c5ab9e7f7410ec5"
] | [
"benchmarks/Pandas/run.py"
] | [
"#!/usr/bin/env python\n\nfrom __future__ import division, print_function\n\nimport pandas as pd\nimport time\n\n\ntest_file = \"test_01.csv\"\n\n\ndef run_timed(name, func, numRepeats=3):\n runtimes = []\n for i in xrange(numRepeats):\n print(\"\\n *** Running {} [Iteration: {}]\".format(name, i+1))\n... | [
[
"pandas.read_csv",
"pandas.Series"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.3",
"1.1",
"1.5",
"1.2"
],
"scipy": [],
"tensorflow": []
}
] |
fredfung007/snlt | [
"5ce66f9f79808d39341dd3dfbab6a2c78e1c0425"
] | [
"utils/bbox.py"
] | [
"# COPYRIGHT 2021. Fred Fung. Boston University.\n# ADAPTED FROM Copyright (c) SenseTime. All Rights Reserved.\n\nfrom collections import namedtuple\n\nimport numpy as np\n\nCorner = namedtuple('Corner', 'x1 y1 x2 y2')\n# alias\nBBox = Corner\nCenter = namedtuple('Center', 'x y w h')\n\n\ndef corner2center(corner):... | [
[
"numpy.maximum",
"numpy.sqrt",
"numpy.minimum",
"numpy.linalg.norm",
"numpy.mean",
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ccphillippi/Horizon | [
"a18d8941f663eea55488781c804e6305a36f1b58"
] | [
"ml/rl/workflow/transitional.py"
] | [
"#!/usr/bin/env python3\n# Copyright (c) Facebook, Inc. and its affiliates. All rights reserved.\n\nfrom typing import Dict\n\nimport torch\nfrom ml.rl.models.dqn import FullyConnectedDQN\nfrom ml.rl.models.dueling_q_network import DuelingQNetwork\nfrom ml.rl.models.parametric_dqn import FullyConnectedParametricDQN... | [
[
"torch.cuda.is_available"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
welkinwalker/DeepCTR | [
"753c689cb4834b56685c5e3d4ce48da3c28ddfc6"
] | [
"examples/serving_pred.py"
] | [
"\"\"\"\n本文件主要用于向deepFM模型发起restful api请求, 获取ctr预估值\n请求数据源来自于train_sample.txt,需要保证以下几点:\n1. 逐条预测得到的ctr值与模型直接预测的值一模一样。\n2. 一次预测的值与模型预测的一模一样。\n3. 所有的请求预测得到的AUC与模型直接预测得到的一模一样。\n\npandas int64的type是无法被序列化的\n\"\"\"\n\nimport os\nimport pandas as pd\nimport requests\nimport pickle\nimport json\nimport numpy as np\nfrom sk... | [
[
"sklearn.metrics.roc_auc_score",
"pandas.read_csv",
"numpy.array",
"sklearn.preprocessing.LabelEncoder",
"sklearn.preprocessing.MinMaxScaler"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
imerad/linlearn | [
"b63385ea4d754db2ec08f6479a555963c8d42576"
] | [
"example_least_squares_solvers.py"
] | [
"import numpy as np\n\nfrom numpy.random.mtrand import multivariate_normal\nfrom scipy.linalg import toeplitz\n\nfrom linlearn.model import LeastSquares\nfrom linlearn.model.utils import inner_prods\nfrom linlearn.prox_old import ProxL2Sq, ProxL1\nfrom linlearn.solver_old import SVRG, CGD, History\n\nfrom linlearn.... | [
[
"numpy.arange",
"numpy.set_printoptions",
"numpy.random.randn",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ylzhang29/UpstateSU-GRU-Covid | [
"c805c67ffe0f651b98050d4554cfa663145a72bd"
] | [
"Model/GRU_Daily_MA7_NewCases.py"
] | [
"import os\n\nos.environ[\"KERAS_BACKEND\"] = \"tensorflow\"\nfrom sklearn.preprocessing import MinMaxScaler\nimport pickle\n\nimport csv\nfrom math import sqrt\n\nfrom tensorflow import keras\nimport keras\nimport tensorflow as tf\n\n\nfrom keras.layers import Input, Dense, Dropout\nfrom keras.models import Model\... | [
[
"matplotlib.pyplot.legend",
"pandas.to_datetime",
"pandas.DataFrame",
"matplotlib.pyplot.plot",
"numpy.concatenate",
"numpy.mean",
"sklearn.preprocessing.MinMaxScaler",
"numpy.hstack",
"pandas.read_csv",
"numpy.unique",
"numpy.arange",
"numpy.save",
"matplotlib.... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.3",
"1.1",
"1.5",
"1.2"
],
"scipy": [
"0.13",
"1.6",
"0.14",
"1.10",
"0.15",
"1.4",
"0.16",
"1.9",
"0.19",
"1.5",
"0.18",
"1.2... |
deapplegate/wtgpipeline | [
"9693e8562022cc97bf5a96427e22965e1a5e8497"
] | [
"calc_area.py"
] | [
"#!/usr/bin/env python\n\nimport astropy, astropy.io.fits as pyfits, numpy, os, sys\nsubarudir = '/nfs/slac/g/ki/ki05/anja/SUBARU'\n\ncluster = sys.argv[1]\nfilter = sys.argv[2]\n\nmin = 0\nmax = 5000\nbins = 20\ndr = float(max-min)/bins\n\n\nflags = pyfits.open('%(subaru)s/%(cluster)s/%(filter)s/SCIENCE/coadd_%(cl... | [
[
"numpy.arange",
"numpy.array",
"numpy.sqrt",
"numpy.logical_and"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
rish283/DL_Uncertainty_Quantification | [
"60702eda0130da5a2c579c6ec8b0d58dc6d3df57"
] | [
"UQ_methods.py"
] | [
"# IMPORT NECESSARY PYTHON LIBRARIES\nimport tensorflow as tf\nfrom keras import backend as K\nimport keras.layers\nfrom tensorflow.keras.layers import Flatten\nfrom tensorflow.keras import layers\nfrom tensorflow.keras.models import Model\nfrom tensorflow.keras.layers import Lambda, Dense, Dropout, AveragePooling2... | [
[
"tensorflow.keras.layers.AveragePooling2D",
"tensorflow.keras.models.Model",
"numpy.asarray",
"tensorflow.keras.layers.Dense",
"tensorflow.reduce_mean",
"tensorflow.keras.layers.Conv2D",
"tensorflow.keras.Sequential",
"numpy.max",
"numpy.std",
"numpy.mean",
"numpy.shape... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
jpaduart/entsoe-py | [
"48ec8c5725a91eda37f5fa167a1b9672a4221eb8"
] | [
"entsoe/entsoe.py"
] | [
"import logging\nfrom functools import wraps\nfrom socket import gaierror\nfrom time import sleep\nfrom typing import Union, Optional, Dict\n\nimport pandas as pd\nfrom pandas.tseries.offsets import YearBegin, YearEnd\nimport pytz\nimport requests\nfrom bs4 import BeautifulSoup\n\nfrom entsoe.exceptions import Inva... | [
[
"pandas.tseries.offsets.YearBegin",
"pandas.concat",
"pandas.tseries.offsets.YearEnd"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"0.23",
"0.21",
"0.19",
"0.24",
"0.20",
"1.0",
"0.25"
],
"scipy": [],
"tensorflow": []
}
] |
CIS-group/3DGCN_poolings | [
"2e91d2f2c75a848f732491274fc934d1c192b094"
] | [
"models/bace_train.py"
] | [
"from trainer import Trainer\nimport os\nimport argparse\n\nimport tensorflow as tf\n\nparser = argparse.ArgumentParser()\nparser.add_argument('--pooling', default='avg', help=\"Pooling type\")\nparser.add_argument('--gpu', default=0, help=\"GPU number you want to use\")\n\nparser.add_argument('--fold', default=10,... | [
[
"tensorflow.config.experimental.list_physical_devices"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
kevogil/python_challenge | [
"a83dc2fb57d3cd692d686234fa8076ac8f473b36"
] | [
"PyBank/main.py"
] | [
"import pandas as pd\nimport pathlib\n\ncsv_path = pathlib.Path(\"Resources/budget_data.csv\")\ndata_df = pd.read_csv(csv_path)\n\ndates = data_df[\"Date\"]\nprofits_losses = data_df[\"Profit/Losses\"].astype('float32')\n\nnum_of_months = int(len(dates))\ntotal = profits_losses.sum()\n\n# Add list of all variances ... | [
[
"pandas.read_csv"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
bhfs9999/maskrcnn_isic | [
"c3107f351cdcbee5c1c404457a4f35e76618537c"
] | [
"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.nonzero",
"torch.tensor"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
arupmondal835/molecool | [
"c69afdfb24045c95842257224ecfc83fd807763b"
] | [
"molecool/io/pdb.py"
] | [
"import numpy as np\nimport os\n\ndef open_pdb(f_loc):\n # This function reads in a pdb file and returns the atom names and coordinates.\n with open(f_loc) as f:\n data = f.readlines()\n c = []\n sym = []\n for l in data:\n if 'ATOM' in l[0:6] or 'HETATM' in l[0:6]:\n sym.app... | [
[
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
HimashiRathnayake/emea | [
"5e3ddd8393082b7bc7551f6ad7b136ab08ec08f9"
] | [
"examples/seq2seq/test_bash_script.py"
] | [
"#!/usr/bin/env python\n\nimport argparse\nimport os\nimport sys\nfrom unittest.mock import patch\n\nimport pytorch_lightning as pl\nimport timeout_decorator\nimport torch\n\nfrom distillation import BartSummarizationDistiller, distill_main\nfrom finetune import SummarizationModule, main\nfrom transformers import M... | [
[
"torch.load"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
mdemoret-nv/clx | [
"3737706187d8f5720561e10b85cbd638c77b9267"
] | [
"python/clx/tests/test_phish_detector.py"
] | [
"# Copyright (c) 2020, NVIDIA CORPORATION.\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 l... | [
[
"torch.cuda.is_available"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
mindw/mahotas | [
"070332dacd4108df12b999d3d720596de8b59ac9"
] | [
"mahotas/tests/test_zernike.py"
] | [
"import numpy as np\nfrom mahotas.features import zernike_moments\nfrom mahotas.center_of_mass import center_of_mass\nfrom math import atan2\nfrom numpy import cos, sin, conjugate, pi, sqrt\n\ndef _slow_znl(Y,X,P,n,l):\n def _polar(r,theta):\n x = r * cos(theta)\n y = r * sin(theta)\n return... | [
[
"numpy.sqrt",
"numpy.abs",
"numpy.arange",
"numpy.cos",
"numpy.sin",
"numpy.array",
"numpy.where",
"numpy.conjugate"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
nobodyczcz/flatland2020 | [
"0eebf66098f339d22ef2215570ab7475c438c721",
"0eebf66098f339d22ef2215570ab7475c438c721"
] | [
"flatland/envs/agent_utils.py",
"flatland/envs/rail_generators.py"
] | [
"from flatland.envs.rail_trainrun_data_structures import Waypoint\nimport numpy as np\n\nfrom enum import IntEnum\nfrom itertools import starmap\nfrom typing import Tuple, Optional, NamedTuple, List\n\nfrom attr import attr, attrs, attrib, Factory\n\nfrom flatland.core.grid.grid4 import Grid4TransitionsEnum\nfrom f... | [
[
"numpy.ceil"
],
[
"numpy.abs",
"numpy.linspace",
"numpy.sqrt",
"numpy.clip",
"numpy.arange",
"numpy.ceil",
"numpy.shape",
"numpy.argsort",
"numpy.array",
"numpy.zeros",
"numpy.random.mtrand.RandomState"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ManuelEberhardinger/demo2program | [
"97198968b5178ce9d5584a42b0baa2a1ef171377"
] | [
"vizdoom_env/dataset_vizdoom.py"
] | [
"from __future__ import absolute_import\nfrom __future__ import division\nfrom __future__ import print_function\n\nimport os.path as osp\nimport numpy as np\nimport h5py\nfrom vizdoom_env.util import log\n\n\nrs = np.random.RandomState(123)\n\n\nclass Dataset(object):\n\n def __init__(self, ids, dataset_path, na... | [
[
"numpy.random.RandomState",
"numpy.zeros",
"numpy.argmax",
"numpy.stack"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
WorqHat/Music-Recommender | [
"0df57d7b8b75d0cb7cc1234965f7e796789173e1"
] | [
"Recommenders.py"
] | [
"import numpy as np\nimport pandas\n\n#Class for Popularity based Recommender System model\nclass popularity_recommender_py():\n def __init__(self):\n self.train_data = None\n self.user_id = None\n self.item_id = None\n self.popularity_recommendations = None\n \n #Create the... | [
[
"numpy.count_nonzero",
"numpy.isnan",
"numpy.array",
"pandas.DataFrame"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"0.23",
"0.21",
"2.0",
"1.4",
"0.19",
"1.1",
"1.5",
"1.2",
"0.24",
"0.20",
"1.0",
"0.25",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
shiwei23/STORM6 | [
"669067503ebd164b575ce529fcc4a9a3f576b3d7"
] | [
"storm_control/sc_hardware/baseClasses/daqModule.py"
] | [
"#!/usr/bin/env python\n\"\"\"\nBasic DAQ module functionality.\n\nHazen 04/17\n\"\"\"\n\nimport numpy\nfrom PyQt5 import QtCore\n\nimport storm_control.hal4000.halLib.halMessage as halMessage\n\nimport storm_control.sc_hardware.baseClasses.hardwareModule as hardwareModule\nimport storm_control.sc_library.halExcept... | [
[
"numpy.max",
"numpy.tile"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Joseph-A-Mason/landlab | [
"a5dd80b8ebfd03d1ba87ef6c4368c409485f222c"
] | [
"landlab/components/bedrock_landslider/bedrock_landslider.py"
] | [
"# -*- coding: utf-8 -*-\n\"\"\"Grid-based simulation of bedrock landslides.\n\nBenjamin Campforts\n\"\"\"\n\nimport numpy as np\n\nfrom landlab import Component\nfrom landlab.grid.nodestatus import NodeStatus\n\nfrom ..depression_finder.lake_mapper import _FLOODED\nfrom .cfuncs import _landslide_runout\n\nMAX_HEIG... | [
[
"numpy.arctan",
"numpy.concatenate",
"numpy.max",
"numpy.zeros_like",
"numpy.exp",
"numpy.where",
"numpy.square",
"numpy.allclose",
"numpy.clip",
"numpy.unique",
"numpy.matlib.divide",
"numpy.zeros",
"numpy.nonzero",
"numpy.delete",
"numpy.random.rand",
... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
BigBen0519/mmtracking | [
"61509b301ccbc2ab14f82a682b94c56f82ce09de",
"61509b301ccbc2ab14f82a682b94c56f82ce09de"
] | [
"tests/test_models/test_reid/test_base_reid.py",
"mmtrack/datasets/pipelines/transforms.py"
] | [
"# Copyright (c) OpenMMLab. All rights reserved.\nimport pytest\nimport torch\n\nfrom mmtrack.models import REID\n\n\n@pytest.mark.parametrize('model_type', ['BaseReID'])\ndef test_base_reid(model_type):\n model_class = REID.get(model_type)\n backbone = dict(\n type='ResNet',\n depth=50,\n ... | [
[
"torch.randperm",
"torch.randn"
],
[
"numpy.dot",
"numpy.split",
"numpy.sqrt",
"numpy.asarray",
"numpy.concatenate",
"numpy.round",
"numpy.mean",
"numpy.random.randn",
"numpy.random.randint",
"numpy.clip",
"numpy.arange",
"numpy.zeros",
"numpy.random... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Francis777/CME241-Assignment | [
"e8f809ab864b5d360152f2284b01d730aede0f7a"
] | [
"assignment/src/process/mp.py"
] | [
"# TODO: Check correctness of stationary distribution\n\nfrom typing import Generic, Mapping, Sequence\nimport numpy as np\nfrom scipy import linalg\n# use math.fsum() instead of sum to get rid of rounding error\nimport math\n\nfrom src.type_vars import S, SSf\nfrom src.utils import get_all_states\n\n# Note: if usi... | [
[
"scipy.linalg.lstsq",
"numpy.ones",
"numpy.identity",
"numpy.transpose",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [
"0.13",
"0.12",
"0.14",
"0.15"
],
"tensorflow": []
}
] |
arthurdjn/colorply | [
"1a4ef819ddee068565664bb08953b474e54e2b0b"
] | [
"colorply/process/image.py"
] | [
"\"\"\"\nDefines an Image, with its orientation, focal, symmetry.\n\"\"\"\n\nimport numpy as np\n\n\nclass Image:\n \"\"\"\n Define an image, with its name, channels, data, rotation and autocollimation.\n \"\"\"\n\n def __init__(self, name=\"None\", channel=\"None\", data=np.array([[]]), R=np.eye(3),\n ... | [
[
"numpy.eye",
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
dongrami0425/Python_OpenCV-Study | [
"c7faee4f63720659280c3222ba5abfe27740d1f4",
"c7faee4f63720659280c3222ba5abfe27740d1f4",
"c7faee4f63720659280c3222ba5abfe27740d1f4",
"c7faee4f63720659280c3222ba5abfe27740d1f4"
] | [
"opencv_project_python-master/opencv_project_python-master/07.segmentation/cntr_hierarchy.py",
"capstoneproject/firstnw/inception v3 test code.py",
"opencv_project_python-master/opencv_project_python-master/04.img_processing/bgr2hsv.py",
"opencv_project_python-master/opencv_project_python-master/06.filter/mor... | [
"import cv2\nimport numpy as np\n\n# 영상 읽기\nimg = cv2.imread('../img/shapes_donut.png')\nimg2 = img.copy()\n# 바이너리 이미지로 변환\nimgray = cv2.cvtColor(img, cv2.COLOR_BGR2GRAY)\nret, imthres = cv2.threshold(imgray, 127, 255, cv2.THRESH_BINARY_INV)\n\n# 가장 바깥 컨투어만 수집 --- ①\nim2, contour, hierarchy = cv2.findContours(imt... | [
[
"numpy.random.randint"
],
[
"tensorflow.python.framework.tensor_shape.scalar",
"tensorflow.nn.softmax_cross_entropy_with_logits",
"tensorflow.python.platform.gfile.Walk",
"tensorflow.zeros",
"tensorflow.stack",
"numpy.squeeze",
"tensorflow.cast",
"tensorflow.python.platform... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
... |
cogtoolslab/projection_block_construction | [
"faae126fbb7da45f2c5f4df05a2ff606a2b86d59"
] | [
"stimuli/subgoal_tree.py"
] | [
"\"\"\"This class contains a class for a tree of subgoals that culminates in a full decomposition. This is for the human experiments involving A/B choice between subgoals\"\"\"\n\nfrom nis import match\nfrom typing import Dict\nimport model.utils.decomposition_functions as dcf\nimport random\nimport matplotlib.pypl... | [
[
"matplotlib.pyplot.show",
"numpy.equal",
"matplotlib.pyplot.figure"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
qiaone/Peppa_Pig_Face_Engine | [
"d294aabb102c61352f2a97a0c3e5b4aeac25037d"
] | [
"lib/core/api/face_detector.py"
] | [
"import numpy as np\nimport cv2\nimport tensorflow as tf\nimport math\nimport time\n\nfrom config import config as cfg\n\nclass FaceDetector:\n def __init__(self):\n \"\"\"\n the model was constructed by the params in config.py\n \"\"\"\n\n self.model_path=cfg.DETECT.model_path\n ... | [
[
"numpy.expand_dims",
"numpy.maximum",
"tensorflow.saved_model.load",
"numpy.minimum",
"tensorflow.lite.Interpreter",
"numpy.argsort",
"numpy.array",
"numpy.zeros",
"numpy.where"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
amangoel185/boost-histogram | [
"4de56da56a776f429c4685c0b5c64149d63c2768"
] | [
"tests/test_histogram.py"
] | [
"import functools\nimport operator\nimport sys\nfrom io import BytesIO\n\nimport numpy as np\nimport pytest\nfrom numpy.testing import assert_array_equal\nfrom pytest import approx\n\nimport boost_histogram as bh\n\ntry:\n import cPickle as pickle\nexcept ImportError:\n import pickle\n\nfrom collections impor... | [
[
"numpy.asarray",
"numpy.arange",
"numpy.ones",
"numpy.testing.assert_array_equal",
"numpy.float64",
"numpy.prod",
"numpy.array",
"numpy.zeros",
"numpy.sum",
"numpy.empty"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
linuful/tensorflow | [
"37659f525f0c69b27830b8ad58b14dad5f55fd28"
] | [
"mnist_with_summaries.py"
] | [
"# Copyright 2015 The TensorFlow Authors. 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\n#\n# Unless requir... | [
[
"tensorflow.nn.softmax_cross_entropy_with_logits",
"tensorflow.RunMetadata",
"tensorflow.cast",
"tensorflow.train.AdamOptimizer",
"tensorflow.summary.scalar",
"tensorflow.Variable",
"tensorflow.summary.image",
"tensorflow.name_scope",
"tensorflow.square",
"tensorflow.argmax... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
pankaj90382/TSAI-2 | [
"af4b3543dfb206fb1cc2bd166ed31e9ea7bd3778"
] | [
"S3/S3_Modular_Code/face_blend_common.py"
] | [
"#!/usr/bin/python\r\n# Copyright 2017 BIG VISION LLC ALL RIGHTS RESERVED\r\n#\r\n# This code is made available to the students of\r\n# the online course titled \"Computer Vision for Faces\"\r\n# by Satya Mallick for personal non-commercial use.\r\n#\r\n# Sharing this code is strictly prohibited without written\r\n... | [
[
"numpy.reshape",
"numpy.int32",
"numpy.linalg.norm",
"numpy.int",
"numpy.copy",
"numpy.argmin",
"numpy.float32",
"numpy.array",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
simonmeister/pytorch-mono-depth | [
"713c70e2fdae6d9d6e0322febadfedcaee9470d3",
"713c70e2fdae6d9d6e0322febadfedcaee9470d3"
] | [
"dense_estimation/distributions.py",
"dense_estimation/densenet.py"
] | [
"## Experimental research code - not part of the depth prediction re-implementation\n\nimport torch\nfrom torch.autograd import Variable\nimport numpy as np\nimport scipy.stats as ss\nimport matplotlib.pyplot as plt\nimport math\n\nfrom pytorch.contrib.distributions import BaseDistribution, MultivariateDiag\n\n\ncl... | [
[
"torch.mean",
"numpy.sqrt",
"scipy.stats.norm.pdf",
"torch.cat",
"torch.sqrt",
"numpy.arange",
"torch.sum",
"matplotlib.pyplot.plot",
"torch.exp",
"torch.log",
"torch.split",
"numpy.array",
"numpy.zeros"
],
[
"torch.nn.functional.softmax",
"torch.nn.... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
collinbrake/image-plot | [
"804b21b2fc36798506bcff43f5d4655c0eac0aed"
] | [
"blitz.py"
] | [
"import numpy as np\nimport cv2 as cv\nfrom matplotlib import pyplot as plt\nfrom mpl_toolkits import mplot3d\n\ndef plot(nparray, scale=1, title=\"Plot\"):\n\n # Scale the image as specified\n nparray = cv.resize(nparray, None, fx=scale, fy=scale,\n interpolation=cv.INTER_CUBIC)\n\n # D... | [
[
"matplotlib.pyplot.axes",
"numpy.meshgrid",
"numpy.linspace",
"matplotlib.pyplot.figure"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
bhatiaabhinav/RL-v2 | [
"38322aac7d1dcb1f9e86dd32bc1d861d143dcd7a"
] | [
"RL/wrappers/atari_wrappers.py"
] | [
"from collections import deque\n\nimport gym\nimport numpy as np\nfrom gym import spaces\nfrom PIL import Image\n\n\nclass NoopResetEnv(gym.Wrapper):\n def __init__(self, env, noop_max=30):\n \"\"\"Sample initial states by taking random number of no-ops on reset.\n No-op is assumed to be action 0.\... | [
[
"numpy.asarray",
"numpy.stack",
"numpy.sign",
"numpy.concatenate",
"numpy.shape",
"numpy.isscalar",
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
hassifow/AMLS_assignment20_21 | [
"b609751dd7b3844e1b7ffece17527840a0a0e8e7"
] | [
"data_loader/A_data_loader.py"
] | [
"import csv\nimport os\nfrom pathlib import Path\n\nimport chardet\nimport random\nimport cv2\nimport numpy as np\nimport pandas as pd\nimport matplotlib.pyplot as plt\nfrom keras.preprocessing import image as Image\nfrom sklearn.model_selection import train_test_split\n\nfont = cv2.FONT_HERSHEY_SIMPLEX\n\n\ndef ge... | [
[
"pandas.read_csv",
"numpy.array",
"sklearn.model_selection.train_test_split"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
plavin/comp_arch_book | [
"deef3f0c97416ae4ba11e8f7ecf0030637197f3a"
] | [
"comp_arch_book/_build/jupyter_execute/notebooks.py"
] | [
"#!/usr/bin/env python\n# coding: utf-8\n\n# # Content with notebooks\n# \n# You can also create content with Jupyter Notebooks. This means that you can include\n# code blocks and their outputs in your book.\n# \n# ## Markdown + notebooks\n# \n# As it is markdown, you can embed images, HTML, etc into your posts!\n#... | [
[
"numpy.random.seed",
"numpy.linspace",
"numpy.logspace",
"matplotlib.pyplot.subplots",
"numpy.random.randn",
"numpy.array",
"matplotlib.pyplot.ion"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
karolmajek/tensorflow-yolov3 | [
"f443bec33a2f0fdafc52f47fa4a31ec8d322497b"
] | [
"nms_demo.py"
] | [
"#! /usr/bin/env python\n# coding=utf-8\n#================================================================\n# Copyright (C) 2018 * Ltd. All rights reserved.\n#\n# Editor : VIM\n# File name : nms_demo.py\n# Author : YunYang1994\n# Created date: 2018-11-27 13:02:17\n# Description :\n#\n#======... | [
[
"tensorflow.Graph",
"numpy.expand_dims",
"tensorflow.Session"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10",
"1.12",
"1.4",
"1.13",
"1.5",
"1.7",
"0.12",
"1.0",
"1.2"
]
}
] |
seungyulhan/disc | [
"f934524fea45637ecc4476149066cd7a68d5702f"
] | [
"baselines/logger.py"
] | [
"import os\nimport sys\nimport shutil\nimport os.path as osp\nimport json\nimport time\nimport datetime\nimport tempfile\nfrom collections import defaultdict\n\nDEBUG = 10\nINFO = 20\nWARN = 30\nERROR = 40\n\nDISABLED = 50\n\nclass KVWriter(object):\n def writekvs(self, kvs):\n raise NotImplementedError\n... | [
[
"tensorflow.python.util.compat.as_bytes",
"pandas.read_csv",
"tensorflow.train.summary_iterator",
"pandas.DataFrame"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.3",
"1.1",
"1.5",
"1.2"
],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
gabbonj/Workbench | [
"86bbb2e3184e0f2fc5e9ac6dc7cfec86473fb7b9"
] | [
"src/transforms.py"
] | [
"import numpy as np\n\ndef normalize(v):\n m = np.sqrt(v[0]**2 + v[1]**2 + v[2]**2)\n if m == 0:\n m = .00001\n return v / m\n\n\ndef get_rot(angle, axis_ix):\n s = np.sin(angle)\n c = np.cos(angle)\n if axis_ix == 0:\n return np.array([[ 1, 0, 0, 0],\n [ 0, ... | [
[
"numpy.cos",
"numpy.array",
"numpy.sqrt",
"numpy.sin"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
nitishgupta/allennlp-semparse | [
"0315b59df482c27ad36808cf7a992f01e07e36b1"
] | [
"tests/state_machines/constrained_beam_search_test.py"
] | [
"import torch\n\nfrom .. import SemparseTestCase\n\nfrom allennlp_semparse.state_machines import ConstrainedBeamSearch\nfrom .simple_transition_system import SimpleState, SimpleTransitionFunction\n\n\nclass TestConstrainedBeamSearch(SemparseTestCase):\n def test_search(self):\n # The simple transition sys... | [
[
"torch.Tensor"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
JosephKJ/continual-learning | [
"2e526cc58ab35d76cddc1df46ee421baea89a727"
] | [
"encoder.py"
] | [
"import torch\nfrom torch.nn import functional as F\nfrom linear_nets import MLP,fc_layer\nfrom exemplars import ExemplarHandler\nfrom continual_learner import ContinualLearner\nfrom replayer import Replayer\nimport utils\n\n\nclass Classifier(ContinualLearner, Replayer, ExemplarHandler):\n '''Model for classify... | [
[
"torch.sigmoid",
"torch.nn.functional.binary_cross_entropy_with_logits",
"torch.nn.functional.cross_entropy"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
pgruening/fp_nets_as_novel_deep_networks_inspired_by_vision | [
"41a0fb236cba9d4af259329d1ccbcb35a1981f3d",
"41a0fb236cba9d4af259329d1ccbcb35a1981f3d",
"41a0fb236cba9d4af259329d1ccbcb35a1981f3d"
] | [
"experiments/new_JOV_result_plots/exe_create_bin_gif.py",
"models/imagenet_legacy_models/mobilenet.py",
"experiments/new_JOV_result_plots/cifar_10_jpeg_compression.py"
] | [
"import subprocess\nfrom os.path import join\n\nimport matplotlib.pyplot as plt\nimport numpy as np\nfrom DLBio.helpers import check_mkdir, set_plt_font_size\nfrom experiments.new_JOV_result_plots import exe_interactive_gradient as igrad\nfrom experiments.new_JOV_result_plots import create_bin_plots as binp\nfrom t... | [
[
"matplotlib.pyplot.scatter",
"numpy.linspace",
"matplotlib.pyplot.subplots",
"matplotlib.pyplot.contour",
"matplotlib.pyplot.close",
"matplotlib.pyplot.axis",
"numpy.array"
],
[
"torch.nn.Dropout",
"torch.nn.Linear",
"torch.nn.init.normal_",
"torch.nn.init.zeros_",
... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [
"0.13",
"1.6",
"... |
jmcdermo/pandas_market_calendars | [
"358825917a24966e5e098c2200fb38e7bde3f315"
] | [
"tests/test_cme_agriculture_calendar.py"
] | [
"import pandas as pd\nimport pytz\n\nfrom pandas_market_calendars.exchange_calendar_cme import CMEAgricultureExchangeCalendar\n\n\ndef test_time_zone():\n assert CMEAgricultureExchangeCalendar().tz == pytz.timezone('America/Chicago')\n assert CMEAgricultureExchangeCalendar().name == 'CME_Agriculture'\n\n\ndef... | [
[
"pandas.Timestamp"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Baraldo/spark-lineage | [
"e9f567da80b6734d6a549f061f0529bb2b57dae8"
] | [
"spark_lineage/Lineage.py"
] | [
"import networkx as nx\r\nimport matplotlib.pyplot as plt\r\n\r\nfrom spark_lineage.LineageParser import LineageParser\r\nfrom spark_lineage.LineagerWrapper import LineageWrapper\r\n\r\nclass Lineage:\r\n def __init__(self, lineage_wrapper: LineageWrapper, produce_parser: LineageParser, require_parser: LineagePa... | [
[
"matplotlib.pyplot.xlim",
"matplotlib.pyplot.savefig"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
WPringle/SeismicMesh | [
"9e73aac63ecc4411163dc4093941af946cffae37"
] | [
"SeismicMesh/generation/utils.py"
] | [
"import numpy as np\nimport copy\nimport scipy.sparse as spsparse\n\n\ndef closestNumber(n, m):\n # Find the quotient\n q = int(n / m)\n\n # 1st possible closest number\n n1 = m * q\n\n # 2nd possible closest number\n if (n * m) > 0:\n n2 = m * (q + 1)\n else:\n n2 = m * (q - 1)\n... | [
[
"scipy.sparse.coo_matrix",
"numpy.linspace",
"numpy.unique",
"numpy.dtype",
"numpy.isscalar",
"numpy.require",
"numpy.empty"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [
"1.7",
"1.0",
"0.10",
"1.2",
"0.14",
"0.19",
"1.5",
"0.12",
"0.17",
"0.13",
"1.6",
"1.4",
"1.9",
"1.3",
"1.10",
"0.15",
"0.18",
"0.16"... |
eycramer/covid19-forecast-hub | [
"7084a80bf08763c0de204d9349c516aeddc13669"
] | [
"data-truth/get-truth-data.py"
] | [
"import pandas as pd\nimport pymmwr as pm\nimport datetime\nimport warnings\nimport io\nimport requests\nwarnings.simplefilter(action='ignore')\n\ndef read_fips_codes(filepath):\n # read file\n fips_codes = pd.read_csv(filepath)\n # take state code from all fips codes\n fips_codes['state_abbr'] = fips_codes['lo... | [
[
"pandas.notnull",
"pandas.read_csv",
"pandas.to_datetime"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
KaihuaTang/VCTree-Visual-Question-Answering | [
"b6b0a8bdb01d45d36de3bded91db42544ad6a593"
] | [
"eval-acc.py"
] | [
"import json\nimport sys\nimport os.path\nfrom collections import defaultdict\n\nimport numpy as np\nimport torch\n\nimport utils\nimport config\n\n\nq_path = utils.path_for(val=True, question=True)\nwith open(q_path, 'r') as fd:\n q_json = json.load(fd)\na_path = utils.path_for(val=True, answer=True)\nwith open... | [
[
"numpy.std",
"numpy.mean",
"torch.load"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
maraboinavamshi/courses | [
"7713267ee5c92e488086588ac41490c44b4f7350"
] | [
"18-05-28-Complete-Guide-to-Tensorflow-for-Deep-Learning-with-Python/07-Reinforcement-Learning-with-OpenAI Gym/05-Policy-Gradient-Gym-NN.py"
] | [
"import tensorflow as tf\nimport gym\nimport numpy as np\n\n##########################\n### VARIABLES ############\n##########################\n\nnum_inputs = 4\nnum_hidden = 4\nnum_outputs = 1\n\nlearning_rate = 0.01\n\ninitializer = tf.contrib.layers.variance_scaling_initializer()\n\n#############################... | [
[
"tensorflow.concat",
"tensorflow.nn.sigmoid",
"tensorflow.contrib.layers.variance_scaling_initializer",
"tensorflow.train.export_meta_graph",
"tensorflow.layers.dense",
"tensorflow.placeholder",
"tensorflow.nn.sigmoid_cross_entropy_with_logits",
"tensorflow.global_variables_initial... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
tim-learn/BA3US | [
"913624e90d419380a85eabd77bd1eaa4454632b9"
] | [
"network.py"
] | [
"import numpy as np\nimport torch\nimport torch.nn as nn\nimport torchvision\nfrom torchvision import models\nfrom torch.autograd import Variable\nimport math\nimport pdb\nimport torch.utils.model_zoo as model_zoo\n\ndef calc_coeff(iter_num, high=1.0, low=0.0, alpha=10.0, max_iter=10000.0):\n return np.float(2.0... | [
[
"torch.nn.Sequential",
"torch.nn.Dropout",
"torch.nn.init.xavier_normal_",
"torch.nn.Sigmoid",
"torch.nn.init.kaiming_uniform_",
"torch.nn.Linear",
"torch.nn.init.normal_",
"torch.nn.init.zeros_",
"torch.nn.ReLU",
"numpy.exp"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
feze23/OpenNMT-tf | [
"27d8de46021ded39b6ffc9f09ec15b141af6cf5e"
] | [
"opennmt/runner.py"
] | [
"\"\"\"Main library entrypoint.\"\"\"\n\nimport copy\nimport os\nimport sys\nimport random\nimport math\nimport shutil\nimport subprocess\nimport tempfile\nimport yaml\n\nimport numpy as np\nimport tensorflow as tf\n\nfrom opennmt import evaluation\nfrom opennmt import inference\nfrom opennmt import models\nfrom op... | [
[
"tensorflow.io.gfile.GFile",
"tensorflow.get_logger",
"numpy.random.seed",
"tensorflow.random.set_seed"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
smkartik/msda | [
"7a09789e6abd4d11abdee3eb5a451c907279eb42"
] | [
"msda/run_viper.py"
] | [
"import subprocess\nimport os\nimport pandas as pd\n\n\ndef sum_duplicate_rows(df, identifier='Gene_Symbol',\n filename='expr_temp.csv'):\n if identifier == 'Gene_Symbol':\n df[identifier] = [g.upper() for g in df[identifier].tolist()]\n df2 = df.sort_values(identifier).groupby(id... | [
[
"pandas.read_csv"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
ixlan/Deep-learning | [
"246e5285b6fb6508814762fddfd00d54515ccf79",
"246e5285b6fb6508814762fddfd00d54515ccf79"
] | [
"hw1/practical_1/uva_code/layers_backup.py",
"hw3/siamese.py"
] | [
"\"\"\"\nThis module implements various layers for the network.\nYou should fill in code into indicated sections.\n\"\"\"\nimport numpy as np\nfrom support import L2\nimport math\n\nclass Layer(object):\n \"\"\"\n Base class for all layers classes.\n\n \"\"\"\n def __init__(self, layer_params):\n \"\"\"\n ... | [
[
"numpy.dot",
"numpy.maximum",
"numpy.random.normal",
"numpy.tanh",
"numpy.zeros",
"numpy.sum"
],
[
"tensorflow.nn.l2_normalize",
"tensorflow.reduce_max",
"tensorflow.shape",
"tensorflow.reduce_sum",
"tensorflow.name_scope",
"tensorflow.histogram_summary",
"t... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10",
"1.12",
"1.4",
"1.13",
"1.5",
"1.7",
"0.12",
"1.0",
"1... |
choderalab/integrator-benchmark | [
"bb307e6ebf476b652e62e41ae49730f530732da3"
] | [
"benchmark/testsystems/coupled_power_oscillators.py"
] | [
"import os\nimport numpy as np\n\nfrom simtk import openmm\nfrom simtk import unit\nfrom simtk.openmm import app\n\nfrom openmmtools.testsystems import TestSystem\n\nfrom benchmark.testsystems.bookkeepers import EquilibriumSimulator\nfrom benchmark.testsystems.configuration import configure_platform\n\nfrom benchma... | [
[
"numpy.random.randn",
"numpy.array",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
one-data-cookie/slack-emoji-stats | [
"c82a0a8c0219f268bdf34ab8003c87675c1e5ce5"
] | [
"slack-emoji-stats.py"
] | [
"import requests as rq\nimport pandas as pd\n\nmsg_url = 'https://slack.com/api/conversations.history'\nmsg_headers = {'content-type': 'application/x-www-form-urlencoded'}\nmsg_params = {\n 'token': 'xoxp-XXXXXXXXXXXX-XXXXXXXXXXXX-XXXXXXXXXXXXX-XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',\n 'channel': 'CXXXXXXXX',\n ... | [
[
"pandas.DataFrame"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"0.23",
"0.21",
"2.0",
"1.4",
"0.19",
"1.1",
"1.5",
"1.2",
"0.24",
"0.20",
"1.0",
"0.25",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
zxtxjtu/pytorch_geometric | [
"8e9f9de9b3ed741c5f65bf75cf7adc10fdb24533"
] | [
"torch_geometric/data/batch.py"
] | [
"import re\n\nimport torch\nfrom torch_geometric.data import Data\n\n\nclass Batch(Data):\n r\"\"\"A plain old python object modeling a batch of graphs as one big\n (dicconnected) graph. With :class:`torch_geometric.data.Data` being the\n base class, all its methods can also be used here.\n In addition,... | [
[
"torch.full",
"torch.cat"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
lukasheuberger/vesicle-imaging | [
"59c4debcb35692d9affb60de701f45df3380788c"
] | [
"vesicle_imaging/czi_zstack_analysis.py"
] | [
"import matplotlib.pyplot as plt\nimport numpy as np\nimport cv2\n\ndef plot_zstack(image_stack: list, input_cmap: str):\n for index, image in enumerate(image_stack):\n plt.figure(figsize = (5,5))\n plt.axis('off')\n slice_title = ''.join(['slice ', str(index)])\n plt.title(slice_titl... | [
[
"matplotlib.pyplot.imshow",
"matplotlib.pyplot.title",
"numpy.min",
"numpy.round",
"numpy.max",
"numpy.std",
"numpy.mean",
"matplotlib.pyplot.axis",
"numpy.average",
"matplotlib.pyplot.figure"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Moahe/PlantsPi | [
"411dea9b46c144d142a145221039433c4553235c"
] | [
"graph.py"
] | [
"# libraries\nimport matplotlib.pyplot as plt\nimport numpy as np\n# https://python-graph-gallery.com/line-chart/\n\n# create data\nvalues = np.cumsum(np.random.randn(1000, 1))\n\n# use the plot function\nplt.plot(values)\nplt.show()\n"
] | [
[
"matplotlib.pyplot.plot",
"matplotlib.pyplot.show",
"numpy.random.randn"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
dash2927/diff_classifier | [
"8b67ca314711fe6325ff571c3a917102ed1df197"
] | [
"diff_classifier/heatmaps.py"
] | [
"import matplotlib as mpl\nimport numpy as np\nimport pandas as pd\nimport matplotlib.pyplot as plt\nfrom scipy.spatial import Voronoi\nimport scipy.stats as stats\nimport os\nimport os.path as op\nfrom shapely.geometry import Point\nfrom shapely.geometry.polygon import Polygon\nimport numpy.ma as ma\nimport matplo... | [
[
"matplotlib.pyplot.legend",
"numpy.dot",
"scipy.spatial.Voronoi",
"numpy.linspace",
"numpy.asarray",
"matplotlib.pyplot.rc",
"matplotlib.pyplot.plot",
"numpy.arctan2",
"numpy.mean",
"numpy.ma.masked_where",
"numpy.ma.getmask",
"numpy.histogram",
"numpy.exp",
... | [
{
"matplotlib": [],
"numpy": [
"1.11",
"1.10",
"1.12",
"1.19",
"1.13",
"1.16",
"1.9",
"1.18",
"1.20",
"1.7",
"1.15",
"1.14",
"1.17",
"1.8"
],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
codlaug/zenbot | [
"f3066dd7f7fded1d9c1aeaff8d0ba83fbec9bea3"
] | [
"hello.py"
] | [
"import sys\nimport ta\nimport pandas as pd\nfrom sklearn.preprocessing import minmax_scale\nimport numpy as np\nimport tensorflow as tf\n\nsess=tf.Session() \nsignature_key = tf.saved_model.signature_constants.DEFAULT_SERVING_SIGNATURE_DEF_KEY\ninput_key = 'x_input'\noutput_key = 'y_output'\n\nimport_path = './de... | [
[
"pandas.DataFrame",
"numpy.append",
"numpy.array_str",
"tensorflow.Session",
"sklearn.preprocessing.minmax_scale",
"tensorflow.saved_model.loader.load"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"0.23",
"0.21",
"2.0",
"1.4",
"0.19",
"1.1",
"1.5",
"1.2",
"0.24",
"0.20",
"1.0",
"0.25",
"1.3"
],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
hanantabak2/Bringing-Old-Photos-Back-to-Life | [
"e0b1313159e156eab269f36a096bb0b098bb5c9a"
] | [
"Global/train_mapping.py"
] | [
"# Copyright (c) Microsoft Corporation.\n# Licensed under the MIT License.\n\nimport time\nfrom collections import OrderedDict\nfrom options.train_options import TrainOptions\nfrom data.data_loader import CreateDataLoader\nfrom models.mapping_model import Pix2PixHDModel_Mapping\nimport util.util as util\nfrom util.... | [
[
"torch.mean",
"numpy.savetxt",
"torch.nn.DataParallel",
"numpy.loadtxt",
"torch.autograd.Variable"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
jake106/pl_curves | [
"1c777eb6f7dd993c0ef88497114ba2221478feb2"
] | [
"tests/test_gini.py"
] | [
"#!/usr/bin/env python3\n'''\nunit test for the gini coefficient function\n'''\nfrom pl_curve import calculate_gini\nimport pandas as pd\nimport math\n\n\ndef test_gini_empty():\n '''test calculating a gini coefficient with an empty list\n This will cause some warnings from python\n '''\n gini = calcula... | [
[
"pandas.Series"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"0.23",
"0.21",
"2.0",
"1.4",
"0.19",
"1.1",
"1.5",
"1.2",
"0.24",
"0.20",
"1.0",
"0.25",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
IHR-Nom/Full_Page_Recognition | [
"27899ece69e328e8d40a8cf5214a77a6ab8aef35"
] | [
"predict.py"
] | [
"import torch\nimport torchvision\n\nfrom transformers import BertTokenizer\nfrom PIL import Image\nimport argparse\n\nfrom models import caption\nfrom datasets import coco, utils, wikitext, iam\nfrom configuration import Config\nimport os\nimport numpy as np\n\n# parser = argparse.ArgumentParser(description='Image... | [
[
"torch.ones",
"torch.zeros",
"numpy.asarray",
"torch.load",
"torch.no_grad",
"torch.argmax"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
yutiansut/alphalens | [
"67d79a0425675cdbb30a21cfab3780a6d7c0f8e9"
] | [
"alphalens/tears.py"
] | [
"#\n# Copyright 2017 Quantopian, 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... | [
[
"pandas.tseries.offsets.BDay",
"pandas.Timedelta",
"matplotlib.pyplot.subplot",
"matplotlib.gridspec.GridSpec",
"matplotlib.pyplot.close",
"matplotlib.pyplot.show",
"matplotlib.pyplot.figure"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
gregorywaynepower/DASHNextGenMigration | [
"81fa0d373925611b29ce8df599f371880a56ea87",
"81fa0d373925611b29ce8df599f371880a56ea87"
] | [
"Archive/DASHNextGen_Service_delimited.py",
"DASHNextGen_Job_date_BIG.py"
] | [
"\"\"\"\nThis script has been deprecated in favor of DASHNextGen_Service_Report.py.\n\"\"\"\n\nimport selenium\nfrom selenium import webdriver\nfrom selenium.webdriver.common.keys import Keys\nfrom selenium.webdriver.chrome.webdriver import Options\nfrom webdriver_manager.chrome import ChromeDriverManager\nfrom sel... | [
[
"pandas.to_datetime",
"pandas.DataFrame",
"pandas.read_html"
],
[
"pandas.to_datetime",
"pandas.DataFrame",
"pandas.read_html"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"0.23",
"0.21",
"2.0",
"1.4",
"1.3",
"0.19",
"1.1",
"1.5",
"0.24",
"0.20",
"1.0",
"0.25",
"1.2"
],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"nump... |
pooyanjamshidi/xgboost-xplorer | [
"78e8a7b9e09148bbd001dcad08b4ff3ff172f149"
] | [
"run_exp.py"
] | [
"# import classes and functions\nimport numpy as np\nimport itertools\nimport csv\nfrom pandas import read_csv\nfrom xgboost import XGBClassifier\nfrom sklearn.model_selection import train_test_split\nfrom sklearn.metrics import accuracy_score\nimport time\nimport os\n\n\ndef write_configuration(name, configs, opti... | [
[
"numpy.random.seed",
"sklearn.model_selection.train_test_split",
"numpy.random.permutation",
"numpy.array",
"sklearn.metrics.accuracy_score"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
HS88/CS281 | [
"a64995f4569070a9c3e1ca17a4a1ba6dff277135"
] | [
"keras_interactnet/data_augment.py"
] | [
"import cv2\nimport numpy as np\nimport copy\nfrom PIL import Image\nimport urllib, cStringIO\n\ndef augment(img_data, config, augment=True):\n assert 'filepath' in img_data\n assert 'bboxes' in img_data\n assert 'width' in img_data\n assert 'height' in img_data\n\n img_data_aug = copy.deepcopy(img_d... | [
[
"numpy.transpose",
"numpy.random.choice",
"numpy.random.randint"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
renhongkai/LSTM-CRF | [
"cb47d7d865152893a06fbb890a5cbaa9fb7d03c0"
] | [
"model/lstm_crf.py"
] | [
"\"\"\"\r\n.. module:: lstm_crf\r\n :synopsis: lstm_crf\r\n \r\n.. moduleauthor:: Liyuan Liu\r\n\"\"\"\r\n\r\nimport torch\r\nimport torch.autograd as autograd\r\nimport torch.nn as nn\r\nimport model.crf as crf\r\nimport model.utils as utils\r\n\r\n\r\nclass LSTM_CRF(nn.Module):\r\n \"\"\"LSTM_CRF model\r\n\... | [
[
"torch.nn.Dropout",
"torch.nn.Parameter",
"torch.nn.LSTM",
"torch.randn",
"torch.nn.Embedding"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
a-gilbert/statsmodels | [
"f3f89ad777b22e6db565897397ece24d41af5700",
"f3f89ad777b22e6db565897397ece24d41af5700"
] | [
"statsmodels/tsa/tests/test_exponential_smoothing.py",
"statsmodels/tsa/exponential_smoothing/base.py"
] | [
"\"\"\"\nAuthor: Samuel Scherrer\n\"\"\"\nfrom itertools import product\nimport json\nimport pathlib\n\nimport numpy as np\nfrom numpy.testing import assert_allclose, assert_almost_equal\nimport pandas as pd\nimport pytest\nimport scipy.stats\n\nfrom statsmodels.tsa.exponential_smoothing.ets import ETSModel\n\n# Th... | [
[
"numpy.log",
"pandas.Series",
"pandas.date_range",
"numpy.asarray",
"numpy.all",
"numpy.testing.assert_almost_equal",
"numpy.random.randn",
"numpy.testing.assert_allclose",
"numpy.random.RandomState"
],
[
"numpy.diag",
"numpy.ix_",
"numpy.ones_like",
"numpy.... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"0.23",
"0.21",
"2.0",
"1.4",
"1.3",
"0.19",
"1.1",
"1.5",
"0.24",
"0.20",
"1.0",
"0.25",
"1.2"
],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"nump... |
vacary/siconos-tutorials | [
"93c0158321077a313692ed52fed69ff3c256ae32"
] | [
"examples/mechanics/Mechanisms/SliderCrank/bodydef.py"
] | [
"\"\"\"Simulation of a slider-crank system.\nCheck examples manual for details.\n\n\"\"\"\n\nimport numpy as np\nimport array\nimport subprocess\nimport siconos.mechanisms.mbtb as mbtb\n\ncommand = ['siconos', '--build-plugins', '-q']\nsubprocess.run(command)\n\n\nWITH_CLEARANCE_ON_RODE = 1\n\"\"\"if true, add clea... | [
[
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
bw-airbnb-2/family-promise-spokane-ds-b | [
"22c1f569064ac6963da1ddc1428ccf3c86e0978e"
] | [
"fps_dashboard/des_statistics.py"
] | [
"# Setup:\nfrom datetime import datetime\nimport numpy as np\nimport os\nimport pandas as pd\nimport streamlit as st\n\n# Plot:\nimport altair as alt\nimport matplotlib.pyplot as plt\nimport seaborn as sns\n\n\ndef write():\n @st.cache\n def loadDataFile(filePath):\n df = pd.read_csv(filePath, parse_da... | [
[
"pandas.read_csv",
"matplotlib.pyplot.subplots",
"matplotlib.pyplot.title"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
EMBEDDIA/jiant_slovene | [
"2f4d79470143af51603dc7257f0c5aeba2e91ac9"
] | [
"src/utils/utils.py"
] | [
"\"\"\"\nAssorted utilities for working with neural networks in AllenNLP.\n\"\"\"\nfrom typing import Dict, List, Sequence, Optional, Union, Iterable\n\nimport copy\nimport os\nimport json\nimport random\nimport logging\nimport codecs\nimport time\n\nfrom nltk.tokenize.moses import MosesTokenizer, MosesDetokenizer\... | [
[
"torch.nn.Dropout",
"torch.nn.init.xavier_normal_",
"torch.nn.Linear",
"torch.FloatTensor",
"torch.bmm",
"torch.split"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
inyukwo1/rat-sql | [
"b2ae26f91e8dafcda21d2dbcd74fbaf89ad5d2ed"
] | [
"ratsql/utils/saver.py"
] | [
"\"\"\"Tools to save/restore model from checkpoints.\"\"\"\n\nimport argparse\nimport shutil\nimport sys\nimport os\nimport re\nimport json\nimport time\n\nimport torch\n\nCHECKPOINT_PATTERN = re.compile(r'^model_checkpoint-(\\d+)$')\n\n\nclass ArgsDict(dict):\n\n def __init__(self, **kwargs):\n super(Arg... | [
[
"torch.save",
"torch.load"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
tna-webarchive/A-Z-list | [
"36dc4243dbcc61c5ab49c742d977c0257d8679a5"
] | [
"add_sites.py"
] | [
"import os, re\nimport string\nimport sys\n\nimport pandas as pd\nimport requests\nfrom datetime import datetime, date\nfrom tqdm import tqdm\nimport openpyxl as pxl\nfrom openpyxl.utils.dataframe import dataframe_to_rows\nfrom shutil import copy, rmtree\nfrom openpyxl.worksheet.datavalidation import DataValidation... | [
[
"pandas.concat",
"pandas.read_excel",
"pandas.read_csv"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.3",
"1.1",
"1.5",
"1.2"
],
"scipy": [],
"tensorflow": []
}
] |
nmegiddo/adversarial-robustness-toolbox | [
"183b672470a5284dc374d1a177497d4ec69dcc07"
] | [
"art/estimators/certification/randomized_smoothing/pytorch.py"
] | [
"# MIT License\n#\n# Copyright (C) The Adversarial Robustness Toolbox (ART) Authors 2020\n#\n# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated\n# documentation files (the \"Software\"), to deal in the Software without restriction, including without limita... | [
[
"torch.randn_like",
"torch.nn.functional.softmax",
"torch.nn.functional.nll_loss",
"torch.from_numpy",
"torch.tensor",
"numpy.argmax"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.