repo_name stringlengths 6 130 | hexsha list | file_path list | code list | apis list | possible_versions list |
|---|---|---|---|---|---|
brandontrabucco/im2txt_attend | [
"b1381574139a5dc54e4a6f6635bf6cf676e1dad8"
] | [
"im2txt_attend/data/build_mscoco_data.py"
] | [
"# Copyright 2016 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 requ... | [
[
"tensorflow.train.Int64List",
"tensorflow.image.decode_jpeg",
"tensorflow.gfile.FastGFile",
"numpy.linspace",
"tensorflow.flags.DEFINE_string",
"numpy.arange",
"tensorflow.train.Coordinator",
"tensorflow.train.SequenceExample",
"tensorflow.placeholder",
"tensorflow.python_i... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
ismetshn/qiskit-terra | [
"691ffdf7fe50214cf944783357fdcb5c5054e9c2"
] | [
"qiskit/extensions/standard/u3.py"
] | [
"# -*- coding: utf-8 -*-\n\n# This code is part of Qiskit.\n#\n# (C) Copyright IBM 2017.\n#\n# This code is licensed under the Apache License, Version 2.0. You may\n# obtain a copy of this license in the LICENSE.txt file in the root directory\n# of this source tree or at http://www.apache.org/licenses/LICENSE-2.0.\... | [
[
"numpy.exp",
"numpy.cos",
"numpy.sin"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
rosocz/CarND-Capstone | [
"39831a307ca71e9d5fb7a7deb7a7a1a58cabfb44"
] | [
"train_nn/train.py"
] | [
"import os\nimport numpy as np\nimport pandas as pd\nimport random\nimport cv2\nimport csv\nimport math\nimport glob\nfrom sklearn import model_selection\nfrom skimage.transform import rescale\n\nfrom keras import backend as K\nfrom keras import models, optimizers\nfrom keras.models import Sequential\nfrom keras.la... | [
[
"tensorflow.python.client.device_lib.list_local_devices",
"sklearn.model_selection.train_test_split",
"numpy.ndarray",
"numpy.ceil",
"numpy.copy",
"numpy.append",
"numpy.empty"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10",
"2.7",
"1.12",
"2.6",
"2.2",
"1.13",
"2.3",
"2.4",
"1.4",
"2.9",
"1.5",
"1.7",
"2.5",
"0.12",
"1.0",
"2.8",
"1... |
kuperov/distrax | [
"dd3363a64017c5eafb3241bb2a3884de50f21427"
] | [
"distrax/_src/bijectors/scalar_affine_test.py"
] | [
"# Copyright 2021 DeepMind Technologies Limited. 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# Unle... | [
[
"numpy.zeros",
"numpy.prod",
"numpy.testing.assert_allclose"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Warmshawn/CaliCompari | [
"34cb5204a1b11a799f94b233189ebcd87816cbc1"
] | [
"Python/calicompari.py"
] | [
"#!/usr/bin/env python\n# Copyright 2013 Jonathan Whitmore\n# Distributed under the Boost Software License, Version 1.0.\n#\n# Permission is hereby granted, free of charge, to any person or organization\n# obtaining a copy of the software and accompanying documentation covered by\n# this license (the \"Software\") ... | [
[
"numpy.polyfit",
"numpy.linspace",
"matplotlib.pylab.errorbar",
"numpy.nan_to_num",
"numpy.max",
"numpy.zeros_like",
"numpy.average",
"matplotlib.pylab.legend",
"numpy.hstack",
"matplotlib.pylab.yticks",
"numpy.arange",
"numpy.min",
"numpy.append",
"matplotl... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
fcco/SkySol | [
"78a0a35139f51f56a8c32d75908d0203dfb19eea"
] | [
"skysol/lib/classification.py"
] | [
"\"\"\"\nModule for cloud classification training and application\n\nIt uses sklearn for machine learning\n\"\"\"\n\nimport numpy as np\nimport csv\nimport os\nimport time\nimport h5py\nfrom operator import itemgetter\n\nfrom sklearn.svm import SVC\nfrom sklearn.neighbors import KNeighborsClassifier\nfrom sklearn i... | [
[
"sklearn.tree.DecisionTreeClassifier",
"numpy.where",
"sklearn.model_selection.ShuffleSplit",
"sklearn.ensemble.RandomForestClassifier",
"numpy.arange",
"numpy.float16",
"sklearn.neighbors.KNeighborsClassifier",
"numpy.std",
"matplotlib.pyplot.figure",
"matplotlib.pyplot.ti... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Mofetoluwa/text2text | [
"a1b7868854449cd8b0f874cc1aeb02bae97a05a6"
] | [
"text2text/biunilm/seq2seq_loader.py"
] | [
"from random import randint, shuffle, choice\nfrom random import random as rand\nimport math\nimport torch\n\nfrom .loader_utils import get_random_word, batch_list_to_batch_tensors, Pipeline\n\n# Input file format :\n# 1. One sentence per line. These should ideally be actual sentences,\n# not entire paragraphs o... | [
[
"torch.ones",
"torch.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
zalanborsos/coresets | [
"47896a68c79666496cf1ef1d2683bd76875fe013"
] | [
"tests/test_sensitivity.py"
] | [
"from __future__ import division, absolute_import\n\nimport pytest\nfrom sklearn.datasets import load_iris\nimport numpy as np\n\nfrom coresets import *\n\n\nclass TestSensitivity(object):\n\n @pytest.fixture\n def gen_data(self):\n X, _ = load_iris(return_X_y=True)\n centers = X[np.random.choic... | [
[
"numpy.allclose",
"numpy.min",
"numpy.arange",
"sklearn.datasets.load_iris",
"numpy.ones",
"numpy.argmin",
"numpy.bincount",
"numpy.mean",
"numpy.where",
"numpy.zeros",
"numpy.sum"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
zygmuntz/time-series-classification | [
"31026cd3448cb2a1807267cfa5b460aa8386830b"
] | [
"train_and_evaluate.py"
] | [
"#!/usr/bin/env python\n\n\"train a binary classifier on extracted features, predict, evaluate\"\n\nimport pandas as pd\n\nfrom pprint import pprint\nfrom sklearn.preprocessing import StandardScaler, MinMaxScaler\nfrom sklearn.pipeline import make_pipeline\nfrom sklearn.linear_model import LogisticRegression as LR\... | [
[
"sklearn.metrics.roc_auc_score",
"pandas.read_csv",
"sklearn.linear_model.LogisticRegression",
"sklearn.ensemble.RandomForestClassifier",
"sklearn.preprocessing.StandardScaler",
"sklearn.preprocessing.MinMaxScaler",
"sklearn.metrics.accuracy_score"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
rejane-paulino/exercicos | [
"c8844dd7beb8eecdf92b2852e1f5356b15d2de06"
] | [
"exercicio-02.py"
] | [
"#!/usr/bin/env python\n# coding: utf-8\n\n# In[26]:\n\n\n#Exercicio 02\n\nimport matplotlib.pyplot as plt\n\n#Grupos de Idade\ng_idade = ['0 a 4','5 a 9','10 a 14','15 a 19','20 a 24','25 a 29','30 a 34','35 a 39','40 a 44','45 a 49','50 a 54','55 a 59','60 a 64','65 a 69','70 a 74','75 a 79','80 a 84','85 a 89','... | [
[
"matplotlib.pyplot.title",
"matplotlib.pyplot.ylabel",
"matplotlib.pyplot.bar",
"matplotlib.pyplot.xlabel",
"matplotlib.pyplot.yticks",
"matplotlib.pyplot.show",
"matplotlib.pyplot.xticks",
"matplotlib.pyplot.figure"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
aysedemirel/udacity-pytorch-scholarship | [
"48823e9f97c2bbb7f2df0b2b6363623dd11587fa"
] | [
"perceptron.py"
] | [
"import numpy as np\n# Setting the random seed, feel free to change it and see different solutions.\nnp.random.seed(42)\n\ndef stepFunction(t):\n if t >= 0:\n return 1\n return 0\n\ndef prediction(X, W, b):\n return stepFunction((np.matmul(X,W)+b)[0])\n\n# TODO: Fill in the code below to implement t... | [
[
"numpy.matmul",
"numpy.random.rand",
"numpy.random.seed"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
himanshu007-creator/jina | [
"129c7d9db4b0e3077a621f58570e4848b46d5740"
] | [
"jina/types/document/__init__.py"
] | [
"import base64\nimport json\nimport mimetypes\nfrom collections import Counter\nfrom hashlib import blake2b\nfrom typing import (\n Any,\n Dict,\n Iterable,\n List,\n Optional,\n Tuple,\n Type,\n TypeVar,\n Union,\n overload,\n)\n\nimport numpy as np\nfrom google.protobuf import json_f... | [
[
"numpy.array",
"scipy.sparse.issparse"
]
] | [
{
"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"... |
ProkopHapala/ProbeParticleModel | [
"1afbd32cbf68440d71c2ee53f2066c898a00ae23"
] | [
"pyProbeParticle/HighLevel.py"
] | [
"#!/usr/bin/python\n\nimport numpy as np\nimport os\nfrom . import GridUtils as GU\nfrom . import basUtils as bU\nfrom . import fieldFFT\nfrom . import common as PPU\n\nfrom . import core\nfrom . import cpp_utils\n\n# overall procedure for importing the sample geometry:\n\ndef importGeometries( fname ):\n if (fn... | [
[
"numpy.shape",
"numpy.transpose",
"numpy.array",
"numpy.exp",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
pn11/anchor-stats | [
"51c4195ac65261b59c25991fc3e64dba085791ba"
] | [
"analyze.py"
] | [
"import glob\nimport os\n\nimport matplotlib.pyplot as plt\nimport numpy as np\nimport pandas as pd\n\n\ndef make_label(filename):\n filename = filename.split('/')[-1]\n filename = filename.split('_')[0]\n # sometimes unexpected '%'\n filename = filename.split('%')[0]\n filename = filename[:10]\n ... | [
[
"pandas.merge",
"pandas.to_datetime",
"pandas.read_csv",
"numpy.cumsum",
"matplotlib.pyplot.show",
"matplotlib.pyplot.figure"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.3",
"1.1",
"1.5",
"1.2"
],
"scipy": [],
"tensorflow": []
}
] |
Amanuel4/Finger-Counter-project | [
"37987e9efc28f27adb11a1b0f32847a507217c54"
] | [
"Finger Counter.py"
] | [
"import cv2\r\nimport time\r\nimport pygame\r\nimport numpy as np\r\nimport mediapipe as mp\r\nfrom PIL import Image\r\nimport matplotlib.pyplot as plt\r\n\r\n# Initialize the mediapipe hands class.\r\nmp_hands = mp.solutions.hands\r\n\r\n# Set up the Hands functions for images and videos.\r\n#hands = mp_hands.Hand... | [
[
"matplotlib.pyplot.imshow",
"matplotlib.pyplot.title",
"matplotlib.pyplot.subplot",
"matplotlib.pyplot.axis",
"matplotlib.pyplot.figure"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
n-zhang/mmf | [
"9d76995ac76e70544315701a5057f4269949514f"
] | [
"tests/test_utils.py"
] | [
"# Copyright (c) Facebook, Inc. and its affiliates.\nimport argparse\nimport platform\nimport random\nimport socket\nimport unittest\n\nimport torch\n\n\ndef compare_tensors(a, b):\n return torch.equal(a, b)\n\n\ndef dummy_args(model=\"cnn_lstm\", dataset=\"clevr\"):\n args = argparse.Namespace()\n args.op... | [
[
"torch.equal",
"torch.tensor",
"torch.nn.Linear",
"torch.rand",
"torch.cuda.is_available"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
rparak/Bezier_Curve_Simple | [
"06531e17601a52c65aef36c38d61673fee676751"
] | [
"src/Python/Animation/animation_2D.py"
] | [
"\"\"\"\n## =========================================================================== ## \nMIT License\nCopyright (c) 2021 Roman Parak\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software wit... | [
[
"numpy.array",
"matplotlib.pyplot.subplots",
"numpy.float"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
spenczar/thor | [
"d0f3d0f07ffb069d1ca94701ad32f3c0c013aa61"
] | [
"submitTHORJob.py"
] | [
"import logging\nimport argparse\nimport pandas as pd\nimport os\n\nimport pika\nfrom google.cloud.storage import Client as GCSClient\nimport google.cloud.exceptions\n\nlogger = logging.getLogger(\"thor\")\n\n\ndef parse_args():\n parser = argparse.ArgumentParser(\n description=\"Run Tracklet-less Helioce... | [
[
"pandas.read_csv"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
dropoutlabs/PySyft-TensorFlow | [
"70c80872babb4d7926d2b57242850751903bff31"
] | [
"syft_tensorflow/serde/serde_test.py"
] | [
"import tensorflow as tf\nimport syft\n\ndef test_serde_constant():\n z = tf.constant([1.0, 2.0])\n z.id = 123456\n\n ser = syft.serde.serialize(z)\n x = syft.serde.deserialize(ser)\n\n assert all(tf.math.equal(x, z))\n assert x.id == z.id\n assert x.dtype == z.dtype\n\ndef test_serde_tensorsha... | [
[
"tensorflow.math.equal",
"tensorflow.TensorShape",
"tensorflow.constant"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
saman-codes/dldojo | [
"9fd828f1902ba3d46e9bb5f554ef37d07335b29e"
] | [
"src/network.py"
] | [
"# Standard Python\nimport os\nimport copy\nimport pickle\nimport logging\nfrom collections import OrderedDict\n\n# Local\nfrom layers import Layer\nfrom losses import BinaryCrossEntropy\n\n# Thirdparty\nimport numpy as np\nfrom tqdm import tqdm\nimport matplotlib.pyplot as plt\n\nlogging.basicConfig(format='%(mess... | [
[
"numpy.absolute",
"matplotlib.pyplot.title",
"matplotlib.pyplot.plot",
"numpy.random.permutation",
"matplotlib.pyplot.show"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
vprzybylo/IPAS | [
"9c9268097b9d7d02be1b14671b8fbfc1818e02c0"
] | [
"ipas/collection_no_db/iceagg_collection_nodask.py"
] | [
"\"\"\"\nMain function for running ice particle simulations\nICE-AGG collection\nincludes looping over ncrystals instead of doing that outside in a dask computation\n\"\"\"\n\nfrom ipas.collection_no_db.crystal import Crystal\nfrom ipas.collection_no_db.calculations import ClusterCalculations\nimport copy as cp\nim... | [
[
"numpy.sqrt",
"numpy.empty",
"numpy.power"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
flodorner/safety-starter-agents | [
"d140ce69c817a7939232d2c7848c0dfa55de8e90"
] | [
"safe_rl/sac/sac.py"
] | [
"#!/usr/bin/env python\n\nfrom functools import partial\nimport numpy as np\nimport tensorflow as tf\nimport gym\nimport time\nfrom safe_rl.utils.logx import EpochLogger\nfrom safe_rl.utils.mpi_tf import sync_all_params, MpiAdamOptimizer\nfrom safe_rl.utils.mpi_tools import mpi_fork, mpi_sum, proc_id, mpi_statistic... | [
[
"tensorflow.get_variable",
"tensorflow.concat",
"tensorflow.control_dependencies",
"tensorflow.reduce_sum",
"tensorflow.minimum",
"tensorflow.global_variables",
"tensorflow.abs",
"tensorflow.tanh",
"tensorflow.group",
"numpy.random.randint",
"tensorflow.layers.dense",
... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
smnmnkr/geneticNLP | [
"f053cde54f90a3c213e355dc0c4038b0f7583bd0",
"f053cde54f90a3c213e355dc0c4038b0f7583bd0"
] | [
"beyondGD/data/loader.py",
"tests/test__nn.py"
] | [
"from typing import Union\n\n\nfrom torch.utils.data import (\n Dataset,\n IterableDataset,\n DataLoader,\n)\n\n#\n#\n# -------- batch_loader -----------\n#\ndef batch_loader(\n data_set: Union[IterableDataset, Dataset],\n batch_size: int = 32,\n shuffle: bool = False,\n num_workers: int = 0,\... | [
[
"torch.utils.data.DataLoader"
],
[
"torch.randn"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
khansaadbinhasan/Low-Cost-Autonomous-Vehicle-for-Inventory-Movement-in-Warehouses | [
"3c24390a49a76f893675e606ca24fccdbcce43e2"
] | [
"src/Workstation/Misc/path planning/process_image.py"
] | [
"import cv2\nimport numpy as np\nimport time\nimport astarsearch\nimport traversal\nfrom sklearn.cluster import KMeans\nfrom skimage import io\nimport matplotlib.pyplot as plt\n\ndef main(source , dest, cap, grid_size,frame_width, frame_height,decision):\n\n\toccupied_grids = []\t\t# List to store coordinates of oc... | [
[
"numpy.array",
"numpy.zeros",
"numpy.ones"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Jack-alope/tempers | [
"c5b019d2f5f14a55b6a9656e32a110c1d5c6c088"
] | [
"tests/test_tissue_class.py"
] | [
"\"\"\"\nTesting for the point finding class\n\"\"\"\n\n# import matplotlib.pyplot as plt\nimport numpy as np\n\n\ndef test_find_peaks(tissue_object):\n \"\"\"Testing peaks are where they schould be\"\"\"\n assert np.all([round(time % np.pi, 3) == 1.571 for time in tissue_object.peaks[0]])\n assert np.all(... | [
[
"numpy.absolute"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
raimamathew/Brain-Tumor-Segmentation | [
"748bc37b61a2e89637a2ddf1da9029c0c820f400"
] | [
"train_script.py"
] | [
"import matplotlib.pyplot as plt\nfrom mpl_toolkits.mplot3d import Axes3D\nimport numpy as np\nimport os\nfrom skimage import measure\nimport re\nimport nibabel as nib\nimport tensorflow as tf\nimport time\nfrom scipy.ndimage import zoom\nimport tensorflow as tf\nfrom tensorflow.keras.models import Model, load_mode... | [
[
"tensorflow.keras.callbacks.ModelCheckpoint",
"numpy.logical_not",
"tensorflow.keras.layers.Activation",
"tensorflow.keras.models.Model",
"tensorflow.keras.layers.MaxPooling3D",
"tensorflow.keras.layers.UpSampling3D",
"tensorflow.keras.layers.Conv3D",
"tensorflow.keras.layers.conca... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"2.7",
"2.2",
"2.3",
"2.4",
"2.5",
"2.6"
]
}
] |
labsyspharm/deeptile | [
"b79a52f9613d5f8861b31e68a407cf507a90bcbe"
] | [
"sampling/run_tile_mcmc.py"
] | [
"import numpy as np\nimport pandas as pd\nimport time\nimport argparse\nimport os\nimport copy\nimport typing\n\nimport tqdm\nimport tensorflow as tf\n\n'''\n# turn on memory growth so GPU memory allocation becomes as-needed\n# for cases when training takes too much memory.\ngpus = tf.config.experimental.list_physi... | [
[
"numpy.random.normal",
"tensorflow.keras.optimizers.Adam",
"numpy.random.rand"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10",
"2.7",
"2.2",
"2.3",
"2.4",
"2.5",
"2.6"
]
}
] |
Jeffyrao/translate | [
"ab928e0b692f476c0a43ee7f9d0fbd3ecbada2b4"
] | [
"pytorch_translate/utils.py"
] | [
"#!/usr/bin/env python3\n\nimport argparse\nimport os\nimport signal\nimport threading\nimport time\nfrom typing import List, Optional\n\nimport torch\nfrom fairseq import distributed_utils, tasks, utils\n\n\n# Helper type for argparse to enable flippable boolean flags. For example,\n# group.add_argument(\"--foo\",... | [
[
"torch.zeros",
"torch.cat",
"torch.zeros_like",
"torch.serialization.default_restore_location",
"torch.sort",
"torch.cuda.is_available",
"torch.arange"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Koopakiller/Edu-NLA | [
"8376557cab9f74cedd19ee1573a8c71d7e415dd4",
"8376557cab9f74cedd19ee1573a8c71d7e415dd4"
] | [
"serie4/plot.py",
"serie2/Sum.py"
] | [
"import matplotlib\nmatplotlib.use(\"TkAgg\")\nimport matplotlib.pyplot as plt\nimport numpy\nimport math\n\n\ndef plot(parameter_list, data_points_list):\n e = math.e\n\n x = numpy.arange(0, 25, 0.01)\n for entry in parameter_list:\n a, b, c, d, k, n, _, _, _ = entry\n plt.plot(x, a * (e ** ... | [
[
"matplotlib.pyplot.legend",
"matplotlib.use",
"numpy.arange",
"matplotlib.pyplot.xlabel",
"matplotlib.pyplot.show",
"matplotlib.pyplot.ylabel"
],
[
"numpy.isnan",
"numpy.float16",
"numpy.isposinf",
"numpy.isneginf"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Shivam-Miglani/contextual_drl | [
"0f9930ff2b90522c3bd3319daa4b02167ab8190d"
] | [
"main_easdrl.py"
] | [
"# coding:utf-8\nimport time\nimport argparse\nimport tensorflow as tf\nfrom utils import get_time, plot_results\nfrom Agent import Agent\nfrom EADQN import DeepQLearner\nfrom Environment import Environment\nfrom ReplayMemory import ReplayMemory\nfrom gensim.models import KeyedVectors\nfrom tqdm import tqdm\nfrom k... | [
[
"tensorflow.compat.v1.reset_default_graph",
"tensorflow.compat.v1.ConfigProto",
"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"
]
}
] |
Liuhongzhi2018/Car_detection | [
"f32fea9c348c691ccc30b9804a4f3fa32732bbae"
] | [
"video_demo_car.py"
] | [
"# -*- coding: utf-8 -*-\r\n\"\"\"\r\nCreated on Sun Apr 12 14:47:25 2020\r\n@author: NAT\r\n\"\"\"\r\nimport sys\r\nsys.path.append(\"./model/\")\r\nimport numpy as np\r\nimport cv2\r\nfrom PIL import Image, ImageDraw, ImageFont\r\nfrom utils import *\r\nfrom torchvision import transforms\r\nimport torch\r\nfrom m... | [
[
"numpy.array",
"torch.FloatTensor",
"torch.cuda.is_available",
"torch.load"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
john-hawkins/Minimum_Required_MLModel_Estimator | [
"dbcb7622b8fced2db8bfdbf0f608936534925971"
] | [
"minvime/generator.py"
] | [
"\"\"\" \n Distribution Generators for use in Performance Estimation for Regression Models\n\"\"\"\nimport random\nimport numpy as np\nimport pandas as pd\n\n######################################################################\ndef extract_distribution_from_sample(filepath):\n \"\"\" Extract a sample of tar... | [
[
"pandas.read_csv",
"numpy.issubdtype",
"numpy.std",
"numpy.random.normal",
"numpy.mean"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
CactusBall/MobaAnalysis | [
"efe6c58cbffaf94220db79e7fda579dea97cb3ac"
] | [
"analysis/test.py"
] | [
"import pandas as pd\n\ncsv = pd.read_csv('/Users/emrys/Documents/BattleList.csv')\nopenids = csv.get('openid')\ngames = csv.get('game_seq')\nfor o in openids:\n # print(o)\n if 'owanlsn0eMVK8aKyiWf0sYWxW5VU' == o:\n\n print('yes')\n\n# print('owanlsoStRgq-MP1HX3ueUHLE73U' is 'owanlsoStRgq-MP1HX3ueUHLE... | [
[
"pandas.read_csv"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
S-ayanide/Human-Action-Classifier-And-Pedestrian-Detection | [
"553ad687a677f155e4c0bb4f59d4949e70fd6cfc"
] | [
"posenet-py/webcam_demo.py"
] | [
"import tensorflow as tf\nimport cv2\nimport time\nimport argparse\n\nimport posenet\n\nparser = argparse.ArgumentParser()\nparser.add_argument('--model', type=int, default=101)\nparser.add_argument('--cam_id', type=int, default=0)\nparser.add_argument('--cam_width', type=int, default=1280)\nparser.add_argument('--... | [
[
"tensorflow.compat.v1.Session"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
aluquecerp/U-Time | [
"a9ed4892da77d165a71dbfef1d069d782c909757"
] | [
"utime/preprocessing/scaling.py"
] | [
"\"\"\"\nFunctions for channel-wise scaling of PSG data\n\nImplements the MultiChannelScaler, which fits and applies scalers from the\nsklearn.preprocessing module individually to channels of a PSG ndarray\n\"\"\"\n\nimport sklearn.preprocessing as preprocessing\nimport numpy as np\n\n\ndef assert_scaler(scaler):\n... | [
[
"numpy.empty_like"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Tinusf/imbalanced-learn | [
"67ea479fc907f52d7d7776b0d722654bfd699fa2"
] | [
"imblearn/under_sampling/_prototype_selection/_random_under_sampler.py"
] | [
"\"\"\"Class to perform random under-sampling.\"\"\"\n\n# Authors: Guillaume Lemaitre <g.lemaitre58@gmail.com>\n# Christos Aridas\n# License: MIT\n\nimport numpy as np\n\nfrom sklearn.utils import check_array\nfrom sklearn.utils import check_consistent_length\nfrom sklearn.utils import check_random_state\n... | [
[
"sklearn.utils._safe_indexing",
"numpy.unique",
"sklearn.utils.check_consistent_length",
"sklearn.utils.check_array",
"numpy.flatnonzero",
"numpy.count_nonzero",
"sklearn.utils.check_random_state",
"numpy.empty"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
kitkatkandybar/RFSoC-Spectrum-Monitoring | [
"11eb7b1d1e27f35aa2161bbc7c8531eed1c8cca5"
] | [
"front_end/stream_callbacks.py"
] | [
"import dash\r\nfrom dash import dcc\r\nfrom dash import html\r\nimport dash_bootstrap_components as dbc\r\nimport orjson\r\nimport time\r\nimport shutil\r\nimport digital_rf\r\n\r\nimport os.path\r\nimport numpy as np\r\n\r\nimport config as cfg\r\n\r\n\r\n##########################################################... | [
[
"numpy.longdouble",
"numpy.arange",
"numpy.uint64",
"numpy.ones"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
tbennun/pytorch | [
"39a2acbd8e7b50b77a728f48f0a3ebb49fd4e982"
] | [
"torch/fx/experimental/fx2trt/converters/acc_ops_converters.py"
] | [
"import math\nimport operator\n\nimport torch.fx.experimental.fx_acc.acc_ops as acc_ops\nimport torch.fx.experimental.fx_acc.acc_utils as acc_utils\nimport numpy as np\nimport tensorrt as trt\nimport torch\nfrom torch.fx.experimental.fx2trt.fx2trt import (\n tensorrt_converter,\n torch_dtype_from_trt,\n ge... | [
[
"torch.fx.experimental.fx2trt.fx2trt.get_dynamic_dims",
"torch.Size",
"torch.fx.experimental.fx_acc.acc_utils.get_field_from_acc_out_ty",
"numpy.ones_like",
"torch.ge",
"torch.Tensor",
"torch.zeros",
"numpy.ascontiguousarray",
"torch.fx.experimental.fx2trt.fx2trt.tensorrt_conve... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ssabhijith/active-learning | [
"02cd16bbefb23e7a77c80c3d1987bf353e60b5f7"
] | [
"utils/utils.py"
] | [
"# Copyright 2017 Google 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... | [
[
"numpy.product",
"numpy.concatenate",
"sklearn.svm.LinearSVC",
"tensorflow.compat.v1.gfile.GFile",
"numpy.where",
"numpy.unique",
"numpy.zeros",
"numpy.delete",
"sklearn.svm.SVC",
"numpy.array",
"sklearn.model_selection.GridSearchCV",
"sklearn.linear_model.LogisticR... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"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",
"1.7",
"0.12",
"1.0",
"0.17",
"1.3",
"1.8"
... |
aelerojas/masksRecognition | [
"001348e608fc4edf7f40ea7e5d55898e150d7eaa"
] | [
"export_tfserving.py"
] | [
"import time\nfrom absl import app, flags, logging\nfrom absl.flags import FLAGS\nimport cv2\nimport numpy as np\nimport tensorflow as tf\nfrom yolov3_tf2.models import (\n YoloV3, YoloV3Tiny\n)\nfrom yolov3_tf2.dataset import transform_images\n\nfrom tensorflow.python.eager import def_function\nfrom tensorflow.... | [
[
"tensorflow.saved_model.save",
"tensorflow.expand_dims",
"tensorflow.saved_model.load"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
SamH3pn3r/bitcoin-prediction | [
"90c7f18f3257ad6f2a8fcaa91f36ea99f77b3f0d"
] | [
"pages/insights.py"
] | [
"import dash\nimport dash_bootstrap_components as dbc\nimport dash_core_components as dcc\nimport dash_html_components as html\nfrom dash.dependencies import Input, Output\n\nfrom app import app\n\nfrom joblib import load\npipeline = load('assets/pipeline.joblib')\n\nimport plotly.graph_objects as go\nimport pandas... | [
[
"pandas.read_csv",
"pandas.to_datetime"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.3",
"1.1",
"1.5",
"1.2"
],
"scipy": [],
"tensorflow": []
}
] |
hunto/mmrazor | [
"e1483b4f4ca69de98130b01a27a6dd7ed44bda4f"
] | [
"mmrazor/datasets/utils.py"
] | [
"from torch.utils.data import random_split\n\n\ndef split_dataset(dataset):\n dset_length = len(dataset)\n\n first_dset_length = dset_length // 2\n second_dset_length = dset_length - first_dset_length\n split_tuple = (first_dset_length, second_dset_length)\n first_dset, second_dset = random_split(dat... | [
[
"torch.utils.data.random_split"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
firiceguo/my-pycuda | [
"5c9691bcc380a1e1ff55615bf3135fcdacb54691"
] | [
"filter.py"
] | [
"'''\nDescription:\n This is the separable filter algorithm of image convolution using CUDA.\n\nUsage:\n $python filter.py\n\nNote:\n When changing the scale of tile, and the width of image,\n please ensure that IMAGE_W >= TILE_W and IMAGE_W % TILE_W == 0,\n or there will be an AssertionError.\n A... | [
[
"numpy.reshape",
"numpy.random.randn",
"numpy.zeros_like"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
tonyreina/neon | [
"bab09ddb4bafd00d8415b831ba6da676a2fd178e",
"bab09ddb4bafd00d8415b831ba6da676a2fd178e"
] | [
"luna16/old_code/LUNA16_inferenceTestingVGG_noBatch.py",
"luna16/old_code/LUNA16_extract_patches.py"
] | [
"#!/usr/bin/env python\n# ----------------------------------------------------------------------------\n# Copyright 2015-2017 Nervana Systems Inc.\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 ... | [
[
"numpy.set_printoptions"
],
[
"numpy.max",
"pandas.read_csv",
"numpy.absolute",
"scipy.misc.toimage"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [
"0.13",
"0.14",
"0.15",
"1.0",
... |
MapleNSteel/AckermannControl | [
"bca97ca0900dde416f247a3a1c30fbf7dba51aa6"
] | [
"Controllers/LinearMPC.py"
] | [
"import numpy as np\nimport cvxopt\n\ncvxopt.matrix_repr = cvxopt.printing.matrix_str_default\ncvxopt.printing.options['dformat'] = '%.4f'\ncvxopt.printing.options['width'] = -1\ncvxopt.solvers.options['show_progress'] = False\ncvxopt.solvers.options['maxiters'] = 30\ncvxopt.solvers.options['abstol'] = 1e-08\ncvxop... | [
[
"numpy.eye",
"numpy.linalg.matrix_power",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
MichaelORegan/46887-COMPUTATIONAL-THINKING-WITH-ALGORITHMS-PROJECT | [
"8d699e147fadd4eeb8652195c311a13c2d942a5b"
] | [
"benchmarkmerge.py"
] | [
"# Michael O'Regan 05/May/2019\n# http://interactivepython.org/courselib/static/pythonds/SortSearch/TheMergeSort.html\n\nimport time\nimport statistics\nimport numpy as np # importing numpy as np\n\nnp.random.seed(1) # seeding random on seed 1 so that all ... | [
[
"numpy.random.seed",
"numpy.random.randint"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
TNTtian/Faasm | [
"377f4235063a7834724cc750697d3e0280d4a581"
] | [
"tasks/matrix_data.py"
] | [
"from os.path import join\n\nimport numpy as np\nfrom invoke import task\nfrom numpy import int32\nfrom pyfaasm.config import MatrixConf\nfrom pyfaasm.matrix import random_matrix\nfrom pyfaasm.matrix_data import subdivide_matrix_into_files\n\nfrom tasks.util.matrices import get_matrix_dir, MATRIX_CONF_STATE_KEY, SU... | [
[
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Mohamed0gad/hoggorm | [
"4debdb49a8d1d8858abb783be2ad67ffc96fd3ab"
] | [
"tests/test_pls1.py"
] | [
"# -*- coding: utf-8 -*-\n\"\"\"\nTest whether PLS1 results are as expected.\n\"\"\"\nimport os.path as osp\nimport numpy as np\nimport pytest\nfrom hoggorm import nipalsPLS1 as PLS1\n\n\n# If the following equation is element-wise True, then allclose returns True.\n# absolute(a - b) <= (atol + rtol * absolute(b))\... | [
[
"numpy.array",
"numpy.allclose"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
SirJakesalot/MinecraftObjectRecognition | [
"7b70c9d8cc3bfc729baa072d94b8fc861dc9e579"
] | [
"agents/RecorderAgent.py"
] | [
"import time\nimport os\n# vendors\nimport MalmoPython\nimport cv2\nimport numpy as np\n\nfrom BaseAgent import BaseAgent\n\nclass RecorderAgent(BaseAgent):\n imgCounter = 1\n imgDir = 'imgs/tmp'\n def __init__(self, config):\n BaseAgent.__init__(self, config)\n if not os.path.exists(self.img... | [
[
"numpy.asarray"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
hyoputer/open-unmix-pytorch | [
"ffe568592bb508fcfdf2174553efd2139e61de4c"
] | [
"openunmix/cli.py"
] | [
"from pathlib import Path\nimport torch\nimport torchaudio\nimport json\nimport numpy as np\n\n\nfrom openunmix import utils\nfrom openunmix import predict\nfrom openunmix import data\n\nimport argparse\n\n\ndef separate():\n parser = argparse.ArgumentParser(\n description=\"UMX Inference\",\n add_... | [
[
"torch.device",
"torch.squeeze",
"torch.cuda.is_available",
"torch.tensor"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
jongtaeklee/dsmil-wsi | [
"e637f8295e0bc580e20569586b11ce69a75190c6"
] | [
"train_tcga.py"
] | [
"import torch\nimport torch.nn as nn\nfrom torch.utils.data import DataLoader\nfrom torch.autograd import Variable\nimport torchvision.transforms.functional as VF\nfrom torchvision import transforms\n\nimport sys, argparse, os, copy, itertools, glob, datetime\nimport pandas as pd\nimport numpy as np\nfrom sklearn.u... | [
[
"sklearn.metrics.roc_auc_score",
"torch.sigmoid",
"pandas.read_csv",
"torch.max",
"torch.optim.lr_scheduler.CosineAnnealingLR",
"torch.load",
"numpy.array_equal",
"sklearn.utils.shuffle",
"numpy.squeeze",
"sklearn.metrics.roc_curve",
"torch.nn.BCEWithLogitsLoss",
"n... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
Goschjann/ssltsc | [
"08d6b1bf711bb1c8f19f9bfb66a98d4e423e932e"
] | [
"ssltsc/models/utils.py"
] | [
"\"\"\"Utility functions for submodule 'models'\n\"\"\"\nfrom copy import deepcopy\nimport math\nimport numpy as np\nimport pandas as pd\nimport pdb\nimport torch\n\nfrom sklearn.metrics import log_loss, roc_auc_score, f1_score\nfrom uncertainty_metrics.numpy import ece\n\ndef ema_update(student, teacher, alpha=0.9... | [
[
"sklearn.metrics.roc_auc_score",
"torch.optim.lr_scheduler.LambdaLR",
"numpy.clip",
"numpy.arange",
"sklearn.metrics.log_loss",
"torch.no_grad",
"sklearn.metrics.f1_score",
"numpy.exp",
"numpy.where"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
evgenykurbatov/kb21-hotjup-migration-adv | [
"c346a6af8e0a79e69b619f3988db34e71efe131d"
] | [
"plot_wind.py"
] | [
"# -*- coding: utf-8 -*-\n\nimport sys\nimport numpy as np\nfrom numpy import pi, sqrt, exp, sin, cos, tan, log, log10\n\nimport h5py\n\nimport matplotlib as mpl\nimport matplotlib.pyplot as plt\nfrom matplotlib.collections import PatchCollection\nfrom matplotlib.patches import Rectangle\n\nfrom aux import *\n\n\n\... | [
[
"matplotlib.pyplot.tight_layout",
"numpy.sqrt",
"matplotlib.pyplot.subplots",
"matplotlib.pyplot.savefig",
"numpy.loadtxt",
"matplotlib.rc"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Pratyush2703/DensityPeakCluster | [
"958b4b62cbbc36f8651211a067bb0e065c29004a"
] | [
"cluster.py"
] | [
"#!/usr/bin/env python\n# -*- coding: UTF-8 -*-\n\nimport sys\nimport math\nimport logging\nimport numpy as np\n\nlogger = logging.getLogger(\"dpc_cluster\")\n\n\ndef load_paperdata(distance_f):\n '''\n Load distance from data\n\n Args:\n distance_f : distance file, the format is column1-index 1... | [
[
"numpy.argsort",
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
cgalaz01/acur_mri | [
"3be85e62a3362f9498169edb87c233e4da35ddd8"
] | [
"functions/cataloguing/split.py"
] | [
"import os\nimport re\n\nfrom typing import Any, Dict, Union\nfrom pathlib import Path\n\nimport pydicom\n\nimport plotly.graph_objects as go\n\n\nclass MetadataSplit():\n \n __dicom_tags = ['MRAcquisitionType', 'SliceThickness', 'RepetitionTime', 'EchoTime',\n 'NumberOfAverages', 'SpacingB... | [
[
"matplotlib.pyplot.xlabel",
"matplotlib.pyplot.ylabel",
"matplotlib.pyplot.title",
"matplotlib.pyplot.figure"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
scc-usc/ReCOVER-COVID-19 | [
"29d5872d5da0aa3621c520f1edbac510ae99b8df"
] | [
"results/format-covid-forecast/format_data_county_case.py"
] | [
"import math\nimport datetime\nimport pytz\nimport pandas as pd\nimport csv\nimport urllib.request\nimport io\n\nFORECAST_DATE = datetime.datetime.now(pytz.timezone('US/Pacific'))\nFORECAST_DATE = FORECAST_DATE.replace(tzinfo=None)\nfor i in range(0, 8):\n if FORECAST_DATE.weekday() == 6:\n break\n FOR... | [
[
"pandas.read_csv"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
smallporridge/Socialformer | [
"a2e26e2c4d0fc6e355e46f3a1098f0bfa23ce0d6"
] | [
"dataprocess/subgraph.py"
] | [
"import numpy as np\nfrom torch import index_put_\n\n'''\nremove subgraph_edges\n'''\ndef get_subgraph_edge(psg,graph_matrix,subgraph_num=8,max_subgraph_node=128):\n '''\n Args:\n psg: [list] a list consisting of token_ids representing the original long passage\n graph_matrix: [numpy.ndarray] th... | [
[
"numpy.sum"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
SymbiFlow/prjuray | [
"bd446a50d94498829a25170ed342c32944f1d807"
] | [
"utils/spec/rclk_int_8.py"
] | [
"#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\n#\n# Copyright (C) 2020 The Project U-Ray Authors.\n#\n# Use of this source code is governed by a ISC-style\n# license that can be found in the LICENSE file or at\n# https://opensource.org/licenses/ISC\n#\n# SPDX-License-Identifier: ISC\n\nimport numpy as np\n\nfro... | [
[
"numpy.random.shuffle",
"numpy.random.randint",
"numpy.random.seed",
"numpy.random.choice"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
boostcampaitech2/model-optimization-level3-nlp-02 | [
"bcc2da9cbb7bf41f8635dba6a63af87c9f9dd181",
"bcc2da9cbb7bf41f8635dba6a63af87c9f9dd181"
] | [
"train_student.py",
"src/modules/mbconv.py"
] | [
"\"\"\"Baseline train\n- Author: Junghoon Kim\n- Contact: placidus36@gmail.com\n\"\"\"\n\nimport argparse\nimport os\nfrom datetime import datetime\nfrom typing import Any, Dict, Tuple, Union\n\nimport timm\n\nimport torch\nimport torch.nn as nn\nimport torch.optim as optim\nimport yaml\n\nfrom src.dataloader impor... | [
[
"numpy.random.seed",
"torch.load",
"torch.cuda.manual_seed",
"torch.manual_seed",
"torch.cuda.amp.GradScaler",
"torch.cuda.manual_seed_all",
"torch.cuda.is_available",
"torch.device"
],
[
"torch.nn.Sequential",
"torch.sigmoid",
"torch.nn.Conv2d",
"torch.nn.Sigmo... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
riteshkumarumassedu/BERT-with-SOP | [
"5fa5d34b1fc919ca2ddac2112d74d54e0dbd4b77"
] | [
"pretrain_SOP2.py"
] | [
"\"\"\"\nPretrain transformer with Masked LM and and different SOP variants\n\"\"\"\nfrom random import randint, shuffle\nfrom random import random as rand\n\nimport fire\nimport torch\nimport torch.nn as nn\nfrom tensorboardX import SummaryWriter\n\nimport models\nimport optim\nimport tokenization\nimport train\nf... | [
[
"torch.nn.CrossEntropyLoss",
"torch.zeros",
"torch.nn.Tanh",
"torch.tensor",
"torch.nn.Linear",
"torch.gather"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
iross/blackstack | [
"4e44679f889d86626cd7cd263a0b770e1d5e9e64"
] | [
"helpers.py"
] | [
"import math\nimport numpy as np\nimport itertools\nfrom PIL import Image\nfrom shapely.geometry import Polygon\nfrom shapely.ops import cascaded_union\n\nimport matplotlib.pyplot as plt\nimport matplotlib.patches as patches\n\nfrom difflib import SequenceMatcher\nfrom bs4 import BeautifulSoup\n\nimport classifier\... | [
[
"numpy.nanmedian",
"numpy.nanmean",
"numpy.nanstd",
"numpy.zeros",
"numpy.sum"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Karikari1234/Graph-Markov-Network | [
"8e29e58c8fe7879e53605485615d09356b990a85"
] | [
"Python Scripts/Exp_baseline.py"
] | [
"#!/usr/bin/env python\n# coding: utf-8\n\n\nimport torch.utils.data as utils\nimport torch.nn.functional as F\nimport torch\nimport torch.nn as nn\nfrom torch.autograd import Variable\nfrom torch.nn.parameter import Parameter\nimport math\nimport numpy as np\nimport pandas as pd\nimport time\nimport pickle\nimport... | [
[
"pandas.read_hdf",
"torch.cuda.set_device",
"numpy.random.seed",
"torch.cuda.is_available",
"torch.device",
"numpy.load",
"pandas.read_pickle",
"numpy.where"
]
] | [
{
"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": []
}
] |
olebole/specutils | [
"566de5cec00bd1198f1275ce74b1e261b61813af"
] | [
"specutils/analysis/uncertainty.py"
] | [
"\"\"\"\nA module for analysis tools dealing with uncertainties or error analysis in\nspectra.\n\"\"\"\n\nimport numpy as np\nfrom ..spectra import SpectralRegion\nfrom ..manipulation import extract_region\n\n__all__ = ['snr', 'snr_derived']\n\n\ndef snr(spectrum, region=None):\n \"\"\"\n Calculate the mean S... | [
[
"numpy.median",
"numpy.mean",
"numpy.abs"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
raphaelsulzer/occupancy_networks | [
"aacc9e42e663b9c9ad0352a511c38cb1f705ec51"
] | [
"external/mesh-fusion/2_fusion.py"
] | [
"import math\nimport numpy as np\nimport os\nfrom scipy import ndimage\nfrom scipy.interpolate import RegularGridInterpolator as rgi\nimport common\nimport argparse\nimport ntpath\n\n# Import shipped libraries.\nimport librender\nimport libmcubes\nfrom multiprocessing import Pool\n\nuse_gpu = False\nif use_gpu:\n ... | [
[
"numpy.unravel_index",
"numpy.savez",
"numpy.pad",
"numpy.linspace",
"numpy.abs",
"numpy.random.choice",
"numpy.arange",
"scipy.interpolate.RegularGridInterpolator",
"numpy.stack",
"numpy.ones",
"numpy.random.rand",
"scipy.ndimage.morphology.grey_erosion",
"nump... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [
"0.14",
"1.6",
"0.15",
"1.4",
"1.3",
"0.19",
"1.5",
"0.18",
"1.2",
"1.7",
"1.0",
"0.17",
"0.16"
],
"tensorflow": []
}
] |
ridicolos/featuretools | [
"bbad3f7392b203b7b9c250a93465052e7fc06bbc",
"bbad3f7392b203b7b9c250a93465052e7fc06bbc",
"bbad3f7392b203b7b9c250a93465052e7fc06bbc"
] | [
"featuretools/tests/primitive_tests/test_agg_feats.py",
"featuretools/tests/computational_backend/test_feature_set_calculator.py",
"featuretools/tests/entityset_tests/test_dask_es.py"
] | [
"from datetime import datetime\nfrom inspect import isclass\nfrom math import isnan\n\nimport numpy as np\nimport pandas as pd\nimport pytest\nfrom woodwork.column_schema import ColumnSchema\nfrom woodwork.logical_types import Datetime\n\nimport featuretools as ft\nfrom featuretools.entityset.relationship import Re... | [
[
"pandas.DateOffset",
"pandas.Series",
"pandas.isnull",
"pandas.Timestamp",
"numpy.nan_to_num",
"pandas.DataFrame",
"pandas.DatetimeIndex",
"numpy.append",
"numpy.array"
],
[
"pandas.testing.assert_series_equal",
"pandas.Series",
"pandas.isnull",
"pandas.Time... | [
{
"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... |
adam-coogan/swyft | [
"c54bdd9f77ddf02fda857e26640df012cbe545fc"
] | [
"swyft/utils/array.py"
] | [
"from typing import Optional\n\nimport numpy as np\nimport torch\n\nfrom swyft.types import Array, Device\n\n\ndef dict_to_tensor(d, device=\"cpu\", non_blocking=False, indices=slice(0, None)):\n return {\n k: array_to_tensor(v[indices]).float().to(device, non_blocking=non_blocking)\n for k, v in d... | [
[
"numpy.asarray",
"torch.isfinite",
"torch.from_numpy",
"numpy.isfinite"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
gianlucacovini/opt4ds | [
"42904fd56c18a83fd5ff6f068bbd20b055a40734"
] | [
"aa2020/python/plot_shortest_path_tree.py"
] | [
"# -*- coding: utf-8 -*-\n\"\"\"\nCreated on Thu Mar 26 11:14:53 2020\n\n@author: Gualandi\n\"\"\"\n\nimport networkx as nx\nimport matplotlib.pyplot as plt\n\nLs = [('a', 'b', 5), ('a', 'c', 3), ('a', 'd', 3), ('b', 'c', 2), \n ('b', 'd', 5), ('c', 'e', 2), ('c', 'd', 3), ('d', 'e', 2), \n ('d', 'f', 3),... | [
[
"matplotlib.pyplot.show",
"matplotlib.pyplot.get_cmap",
"matplotlib.pyplot.savefig"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
jayhombal/forest-biomass-prediction | [
"f48264a7696896899c9745de1b82e85130b634ae"
] | [
"src/data/aerial_data_preprocess.py"
] | [
"import numpy as np\nimport pandas as pd\nimport uuid\n\nclass AerialDataProcessor:\n \"\"\"\n Class for reading, processing, and writing data from the UCI\n Condition monitoring of hydraulic systems` dataset.\n \"\"\"\n\n\n def __init__(self):\n \n self.aerial_data_usecols= ['left', 'b... | [
[
"pandas.read_csv",
"pandas.qcut",
"pandas.DataFrame"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
csm-kr/s2cnn | [
"09652af9811357c4bf6f7a6d3e912a06d7826f70"
] | [
"examples/sun360/sun360_dataset.py"
] | [
"from torch.utils.data import DataLoader, Dataset\nimport torch.nn as nn\nimport os\nimport glob\nimport torch\nimport numpy as np\nfrom examples.mnist.gendata import get_projection_grid, project_2d_on_sphere_sun360, rand_rotation_matrix, rotate_grid\nimport cv2\nfrom utils import rotate_map_given_R, calculate_Rmat... | [
[
"torch.ones",
"numpy.random.seed",
"numpy.random.choice",
"torch.zeros",
"torch.utils.data.DataLoader",
"torch.FloatTensor",
"numpy.transpose"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
yanyuliren/tt | [
"a6885a4128a4992ef8a905d27790efa67023063f"
] | [
"network2.py"
] | [
"\"\"\"network2.py\r\n~~~~~~~~~~~~~~\r\n\r\nImplementing the stochastic gradient descent learning algorithm for a \r\nfeedforward neural network.\r\n\r\nImprovements include the addition of the cross-entropy cost function,\r\nregularization, and better initialization of network weights. Focused on making the code ... | [
[
"numpy.dot",
"numpy.log",
"numpy.sqrt",
"numpy.linalg.norm",
"numpy.argmax",
"numpy.random.randn",
"numpy.array",
"numpy.exp",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
MarvinT/pyoperant | [
"f5837cfd48e279023fe5e82a60d659d7171cb4b9"
] | [
"pyoperant/queues.py"
] | [
"import random\nfrom pyoperant.utils import rand_from_log_shape_dist\nimport cPickle as pickle\nimport numpy as np\n\ndef random_queue(conditions,tr_max=100,weights=None):\n \"\"\" generator which randomly samples conditions\n\n Args:\n conditions (list): The conditions to sample from. \n weights... | [
[
"numpy.ceil"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
tomsaleeba/natcap-invest-docker-flask | [
"1ef3e58f6af58d1783f6c0b8c80377e645923204"
] | [
"natcap_invest_docker_flask/natcap_wrapper.py"
] | [
"import time\nimport csv\nimport os\nfrom copy import deepcopy\nimport shutil\nimport logging\nimport base64\n# Note for eventlet: DO NOT call eventlet.monkey_patch(), it doesn't\n# work with multiprocessing\nimport multiprocessing as mp\nimport uuid\n\nimport natcap.invest.pollination\nimport shapefile\nimport sub... | [
[
"numpy.printoptions"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
piroshi303/s2d-bot | [
"7a8889ce6b88e7d3004e61459a43749381ab58c9"
] | [
"s2d-bot.py"
] | [
"import discord\nimport asyncio\nimport yaml\nimport pandas as pd\nimport urllib.request, urllib.error\nfrom xml.sax.saxutils import unescape\nfrom bs4 import BeautifulSoup\n\nclient = discord.Client()\n\n@client.event\nasync def on_ready():\n print('Logged in as' + client.user.name)\n print(client.user.id)\n... | [
[
"pandas.read_csv"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
innat/vit-tensorflow | [
"2f0f009651295c054aa84ed45f4dace35e7ea442",
"2f0f009651295c054aa84ed45f4dace35e7ea442"
] | [
"vit_tensorflow/mobile_vit.py",
"vit_tensorflow/vit.py"
] | [
"import tensorflow as tf\nfrom tensorflow.keras import Model\nfrom tensorflow.keras.layers import Layer\nfrom tensorflow.keras import Sequential\nimport tensorflow.keras.layers as nn\n\nfrom einops import rearrange\nfrom einops.layers.tensorflow import Reduce\n\n\ndef gelu(x, approximate=False):\n if approximate... | [
[
"tensorflow.keras.layers.LayerNormalization",
"tensorflow.matmul",
"tensorflow.concat",
"tensorflow.transpose",
"tensorflow.pow",
"tensorflow.keras.activations.swish",
"tensorflow.keras.layers.Dense",
"tensorflow.cast",
"tensorflow.identity",
"tensorflow.keras.Sequential",
... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"2.7",
"2.2",
"2.3",
"2.4",
"2.5",
"2.6"
]
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10",
"2.7",
"... |
YourRoyalLinus/dataset-integration | [
"de75c409347a94de729905903ae4a2ac9daeaa31"
] | [
"dataset_integration/calculations.py"
] | [
"from _collections_abc import Sequence\nfrom numpy import ndarray\nfrom scipy.integrate import cumulative_trapezoid\n\n\ndef strictly_increasing(s: Sequence):\n \"\"\"Returns true if sequence s is monotonically increasing\"\"\"\n return all(x < y for x, y in zip(s, s[1:]))\n\ndef strictly_decreasing(s: Sequen... | [
[
"scipy.integrate.cumulative_trapezoid"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [
"1.6",
"1.10",
"1.9",
"1.7",
"1.8"
],
"tensorflow": []
}
] |
fractalphile/michi | [
"449c784929e84b9d47728b8af4db8db2e292fb67"
] | [
"michi/geocoder/geocoder.py"
] | [
"import itertools\nimport pickle\nimport re\nfrom warnings import warn\n\nimport geopandas as gp\nfrom geosupport import Geosupport, GeosupportError\nimport networkx as nx\nimport numpy as np\nimport pandas as pd\nfrom shapely.geometry import LineString, Point\nfrom shapely.ops import transform\nfrom rtree import i... | [
[
"pandas.DataFrame.from_records",
"pandas.concat",
"numpy.log",
"pandas.isnull"
]
] | [
{
"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": []
}
] |
chrdiller/mitsuba-visualize | [
"b6dfa8b23638b6cb805aa28107f718aea3a9462a"
] | [
"math_util/util.py"
] | [
"\nimport numpy as np\n\n\ndef find_closest_orthogonal_matrix(A: np.ndarray) -> np.ndarray:\n \"\"\"\n Find closest orthogonal matrix to *A* using iterative method.\n Based on the code from REMOVE_SOURCE_LEAKAGE function from OSL Matlab package.\n Reading:\n Colclough GL et al., A symmetric mult... | [
[
"numpy.dot",
"numpy.linalg.svd",
"numpy.finfo",
"numpy.max",
"numpy.zeros",
"numpy.sum"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
jlauman/data_engineering_project_03 | [
"722c0f5226ed29c00d6b33e64da5982fe0be69e0"
] | [
"rs_etl.py"
] | [
"import configparser, os, glob, csv, json, hashlib, time\nimport pandas as pd\nimport psycopg2\nfrom pprint import pprint\nfrom rs_sql_queries import staging_events_insert, staging_songs_insert\nfrom rs_sql_queries import insert_table_queries\n\nimport boto3\nfrom botocore import UNSIGNED\nfrom botocore.config impo... | [
[
"pandas.to_datetime",
"pandas.read_json"
]
] | [
{
"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": []
}
] |
fcole90/demotivational-policy-descent | [
"9193487587c03530bf5a962fda7b6ac5a4ceaae4"
] | [
"demotivational_policy_descent/agents/actor_critic_old.py"
] | [
"import logging\nimport torch.nn.functional as F\nfrom torch.distributions import Normal\nimport numpy as np\nimport torch\n\nfrom demotivational_policy_descent.agents.agent_interface import AgentInterface\nfrom demotivational_policy_descent.utils.utils import discount_rewards, softmax_sample\n\nclass Policy(torch.... | [
[
"torch.mean",
"torch.sigmoid",
"torch.nn.init.uniform_",
"torch.Tensor",
"torch.sum",
"torch.from_numpy",
"torch.exp",
"torch.nn.Linear",
"torch.nn.functional.relu",
"torch.std",
"numpy.argmax",
"torch.nn.init.zeros_",
"torch.stack",
"numpy.zeros",
"torc... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ssakhavi/pytorch-lightning | [
"fd7814d287a86046bdda0367e02085a8b709fe33"
] | [
"tests/models/test_cpu.py"
] | [
"import os\nimport platform\nfrom collections import namedtuple\n\nimport pytest\nimport torch\nfrom packaging.version import parse as version_parse\n\nimport tests.base.utils as tutils\nfrom pytorch_lightning import Trainer\nfrom pytorch_lightning.callbacks import EarlyStopping\nfrom tests.base import EvalModelTem... | [
[
"torch.eq",
"torch.rand",
"torch.cuda.is_available",
"torch.tensor"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
FitzLu/drl-snake-ai | [
"0c0f817fd91ee7061b99f01fed429598252fa54f"
] | [
"train_with_tensorflow.py"
] | [
"import collections\nimport numpy as np\nfrom env.game import SnakeGame\nfrom agent.brain import Agent\n\n\ndef main():\n last_frames_num = 4\n actions_num = 3\n exploration_rate = 1.0\n min_exploration_rate = 0.1\n episode_num = 10000\n exploration_decay = ((exploration_rate - min_exploration_rat... | [
[
"numpy.reshape",
"numpy.array",
"numpy.random.random",
"numpy.random.randint"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
dhingratul/Data-Analysis | [
"8aa9695375b143fbbcb1355e9ade7a57ab68592d"
] | [
"Lesson-3/L3_pd_shift.py"
] | [
"#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\n\"\"\"\nCreated on Mon Jun 19 19:13:02 2017\n\n@author: dhingratul\n\"\"\"\n\nimport pandas as pd\n\n# --- Quiz ---\n# Cumulative entries and exits for one station for a few hours.\nentries_and_exits = pd.DataFrame({\n 'ENTRIESn': [3144312, 3144335, 3144353, 3144... | [
[
"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": []
}
] |
ucas-vg/PointTinyBenchmark | [
"63fc417c40ed9484f8d7bb6a2212162c9e98b711"
] | [
"TOV_mmdetection/mmdet/core/bbox/assigners/hungarian_assigner.py"
] | [
"import torch\n\nfrom ..builder import BBOX_ASSIGNERS\nfrom ..match_costs import build_match_cost\nfrom ..transforms import bbox_cxcywh_to_xyxy\nfrom .assign_result import AssignResult\nfrom .base_assigner import BaseAssigner\n\ntry:\n from scipy.optimize import linear_sum_assignment\nexcept ImportError:\n li... | [
[
"scipy.optimize.linear_sum_assignment",
"torch.from_numpy",
"torch.nonzero"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [
"1.6",
"1.4",
"0.19",
"1.5",
"0.18",
"1.2",
"1.7",
"1.0",
"0.17",
"1.3",
"1.8"
],
"tensorflow": []
}
] |
pat4life360/LEAP-Camera-Face-Tracker- | [
"be31183f9047f432ae400888aef1e0b0c58ff72b"
] | [
"build/PersonFollower.py"
] | [
"#Python Script for Object-Face Servo Tracking\n#Import necesasry libraries\nfrom picamera.array import PiRGBArray\n\nfrom picamera import PiCamera\nimport time\nimport cv2\nimport sys\nimport numpy as np\nimport math\nfrom adafruit_servokit import ServoKit\n\n#Initialize Servos on PCA9685 driver\nkit = ServoKit(ch... | [
[
"numpy.array",
"numpy.sqrt"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
CMURoboTouch/Taxim | [
"d067cc63892fab8de736a1d3f449d01368b32205"
] | [
"MarkerMotionSimulation/compose/dataLoader.py"
] | [
"import matplotlib.pyplot as plt\nimport numpy as np\nimport os\nfrom os import path as osp\nimport cv2\nfrom scipy import interpolate\n\nimport sys\nsys.path.append(\"../..\")\nimport Basics.sensorParams as psp\n\ndef fill_blank(img):\n \"\"\"\n fill the zero value holes with interpolation\n \"\"\"\n i... | [
[
"numpy.rot90",
"numpy.meshgrid",
"numpy.min",
"numpy.arange",
"numpy.max",
"numpy.mean",
"numpy.ma.masked_where",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
gvdeynde/deepburn | [
"1af3d62ec0e70b82250bce31342326adcf561002"
] | [
"tests/tools/test_burnup_problem.py"
] | [
"import pytest\n\nfrom numpy import allclose\nfrom scipy.sparse import dok_matrix\nfrom deepburn.isotope import Isotope\nfrom deepburn.burnup_problem import IsotopicComposition, Transitions, BUP, Polonium\n\n\ndef test_isotopic_composition_init():\n ics = IsotopicComposition()\n assert ics._ics == {}\n\n\ndef... | [
[
"scipy.sparse.dok_matrix",
"numpy.allclose"
]
] | [
{
"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"... |
EthanChen1234/NLP | [
"16c4e07abba4f8349b4584a8e6d803525e78515c"
] | [
"dssm/siamese_rnn.py"
] | [
"# coding=utf8\n\"\"\"\npython=3.5\nTensorFlow=1.2.1\n\"\"\"\n\nimport time\nimport numpy as np\nimport tensorflow as tf\nimport data_input\nfrom config import Config\nimport random\n\nrandom.seed(9102)\n\nstart = time.time()\n# 是否加BN层\nnorm, epsilon = False, 0.001\n\n# TRIGRAM_D = 21128\nTRIGRAM_D = 100\n# query b... | [
[
"tensorflow.get_variable",
"tensorflow.concat",
"tensorflow.contrib.rnn.GRUCell",
"tensorflow.reduce_sum",
"tensorflow.nn.bidirectional_dynamic_rnn",
"tensorflow.nn.sigmoid_cross_entropy_with_logits",
"tensorflow.train.AdamOptimizer",
"tensorflow.summary.scalar",
"tensorflow.co... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
karlnapf/kernel_hmc | [
"8ab93ae0470cc5916d5349b40bae7f91075bc385"
] | [
"kernel_hmc/proposals/base.py"
] | [
"from kernel_hmc.tools.assertions import assert_implements_log_pdf_and_grad\nfrom kernel_hmc.tools.log import Log\nimport numpy as np\n\n\nlogger = Log.get_logger()\n\ndef standard_sqrt_schedule(t):\n return 1. / np.sqrt(t + 1)\n\nclass ProposalBase(object):\n def __init__(self, target, D, step_size, adaptati... | [
[
"numpy.log",
"numpy.sqrt",
"numpy.arange",
"numpy.sort",
"numpy.all",
"numpy.exp"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
brendenpetersen/deep-symbolic-optimization | [
"8724839dab910022e24d03debdf564236683474b",
"8724839dab910022e24d03debdf564236683474b"
] | [
"dso/dso/tf_state_manager.py",
"dso/dso/controller.py"
] | [
"from abc import ABC, abstractmethod\n\nimport tensorflow as tf\n\nfrom dso.program import Program\n\n\nclass StateManager(ABC):\n \"\"\"\n An interface for handling the tf.Tensor inputs to the Controller.\n \"\"\"\n\n def setup_manager(self, controller):\n \"\"\"\n Function called inside ... | [
[
"tensorflow.get_variable",
"tensorflow.concat",
"tensorflow.unstack",
"tensorflow.random_uniform_initializer",
"tensorflow.cast",
"tensorflow.expand_dims",
"tensorflow.one_hot",
"tensorflow.variable_scope",
"tensorflow.nn.embedding_lookup"
],
[
"tensorflow.nn.raw_rnn",
... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
chiptrontech/WiredQTv1.0 | [
"760948bb736867db4e772031b23ed9151e0364b9"
] | [
"WiredQT/examples/BySomeBody/flask/wired_module.py"
] | [
"import time\nimport datetime\nimport os\nfrom PyQt5.QtWidgets import *\nfrom PyQt5.QtCore import *\nfrom PyQt5 import QtCore, QtWidgets\nfrom PyQt5.QtGui import * \nfrom PyQt5.Qsci import QsciScintilla, QsciLexerPython\nfrom copy import deepcopy\ntry:\n\timport RPi.GPIO as GPIO\n\tGPIO.setmode(GPIO.BCM)\n\tGPIO.se... | [
[
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
qgoestch/sinecity_testcases | [
"ec04ba707ff69b5c1b4b42e56e522855a2f34a65"
] | [
"main/case3_pe_ground_imp.py"
] | [
"# -*- coding: utf-8 -*-\n##\n# \\file case3_pe_ground_imp.py\n# \\title Study of an acoustic impulse reflected by an impedance ground.\n# \\author Pierre Chobeau\n# \\version 0.1\n# \\license BSD 3-Clause License\n# \\inst UMRAE (Ifsttar Nantes), LAUM (Le Mans Université)\n# \\date 2017, 21 Nov.... | [
[
"numpy.log10"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
psFournier/robo-gym | [
"0e67a36c0cbeac885c53b92de8f3f1f13e286c9a"
] | [
"tests/robo-gym/envs/ur/test_ur_ee_positioning.py"
] | [
"import gym\nimport robo_gym\nimport math\nimport numpy as np \nimport pytest\n\nur_models = [pytest.param('ur3', marks=pytest.mark.nightly), \\\n pytest.param('ur3e', marks=pytest.mark.nightly), \\\n pytest.param('ur5', marks=pytest.mark.commit), \\\n pytest.param('ur5e', marks=... | [
[
"numpy.isclose"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
haohy/deepts_torch | [
"166cb0ac2ea1d89d1196a33f40caf89c3f2c23c5"
] | [
"unittests/layers/test_interaction.py"
] | [
"import pytest\nimport os, sys\nsys.path.insert(0, os.path.abspath('..'))\nsys.path.insert(1, os.getcwd())\nos.environ['TF_CPP_MIN_LOG_LEVEL'] = '3'\n\nimport tensorflow as tf\n\nfrom deepts.layers import AttentionBlock, TemporalBlock, TemporalConvNet,TCN\nfrom unittests.config import SAMPLE_SIZE, BATCH_SIZE, N_BAC... | [
[
"tensorflow.random.uniform",
"tensorflow.random.normal",
"tensorflow.config.list_physical_devices",
"tensorflow.config.set_visible_devices"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
alialamiidrissi/pinkfish | [
"c34920d970281b60ae4d46d6c52af13f6b3761f0"
] | [
"examples/240.double-7s-portfolio/strategy.py"
] | [
"\"\"\"\nThe double-7s-portfolio stategy.\n\nThis is double-7s strategy applied to a portfolio.\nThe simple double 7's strategy was revealed in the book\n'Short Term Strategies that Work: A Quantified Guide to Trading Stocks\nand ETFs', by Larry Connors and Cesar Alvarez. It's a mean reversion\nstrategy looking to ... | [
[
"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": []
}
] |
alchemistlee/bert | [
"8837f10cad4317cfd8a792a1c954e15f0dc4b791"
] | [
"spear/multi_lable_classifier_v1.py"
] | [
"# coding=utf-8\n\"\"\"BERT finetuning runner.\"\"\"\n\n# @time : 2019/5/17 19:01\n# @author : alchemistlee\n# @fileName: multi_lable_classifier_v1.py\n# @abstract:\n\nfrom __future__ import absolute_import\nfrom __future__ import division\nfrom __future__ import print_function\n\nimport collections\nimport csv... | [
[
"tensorflow.contrib.cluster_resolver.TPUClusterResolver",
"tensorflow.metrics.accuracy",
"tensorflow.FixedLenFeature",
"tensorflow.nn.log_softmax",
"tensorflow.reduce_sum",
"tensorflow.gfile.GFile",
"tensorflow.cast",
"tensorflow.train.init_from_checkpoint",
"tensorflow.gfile.M... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10",
"1.12",
"1.4",
"1.13",
"1.5",
"1.7",
"0.12",
"1.0",
"1.2"
]
}
] |
HudZah/AutoDrawer | [
"e23e8c012c8000197f6fd34ee8bb7f14eb04e7f5"
] | [
"AutoDrawer/mouseAutomater.py"
] | [
"import numpy as np\r\nimport pyautogui\r\nimport time\r\nimport os\r\nfrom PIL import Image, ImageFilter, ImageOps\r\n\r\nclass MouseAutomater(object):\r\n\r\n pyautogui.PAUSE = 0.00\r\n pyautogui.FAILSAFE = True\r\n\r\n def openPaint():\r\n openPain = input(\"Would you like to open paint? (yes to ... | [
[
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ResearchSoftwareInstitute/MyHPOM | [
"2d48fe5ac8d21173b1685eb33059bb391fe24414"
] | [
"hs_file_types/models/netcdf.py"
] | [
"import os\nimport shutil\nimport logging\nimport re\n\nfrom functools import partial, wraps\nimport netCDF4\nimport numpy as np\n\nfrom django.db import models, transaction\nfrom django.core.exceptions import ValidationError\nfrom django.core.files.uploadedfile import UploadedFile\nfrom django.template import Temp... | [
[
"numpy.fromstring",
"numpy.dtype"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
RichardScottOZ/uncover-ml | [
"05faede0efa989997f9eabaf18c45267011eb861"
] | [
"uncoverml/scripts/gridsearch_cli.py"
] | [
"\"\"\"\nRun the various machine learning parameter optimisation using\nscikit-learn GridSearchCv.\n\nAvailable scorers:\n Regression:\n 'r2', 'expvar', 'smse', 'lins_ccc'\n Classification:\n 'accuracy'\n Classification with probability:\n 'log_loss', 'auc'\n\nNot yet implemented:\n ... | [
[
"sklearn.model_selection.GridSearchCV",
"sklearn.pipeline.Pipeline",
"pandas.DataFrame.from_dict",
"sklearn.gaussian_process.kernels.WhiteKernel",
"sklearn.decomposition.PCA"
]
] | [
{
"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": []
}
] |
Guangyi-Zhang/eiv-treatment-response | [
"66ce76c52a3c05cfac681455c1ce9ae507614270"
] | [
"inducingpolicy.py"
] | [
"import numpy as np\nimport pymc3 as pm\n\n\ndef inducing_policy3(n_inducing_points, t, y, tx, bwin=60, awin=180):\n '''\n uniform excluding the regions of treatment\n '''\n idx_t = t > -1 # all True\n for tx_ in tx:\n idx_t &= (t > tx_+awin) | (t < tx_-bwin)\n t_valid = t[idx_t]\n\n idx... | [
[
"numpy.array",
"numpy.stack"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
AMOLFResonantNanophotonics/CPA | [
"da665fa0fe3c90b1fcd87236e018a44f3fe8b2e0"
] | [
"Scripts_simulate_data/simulate_qdot.py"
] | [
"'''\nFunction that simulates photon counting data with the following characteristics\n- The data is distributed randomly over two detector channels\n- The data is assumed generated by a pulsed laser excitation\n- The emitter itself perfectly antibunches, the two detectors have independent noise\n- The data is spe... | [
[
"numpy.logical_not",
"numpy.random.random",
"numpy.random.exponential",
"numpy.stack",
"numpy.concatenate",
"numpy.int64",
"numpy.diff",
"numpy.insert",
"numpy.random.rand",
"numpy.zeros"
]
] | [
{
"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.