repo_name stringlengths 6 130 | hexsha list | file_path list | code list | apis list | possible_versions list |
|---|---|---|---|---|---|
daiquocnguyen/Walk-Transformer | [
"dc234811dc61bb4d1df7e2d0960be776e2a2b2ac",
"dc234811dc61bb4d1df7e2d0960be776e2a2b2ac"
] | [
"tf_impl/node2vec.py",
"tf_impl/train_SANNE.py"
] | [
"import numpy as np\nimport networkx as nx\nimport random\n\n'''This file is taken from https://github.com/aditya-grover/node2vec/blob/master/src/node2vec.py'''\n\nclass Graph():\n def __init__(self, nx_G, is_directed, p, q):\n self.G = nx_G\n self.is_directed = is_directed\n self.p = p\n ... | [
[
"numpy.zeros",
"numpy.random.rand"
],
[
"tensorflow.train.global_step",
"tensorflow.Graph",
"numpy.random.seed",
"tensorflow.Variable",
"numpy.random.choice",
"tensorflow.ConfigProto",
"tensorflow.global_variables_initializer",
"numpy.shape",
"tensorflow.Session",
... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
hust-wuwechao/mxnetv2 | [
"81528c9908b6ae00adcbe3936ea9cca7967ce814"
] | [
"3rdparty/tvm/nnvm/tests/python/frontend/darknet/test_forward.py"
] | [
"\"\"\"\nCompile Darknet Models\n=====================\nThis article is a test script to test darknet models with NNVM.\nAll the required models and libraries will be downloaded from the internet\nby the script.\n\"\"\"\nimport os\nimport requests\nimport numpy as np\nfrom nnvm import frontend\nfrom nnvm.testing.da... | [
[
"numpy.zeros",
"numpy.random.rand",
"numpy.empty",
"numpy.testing.assert_allclose"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ElasticDuckCode/OpenPCDet | [
"616f3baf05ba81bdf6461c6b814079a81b55ae68"
] | [
"pcdet/datasets/waymo/waymo_dataset.py"
] | [
"# OpenPCDet PyTorch Dataloader and Evaluation Tools for Waymo Open Dataset\n# Reference https://github.com/open-mmlab/OpenPCDet\n# Written by Shaoshuai Shi, Chaoxu Guo\n# All Rights Reserved 2019-2020.\n\nimport os\nimport pickle\nimport copy\nimport numpy as np\nimport torch\nimport multiprocessing\nfrom tqdm imp... | [
[
"torch.from_numpy",
"numpy.load",
"numpy.tanh",
"numpy.array",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
mark-koren/garage | [
"a5feda84d8a226225ff6148542b4e53ff4bd0fb5"
] | [
"garage/tf/distributions/diagonal_gaussian.py"
] | [
"import numpy as np\nimport tensorflow as tf\n\nfrom garage.tf.distributions.base import Distribution\n\n\nclass DiagonalGaussian(Distribution):\n def __init__(self, dim, name=\"DiagonalGaussian\"):\n self._dim = dim\n self._name = name\n\n @property\n def dim(self):\n return self._dim... | [
[
"numpy.square",
"numpy.log",
"numpy.sqrt",
"tensorflow.reduce_sum",
"tensorflow.exp",
"numpy.random.normal",
"tensorflow.name_scope",
"tensorflow.square",
"numpy.exp",
"numpy.sum"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10",
"1.12",
"1.4",
"1.5",
"1.7",
"0.12",
"1.0",
"1.2"
]
}
] |
NVIDIA-AI-IOT/ros2_torch_trt | [
"ea65bc045761cc7732fbb548369fa16219050e71"
] | [
"live_classifier/live_classifier/live_classifier_helper.py"
] | [
"'''Copyright (c) 2019-2020, NVIDIA CORPORATION. All rights reserved.\n\nPermission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, c... | [
[
"torch.nn.functional.softmax",
"torch.max",
"numpy.asarray",
"numpy.reshape",
"torch.unsqueeze"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
liushengzhong1023/multihead-siamese-nets | [
"ccb544d5a8adefa41743ef7948aeb5f20a74507e"
] | [
"models/base_model.py"
] | [
"import tensorflow as tf\n\nfrom layers.basics import optimize\nfrom layers import losses\n\nclass BaseSiameseNet:\n \n def __init__(\n self,\n max_sequence_len,\n vocabulary_size,\n main_cfg,\n model_cfg,\n ):\n self.x1 = tf.placeholder(dtype=t... | [
[
"tensorflow.get_variable",
"tensorflow.rint",
"tensorflow.placeholder",
"tensorflow.gather",
"tensorflow.summary.merge_all",
"tensorflow.to_float",
"tensorflow.variable_scope",
"tensorflow.summary.scalar"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
QuentinAndre/pypcurve | [
"34b96353218a6831020ea2addb5e375fec2f7259"
] | [
"poibin/poibin.py"
] | [
"# -*- coding: utf-8 -*-\n\"\"\"\nCreated on Tue Mar 29, 2016\nModule:\n poibin - Poisson Binomial Distribution\nAuthor:\n Mika Straka\nDescription:\n Implementation of the Poisson Binomial distribution for the sum of\n independent and not identically distributed random variables as described\n in th... | [
[
"numpy.abs",
"numpy.fft.fft",
"numpy.arange",
"numpy.finfo",
"numpy.all",
"numpy.arctan2",
"numpy.array",
"numpy.exp",
"numpy.empty",
"numpy.conjugate"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
simonsantama/transient_heat_conduction | [
"badb70965e62def5d14243dfc30a5f8502f1fd60"
] | [
"transient_heat_conduction/classes_and_functions/calc_parameters.py"
] | [
"\"\"\"\nCalculates parameters that are used by the numerical solver\n\"\"\"\nimport numpy as np\n\n\ndef calc_Fo(sample, t_step):\n \"\"\"Returns the Fourier number as an array given the density, conductivity\n and heat capacity as DataFrames\"\"\"\n\n sample.fo.iloc[:, t_step] = (sample.conductivity.iloc... | [
[
"numpy.diagflat",
"numpy.exp",
"numpy.zeros_like"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
c-w-m/btap | [
"6f96f599df1fbeb7dcffa3a4f3e5e584e9df67f0"
] | [
"ch03/Scraping_Extraction.py"
] | [
"print('Chapter 03: Scraping Extraction')\nprint('~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~')\nprint('setup.py')\n# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nBASE_DIR = \"..\"\ndef figNum():\n figNum.counter += 1\n return \"{0:02d}\".format(figNum.counter)\nfigNum.counter = 0\nFIGPREFIX = 'ch03... | [
[
"matplotlib.pyplot.tight_layout",
"pandas.to_datetime",
"pandas.DataFrame",
"matplotlib.rcParams.update",
"pandas.set_option"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
LaudateCorpus1/jax-1 | [
"d42981bf1c0b6e6f4951062e2ea9f74e84a1c67f"
] | [
"jax/experimental/pjit.py"
] | [
"# Copyright 2021 Google LLC\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# https://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable law or agreed ... | [
[
"numpy.asarray",
"numpy.cumprod",
"numpy.prod"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
QDLGARIM/Semantic-segmentation-network-for-mechanical-assembly- | [
"27c90c323808f1c97726d21fa0ddc7d4e1735b35"
] | [
"guided_filter.py"
] | [
"import tensorflow as tf\n\nfrom box_filter import box_filter\n\n\ndef guided_filter(x, y, r, eps=1e-8, nhwc=False):\n assert x.shape.ndims == 4 and y.shape.ndims == 4\n\n # data format\n if nhwc:\n x = tf.transpose(x, [0, 3, 1, 2])\n y = tf.transpose(y, [0, 3, 1, 2])\n\n # shape check\n ... | [
[
"tensorflow.assert_greater",
"tensorflow.transpose",
"tensorflow.control_dependencies",
"tensorflow.shape",
"tensorflow.equal",
"tensorflow.identity",
"tensorflow.ones",
"tensorflow.assert_equal",
"tensorflow.image.resize"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
emillyasmin/analise-de-dados-IES | [
"e3dc2f08041f59ca4d9c5794586471f5f4d20a8f"
] | [
"main.py"
] | [
"from matplotlib import pyplot\n\n\ndef contagem(dicio, key):\n if key not in dicio.keys():\n dicio[key] = 1\n else:\n dicio[key] += 1\n\n\ndef questao(numero, texto):\n print()\n print(f'------------- QUESTÃO {numero} -------------')\n print(texto)\n print()\n\n\ndef saida(dicio, to... | [
[
"matplotlib.pyplot.savefig",
"matplotlib.pyplot.title",
"matplotlib.pyplot.figure"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
etalab-ia/ocr-xtract | [
"e09897dcfdb2d27a0008e4004bf70ecacfeb288c"
] | [
"src/data/doctr_utils.py"
] | [
"from pathlib import Path\nfrom typing import List, Optional\n\nimport pandas as pd\nfrom doctr.io import Document, DocumentFile\nfrom doctr.models import ocr_predictor\n\n\ndef get_list_words_in_page(page: Document):\n list_words_in_page = []\n for block in page.blocks:\n for line in block.lines:\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": []
}
] |
data-man-34/TensorFlow-Projects | [
"d468ba78a1202b0ebf026ee33fdf530d77011e25"
] | [
"2-Layer-MNIST.py"
] | [
"# @author: BOYU ZHANG\n# GitHub: CristianoBY\n# All Rights Reserved\n\n# Neural Network for solving the MNIST dataset recognition\n# http://yann.lecun.com/exdb/mnist/\n\nimport tensorflow as tf\nimport matplotlib\nmatplotlib.use('TkAgg')\n\nimport matplotlib.pyplot as plt\nfrom tensorflow import keras\nfrom keras.... | [
[
"matplotlib.pyplot.legend",
"matplotlib.pyplot.title",
"matplotlib.use",
"matplotlib.pyplot.plot",
"matplotlib.pyplot.xlabel",
"matplotlib.pyplot.show",
"tensorflow.keras.utils.to_categorical",
"matplotlib.pyplot.ylabel"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10",
"2.7",
"2.2",
"2.3",
"2.4",
"2.5",
"2.6"
]
}
] |
emleddin/mm_2019_sss_2 | [
"0c320653daab9b65090b20c012006c011b39f9a4"
] | [
"mm_2019_sss_2/system.py"
] | [
"import numpy as np\n\n\nclass SystemSetup:\n \"\"\"A class object that initializes the system for your Monte Carlo\n calculation.\n\n By defining the method as either 'random' or 'file' you an either generate\n a random box of Ar atoms, or you can read in the coordinates the specifying\n the file us... | [
[
"numpy.cbrt",
"numpy.random.rand",
"numpy.loadtxt"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
winderica/GoodbyeSteganography | [
"bcafd1ab4cbb049a4c8593b54f66e1753bf25758"
] | [
"3/utils.py"
] | [
"import numpy as np\nimport hashlib\nimport math\n\n\ndef pad_image(size, image):\n ceil = lambda n, s: math.ceil(n / s) * s\n h, w, _ = image.shape\n padded_img = np.zeros((ceil(h, size), ceil(w, size), 3), dtype=np.uint8)\n padded_img[:h, :w] = image\n return padded_img\n\n\ndef key_gen(key, size):... | [
[
"numpy.random.permutation",
"numpy.random.seed",
"numpy.random.randint"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ryashpal/mimic_iii_explore | [
"6fd022ccb5c6f4967be1b3be474298107877c7d3"
] | [
"mimic_direct_extract.py"
] | [
"from __future__ import print_function, division\n\n# MIMIC IIIv14 on postgres 9.4\nimport os, psycopg2, re, sys, time, numpy as np, pandas as pd\nfrom sklearn import metrics\nfrom datetime import datetime\nfrom datetime import timedelta\n\nfrom os.path import isfile, isdir, splitext\nimport argparse\nimport pickle... | [
[
"matplotlib.pyplot.legend",
"pandas.concat",
"pandas.read_csv",
"pandas.to_datetime",
"pandas.Series",
"pandas.read_sql_query",
"matplotlib.use",
"matplotlib.pyplot.subplots",
"pandas.DataFrame",
"matplotlib.pyplot.plot",
"pandas.to_numeric",
"matplotlib.pyplot.figu... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
lianghongzhuo/MultimodalPouring | [
"6495c7de9afad396f39bd7ac25e1a150e74479d2"
] | [
"audio_pouring/model/dataset.py"
] | [
"#!/usr/bin/env python\n# -*- coding:UTF-8 -*-\n\n# File Name : dataset.py\n# Purpose :\n# Creation Date : 05-01-2019\n# Author : Shuang Li [sli[at]informatik[dot]uni-hamburg[dot]de]\n# Author : Hongzhuo Liang [liang[at]informatik[dot]uni-hamburg[dot]de]\nfrom __future__ import division, pri... | [
[
"numpy.abs",
"numpy.asfortranarray",
"numpy.array",
"numpy.zeros",
"numpy.roll",
"numpy.vstack",
"numpy.random.randint"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Lornatang/Deep-learning-with-python3 | [
"11794d871e68f8f80486a07bf5137325b4ee1526"
] | [
"pytorch/2.1-a-first-look-at-a-neural-network.py"
] | [
"# Copyright 2019 Lorna Authors. All Rights Reserved.\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 b... | [
[
"torch.nn.CrossEntropyLoss",
"torch.max",
"torch.utils.data.DataLoader",
"torch.nn.Linear",
"torch.no_grad",
"torch.cuda.is_available"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
matteoferla/pedel2 | [
"0767cf37a7b1af74319c4d515da53f338f70f7a0"
] | [
"direvo/calculations.py"
] | [
"#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\n# Written for python 3, not tested under 2.\n\"\"\"\n\"\"\"\n__author__ = \"Matteo Ferla. [Github](https://github.com/matteoferla)\"\n__email__ = \"matteo.ferla@gmail.com\"\n__date__ = \"\"\n\nN = \"\\n\"\nT = \"\\t\"\n# N = \"<br/>\nimport json\nimport os\nimport r... | [
[
"numpy.random.poisson",
"numpy.random.uniform"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
zenodhaene/HyperspectralClassification | [
"77722f4a5c5337b2b3cf017e999eaace42a893c6"
] | [
"src/python/api/Algorithms/PatchPreprocessing.py"
] | [
"import numpy as np\n\nfrom Algorithms.Preprocessing import Preprocessing\n\nclass PatchPreprocessing(Preprocessing):\n def __init__(self, data, labels, n_train_samples, n_validation_samples, use_ground_truth, patch_radius):\n super().__init__(data, labels, n_train_samples, n_validation_samples, use_groun... | [
[
"numpy.array",
"numpy.random.shuffle"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Junnozyp/my_recyclable_net | [
"b3b981ac5bb454f698b7d4681d01503d60b2e22b"
] | [
"Linux_project/PyQt5/QPixmap.py"
] | [
"import os\nimport sys\nimport time\n\nimport numpy as np\nfrom PyQt5.QtCore import Qt, QTimer\nfrom PyQt5.QtGui import QFont, QIcon, QImage, QPainter, QPixmap\nfrom PyQt5.QtWidgets import (QApplication, QGridLayout, QHBoxLayout, QLabel,\n QMessageBox, QPushButton, QVBoxLayout, QWidget)\... | [
[
"numpy.reshape",
"numpy.argsort"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
khammernik/sigmanet | [
"6eb8dbd1ee350bb9baee60eb254080f7d660bbc5"
] | [
"reconstruction/models/sigmanet/run.py"
] | [
"\"\"\"\nCopyright (c) 2019 Imperial College London.\n\nThis source code is licensed under the MIT license found in the\nLICENSE file in the root directory of this source tree.\n\"\"\"\n\nimport logging\nimport resource\nimport sys\nfrom collections import defaultdict\n\nimport matplotlib.pyplot as plt\nimport nump... | [
[
"numpy.hstack",
"torch.no_grad",
"torch.load"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
nocotan/orakl | [
"b524bc311f008b7ac46f5c289e4cc86322f4c5e3"
] | [
"tests/attr/core/strategies/test_expected_model_change.py"
] | [
"#!/usr/bin/env python3\nimport numpy as np\nimport tensorflow as tf\n\nfrom orakl.attr import ExpectedModelChange\n\nfrom ...helpers.utils import BaseTest\n\n\nclass Test(BaseTest):\n def test_call_with_empty_data_pool(self):\n emc = ExpectedModelChange()\n model = tf.keras.Model()\n\n with... | [
[
"tensorflow.keras.losses.SparseCategoricalCrossentropy",
"tensorflow.keras.layers.Dense",
"tensorflow.keras.Model",
"numpy.random.rand",
"tensorflow.keras.layers.Flatten",
"tensorflow.initializers.he_normal"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
TemoaProject/PowerGenome | [
"4cb1e13f032195e39867fe9e26528de1d1b9ec57"
] | [
"powergenome/load_profiles.py"
] | [
"\"\"\"\nHourly demand profiles\n\"\"\"\n\nimport logging\nfrom pathlib import Path\nimport pandas as pd\nimport numpy as np\n\nfrom powergenome.util import regions_to_keep, reverse_dict_of_lists, remove_feb_29\nfrom powergenome.external_data import make_demand_response_profiles\nfrom powergenome.eia_opendata impor... | [
[
"pandas.read_sql_table",
"pandas.read_csv"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.3",
"1.1",
"1.5",
"1.2"
],
"scipy": [],
"tensorflow": []
}
] |
lzha106/Paddle | [
"a9a531fa5f15038a0627fc5c439c462c7be05f1a"
] | [
"python/paddle/fluid/contrib/tests/test_distributed_reader.py"
] | [
"# Copyright (c) 2019 PaddlePaddle 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 ... | [
[
"numpy.random.random",
"numpy.random.randint"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
c-koehl/oemof-examples | [
"86456d50d43c6c3a83e6be5efd0c624881d2e6f0"
] | [
"oemof_examples/tespy/solar_collector/solar_collector.py"
] | [
"# -*- coding: utf-8 -*-\n\"\"\"\nCreated on Thu Jan 9 10:48:43 2020\n\n@author: Malte Fritz\n\"\"\"\n\nfrom tespy.networks import network\nfrom tespy.components import sink, source, solar_collector\nfrom tespy.connections import connection\n\nimport numpy as np\nfrom matplotlib import pyplot as plt\nimport pandas... | [
[
"numpy.linspace",
"pandas.DataFrame",
"numpy.meshgrid",
"matplotlib.pyplot.show",
"matplotlib.pyplot.figure"
]
] | [
{
"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": []
}
] |
EL-BID/Covid-19-Traffic-Impact-Dashboard | [
"93cf471e5f3e45b22090b3278a362ddcf01a20c4"
] | [
"src/runners/create_local_table_athena.py"
] | [
"from pathlib import Path\n\nhome = Path().home()\n\nimport gspread\nfrom oauth2client.service_account import ServiceAccountCredentials\nimport pandas as pd\nimport logging\nfrom df2gspread import df2gspread as d2g\nimport yaml\nfrom datetime import timedelta, date\nimport osm_road_length\nfrom shapely import wkt\n... | [
[
"pandas.concat",
"pandas.DataFrame"
]
] | [
{
"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": []
}
] |
TacPhoto/Learning | [
"28fb3c6469164c57d0ccb973732168f01b685113",
"28fb3c6469164c57d0ccb973732168f01b685113"
] | [
"Python/MachineLearningCourse/BestFitLine_Regression.py",
"Python/StandaloneExercises/NumpyMatrixes2.py"
] | [
"from statistics import mean\nimport numpy as np\n\nimport matplotlib.pyplot as plt\n\ndef best_fit_slope_and_intercept(xs, ys):\n m = ( ( (mean(xs) * mean(ys)) - mean(xs*ys) ) /\n ( (mean(xs)*mean(xs)) - mean(xs**2) ) )\n b = mean(ys) - m * mean(xs)\n return m, b\n\nplt.style.us... | [
[
"matplotlib.pyplot.scatter",
"matplotlib.pyplot.plot",
"numpy.array",
"matplotlib.pyplot.show",
"matplotlib.pyplot.style.use"
],
[
"numpy.dot",
"numpy.inner",
"numpy.multiply",
"numpy.linalg.matrix_rank",
"numpy.linalg.matrix_power",
"numpy.kron",
"numpy.linalg.... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
alxqiu/cobra | [
"dd94f4bafe4462a0d0e1a4de0303a921c3bdbebd"
] | [
"python/angle_plot.py"
] | [
"import joint_positions as ag\nimport numpy as np\nimport pandas as pd\nimport matplotlib.pyplot as plt\nimport math\n\n# TICKS are ticks per cycle\nTICKS = 200\nS_PER_TICK = 0.01\nCYCLES = 7\n\ndef tick_joint_pos(i):\n return ag.find_joint_coords(\n lambda x: ag.AMPLITUDE *\n np.... | [
[
"pandas.concat",
"numpy.arange",
"pandas.DataFrame",
"numpy.sin",
"matplotlib.pyplot.xlim",
"matplotlib.pyplot.show"
]
] | [
{
"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": []
}
] |
MokkeMeguru/addons | [
"af6866a2e6d9ddbc79d612d7cb04a8a5befe4a47"
] | [
"tensorflow_addons/losses/contrastive.py"
] | [
"# Copyright 2019 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.convert_to_tensor",
"tensorflow.keras.utils.register_keras_serializable",
"tensorflow.math.square",
"tensorflow.dtypes.cast",
"tensorflow.math.maximum"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
petercheng00/PSPNet-Keras-tensorflow | [
"d50583786a3e8782dd1b735d268e57392cd8c646"
] | [
"python_utils/utils.py"
] | [
"from __future__ import print_function\nimport colorsys\nimport numpy as np\nfrom keras.models import Model\nfrom cityscapes_labels import trainId2label\nfrom ade20k_labels import ade20k_id2label\nfrom pascal_voc_labels import voc_id2label\n\n\ndef class_image_to_image(class_id_image, class_id_to_rgb_map):\n \"\... | [
[
"numpy.max",
"numpy.zeros",
"numpy.mean",
"numpy.min"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
alisure-fork/imgaug | [
"037abbd0d9f8dd8949c10858bf4aa2f7762c6add"
] | [
"test/augmentables/test_normalization.py"
] | [
"from __future__ import print_function, division, absolute_import\n\nimport sys\n# unittest only added in 3.4 self.subTest()\nif sys.version_info[0] < 3 or sys.version_info[1] < 4:\n import unittest2 as unittest\nelse:\n import unittest\n# unittest.mock is not available in 2.7 (though unittest2 might contain ... | [
[
"numpy.allclose",
"numpy.array_equal",
"matplotlib.use",
"numpy.dtype",
"numpy.ones",
"numpy.full",
"numpy.copy",
"numpy.float32",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
leenldk/incubator-tvm | [
"46ce24d1451ecf2c06e77ca751ceda1971968922"
] | [
"python/tvm/relay/frontend/pytorch.py"
] | [
"# Licensed to the Apache Software Foundation (ASF) under one\n# or more contributor license agreements. See the NOTICE file\n# distributed with this work for additional information\n# regarding copyright ownership. The ASF licenses this file\n# to you under the Apache License, Version 2.0 (the\n# \"License\"); y... | [
[
"numpy.uint8",
"numpy.float16",
"numpy.int32",
"numpy.int8",
"torch._C._jit_pass_inline",
"numpy.ones",
"numpy.finfo",
"numpy.int64",
"numpy.int16",
"numpy.float64",
"numpy.float32"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
bringBackm/EFCNN | [
"a10e5d4714d4f447f26cbeeb0255aca61eb1dc34"
] | [
"object_wise/object_wise_evaluate.py"
] | [
"import argparse\nimport sys\nfrom tqdm import tqdm\nfrom random import shuffle\n\nimport torch\nimport numpy as np\nimport matplotlib.pyplot as plt\nfrom skimage.filters import gaussian\n\nsys.path.insert(0, '.')\nfrom dataset_processing.grasp import BoundingBoxes, detect_grasps\nfrom object_wise_datasets import C... | [
[
"numpy.expand_dims",
"torch.load",
"torch.tensor",
"matplotlib.pyplot.colorbar",
"torch.no_grad",
"numpy.transpose",
"torch.nn.DataParallel",
"matplotlib.pyplot.show",
"matplotlib.pyplot.figure"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
mafrancelino/Atividades-Coursera | [
"3533857bd4b05197f3b278dc94dc94f6842079a8"
] | [
"Neural Networks and Deep Learning/Planar_data_classification_with_onehidden_layer_v6c.py"
] | [
"\n# coding: utf-8\n\n# \n# ### <font color = \"darkblue\">Updates to Assignment</font>\n# \n# #### If you were working on the older version:\n# * Please click on the \"Coursera\" icon in the top right to open up the folder directory. \n# * Navigate to the folder: Week 3/ Planar data classification with one hidden... | [
[
"numpy.dot",
"numpy.log",
"sklearn.linear_model.LogisticRegressionCV",
"matplotlib.pyplot.scatter",
"numpy.random.seed",
"matplotlib.pyplot.title",
"numpy.power",
"numpy.squeeze",
"matplotlib.pyplot.subplot",
"numpy.mean",
"numpy.random.randn",
"numpy.tanh",
"nu... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
PrivateFork/DeOldify | [
"5ba37561aed980f117304217f7dd6a57f51cb3a0"
] | [
"fasterai/filters.py"
] | [
"from numpy import ndarray\nfrom abc import ABC, abstractmethod\nfrom .generators import Unet34, Unet101, Unet152, GeneratorModule\nfrom .transforms import BlackAndWhiteTransform\nfrom fastai.torch_imports import *\nfrom fastai.core import *\nfrom fastai.transforms import Transform, scale_min, tfms_from_stats, ince... | [
[
"scipy.misc.toimage"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [
"0.13",
"0.14",
"0.15",
"1.0",
"0.19",
"0.18",
"1.2",
"0.12",
"0.10",
"0.17",
"0.16"
],
"tensorflow": []
}
] |
iflyings/tensorflow-flower | [
"3b67dbbcda1d0855e0799e81ffc462192580b30e",
"3b67dbbcda1d0855e0799e81ffc462192580b30e"
] | [
"python/app.py",
"python/classifier.py"
] | [
"#!/home/iflyings/VSCode/venv/tensorflow-venv python\n# -*- coding:utf-8 -*-\n# Author: iflyings\nimport os\nimport numpy as np\nimport tensorflow as tf\nfrom recordres import RecordRes\nfrom imageres import ImageRes\nfrom cnnmodel import CnnModel\nfrom cnnnetwork import CnnNetwork\nfrom vgg16 import VGG16\n\nimage... | [
[
"tensorflow.cast",
"tensorflow.compat.v1.InteractiveSession",
"tensorflow.compat.v1.train.Saver",
"tensorflow.compat.v1.summary.merge_all",
"numpy.reshape",
"tensorflow.ConfigProto",
"tensorflow.reset_default_graph",
"numpy.argmax",
"tensorflow.nn.in_top_k",
"tensorflow.com... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
kangxue/LOGAN | [
"7951d05abae1d79651a9e44f0fce1b2fde929b9c"
] | [
"latent_3d_points/structural_losses/tf_nndistance.py"
] | [
"import tensorflow as tf\nfrom tensorflow.python.framework import ops\nimport os.path as osp\n\nbase_dir = osp.dirname(osp.abspath(__file__))\n\nnn_distance_module = tf.load_op_library(osp.join(base_dir, 'tf_nndistance_so.so'))\n\n\ndef nn_distance(xyz1, xyz2):\n\t'''\n\tComputes the distance of nearest neighbors f... | [
[
"tensorflow.TensorShape",
"tensorflow.device",
"tensorflow.constant",
"tensorflow.python.framework.ops.RegisterGradient",
"numpy.random.seed",
"tensorflow.Variable",
"tensorflow.reduce_sum",
"tensorflow.python.framework.ops.RegisterShape",
"tensorflow.initialize_all_variables",... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
Bi0T1N/agents | [
"d4f392dd5a42910dde6507bcb80620ab57ceb292"
] | [
"tf_agents/experimental/examples/cql_sac/kumar20/cql_sac_train_eval.py"
] | [
"# coding=utf-8\n# Copyright 2020 The TF-Agents Authors.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# https://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required ... | [
[
"tensorflow.io.gfile.glob",
"tensorflow.keras.optimizers.Adam",
"numpy.random.seed",
"tensorflow.random.set_seed"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
zheng-ningxin/MLPruning | [
"a9ac0ecbda1750195041760baaf29372c35a4171"
] | [
"training/masked_blockwise_run_glue.py"
] | [
"# This code is modified from https://github.com/huggingface/transformers/tree/master/examples/pytorch/text-classification\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# We add more functionalities as well as remove unnecessary functionalities\n\nimport argparse\nimport glob\nimport json\ni... | [
[
"torch.nn.functional.softmax",
"torch.load",
"numpy.squeeze",
"torch.utils.data.DataLoader",
"torch.cuda.amp.autocast",
"torch.no_grad",
"torch.cuda.manual_seed_all",
"torch.cuda.is_available",
"torch.device",
"torch.distributed.get_rank",
"scipy.special.softmax",
"... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [
"1.6",
"1.10",
"1.4",
"1.9",
"1.5",
"1.2",
"1.7",
"1.3",
"1.8"
],
"tensorflow": []
}
] |
jmframe/nwm-post-processing-with-lstm | [
"c254b277073aeff819e398594d26858b2ddb987d"
] | [
"check_for_gpu_available.py"
] | [
"#!/att/nobackup/jframe/anaconda3/bin/python3\nimport multiprocessing\nimport torch\nnum_cores = multiprocessing.cpu_count()\nprint(f\"There are {num_cores} cpu cores available\")\nuse_cuda = torch.cuda.is_available()\nprint(use_cuda)\nDEVICE = torch.device(\"cuda:0\" if use_cuda else \"cpu\")\nprint('using device'... | [
[
"torch.device",
"torch.cuda.is_available"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
issamouawad/retina-tracking | [
"8ba29342c2783bf92fd7d1c4be34b98ddd4a7d43"
] | [
"keras_retinanet/utils/anchors.py"
] | [
"\"\"\"\nCopyright 2017-2018 Fizyr (https://fizyr.com)\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable la... | [
[
"numpy.meshgrid",
"numpy.arange",
"numpy.tile",
"numpy.stack",
"numpy.logical_or",
"numpy.append",
"numpy.argmax",
"numpy.array",
"numpy.zeros",
"numpy.vstack"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
zhihanyang2022/gym_custom | [
"6a50421b51ab4db35dd34fe7624ed7bac648e9f2"
] | [
"gym_custom/envs/pomdp_mountain_car_easy.py"
] | [
"# -*- coding: utf-8 -*-\n\"\"\"\n@author: Olivier Sigaud\n\nA merge between two sources:\n\n* Adaptation of the MountainCar Environment from the \"FAReinforcement\" library\nof Jose Antonio Martin H. (version 1.0), adapted by 'Tom Schaul, tom@idsia.ch'\nand then modified by Arnaud de Broissia\n\n* the OpenAI/gym ... | [
[
"numpy.array",
"numpy.ones_like",
"numpy.linspace"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
papelero/control-limit-search | [
"c3b8dfbc22e1c895f7e868f9243e21cee7599444"
] | [
"control_limits/src/statistical_distance.py"
] | [
"import numpy as np\n\n\nclass StatisticalDistance:\n \"\"\"Locate the maximum class separability in time-series data\n\n :param data: input data\n :param labels: input labels\n \"\"\"\n\n def __init__(self, data, labels):\n self.data = data\n self.labels = labels\n\n @staticmethod\n... | [
[
"numpy.min",
"numpy.unique",
"numpy.max",
"numpy.argmax",
"numpy.empty"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
rickyHong/Question-answer-repl | [
"22573096ec48c94bbb3d91ad20ca5fb12d6790fc"
] | [
"open/dump_tfidf.py"
] | [
"import json\nimport os\nimport argparse\nimport random\nimport h5py\nimport numpy as np\nimport scipy.sparse as sp\nimport logging\n\nfrom tqdm import tqdm\nfrom drqa import retriever\nfrom drqa.retriever import utils\n\nlogger = logging.getLogger(__name__)\n\nRANKER_PATH = os.path.join(\n os.path.expanduser('~... | [
[
"numpy.log",
"numpy.multiply",
"numpy.unique",
"scipy.sparse.csr_matrix",
"numpy.log1p"
]
] | [
{
"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"... |
yonglin-wang/spacecraft-crash-predictor | [
"527839e1d5084dfb8b45411e2eccf89086e31253"
] | [
"src/predict.py"
] | [
"#!/usr/bin/env python3\n# Author: Yonglin Wang\n# Date: 2021/3/21 10:14 PM\n# Run prediction on held-out test sets, supports 1) running on test sets with different look ahead times\n# and 2) running on new threshold at a specific recall\n\nimport os\nimport re\nimport pickle\nfrom typing import Union, Tuple\n\nimp... | [
[
"tensorflow.keras.models.load_model",
"pandas.read_csv",
"numpy.abs",
"numpy.random.seed",
"numpy.asarray",
"sklearn.metrics.precision_score",
"sklearn.metrics.precision_recall_curve",
"numpy.savez_compressed",
"sklearn.metrics.recall_score",
"sklearn.metrics.accuracy_score... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": [
"1.10",
"2.7",
"2.2",
"2.3",
"2.4",
"2.5",
"2.6"
]
}
] |
Beskamir/BlenderDepthMaps | [
"ba1201effde617078fb35f23d534372de3dd39c3"
] | [
"src/loadImage.py"
] | [
"import bpy\nimport os\nimport numpy\n#from .config import IMAGES_DIR\n\n#References:\n# https://docs.blender.org/api/blender_python_api_2_71_release/bpy.types.Image.html\n# https://blender.stackexchange.com/questions/13422/crop-image-with-python-script/13516#13516\n# https://blender.stackexchange.com/questio... | [
[
"numpy.empty"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
scutcyr/EVA | [
"37ff5210988a7b7fc0564d7fccf25571ddc9f425"
] | [
"src/generation_metrics.py"
] | [
"# coding=utf-8\n\nimport warnings\nimport numpy as np\nfrom typing import List\nfrom collections import Counter\nfrom nltk.translate.bleu_score import corpus_bleu, SmoothingFunction\nfrom copy import deepcopy\n\n\nclass Ngrams(object):\n \"\"\"\n Ngrams datastructure based on `set` or `list`\n dep... | [
[
"numpy.mean"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Weiming-Hu/DeepAnalogs | [
"59b9c08f6ffdad4f0ba4314761e1611f31feeac4"
] | [
"DeepAnalogs/AnEnDataset.py"
] | [
"# \"`-''-/\").___..--''\"`-._\n# (`6_ 6 ) `-. ( ).`-.__.`) WE ARE ...\n# (_Y_.)' ._ ) `._ `. ``-..-' PENN STATE!\n# _ ..`--'_..-_/ /--'_.' ,'\n# (il),-'' (li),' ((!.-'\n#\n# Author: Weiming Hu <weiming@psu.edu>\n# Geoinformatics and Earth Observation Laboratory (http://geolab.psu.... | [
[
"numpy.expand_dims",
"numpy.unique",
"numpy.isnan",
"numpy.arange",
"numpy.cumsum",
"torch.tensor",
"numpy.nanargmin"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
kolk/ConfnetPointerGenerator | [
"724823c2f809f413c3e35cf4e902b5ea36f5fa24"
] | [
"onmt/bin/preprocess.py"
] | [
"#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n\"\"\"\n Pre-process Data / features files and build vocabulary\n\"\"\"\nimport codecs\nimport glob\nimport gc\nimport torch\nfrom collections import Counter, defaultdict\n\nfrom onmt.utils.logging import init_logger, logger\nfrom onmt.utils.misc import split_corp... | [
[
"torch.manual_seed",
"torch.load",
"torch.save"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
thatlittleboy/pyjanitor | [
"f7977e00d3d9bf49aebeaa62db2965a668c50c90"
] | [
"janitor/functions/encode_categorical.py"
] | [
"import warnings\nfrom enum import Enum\nfrom typing import Hashable, Iterable, Union\n\nimport pandas_flavor as pf\nimport pandas as pd\nfrom pandas.api.types import is_list_like\n\nfrom janitor.utils import check, check_column, deprecated_alias\n\n\n@pf.register_dataframe_method\n@deprecated_alias(columns=\"colum... | [
[
"pandas.api.types.is_list_like",
"pandas.Index",
"pandas.CategoricalDtype"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"0.24"
],
"scipy": [],
"tensorflow": []
}
] |
pyvonpyton/PyHealth | [
"b7eb39ed18a335dc702bfdb0801fe7f2d9ca5366",
"b7eb39ed18a335dc702bfdb0801fe7f2d9ca5366"
] | [
"pyhealth/data/expdata_generator.py",
"pyhealth/evaluation/phenotyping.py"
] | [
"# -*- coding: utf-8 -*-\n\n# Author: Zhi Qiao <mingshan_ai@163.com>\n\n# License: BSD 2 clause\n\nimport os\nimport csv\nimport pickle\nimport random\nimport numpy as np\nimport pandas as pd\nimport tqdm\nfrom tqdm._tqdm import trange\nimport time\nfrom ..utils.check import *\n\nclass imagedata:\n\n def __init_... | [
[
"numpy.array",
"pandas.read_csv"
],
[
"sklearn.metrics.roc_auc_score",
"sklearn.metrics.hamming_loss",
"numpy.shape",
"sklearn.metrics.average_precision_score",
"sklearn.metrics.label_ranking_loss",
"numpy.argsort",
"sklearn.metrics.label_ranking_average_precision_score",
... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
zh417233956/pykeywordsearch | [
"4b77465a68d71b9b014b731ca5cadbe742206981"
] | [
"handlers/searchHanler.py"
] | [
"\"\"\" 利用倒排表进行优化 \"\"\"\nimport pandas as pd\nimport matplotlib as mpl\nimport numpy as np\nfrom nltk.probability import FreqDist\nimport time\nfrom utils.jiebaSegment import Seg\nfrom utils.sentenceSimilarity import SentenceSimilarity\nimport logging\n\nmpl.rcParams['font.sans-serif'] = ['Microsoft YaHei'] # ena... | [
[
"numpy.array",
"pandas.read_csv"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
puruBHU/tf-keras-stacked-hourglass-keypoint-detection | [
"56707252501c73b2bf2aac8fff3e22760fd47dca"
] | [
"demo.py"
] | [
"#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\nimport os, sys, argparse\nimport cv2\nfrom PIL import Image\nimport numpy as np\nimport time\nfrom timeit import default_timer as timer\nfrom tensorflow.keras.models import Model, load_model\nimport tensorflow.keras.backend as K\n\nfrom hourglass.model import get_ho... | [
[
"numpy.asarray",
"tensorflow.keras.backend.set_learning_phase",
"numpy.array",
"tensorflow.keras.models.Model"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"2.7",
"2.6",
"2.4",
"2.3",
"2.5",
"2.2"
]
}
] |
wsjeon/softlearning | [
"8ceba916e5b3b2df66a1aa51bed3ff703e394a56",
"8ceba916e5b3b2df66a1aa51bed3ff703e394a56"
] | [
"examples/development/variants.py",
"softlearning/preprocessors/convnet.py"
] | [
"from ray import tune\nimport numpy as np\n\nfrom softlearning.misc.utils import get_git_rev, deep_update\n\nM = 256\nREPARAMETERIZE = True\n\nNUM_COUPLING_LAYERS = 2\n\n\nGAUSSIAN_POLICY_PARAMS_BASE = {\n 'type': 'GaussianPolicy',\n 'kwargs': {\n 'hidden_layer_sizes': (M, M),\n 'squash': True,\... | [
[
"numpy.random.randint"
],
[
"tensorflow.concat",
"tensorflow.keras.layers.Lambda",
"tensorflow.keras.layers.Conv2D",
"tensorflow.keras.layers.Reshape",
"tensorflow.keras.layers.Flatten",
"tensorflow.keras.layers.Input"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10",
"2.7",
"2.6",
"2.4",
"2.3",
"2.5",
"2.2"
]
}
] |
derektan95/drl-algorithms-collection | [
"bd4bcf82d28027c84e919df371ed20576e1c4379"
] | [
"exercises/multi_agent_methods/multi-agent-ddpg/main.py"
] | [
"# main function that sets up environments\n# perform training loop\n\nimport envs\nfrom buffer import ReplayBuffer\nfrom maddpg import MADDPG\nimport torch\nimport numpy as np\nfrom tensorboardX import SummaryWriter\nimport os\nfrom utilities import transpose_list, transpose_to_tensor\n\n# keep training awake\nfro... | [
[
"numpy.rollaxis",
"torch.Tensor",
"numpy.random.seed",
"torch.manual_seed",
"torch.set_num_threads",
"numpy.mean",
"torch.stack",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
pacsuta/tf-nn-maze-solver | [
"6e6f0e53ea80d82c4252cb69f44de4d9d8cea1b1"
] | [
"random_exploration2.py"
] | [
"import numpy as np\r\nimport maze_collection as mc\r\nimport maze\r\n\r\nMAX_STEPS = 20\r\n\r\nm = maze.Maze(mc.T_maze)\r\n\r\ncumulative = np.zeros_like(m.maze, np.int64)\r\ncumulative[m.startY, m.startX] = 1\r\n\r\nvictory_steps = np.zeros(MAX_STEPS)\r\n\r\nfor i in range(MAX_STEPS):\r\n change = np.zeros_lik... | [
[
"numpy.zeros_like",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
RomanKotybeev/yellowbrick | [
"2bca408eb4134f9cfac49deb8ed2f3c9ded9a975"
] | [
"yellowbrick/text/tsne.py"
] | [
"# yellowbrick.text.tsne\n# Implements TSNE visualizations of documents in 2D space.\n#\n# Author: Benjamin Bengfort\n# Author: Rebecca Bilbro\n# Created: Mon Feb 20 06:33:29 2017 -0500\n#\n# Copyright (C) 2016 The scikit-yb developers\n# For license information, see LICENSE.txt\n#\n# ID: tsne.py [6aa9198] ben... | [
[
"sklearn.manifold.TSNE",
"numpy.array",
"sklearn.pipeline.Pipeline",
"numpy.unique"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
hemantranvir/turret | [
"bc3df21541ce2f808c749c985db47a210149f22c"
] | [
"tests/int8_test.py"
] | [
"# -*- coding: utf-8 -*-\nimport unittest\nimport turret\n\nimport numpy as np\n\n\nclass Int8Test(unittest.TestCase):\n def _create_builder(self):\n builder = turret.InferenceEngineBuilder(\n turret.loggers.ConsoleLogger())\n return builder\n\n def _create_network(self, builder):\n ... | [
[
"numpy.asarray"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
hadibakalim/Intel-Edge-AI-Fundamental-Course | [
"a937d4d12bfc7c9bae31056121ff5ddae911f7e0"
] | [
"lesson_02/03_deploy_an_app_at_edge/app.py"
] | [
"import argparse\nimport cv2\nimport numpy as np\n\nfrom handle_models import handle_output, preprocessing\nfrom inference import Network\n\n\nCAR_COLORS = [\"white\", \"gray\", \"yellow\", \"red\", \"green\", \"blue\", \"black\"]\nCAR_TYPES = [\"car\", \"bus\", \"truck\", \"van\"]\n\n\ndef get_args():\n '''\n ... | [
[
"numpy.where",
"numpy.zeros",
"numpy.sum",
"numpy.dstack"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
xiaoqiang0008/YOLOV2-predict-use-tensorflow | [
"218a630200291d7c585596bd4d18710b35b5d7a3"
] | [
"yolo/box.py"
] | [
"\nimport numpy as np\n\nclass BoundBox:\n def __init__(self, classes):\n self.x, self.y = float(), float()\n self.w, self.h = float(), float()\n self.c = float()\n self.class_num = classes\n self.probs = np.zeros((classes,))\n\ndef overlap(x1,w1,x2,w2):\n l1 = x1 - w1 / 2.;... | [
[
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Noble-Lab/mokapot-analyses | [
"6fade4dedbec9600eaf566fd8c71c9c42a9b9e08"
] | [
"scripts/percolator/runall.py"
] | [
"\"\"\"\nSample PSMs from the Kim et al then run Percolator and Mokapot\n\"\"\"\nimport os\nimport logging\nimport subprocess\n\nimport mokapot\nimport pandas as pd\n\n# Setup -----------------------------------------------------------------------\nPIN = os.path.join(\"..\", \"scope\", \"pin-out\", \"190222S_LCA9_X... | [
[
"pandas.read_table",
"pandas.merge"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.3",
"1.1",
"1.5",
"1.2"
],
"scipy": [],
"tensorflow": []
}
] |
aub-mind/Robust-Seizure-Prediction | [
"4c98a906121bb380fbe8e202ed21dfaf031964df"
] | [
"models/model_ae.py"
] | [
"\"\"\"\r\nThis file contains the class to build Model graph\r\n\r\n\"\"\"\r\nimport os\r\nimport numpy as np\r\nfrom models.helping_functions import *\r\nfrom utils.save_load import load_ae, savefile\r\nimport tensorflow as tf\r\nimport time\r\nfrom keras.utils import to_categorical\r\n\r\n\r\nclass CNN_GRU:\r\n ... | [
[
"tensorflow.layers.conv1d",
"tensorflow.zeros",
"tensorflow.variables_initializer",
"numpy.concatenate",
"tensorflow.nn.l2_loss",
"tensorflow.train.AdamOptimizer",
"numpy.random.randint",
"tensorflow.layers.max_pooling1d",
"tensorflow.get_collection",
"tensorflow.placeholde... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
hubertkarbowy/awd_lstm_tensorflow2 | [
"0b8d1f94003eb5895fadb73dc90bc2b6fd4655e4"
] | [
"ulmfit_tf2_heads.py"
] | [
"import tensorflow as tf\nimport tensorflow_text as text\nimport tensorflow_hub as hub\nfrom tensorflow.python.ops import math_ops, array_ops\nfrom tensorflow.python.keras.engine import keras_tensor\n# from .awdlstm_tf2 import *\nfrom .ulmfit_tf2 import *\n\ndef ulmfit_rnn_encoder_native(*, pretrained_weights=None,... | [
[
"tensorflow.keras.layers.Masking",
"tensorflow.keras.layers.RNN",
"tensorflow.keras.models.Model",
"tensorflow.keras.layers.Embedding",
"tensorflow.keras.layers.Dense",
"tensorflow.gather",
"tensorflow.keras.layers.BatchNormalization",
"tensorflow.keras.layers.Dropout",
"tensor... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10",
"2.7",
"2.6",
"2.4",
"2.3",
"2.5",
"2.2"
]
}
] |
JosephOHagan/pyspheregl | [
"4258f8bb69372f0cb33ea1d859aaa1d8195e0167"
] | [
"pyspheregl/demo/search_test.py"
] | [
"import math\nimport random\nfrom random import randint\nimport datetime\nimport numpy as np\nimport pyglet\nfrom pyglet.gl import *\n\n# sphere stuff\nfrom ..sim.sphere_sim import getshader, resource_file\nfrom ..sim import sphere_sim\nfrom ..sphere import sphere\nfrom ..utils.shader import ShaderVBO, shader_from... | [
[
"numpy.degrees",
"numpy.array",
"numpy.radians",
"numpy.linalg.norm"
]
] | [
{
"matplotlib": [],
"numpy": [
"1.10",
"1.12",
"1.11",
"1.19",
"1.24",
"1.13",
"1.16",
"1.9",
"1.18",
"1.23",
"1.21",
"1.22",
"1.20",
"1.7",
"1.15",
"1.14",
"1.17",
"1.8"
],
"pandas": [],
... |
Oktopus-Multicast/oktopus_dataset-gen | [
"ea178db9ffc64962c9f2d7276f48f6385f808078"
] | [
"okdatasetgen/commands/get_dataset_sfc.py"
] | [
"\"\"\"The get_sfc_dataset command.\"\"\"\n\nimport os, sys, random\nfrom math import ceil\nimport numpy as np\n\nfrom base import Base # cli\n\nfrom oktopus import load_sessions as ok_load_sessions\nfrom oktopus import App, Session, Node, make_service\nfrom oktopus.dataset import OK_SESSIONS_FILE, OK_NODES_SERVICE... | [
[
"numpy.random.choice"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
sebemery/Lipschitz-constrained-neural-networks | [
"79ac2c6f7e7cef692cacf35619baf91beaeba948"
] | [
"dataloader/BSD500.py"
] | [
"import torch\nfrom torch.utils.data import Dataset\nimport os\nimport numpy as np\nimport cv2\nimport matplotlib.pyplot as plt\nimport h5py\nimport random\n\n\nclass BSD500(Dataset):\n\n def __init__(self, data_dir, noise):\n super(Dataset, self).__init__()\n self.data_dir = data_dir\n self... | [
[
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
knighton/jax | [
"2ed6bbed3b98afc94da38506fb0431db5e26bf4d"
] | [
"jax/experimental/jax2tf/tests/jax2tf_test.py"
] | [
"# Copyright 2020 Google LLC\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# https://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable law or agreed ... | [
[
"tensorflow.constant",
"tensorflow.Variable",
"numpy.arange",
"tensorflow.ones",
"numpy.full",
"numpy.ones",
"tensorflow.Module",
"tensorflow.function",
"numpy.array",
"numpy.zeros",
"tensorflow.TensorSpec",
"tensorflow.nest.map_structure",
"tensorflow.GradientT... | [
{
"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"
]
}
] |
hughbing/Web-Scraping-Challenge | [
"3bc80e4238318de38244cd176b6bf47984cacdf6"
] | [
"scrape_mars.py"
] | [
"from splinter import Browser\r\nfrom bs4 import BeautifulSoup\r\nimport pandas as pd\r\nimport datetime as dt\r\n\r\n\r\ndef scrape_all():\r\n\r\n # Initiate headless driver for deployment\r\n browser = Browser(\"chrome\", executable_path=\"chromedriver\", headless=True)\r\n news_title, news_paragraph = m... | [
[
"pandas.read_html"
]
] | [
{
"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": []
}
] |
Prowler-io/numpy-stubs | [
"ceef07c4ad5c246dc3d25b0084b8f138c20ebe5b"
] | [
"tests/pass/records.py"
] | [
"import numpy as np\nimport numpy.core.records as records\n\n# Example data from numpy docs\nx1 = np.array([1, 2, 3, 4])\nx2 = np.array(['a', 'dd', 'xyz', '12'])\nx3 = np.array([1.1, 2, 3, 4])\nnames = ['a', 'b', 'c']\n\n# Testing various parameter types for fromarrays\nrecords.fromarrays([x1, x2, x3])\nrecords.fro... | [
[
"numpy.array",
"numpy.core.records.fromrecords",
"numpy.core.records.fromarrays"
]
] | [
{
"matplotlib": [],
"numpy": [
"1.11",
"1.10",
"1.12",
"1.19",
"1.24",
"1.13",
"1.16",
"1.9",
"1.18",
"1.23",
"1.21",
"1.22",
"1.20",
"1.7",
"1.15",
"1.14",
"1.17",
"1.8"
],
"pandas": [],
... |
Moctader/HMDSOrientation | [
"de33c2d9c3b8c7b36a8be5ee789e66818372d41f"
] | [
"Scripts/Utilities.py"
] | [
"import os\nimport cv2\nimport numpy as np\nimport matplotlib.pyplot as plt\nfrom joblib import Parallel, delayed\nfrom tqdm import tqdm\n\n# Add utility functions here\n\n\ndef load(path, axis=(1, 2, 0), n_jobs=12):\n\n \"\"\"\n Loads an image stack as numpy array.\n\n Parameters\n ----------\n path... | [
[
"matplotlib.pyplot.suptitle",
"matplotlib.pyplot.title",
"numpy.linspace",
"numpy.min",
"numpy.arange",
"numpy.max",
"numpy.shape",
"numpy.array",
"matplotlib.pyplot.show",
"matplotlib.pyplot.figure"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
disiji/fc_mondrian | [
"97420ff311242afe103c45130ada509e1e60a0ac"
] | [
"src/flowMP_visualize.py"
] | [
"import matplotlib as mpl\nimport matplotlib.patches as mpatches\nimport matplotlib.pyplot as plt\nimport numpy as np\n\n\n### VISUALIZE 2D MONDRIAN PROCESS ###\ndef print_partitions(partition, trans_level=1., color='k'):\n \"\"\"\n INPUT:\n partition: An mp tree defined on a 2 dimensional space\n O... | [
[
"matplotlib.pyplot.legend",
"matplotlib.pyplot.yticks",
"matplotlib.pyplot.imshow",
"matplotlib.pyplot.tight_layout",
"matplotlib.pyplot.scatter",
"matplotlib.pyplot.yscale",
"matplotlib.pyplot.savefig",
"matplotlib.pyplot.plot",
"matplotlib.pyplot.colorbar",
"matplotlib.py... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
shreyaspotnis/bandstructure1d | [
"710ea816179c2f3ff96e5cc7ac6a4228c31403f6"
] | [
"bandstructure1d/main.py"
] | [
"import numpy as np\nimport numpy.linalg as lin\nimport matplotlib.pyplot as plt\n\n\ndef calculate_band_structure(n_bands, n_q, lattice_depth):\n \"\"\"Calculate the band structure for a given depth of the potential.\n\n Inputs:\n n_bands - Number of bands to include in the calculation. The higher thi... | [
[
"numpy.diag",
"numpy.conj",
"numpy.linspace",
"numpy.arange",
"numpy.ones",
"matplotlib.pyplot.plot",
"numpy.linalg.eigh",
"matplotlib.pyplot.xlabel",
"matplotlib.pyplot.show",
"numpy.zeros",
"matplotlib.pyplot.ylabel"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Caolvxiong/CarND-Advanced-Lane-Lines | [
"44c0debe55e7010f91d4261cb138a1d4f2624013"
] | [
"project_2.py"
] | [
"import pickle\nimport cv2\nimport glob\nimport os\nimport numpy as np\nimport matplotlib.pyplot as plt\nimport matplotlib.image as mpimg\n\n# Define a function to generate mtx and dist\ndef cal_undist_params(read_path='camera_cal', out_path='output_images'):\n objpoints = [] # 3D points in real world space\n ... | [
[
"matplotlib.pyplot.imshow",
"numpy.absolute",
"numpy.sqrt",
"numpy.arctan2",
"matplotlib.image.imread",
"numpy.copy",
"numpy.max",
"numpy.zeros_like",
"numpy.float32",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ferjorosa/test-glfm | [
"b219c650d0429ea71b953743730ae53cc122a61b"
] | [
"vbsem_experiments/demo_types.py"
] | [
"import numpy as np\n\ndata = dict()\ndata['X'] = np.array([[1.0, 1, -0.3, 1, 1],[6.3, 2, 3.8, 23, np.nan],[11, 3, 4.1, 4, 2]]) # (N,D)\ndata['C'] = 'poGNc'\n\nprint(data['X'].dtype)\n\nres = np.isnan(data['X'])"
] | [
[
"numpy.isnan",
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
anhquannguyen21/Skeleton-Action-Recognition | [
"1bf6162b72189be8d24bce98d37859aa13178a9d"
] | [
"HR-Net/core/loss.py"
] | [
"# ------------------------------------------------------------------------------\n# Copyright (c) Microsoft\n# Licensed under the MIT License.\n# Written by Bin Xiao (Bin.Xiao@microsoft.com)\n# ------------------------------------------------------------------------------\n\nfrom __future__ import absolute_import\... | [
[
"torch.cat",
"torch.sum",
"torch.gather",
"torch.topk",
"torch.nn.MSELoss"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ankilab/AirwaySymptomDetection | [
"be5a552178ed46cd9f365b9f5cc7beb78c02d165",
"be5a552178ed46cd9f365b9f5cc7beb78c02d165"
] | [
"neural_networks/src/lr_scheduler.py",
"analysis/src/roc_curves.py"
] | [
"import numpy as np\n\n\ndef exp_scheduler(epoch, lr):\n \"\"\"\n Exponential learning rate scheduler.\n Args:\n epoch: Current epoch during TensorFlow training.\n lr: Current learning rate after each epoch.\n Returns:\n Learning rate shrinking exponentially.\n \"\"\"\n if epoch <... | [
[
"numpy.exp"
],
[
"matplotlib.pyplot.legend",
"matplotlib.pyplot.title",
"matplotlib.pyplot.ylim",
"numpy.arange",
"matplotlib.pyplot.savefig",
"matplotlib.pyplot.plot",
"matplotlib.pyplot.xlim",
"numpy.copy",
"matplotlib.pyplot.xlabel",
"numpy.array",
"matplotli... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
shubham-kamlaskar/Machine_Learning | [
"f56d86a267359c7a22342343fce741d952b7740e"
] | [
"Hiring/Hiring.py"
] | [
"import numpy as np \r\nimport pandas as pd\r\nimport matplotlib.pyplot as plt \r\nimport seaborn as sns\r\nfrom sklearn.tree import DecisionTreeClassifier\r\nfrom sklearn.model_selection import train_test_split\r\nfrom sklearn.linear_model import LinearRegression\r\nimport math\r\n\r\ndata = {\r\n \"experience\... | [
[
"sklearn.tree.DecisionTreeClassifier",
"sklearn.model_selection.train_test_split",
"sklearn.linear_model.LinearRegression",
"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": []
}
] |
rosteen/photutils | [
"5821bddc2d3fa2709b8de79c18efe99cff1ecb71",
"5821bddc2d3fa2709b8de79c18efe99cff1ecb71"
] | [
"photutils/morphology/tests/test_non_parametric.py",
"photutils/aperture/circle.py"
] | [
"# Licensed under a 3-clause BSD style license - see LICENSE.rst\n\"\"\"\nTests for the non_parametric module.\n\"\"\"\n\nimport numpy as np\n\nfrom ..non_parametric import gini\n\n\ndef test_gini():\n \"\"\"\n Test Gini coefficient calculation.\n \"\"\"\n\n data_evenly_distributed = np.ones((100, 100))... | [
[
"numpy.zeros",
"numpy.ones"
],
[
"numpy.atleast_1d",
"matplotlib.patches.Circle",
"matplotlib.patches.PathPatch"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
WeijiaLau/RSSN | [
"a18b7ae39befa5c6927900d1fad9bda1229b20ee"
] | [
"tf_models/layers/transformer.py"
] | [
"# -*- coding: utf-8 -*-\n#/usr/bin/python3\n\nimport warnings\nwarnings.filterwarnings('ignore',category=FutureWarning)\nimport numpy as np\nimport tensorflow as tf\n\n\ndef ln(inputs, epsilon = 1e-8, scope=\"ln\"):\n '''Applies layer normalization. See https://arxiv.org/abs/1607.06450.\n inputs: A tensor wi... | [
[
"tensorflow.convert_to_tensor",
"tensorflow.zeros",
"tensorflow.layers.dropout",
"tensorflow.cast",
"tensorflow.minimum",
"tensorflow.equal",
"tensorflow.nn.moments",
"tensorflow.layers.dense",
"numpy.sin",
"tensorflow.ones_initializer",
"tensorflow.to_float",
"tens... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
hongliuuuu/AutomobilePy | [
"085b42f98d37808da10879c7e744ffcd6d7990ef"
] | [
"pythonC/nms.py"
] | [
"# import the necessary packages\nimport numpy as np\n\n# Malisiewicz et al.\ndef non_max_suppression_fast(boxes, overlapThresh):\n\t# if there are no boxes, return an empty list\n\tif len(boxes) == 0:\n\t\treturn []\n\n\t# if the bounding boxes integers, convert them to floats --\n\t# this is important since we'll... | [
[
"numpy.argsort",
"numpy.where",
"numpy.maximum",
"numpy.minimum"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
cse75/Machine-Learning | [
"1279d2ea65fa7bbeb4d18ab80f7f77685df553b8"
] | [
"Plotting in Machine Learning with Python/cluster/plot_feature_agglomeration_vs_univariate_selection.py"
] | [
"\"\"\"\n==============================================\nFeature agglomeration vs. univariate selection\n==============================================\n\nThis example compares 2 dimensionality reduction strategies:\n\n- univariate feature selection with Anova\n\n- feature agglomeration with Ward hierarchical clust... | [
[
"matplotlib.pyplot.imshow",
"sklearn.model_selection.KFold",
"numpy.random.randn",
"numpy.exp",
"sklearn.pipeline.Pipeline",
"matplotlib.pyplot.subplot",
"matplotlib.pyplot.close",
"matplotlib.pyplot.subplots_adjust",
"scipy.linalg.norm",
"numpy.zeros",
"matplotlib.pypl... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [
"0.13",
"0.14",
"0.15",
"0.12",
"0.10"
],
"tensorflow": []
}
] |
EZoni/fbpic | [
"b50bfcdfba37a90af174d9febbe14f92338b0315"
] | [
"fbpic/particles/particles.py"
] | [
"# Copyright 2016, FBPIC contributors\n# Authors: Remi Lehe, Manuel Kirchen, Kevin Peters\n# License: 3-Clause-BSD-LBNL\n\"\"\"\nThis file is part of the Fourier-Bessel Particle-In-Cell code (FB-PIC)\nIt defines the structure and methods associated with the particles.\n\"\"\"\nimport warnings\nimport numpy as np\nf... | [
[
"numpy.zeros",
"numpy.empty"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Jdash99/des-inventory-simulation | [
"663b2cc07af938207032adb49d7abbc7c64f3637"
] | [
"psim/psim_plot.py"
] | [
"import numpy as np\n\nfrom matplotlib.figure import Figure\nfrom matplotlib.backends.backend_qt4agg import FigureCanvasQTAgg as FigureCanvas\n\n\nclass MatplotlibWidget(FigureCanvas):\n\n def __init__(self, parent=None):\n super(MatplotlibWidget, self).__init__(Figure())\n\n self.setParent(parent)... | [
[
"numpy.ones",
"matplotlib.backends.backend_qt4agg.FigureCanvasQTAgg",
"matplotlib.figure.Figure"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
MattiaCinelli/EuroNations-SQLitePy | [
"c09a3e3fe0067628f4e3b4f556f92dbde876f0e3"
] | [
"euronations/query_db.py"
] | [
"# Standard library\nimport os\n\n# Third imports\nimport random\nimport sqlite3\nimport numpy as np\nimport pandas as pd\n\nclass QueryDB:\n \"\"\"\n Download the db an save it in csv.\n \"\"\"\n def __init__(self, db: str = \"euronations.db\"):\n self.db = sqlite3.connect(db)\n\n def get_eur... | [
[
"pandas.read_sql_query"
]
] | [
{
"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": []
}
] |
zhefan/rl-baselines3-zoo | [
"beea1e535045e5799feaa412589fd8c664bbc15e"
] | [
"various_env.py"
] | [
"'''\nProject: rl-baselines3-zoo\nCreated Date: Monday, March 29th 2021, 1:12:38 am\nAuthor: Zhefan Ye <zhefanye@gmail.com>\n-----\nCopyright (c) 2021 TBD\nDo whatever you want\n'''\n\nimport os\n\nimport numpy as np\nimport gym\n\n\ndef check_path(input_path):\n if not os.path.exists(input_path):\n os.ma... | [
[
"numpy.array",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
anbarief/matplotlib-ex | [
"dd7ad749ac9a2653372edc7f6b088708fa6455dc"
] | [
"Examples/Sackboy Animation/sackboy_anim.py"
] | [
"#Copyright Arief Anbiya (2019)\n#E-mail: anbarief@live.com\n\nimport math\nimport random\n\nimport matplotlib.pyplot as plt\nimport matplotlib.font_manager as fm\nfrom matplotlib.animation import FuncAnimation\n\nsophia_regular_otf = \"Sofia-Regular.otf\"\nsophia_regular = fm.FontProperties(fname = sophia_regular_... | [
[
"matplotlib.pyplot.imread",
"matplotlib.pyplot.show",
"matplotlib.font_manager.FontProperties",
"matplotlib.pyplot.subplots"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
FlyingRoastDuck/UnrealPerson | [
"9fd5a882bea16f6289f0353b78140bff36c16609"
] | [
"CBN/utils/loss.py"
] | [
"from __future__ import absolute_import\nfrom __future__ import division\nfrom __future__ import print_function\nfrom __future__ import unicode_literals\nimport numpy as np\nimport torch,time\nfrom torch import nn\nimport torch.nn.functional as F\nimport random\n\n\ndef pairwise_loss(outputs, label1, seg,sigmoid_p... | [
[
"torch.nn.MarginRankingLoss",
"torch.norm",
"torch.zeros",
"torch.exp",
"torch.log",
"torch.sort",
"torch.nn.SoftMarginLoss",
"torch.masked_select",
"torch.pow"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
StarStar-666/TensorFlow | [
"ab5e2de04bc0930c4c3e11f69aee95f071c8df3f",
"ab5e2de04bc0930c4c3e11f69aee95f071c8df3f"
] | [
"train_mobilenetv2.py",
"image_demo_mobilenetv2.py"
] | [
"#! /usr/bin/env python\n# coding=utf-8\n\nimport os\nimport time\nimport shutil\nimport numpy as np\nimport tensorflow as tf\nimport core.utils as utils\nfrom tqdm import tqdm\nfrom core.dataset import Dataset\nfrom core.yolov3_mobilenetv2 import YOLOV3\nfrom core.config import cfg\n\nclass YoloTrain(object):\n ... | [
[
"tensorflow.control_dependencies",
"tensorflow.global_variables",
"tensorflow.train.ExponentialMovingAverage",
"numpy.mean",
"tensorflow.train.AdamOptimizer",
"tensorflow.summary.scalar",
"tensorflow.assign_add",
"tensorflow.Variable",
"tensorflow.get_collection",
"tensorfl... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
dbrg-deeplearning/CNN-MNIST | [
"0e763b1c7ac7922982fa8dff87bfb6fe274cd7c5"
] | [
"input_data.py"
] | [
"# Copyright 2015 Google Inc. 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... | [
[
"tensorflow.as_dtype",
"numpy.multiply",
"numpy.arange",
"numpy.dtype",
"numpy.random.shuffle",
"numpy.frombuffer",
"numpy.zeros"
]
] | [
{
"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... |
kkucharc/incubator-superset | [
"5199423ad19d30ee066dcfdb75c10f9c084a1250"
] | [
"superset/common/query_context.py"
] | [
"# Licensed to the Apache Software Foundation (ASF) under one\n# or more contributor license agreements. See the NOTICE file\n# distributed with this work for additional information\n# regarding copyright ownership. The ASF licenses this file\n# to you under the Apache License, Version 2.0 (the\n# \"License\"); y... | [
[
"pandas.to_datetime",
"pandas.to_numeric",
"pandas.DataFrame"
]
] | [
{
"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": []
}
] |
atudell/PyEye | [
"871098734ef7230750c489c9761fbcc5ba8788de"
] | [
"PyEye.py"
] | [
"import numpy as np\r\nimport cv2\r\n\r\ndef projectOnEyes(image_src, window_name = \"projectOnEyes\"):\r\n \r\n # Import the pre-trained models for face and eye detection\r\n face_cascade = cv2.CascadeClassifier(\"haarcascade_frontalface_default.xml\")\r\n eye_cascade = cv2.CascadeClassifier(\"haarcasc... | [
[
"numpy.array",
"numpy.dstack"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
twang9/unet_exp | [
"d492238ff785a179a49d4d65542443cd8c9d66d1"
] | [
"networks/RecursiveUNet3D.py"
] | [
"#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n#\n# Copyright 2017 Division of Medical Image Computing, German Cancer Research Center (DKFZ)\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 L... | [
[
"torch.nn.Sequential",
"torch.nn.Dropout",
"torch.cat",
"torch.nn.ConvTranspose3d",
"torch.nn.MaxPool3d",
"torch.nn.Conv3d",
"torch.nn.LeakyReLU"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ks8/conformation | [
"f470849d5b7b90dc5a65bab8a536de1d57c1021a"
] | [
"conformation/basic_metropolis.py"
] | [
"\"\"\" Run basic Metropolis-Hastings sampling. \"\"\"\r\nfrom logging import Logger\r\nimport numpy as np\r\nimport os\r\nimport time\r\nfrom typing_extensions import Literal\r\n\r\n# noinspection PyPackageRequirements\r\nfrom tap import Tap\r\nfrom tqdm import tqdm\r\n\r\nfrom conformation.funnel_sampler import f... | [
[
"numpy.random.uniform",
"numpy.random.normal",
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
chenyg1119/project-WP-QD | [
"5b9ca3621c0860792eb8f35dc48e1c55ef7066b8"
] | [
"tunneling2.py"
] | [
"import numpy as np\nimport matplotlib.pyplot as plt\nfrom numpy import linalg\nfrom matplotlib.widgets import Slider\n\nt=1\nd=2\ntheta = np.pi\n\nw = np.linspace(-4,4,200)\ndef b(value):\n m = np.empty([3,200])\n for i in range(200):\n m[0,i] = np.sort(np.roots([1,-2,-2-(w**2)[i],2*(w**2)[i]+2*w[i]*n... | [
[
"numpy.ones_like",
"numpy.linspace",
"numpy.cos",
"matplotlib.widgets.Slider",
"numpy.zeros_like",
"matplotlib.pyplot.show",
"numpy.empty",
"matplotlib.pyplot.figure"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Pandinosaurus/deep-motion-editing | [
"19604abdc0ead66f8c82d9211b8c5862c6a68089"
] | [
"utils/BVH.py"
] | [
"import re\r\nimport numpy as np\r\nimport sys\r\nsys.path.append(\"motion_utils\")\r\n\r\nfrom Animation import Animation\r\nfrom Quaternions_old import Quaternions\r\n\r\nchannelmap = {\r\n 'Xrotation' : 'x',\r\n 'Yrotation' : 'y',\r\n 'Zrotation' : 'z' \r\n}\r\n\r\nchannelmap_inv = {\r\n 'x': 'Xrot... | [
[
"numpy.append",
"numpy.array",
"numpy.radians"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
adityabingi/DCGAN-TF2.0 | [
"d527618c2fddc6cb5f1e0bc7654c48aa86d8c3e6"
] | [
"nets.py"
] | [
"import tensorflow as tf\nfrom config import Config\n\nb_init = tf.constant_initializer(0.0) #bias initializer\nw_init = tf.initializers.TruncatedNormal(stddev=0.02) #kernel_initializer\n\ndef ReLU():\t\n\n\treturn tf.keras.layers.ReLU()\n\ndef leaky_ReLU(leak=0.2):\n\n\treturn tf.keras.layers.LeakyReLU(alpha =leak... | [
[
"tensorflow.keras.layers.ReLU",
"tensorflow.keras.layers.LeakyReLU",
"tensorflow.keras.layers.Dense",
"tensorflow.keras.layers.Conv2DTranspose",
"tensorflow.keras.layers.Conv2D",
"tensorflow.reshape",
"tensorflow.nn.tanh",
"tensorflow.constant_initializer",
"tensorflow.keras.la... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
ChatCatKatzeNeko/PFam_classification | [
"90bb8f92eae5c9c4e86b84be866e9c9586e39c76"
] | [
"pkg/Models.py"
] | [
"# Pytorch packages\nimport torch\nfrom torch import nn, optim, tensor\nif torch.cuda.is_available(): \n device = torch.device(\"cuda\")\n print(f'There are {torch.cuda.device_count()} GPU(s) available.')\n print('Device name:', torch.cuda.get_device_name(0))\nelse:\n print('No GPU available, usin... | [
[
"torch.nn.CrossEntropyLoss",
"torch.transpose",
"torch.nn.LSTM",
"torch.cuda.device_count",
"torch.nn.Linear",
"torch.nn.Conv1d",
"numpy.mean",
"torch.no_grad",
"torch.cuda.is_available",
"torch.cuda.get_device_name",
"torch.device",
"torch.nn.ReLU",
"torch.argm... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
zohrehraziei/CS6140-Machine-Learning- | [
"d0f5a4766dfd86c7097ec4524441adaf4136a80b"
] | [
"src/PCA.py"
] | [
"\n\n\"\"\"\nPrincipal Component Analysis (PCA)\n\n@author: raziei.z@husky.neu.edu\n\n\"\"\"\n\n# In[1]:\n\n\nimport numpy as np\nimport scipy\nimport matplotlib.pyplot as plt\nimport pandas as pd\nimport seaborn as sns\nfrom sklearn.metrics import roc_auc_score,accuracy_score,roc_curve,auc\nimport random\nfrom sci... | [
[
"matplotlib.pyplot.legend",
"numpy.linspace",
"numpy.cumsum",
"matplotlib.pyplot.plot",
"numpy.mean",
"numpy.exp",
"numpy.where",
"pandas.read_csv",
"numpy.linalg.eig",
"numpy.size",
"pandas.set_option",
"numpy.zeros",
"numpy.log",
"matplotlib.pyplot.title",... | [
{
"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.