repo_name stringlengths 6 130 | hexsha list | file_path list | code list | apis list | possible_versions list |
|---|---|---|---|---|---|
tos-1/MUSCLE | [
"fd7e6115742028f324b28157344ed6bb7e3e6ade"
] | [
"muscle.py"
] | [
"import numpy as N\nimport cosmo\nimport pyfftw\nimport gadgetutils\nimport os\nimport warnings\nimport multiprocessing\n\n\nclass muscle(object):\n '''\n Inputs::\n cosmo: whether to use Eisenstein & Hu linear power spectrum ('ehu') or CLASS ('cls')\n h: normalized hubble rate\n omega_b: physi... | [
[
"numpy.minimum",
"numpy.sqrt",
"numpy.flipud",
"numpy.zeros_like",
"numpy.exp",
"numpy.where",
"numpy.reshape",
"numpy.arange",
"numpy.fft.irfftn",
"numpy.log",
"numpy.min",
"numpy.isnan",
"numpy.random.RandomState",
"numpy.conj",
"numpy.cos",
"numpy... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
fulmen27/SpectroFit | [
"75c170b9ac1c92fb592fc6ce1826bf4dd4409c93"
] | [
"spectrofit/tools/Interactive_Fit.py"
] | [
"import pyqtgraph as pg\nfrom PySide2.QtWidgets import QWidget, QGridLayout, QMenuBar, QAction\nfrom PySide2.QtGui import QPen\nfrom PySide2.QtCore import Slot, Qt\nimport json\n\nimport spectrofit.math.mathFunction as mF\n\nfrom spectrofit.ui.SliderGaussian import SliderGaussian\nfrom spectrofit.ui.SliderLorentz i... | [
[
"numpy.asarray"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Apidwalin/models-tensorflow | [
"b7000f7b156a30421d0e86b0bd0a7294f533280f"
] | [
"orbit/utils.py"
] | [
"# Copyright 2020 The Orbit Authors. All Rights Reserved.\r\n#\r\n# Licensed under the Apache License, Version 2.0 (the \"License\");\r\n# you may not use this file except in compliance with the License.\r\n# You may obtain a copy of the License at\r\n#\r\n# http://www.apache.org/licenses/LICENSE-2.0\r\n#\r\n# ... | [
[
"tensorflow.summary.create_noop_writer",
"tensorflow.summary.should_record_summaries",
"tensorflow.is_tensor",
"tensorflow.constant",
"tensorflow.range",
"tensorflow.Variable",
"tensorflow.config.get_soft_device_placement",
"tensorflow.config.set_soft_device_placement",
"tensor... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
raess1/robot-gym | [
"1e61ed388d4557e9bd5f8e2b83379ebce3c01081"
] | [
"robot_gym/gym/envs/go_to/path_follower/path.py"
] | [
"\"\"\"\nCredits: nplan\n\nhttps://github.com/nplan/gym-line-follower\n\"\"\"\nimport json\nimport random\n\nfrom shapely.geometry import LineString, MultiPoint, Point\nimport numpy as np\nfrom shapely.ops import nearest_points\n\nfrom robot_gym.gym.envs.go_to.path_follower.line_interpolation import interpolate_poi... | [
[
"numpy.dot",
"matplotlib.pyplot.imshow",
"numpy.linalg.norm",
"matplotlib.pyplot.savefig",
"numpy.ones",
"numpy.linalg.det",
"numpy.arctan2",
"numpy.concatenate",
"matplotlib.pyplot.subplot",
"matplotlib.pyplot.axis",
"numpy.array",
"numpy.where",
"matplotlib.py... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
linkinpark213/mmaction | [
"cd80ff1da17086e231a4197585986ea0f662a7c8"
] | [
"data_tools/climbing/crop_video_patches.py"
] | [
"import os\nimport cv2\nimport logging\nimport argparse\nimport numpy as np\n\n\ndef fill_gaps(track, target_id):\n logging.info('Gap-filling: Length before filling: {}'.format(len(track)))\n output_trajectory = []\n current_frame = -1\n for i in range(len(track)):\n if current_frame > -1 and tra... | [
[
"numpy.concatenate",
"numpy.array",
"numpy.convolve"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
mhearne-usgs/MapIO | [
"5d298c8dd12dbb0c5abb14227baafee1ce95ef82"
] | [
"test/grid2d_test.py"
] | [
"#!/usr/bin/env python\n\n# python 3 compatibility\nfrom __future__ import print_function\nimport os.path\nimport sys\nimport shutil\nimport time\n\n# stdlib imports\nimport abc\nimport textwrap\nimport glob\nimport os\nimport tempfile\n\n# hack the path so that I can debug these functions if I need to\nhomedir = o... | [
[
"numpy.arange",
"numpy.ones",
"numpy.testing.assert_almost_equal",
"numpy.random.rand",
"numpy.array",
"numpy.zeros",
"numpy.random.randint"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ashwin2rai/no_more_backlogs | [
"23439a6c8cf4ca68e67375048242c52cb79818c8"
] | [
"project_workdir/test_func.py"
] | [
"# Very basic unit testing for investigame package, run using pytest\n# > pytest\n\nimport numpy as np\n\nfrom investigame import GetWikiGameTable\nfrom investigame import PricingAndRevs\nfrom investigame import GetRedditComments\n\n\ndef test_table():\n WikiTable = GetWikiGameTable()\n df = WikiTable.get_wik... | [
[
"numpy.random.randint"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
xcgoner/AISTATS2020-AdaAlter-GluonNLP | [
"9c673ed5a7ec1c02eb5383f7403bf7f73a067a9e"
] | [
"scripts/language_model/large_word_language_model_hvd.py"
] | [
"\"\"\"\nLarge Word Language Model\n===================\n\nThis example shows how to build a word-level language model on Google Billion Words dataset\nwith Gluon NLP Toolkit.\nBy using the existing data pipeline tools and building blocks, the process is greatly simplified.\n\nWe implement the LSTM 2048-512 languag... | [
[
"numpy.random.seed"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
medric49/embeddings | [
"ba439e91991b127115a9fbb5477ace87b9056d45"
] | [
"train.py"
] | [
"import os\nimport random\nimport sys\nimport time\n\nimport numpy as np\nfrom gensim import models\n\n\ndef train(corpus, id, dim=100, window=5, negative=5, workers=8, log_dir=None, log_parent_dir='logs'):\n\n if log_dir is None:\n log_dir = f'{log_parent_dir}/model-{id}-{dim}-{window}-{negative}'\n\n ... | [
[
"numpy.dot",
"numpy.exp",
"numpy.mean"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
andry900/NN-Project | [
"e04a83029f5990d9b65216ab0648a8826a8ebca7"
] | [
"nnBuildUnits.py"
] | [
"'''\n * Building units for neural networks: conv23D units, residual units, unet units, upsampling unit and so on.\n * all kinds of loss functions: softmax, 2d softmax, 3d softmax, dice, multi-organ dice, focal loss, attention based loss...\n * kinds of test units\n * First implemented in Dec. 2016, and... | [
[
"torch.mean",
"torch.nn.functional.softmax",
"torch.abs",
"torch.nn.Dropout2d",
"numpy.sqrt",
"torch.cat",
"torch.sum",
"numpy.max",
"torch.nn.NLLLoss2d",
"torch.FloatTensor",
"torch.pow",
"torch.autograd.Variable",
"torch.nn.Dropout",
"torch.ones",
"tor... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
karbogas/traffic4cast | [
"cec5523a794df26c4a71723c866ad5d1443c2d94"
] | [
"utils/secondloader.py"
] | [
"# -*- coding: utf-8 -*-\n\"\"\"\nCreated on Wed Apr 1 15:37:18 2020\n\n@author: konst\n\nNOTE: Large parts of this code have been taken from the MIE lab code at https://github.com/mie-lab/traffic4cast\n\nChanges: Load the whole files at once\n\"\"\"\n\n\nimport torch\nfrom torchvision import datasets, transforms\... | [
[
"numpy.reshape",
"torch.from_numpy",
"torch.is_tensor",
"numpy.moveaxis",
"numpy.sum"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ninatu/everything_at_once | [
"b4cd3a70076ea3ea2b40832aa3e2afab50495c47"
] | [
"everything_at_once/dataset/crosstask_mining_dataset.py"
] | [
"from __future__ import absolute_import\nfrom __future__ import division\nfrom __future__ import unicode_literals\nfrom __future__ import print_function\n\nimport torch as th\nfrom torch.utils.data import Dataset\nimport pandas as pd\nimport os\nimport numpy as np\nimport json\nimport librosa\n\nfrom everything_at_... | [
[
"pandas.read_csv",
"torch.from_numpy",
"torch.stack",
"numpy.load",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
theleokul/AWR-Adaptive-Weighting-Regression | [
"a6c224302bab474db8b774a2d009c9497e32f6bd"
] | [
"util/feature_tool.py"
] | [
"import numpy as np\nimport torch\nfrom numpy import linalg\nfrom torch.nn import Module, Conv2d, Parameter, Softmax\nimport torch.nn.functional as F\nimport sys\nimport cv2\n\n# generate dense offsets feature \nclass FeatureModule:\n\n def joint2offset(self, jt_uvd, img, kernel_size, feature_size):\n '''... | [
[
"torch.nn.functional.softmax",
"torch.cat",
"torch.nn.functional.interpolate",
"torch.arange",
"torch.stack",
"torch.pow"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
GoodManWEN/Language-Benchmarks-Visualization | [
"70989ee003a443c87aa332a06321e974783d31bb"
] | [
"update_and_render.py"
] | [
"import sys\nimport os\nimport time\nimport json\nimport math\nimport datetime\nimport base64\nimport pandas as pd\nimport requests\nfrom PIL import Image\nfrom PIL.PngImagePlugin import PngImageFile\nfrom bs4 import BeautifulSoup\nfrom pipeit import *\nfrom typing import List, Set, Dict\nfrom io import BytesIO\nfr... | [
[
"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": []
}
] |
proModeLife/Control-Theory | [
"dac8377bc166d1bd47381c77a2a8732790d94ebc"
] | [
"resources/simulation.py"
] | [
"import cv2\nimport math\nimport numpy as np\nimport matplotlib.pyplot as plt\n\nfrom tqdm import tqdm\nfrom control import controller\nfrom numpy.linalg import inv\nfrom resources.physics import M, F\ndef simulate():\n\n def T(q,qd,t,trajectories):\n q1 = q[0][0]\n q2 = q[1][0]\n w1 = qd[0]... | [
[
"numpy.array",
"numpy.ones"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
anveshpothula/rasa | [
"4211b92b029779b191c2ede67f12f8646accba79"
] | [
"rasa/core/policies/embedding_policy.py"
] | [
"import copy\nimport json\nimport logging\nimport os\nimport pickle\n\nimport numpy as np\nfrom typing import Any, List, Optional, Text, Dict, Tuple\n\nimport rasa.utils.io\nfrom rasa.core.domain import Domain\nfrom rasa.core.featurizers import (\n TrackerFeaturizer,\n FullDialogueTrackerFeaturizer,\n Labe... | [
[
"tensorflow.Graph",
"numpy.expand_dims",
"tensorflow.constant",
"tensorflow.reduce_max",
"numpy.random.seed",
"numpy.asarray",
"tensorflow.placeholder_with_default",
"tensorflow.placeholder",
"numpy.stack",
"tensorflow.train.import_meta_graph",
"tensorflow.Session",
... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
sytk/glow-pytorch-1 | [
"e3f7cb199a0e2970b285d62d6e33daf749c30af3"
] | [
"glow/builder.py"
] | [
"import re\nimport os\nimport copy\nimport torch\nfrom collections import defaultdict\nfrom .import learning_rate_schedule\nfrom .config import JsonConfig\nfrom .models import Glow\nfrom .utils import load, save, get_proper_device\n\n\ndef build_adam(params, args):\n return torch.optim.Adam(params, **args)\n\n\n... | [
[
"torch.optim.Adam",
"torch.is_tensor"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
BaoLocPham/hum2song | [
"3e0e093a600fbfe5dc670c1c3194971429795f6f"
] | [
"utils/visualize_mel.py"
] | [
"import numpy as np\nimport yaml\nimport argparse\nimport os\nimport random\nimport matplotlib.pyplot as plt\n\ndef save_img(path, spec_song=None, spec_hum=None):\n if spec_song is None or spec_hum is None:\n if spec_song is not None:\n plt.imshow(spec_song, origin=\"lower\")\n plt.t... | [
[
"matplotlib.pyplot.imshow",
"matplotlib.pyplot.title",
"matplotlib.pyplot.ylim",
"matplotlib.pyplot.subplots",
"matplotlib.pyplot.savefig",
"matplotlib.pyplot.close"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
udapy/CarND-Behavioral-Cloning-P3 | [
"c2d65595e779bb0bb8881917348642f33ea9101b"
] | [
"model.py"
] | [
"#Importing libraries\nimport os\nimport numpy as np\nimport cv2\nimport sklearn\nfrom sklearn.preprocessing import LabelBinarizer\nfrom sklearn.utils import shuffle\nfrom sklearn.model_selection import train_test_split\nfrom keras.models import Sequential\nfrom keras.layers.core import Dense, Flatten, Activation, ... | [
[
"sklearn.utils.shuffle",
"numpy.array",
"sklearn.model_selection.train_test_split"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
BrunoGeorgevich/Cardiovascular | [
"4cee0a72e287f8d27bd52ff2610da32f646bbc24"
] | [
"Projeto 1/main.py"
] | [
"# -*- coding: utf-8 -*-\n\n\"\"\"\nCreated on Fri Jun 13 15:44:58 2019\n\n@author: Bruno Georgevich Ferreira\n\"\"\"\n\nimport numpy as np\nimport matplotlib.pyplot as plt\n\n#Constantes\nEmax = 2\nEmin = 0.06\nHR = 75\n\nRs = 1\nRm = 0.005\nRa = 0.001\nRc = 0.0398\n\nCr = 4.4\nCs = 1.33\nCa = 0.08\nLs = 0.0005\nV... | [
[
"matplotlib.pyplot.legend",
"matplotlib.pyplot.title",
"matplotlib.pyplot.figure",
"matplotlib.pyplot.plot",
"matplotlib.pyplot.subplot",
"matplotlib.pyplot.grid",
"matplotlib.pyplot.xlabel",
"numpy.array",
"matplotlib.pyplot.show",
"matplotlib.pyplot.ylabel"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
odotreppe/scikit-learn-mooc | [
"c3aaf8c5a9aa4f1d749ebc1b7d5ae24619fee4bf",
"c3aaf8c5a9aa4f1d749ebc1b7d5ae24619fee4bf"
] | [
"python_scripts/02_numerical_pipeline_ex_00.py",
"python_scripts/linear_models_sol_03.py"
] | [
"# -*- coding: utf-8 -*-\n# ---\n# jupyter:\n# jupytext:\n# text_representation:\n# extension: .py\n# format_name: percent\n# format_version: '1.3'\n# jupytext_version: 1.10.3\n# kernelspec:\n# display_name: Python 3\n# language: python\n# name: python3\n# ---\n\n# %% [ma... | [
[
"pandas.read_csv"
],
[
"matplotlib.pyplot.title",
"pandas.DataFrame",
"sklearn.datasets.fetch_california_housing",
"sklearn.linear_model.LinearRegression",
"sklearn.model_selection.cross_validate"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [
"0.23",
"0.21",
"2.0",
"1.4",
"0.19",
... |
RowanAI/BayesianDefense | [
"c4c0be9b258f40130b40d6a6e009c459666f2722"
] | [
"snr_density.py"
] | [
"import argparse\nimport torch\nimport torch.nn as nn\n\nimport matplotlib.pyplot as plt\nimport seaborn as sns\nimport numpy as np\n\n# arguments\nparser = argparse.ArgumentParser(description='Density plot')\nparser.add_argument('--model', type=str, required=True)\nparser.add_argument('--defense', type=str, requir... | [
[
"torch.load"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ahu-hpt/AOMD | [
"8d99dbb803feaef55fc089bfb3399d2fb21d55d8"
] | [
"model/backbone/inception/google.py"
] | [
"import os\nimport torch\nimport torch.nn as nn\nimport h5py\n\nfrom collections import OrderedDict\nfrom torchvision.datasets.utils import download_url\n\n__all__ = [\"GoogleNet\"]\n\n\nclass GoogleNet(nn.Sequential):\n output_size = 1024\n input_side = 227\n rescale = 255.0\n rgb_mean = [122.7717, 115... | [
[
"torch.nn.Conv2d",
"torch.from_numpy",
"torch.nn.CrossMapLRN2d",
"torch.nn.MaxPool2d",
"torch.nn.AvgPool2d",
"torch.nn.ReLU"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
mikiec84/linkshop | [
"72959ceca0003be226edeca6496f915502831596"
] | [
"linkograph/stats.py"
] | [
"#!/usr/bin/env python3\n\n\"\"\"Statistics package for linkographs.\"\"\"\n\nfrom collections import Counter\nfrom functools import reduce\nfrom linkograph import linkoCreate\nimport math # For logs\nimport argparse # For command line parsing.\nimport json\nimport numpy\n\ndef similarity(lg_0, lg_1):\n underli... | [
[
"numpy.std",
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
health-vision/CenterTrack | [
"9f4621f5cfdd0242991a87278a24068eb0a21e63"
] | [
"src/lib/dataset/generic_dataset.py"
] | [
"from __future__ import absolute_import\nfrom __future__ import division\nfrom __future__ import print_function\n\nimport copy\nimport math\nimport os\nfrom collections import defaultdict\n\nimport cv2\nimport numpy as np\nimport pycocotools.coco as coco\nimport torch.utils.data as data\n\nfrom ..utils.image import... | [
[
"numpy.maximum",
"numpy.random.random",
"numpy.clip",
"numpy.arange",
"numpy.cos",
"numpy.sin",
"numpy.random.randn",
"numpy.array",
"numpy.zeros",
"numpy.random.RandomState",
"numpy.random.randint"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Vatsal241212/Open-Api | [
"302e4c5a779840fb215a9f3ddb6d46cf8bbb4efc"
] | [
"Flask Backend.py"
] | [
"from flask import *\nimport keras2onnx\nfrom tensorflow import keras\nimport tensorflow as tf\nimport onnx\nfrom google.protobuf.json_format import MessageToJson\nimport json\nfrom torch.autograd import Variable\nimport torch.onnx as torch_onnx\nfrom onnx_tf.backend import prepare\nimport torch\nfrom keras.utils i... | [
[
"tensorflow.keras.models.load_model",
"torch.onnx.export",
"torch.nn.LogSoftmax",
"tensorflow.lite.TFLiteConverter.from_keras_model",
"torch.load",
"torch.randn",
"torch.nn.Linear",
"tensorflow.lite.TFLiteConverter.from_saved_model",
"torch.nn.ReLU"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
gw2015tylerdurden/gw-deep | [
"214f3e4df91a32ecae8811a171b45207ead4004c"
] | [
"src/nn/models/vae.py"
] | [
"import torch\nimport torch.nn as nn\nimport torch.nn.functional as F\nfrom collections import abc\n\nfrom .basic import *\n\n\n__all__ = [\"VAE\"]\n\n\nclass VAE(BaseModule):\n def __init__(self, in_channels: int = 3, z_dim: int = 512, msize: int = 7):\n super().__init__()\n self.encoder = Encoder... | [
[
"torch.nn.functional.binary_cross_entropy_with_logits",
"torch.pow"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
titaneric/optnet | [
"d0aaa98de24b89337295749ec768bc555a979894"
] | [
"sudoku/true-Qpenalty-errors.py"
] | [
"#!/usr/bin/env python3\n\nimport torch\nfrom torch.autograd import Variable\n\nimport numpy as np\n\nimport matplotlib as mpl\nmpl.use('Agg')\nimport matplotlib.pyplot as plt\nplt.style.use('bmh')\n\nimport models\nfrom train import computeErr\n\nbatchSz = 128\n\nboards = {}\nfor boardSz in (2,3):\n with open('... | [
[
"torch.max",
"numpy.linspace",
"torch.load",
"matplotlib.use",
"numpy.concatenate",
"numpy.mean",
"matplotlib.pyplot.style.use"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
uiuc-arc/FANC | [
"19aad400b62ccfbaa7376d0f3b9a6d88f084f023"
] | [
"proof_transfer/overview.py"
] | [
"\nimport matplotlib.pyplot as plt\nimport matplotlib.patches as patches\nimport matplotlib.lines as lines\nimport copy\n\ncolors = ['#D5B4AB', '#DFE780', '#80E7E1']\n\n# x1 = [0.05, 0.35]\n# x2 = [0.1, 0.2]\n# x3 = [0.225, 0.275]\n\nx1 = [0, 0.35]\nx2 = [0.1, 0.3]\nx3 = [0.3, 0.4]\n\n\ndef template():\n N = NN(... | [
[
"matplotlib.pyplot.ylim",
"matplotlib.patches.Rectangle",
"matplotlib.lines.Line2D",
"matplotlib.pyplot.xlim",
"matplotlib.pyplot.figure"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
NickMacro/heroku-streamlit-learning | [
"1ef800e5827b7ccd814a0bd5f621e50d33a15ad3"
] | [
"app.py"
] | [
"import streamlit as st\n# To make things easier later, we're also importing numpy and pandas for\n# working with sample data.\nimport numpy as np\nimport pandas as pd\n\nst.title('My second app')\n\nst.write(\"Here's our first attempt at using data to create a table:\")\nst.write(pd.DataFrame({\n 'first column'... | [
[
"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": []
}
] |
everydaycodings/handwritten-digits-recognition | [
"85c039f265050f7d9e5b118334372374dea8ae05"
] | [
"handwritten_digits_recognition.py"
] | [
"import os\nimport cv2\nimport numpy as np\nimport tensorflow as tf\nimport matplotlib.pyplot as plt\n\nprint(\"Welcome to the everydaycodings (c) Handwritten Digits Recognition v0.2\")\n\n# Decide if to load an existing model or to train a new one\ntrain_new_model = False\n\nif train_new_model:\n # Loading the ... | [
[
"tensorflow.keras.models.load_model",
"matplotlib.pyplot.imshow",
"tensorflow.keras.layers.Dense",
"tensorflow.keras.utils.normalize",
"numpy.argmax",
"numpy.array",
"matplotlib.pyplot.show",
"tensorflow.keras.models.Sequential",
"tensorflow.keras.layers.Flatten"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"2.7",
"2.2",
"2.3",
"2.4",
"2.5",
"2.6"
]
}
] |
yhust/lacs | [
"c358c62a4e3be450becce173f5453eee615f8c80"
] | [
"python/MicrobenchSearch.py"
] | [
"from generate_microbench_rates import generate_microbench_rates\nimport numpy as np\nfrom isolation import get_iso_latency\nfrom lacs import lacs\nfrom mm_default import mm_default\nimport os\n\n\nrate1 = 20.0\nfilenumber = 100\nfor rate2 in range(26,37):\n\n generate_microbench_rates(filenumber, rate1, rate2)\... | [
[
"numpy.zeros",
"numpy.ones"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ayakut16/alpha-zero-connect4 | [
"2c0f0a861808cb964ecc499177a4d2e96ff905fa"
] | [
"Arena.py"
] | [
"import numpy as np\nfrom pytorch_classification.utils import Bar, AverageMeter\nimport time\nfrom connect4.Connect4Constants import Connect4Constants as constants\nimport pygame\n\nBLUE = (0,0,255)\nRED = (220,20,60)\nYELLOW = (255,255,0)\nWHITE = (255,255,255)\nBLACK = (0,0,0)\nP1_PIECE = 1\nP2_PIECE = -1\nclass ... | [
[
"numpy.flip"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
KECB/learn | [
"5b52c5c3ac640dd2a9064c33baaa9bc1885cf15f"
] | [
"computer_vision/05_border_types.py"
] | [
"import numpy as np\nimport cv2\nimport matplotlib.pyplot as plt\n\n\"\"\"\n在过滤(filtering)图片时, Border 类型对于保持图片大小起决定作用. 因为 filters 会扩展图片的\n边界(edge). \n\"\"\"\n\nimg = cv2.imread('images/leaves.png')\nred = [0, 0, 255] # boarder color\n\n# Border 类型\n# cv2.BORDER_REPLICATE - Last element is replicated throughout for... | [
[
"matplotlib.pyplot.imshow",
"matplotlib.pyplot.yticks",
"matplotlib.pyplot.title",
"matplotlib.pyplot.subplot",
"matplotlib.pyplot.xticks",
"matplotlib.pyplot.show"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Mukeshka/streamlit | [
"911cfce9ab7b1c0d9b40520ed454213ebf13940b"
] | [
"tommy.py"
] | [
"\nimport streamlit as st\nimport numpy as np\nfrom sklearn import preprocessing\nimport pandas as pd\n#from sklearn.cluster import KMeans\n#from sklearn.preprocessing import StandardScaler\nfrom sklearn import svm\nfrom sklearn.model_selection import train_test_split\nfrom sklearn.tree import DecisionTreeClassifie... | [
[
"pandas.read_excel",
"sklearn.linear_model.LogisticRegression",
"sklearn.model_selection.train_test_split",
"sklearn.tree.DecisionTreeClassifier",
"sklearn.ensemble.AdaBoostClassifier",
"sklearn.svm.SVC"
]
] | [
{
"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": []
}
] |
walterkissling/trading_calendars | [
"5ef2fd919be8d0cb2d6f53eb417d1959a92272d6"
] | [
"trading_calendars/futures_calendar.py"
] | [
"# for setting our open and close times\nfrom datetime import time\n# for setting our start and end sessions\nimport pandas as pd\n# for setting which days of the week we trade on\nfrom pandas.tseries.offsets import CustomBusinessDay\nfrom pandas.tseries.holiday import Holiday\n# for setting our timezone\nfrom pytz... | [
[
"pandas.tseries.offsets.CustomBusinessDay",
"pandas.Timestamp"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
RAV10K1/med_cab_test | [
"51e5673d25cb1c0e04344940c76d13b101828774"
] | [
"app/model.py"
] | [
"import pickle\nimport pandas as pd\nfrom sklearn.neighbors import NearestNeighbors\nfrom sklearn.feature_extraction.text import TfidfVectorizer\nfrom spacy.lang.en import English\n\n\n# NLP Based Recommendation Bot - Courtesy Curdt Million and Ravi Tennekone\n\nKNN = \"KNN_Model.pkl\"\nCNN = \"CNN_Model.pkl\"\ndat... | [
[
"pandas.read_csv",
"sklearn.feature_extraction.text.TfidfVectorizer"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
davidpetra/covid19-sir | [
"813bc66f668a3d2945dc97474ea1149bbc6e40c2",
"813bc66f668a3d2945dc97474ea1149bbc6e40c2"
] | [
"covsirphy/phase/phase_series.py",
"covsirphy/cleaning/covid19datahub.py"
] | [
"#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n\nimport numpy as np\nimport pandas as pd\nfrom covsirphy.util.error import deprecate\nfrom covsirphy.util.term import Term\nfrom covsirphy.phase.phase_unit import PhaseUnit\n\n\nclass PhaseSeries(Term):\n \"\"\"\n A series of phases.\n\n Args:\n firs... | [
[
"pandas.concat",
"pandas.DataFrame",
"pandas.DataFrame.from_dict"
],
[
"pandas.concat"
]
] | [
{
"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... |
kimhaggie/torchdiffeq | [
"ebada7130a4c215b95dd2dfd35bd8b092ef324f8"
] | [
"torchdiffeq/_impl/misc.py"
] | [
"from enum import Enum\nimport math\nimport numpy as np\nimport torch\nimport warnings\nfrom .event_handling import combine_event_functions\n\n\ndef _handle_unused_kwargs(solver, unused_kwargs):\n if len(unused_kwargs) > 0:\n warnings.warn('{}: Unexpected arguments {}'.format(solver.__class__.__name__, un... | [
[
"torch.abs",
"torch.ones",
"torch.max",
"torch.cat",
"torch.is_floating_point",
"torch.min",
"torch.is_tensor",
"torch.tensor",
"torch.no_grad",
"torch.nextafter",
"numpy.nextafter",
"torch.as_tensor"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
SanGreel/gpt-2-simple | [
"3d891cae321931d3a2a1503387628e4a4215c1ae"
] | [
"gpt_2_simple/gpt_2.py"
] | [
"import tarfile\nimport os\nimport json\nimport requests\nimport sys\nimport shutil\nimport re\nfrom tqdm import tqdm, trange\nimport numpy as np\nimport tensorflow as tf\nfrom tensorflow.core.protobuf import rewriter_config_pb2\nfrom tensorflow.python.client import device_lib\nimport time\nfrom datetime import dat... | [
[
"tensorflow.python.client.device_lib.list_local_devices",
"numpy.mean",
"tensorflow.compat.v1.train.Saver",
"tensorflow.summary.scalar",
"tensorflow.compat.v1.train.AdamOptimizer",
"tensorflow.gradients",
"tensorflow.compat.v1.trainable_variables",
"tensorflow.compat.v1.set_random_... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
cog-isa/htm-rl | [
"baf5b67a11283d37165bf6a29d6808a234d6d98c",
"baf5b67a11283d37165bf6a29d6808a234d6d98c"
] | [
"htm_rl/htm_rl/common/sdr_encoders.py",
"htm_rl/htm_rl/agents/hima/elementary_actions.py"
] | [
"from typing import List, Any, Sequence, Tuple\n\nimport numpy as np\n\nfrom htm_rl.common.sdr import SparseSdr\nfrom htm_rl.common.utils import isnone\n\n\nclass IntBucketEncoder:\n \"\"\"\n Encodes integer values from the range [0, `n_values`) as SDR with `output_sdr_size` total bits.\n SDR bit space is ... | [
[
"numpy.linspace",
"numpy.arange",
"numpy.cumsum",
"numpy.flatnonzero",
"numpy.concatenate",
"numpy.argpartition",
"numpy.prod",
"numpy.array",
"numpy.zeros",
"numpy.empty",
"numpy.random.default_rng"
],
[
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
VladimirSiv/datyy | [
"4f3b54557850212ca3ce4c0d16cd56eb9989d7c4"
] | [
"datyy/views/projects.py"
] | [
"import dash\nimport dash_html_components as html\nimport dash_bootstrap_components as dbc\nimport numpy as np\nfrom server import app\nfrom dash.dependencies import Input, Output, State\nfrom dash.exceptions import PreventUpdate\nfrom components.cards import simple_info_card\nfrom components.dropdowns import dropd... | [
[
"numpy.random.randint"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
LiuShang-777/single_cnn | [
"bae5d723fe1e65424de00967d212c0d89b09dc6a",
"bae5d723fe1e65424de00967d212c0d89b09dc6a"
] | [
"06deeplift_visual.py",
"01single_detect.py"
] | [
"# -*- coding: utf-8 -*-\r\n\"\"\"\r\nCreated on Tue Sep 15 16:18:46 2020\r\n\r\n@author: liushang\r\n\"\"\"\r\nimport pandas as pd\r\nimport numpy as np\r\nimport matplotlib.pyplot as plt\r\nimport os\r\nimport sys\r\n#plt.rcParams['font.family']='Times New Roman'\r\nprefix=sys.argv[1]\r\nfile=[i for i in os.listd... | [
[
"matplotlib.pyplot.text",
"matplotlib.pyplot.legend",
"matplotlib.pyplot.tight_layout",
"matplotlib.pyplot.title",
"numpy.arange",
"numpy.load",
"matplotlib.pyplot.savefig",
"matplotlib.pyplot.plot",
"matplotlib.pyplot.ylabel",
"matplotlib.pyplot.clf",
"matplotlib.pyplo... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"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",
"... |
DrexelLagare/Senior-Design-1 | [
"fbe6c83136682d885276c65a80bff7f7bd738567"
] | [
"Object Tracking/target_A.py"
] | [
"from scipy.spatial import distance as dist\nimport numpy as np\nimport cv2\nimport imutils\nimport tello_drone as tello\nimport time\n\n\nhost = ''\nport = 9000\nlocal_address = (host, port)\n\n# Pass the is_dummy flag to run the face detection on a local camera\ndrone = tello.Tello(host, port, is_dummy=False)\n\... | [
[
"numpy.int0",
"numpy.array",
"scipy.spatial.distance.euclidean"
]
] | [
{
"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"
... |
mmaguero/twitter-analysis | [
"c7517a9d4a19af4a8c79ba85c1e5806f4a9ae6b8"
] | [
"get_stats.py"
] | [
"# import\nimport pandas as pd\nimport sys\nimport glob\nimport dask.dataframe as dd\nimport matplotlib.pyplot as plt\nfrom utils import get_spain_places\nimport re\n\n# args\nraw_tweet_dir = sys.argv[1] # data path\nscope = sys.argv[2] # SPA\n\n# read files\n# tweets\nall_files = glob.glob(raw_tweet_dir + \"/ours_... | [
[
"pandas.merge",
"pandas.to_datetime"
]
] | [
{
"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": []
}
] |
CircleXing001/DL-tools | [
"1f49101f51e31bd8e361efc46b3b8d4ffe9497b7"
] | [
"mnist/GPU/keras_mnist.py"
] | [
"import time\r\nfrom keras.models import Sequential\r\nfrom keras.layers.core import Dense, Dropout, Activation, Flatten,Reshape\r\nfrom keras.layers.convolutional import Convolution2D, MaxPooling2D \r\nfrom tensorflow.examples.tutorials.mnist import input_data \r\nmnist = input_data.read_data_sets(\"MNIST_data/\"... | [
[
"tensorflow.examples.tutorials.mnist.input_data.read_data_sets"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10",
"1.12",
"1.4",
"1.13",
"1.5",
"1.7",
"0.12",
"1.0",
"1.2"
]
}
] |
AswinRetnakumar/Machina | [
"6519935ca4553192ac99fc1c7c1e7cab9dd72693",
"6519935ca4553192ac99fc1c7c1e7cab9dd72693"
] | [
"machina/algos/gail.py",
"example/run_airl.py"
] | [
"\"\"\"\nThis is an implementation of Generative Adversarial Imiation Learning\nSee https://arxiv.org/abs/1606.03476\n\"\"\"\n\nimport torch\nimport torch.nn as nn\nimport torch.nn.functional as F\n\nfrom machina import loss_functional as lf\nfrom machina import logger\nfrom machina.algos import trpo, ppo_kl, ppo_c... | [
[
"torch.no_grad"
],
[
"numpy.random.seed",
"torch.manual_seed",
"numpy.mean",
"torch.device",
"numpy.sum"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
jgd10/pymapdl | [
"6ac4d19f74d6488da70e16e475e31f51ef41b108"
] | [
"ansys/mapdl/core/post.py"
] | [
"\"\"\"Post-processing module using MAPDL interface\"\"\"\nimport re\nimport weakref\n\nimport numpy as np\n\nfrom ansys.mapdl.core.plotting import general_plotter\nfrom ansys.mapdl.core.errors import MapdlRuntimeError\nfrom ansys.mapdl.core.misc import supress_logging\n\n\nCOMPONENT_STRESS_TYPE = ['X', 'Y', 'Z', '... | [
[
"numpy.argsort",
"numpy.in1d",
"numpy.linalg.norm",
"numpy.vstack"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Mistobaan/mesh | [
"3d4d619afd1bf2b3952879fe73123d5bd4118b9d"
] | [
"examples/mnist_dataset.py"
] | [
"# coding=utf-8\n# Copyright 2020 The Mesh TensorFlow Authors.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless requ... | [
[
"tensorflow.compat.v1.to_int32",
"tensorflow.compat.v1.decode_raw",
"tensorflow.compat.v1.gfile.Exists",
"tensorflow.compat.v1.reshape",
"tensorflow.compat.v1.gfile.Open",
"numpy.dtype",
"tensorflow.compat.v1.data.Dataset.zip",
"tensorflow.compat.v1.data.FixedLengthRecordDataset",
... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
MrMistrOY/Photogrammetry_Toolbox | [
"abffbbe437dd8bd33ff6935ab18dadd3cf22af9a"
] | [
"photogrammetry_toolbox/model/retina/model.py"
] | [
"import torch\nimport torch.nn as nn\nfrom torchvision.models import resnet\nfrom torchvision.models._utils import IntermediateLayerGetter\nfrom torchvision.ops import FeaturePyramidNetwork, nms\nfrom torchvision.ops.feature_pyramid_network import LastLevelP6P7\n\nfrom photogrammetry_toolbox.model.retina.anchors im... | [
[
"torch.load",
"torch.zeros",
"torch.cat",
"torch.nn.Conv2d",
"torch.nn.Sigmoid",
"torch.tensor",
"torch.cuda.is_available",
"torch.nn.ReLU"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Dhruv-Mohan/Super_TF | [
"c693663adc59947cb7d15bd42ff260b7d3de6bdc"
] | [
"Super_TF/Model_builder/Architecture/Classification/Inception_resnet_v2a.py"
] | [
"from utils.builder import Builder\nimport tensorflow as tf\nfrom utils.Base_Archs.Base_Classifier import Base_Classifier\n\nclass Inception_resnet_v2a(Base_Classifier):\n \"\"\"Inception_Resnet_v2 as written in tf.slim\"\"\"\n\n def __init__(self, kwargs):\n super().__init__(kwargs)\n self.buil... | [
[
"tensorflow.clip_by_global_norm",
"tensorflow.variable_scope",
"tensorflow.name_scope",
"tensorflow.nn.softmax_cross_entropy_with_logits_v2",
"tensorflow.trainable_variables",
"tensorflow.add_n"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
bhklab/med-imagetools | [
"0cce0ee6666d052d4f76a1b6dc5d088392d309f4"
] | [
"imgtools/utils/imageutils.py"
] | [
"import SimpleITK as sitk\nimport numpy as np\n\ndef physical_points_to_idxs(image, points, continuous=False):\n if continuous:\n transform = image.TransformPhysicalPointToContinuousIndex\n else:\n transform = image.TransformPhysicalPointToIndex\n \n vectorized_transform = np.vectorize(lam... | [
[
"numpy.ma.masked_where",
"matplotlib.pyplot.subplots"
]
] | [
{
"matplotlib": [],
"numpy": [
"1.10",
"1.12",
"1.11",
"1.19",
"1.13",
"1.16",
"1.9",
"1.18",
"1.20",
"1.7",
"1.15",
"1.14",
"1.17",
"1.8"
],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
JiYuanFeng/MCTrans | [
"9b8b5677eef584b423d5e1630680a4b667cbe823"
] | [
"mctrans/models/decoders/unet_plus_plus_decoder.py"
] | [
"from collections import OrderedDict\n\nimport torch\nimport torch.nn as nn\n\nfrom ..utils import conv_bn_relu\nfrom ..builder import DECODERS\n\n\nclass AttBlock(nn.Module):\n def __init__(self, F_g, F_l, F_int):\n super(AttBlock, self).__init__()\n self.W_g = nn.Sequential(\n nn.Conv2... | [
[
"torch.cat",
"torch.nn.ModuleList",
"torch.nn.Conv2d",
"torch.nn.ModuleDict",
"torch.nn.Sigmoid",
"torch.nn.Upsample",
"torch.nn.BatchNorm2d",
"torch.nn.ReLU"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
kding1225/TDTS-visdrone | [
"733f51245a86658bbc09c6d86a585f84a6e4c6d1"
] | [
"fcos_core/data/transforms/transforms.py"
] | [
"# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved.\nimport random\nimport numpy as np\nimport math\nimport cv2\n\nimport torch\nimport torchvision\nfrom torchvision.transforms import functional as F\n\n\nclass Compose(object):\n def __init__(self, transforms):\n self.transforms = tra... | [
[
"numpy.minimum",
"numpy.maximum",
"numpy.clip",
"numpy.arange",
"numpy.copy",
"numpy.random.uniform",
"numpy.array",
"numpy.zeros",
"numpy.sum"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
54isb/FDMA | [
"e8aedb7651c62e0b0d02fb813458ec3feff2d40a"
] | [
"audio_FDMA_QPSK.py"
] | [
"import numpy as np\nimport warnings\nimport matplotlib.pyplot as plt\nimport pyaudio\nimport matplotlib as mpl\nfrom time import sleep\nfrom scipy import signal\nmpl.rcParams['toolbar'] = 'None'\n#Default parameters *****************************************\nwarnings.filterwarnings('ignore')\nSOUND_OUT = 1 #AUDIO ... | [
[
"numpy.convolve",
"numpy.imag",
"numpy.sqrt",
"numpy.power",
"numpy.arange",
"numpy.cos",
"numpy.sin",
"numpy.bitwise_xor",
"numpy.size",
"numpy.real",
"numpy.zeros",
"numpy.random.randint"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
MatthewDaggitt/PathVision | [
"93880bb21bc3b52ce7a7ecc0e5bd7bc1289718cd"
] | [
"modules/shared/graphFrame.py"
] | [
"import math\nfrom collections import defaultdict\n\nimport tkinter\nimport networkx as nx\nimport matplotlib\nmatplotlib.use('TkAgg')\nfrom matplotlib.backends.backend_tkagg import FigureCanvasTkAgg\nimport matplotlib.pyplot as plt\n\nfrom settings import NODE_SIZE, NODE_COLOUR, SOURCE_NODE_COLOUR, NODE_LABEL_OFFS... | [
[
"matplotlib.use",
"matplotlib.pyplot.figure",
"matplotlib.pyplot.subplots_adjust",
"matplotlib.pyplot.axis",
"matplotlib.backends.backend_tkagg.FigureCanvasTkAgg"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Bhaskers-Blu-Org1/model-sanitization | [
"1eff7e9f35e4fd194ffc83a55e4f6688ca9bb5c3",
"1eff7e9f35e4fd194ffc83a55e4f6688ca9bb5c3"
] | [
"error-injection/injection_cifar/evalacc.py",
"Hessian/models/c1.py"
] | [
"import torch\r\nimport torch.nn as nn\r\nimport torch.optim as optim\r\nimport torch.nn.functional as F\r\nimport torch.backends.cudnn as cudnn\r\n\r\nimport numpy as np\r\nimport torchvision\r\nimport torchvision.transforms as transforms\r\nimport data\r\nimport os\r\nimport argparse\r\nimport utils\r\nfrom tqdm ... | [
[
"torch.nn.CrossEntropyLoss",
"torch.load",
"torch.utils.data.DataLoader",
"numpy.mean",
"numpy.load"
],
[
"torch.nn.Dropout",
"torch.nn.Dropout2d",
"torch.nn.Conv2d",
"torch.nn.Linear",
"torch.nn.BatchNorm2d"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
megamaz/pythonBaseMath | [
"1427343927954c801e9e334170bc23df0ed47eee"
] | [
"BaseMath/__init__.py"
] | [
"\"\"\"Allows you to do math in any base.\"\"\"\nfrom __future__ import annotations\n\nimport sys\nimport numpy\nimport contextlib\nfrom io import StringIO\nfrom typing import Union\n\nfrom .exceptions import *\n\ndef _execWithOutput(code:str, stdout=None):\n try:\n old = sys.stdout\n if not stdout... | [
[
"numpy.base_repr"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
lerooze/pandaSDMX | [
"3a9a3d23694c5d61878316f4a33cbd3aa3d1945a"
] | [
"pandasdmx/writer.py"
] | [
"from itertools import chain\n\nimport numpy as np\nimport pandas as pd\n\nfrom pandasdmx.model import (\n DEFAULT_LOCALE,\n AgencyScheme,\n DataAttribute,\n DataflowDefinition,\n DataStructureDefinition,\n DataSet,\n Dimension,\n DimensionComponent,\n # DimensionDescriptor,\n Category... | [
[
"pandas.concat",
"pandas.to_datetime",
"pandas.Series",
"pandas.DataFrame",
"pandas.DataFrame.from_dict"
]
] | [
{
"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": []
}
] |
tomvothecoder/pcmdi_metrics | [
"34cdd56a78859db6417cbc7018c8ae8bbf2f09b5"
] | [
"pcmdi_metrics/variability_mode/lib/eof_analysis.py"
] | [
"from __future__ import print_function\nfrom eofs.cdms import Eof\nfrom time import gmtime, strftime\nimport cdms2\nimport cdutil\nimport genutil\nimport MV2\nimport numpy as np\nimport sys\n\n# from pcmdi_metrics.variability_mode.lib import debug_print\n\n\ndef eof_analysis_get_variance_mode(\n mode, timese... | [
[
"numpy.polyfit"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
modudeepnlp/transformers-ace | [
"c048155156daf1fe1901757f039b1f67fed46b14"
] | [
"transformers_ace/temp/lm_finetuning/pregenerate_training_data.py"
] | [
"from argparse import ArgumentParser\nfrom pathlib import Path\nfrom tqdm import tqdm, trange\nfrom tempfile import TemporaryDirectory\nimport shelve\nfrom multiprocessing import Pool\n\nfrom random import random, randrange, randint, shuffle, choice\nfrom transformers.tokenization_bert import BertTokenizer\nimport ... | [
[
"numpy.cumsum",
"numpy.searchsorted"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
st--/trieste | [
"8c21681806b96912bd31929ab04d99ef0c6b48c9"
] | [
"tests/unit/test_data.py"
] | [
"# Copyright 2020 The Trieste Contributors\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable l... | [
[
"tensorflow.constant",
"tensorflow.reduce_all",
"tensorflow.ones",
"tensorflow.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"2.8",
"1.10",
"1.12",
"1.4",
"2.7",
"2.2",
"2.3",
"2.4",
"2.9",
"1.5",
"1.7",
"2.5",
"0.12",
"1.0",
"2.6",
"1.2",
"2.... |
karbassi/pycovid | [
"ec99ed3302b155588960b3df006775f3daa4d3f5"
] | [
"pycovid/pycovid.py"
] | [
"import pandas as pd\nimport numpy as np\nimport plotly.express as px\n\ndef getCovidCases(countries=None, provinces=None, start_date=None, end_date=None, casetype=['confirmed', 'death', 'recovered'], cumsum=False):\n df = pd.read_csv('https://raw.githubusercontent.com/RamiKrispin/coronavirus-csv/master/coronavi... | [
[
"pandas.merge",
"pandas.read_csv",
"pandas.Grouper"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
GreenKuaiKuai/image-processing-homework | [
"84c34065aa6a656adcb8576e8630680cb99b5dd6"
] | [
"HW4/cnn.py"
] | [
"from keras.preprocessing.image import ImageDataGenerator\r\nimport matplotlib.pyplot as plt\r\nimport tensorflow as tf\r\nimport keras\r\nfrom tensorflow.keras.models import Sequential\r\nfrom tensorflow.keras.layers import Dense, Flatten, Dropout, Activation, Conv2D, MaxPooling2D, BatchNormalization\r\n\r\n\r\n# ... | [
[
"matplotlib.pyplot.legend",
"tensorflow.keras.layers.Dropout",
"tensorflow.keras.layers.Activation",
"matplotlib.pyplot.title",
"tensorflow.keras.layers.Dense",
"tensorflow.keras.layers.Conv2D",
"tensorflow.keras.layers.MaxPooling2D",
"matplotlib.pyplot.plot",
"tensorflow.keras... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"2.7",
"2.2",
"2.3",
"2.4",
"2.5",
"2.6"
]
}
] |
gil9red/SimplePyScripts | [
"c191ce08fbdeb29377639184579e392057945154"
] | [
"Bot Buff Knight Advanced/main.py"
] | [
"#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\n\n\n__author__ = 'ipetrash'\n\n\nimport threading\nimport os\nimport time\n\nfrom timeit import default_timer as timer\n\n# pip install opencv-python\nimport cv2\nimport numpy as np\nimport pyautogui\nimport keyboard\n\nfrom common import get_logger, get_current_dat... | [
[
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
medhini/robosuite | [
"f308281ed17b6710334c06f8e7da5fededccaee8"
] | [
"robosuite/models/arenas/bin_packing_arena.py"
] | [
"import numpy as np\nfrom robosuite.models.arenas import Arena\nfrom robosuite.utils.mjcf_utils import xml_path_completion\nfrom robosuite.utils.mjcf_utils import array_to_string, string_to_array\n\n\nclass BinPackingArena(Arena):\n \"\"\"Workspace that contains two bins placed side by side.\"\"\"\n\n def __i... | [
[
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
AntixK/MISSO | [
"67a6cb7e149a7da14733f931e21afb887af92f57"
] | [
"benchmarks/full_benchmark.py"
] | [
"from time import time\nimport numpy as np\nfrom misso import MISSO as misso_cpu\nfrom misso_gpu import MISSO as misso_gpu\nimport matplotlib.pyplot as plt\nplt.style.use('seaborn')\n\n# np.set_printoptions(precision=2)\n\nK = 15\ndef get_data(N, M:int = K):\n t = np.random.uniform(-10, 10, (N, 1))\n y = np.s... | [
[
"numpy.hstack",
"matplotlib.pyplot.subplots",
"matplotlib.pyplot.savefig",
"numpy.sin",
"numpy.cos",
"numpy.std",
"numpy.mean",
"numpy.random.uniform",
"numpy.array",
"matplotlib.pyplot.show",
"matplotlib.pyplot.style.use"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
nntrongnghia/chatenoud_delorme | [
"b6e9a3d5e0c1a040ca7131d725126917992b15c1"
] | [
"main_scraping_v2.py"
] | [
"import FNscraping as scrap\nimport time\nfrom datetime import datetime as dt\nimport pandas as pd\n\n# POUR TESTER, J'AI CHANGER LE FILTRE UN PEU\n\n#================ Configurer le programme pricipal\nCategoryChoice = ['Consoles & Jeux vidéo' , 'Informatique' , 'Motos' , 'Téléphonie']\nRegionChoice = ['Bouches... | [
[
"pandas.read_excel"
]
] | [
{
"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": []
}
] |
j-faria/kima-subtrees-test | [
"2a8acfaa7b2b03da13945cbe753088fd85039d73"
] | [
"DNest4/python/setup.py"
] | [
"#!/usr/bin/env python\n\nimport os\n\ntry:\n from setuptools import setup, Extension\nexcept ImportError:\n from distutils.core import setup, Extension\n\n\nif __name__ == \"__main__\":\n import sys\n\n # Publish the library to PyPI.\n if \"publish\" in sys.argv:\n os.system(\"python setup.py... | [
[
"numpy.get_include"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
FTC-8856/SAC | [
"98898d2c4b2ae99b74a8b5a6934d5d3cb91fe5f4"
] | [
"sac/policy.py"
] | [
"import numpy as np\nimport torch\nimport torch.nn.functional as F\nimport torch.nn as nn\nfrom torch.distributions import Normal\nuse_cuda = torch.cuda.is_available()\ndevice = torch.device(\"cuda\" if use_cuda else \"cpu\")\n\n\nclass PolicyNetwork(nn.Module):\n def __init__(self, num_inputs, num_actions, hidd... | [
[
"torch.tanh",
"torch.nn.Linear",
"torch.FloatTensor",
"torch.cuda.is_available",
"torch.distributions.Normal",
"torch.device",
"torch.clamp"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
terrifyzhao/tf2-bert | [
"23dae92c66c2c9241ec2c36cb5b42b8652d5b4e4"
] | [
"bert_utils/utils.py"
] | [
"import tensorflow as tf\nimport numpy as np\nimport six\n\n\ndef create_initializer(initializer_range=0.02):\n \"\"\"Creates a `truncated_normal_initializer` with the given range.\"\"\"\n return tf.keras.initializers.TruncatedNormal(stddev=initializer_range)\n\n\ndef pad_sequences(sequences, maxlen=None, dty... | [
[
"tensorflow.keras.metrics.BinaryAccuracy",
"tensorflow.keras.metrics.SparseCategoricalAccuracy",
"numpy.asarray",
"tensorflow.keras.losses.SparseCategoricalCrossentropy",
"numpy.issubdtype",
"tensorflow.keras.losses.BinaryCrossentropy",
"numpy.full",
"numpy.max",
"tensorflow.co... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"2.7",
"2.2",
"2.3",
"2.4",
"2.5",
"2.6"
]
}
] |
ngshya/ssl-play | [
"ef70793a07aa3424502c7443c44de3e5f18ee2be"
] | [
"sslplay/utils/ssplit.py"
] | [
"import numpy as np\nimport random\nimport logging\n\ndef ssplit(X, y, percentage_1, percentage_2, min_el_1=1, min_el_2=1, seed=1102):\n\n assert percentage_1 >= 0\n assert percentage_2 >= 0\n assert percentage_1 + percentage_2 > 0\n\n np.random.seed(seed)\n random.seed(seed)\n\n y = np.array(y)\n... | [
[
"numpy.random.seed",
"numpy.min",
"numpy.unique",
"numpy.random.choice",
"numpy.max",
"numpy.append",
"numpy.repeat",
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
mmilk1231/chainerrl | [
"d351f9f5d1bb1dbaf98c8c629312884eb940de7a"
] | [
"examples/gym/train_acer_gym.py"
] | [
"from __future__ import division\nfrom __future__ import print_function\nfrom __future__ import unicode_literals\nfrom __future__ import absolute_import\nfrom builtins import * # NOQA\nfrom future import standard_library\nstandard_library.install_aliases() # NOQA\nimport argparse\nimport os\n\n# This prevents num... | [
[
"numpy.arange"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
sbaker-dev/weightGIS | [
"9e9137a00cc00d3993b7fcf4a30bc02082c8ee5a"
] | [
"weightGIS/PlaceReference.py"
] | [
"from miscSupports import directory_iterator, flip_list, flatten\nfrom csvObject import CsvObject, write_csv\nfrom shapely.geometry import Polygon\nfrom shapeObject import ShapeObject\nfrom pathlib import Path\nimport numpy as np\nimport re\n\n\nclass PlaceReference:\n def __init__(self, working_directory, base_... | [
[
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
zhaoheri/homework | [
"fcae59f37a947d8409a9e4d14885a8df07124aac"
] | [
"hw3/dqn.py"
] | [
"import uuid\nimport time\nimport pickle\nimport sys\nimport gym.spaces\nimport itertools\nimport numpy as np\nimport random\nimport tensorflow as tf\nimport tensorflow.contrib.layers as layers\nfrom collections import namedtuple\nfrom dqn_utils import *\n\nOptimizerSpec = namedtuple(\"OptimizerSpec\", [\"construct... | [
[
"tensorflow.reduce_max",
"tensorflow.get_collection",
"tensorflow.cast",
"tensorflow.global_variables",
"tensorflow.placeholder",
"numpy.mean",
"tensorflow.one_hot",
"tensorflow.argmax",
"tensorflow.group"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10",
"1.12",
"1.4",
"1.5",
"1.7",
"0.12",
"1.0",
"1.2"
]
}
] |
OceanNuclear/PeakFinding | [
"dd82589201496b8c46cbd8ae28c2dabbfba7fed1",
"dd82589201496b8c46cbd8ae28c2dabbfba7fed1"
] | [
"user_scripts/plot_ChipIr.py",
"maths_exploration/full_pmf.py"
] | [
"from peakfinding.spectrum import RealSpectrumInteractive, RealSpectrum\nimport sys\nimport matplotlib.pyplot as plt\n\nif __name__=='__main__':\n spectrum = RealSpectrum.from_multiple_files(*sys.argv[1:-1])\n # spectrum.to_Spe(sys.argv[-1]+\".Spe\")\n ax, line = spectrum.plot_sqrt_scale()\n ax.set_xlim... | [
[
"matplotlib.pyplot.savefig"
],
[
"pandas.read_csv",
"numpy.arange",
"numpy.mean",
"numpy.array",
"numpy.exp"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
nuin/bcbio-nextgen | [
"bd084774c8ce9a540d0d0064044f16e92a61358b",
"9320479d8f21677b61ed1274b4da23d569c686ae"
] | [
"bcbio/install.py",
"bcbio/bam/__init__.py"
] | [
"\"\"\"Handle installation and updates of bcbio-nextgen, third party software and data.\n\nEnables automated installation tool and in-place updates to install additional\ndata and software.\n\"\"\"\nimport argparse\nimport collections\nimport contextlib\nimport datetime\nfrom distutils.version import LooseVersion\n... | [
[
"matplotlib.use",
"matplotlib.matplotlib_fname"
],
[
"numpy.median"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
cli99/tvm | [
"6c6e873a1325a32418108daad6e38f3df8c37660"
] | [
"tests/python/relay/test_pipeline_executor.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.full"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
fossabot/numba-dppy | [
"918922d94c64572c279679b893445bf84f817187"
] | [
"numba_dppy/examples/atomic_op.py"
] | [
"# Copyright 2020, 2021 Intel Corporation\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable l... | [
[
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
AP-Atul/Pima-Indians-Diabetes | [
"68cc4f068992fcca24f1435818601996f56eb0b6"
] | [
"cleanup.py"
] | [
"\"\"\"Cleaning up the data set\"\"\"\n\nimport numpy as np\nimport pandas as pd\nfrom matplotlib import pyplot as plt\n\n# reading the data set\ndf = pd.read_csv(\"./dataset/diabetes.csv\")\n\n# features in the data set\n# OP: 'Pregnancies', 'Glucose', 'BloodPressure', 'SkinThickness',\n# 'Insulin', 'BMI', 'Di... | [
[
"pandas.concat",
"pandas.read_csv",
"matplotlib.pyplot.show"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.3",
"1.1",
"1.5",
"1.2"
],
"scipy": [],
"tensorflow": []
}
] |
AAlexCho/csci1470final | [
"f6720235d1583fba7bf2f6c3db9135a438c2b1db"
] | [
"deep_lstm.py"
] | [
"import time\nimport numpy as np\n\nfrom utils import array_pad\nfrom base_model import Model\nfrom cells import LSTMCell, MultiRNNCellWithSkipConn\nfrom data_utils import load_vocab, load_dataset\n\nimport torch as torch\nimport torch.nn as nn\nimport torch.nn.functional as F\nfrom torch.autograd import Variable\n... | [
[
"torch.nn.CrossEntropyLoss",
"torch.nn.Dropout",
"torch.transpose",
"torch.max",
"torch.randn",
"torch.IntTensor",
"torch.nn.Embedding",
"torch.FloatTensor",
"torch.unbind",
"torch.stack"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Mohit-007/DEEP-LEARNING | [
"d2d16138b011444c351ffaef0923ff3127a64e6c"
] | [
"DEEP LEARNING ALGORITHM/CONVOLUTIONAL NEURAL NETWORK/WEEK 1/CONVOLUTION MODEL APPLICATION.py"
] | [
"\n# coding: utf-8\n\n# # Convolutional Neural Networks: Application\n# \n# Welcome to Course 4's second assignment! In this notebook, you will:\n# \n# - Implement helper functions that you will use when implementing a TensorFlow model\n# - Implement a fully functioning ConvNet using TensorFlow \n# \n# **After this... | [
[
"matplotlib.pyplot.imshow",
"tensorflow.nn.softmax_cross_entropy_with_logits",
"tensorflow.nn.max_pool",
"numpy.squeeze",
"tensorflow.cast",
"tensorflow.contrib.layers.flatten",
"numpy.random.randn",
"tensorflow.train.AdamOptimizer",
"tensorflow.nn.conv2d",
"tensorflow.rese... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [
"0.13",
"0.14",
"0.15",
"0.10",
"0.16",
"0.19",
"0.18",
"0.12",
"1.0",
"0.17",
"1.2"
],
"tensorflow": [
"1.10"
]
}
] |
amolmane1/LDA_collapsed_gibbs_sampling | [
"d5a913da3ae8a1fadb718d7e593d7f304154bd41"
] | [
"src/lda_cgs.py"
] | [
"import numpy as np\n# import pandas as pd\n# from sklearn.feature_extraction.text import CountVectorizer\nimport time\n\n### Desired extensions:\n# show prob(w|z) in get_top_words_for_topics()\n# create horizontal bar chart (for p(w|z)) in get_top_words_for_topics(), one column for each topic\n# code perplexity/li... | [
[
"numpy.multiply",
"numpy.nonzero",
"numpy.zeros",
"numpy.sum",
"numpy.random.randint"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
MuAuan/DarkDrawings | [
"e360df47837610bda6137950b092877a98443ae6"
] | [
"mayuyu.py"
] | [
"import numpy as np\n\nimport torch\nimport torchvision\nfrom torch.utils.data import DataLoader, random_split\nfrom torchvision import transforms\nimport cv2\nimport matplotlib.pyplot as plt\nimport glob\nimport os\nfrom PIL import Image\n\n\nts = torchvision.transforms.ToPILImage()\n\nimage0 = cv2.imread('mayuyu.... | [
[
"matplotlib.pyplot.imshow",
"matplotlib.pyplot.title",
"numpy.uint8",
"matplotlib.pyplot.clf",
"matplotlib.pyplot.pause"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
manoj2601/Machine-Learning-COL774 | [
"b39f35dc3605b6abff4ab2b8263cdecc84b74b35"
] | [
"Assignment 1/q1/q1b.py"
] | [
"import sys\nimport numpy as np\nimport matplotlib\nmatplotlib.use('Agg')\nfrom mpl_toolkits.mplot3d import axes3d\nimport matplotlib.pyplot as plt \nfrom mpl_toolkits import mplot3d \n\n\"\"\"\nComputes the cost for given X, y and theta\nJ(theta) = 1/2m * sum_from i = 0 to m {(y - theta'.x)^2}\n\"\"\"\ndef compute... | [
[
"matplotlib.pyplot.legend",
"numpy.abs",
"matplotlib.pyplot.scatter",
"matplotlib.pyplot.title",
"matplotlib.use",
"numpy.matmul",
"numpy.subtract",
"matplotlib.pyplot.savefig",
"numpy.empty",
"numpy.std",
"matplotlib.pyplot.clf",
"numpy.mean",
"numpy.transpose"... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
krishnaShreedhar/Compositional-embedding-for-speaker-diarization | [
"09ae86a91aeb47d01bcefcf0d808c9d1e20f176d"
] | [
"src/utils.py"
] | [
"import pandas as pd\nimport numpy as np\nimport matplotlib.pyplot as plt\nimport matplotlib as mpl\n\nfrom matplotlib.dates import DateFormatter, MinuteLocator, SecondLocator\nimport numpy as np\nfrom io import StringIO, BytesIO\nimport datetime as dt\n\nimport constants\n\nmpl.style.use(constants.MPL_STYLE)\n\n\n... | [
[
"matplotlib.pyplot.legend",
"pandas.Series",
"matplotlib.pyplot.plot",
"numpy.random.randint",
"matplotlib.style.use",
"numpy.arange",
"matplotlib.pyplot.hlines",
"matplotlib.pyplot.close",
"matplotlib.pyplot.vlines",
"matplotlib.pyplot.figure",
"matplotlib.pyplot.title... | [
{
"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": []
}
] |
salesforce/MoFE | [
"1d7fd335b16f32082544d42e99ba3199a6d905b4"
] | [
"src/weights_ensemble.py"
] | [
"\"\"\"\nCopyright (c) 2021, salesforce.com, inc.\nAll rights reserved.\nSPDX-License-Identifier: BSD-3-Clause\nFor full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause\n\"\"\"\n\n\nimport collections\nimport shutil\nimport os\nimport argparse\nfrom transformers i... | [
[
"torch.device",
"torch.cuda.is_available",
"torch.save"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
xlnwel/cs294-112 | [
"ae88d3a63313aebc9d2ab87cd0c1ec50e162cc50"
] | [
"hw3/run_dqn_ram.py"
] | [
"import argparse\nimport gym\nfrom gym import wrappers\nimport os.path as osp\nimport random\nimport numpy as np\nimport tensorflow as tf\nimport tensorflow.contrib.layers as layers\n\nimport dqn\nfrom dqn_utils import *\nfrom atari_wrappers import *\n\n\ndef atari_model(ram_in, num_actions, scope, reuse=False):\n ... | [
[
"numpy.random.seed",
"tensorflow.python.client.device_lib.list_local_devices",
"tensorflow.set_random_seed",
"tensorflow.ConfigProto",
"tensorflow.contrib.layers.fully_connected",
"tensorflow.reset_default_graph",
"tensorflow.Session",
"tensorflow.variable_scope"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10",
"1.12",
"1.4",
"1.13",
"1.5",
"1.7",
"0.12",
"1.0",
"1.2"
]
}
] |
mateuszroszkowski/nnmnkwii | [
"64f8e0771688e1d0c537b79aa402a6f04e107d56"
] | [
"tests/test_pack_pad_sequence.py"
] | [
"from __future__ import division, print_function, absolute_import\n\nfrom nnmnkwii.datasets import FileSourceDataset, PaddedFileSourceDataset\nfrom nnmnkwii.datasets import MemoryCacheFramewiseDataset\nfrom nnmnkwii.datasets import MemoryCacheDataset\nfrom nnmnkwii.util import example_file_data_sources_for_acoustic... | [
[
"torch.nn.LSTM",
"torch.zeros",
"torch.utils.data.DataLoader",
"torch.from_numpy",
"torch.nn.utils.rnn.pack_padded_sequence",
"torch.nn.Linear",
"torch.nn.utils.rnn.pad_packed_sequence",
"torch.nn.MSELoss",
"torch.autograd.Variable"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
datanalys/datasets | [
"d477dd6fda1e0c8a5500030346708075c2f061c4"
] | [
"scripts/currencies/crypto-details.py"
] | [
"#This example uses Python 2.7 and the python-request library.\n\nfrom requests import Request, Session\nfrom requests.exceptions import ConnectionError, Timeout, TooManyRedirects\nimport json\nimport pandas as pd\nimport sys\nimport io\nimport time\n\nurl = 'https://api.nomics.com/v1/currencies/ticker?key=27f1ff74... | [
[
"pandas.json_normalize"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0"
],
"scipy": [],
"tensorflow": []
}
] |
parphane/udacity-self_driving_cars | [
"069762a5320a109ebe4f7c23997631a2998a0076"
] | [
"gradients_and_color_spaces/hls_quiz.py"
] | [
"import matplotlib.pyplot as plt\nimport matplotlib.image as mpimg\nimport numpy as np\nimport cv2\n\n# Read in an image, you can also try test1.jpg or test4.jpg\nimage = mpimg.imread('test6.jpg')\n\n\n# TODO: Define a function that thresholds the S-channel of HLS\n# Use exclusive lower bound (>) and inclusive uppe... | [
[
"matplotlib.pyplot.subplots",
"matplotlib.image.imread",
"numpy.zeros_like",
"matplotlib.pyplot.subplots_adjust",
"matplotlib.pyplot.show"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
kyleCampbel1/stock-tracker-webapp | [
"a5c1c25218a4d436d3e574e328a23438e300286b"
] | [
"api/views.py"
] | [
"import functools\nimport numpy as np\n\nfrom flask import abort, Blueprint, jsonify, redirect, url_for, request, flash, session, g\nfrom .app import db \nfrom .models import User, Metric, Markets\nfrom .utils import addMarketToDb, addMarketToUser, removeMarket, getMetricHistory\nfrom .cryptoClient import verifyTic... | [
[
"numpy.argsort",
"numpy.std",
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Unique-Divine/crypto-apis | [
"c8f577cdef1ba120c0424fcc5be63e710249f8f1"
] | [
"pycaw/messari/helpers.py"
] | [
"\"\"\"This module is dedicated to helpers for the Messari class\"\"\"\n\n\nimport logging\nfrom typing import Union, List, Dict\nimport pandas as pd\n\nfrom pycaw.messari.utils import validate_input, validate_asset_fields_list_order, find_and_update_asset_field\n\n\ndef fields_payload(asset_fields: Union[str, List... | [
[
"pandas.DataFrame.from_records",
"pandas.concat",
"pandas.to_datetime"
]
] | [
{
"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": []
}
] |
ExamDay/NeuralGREWT | [
"2256eb8c88f410bf5a229911f299b216153c96ba"
] | [
"GPT2/model.py"
] | [
"\"\"\"\n code by TaeHwan Jung(@graykode)\n Original Paper and repository here : https://github.com/openai/gpt-2\n GPT2 Pytorch Model : https://github.com/huggingface/pytorch-pretrained-BERT\n\"\"\"\nimport copy\nimport math\n\nimport torch\nimport torch.nn as nn\nfrom torch.nn.parameter import Parameter\n... | [
[
"torch.nn.Softmax",
"torch.nn.CrossEntropyLoss",
"torch.ones",
"torch.empty",
"torch.zeros",
"torch.sqrt",
"torch.cat",
"torch.nn.Embedding",
"torch.matmul",
"torch.nn.Linear",
"torch.nn.init.normal_",
"torch.nn.parameter.Parameter",
"torch.pow"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
zehao-sean-huang/selfstudy-render | [
"98065134c12973fed784104ed73036201e8852d6"
] | [
"util.py"
] | [
"import json\nimport numpy as np\nimport os\nimport sys\n\nimport paths\n\n# ==============================================================================\n# DTD and ShapeNet helper functions\n# ==============================================================================\n\n# DTD reference\ndtd_img_dir = f'{path... | [
[
"numpy.abs",
"numpy.random.choice",
"numpy.arange",
"numpy.linalg.norm",
"numpy.stack",
"numpy.ones",
"numpy.cos",
"numpy.frombuffer",
"numpy.sin",
"numpy.random.permutation",
"numpy.random.randn",
"numpy.random.rand",
"numpy.array",
"numpy.roll"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
annikan24/geoapps | [
"3f1f1c8d93cdcbe69a3ad3b7d00096aa135c8f0f"
] | [
"geoapps/create/contours.py"
] | [
"# Copyright (c) 2021 Mira Geoscience Ltd.\n#\n# This file is part of geoapps.\n#\n# geoapps is distributed under the terms and conditions of the MIT License\n# (see LICENSE file at the root of this source code package).\n\n\nimport numpy as np\nfrom geoh5py.io import H5Writer\nfrom geoh5py.objects import Curve... | [
[
"numpy.hstack",
"numpy.arange",
"numpy.ones",
"scipy.interpolate.LinearNDInterpolator",
"numpy.vstack"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
snu-mllab/parsimonious-blackbox-attack | [
"278c810e6cd272713935875a8f123031e30c2808"
] | [
"cifar10/cifar10_input.py"
] | [
"\"\"\"This script is borrowed from https://github.com/MadryLab/cifar10_challenge\n\nUtilities for importing the CIFAR10 dataset.\n\nEach image in the dataset is a numpy array of shape (32, 32, 3), with the values\nbeing unsigned integers (i.e., in the range 0,1,...,255).\n\"\"\"\n\nfrom __future__ import absolute_... | [
[
"tensorflow.image.resize_image_with_crop_or_pad",
"tensorflow.image.random_flip_left_right",
"tensorflow.placeholder",
"tensorflow.random_crop",
"numpy.random.permutation",
"numpy.array",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
ben-bougher/modelr | [
"2a3ad38285bad24f5aa05f3ecc4e976dd3147da9"
] | [
"modelr/web/scripts/scenario/forward_model.py"
] | [
"'''\nCreated on Apr 30, 2012\n\n@author: Sean Ross-Ross, Matt Hall, Evan Bianco\n'''\nimport numpy as np\nimport matplotlib\nfrom scipy.interpolate import interp1d\n\nimport urllib2\nimport matplotlib.pyplot as plt\n\nfrom argparse import ArgumentParser\nfrom modelr.web.defaults import default_parsers\nfrom modelr... | [
[
"numpy.asarray",
"numpy.arange",
"matplotlib.interactive",
"numpy.amax"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
DSD-ESDC-EDSC/pass | [
"546514a255400682be6a4157df2e5948c061f61c"
] | [
"modules/aceso/gravity.py"
] | [
"\"\"\"\nTHIS IS A MODIFIED VERSION OF BRIAN LEWIS' ACESO MODEL PYTHON PACKAGE\n\nClasses to calculate gravity-based measures of potential spatial accessibility.\n\nThese measures assign accessibility scores to demand locations based on their proximity to supply\nlocations. The main model used here is a gravitation... | [
[
"numpy.reciprocal",
"numpy.nansum",
"numpy.isinf",
"numpy.ones"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
akutuzov/bilm-tf | [
"87f9db77f2474fecdf7941fe005ef7429c1a3ec2"
] | [
"plotting.py"
] | [
"# python3\n# coding: utf-8\n\nimport sys\nfrom smart_open import open\nimport os\nimport numpy as np\nimport pylab as plot\n\nif __name__ == '__main__':\n files2process = sys.argv[2:]\n lang = sys.argv[1]\n data = {}\n for f in files2process:\n name = os.path.basename(f).split('.')[0].replace('_... | [
[
"numpy.std",
"numpy.mean"
]
] | [
{
"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.