repo_name
stringlengths
6
130
hexsha
list
file_path
list
code
list
apis
list
possible_versions
list
p-morais/rl
[ "6a39d8cec58fdd471f2de80a9c7c9b2f1879f096" ]
[ "rl/utils/experiment.py" ]
[ "import atexit, os\nimport os.path as osp\nfrom subprocess import Popen\nfrom functools import partial\nimport torch.multiprocessing as mp\nfrom .render import renderloop\nfrom .logging import Logger\nfrom rl.envs import Normalize, Vectorize\n\n\ndef run_experiment(algo, policy, env_fn, args, log=True, monitor=Fals...
[ [ "torch.multiprocessing.Process" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
johannestreutlein/op-tie-breaking
[ "ef9dada6c14efa416ecb4f1fcf48a7e4b344ba27", "ef9dada6c14efa416ecb4f1fcf48a7e4b344ba27" ]
[ "src/op_with_tie_breaking.py", "src/modules/critics/pair_coma.py" ]
[ "import argparse\nimport matplotlib.pyplot as plt\nimport numpy as np\nimport datetime\nimport pandas as pd\n\nimport json\n\nimport os\n\nfrom utils.uniquify import uniquify\n\ndef op_tie_breaking_evaluation(hash_lists, args):\n '''This function evaluates our method, other-play with tie-breaking. It applies the...
[ [ "numpy.log2", "numpy.array", "pandas.DataFrame" ], [ "torch.gather", "torch.nn.Linear", "torch.eye", "torch.zeros_like" ] ]
[ { "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": [] }, { "matplotlib": [], "nump...
giulio1979/dldt
[ "b2140c083a068a63591e8c2e9b5f6b240790519d" ]
[ "model-optimizer/mo/graph/graph.py" ]
[ "\"\"\"\n Copyright (C) 2018-2020 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...
[ [ "numpy.any" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
wangdingkang/DiscreteMorse
[ "3e1dcf215d96047f0e6754a34e45057bf1a19ff5" ]
[ "Code/DIPHA/write_dipha_file_3d.py" ]
[ "import sys\nfrom matplotlib import image as mpimg\nimport numpy as np\nimport os\n\nDIPHA_CONST = 8067171840\nDIPHA_IMAGE_TYPE_CONST = 1\nDIM = 3\n\ninput_dir = sys.argv[1]\ndipha_output_filename = sys.argv[2]\nvert_filename = sys.argv[3]\n\ninput_filenames = [name for name in os.listdir(input_dir) if (os.path.isf...
[ [ "numpy.int64", "matplotlib.image.imread", "numpy.zeros", "numpy.float64" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
PinchukKPI/RGS_parasol_model
[ "4c0848951658d8129a0ed71b2becdeab30bf70e5" ]
[ "main.py" ]
[ "\nimport numpy as np\nimport matplotlib.pyplot as plt\nfrom scipy.optimize import minimize\nfrom scipy.io import loadmat\n\n\ndef load_white_noise_data(cell_id):\n data = loadmat('Data/elife-38841-fig4-data1-v2.mat') # loadmat is a function in scipy.io\n # data from Figure 4 can be downloaded from https://d...
[ [ "scipy.io.loadmat", "numpy.zeros" ] ]
[ { "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"...
RacleRay/Fine-grained_TextClassification
[ "ffd43b576ee766dfdfefa17946592a8506eae0de", "ffd43b576ee766dfdfefa17946592a8506eae0de", "ffd43b576ee766dfdfefa17946592a8506eae0de" ]
[ "multi_class_base.py", "Albert/models/multi_class_cnn.py", "Albert/models/awd_lstm.py" ]
[ "#!/usr/bin/env python\n# -*- encoding: utf-8 -*-\n'''\n@File : multi_class_base.py\n'''\n\n# multi-task learning implementation of Kim's paper : Convolutional Neural Networks for Sentence Classification.\n\nimport tensorflow as tf\nimport numpy as np\n\n\nclass TextCNN(object):\n \"\"\"\n A CNN for text...
[ [ "tensorflow.device", "tensorflow.nn.softmax_cross_entropy_with_logits", "tensorflow.concat", "tensorflow.nn.max_pool", "tensorflow.cast", "tensorflow.nn.l2_loss", "tensorflow.nn.conv2d", "tensorflow.name_scope", "tensorflow.contrib.layers.xavier_initializer", "tensorflow.ar...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10" ] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflo...
GeoDaCenter/accessibility
[ "731ca101ca3744740ea246fd9f57e29f893e8405" ]
[ "access/tests/test_floating_catchment_area.py" ]
[ "import sys\nsys.path.append('../..')\n\nimport math\nimport unittest\n\nimport numpy as np\nimport pandas as pd\nimport geopandas as gpd\nfrom access import access, weights\nimport util as tu\n\n\nclass TestFloatingCatchmentArea(unittest.TestCase):\n\n def setUp(self):\n n = 5\n supply_grid = tu.c...
[ [ "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": [] } ]
pome-ta/pystaMetalStudy
[ "530248ad8621ec951fcbaf450ebd26ac2752e540" ]
[ "src/everythingAboutTheMetalAPI/chapter09/__main__.py" ]
[ "import pathlib\nimport ctypes\nimport numpy as np\n\nfrom objc_util import c, create_objc_class, ObjCClass, ObjCInstance\nimport ui\n\n#import pdbg\n\n\n\nshader_path = pathlib.Path('./Shaders.metal')\n\n\n# --- load objc classes\nMTKView = ObjCClass('MTKView')\nMTLCompileOptions = ObjCClass('MTLCompileOptions')\n...
[ [ "numpy.dot", "numpy.ctypeslib.as_array", "numpy.cos", "numpy.sin", "numpy.tan", "numpy.identity", "numpy.array", "numpy.zeros", "numpy.vstack" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
AdvAiLab/smart_lab
[ "e99d2e0129e7dba3a8847bf215b2588128fc32b1" ]
[ "webap_tools/webap_tools/captcha_prediction.py" ]
[ "import os\nfrom time import sleep\n\nimport cv2\nimport matplotlib.pyplot as plt\nimport numpy as np\nimport tensorflow as tf\nfrom tensorflow.keras.backend import clear_session\nfrom tensorflow.keras.models import load_model\nfrom tensorflow.python.keras.backend import set_session\n\n\ndef rgb2gray(rgb):\n r, ...
[ [ "tensorflow.keras.models.load_model", "tensorflow.ConfigProto", "tensorflow.keras.backend.clear_session", "tensorflow.python.keras.backend.set_session", "tensorflow.Session", "tensorflow.get_default_graph", "numpy.array", "matplotlib.pyplot.show", "matplotlib.pyplot.figure" ]...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10" ] } ]
sidgan/ETCI-2021-Competition-on-Flood-Detection
[ "dbb73bef7e26f0109870be13ef4d30c15ce15a33" ]
[ "src/etci_dataset.py" ]
[ "\"\"\"\nReferenced from:\nhttps://medium.com/cloud-to-street/jumpstart-your-machine-learning-satellite-competition-submission-2443b40d0a5a\n\"\"\"\n\nimport cv2\nimport numpy as np\n\nfrom torch.utils.data import Dataset\n\n\ndef s1_to_rgb(vv_image, vh_image):\n ratio_image = np.clip(np.nan_to_num(vh_image / vv...
[ [ "numpy.nan_to_num", "numpy.stack" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
CrazyNicolas/PyTorch-1.x-Reinforcement-Learning-Cookbook
[ "1cca7e0218c2683a730b1c4a66681e68023657ef" ]
[ "Chapter03/chapter3/off_policy_mc_control_weighted_importance_sampling.py" ]
[ "'''\nSource codes for PyTorch 1.0 Reinforcement Learning (Packt Publishing)\nChapter 3: Monte Carlo Methods For Making Numerical Estimations\nAuthor: Yuxi (Hayden) Liu\n'''\n\nimport torch\nimport gym\n\nenv = gym.make('Blackjack-v0')\n\n\ndef gen_random_policy(n_action):\n probs = torch.ones(n_action) / n_acti...
[ [ "torch.ones", "torch.empty", "torch.multinomial", "torch.argmax" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
flatironinstitute/inferelator-prior
[ "572a8016b14d922c74f482dcfc24a83dc7efcc83" ]
[ "inferelator_prior/motifs/homer.py" ]
[ "import subprocess\nimport io\nimport pandas as pd\nimport numpy as np\n\nfrom inferelator_prior.motifs import chunk_motifs, homer_motif, SCAN_SCORE_COL, SCORE_PER_BASE\nfrom inferelator_prior.motifs._motif import MotifScanner\nfrom inferelator_prior import HOMER_EXECUTABLE_PATH\n\nHOMER_DATA_SUFFIX = \".homer.tsv\...
[ [ "pandas.read_csv" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.1", "1.5", "1.2", "1.3" ], "scipy": [], "tensorflow": [] } ]
danjia21/dcp
[ "437c6d10f447304277115f021b8888394ef41a31" ]
[ "model.py" ]
[ "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n\n\nimport os\nimport sys\nimport glob\nimport h5py\nimport copy\nimport math\nimport numpy as np\nimport torch\nimport torch.nn as nn\nimport torch.nn.functional as F\nfrom torch.autograd import Variable\nfrom .util import quat2mat\n\n\n# Part of the code is referre...
[ [ "torch.nn.functional.softmax", "torch.svd", "torch.cat", "torch.zeros", "torch.sum", "torch.device", "torch.softmax", "torch.norm", "torch.ones", "torch.eye", "torch.arange", "torch.nn.Sequential", "torch.nn.BatchNorm1d", "torch.nn.Conv2d", "torch.nn.Lin...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
claylau/genetic_algorithm
[ "692f995a2ca325ba94ac1656b28b651c9a861f46" ]
[ "test_ga.py" ]
[ "import math\nimport numpy as np\nfrom genetic_algorithm.ga import GA\n\n\ndef objective_1():\n cfg = {}\n cfg[\"name\"] = \"Sphere-2D\"\n cfg[\"dimension\"] = 2\n cfg[\"obj_func\"] = lambda x: np.sum(np.power(x, 2))\n cfg[\"fitness_func\"] = lambda x: np.sum(np.power(x, 2))\n cfg[\"lower_bounds\"...
[ [ "numpy.array", "numpy.absolute", "numpy.power" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
jiayouff/Paddle
[ "dc76e4b0f1f9abe61c3886382a004c929379e870" ]
[ "python/paddle/fluid/framework.py" ]
[ "# Copyright (c) 2018 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.array", "numpy.dtype" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
qwilka/PDover2t
[ "4387d153228f1af20a8f5f3f368aa49c42cda2cd" ]
[ "pdover2t/pipe/pipe.py" ]
[ "import logging\n\nimport numpy as np\n\nfrom ..utilities.function_tools import func_call_exception_trap\n\nlogger = logging.getLogger(__name__)\n\n#π = np.pi\n\n\ndef WT_from_D(Do, Di):\n \"\"\"Calculate pipe wall thickness from outer diameter and inner diameter.\n \"\"\"\n return (Do - Di) / 2\n\ndef Di_...
[ [ "numpy.power" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
Anukriti12/PersonalizedFashionStylist
[ "25c45f79ad96b5b52e5dd986d9ba9d837df2d4dc" ]
[ "Recommender-System/model/mlp_inference.py" ]
[ "#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\n\"\"\"\nCreated on Wed Mar 20 15:03:38 2019\n\n@author: lee\n\"\"\"\n\nimport numpy as np\nimport keras\nfrom keras import regularizers\nfrom keras.layers import Embedding, Input, Dense, merge, Reshape, Flatten\nfrom time import time\nimport argparse\nimport json\ni...
[ [ "numpy.arange", "numpy.full" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
demmojo/curve-dao-contracts
[ "6922cd98c7403cc7c6302f5379194c5418c5cb66" ]
[ "scripts/stats/plot_vecrv.py" ]
[ "from brownie import Contract, web3\n\nimport numpy as np\nimport pylab\n\nSTART_BLOCK = 10647813\n\n\ndef main():\n vecrv = Contract(\"0x5f3b5DfEb7B28CDbD7FAba78963EE202a494e2A2\")\n current_block = web3.eth.blockNumber\n blocks = np.linspace(START_BLOCK, current_block, 100)\n powers = [vecrv.totalSupp...
[ [ "numpy.linspace" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
ags3927/frustum-convnet
[ "0ccb4a8e45c9973f902aef5cbb5f776ea634ee32" ]
[ "datasets/temp.py" ]
[ "''' Provider class and helper functions for Frustum PointNets.\n\nAuthor: Charles R. Qi\nDate: September 2017\n\nModified by Zhixin Wang\n'''\n\nfrom __future__ import absolute_import\nfrom __future__ import division\nfrom __future__ import print_function\n\nimport math\nimport time\nimport pickle\nimport sys\nimp...
[ [ "numpy.expand_dims", "torch.zeros", "numpy.arctan2", "numpy.round", "torch.FloatTensor", "numpy.argmin", "numpy.random.randn", "numpy.square", "numpy.clip", "numpy.arange", "numpy.subtract", "numpy.copy", "torch.utils.data.dataloader.default_collate", "torch...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
cycleke/FaceRecognition
[ "c7882ca88b5d7d4bb51aa0852c5225f13f20728c" ]
[ "utils/core/recognizer.py" ]
[ "# *-* coding: utf-8 *-*\n\nimport os\n\nimport cv2\nimport dlib\nimport numpy as np\n\n\nclass Recognizer:\n \"\"\"\n Recognise faces\n \"\"\"\n\n def __init__(\n self,\n *,\n threshold=0.6,\n predictor_path=\"static/shape_predictor_68_face_landmarks.dat\",\n...
[ [ "numpy.array", "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": [], ...
ahmedbesbes/character-based-cnn
[ "593197610498bf0b4898b3bdf2e1f6730f954613" ]
[ "src/model.py" ]
[ "import json\nimport torch\nimport torch.nn as nn\n\n\nclass CharacterLevelCNN(nn.Module):\n def __init__(self, args, number_of_classes):\n super(CharacterLevelCNN, self).__init__()\n\n # define conv layers\n\n self.dropout_input = nn.Dropout2d(args.dropout_input)\n\n self.conv1 = nn....
[ [ "torch.nn.Dropout", "torch.nn.Dropout2d", "torch.nn.Linear", "torch.nn.MaxPool1d", "torch.rand", "torch.nn.Conv1d", "torch.nn.ReLU" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
bryan-flywire/openem
[ "1510ecbbb6b4a43b9f1f9503c87ec66216200677" ]
[ "train/openem_train/classify.py" ]
[ "__copyright__ = \"Copyright (C) 2018 CVision AI.\"\n__license__ = \"GPLv3\"\n# This file is part of OpenEM, released under GPLv3.\n# OpenEM is free software: you can redistribute it and/or modify\n# it under the terms of the GNU General Public License as published by\n# the Free Software Foundation, either version...
[ [ "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": [] } ]
JonSn0w/advent-of-code
[ "f62636ef975dd89d788cba66578d16e07b70d7e9" ]
[ "2017/day10p2.py" ]
[ "import numpy as np;\nRNG = 256;\n\ndef partOne(seq, num_lst, pos, skip):\n\tlst_len = len(num_lst)\n\tcurr_pos = pos\n\tskip_size = skip\n\tlengths = seq.split(',')\n\n\tfor leng in lengths:\n\t\tleng = int(leng.strip())\n\t\tif leng > lst_len:\n\t\t\tcontinue\n\t\trev_end = (curr_pos + leng) % lst_len\n\t\tif rev...
[ [ "numpy.flipud" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
dlvu/vugrad
[ "dabb7fba29f1727c170bc5f37dff5f52adc62536" ]
[ "experiments/train_mlp.py" ]
[ "from _context import vugrad\n\nimport numpy as np\n\n# for running from the command line\nfrom argparse import ArgumentParser\n\nimport vugrad as vg\n\n# Parse command line arguments\nparser = ArgumentParser()\n\nparser.add_argument('-D', '--dataset',\n dest='data',\n help='Which data...
[ [ "numpy.argmax", "numpy.bincount" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
jinjiaodawang/bayesmark
[ "4fbf52c41288ec802cc03c23372e81d2b678ecb9" ]
[ "example_opt_root/bo/models/rf/rf.py" ]
[ "# Copyright (C) 2020. Huawei Technologies Co., Ltd. All rights reserved.\r\n\r\n# This program is free software; you can redistribute it and/or modify it under\r\n# the terms of the MIT license.\r\n\r\n# This program is distributed in the hope that it will be useful, but WITHOUT ANY\r\n# WARRANTY; without even the...
[ [ "sklearn.ensemble.RandomForestRegressor", "torch.cat", "torch.zeros", "numpy.concatenate", "torch.FloatTensor" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
WillianEsp/RM_with_CV
[ "4c2cd607426c73181dc2b2b3ab5722faa42b4a68" ]
[ "python-codes/tictactoe.py" ]
[ "\"\"\"\r\n:File: tictactoe.py\r\n:Description: | Computer Vision for Tic-Tac-Toe\r\n | Detect board and pieces\r\n | Defines next play\r\n | Sends next play through serial communication following a protocol\r\n\r\n:Author: Willian Beraldi Esperandio\r\n:Email: willian.esperan...
[ [ "numpy.rot90", "numpy.dot", "numpy.around", "numpy.chararray", "numpy.array2string" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
Mehrdadj93/handyscripts
[ "5df9a69e17345ca5a3e42dda2424da2da0ab6f12" ]
[ "python/filledlines.py" ]
[ "from collections.abc import Iterable\nimport itertools as it\n\nimport tecplot as tp\nfrom tecplot.constant import AxisMode, Color, PlotType, SurfacesToPlot\n\n\ndef plot_filled_lines_3d(x, *yy, z=(-0.2, 0.2), y0=0, colors=None,\n name='Line Data', page=None):\n \"\"\"Plot a series of li...
[ [ "numpy.asarray", "numpy.meshgrid", "numpy.polynomial.legendre.Legendre", "numpy.linspace" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
BobAnkh/THUEE_ROBOTS
[ "2a302c847058a8d80d83b70b1670e1ffb6de8c57" ]
[ "exp2/svm_canny.py" ]
[ "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n\n# @Author : BobAnkh\n# @Github : https://github.com/BobAnkh\n# @Date : 2020-10-22 19:29:56\n# @LastEditTime : 2020-10-31 11:09:44\n# @Description :\n# @Copyright 2020 BobAnkh\n\nimport cv2\nfrom sklearn import svm\nimport os\nimport random\nimp...
[ [ "sklearn.externals.joblib.dump", "numpy.array", "sklearn.externals.joblib.load", "sklearn.svm.SVC" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
ohenriksson/MastersThesisData
[ "c657deb933d2cbbb7fd55e836e424b9b58c84aab" ]
[ "axis-plotter/functions.py" ]
[ "import numpy as np\n\ndef build_zero_array(n_axes,time):\n return list(map(lambda a: list(map(\n lambda t: 0 ,range(time))) ,range(n_axes) ))\n\n\ndef plot_data(axis, data, title, time):\n axis.set_title(title)\n axis.grid()\n if(len(data) > 1):\n for d in data:\n axis.plot(tim...
[ [ "numpy.round", "numpy.abs", "numpy.divide" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
kad99kev/FGTD-Streamlit
[ "0dc8d2894eadf2260d5e5dcf10ead12ff62f6cd8" ]
[ "app.py" ]
[ "import streamlit as st\nimport torch\nimport gc\n\nfrom utils.toc import Toc\nfrom utils.model_downloader import download_models\nfrom utils.footer import footer\n\nfrom streamlit_utils.loaders import load_face_generators, load_mnist_generators\nfrom streamlit_utils.io import get_sample, read_csv, get_output, face...
[ [ "torch.cuda.is_available" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
MSU-MLSys-Lab/CATE
[ "654c393d7df888d2c3f3b90f9e6752faa061157e" ]
[ "darts/cnn/utils.py" ]
[ "import os\nimport numpy as np\nimport torch\nimport shutil\nimport torchvision.transforms as transforms\n\n\nclass AvgrageMeter(object):\n\n def __init__(self):\n self.reset()\n\n def reset(self):\n self.avg = 0\n self.sum = 0\n self.cnt = 0\n\n def update(self, val, n=1):\n self.sum += val * n\n...
[ [ "numpy.clip", "torch.load", "torch.from_numpy", "numpy.ones", "torch.save", "torch.cuda.is_available", "numpy.random.randint" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
giuscri/TensorFlow-Tutorials
[ "309f7afc803126e882ad185a32f3b39e18452044" ]
[ "eleven.py" ]
[ "import tensorflow as tf\nimport inception\nimport numpy as np\nimport matplotlib.pyplot as plt\nimport os\nfrom sys import argv, stderr\nfrom PIL import Image\nfrom PIL import ImageFilter\n\n\"\"\"\nexercises:\n Try using some of your own images.\n > ✔\n\n Try other arguments for adversary_example().\...
[ [ "numpy.abs", "numpy.clip", "numpy.squeeze", "tensorflow.gradients", "tensorflow.placeholder", "matplotlib.pyplot.subplots", "numpy.ceil", "numpy.argmax", "tensorflow.nn.sparse_softmax_cross_entropy_with_logits", "tensorflow.Session", "numpy.array" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10" ] } ]
praveenck06/Hippocampal-Volume-Quantification-in-Alzheimer-s-Progression
[ "6944ebdf681b35e78b84cd676227f0c396c6a770" ]
[ "ModelTraining/src/experiments/UNetExperiment.py" ]
[ "\"\"\"\nThis module represents a UNet experiment and contains a class that handles\nthe experiment lifecycle\n\"\"\"\nimport os\nimport time\n\nimport numpy as np\nimport torch\nimport torch.optim as optim\nimport torch.nn.functional as F\n\nfrom torch.utils.data import DataLoader\nfrom torch.utils.tensorboard imp...
[ [ "torch.nn.CrossEntropyLoss", "torch.nn.functional.softmax", "torch.optim.lr_scheduler.ReduceLROnPlateau", "torch.load", "torch.no_grad", "torch.utils.tensorboard.SummaryWriter", "torch.cuda.is_available", "numpy.mean" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
toddrme2178/pyccel
[ "deec37503ab0c5d0bcca1a035f7909f7ce8ef653", "deec37503ab0c5d0bcca1a035f7909f7ce8ef653" ]
[ "tests/epyccel/modules/loops.py", "tests/macro/scripts/blas/dswap.py" ]
[ "from pyccel.decorators import types\n\n#==============================================================================\n\n@types( int )\ndef sum_natural_numbers( n ):\n x = 0\n for i in range( 1, n+1 ):\n x += i\n return x\n\n# ...\n@types( int )\ndef factorial( n ):\n x = 1\n for i in range(...
[ [ "numpy.shape" ], [ "numpy.zeros" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
linhvannguyen/PhDworks
[ "9336e5257f5ddc3c899a6fb68b1028c905d13ff9" ]
[ "codes/isotropic/regression/funcs/KRR_poly_cv_alpha_degree_sspacing3_tspacing4.py" ]
[ "# -*- coding: utf-8 -*-\n\"\"\"\nCreated on Thu Mar 3 14:20:44 2016\n\n@author: nguyen\n\"\"\"\nimport numpy as np\nfrom netCDF4 import Dataset\n\n# Constants\nNh = 96\nNt = 37\nsspacing = 3\ntspacing = 4\n\nHTLS_sknots = np.arange(0,Nh,sspacing)\nHTHS_sknots = np.arange(0,Nh,1)\nLTHS_tknots = np.arange(0,Nh,tspa...
[ [ "numpy.logspace", "numpy.arange", "numpy.reshape", "sklearn.kernel_ridge.KernelRidge", "numpy.std", "numpy.mean", "numpy.array", "numpy.zeros" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
activeshadow/HELICS-Examples
[ "750cd111eb11efc681d2575b4919759bdce38e51" ]
[ "python/BLOSEM_tutorial/EVComboFed.py" ]
[ "# -*- coding: utf-8 -*-\n\"\"\"\nCreated on 8/27/2020\n\nThis is a simple EV federate that models a set of EV terminals in an\nEV charging garage. Each terminal can support charging at levels 1, 2,\nand 3 but the EVs that come to charge have a randomly assigned charging\nlevel.\n\nManaging these terminals is a cen...
[ [ "numpy.random.seed", "numpy.linspace", "matplotlib.pyplot.title", "numpy.arange", "numpy.random.choice", "matplotlib.pyplot.plot", "matplotlib.pyplot.ylabel", "matplotlib.pyplot.grid", "matplotlib.pyplot.xlabel", "numpy.array", "matplotlib.pyplot.show", "matplotlib....
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
landbroken/MyPaper
[ "e77581262aac210e6273c3647d091f7cf53eae4a" ]
[ "src/lib_learning/logistics_learning.py" ]
[ "#!/usr/bin/python3.9\n# -*- coding: utf-8 -*-\n#\n# Copyright (C) 2022 LinYulong. All Rights Reserved \n#\n# @Time : 2022/2/7\n# @Author : LinYulong\n# @Description: 逻辑斯蒂回归模型Logistics regression\n# https://blog.csdn.net/u013421629/article/details/78470020\n\nimport pandas as pd\nimport numpy as np\nfrom sklear...
[ [ "pandas.read_csv", "sklearn.linear_model.LogisticRegression", "sklearn.model_selection.train_test_split", "sklearn.metrics.confusion_matrix", "sklearn.preprocessing.StandardScaler", "sklearn.metrics.classification_report", "sklearn.linear_model.SGDClassifier" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.1", "1.5", "1.2", "1.3" ], "scipy": [], "tensorflow": [] } ]
saikrishnarallabandi/Vocoding-Experiments
[ "f2e6c23ea5743ad1d1162669df3c34ccef0541e3" ]
[ "lstmvc.py" ]
[ "import numpy as np\nimport sys, os\nfrom torch.utils.data import Dataset\nfrom torch.utils.data import DataLoader\nfrom torch.autograd import Variable\nfrom model import *\n\n# Locations\nsrc_folder = '../feats/VCC2SF1'\ntgt_folder = '../feats/VCC2TF1'\n\nsrc_files = sorted(os.listdir(src_folder))\ntgt_files = sor...
[ [ "torch.utils.data.DataLoader", "numpy.loadtxt", "torch.autograd.Variable" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
autoih/tensorflow
[ "4a1ae31d56c3c7f40232aace615945c29dcf9c38" ]
[ "tensorflow/python/framework/ops.py" ]
[ "# Copyright 2015 The TensorFlow Authors. All Rights Reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless requ...
[ [ "tensorflow.python.util.function_utils.get_func_code", "tensorflow.python.pywrap_tensorflow.TF_OperationGetAttrType", "tensorflow.python.eager.tape.stop_recording", "tensorflow.python.eager.context.context", "tensorflow.python.pywrap_tensorflow.TF_GraphCopyFunction", "tensorflow.python.pyw...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
sdressler/s64da-benchmark-toolkit
[ "d69b4151c3615fa064795e174e95d159a12ac4ed" ]
[ "s64da_benchmark_toolkit/netdata.py" ]
[ "\nimport logging\n\nimport requests\nimport pandas\n\n\nLOG = logging.getLogger()\n\nclass Netdata:\n def __init__(self, config):\n self.url = f\"{config['url']}/api/v1/data\"\n self.metrics = config['metrics']\n self.charts = config['charts']\n\n def _get_data(self, timerange):\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": [] } ]
jdherman/eci273
[ "86828b2e075258afdd528e86295170e162cc99e3" ]
[ "L15-reservoir-control-multiobj.py" ]
[ "import numpy as np \nimport matplotlib.pyplot as plt\nfrom cvxpy import *\nimport seaborn as sns\nsns.set_style('whitegrid')\n\nQ = np.loadtxt('data/FOL-monthly-inflow-TAF.csv', delimiter=',', skiprows=1, usecols=[1])\nT = len(Q)\nK = 975 # reservoir capacity\nd = 150*np.ones(T) # target demand (TAF/day)\ndw = 0.1...
[ [ "matplotlib.pyplot.scatter", "numpy.arange", "numpy.ones", "numpy.loadtxt", "matplotlib.pyplot.xlabel", "numpy.array", "matplotlib.pyplot.show", "matplotlib.pyplot.ylabel" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
EliasVansteenkiste/edge_detection_framework
[ "b9b3d74bba78edce8b1b7382d0822966b80a61a5" ]
[ "configs/pixelnet_pretrained.py" ]
[ "import numpy as np\nimport torch\nimport torchvision\nimport torch.optim as optim\nimport torch.nn as nn\nimport torch.nn.functional as F\nfrom collections import namedtuple\nfrom functools import partial\nfrom PIL import Image\n\nimport data_transforms\nimport data_iterators\nimport pathfinder\nimport utils\nimpo...
[ [ "torch.mean", "torch.max", "torch.cat", "numpy.asarray", "torch.sign", "torch.sum", "torch.utils.model_zoo.load_url", "numpy.swapaxes", "torch.nn.Dropout", "torch.nn.functional.sigmoid", "numpy.asanyarray", "torch.min", "torch.nn.Conv2d", "torch.nn.Linear", ...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
MichaelMonashev/albumentations
[ "86acab98a81754c2c2d0609519791059316ad121" ]
[ "albumentations/augmentations/transforms.py" ]
[ "from __future__ import absolute_import, division\n\nimport math\nimport random\nimport warnings\nfrom enum import Enum\nfrom types import LambdaType\n\nimport cv2\nimport numpy as np\n\nfrom . import functional as F\nfrom .bbox_utils import denormalize_bbox, normalize_bbox, union_of_bboxes\nfrom ..core.transforms_...
[ [ "numpy.isin", "numpy.rot90", "numpy.split", "numpy.take", "numpy.linspace", "numpy.clip", "numpy.arange", "numpy.indices", "numpy.stack", "numpy.dtype", "numpy.argwhere", "numpy.all", "numpy.random.uniform", "numpy.array", "numpy.meshgrid", "numpy.ze...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
alx/joliGAN
[ "f6350d78a73a2d705a22f80d97b6565f4372a3db", "f6350d78a73a2d705a22f80d97b6565f4372a3db" ]
[ "data/online_creation.py", "models/modules/resnet_architecture/mobile_resnet_generator.py" ]
[ "import math\nimport numpy as np\nimport random\nfrom PIL import Image\nimport torchvision.transforms.functional as F\nfrom torchvision.transforms import InterpolationMode\nfrom tqdm import tqdm\n\ndef crop_image(img_path,bbox_path,mask_delta,crop_delta,mask_square,crop_dim,output_dim):\n\n img = np.array(Image....
[ [ "numpy.zeros", "numpy.full" ], [ "torch.nn.Sequential", "torch.nn.Softmax", "torch.nn.Dropout", "torch.nn.ReflectionPad2d", "torch.nn.ConvTranspose2d", "torch.nn.Conv2d", "torch.nn.Tanh", "torch.nn.InstanceNorm2d", "torch.nn.ReLU", "torch.nn.functional.pad", ...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
hzursa/Play-Reader
[ "d3486fd8306fecc92439606736edbda5a4b1e381" ]
[ "genderbyname.py" ]
[ "import pandas as pd\nimport numpy as np\nfrom sklearn.feature_extraction.text import CountVectorizer\nfrom sklearn.feature_extraction import DictVectorizer\nfrom sklearn.model_selection import train_test_split\nfrom sklearn.tree import DecisionTreeClassifier\nfrom sklearn.naive_bayes import MultinomialNB\ndef feat...
[ [ "pandas.read_csv", "sklearn.naive_bayes.MultinomialNB", "sklearn.model_selection.train_test_split", "numpy.vectorize", "sklearn.feature_extraction.DictVectorizer", "pandas.to_numeric" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.3", "1.1", "1.5", "1.2" ], "scipy": [], "tensorflow": [] } ]
MasazI/python-r-stan-bayesian-model
[ "05a224958a3f5cbea207001465ac12b6862d9d9f" ]
[ "2-5.py" ]
[ "###############\n#\n# Translate R to Python Copyright (c) 2019 Masahiro Imai Released under the MIT license\n#\n###############\n\nimport os\n\nimport pystan\nimport pandas\nimport pickle\nimport matplotlib.pyplot as plt\nimport numpy as np\nimport seaborn as sns\n\nimport arviz as az\n\nfile_beer_sales_1 = pandas...
[ [ "pandas.read_csv", "matplotlib.pyplot.tight_layout", "matplotlib.pyplot.title", "numpy.arange", "numpy.median", "numpy.quantile", "matplotlib.pyplot.plot", "matplotlib.pyplot.subplot", "numpy.mean", "matplotlib.pyplot.show", "matplotlib.pyplot.figure" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.1", "1.5", "1.2", "1.3" ], "scipy": [], "tensorflow": [] } ]
quic-bharathr/aimet
[ "c6ffd3c31c290fe0913b50831d58534f6df61d76", "363308217dca3fc52644bdda31e69e356397adaf" ]
[ "NightlyTests/torch/test_quantize_resnet18.py", "TrainingExtensions/tensorflow/src/python/aimet_tensorflow/examples/test_models.py" ]
[ "# /usr/bin/env python3.5\n# -*- mode: python -*-\n# =============================================================================\n# @@-COPYRIGHT-START-@@\n# \n# Copyright (c) 2017-2018, Qualcomm Innovation Center, Inc. All rights reserved.\n# \n# Redistribution and use in source and binary forms, with or wit...
[ [ "torch.nn.CrossEntropyLoss", "torch.cuda.empty_cache", "torch.device", "torch.cuda.memory_allocated", "torch.optim.lr_scheduler.StepLR" ], [ "tensorflow.python.keras.layers.Flatten", "tensorflow.python.keras.layers.Dense", "tensorflow.stack", "tensorflow.equal", "tensor...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10" ] } ]
NovemberChopin/GuideLine
[ "d49b3b527a5e54f3ee734c8d5245efb89150d594" ]
[ "BSpline/parameter_selection.py" ]
[ "import numpy as np\n\n# 参数域均匀分布\ndef uniform_spaced(n):\n '''\n Calculate parameters using the uniform spaced method.\n :param n: the number of the data points\n :return: parameters\n '''\n parameters = np.linspace(0, 1, n)\n return parameters\n\n# 根据数据点弦长关系分割参数域\ndef chord_length(n, P):\n ...
[ [ "numpy.zeros", "numpy.sqrt", "numpy.linspace", "numpy.power" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
thomasperrot/aes-square-attack
[ "cdc63f4552324a91fa0e7d9bb14cd481bff65740" ]
[ "aes/square.py" ]
[ "import binascii\nimport logging\nfrom concurrent.futures import ProcessPoolExecutor\nfrom functools import partial\nfrom typing import Callable, Iterable, List, Tuple\n\nimport numpy as np\n\nfrom .common import S_BOX, State\nfrom .key_expension import get_first_key\n\nSQUARE_ROUNDS = 4\nREVERSED_S_BOX = {v: k for...
[ [ "numpy.full" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
ska-sa/mkatsim
[ "94f0e5fb28bf3f9c18f0559f9049636db2abcc27" ]
[ "mkatsim/subarray/telescopearray.py" ]
[ "#! /usr/bin/python\n## Display array antenna locations on EARTH grid using astropy coordinates\n\nimport numpy\nimport matplotlib.pyplot as plt\nfrom mpl_toolkits.basemap import Basemap\n\n# Copied library functions\ndef shoot(lon, lat, azimuth, maxdist=None):\n \"\"\"Shooter Function\n Original javascript o...
[ [ "matplotlib.pyplot.legend", "numpy.sqrt", "matplotlib.pyplot.title", "numpy.abs", "numpy.min", "numpy.arange", "numpy.cos", "matplotlib.pyplot.savefig", "numpy.sin", "numpy.arctan2", "matplotlib.pyplot.plot", "matplotlib.pyplot.axes", "numpy.tan", "numpy.max...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
trangvu/ape-npi
[ "4ae2cd6ed1be773dfe1513458d5e7adae0d46283" ]
[ "translate/translation_model.py" ]
[ "import tensorflow as tf\nimport os\nimport pickle\nimport re\nimport time\nimport numpy as np\nimport sys\nimport math\nimport shutil\nimport itertools\nfrom collections import OrderedDict\nfrom translate import utils, evaluation, import_graph\nfrom translate.seq2seq_model import Seq2SeqModel\nfrom subprocess impo...
[ [ "tensorflow.train.get_checkpoint_state", "tensorflow.get_default_session", "tensorflow.device", "tensorflow.get_variable", "tensorflow.Variable", "tensorflow.global_variables", "tensorflow.trainable_variables", "tensorflow.global_variables_initializer", "tensorflow.train.Saver"...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10" ] } ]
Mohamed-hanafy30/Disasters-pipeline-project-
[ "83787c04063f05404eab8f72c0710980588fb3c5" ]
[ "data/process_data.py" ]
[ "import sys\nimport pandas as pd\nfrom sqlalchemy import create_engine\n\ndef load_data(messages_filepath, categories_filepath):\n \"\"\"Load dataframe from filepaths\n\n INPUT\n messages_filepath -- str, link to file\n categories_filepath -- str, link to file\n\n OUTPUT\n df - pandas DataFrame\n ...
[ [ "pandas.concat", "pandas.read_csv" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.3", "1.1", "1.5", "1.2" ], "scipy": [], "tensorflow": [] } ]
swarajthakur/deep-q-learning
[ "7856f2f003455c6c4935c902d722fe435bded863" ]
[ "dqn.py" ]
[ "# -*- coding: utf-8 -*-\nimport random\nimport gym\nimport numpy as np\nfrom collections import deque\nfrom keras.models import Sequential\nfrom keras.layers import Dense\nfrom keras.optimizers import Adam\n\nEPISODES = 1000\n\nclass DQNAgent:\n def __init__(self, state_size, action_size):\n self.state_s...
[ [ "numpy.reshape", "numpy.argmax", "numpy.random.rand" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
leoorshansky/DeepCTR-Torch-MLET
[ "54e8f947ac677b5c0afe7967a224fb8d9cceb516" ]
[ "deepctr_torch/inputs.py" ]
[ "# -*- coding:utf-8 -*-\n\"\"\"\nAuthor:\n Weichen Shen,wcshen1994@163.com\n\"\"\"\n\nfrom collections import OrderedDict, namedtuple, defaultdict\nfrom itertools import chain\n\nimport torch\nimport torch.nn as nn\nimport numpy as np\n\nfrom .layers.sequence import SequencePoolingLayer\nfrom .layers.utils impor...
[ [ "torch.nn.functional.embedding", "torch.nn.Parameter", "torch.Tensor", "torch.cat", "torch.nn.Embedding", "torch.matmul", "torch.nn.init.normal_", "torch.no_grad", "numpy.array" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
gmagannaDevelop/TousAntiCovid
[ "7174845b0614b6a20e48834d5a76579cfbf80bd6" ]
[ "metrics/probability_analysis.py" ]
[ "#!/usr/bin/env python3\n\nimport sys\nimport pandas as pd\n\nif __name__ == \"__main__\":\n x = pd.read_csv(sys.argv[1] , header=None)\n x.columns = [\"lambda\", \"doctor\", \"virus\"]\n print(x.describe())\n" ]
[ [ "pandas.read_csv" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.1", "1.5", "1.2", "1.3" ], "scipy": [], "tensorflow": [] } ]
alexlyttle/cpnest
[ "ae620b5f214a7a2a52e16ef5f2fe7354992aff88" ]
[ "tests/test_half_gaussian.py" ]
[ "import sys\nimport unittest\nimport numpy as np\nfrom scipy import integrate,stats\nimport cpnest\nimport cpnest.model\nimport matplotlib as mpl\nmpl.use('Agg')\nfrom matplotlib import pyplot as plt\n\nclass HalfGaussianModel(cpnest.model.Model):\n \"\"\"\n A simple gaussian model with parameters mean and si...
[ [ "numpy.log", "numpy.sqrt", "numpy.linspace", "matplotlib.pyplot.title", "numpy.abs", "matplotlib.use", "matplotlib.pyplot.savefig", "scipy.stats.norm", "numpy.zeros", "matplotlib.pyplot.figure" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
trungvdhp/mpsnet
[ "e76979e2f8ecd9ea50a0d864533494af2afbb2d4" ]
[ "Keras_Code/model/nets.py" ]
[ "from model.adacos import AdaCos\nfrom model.blocks import NetBlock\nfrom tensorflow.keras.layers import Input, Reshape, Conv2D, Activation, Flatten, Dropout, add\nfrom tensorflow.keras.models import Model\nimport tensorflow.keras.backend as K\n\nclass Net:\n \n def __init__(self, config):\n self.model...
[ [ "tensorflow.keras.layers.Dropout", "tensorflow.keras.models.Model", "tensorflow.keras.backend.int_shape", "tensorflow.keras.layers.add", "tensorflow.keras.layers.Reshape", "tensorflow.keras.layers.Flatten", "tensorflow.keras.layers.Input" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "2.7", "2.2", "2.3", "2.4", "2.5", "2.6" ] } ]
neerajbafila/pytorch-CNN
[ "9828166149b73473138ab54ee45bec054eb9e591" ]
[ "src/utils/evaluation_model.py" ]
[ "from unittest import result\nimport torch\nimport os\nimport logging\nfrom src.utils.common import read_yaml, create_directories\nimport argparse\nimport numpy as np\nimport matplotlib.pyplot as plt\nimport seaborn as sns\nfrom sklearn.metrics import confusion_matrix, classification_report\nfrom pathlib import Pat...
[ [ "torch.load", "torch.argmax", "sklearn.metrics.confusion_matrix", "matplotlib.pyplot.savefig", "numpy.concatenate", "torch.no_grad", "torch.cuda.is_available", "numpy.array", "matplotlib.pyplot.show", "matplotlib.pyplot.figure" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
dougct/predictability
[ "9dbc905b75900477637f3f90a5c4da27c3c778d9" ]
[ "entropy.py" ]
[ "# -*- coding: utf-8 -*-\n\nimport math\nimport numpy as np\n\n\ndef uniform_entropy(sequence):\n \"\"\"\n Computes the \"random entropy\", that is, the entropy of a uniform distribution.\n\n Equation:\n $H_{uniform} = \\log_{2}(n)$, where n is the number of unique symbols in the input sequence.\n\n...
[ [ "numpy.log2", "numpy.logical_and", "numpy.unique" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
goesslfabian/unify-eval
[ "ced486e44ca57ed31b552fd20b53cae61015e486" ]
[ "unify_eval/utils/load_data.py" ]
[ "import abc\nimport sys\nfrom abc import ABC\nfrom typing import List, Iterator, Dict, Callable\n\nimport numpy as np\nfrom tqdm import tqdm\n\n\nclass DataLoader(ABC):\n @abc.abstractmethod\n def next_minibatch(self, minibatch_size: int = 16):\n pass\n\n @abc.abstractmethod\n def is_exhausted(se...
[ [ "numpy.random.choice", "numpy.min", "numpy.arange", "numpy.ceil", "numpy.array" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
dennis-j-lee/AirNet-SNL
[ "c35b84b50b7f1351a450a5970b19d8a8b83053d1" ]
[ "airnetSNL/model/train_loop.py" ]
[ "import errno\nimport numpy as np\nimport os\nimport torch\nfrom torch.nn import functional as F\n\n\ndef train_model(model: torch.nn.Module,\n optimizer: torch.optim.Adam,\n train_loader: torch.utils.data.DataLoader,\n nEpochs: int,\n saveModel: bool = Fa...
[ [ "torch.ones", "torch.cat", "torch.load", "numpy.ones", "torch.tensor", "torch.nn.functional.mse_loss", "torch.save" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
jayunit100/katib
[ "d6ea2d5b3ce5a2ca454b079e18e0dc0d4f7dfeed" ]
[ "pkg/suggestion/bayesianoptimization/src/algorithm_manager.py" ]
[ "\"\"\" module for algorithm manager \"\"\"\n\nimport numpy as np\n\nfrom pkg.api.python import api_pb2\nimport logging\nfrom logging import getLogger, StreamHandler, INFO, DEBUG\n\ndef deal_with_discrete(feasible_values, current_value):\n \"\"\" function to embed the current values to the feasible discrete spac...
[ [ "numpy.hstack", "numpy.absolute", "numpy.subtract", "numpy.argmin", "numpy.array", "numpy.zeros" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
maryamhgf/Heterogeneous-Multiscale-
[ "dd41532a98603d7b75a035b14d28586dd4133baa" ]
[ "examples/Toy_Example_HMM.py" ]
[ "#run export PYTHONPATH=\"${PYTHONPATH}:/home/mhaghifam/Documents/Research/Neural-ODE/Code/torchdiffeq/torchdiffeq\" to be able to import torchdiffeq\n\nimport os\nimport argparse\nimport time\nimport numpy as np\n\nimport torch\nimport torch.nn as nn\nimport torch.optim as optim\nimport matplotlib.pyplot as plt\n\...
[ [ "matplotlib.pyplot.legend", "torch.sin", "torch.zeros", "matplotlib.pyplot.plot", "torch.no_grad", "torch.cuda.is_available", "torch.Size", "torch.tensor", "matplotlib.pyplot.figure", "torch.linspace", "matplotlib.pyplot.title", "torch.full", "torch.nn.init.cons...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
DonovanZhu/minimalRL
[ "333d22e226a168e7af327913cd07f6cc4637acb0" ]
[ "a2c.py" ]
[ "import gym\nimport torch\nimport torch.nn as nn\nimport torch.nn.functional as F\nimport torch.optim as optim\nfrom torch.distributions import Categorical\nimport torch.multiprocessing as mp\nimport time\nimport numpy as np\n\n# Hyperparameters\nn_train_processes = 3\nlearning_rate = 0.0002\nupdate_interval = 5\ng...
[ [ "torch.nn.functional.softmax", "torch.from_numpy", "numpy.stack", "torch.tensor", "torch.nn.Linear", "torch.distributions.Categorical", "torch.log", "torch.multiprocessing.Pipe", "torch.multiprocessing.Process" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
MrRubyRed/DLS
[ "9dd92e83c8ce1a7ec9b3954b7c4640f2fb8dd1dd" ]
[ "DeepLS.py" ]
[ "import reachable_computation as Utils\nimport baselines.common.tf_util as U\nimport numpy as np\nimport tensorflow as tf\nimport pickle\nimport cvxpy\nimport os\n\n#Define a new TF session\nsess = U.single_threaded_session()\nsess.__enter__()\n\n#Experiment Directory\ndirectory = \"/home/vrubies/Documents/Research...
[ [ "tensorflow.get_collection", "numpy.linalg.norm", "numpy.ones", "numpy.array", "numpy.zeros" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10", "1.12", "1.4", "1.13", "1.5", "1.7", "0.12", "1.0", "1.2" ] } ]
FlyBrainLab/Neuroballad
[ "dc8f3aef60e89183e4d5644a226aaf76addcacd1" ]
[ "neuroballad/neuroballad.py" ]
[ "#!/usr/bin/env python\n\"\"\"\nNeuroballad circuit class and components for simplifying Neurokernel/Neurodriver\nworkflow.\n\"\"\"\nfrom __future__ import absolute_import\nimport os\nimport copy\nimport json\nimport h5py\nimport time\nimport random\nimport pickle\nimport inspect\nimport argparse\nimport itertools\...
[ [ "matplotlib.use" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
593903762/center
[ "1093f4519422d417b44d5caa4aea12fa7141ba55" ]
[ "src/cocoeval.py" ]
[ "__author__ = 'tsungyi'\n\nimport numpy as np\nimport datetime\nimport time\nfrom collections import defaultdict\nfrom . import mask as maskUtils\nimport copy\n\nclass COCOeval:\n # Interface for evaluating detection on the Microsoft COCO dataset.\n #\n # The usage for CocoEval is as follows:\n # cocoG...
[ [ "numpy.logical_not", "numpy.spacing", "numpy.unique", "numpy.cumsum", "numpy.ones", "numpy.concatenate", "numpy.round", "numpy.max", "numpy.mean", "numpy.count_nonzero", "numpy.searchsorted", "numpy.exp", "numpy.argsort", "numpy.repeat", "numpy.array", ...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
IPUdk/iputemplates
[ "f182305ffbdd95a75cc55ba8a6a570aca6f78c54" ]
[ "tex/latex/ipu/ipucolours.py" ]
[ "# -*- coding: utf-8 -*-\nfrom __future__ import print_function, division, absolute_import\nimport matplotlib as mpl\nimport matplotlib.cm as mplcm\nfrom cycler import cycler \nimport numpy as np\nfrom matplotlib.colors import LinearSegmentedColormap\n#import brewer2mpl\nfrom itertools import cycle\nimport platform...
[ [ "numpy.linspace", "matplotlib.cm._reverse_cmap_spec", "matplotlib.cm.get_cmap", "matplotlib._cm.cubehelix", "matplotlib.cm.register_cmap" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
mmjazzar/-python-snippets
[ "fa53a6bc5c2f60b8a19677ae8dc848fdb6197589" ]
[ "open cv_example 1.py" ]
[ "import cv2\r\nimport numpy as np\r\n\r\nimg = cv2.imread('C:\\\\Users\\\\mmjaz\\\\Desktop\\\\OneDrive_3_7-3-2017\\\\Button\\\\images_190.jpeg')\r\n\r\nimg = cv2.imread('C:\\\\Users\\\\mmjaz\\\\Desktop\\\\OneDrive_3_7-3-2017\\\\OneDrive_4_7-3-2017\\\\pop up.jpg')\r\n\r\ngray= cv2.imread('C:\\\\Users\\\\mmjaz\\\\Des...
[ [ "numpy.float32" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
ltthinhtb/image_bit
[ "4f4118355b44d5b2d6e4537334065ebdc8312ad1" ]
[ "main.py" ]
[ "import argparse\nimport logging\nimport random\nimport numpy as np\nimport cv2\n\nlogging.basicConfig(level=logging.DEBUG)\n\n\ndef convert_image_to_bit_planes(img, bit_size):\n \"\"\"\n Convert a color image to separate rgb bit planes\n\n Parameters:\n img: OpenCV image\n bit_size: \n\n Returns\...
[ [ "numpy.packbits", "numpy.unpackbits" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
rahul263-stack/TIGRE
[ "073b9c6d42f71f42451c4cd2db68ba8d67363e4c" ]
[ "Python/tigre/algorithms/krylov_subspace_algorithms.py" ]
[ "from __future__ import division\r\n\r\nimport time\r\n\r\nimport numpy as np\r\nimport tigre\r\nfrom tigre.algorithms.iterative_recon_alg import IterativeReconAlg\r\nfrom tigre.algorithms.iterative_recon_alg import decorator\r\nfrom tigre.utilities.Atb import Atb\r\nfrom tigre.utilities.Ax import Ax\r\n\r\n\r\nif ...
[ [ "numpy.zeros", "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": [], ...
vaesl/LFIP
[ "eb9d934616c508c9a9032f170baa1d97fa792822" ]
[ "models/LFIP_VOC_300.py" ]
[ "import torch\nimport torch.nn as nn\n\n\nclass ConvBlock(nn.Module):\n\n def __init__(self, in_planes, out_planes, kernel_size, stride=1, padding=0, dilation=1, groups=1, relu=True, bn=True, bias=False):\n super(ConvBlock, self).__init__()\n self.out_channels = out_planes\n self.conv = nn.C...
[ [ "torch.nn.Softmax", "torch.nn.ModuleList", "torch.nn.Conv2d", "torch.nn.MaxPool2d", "torch.nn.BatchNorm2d", "torch.nn.ReLU" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
wakeful-sun/vehicle-detector
[ "080eab6acb2fc11dc5ea5a93ee5437347612aab2" ]
[ "code/classifier/tools.py" ]
[ "import numpy as np\r\n\r\n\r\ndef insert_separator(items, separator):\r\n row = []\r\n for index, item in enumerate(items):\r\n if index:\r\n row.append(separator)\r\n row.append(item)\r\n return row\r\n\r\n\r\ndef create_composite_image(bgr_images, h_span=5, v_span=5, n_columns=3...
[ [ "numpy.hstack", "numpy.zeros", "numpy.vstack" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
mynameisguy/tensorflow
[ "2803742817755846f847ac506bbe20b4d4a14195" ]
[ "tensorflow/contrib/rnn/python/ops/rnn_cell.py" ]
[ "# Copyright 2015 The TensorFlow Authors. All Rights Reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless requ...
[ [ "tensorflow.python.ops.math_ops.log", "tensorflow.python.ops.array_ops.constant", "tensorflow.python.ops.array_ops.shape", "tensorflow.python.ops.array_ops.split", "tensorflow.contrib.compiler.jit.experimental_jit_scope", "tensorflow.python.framework.op_def_registry.get_registered_ops", ...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "2.8", "1.10", "2.7", "1.4", "2.6", "2.3", "2.4", "2.9", "1.5", "1.7", "2.5", "0.12", "1.0", "2.2", "1.2", "2.10" ] } ...
sxontheway/milliEye
[ "bfdb041c978a45d7481071e8e9579d226ce523ff", "bfdb041c978a45d7481071e8e9579d226ce523ff" ]
[ "module3_our_dataset/yolov3/models.py", "module2_mixed/test_mixed.py" ]
[ "from __future__ import division\n\nimport torch\nimport torch.nn as nn\nimport torch.nn.functional as F\nfrom torch.autograd import Variable\nimport numpy as np\n\nfrom utils.parse_config import *\nfrom utils.utils import build_targets, to_cpu\n\ndef create_modules(module_defs):\n \"\"\"\n Constructs module ...
[ [ "torch.nn.Sequential", "torch.sigmoid", "numpy.fromfile", "torch.cat", "torch.nn.ModuleList", "torch.sum", "torch.from_numpy", "torch.arange", "torch.nn.BCELoss", "torch.exp", "torch.nn.LeakyReLU", "torch.nn.functional.interpolate", "torch.nn.BatchNorm2d", "...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
zhangw106/FlamePyrometry
[ "8f0a9473e54bb4a898effc5bb310b8700e6dd9ad" ]
[ "ExaminationTIF.py" ]
[ "# -*- coding: utf-8 -*-\r\n\"\"\"\r\nA useful tool to examine a series of raw2tif images for the FlamePyrometry code.\r\nFor more information on the FlamePyrometry code, please see [https://doi.org/10.1364/AO.58.002662].\r\n\r\nThe inverse Abel transformation is very sensitive to the symmetry of flame and the unif...
[ [ "matplotlib.pyplot.imshow", "matplotlib.pyplot.plot", "numpy.uint8", "numpy.std", "matplotlib.pyplot.subplot", "numpy.argmax", "matplotlib.pyplot.close", "matplotlib.pyplot.subplots_adjust", "matplotlib.pyplot.axis", "numpy.zeros", "matplotlib.pyplot.figure", "matpl...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
bankbiz/image-matching-benchmark
[ "c314f067b2d7337b9e7de0875214bdbab9750afc" ]
[ "methods/feature_matching/nn.py" ]
[ "# Copyright 2020 Google LLC, University of Victoria, Czech Technical University\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....
[ [ "numpy.asarray", "numpy.zeros", "numpy.concatenate", "numpy.empty" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
ADMoreau/CapsNet_Keras
[ "9aa34b6da7e5528c50f72ecf102c4788df561eeb" ]
[ "capsulenet-multi-gpu.py" ]
[ "\"\"\"\nKeras implementation of CapsNet in Hinton's paper Dynamic Routing Between Capsules.\nThe current version maybe only works for TensorFlow backend. Actually it will be straightforward to re-write to TF code.\nAdopting to other backends should be easy, but I have not tested this.\n\nUsage:\n python caps...
[ [ "tensorflow.device", "numpy.argmax" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10", "1.12", "1.4", "1.13", "1.5", "1.7", "0.12", "1.0", "1.2" ] } ]
ami-a/MaskDetection
[ "9df329a24a987e63331c17db154319b3ebcaad74" ]
[ "mask_example/keras_layers/keras_layer_AnchorBoxes.py" ]
[ "'''\nA custom Keras layer to generate anchor boxes.\n\nCopyright (C) 2018 Pierluigi Ferrari\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....
[ [ "numpy.expand_dims", "numpy.sqrt", "numpy.linspace", "numpy.meshgrid", "numpy.tile", "numpy.concatenate", "numpy.zeros_like", "numpy.any", "numpy.array", "numpy.zeros" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
pillera/cta-lstchain
[ "699b8385bc4bdc35b226c14020638f5d2fcf3c07", "699b8385bc4bdc35b226c14020638f5d2fcf3c07" ]
[ "lstchain/visualization/plot_drs4.py", "lstchain/calib/camera/r0.py" ]
[ "\nfrom matplotlib import pyplot as plt\nfrom traitlets.config.loader import Config\nimport numpy as np\nfrom matplotlib.backends.backend_pdf import PdfPages\nfrom ctapipe.io import event_source\nfrom lstchain.calib.camera.r0 import LSTR0Corrections\nfrom ctapipe.io.containers import PedestalContainer\nfrom ctapipe...
[ [ "matplotlib.pyplot.legend", "numpy.linspace", "matplotlib.pyplot.rc", "matplotlib.pyplot.step", "matplotlib.pyplot.plot", "matplotlib.backends.backend_pdf.PdfPages", "matplotlib.pyplot.tight_layout", "numpy.arange", "numpy.std", "matplotlib.pyplot.subplot", "matplotlib....
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
amanyara/Boston-Home-Price-Forecast
[ "600ccb25c40240ffddee8871d77728a782a80498" ]
[ "Paddle_house_predict.py" ]
[ "# 19200300157\r\n# 张宇含\r\n#加载飞桨、Numpy和相关类库\r\nimport paddle\r\nfrom paddle.nn import Linear\r\nimport paddle.nn.functional as F\r\nimport numpy as np\r\n\r\n\r\ndef load_data():\r\n # 从文件导入数据\r\n datafile = 'housing.data'\r\n data = np.fromfile(datafile, sep=' ', dtype=np.float32)\r\n\r\n # 每条数据包括14项,其...
[ [ "numpy.array", "numpy.fromfile", "numpy.random.shuffle" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
infobeisel/lightmetrica-v3
[ "833d74e5ed8a470c33aca100c9494be11ecbf1be" ]
[ "functest/func_render_all.py" ]
[ "# ---\n# jupyter:\n# jupytext:\n# formats: ipynb,py:light\n# text_representation:\n# extension: .py\n# format_name: light\n# format_version: '1.4'\n# jupytext_version: 1.2.4\n# kernelspec:\n# display_name: Python 3\n# language: python\n# name: python3\n# ---\n\n# ## ...
[ [ "matplotlib.pyplot.show", "numpy.power", "matplotlib.pyplot.figure" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
jamesthesken/stock-scraper
[ "619e6689a4963deeea2b60c63c869eb43d017f3d" ]
[ "wsb_scraper.py" ]
[ "import config\nimport praw\nfrom praw.models import MoreComments\nimport pandas as pd\nimport matplotlib.pyplot as plt\nfrom vaderSentiment.vaderSentiment import SentimentIntensityAnalyzer\nfrom sqlalchemy import create_engine\n\n# Creates a set of stock tickers in NASDAQ\ndef nasdaq_tickers():\n fin = open(\"n...
[ [ "matplotlib.pyplot.show", "matplotlib.pyplot.subplots", "pandas.DataFrame", "matplotlib.pyplot.savefig" ] ]
[ { "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": [] } ]
Lucien-MG/torchreinforce
[ "5ba852bb255c14140d7bc300a44e60e7b4b572ff" ]
[ "torchreinforce/agents/temporal_difference.py" ]
[ "import warnings\nfrom collections import namedtuple, defaultdict\nfrom functools import partial\nfrom typing import Optional, Tuple, List, Callable, Any\n\nimport torch\nfrom torch import Tensor\nfrom torch import distributions\nfrom torch import nn\n\nclass TemporalDifference(nn.Module):\n def __init__(\n ...
[ [ "torch.distributions.binomial.Binomial", "torch.zeros", "torch.max", "torch.argmax" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
frankling2020/Self-learn-Repo
[ "294df18469d6d4ef6d479b1b533f42445cd01ac1" ]
[ "GNN_PRP/prp_3_21/adgcl/test_transfer_finetune_chem.py" ]
[ "import argparse\nimport logging\nimport random\n\nimport numpy as np\nimport pandas as pd\nimport torch\nimport torch.nn as nn\nimport torch.optim as optim\nfrom sklearn.metrics import roc_auc_score\nfrom torch_geometric.data import DataLoader\nfrom tqdm import tqdm\n\nfrom datasets import MoleculeDataset\nfrom tr...
[ [ "torch.optim.Adam", "sklearn.metrics.roc_auc_score", "pandas.read_csv", "numpy.random.seed", "torch.cat", "torch.zeros", "torch.manual_seed", "torch.sum", "torch.nn.BCEWithLogitsLoss", "torch.no_grad", "torch.cuda.manual_seed_all", "torch.cuda.is_available", "nu...
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.1", "1.5", "1.2", "1.3" ], "scipy": [], "tensorflow": [] } ]
ChristophReich1996/ECG_Classification
[ "d281e0d3df85e7917e7a838529d073cf4b0a71a4" ]
[ "predict.py" ]
[ "from typing import List, Tuple, Union, Dict\n\nimport torch\nimport torch.nn as nn\nfrom torch.utils.data import DataLoader\nimport torch_optimizer\nimport numpy as np\nimport os\nfrom tqdm import tqdm\n\nos.environ[\"CUDA_VISIBLE_DEVICES\"] = \"0\"\n\nfrom ecg_classification import *\nfrom wettbewerb import load_...
[ [ "torch.optim.lr_scheduler.MultiStepLR", "torch.utils.data.DataLoader", "torch.no_grad", "torch.load" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
sagar1993/BrainNet_server
[ "70972f4ccd06bb2615afc19a8e077fb9e39470f3" ]
[ "service/feature_extractor.py" ]
[ "import numpy as np\nfrom pyedflib import EdfReader\nfrom sklearn.naive_bayes import GaussianNB\nfrom sklearn.metrics import confusion_matrix\n\n\ndef featureVecs(out, sample_size):\n # sample_size = 120\n fVec = np.zeros((sample_size, 6), dtype=float)\n\n i = 0\n j = 0\n while i < len(out) and j < s...
[ [ "sklearn.naive_bayes.GaussianNB", "numpy.fft.fft", "numpy.arange", "sklearn.metrics.confusion_matrix", "numpy.ones", "numpy.zeros" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
ivanB1975/scipy
[ "8fed46cd7e7b5b63eb101c5d5d521ff7d7bac9b9" ]
[ "setup.py" ]
[ "#!/usr/bin/env python\n\"\"\"SciPy: Scientific Library for Python\n\nSciPy (pronounced \"Sigh Pie\") is open-source software for mathematics,\nscience, and engineering. The SciPy library\ndepends on NumPy, which provides convenient and fast N-dimensional\narray manipulation. The SciPy library is built to work with...
[ [ "numpy.distutils.misc_util.Configuration", "numpy.distutils.core.setup", "numpy.distutils.command.build_clib.build_clib.build_a_library", "scipy._build_utils.system_info.get_info", "scipy._build_utils.system_info.NotFoundError", "numpy.distutils.command.build_ext.build_ext.build_extension"...
[ { "matplotlib": [], "numpy": [ "1.11", "1.19", "1.24", "1.16", "1.23", "1.20", "1.7", "1.12", "1.21", "1.22", "1.14", "1.6", "1.13", "1.9", "1.17", "1.10", "1.18", "1.15", "1.8" ], "pand...
amessadiqi/humorDetection
[ "998a46219b0ef593d7ad416a649f232e6a79c2c2" ]
[ "HumorDetector.py" ]
[ "import pandas as pd\nfrom data_processing.DataProcessor import DataProcessor\nfrom humor_features.HumorFeatures import HumorFeatures\nfrom humor_model.Models import Models\nfrom prediction_server.app import app\n\n\nclass HumorDetector:\n def __init__(self, dataset = None):\n if isinstance(dataset, pd.Da...
[ [ "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": [] } ]
Jakob-Unfried/jax
[ "bec943cee0234178a9143a0447b224a5faa9fbdc" ]
[ "tests/api_test.py" ]
[ "# Copyright 2018 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.__version__.split", "numpy.asarray", "numpy.dtype", "numpy.all", "numpy.random.randn", "numpy.iinfo", "numpy.exp", "numpy.arange", "numpy.eye", "numpy.float16", "numpy.sin", "numpy.float32", "numpy.zeros", "numpy.random.rand", "numpy.testing.asser...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
Ozgay/MockingBird
[ "b46e7a78667732114c22d4f5774c8481d6b75683" ]
[ "toolbox/__init__.py" ]
[ "from toolbox.ui import UI\nfrom encoder import inference as encoder\nfrom synthesizer.inference import Synthesizer\nfrom vocoder.wavernn import inference as rnn_vocoder\nfrom vocoder.hifigan import inference as gan_vocoder\nfrom pathlib import Path\nfrom time import perf_counter as timer\nfrom toolbox.utterance im...
[ [ "numpy.abs", "torch.manual_seed", "numpy.concatenate", "numpy.array", "numpy.random.randint" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
slocke716/airflow
[ "d5ad0761fd0b33cb89258ff6924c608c3e086680" ]
[ "tests/hooks/test_hive_hook.py" ]
[ "# -*- coding: utf-8 -*-\n#\n# 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...
[ [ "pandas.read_csv", "pandas.DataFrame" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.3", "1.1", "1.5", "1.2" ], "scipy": [], "tensorflow": [] } ]
netaz/dirty-rl
[ "189b377b09db9c183fac78274ecfc7857bec695b" ]
[ "utils/utils.py" ]
[ "import torch\nimport os\nfrom colorama import Fore, Back, Style\n\n\ndtype = torch.cuda.FloatTensor if torch.cuda.is_available() else torch.FloatTensor\n\n\n\"\"\"Various decorators\"\"\"\n\ndef cached_function(func):\n \"\"\"Use this wrapper for functions that run often, but always return the same result.\n\n ...
[ [ "torch.load", "torch.cuda.is_available", "torch.save" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
wty9391/maximal-revenue-rtb
[ "a0c8cc5e03e2306023e77323c8f0bfc5b4988823" ]
[ "winner.py" ]
[ "#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\n\nimport sys\nimport numpy as np\nimport matplotlib.pyplot as plt\nfrom scipy.integrate import quad\n\nepsilon = sys.float_info.epsilon\n\nclass wining_pridictor():\n def __init__(self,d=0.1,max_iter=5000,eta=0.001,step=1,eta_decay=0.99):\n self.d = d\n ...
[ [ "matplotlib.pyplot.legend", "numpy.arange", "matplotlib.pyplot.plot", "numpy.round", "numpy.zeros_like", "numpy.shape", "numpy.tanh" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
LucSkyvvalker/TAUS
[ "a804de4386fa31de3fb9a7aebbd686ba2c12a243" ]
[ "scripts/scoreModel.py" ]
[ "import extractSents as es\nimport pandas as pd\nimport numpy as np\nimport cleandatas as cd\nimport learnclassify as lc\nimport score as sc\nimport corpusFuncs as corpf\n\n\n\"\"\"\nscoreModel() is used to get a print of:\n'Precision, Recall\nF1-score\nAccuracy\nCross Entropy'\nThe function will ask for input on w...
[ [ "pandas.read_csv", "numpy.mean" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.1", "1.5", "1.2", "1.3" ], "scipy": [], "tensorflow": [] } ]
dreamflyer/musket_core
[ "1bdf1b4715a3b5c63bf687799d7b977fdf49053f" ]
[ "musket_core/crf.py" ]
[ "from __future__ import absolute_import\r\nfrom __future__ import division\r\n\r\nimport warnings\r\n\r\nfrom keras import backend as K\r\nfrom keras import activations\r\nfrom keras import initializers\r\nfrom keras import regularizers\r\nfrom keras import constraints\r\nfrom keras.layers import Layer\r\nfrom kera...
[ [ "tensorflow.gather_nd", "tensorflow.range" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10", "1.12", "1.4", "1.13", "1.5", "1.7", "0.12", "1.0", "1.2" ] } ]
seanpquinn/augerta
[ "43862fd6b5360c9b7c5a7b3502fb7738ea2e8d75" ]
[ "web_monitor/north_daily_events_final_2016_catchup.py" ]
[ "import time\nimport math\nimport datetime\nimport matplotlib\nmatplotlib.use('Agg')\nimport matplotlib.pyplot as plt\nfrom matplotlib.dates import DateFormatter, date2num\nimport numpy as np\nimport subprocess as sp\nimport time\nimport sys\nimport os\nfrom itertools import groupby\nfrom sklearn.neighbors import K...
[ [ "numpy.linspace", "matplotlib.pyplot.step", "matplotlib.pyplot.plot", "matplotlib.pyplot.tight_layout", "numpy.arange", "matplotlib.pyplot.subplot", "matplotlib.pyplot.close", "numpy.zeros", "matplotlib.pyplot.title", "matplotlib.pyplot.ylim", "matplotlib.pyplot.savefig...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
brendankeith/PyMFEM
[ "5ff7c88cae07ca2a0dfe0b1d4224491c31c8c2ed" ]
[ "mfem/_par/sparsemat.py" ]
[ "# This file was automatically generated by SWIG (http://www.swig.org).\n# Version 4.0.2\n#\n# Do not make changes to this file unless you know what you are doing--modify\n# the SWIG interface file instead.\n\nfrom sys import version_info as _swig_python_version_info\nif _swig_python_version_info < (2, 7, 0):\n ...
[ [ "numpy.ascontiguousarray", "numpy.real" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
escherba/ivis
[ "bbfd8381c0f40f7219585df851ed9a2f4278bee4" ]
[ "ivis/data/sequence/image.py" ]
[ "\"\"\"Custom datasets that load images from disk.\"\"\"\n\nimport numpy as np\nimport tensorflow as tf\n\nfrom .sequence import IndexableDataset\n\n\nclass ImageDataset(IndexableDataset):\n \"\"\"When indexed, loads images from disk, resizes to consistent size, then returns image.\n Since the returned images...
[ [ "tensorflow.image.decode_png", "tensorflow.cast", "tensorflow.image.resize", "numpy.prod", "tensorflow.io.read_file", "tensorflow.image.resize_with_pad", "numpy.array" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
junekihong/beam-span-parser
[ "206e032409640556ac4765a5d15dc2f72fbddd74" ]
[ "src/main.py" ]
[ "import argparse\nimport itertools\nimport os.path\nimport time, timeit\nimport sys\n\nimport dynet as dy\nimport numpy as np\n\nimport evaluate\nimport parse\nimport trees\nimport vocabulary\nimport gc\nfrom collections import defaultdict\n\ndef format_elapsed(start_time):\n elapsed_time = int(time.time() - sta...
[ [ "numpy.random.shuffle", "numpy.random.seed" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]