repo_name
stringlengths
6
130
hexsha
list
file_path
list
code
list
apis
list
possible_versions
list
spider-specimens/todayonhistory-spider
[ "2852e556383442c9a0ce0035d9aafadae427b31d" ]
[ "spider.py" ]
[ "# -*- coding: UTF-8 -*-\nimport time\nimport requests\nimport numpy as np\nfrom bs4 import BeautifulSoup\nimport functools\nimport re\nfrom urllib.parse import urlparse, parse_qs\nimport psycopg2\n\nheaders=[\n {'User-Agent':'Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.1.6) Gecko/20091201 Firefox/3.5...
[ [ "numpy.random.rand" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
Timen/tensorflow-video
[ "3dae3f72769c3312f6d672abefc53a4b3b38000d" ]
[ "tensorflow_extentions/initial_state.py" ]
[ "import tensorflow as tf\nslim = tf.contrib.slim\nfrom tensorflow.python.util import nest\n\ndef get_initial_cell_state(cell, initializer, batch_size, dtype):\n \"\"\"Return state tensor(s), initialized with initializer.\n Args:\n cell: RNNCell.\n batch_size: int, float, or unit Tensor representing ...
[ [ "tensorflow.get_variable", "tensorflow.python.util.nest.is_sequence", "tensorflow.shape", "tensorflow.stack", "tensorflow.expand_dims", "tensorflow.name_scope" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10", "1.4", "1.5", "1.7", "0.12", "1.0", "1.2" ] } ]
PacktWorkshops/Applied-Deep-Learning-with-Keras
[ "d1372a6109e2ee9434ae47df59440577566badaa" ]
[ "Chapter08/Exercise8.03/Exercise8.03_Unit_test.py" ]
[ "import unittest\nimport numpy as np\nimport pandas as pd\nimport numpy.testing as np_testing\nimport pandas.testing as pd_testing\nimport os\nimport import_ipynb\nfrom keras.models import Sequential\nfrom keras.layers import Conv2D, MaxPool2D, Flatten, Dense\nimport numpy as np\nfrom tensorflow import random\nfrom...
[ [ "numpy.expand_dims", "numpy.testing.assert_approx_equal", "numpy.random.seed", "tensorflow.random.set_seed" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
CHENGCHANGHUv/jim-schwoebelv
[ "2b949553362c9541a966ae7c54482a1488140e22" ]
[ "train_audioTPOT.py" ]
[ "'''\n================================================ \n## VOICEBOOK REPOSITORY ## \n================================================ \n\nrepository name: voicebook \nrepository version: 1.0 \nrepository link: https://github.com/jim-schwoebel/voicebook \nauthor: Jim Schwoebel \nauthor co...
[ [ "numpy.asarray", "sklearn.model_selection.train_test_split" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
parth-couture-ai/RecommenderSystems
[ "0a585139de1b49d72511ce5a4a642bd427c1349a" ]
[ "sequentialRec/neural/train.py" ]
[ "#coding: utf-8\n'''\nAuthor: Weiping Song\nContact: songweiping@pku.edu.cn\n'''\n\nimport tensorflow as tf\nimport argparse\nimport numpy as np\nimport sys\nimport time\nimport math\n\nfrom .utils import *\nfrom .model import *\nfrom .sampler import *\n\nparser = argparse.ArgumentParser(description='Sequential or ...
[ [ "tensorflow.ConfigProto", "tensorflow.global_variables_initializer", "tensorflow.Session", "tensorflow.set_random_seed", "numpy.array" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10", "1.12", "1.4", "1.13", "1.5", "1.7", "0.12", "1.0", "1.2" ] } ]
lionfish0/hypercuboid_integrator
[ "beabf2814cbe0020f3c6a52c53f0be720f868de8" ]
[ "hypercuboid_integrator/__init__.py" ]
[ "import numpy as np\n#import numba as nb\n\n#@nb.jit(nb.typeof(([[1.0,1.0],[1.0,1.0]],[True,False]))(nb.double,nb.double,nb.double,nb.double))\ndef split1d(Astart,Aend,Bstart,Bend):\n \"\"\"For a 1-d pair of lines A and B:\n given start and end locations,\n produce new set of points for A, split by B.\n ...
[ [ "numpy.min", "numpy.all", "numpy.max", "numpy.delete", "numpy.argsort", "numpy.array" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
soumye/recalltraces
[ "3d6af8692faf4bd226dafdc02c22cf0a22e5d640" ]
[ "a2c_agent.py" ]
[ "import numpy as np\nimport ipdb\nimport torch\nfrom models import Net\nfrom datetime import datetime\nfrom utils import select_actions, evaluate_actions, discount_with_dones\nimport os\nfrom sil_module import sil_module\nfrom bw_module import bw_module\nimport copy\n\nclass a2c_agent:\n def __init__(self, envs,...
[ [ "torch.zeros", "numpy.asarray", "numpy.stack", "torch.tensor", "numpy.sign", "numpy.copy", "torch.FloatTensor", "torch.no_grad", "numpy.transpose", "numpy.zeros" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
ganileni/py_falcon
[ "a7e187c0140076defee1e89c678ffc96c032c4f8" ]
[ "falcon/test/test_autoEngineShutdown.py" ]
[ "from unittest import TestCase\nimport numpy as np\n\n# TODO -- generalize to a MATLAB function that is not FALCON\nFALCON_DIR = '../'\ntest_matrix = np.loadtxt(FALCON_DIR + 'test.csv', delimiter=',')\n\n\nclass TestAutoEngineShutdown(TestCase):\n def test_working(self):\n import falcon\n # default...
[ [ "numpy.loadtxt" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
anhquannguyen21/Image-Processing
[ "63ad3f475f553bd9283b287e9b3772f41f493c79" ]
[ "Source/LaplaceFilter.py" ]
[ "import numpy as np\r\nimport cv2\r\n\r\nimg = cv2.imread('images/butterfly.jpg', cv2.IMREAD_GRAYSCALE)\r\nimg_out = img.copy()\r\n\r\nheight = img.shape[0]\r\nwidth = img.shape[1]\r\n\r\nlaplace = (1.0/16) * np.array(\r\n [[0, 0, -1, 0, 0],\r\n [0, -1, -2, -1, 0],\r\n [-1, -2, 16, -2, -1],\r\n...
[ [ "numpy.arange", "numpy.array" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
MindMantraSIH/paathshaala
[ "28fcee05f49e7b5dec734d6b9c46a5630e687c5d" ]
[ "Analytics/dashboard.py" ]
[ "import pandas as pd\nimport numpy as np\nimport seaborn as sns\nfrom matplotlib import pyplot as plt\n\ndef analytics(request):\n df = pd.read_csv('/content/Parents Feedback (Responses) - Form Responses 1.csv')\n anx = df[df['Anxiety and pressure felt by students during exams'] > 3]\n number_of_anxious = ...
[ [ "matplotlib.pyplot.legend", "pandas.read_csv", "matplotlib.pyplot.pie", "matplotlib.pyplot.subplot2grid", "matplotlib.pyplot.show", "matplotlib.pyplot.figure" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.1", "1.5", "1.2", "1.3" ], "scipy": [], "tensorflow": [] } ]
RaghavaDhanya/SimSwap
[ "9dc80e258426bbf995d2afe1ee6ea864b8f4b4ea" ]
[ "util/videoswap_specific.py" ]
[ "import os \nimport cv2\nimport glob\nimport torch\nimport shutil\nimport numpy as np\nfrom tqdm import tqdm\nfrom util.reverse2original import reverse2wholeimage\nimport moviepy.editor as mp\nfrom moviepy.editor import AudioFileClip, VideoFileClip \nfrom moviepy.video.io.ImageSequenceClip import ImageSequenceClip\...
[ [ "torch.from_numpy", "numpy.argmin", "torch.nn.functional.interpolate", "numpy.array", "torch.nn.MSELoss" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
diixo/examples
[ "40ce1758fd13929a5f741860a9f50f0a84309b6c" ]
[ "courses/udacity_deep_learning/2_fullyconnected_hidden_adam.py" ]
[ "# These are all the modules we'll be using later. Make sure you can import them\n# before proceeding further.\nfrom __future__ import print_function\nimport numpy as np\nimport tensorflow as tf\nfrom six.moves import cPickle as pickle\nfrom six.moves import range\n\npickle_file = 'notMNIST.pickle'\n\nwith open(pic...
[ [ "tensorflow.Graph", "tensorflow.nn.softmax", "tensorflow.constant", "tensorflow.truncated_normal", "tensorflow.matmul", "tensorflow.zeros", "numpy.arange", "tensorflow.global_variables_initializer", "numpy.argmax", "tensorflow.Session", "tensorflow.nn.softmax_cross_entr...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10" ] } ]
zjzh/sparseml
[ "b92df81257d47eb5aab731bc9929da7339f34667", "b92df81257d47eb5aab731bc9929da7339f34667" ]
[ "src/sparseml/pytorch/optim/modifier_quantization.py", "src/sparseml/transformers/utils/export.py" ]
[ "# Copyright (c) 2021 - present / Neuralmagic, Inc. All Rights Reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Un...
[ [ "torch.quantization.propagate_qconfig_", "torch.quantization.prepare_qat" ], [ "torch.cuda.is_available" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
rossumai/keras
[ "c83ca43005ce81de145f17d112e308b492ddc1e0" ]
[ "tests/keras/test_callbacks.py" ]
[ "import os\nimport multiprocessing\n\nimport numpy as np\nimport pytest\nfrom csv import reader\nfrom csv import Sniffer\nimport shutil\nfrom keras import optimizers\nfrom keras import initializers\nfrom keras import callbacks\nfrom keras.models import Sequential, Model\nfrom keras.layers import Input, Dense, Dropo...
[ [ "numpy.random.random", "numpy.random.seed", "numpy.isnan", "numpy.ones", "numpy.where", "numpy.random.randint" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
modusdatascience/sklearntools
[ "6cb87edcb501440266622fe4c738be3f9015a859" ]
[ "sklearntools/sym/adapters/calibrated_classifier_cv.py" ]
[ "from sklearn.exceptions import NotFittedError\nfrom ..input_size import input_size, register_input_size\nfrom sklearn.calibration import CalibratedClassifierCV, _CalibratedClassifier\nfrom ..sym_predict_proba import register_sym_predict_proba,\\\n sym_predict_proba\nfrom six.moves import reduce\nfrom operator i...
[ [ "sklearn.exceptions.NotFittedError" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
sjperkins/arrow
[ "eb20a3dbc7732f612e5ce54be5f4291440829350" ]
[ "python/pyarrow/tests/test_array.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.isnan", "numpy.arange", "numpy.asarray", "numpy.uint8", "numpy.int8", "pandas.Index", "numpy.dtype", "numpy.datetime64", "numpy.testing.assert_array_equal", "numpy.timedelta64", "numpy.ones", "numpy.int16", "numpy.concatenate", "numpy.int32", "num...
[ { "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": [] } ]
SuperStar0907/lecam-gan
[ "e502c9b182345ddd03d29edda56b76caa7d8fb41" ]
[ "third_party/inception_tf.py" ]
[ "import fnmatch\nimport importlib\nimport inspect\nimport scipy\nimport numpy as np\nimport os\nimport shutil\nimport sys\nimport types\nimport io\nimport pickle\nimport re\nimport requests\nimport html\nimport hashlib\nimport glob\nimport uuid\nfrom typing import Any, List, Tuple, Union\nimport torch\n\nimport thi...
[ [ "numpy.square", "numpy.dot", "numpy.log", "numpy.sum", "numpy.concatenate", "numpy.std", "numpy.real", "numpy.mean", "numpy.cov", "torch.cuda.device_count", "numpy.exp", "numpy.trace" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
purusharths/NumCpp
[ "269b0ff1341b06480c9679285cb6c6c6843df06b" ]
[ "test/pytest/test_filters.py" ]
[ "import numpy as np\r\nimport scipy.ndimage.filters as filters\r\nimport os\r\nimport sys\r\nsys.path.append(os.path.abspath(r'../lib'))\r\nimport NumCppPy as NumCpp # noqa E402\r\n\r\n\r\nmodes = {'reflect': NumCpp.Mode.REFLECT,\r\n 'constant': NumCpp.Mode.CONSTANT,\r\n 'nearest': NumCpp.Mode.NEAR...
[ [ "scipy.ndimage.filters.laplace", "scipy.ndimage.filters.maximum_filter", "scipy.ndimage.filters.uniform_filter", "numpy.array_equal", "numpy.random.seed", "numpy.ones", "numpy.round", "scipy.ndimage.filters.gaussian_filter", "scipy.ndimage.filters.percentile_filter", "numpy...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [ "0.13", "1.6", "0.14", "0.15", "1.4", "0.10", "1.3", "0.19", "1.5", "0.18", "1.2", "1.7", "0.12", "1.0", "0.17", "0.16" ], "tensorflow": [...
hanyas/sds
[ "3c195fb9cbd88a9284287d62c0eacb6afc4598a7" ]
[ "examples/pendulum/sac_policy.py" ]
[ "import numpy as np\n\nimport gym\nimport sds\n\nfrom stable_baselines import SAC\nfrom stable_baselines.sac.policies import MlpPolicy\nfrom stable_baselines.common.vec_env import DummyVecEnv\n\n\nenv = gym.make('Pendulum-ID-v1')\nenv._max_episode_steps = 200\nenv.unwrapped.dt = 0.02\nenv.unwrapped.sigma = 1e-4\nen...
[ [ "matplotlib.pyplot.show", "matplotlib.pyplot.subplots", "numpy.empty", "numpy.clip" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
Titorat/snps
[ "406d2b93303901c81639ccb1734119e0896958ac" ]
[ "tests/__init__.py" ]
[ "\"\"\"\nBSD 3-Clause License\n\nCopyright (c) 2019, Andrew Riha\nAll rights reserved.\n\nRedistribution and use in source and binary forms, with or without\nmodification, are permitted provided that the following conditions are met:\n\n1. Redistributions of source code must retain the above copyright notice, this\...
[ [ "pandas.api.types.is_object_dtype", "pandas.isnull", "numpy.arange", "pandas.DataFrame", "pandas.testing.assert_frame_equal", "pandas.api.types.is_unsigned_integer_dtype" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "0.23", "0.21", "2.0", "1.4", "1.3", "1.1", "1.5", "0.24", "0.20", "1.0", "0.25", "1.2" ], "scipy": [], "tensorflow": [] } ]
sddshao/Auto-Lianliankan
[ "5bf7f1bbc6e38223f4213e8742ef098b3dad9769" ]
[ "run.py" ]
[ "'''\npython 版本:3.5\nopencv 下载链接: \nhttps://www.lfd.uci.edu/~gohlke/pythonlibs/#opencv\n选择版本:opencv_python‑3.4.1‑cp35‑cp35m‑win_amd64.whl\npywin32 下载链接:\nhttps://www.lfd.uci.edu/~gohlke/pythonlibs/#pywin32\n选择版本:pywin32-223-cp35-cp35m-win_amd64.whl \n'''\n\nimport metching\nimport cv2\nimport numpy as np\nimport wi...
[ [ "numpy.subtract", "numpy.any" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
wullli/flatlander
[ "2c7fbd3d025f2a05c40895ec735a92d7a6bfb1ad", "2c7fbd3d025f2a05c40895ec735a92d7a6bfb1ad" ]
[ "flatlander/test/observations/fixed_tree_test.py", "flatlander/envs/utils/global_gym_env.py" ]
[ "import unittest\n\nimport numpy as np\nimport numpy.testing as npt\n\nfrom flatlander.envs.observations.fixed_tree_obs import FixedTreeObservation\nfrom flatlander.test.observations.dummy_tree_builder import DummyBuilder, DummyBuilderForward, \\\n DummyBuilderForwardAlternative, DummyBuilderBackward\n\n\nclass ...
[ [ "numpy.all" ], [ "numpy.zeros" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
prenigma/Optimus
[ "7f450eda8ecf00db38478b69ee11abb453a7b3ad" ]
[ "optimus/helpers/functions.py" ]
[ "import collections\nimport functools\nimport glob\nimport ntpath\nimport os\nimport random\nimport re\nimport subprocess\nimport sys\nimport tempfile\nfrom collections import Counter\nfrom pathlib import Path\nfrom urllib.request import Request, urlopen\n\nimport fastnumbers\nimport humanize\nimport numpy as np\ni...
[ [ "numpy.iinfo" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
alec-tschantz/action-oriented
[ "910b436ee2e90a9d3caeb70cb7f44b35011b6c65" ]
[ "src/core/trials.py" ]
[ "import numpy as np\nfrom core.env import Environment\nfrom core.config import *\n\n\ndef learn_trial(mdp, n_steps, record_states=False):\n env = Environment()\n obv = env.observe()\n mdp.reset(obv)\n states = np.zeros([N_CONTROL, N_STATES, N_STATES])\n\n for step in range(n_steps):\n prev_obv...
[ [ "numpy.square", "numpy.zeros", "numpy.random.choice" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
kaikun213/fonduer
[ "79434aaed22c730ea043fe0909e88e0e39a4b8e5" ]
[ "src/fonduer/utils/utils_udf.py" ]
[ "import logging\nfrom typing import (\n Any,\n Callable,\n Dict,\n Iterable,\n Iterator,\n List,\n Optional,\n Sequence,\n Set,\n Tuple,\n Type,\n Union,\n)\n\nimport numpy as np\nfrom scipy.sparse import csr_matrix\nfrom sqlalchemy import String, Table\nfrom sqlalchemy.dialects....
[ [ "scipy.sparse.csr_matrix" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [ "1.7", "1.0", "0.10", "1.2", "0.14", "0.19", "1.5", "0.12", "0.17", "0.13", "1.6", "1.4", "1.9", "1.3", "1.10", "0.15", "0.18", "0.16"...
afcarl/trees_ensemble
[ "7994798337c7aa54a80a4cfe9d2c05afe3a2f430" ]
[ "ensemble.py" ]
[ "# -*- coding: utf-8 -*-\n\"\"\"\nCreated on Mon Apr 4 13:01:02 2016\n\n@author: rob\n\"\"\"\nimport numpy as np\nfrom sklearn.metrics import confusion_matrix\nacc_weights = np.array([0.964, 0, 0.958, 0, 0.964, 0])\ntest_weights = np.array([0.964, 0.958, 0.964])\n\n#Load the assemble dataset\ndata_ass = np.genfrom...
[ [ "numpy.expand_dims", "numpy.arange", "numpy.squeeze", "sklearn.metrics.confusion_matrix", "numpy.genfromtxt", "numpy.argmax", "numpy.mean", "numpy.where", "numpy.savetxt", "numpy.array", "numpy.zeros", "numpy.sum" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
lacava/PS-Tree
[ "c9e2d93944429e4902709226651fceec84913dd1" ]
[ "pstree/cluster_gp_sklearn.py" ]
[ "import builtins\nimport operator\nimport sys\nimport time\nimport traceback\nimport warnings\nfrom collections import deque, defaultdict\nfrom itertools import compress\n\nimport numpy\nimport pyximport\nfrom deap.gp import Terminal\nfrom deap.tools import selNSGA2, selRandom, selSPEA2, selLexicase, selNSGA3\nfrom...
[ [ "sklearn.linear_model.RidgeCV", "sklearn.tree.DecisionTreeRegressor", "sklearn.linear_model.LogisticRegression", "sklearn.cluster.KMeans", "sklearn.naive_bayes.GaussianNB", "sklearn.ensemble.RandomForestClassifier", "sklearn.mixture.BayesianGaussianMixture", "scipy.stats.pearsonr",...
[ { "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" ...
ariel415el/CTSegmentation-Pytorch
[ "9584c20fd009b93211d6d89afa0df7aaecd31468" ]
[ "inference.py" ]
[ "import argparse\nimport json\nimport os\n\nimport numpy as np\nimport torch\nimport SimpleITK as sitk\nfrom torchvision.transforms import InterpolationMode\nfrom scipy import ndimage\nimport torch.nn.functional as F\nimport cc3d\nfrom scipy.ndimage.morphology import binary_opening, binary_dilation, binary_erosion\...
[ [ "scipy.ndimage.morphology.binary_dilation", "numpy.ones_like", "torch.load", "torch.zeros", "numpy.clip", "scipy.ndimage.zoom", "torch.from_numpy", "scipy.ndimage.morphology.binary_erosion", "torch.no_grad", "numpy.mean", "torch.logical_and", "numpy.where", "tor...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [ "0.13", "1.6", "0.14", "0.15", "1.4", "0.10", "1.3", "0.19", "1.5", "0.18", "1.2", "1.7", "0.12", "1.0", "0.17", "0.16" ], "tensorflow": [...
hyoo/candle_lib
[ "33fe91879a09035fab1b94361c0d65d4595e8d0d" ]
[ "candle/pytorch_utils.py" ]
[ "from __future__ import absolute_import\n\nfrom typing import Dict\n\nimport torch\nimport torch.nn\nimport torch.nn.functional as F\nimport torch.nn.init\nimport torch.optim\n\nfrom .helper_utils import set_seed as set_seed_defaultUtils\n\n\ndef set_pytorch_threads(): # for compatibility\n pass\n\n\ndef set_py...
[ [ "torch.optim.GradientDescentMomentum", "torch.optim.Adadelta", "torch.nn.init.xavier_normal", "torch.nn.CrossEntropyLoss", "torch.nn.Sigmoid", "torch.nn.SmoothL1Loss", "torch.optim.Adam", "torch.nn.init.uniform", "torch.nn.init.constant_", "torch.nn.BCELoss", "torch.nn....
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
stevesolun/nlp-architect-1
[ "d2c1ea15ce20517af52d32ac87e5ccd009b4a620", "d2c1ea15ce20517af52d32ac87e5ccd009b4a620" ]
[ "nlp_architect/models/transformers/sequence_classification.py", "examples/sparse_gnmt/gnmt/model.py" ]
[ "# ******************************************************************************\n# Copyright 2017-2019 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# ...
[ [ "torch.utils.data.TensorDataset", "torch.utils.data.SequentialSampler", "torch.utils.data.DataLoader", "numpy.squeeze", "torch.tensor", "numpy.argmax" ], [ "tensorflow.cond", "tensorflow.nn.dynamic_rnn", "tensorflow.concat", "tensorflow.zeros", "tensorflow.reduce_su...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10" ] } ]
coolo/Character-level-cnn-pytorch
[ "954fe0e53a1c403b0ec1a886e3d6ef66e36df981" ]
[ "classify-server.py" ]
[ "# -*- coding: utf-8 -*-\n\"\"\"\n@author: Viet Nguyen <nhviet1009@gmail.com>\n\"\"\"\nimport os\nimport sys\nimport json\nimport glob\nimport argparse\nimport socket\nimport torch\nimport torch.nn as nn\nimport torch.nn.functional as F\nfrom torch.utils.data import DataLoader\nimport shutil\nimport http.server\nim...
[ [ "torch.nn.functional.softmax", "torch.load", "torch.utils.data.DataLoader", "torch.no_grad", "torch.cuda.is_available", "torch.argmax" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
sagarsetru/msd_analysis_floA_floT
[ "9e880d4a107fef44063faec7de32ea38175782ef" ]
[ "dataParserScript_v2.py" ]
[ "# Sagar Setru\n# 2016 07 14\n\nimport pandas as pd\nimport numpy as np\nimport os\nimport matplotlib.pyplot as plt\nfrom matplotlib.backends.backend_pdf import PdfPages\nimport itertools\n\n\n#def loadDataFile( baseDir, subBaseDir, fileName):\n# \"helper function to load bed files\"\n# return pd.read_csv(bas...
[ [ "pandas.read_csv", "numpy.multiply", "numpy.unique", "matplotlib.pyplot.savefig", "matplotlib.pyplot.ylabel", "matplotlib.pyplot.clf", "numpy.mean", "numpy.savetxt", "matplotlib.pyplot.xlabel", "numpy.array", "matplotlib.pyplot.tick_params", "numpy.sum", "numpy....
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.1", "1.5", "1.2", "1.3" ], "scipy": [], "tensorflow": [] } ]
mohi7solanki/causalml
[ "73e41837a8edb7220de1e2d102157000b2ccd476" ]
[ "tests/test_meta_learners.py" ]
[ "import numpy as np\nimport pandas as pd\n\nfrom sklearn.linear_model import LinearRegression\nfrom sklearn.linear_model import LogisticRegression\nfrom sklearn.model_selection import train_test_split\nfrom xgboost import XGBRegressor\nfrom xgboost import XGBClassifier\n\nfrom causalml.dataset import synthetic_data...
[ [ "sklearn.linear_model.LogisticRegression", "numpy.random.seed", "sklearn.model_selection.train_test_split", "pandas.DataFrame", "sklearn.linear_model.LinearRegression", "numpy.where" ] ]
[ { "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": [] } ]
ahmetcik/ML-and-LA-from-scratch
[ "9718ccb68c228be6cdcb0b14b97f9d0acdfc28ca" ]
[ "logistic_regression.py" ]
[ "import numpy as np\n\nclass LogisticRegression(object):\n \n def __init__(self, intercept=True, alpha=0.01, max_steps=2000,):\n self.intercept = intercept\n self.alpha = alpha # learning rate\n self.max_steps = max_steps\n\n def fit(self, X, Y): \n if self.intercept:\n ...
[ [ "numpy.dot", "matplotlib.pyplot.scatter", "numpy.linspace", "numpy.insert", "numpy.exp", "numpy.array", "numpy.zeros", "matplotlib.pyplot.show" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
HumanCompatibleAI/seals
[ "08dc04e1b21e4bd2d83e0447e1d9e40902471961" ]
[ "src/seals/diagnostics/init_shift.py" ]
[ "\"\"\"Environment with shift in initial state distribution.\"\"\"\n\nimport functools\nimport itertools\n\nimport numpy as np\n\nfrom seals import base_envs\n\n\nclass InitShiftEnv(base_envs.TabularModelMDP):\n \"\"\"Tests for robustness to initial state shift.\n\n Many LfH algorithms learn from expert demon...
[ [ "numpy.arange", "numpy.zeros" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
nkalupahana/onshape-to-robot
[ "fd0f8897131611935ad7e7cd90c3ed60b2bb31f2" ]
[ "onshape_to_robot/stl_combine.py" ]
[ "import numpy as np\nimport shutil\nimport math\nimport subprocess\nimport stl\nimport os\nfrom stl import mesh\nfrom colorama import Fore, Back, Style\n\n\ndef load_mesh(stl_file):\n return mesh.Mesh.from_file(stl_file)\n\n\ndef save_mesh(mesh, stl_file):\n mesh.save(stl_file, mode=stl.Mode.BINARY)\n\n\ndef ...
[ [ "numpy.concatenate", "numpy.matrix" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
mshaikh2/sagan
[ "c978d18b0400eddecde303e30900107093029876" ]
[ "PyTorch-cSAWGAN/Discriminators.py" ]
[ "import numpy as np\nimport torch\nimport torch.nn as nn\nimport torch.nn.functional as F\nimport torch.autograd as autograd\nimport torch.optim as optim\nimport torchvision\nimport torchvision.transforms as transforms\nimport Components\n\nclass cSAWGANDiscriminatorV1(nn.Module):\n def __init__(self, in_channel...
[ [ "torch.nn.Linear", "torch.nn.Conv2d", "torch.nn.LeakyReLU", "torch.nn.BatchNorm2d" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
bicycleman15/pytorch-classification
[ "01e480dad9ea1e9bbf0810b35c1103dd76e06510" ]
[ "train.py" ]
[ "import argparse\nimport os\nimport shutil\nimport random\n\nimport torch\nimport torch.nn as nn\nimport torch.optim as optim\n\nfrom utils import Logger, AverageMeter, accuracy, mkdir_p, parse_args\nfrom utils import get_lr, save_checkpoint\nfrom tqdm import tqdm\n\nfrom solver.runners import train, test\nfrom sol...
[ [ "torch.optim.lr_scheduler.MultiStepLR", "torch.manual_seed", "torch.load" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
keerthanss/Synthesia-to-Sheet
[ "2a74db9673cfd9fbdce53eaf1ac65f60820c59ab" ]
[ "synthesia_to_sheet/Song.py" ]
[ "import cv2\nimport numpy as np\n\nfrom sklearn.cluster import KMeans\n\nfrom ClassDefinitions.Hand import Hand\n\nclass Song:\n \"\"\"docstring for Song\"\"\"\n\n def __init__(self, piano):\n self.piano = piano\n self.key_presses = [] # list of key presses for each frame\n self.length_of...
[ [ "numpy.square", "numpy.argmax", "numpy.argmin", "sklearn.cluster.KMeans" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
windysavage/dfdc_deepfake_challenge
[ "d10b54cf933282366157a031954b046d87d57009" ]
[ "training/zoo/classifiers.py" ]
[ "from functools import partial\n\nimport numpy as np\nimport torch\nfrom timm.models.efficientnet import tf_efficientnet_b4_ns, tf_efficientnet_b3_ns, \\\n tf_efficientnet_b5_ns, tf_efficientnet_b2_ns, tf_efficientnet_b6_ns, tf_efficientnet_b7_ns\nfrom torch import nn\nfrom torch.nn.modules.dropout import Dropou...
[ [ "torch.nn.Parameter", "torch.nn.modules.linear.Linear", "torch.load", "torch.nn.Conv2d", "torch.nn.modules.pooling.AdaptiveAvgPool2d", "torch.no_grad", "torch.nn.modules.dropout.Dropout", "numpy.array" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
jens-k/sleap
[ "4e99ed037f1f7f41d9f15e2efaac638fc7e12b09" ]
[ "sleap/nn/training.py" ]
[ "\"\"\"Training functionality and high level APIs.\"\"\"\n\nimport os\nimport re\nfrom datetime import datetime\nfrom time import time\nimport logging\n\nimport tensorflow as tf\nimport numpy as np\n\nimport attr\nfrom typing import Optional, Callable, List, Union, Text, TypeVar\nfrom abc import ABC, abstractmethod...
[ [ "tensorflow.keras.losses.MeanSquaredError", "matplotlib.use", "tensorflow.keras.callbacks.ReduceLROnPlateau", "tensorflow.keras.optimizers.Adam", "tensorflow.keras.callbacks.TensorBoard", "tensorflow.keras.callbacks.EarlyStopping" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "2.7", "2.2", "2.3", "2.4", "2.5", "2.6" ] } ]
yogendras843/Edureka-Mastering-Python-Assignments
[ "b47e926d753732a8fd697baa60df2d7c2a6c9f02" ]
[ "Module 6/Module_6_Problem_2.py" ]
[ "\"\"\"\n@author: Maneesh D\n@date: 29-May-17\n@intepreter: Python 3.6\n\nCreate random vector of size 50 and replace the maximum value by 0 and minimum value by 100.\n\"\"\"\nimport numpy as np\n\n\nrand_vector = np.random.randint(low=1, high=100, size=50)\nprint(rand_vector)\n\nprint(\"-\" * 12 + \"Replacing the ...
[ [ "numpy.random.randint" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
Qiskit/monodromy
[ "97829c1289c8a79b6ae3ab29eb7f4ad1ea79d5ab" ]
[ "monodromy/coordinates.py" ]
[ "\"\"\"\nmonodromy/coordinates.py\n\nThis file contains routines for converting from one system to another. There are\nseveral common coordinate systems / choices of Weyl alcove in pu_4:\n\n+ (Balanced) canonical parameters: These are the (a, b, c) in the exponential\n\n exp(-i(a XX + b YY + c ZZ))\n\n with a...
[ [ "numpy.linalg.det", "numpy.array", "numpy.linalg.eigvals", "numpy.mod" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
bitbacchus/agent_based_COVID_SEIRX
[ "9957b443c06f86f33794c8404d8e6a2a4d964fa6" ]
[ "src/scseirx/model_SEIRX.py" ]
[ "import numpy as np\nimport networkx as nx\nfrom math import gamma\nfrom scipy.optimize import root_scalar\n\nfrom mesa import Model\nfrom mesa.time import RandomActivation, SimultaneousActivation\nfrom mesa.datacollection import DataCollector\n\nfrom scseirx.testing_strategy import Testing\n\n## data collection fu...
[ [ "numpy.random.weibull", "numpy.abs", "numpy.random.seed", "numpy.random.choice", "numpy.asarray", "scipy.optimize.root_scalar" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [ "1.6", "1.10", "1.4", "1.9", "1.5", "1.2", "1.7", "1.3", "1.8" ], "tensorflow": [] } ]
Tarpelite/nConvSA
[ "15f71895cebf4f980e888d7405db0a07d80bcdf9" ]
[ "examples/run_nConv_adv.py" ]
[ "# coding=utf-8\n# Copyright 2018 The Google AI Language Team Authors and The HuggingFace Inc. team.\n# Copyright (c) 2018, NVIDIA CORPORATION. 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...
[ [ "torch.load", "numpy.squeeze", "torch.utils.data.DataLoader", "torch.sum", "torch.no_grad", "torch.cuda.manual_seed_all", "torch.cuda.is_available", "torch.device", "torch.distributed.get_rank", "sklearn.metrics.f1_score", "torch.save", "torch.clamp", "torch.dis...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
530824679/2D_ObjectDetect
[ "cdae94bfbcb3d6ef9123e05dca3bf4f4b8501d62" ]
[ "evaluate.py" ]
[ "import numpy as np\nimport tensorflow as tf\nfrom collections import Counter\nfrom utils.process_utils import calculate_iou, non_maximum_suppression\n\ndef evaluate(y_pred, y_true, num_classes, score_thresh=0.5, iou_thresh=0.5):\n\n num_images = y_true[0].shape[0]\n true_labels_dict = {i:0 for i in range(n...
[ [ "numpy.array", "numpy.argmax" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
zeffon/logparser
[ "4ef7bf0c63652a44dc6dd583b1e15526d5036b32" ]
[ "logparser/Drain/Drain.py" ]
[ "\"\"\"\r\nDescription : This file implements the Drain algorithm for log parsing\r\nAuthor : LogPAI team\r\nLicense : MIT\r\n\"\"\"\r\n\r\nimport re\r\nimport os\r\nfrom sys import version_info\r\nimport numpy as np\r\nimport pandas as pd\r\nimport hashlib\r\nfrom datetime import datetime\r\n\r\n\r\nclass...
[ [ "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": [] } ]
rloganiv/meercat-aux
[ "4d9006095e9fb91034f8dae0baaa81a1567f6606" ]
[ "meercat/cluster_w_grinch.py" ]
[ "\"\"\"\nCluster embeddings using GRINCH.\n\"\"\"\nimport argparse\nimport csv\nimport logging\n\nimport numpy as np\n\nfrom meercat.grinch_alg import Grinch\n\n\nlogger = logging.getLogger(__name__)\n\n\ndef find_threshold(grinch, target, max_iters=100):\n logger.info(f'Finding threshold. Target # of clusts: {t...
[ [ "numpy.array", "numpy.unique" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
georgeRenard/CrackingTheCodingInterview
[ "ba9866e8e7a8c9942464d76b13af08ea6b15f3f9" ]
[ "linked-lists/removeDups.py" ]
[ "import sys\nimport numpy\n\n\ndef problem():\n \"\"\"\n Remove Dups! Write code to remove duplicates from an unsorted linked list.\n FOLLOW UP\n How would you solve this problem if a temporary buffer is not allowed? \n \"\"\"\n pass\n\n\nclass Node():\n \n\n # If it is so importa...
[ [ "numpy.random.randint" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
AlgTUDelft/WCSAC
[ "6536929bb3a167090752305373bf16e726994305" ]
[ "wc_sac/sac/saclag.py" ]
[ "#Portions of the code are adapted from Safety Starter Agents and Spinning Up, released by OpenAI under the MIT license.\n#!/usr/bin/env python\n\nfrom functools import partial\nimport numpy as np\nimport tensorflow as tf\nimport gym\nimport time\nfrom wc_sac.utils.logx import EpochLogger\nfrom wc_sac.utils.mpi_tf ...
[ [ "tensorflow.get_variable", "tensorflow.concat", "tensorflow.control_dependencies", "tensorflow.reduce_sum", "tensorflow.minimum", "tensorflow.global_variables", "tensorflow.tanh", "tensorflow.group", "numpy.random.randint", "tensorflow.layers.dense", "tensorflow.stop_gr...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10" ] } ]
yamathcy/motif
[ "3f43568e59f0879fbab5ef278e9e687b7cac3dd6" ]
[ "tests/feature_extractors/test_cesium.py" ]
[ "\"\"\"Test motif.features.cesium\n\"\"\"\nimport unittest\nimport numpy as np\n\nfrom motif.feature_extractors import cesium\n\n\ndef array_equal(array1, array2):\n return np.all(np.isclose(array1, array2, atol=1e-7))\n\n\nclass TestCesiumFeatures(unittest.TestCase):\n\n def setUp(self):\n self.ftr = ...
[ [ "numpy.ones", "numpy.linspace", "numpy.isclose" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
mittagessen/cutout
[ "c5bb68b4d71fe3625c89c6e005dad333143d052d" ]
[ "cutout/model.py" ]
[ "import torch\n\nfrom torchvision import models\nimport torch.nn.functional as F\nfrom torch import autograd\n\nfrom torch import nn\n\n\ndef _wi(m):\n if isinstance(m, torch.nn.Linear):\n torch.nn.init.xavier_uniform_(m.weight.data)\n torch.nn.init.constant_(m.bias.data, 0)\n elif isinstance(m,...
[ [ "torch.nn.AdaptiveMaxPool2d", "torch.nn.init.constant_", "torch.nn.init.kaiming_uniform_", "torch.nn.Linear", "torch.nn.init.orthogonal_", "torch.nn.init.xavier_uniform_" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
siddharthjoshi01/Banknote-Authentication-Project
[ "842974648742318c3d0831020ce30efc23d54015" ]
[ "scripts/proj1_B.py" ]
[ "############################################################################################\n# The following program deals with the problem 2 of project 1. The program implements the #\n# machine learning algorithms: perceptron, logistic regression, support vector machines, #\n# decision trees, random forests ...
[ [ "numpy.hstack", "pandas.read_csv", "sklearn.linear_model.LogisticRegression", "sklearn.ensemble.RandomForestClassifier", "sklearn.metrics.accuracy_score", "sklearn.model_selection.train_test_split", "pandas.DataFrame", "sklearn.neighbors.KNeighborsClassifier", "sklearn.tree.Dec...
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.3", "1.1", "1.5", "1.2" ], "scipy": [], "tensorflow": [] } ]
yangyuethz/pyEPR
[ "39d914587938cd7aa7fc546444c5bd4572a922dc" ]
[ "pyEPR/project_info.py" ]
[ "\"\"\"\nMain interface module to use pyEPR.\n\nContains code to conenct to Ansys and to analyze HFSS files using the EPR method.\n\nThis module handles the micowave part of the analysis and conenction to\n\nFurther contains code to be able to do autogenerated reports,\n\nCopyright Zlatko Minev, Zaki Leghtas, and t...
[ [ "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": [] } ]
isaacatwork/aws-py-lambda-container
[ "f9e500674c13aa658cd263725b4c515a9bd0a5c7" ]
[ "anniversary/data_generator.py" ]
[ "import argparse\nimport datetime\nimport itertools\nimport logging\nimport os\nimport random\n\nimport boto3\nimport pandas as pd\nfrom botocore.exceptions import ClientError\nfrom faker import Faker\n\n\ndef date_generator():\n \"\"\"\n Simple random date generator\n\n Returns datetime.date - a valid ran...
[ [ "pandas.to_datetime", "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": [] } ]
jleinonen/downscaling-rnn-gan
[ "3c5e819ab994352519a71df6eb69def1e95163f2" ]
[ "dsrnngan/data.py" ]
[ "import numpy as np\nfrom scipy.ndimage import convolve\n\n\nclass Smoothener(object):\n def __init__(self):\n (x,y) = np.mgrid[-2:3,-2:3]\n self.smoothing_kernel = np.exp(-0.5*(x**2+y**2)/(0.65**2))\n self.smoothing_kernel /= self.smoothing_kernel.sum()\n self.edge_shapes = {}\n\n ...
[ [ "numpy.rot90", "numpy.log", "numpy.isfinite", "numpy.empty_like", "numpy.arange", "scipy.ndimage.convolve", "numpy.full", "numpy.concatenate", "numpy.ones", "numpy.log10", "numpy.flip", "numpy.exp", "numpy.load", "numpy.array", "numpy.zeros", "numpy....
[ { "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"...
aGIToz/semi-supervised-segmentation-on-graphs
[ "cffdd6c75850c6cdc8e7752d60fbd372f6e61f34" ]
[ "graph/graph.py" ]
[ "\"\"\"\nA simple knn graph creation with exponential weights.\n\ntodo:\npython decorator for elapsed time?\nDo if for patches.\nGraph Symmetrization.\n\"\"\"\n\nfrom time import time\nimport numpy\nfrom bufferkdtree.neighbors import NearestNeighbors\nfrom utilities import roll, unroll\nimport pyopencl as cl\nimpor...
[ [ "numpy.reshape", "numpy.int32", "numpy.ndarray", "numpy.float32" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
kevinko1788/CarND-Behavioral-Cloning-P3
[ "f8b17260d98a1aae66c340efcbebf9db1b752039" ]
[ "model.py" ]
[ "import csv\nimport cv2\nimport numpy as np\nimport tensorflow\nimport pdb\n\nfrom keras.models import Sequential\nfrom keras.layers import Flatten, Dense, Lambda, Conv2D, Cropping2D, Activation\nfrom keras.layers import Dropout, ELU, MaxPooling2D\nfrom keras.optimizers import Adam\nfrom keras.callbacks import Mode...
[ [ "sklearn.utils.shuffle", "numpy.array", "sklearn.model_selection.train_test_split" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
kingsaint/ExplainableEntityLinking
[ "2f26602a0187d8785214e639ccb8dc87f4ca2302" ]
[ "src/rl/graph_search/pg.py" ]
[ "\"\"\"\n Copyright (c) 2018, salesforce.com, inc.\n All rights reserved.\n SPDX-License-Identifier: BSD-3-Clause\n For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause\n \n Policy gradient (REINFORCE algorithm) training and inference.\n\"\"\"\n\nimport torch\...
[ [ "torch.exp", "torch.no_grad", "torch.multinomial", "torch.cat" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
mnthnx64/All-about-faces
[ "860eb760286fcb5d04fd797e16842509467f462f" ]
[ "gender-emotion/video_emotion_color_demo.py" ]
[ "from statistics import mode\n\nimport cv2\nfrom keras.models import load_model\nimport numpy as np\n\nfrom utils.datasets import get_labels\nfrom utils.inference import detect_faces\nfrom utils.inference import draw_text\nfrom utils.inference import draw_bounding_box\nfrom utils.inference import apply_offsets\nfro...
[ [ "numpy.asarray", "numpy.max", "numpy.expand_dims", "numpy.argmax" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
YOULLNEVERWA/PyTorchVideoCompression
[ "48b57298c86557d151627dc3ef8a2db8ab613654" ]
[ "DVC/subnet/flowlib.py" ]
[ "\"\"\"\n# ==============================\n# flowlib.py\n# library for optical flow processing\n# Author: Ruoteng Li\n# Date: 6th Aug 2016\n# ==============================\n\"\"\"\nimport png\nimport numpy as np\nimport matplotlib.colors as cl\nimport matplotlib.pyplot as plt\nfrom PIL import Image\n\n\nUNKNOWN_FL...
[ [ "matplotlib.pyplot.imshow", "numpy.resize", "numpy.sqrt", "matplotlib.colors.hsv_to_rgb", "numpy.arctan2", "numpy.max", "numpy.mean", "scipy.interpolate.griddata", "numpy.reshape", "numpy.uint8", "numpy.arange", "numpy.finfo", "numpy.size", "numpy.repeat", ...
[ { "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"...
wesleyktatum/bms_kaggle
[ "679c23b53ecbcf12ebd84a84a8619adc5f6a4ab2" ]
[ "eval_distributed.py" ]
[ "import os\nimport json\nimport argparse\nimport numpy as np\nimport pandas as pd\nfrom time import perf_counter\n\nfrom util import *\nfrom dataloader import MoleculeDataset\nfrom models.sasa import ResNet26, ResNet38, ResNet50\nfrom models.axial import axial18s, axial18srpe, axial26s, axial50s, axial50m, axial50l...
[ [ "torch.distributed.init_process_group", "torch.utils.data.distributed.DistributedSampler", "torch.cuda.set_device", "torch.multiprocessing.spawn", "torch.utils.data.DataLoader", "torch.cuda.is_available", "torch.cuda.device_count", "torch.nn.parallel.DistributedDataParallel" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
chenxyzj/car-color-classifier-yolo3-python
[ "013649f2e6219a28fd945a46e74d939d58c1ee17" ]
[ "classifier.py" ]
[ "# Copyright © 2019 by Spectrico\r\n# Licensed under the MIT License\r\n\r\nimport numpy as np\r\nimport json\r\nimport tensorflow as tf\r\nfrom PIL import Image, ImageOps\r\nimport cv2\r\nimport io\r\nimport config\r\n\r\nmodel_file = config.model_file\r\nlabel_file = config.label_file\r\ninput_layer = config.inpu...
[ [ "tensorflow.Graph", "tensorflow.import_graph_def", "numpy.expand_dims", "numpy.squeeze", "tensorflow.Session", "tensorflow.GraphDef" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
damiafuentes/TelloSDKPy
[ "156b61e374150cf97a396973208b765f6dcec0c0" ]
[ "djitellopy/tello.py" ]
[ "\"\"\"Library for interacting with DJI Ryze Tello drones.\n\"\"\"\n\n# coding=utf-8\nimport logging\nimport socket\nimport time\nfrom threading import Thread\nfrom typing import Optional, Union, Type, Dict\n\nfrom .enforce_types import enforce_types\n\nimport av\nimport numpy as np\n\n\nthreads_initialized = False...
[ [ "numpy.zeros" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
GiuppoUni/warInspector
[ "c0b06ba355d481e2260f9476b38524270948808a" ]
[ "application.py" ]
[ "\"\"\"\r\n==================================================\r\n\r\n WarInspector web app\r\n \r\n==================================================\r\n\r\n\r\n\"\"\"\r\n\r\nprint(__doc__)\r\nimport numpy as np\r\nimport pandas as pd\r\nfrom numpy import dot\r\nfrom numpy.linalg import norm\r...
[ [ "pandas.merge", "pandas.read_csv", "pandas.concat", "pandas.DataFrame", "matplotlib.pyplot.grid", "sklearn.preprocessing.StandardScaler", "sklearn.decomposition.PCA", "matplotlib.pyplot.figure" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.3", "1.1", "1.5", "1.2" ], "scipy": [], "tensorflow": [] } ]
Wong-Lab/deepcell-label
[ "b07f93bed342b470d0662c898e4c2fc8ccb5e9c2" ]
[ "deepcell_label/conftest.py" ]
[ "\"\"\"Tests for the DeepCell Label Flask App.\"\"\"\n\nimport os\n\nfrom flask_sqlalchemy import SQLAlchemy\nimport numpy as np\nimport pytest\nfrom pytest_lazyfixture import lazy_fixture\nfrom unittest.mock import MagicMock\n\nfrom deepcell_label import create_app # pylint: disable=C0413\nfrom deepcell_label.loa...
[ [ "numpy.zeros" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
ericchen12377/Leetcode-Algorithm-Python
[ "eb58cd4f01d9b8006b7d1a725fc48910aad7f192" ]
[ "1stRound/Medium/973-K Closest Points to Origin/Argsort.py" ]
[ "import numpy as np\n\n\nclass Solution:\n def kClosest(self, points: List[List[int]], K: int) -> List[List[int]]:\n res = []\n for p in points:\n d = np.sqrt(p[0]**2 + p[1]**2)\n res.append(d)\n idx = np.argsort(res)[:K]\n print(idx)\n return [points[i] f...
[ [ "numpy.argsort", "numpy.sqrt" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
temuller/PISCoLA
[ "e380603155991c267c26c4c93dfd650b9777b6b9" ]
[ "src/piscola/filter_utils.py" ]
[ "import os\nimport numpy as np\nimport piscola\n\ndef integrate_filter(spectrum_wave, spectrum_flux, filter_wave, filter_response, response_type='photon'):\n \"\"\"Calcultes the flux density of an SED given a filter response.\n\n Parameters\n ----------\n spectrum_wave : array\n Spectrum's wavele...
[ [ "numpy.sqrt", "numpy.arange", "numpy.log10", "numpy.interp", "numpy.trapz", "numpy.loadtxt" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
bycxw/ETC4Rec
[ "8f3074949a0f3731eac32e0cec36a5d29d97201f" ]
[ "etclayers/transformer.py" ]
[ "# coding=utf-8\n# Copyright 2021 The Google Research 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.keras.layers.LayerNormalization", "tensorflow.compat.v1.TensorShape", "tensorflow.compat.v1.keras.initializers.TruncatedNormal" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
SwiftieH/SpGAT
[ "b9fdd1a326e28d4d4dcd922cdebaedd764783cf6" ]
[ "inits.py" ]
[ "import tensorflow as tf\nimport numpy as np\n\n\ndef uniform(shape, scale=1.0, name=None):\n \"\"\"Uniform init.\"\"\"\n initial = tf.random_uniform(shape, minval=0.0, maxval=scale, dtype=tf.float32)\n return tf.Variable(initial, name=name)\n\n\ndef glorot(shape, name=None):\n \"\"\"Glorot & Bengio (AI...
[ [ "numpy.sqrt", "tensorflow.Variable", "tensorflow.zeros", "tensorflow.ones", "tensorflow.random_uniform" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10", "1.4", "1.5", "1.7", "0.12", "1.0", "1.2" ] } ]
DuncDennis/rescomp
[ "796d8db1aa0b21c909097f6642d3408e04bf8271" ]
[ "test/test_measures.py" ]
[ "# -*- coding: utf-8 -*-\n\"\"\" Tests if the rescomp.measures module works as it should \"\"\"\n\nimport unittest\nimport numpy as np\nfrom rescomp import measures\nimport pytest\n\n\nclass testMeasures(unittest.TestCase):\n def setUp(self):\n np.random.seed(0)\n\n def tearDown(self):\n np.rand...
[ [ "numpy.testing.assert_equal", "numpy.random.random", "numpy.random.seed", "numpy.linspace", "numpy.linalg.norm", "numpy.testing.assert_almost_equal", "numpy.std", "numpy.mean", "numpy.testing.assert_allclose", "numpy.zeros", "numpy.random.randint" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
HirotakaNakagame/feature-enginerring
[ "f5800337fd37dc487fc78f39e0d475e8f8178360" ]
[ "WeightofEvidenceEncoder/WeightofEvidenceEncoder.py" ]
[ "# Authors: Hirotaka Nakagame <hirotaka.nakagame@gmail.com>\r\n\r\nimport pandas as pd\r\nimport numpy as np\r\n\r\n\r\nclass WeightofEvidenceEncoder:\r\n \"\"\"\r\n Calculate weight of evidence for categorical features\r\n\r\n Parameters\r\n ----------\r\n feats: list type\r\n list of...
[ [ "numpy.log", "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": [] } ]
tbmihailov/OBQA
[ "653c5c64ae7eb164bde0b381813afe5f664dcf67" ]
[ "ir/run_sts.py" ]
[ "# coding=utf-8\n# Copyright 2018 The Google AI Language Team Authors and The HugginFace Inc. team.\n# Copyright (c) 2018, NVIDIA CORPORATION. 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 ...
[ [ "torch.nn.MSELoss", "torch.distributed.init_process_group", "numpy.random.seed", "torch.cuda.set_device", "torch.utils.data.distributed.DistributedSampler", "torch.manual_seed", "torch.utils.data.TensorDataset", "torch.utils.data.DataLoader", "torch.utils.data.RandomSampler", ...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
Aewaterhouse/dhitools
[ "da3a2244d44802dc871debcc6ce06bf78dfc85a8" ]
[ "dhitools/dfs.py" ]
[ "\"\"\"DHI MIKE21 dfs0/1/2 functions\n\"\"\"\n\nimport numpy as np\nimport datetime as dt\nimport pandas as pd\nfrom . import _utils\nimport os\n\n# Import .NET libraries\nimport DHI.Generic.MikeZero.DFS as dfs\n\n\nclass _Dfs(object):\n \"\"\"\n Base class for dfs0/1/2\n \"\"\"\n\n def __init__(self, d...
[ [ "numpy.arange", "numpy.zeros", "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": [] } ]
Fangyh09/pysteps
[ "9eb7f4ead0a946d98b7504d1bd66b18dc405ed51" ]
[ "pysteps/tests/test_motion.py" ]
[ "# coding: utf-8\n\n\"\"\"\nTest the convergence of the optical flow methods available in\npySTEPS using idealized motion fields.\n\nTo test the convergence, using an example precipitation field we will:\n\n- Read precipitation field from a file\n- Morph the precipitation field using a given motion field (linear or...
[ [ "numpy.ma.MaskedArray", "numpy.sqrt", "numpy.ma.getmaskarray", "numpy.abs", "scipy.ndimage.uniform_filter", "numpy.ma.concatenate", "numpy.ma.masked_invalid", "numpy.array", "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"...
seungguini/DialoGPT
[ "6b89677496cc674fd5cf951c179e94d330292437" ]
[ "LSP_train.py" ]
[ "# Copyright (c) Microsoft Corporation. \n# Licensed under the MIT license. \n'''\n * @Desc: train GPT2 from scratch/ fine tuning.\n Modified based on Huggingface GPT-2 implementation\n'''\n\nimport json\nimport os\nimport sys\nimport argparse\nimport logging\nimport time\nimport tqdm\nimport datetime\ni...
[ [ "torch.distributed.init_process_group", "torch.cuda.manual_seed", "torch.cuda.set_device", "numpy.random.seed", "torch.random.manual_seed", "torch.cuda.empty_cache", "torch.cuda.manual_seed_all", "torch.cuda.is_available", "torch.device", "torch.distributed.get_rank", "...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
BNIA/VitalSigns
[ "1c06284a7423fb837890b5d4b42567e8f14bf278" ]
[ "VitalSigns/closecrawl.py" ]
[ "# AUTOGENERATED! DO NOT EDIT! File to edit: notebooks/01_Close Crawl.ipynb (unless otherwise specified).\n\n\nfrom __future__ import absolute_import, print_function, unicode_literals\n\n\n\nfrom __future__ import absolute_import, print_function, unicode_literals\n\n\n\nfrom __future__ import absolute_import, print...
[ [ "pandas.to_datetime", "pandas.read_csv", "pandas.DataFrame" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.1", "1.5", "1.2", "1.3" ], "scipy": [], "tensorflow": [] } ]
sujavarghese/data-validator
[ "e0c5d94da797cb43b17d6ee193d337cbcb602f49" ]
[ "tests/test_helper.py" ]
[ "import re\nimport numpy\nimport pandas\nfrom tests import TestCase\nfrom file_validator.helper.utils import (\n FLOAT_RE, FIRST_CAP_RE, ALL_CAP_RE, clean_value, is_empty, to_snake, to_int, to_str, to_float, dollar_str_to_float,\n)\n\n\nclass TestUtils(TestCase):\n def test_should_match_float_re(self):\n ...
[ [ "pandas.Series" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "0.23", "0.21", "2.0", "1.4", "0.19", "1.1", "1.5", "1.2", "0.24", "0.20", "1.0", "0.25", "1.3" ], "scipy": [], "tensorflow": [] } ]
pnuehrenberg/Mask_RCNN
[ "b98dd80842c95487ad842c216b8868cac5c9a073" ]
[ "mrcnn/model.py" ]
[ "\"\"\"\nMask R-CNN\nThe main Mask R-CNN model implementation.\n\nCopyright (c) 2017 Matterport, Inc.\nLicensed under the MIT License (see LICENSE for details)\nWritten by Waleed Abdulla\n\"\"\"\n\nimport os\nimport random\nimport datetime\nimport re\nimport math\nimport logging\nfrom collections import OrderedDict...
[ [ "numpy.amax", "numpy.expand_dims", "tensorflow.concat", "tensorflow.control_dependencies", "tensorflow.stack", "tensorflow.reduce_sum", "tensorflow.minimum", "tensorflow.cast", "tensorflow.image.non_max_suppression", "tensorflow.equal", "tensorflow.image.crop_and_resize...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10" ] } ]
bparazin/skyportal
[ "c160610ca0cc28eef9f36c2d11cc15bd9bcbfe56" ]
[ "skyportal/models/localization.py" ]
[ "__all__ = ['Localization']\n\nimport sqlalchemy as sa\nfrom sqlalchemy.orm import relationship, deferred\nfrom sqlalchemy.dialects.postgresql import JSONB\nfrom sqlalchemy.ext.hybrid import hybrid_property\n\nfrom astropy.table import Table\nimport numpy as np\nimport ligo.skymap.bayestar as ligo_bayestar\nimport ...
[ [ "numpy.asarray" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
brown170/fudge
[ "4f818b0e0b0de52bc127dd77285b20ce3568c97a", "4f818b0e0b0de52bc127dd77285b20ce3568c97a" ]
[ "brownies/legacy/toENDF6/covariances/modelParameters.py", "examples/compareCrossSections.py" ]
[ "# <<BEGIN-copyright>>\n# Copyright 2021, Lawrence Livermore National Security, LLC.\n# See the top-level COPYRIGHT file for details.\n# \n# SPDX-License-Identifier: BSD-3-Clause\n# <<END-copyright>>\n\nimport numpy\n\nfrom fudge.resonances import scatteringRadius as scatteringRadiusModule, resolved as resolvedModu...
[ [ "numpy.sqrt", "numpy.rint", "numpy.all", "numpy.identity", "numpy.outer", "numpy.array", "numpy.sum" ], [ "matplotlib.pyplot.savefig", "matplotlib.pyplot.suptitle", "matplotlib.pyplot.show", "matplotlib.pyplot.subplot2grid", "matplotlib.pyplot.figure" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
danieldiezmallo/euBERTus
[ "056c36166362074cb08734ca9fb4c6e6b42f3aaf" ]
[ "01 Crawling/crawler/crawler/spiders/eu_data_spider.py" ]
[ "import scrapy\nfrom datetime import datetime\nimport pandas as pd\nimport os\nfrom shutil import rmtree\n\nclass EuDataSpiderSpider(scrapy.Spider):\n name = \"eu_data_spider\" \n def start_requests(self):\n '''\n Select the URLs to extract from\n ''' \n # Get the o...
[ [ "pandas.read_csv" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.1", "1.5", "1.2", "1.3" ], "scipy": [], "tensorflow": [] } ]
hirnimeshrampuresoftware/quaternion
[ "dac0c5cd5ea286e3583b71e1a1ee1620e7e7a03d" ]
[ "src/quaternion/calculus.py" ]
[ "# Copyright (c) 2019, Michael Boyle\n# See LICENSE file for details: <https://github.com/moble/quaternion/blob/main/LICENSE>\n\nfrom __future__ import division, print_function, absolute_import\nimport numpy as np\nfrom quaternion.numba_wrapper import njit, jit, xrange\n\n\ndef fd_derivative(f, t):\n \"\"\"Fourt...
[ [ "scipy.interpolate.InterpolatedUnivariateSpline", "numpy.abs", "numpy.asarray", "numpy.empty_like", "numpy.squeeze", "numpy.asanyarray", "numpy.zeros_like", "numpy.iscomplexobj", "numpy.ndindex", "numpy.array", "numpy.moveaxis", "numpy.sum", "numpy.empty" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [ "1.7", "1.0", "0.10", "1.2", "0.14", "0.19", "1.5", "0.12", "0.17", "0.13", "1.6", "1.4", "1.9", "1.3", "1.10", "0.15", "0.18", "0.16"...
TheEagerLearner/Hacktoberfest2020
[ "a244d49c0f7959e05bbcdad39ee49b559b32e4a2" ]
[ "Machine_Learning/Regression/Data_Preprocessing/dataPreprocessing.py" ]
[ "import numpy as np\r\nimport pandas as pd\r\nimport matplotlib.pyplot as plt\r\n\r\n#reading data from the csv file\r\ndataset=pd.read_csv(\"Data.csv\")\r\n\r\n#Seperating dataset into dependent and independent variables\r\nX=dataset.iloc[:,:-1].values\r\nY=dataset.iloc[:,-1].values\r\n\r\n#removing NULL values fr...
[ [ "pandas.read_csv", "sklearn.preprocessing.OneHotEncoder", "sklearn.impute.SimpleImputer", "sklearn.model_selection.train_test_split", "sklearn.preprocessing.StandardScaler", "sklearn.preprocessing.LabelEncoder" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.1", "1.5", "1.2", "1.3" ], "scipy": [], "tensorflow": [] } ]
GUO-Liping/Work_excel
[ "6c74dd28552a8dd7de32a93dab3f17e717c37458" ]
[ "work_with_excel.py" ]
[ "# -*- coding utf-8 -*-\nimport pandas as pd\na = pd.read_excel('data_a.xlsx', index_col=[0], header=[0])\nb = pd.read_excel('data_b.xlsx', sheet_name=None, index_col=None, header=None, skiprows=0, na_values=['NA']) # it's a dictionary\n# where index_col=[0] means that using the first column as the index rows\n# i...
[ [ "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": [] } ]
ZhuangLab/Chromatin_Analysis_2020_cell
[ "ecc0d3e92e8b9cb0dcf970c29440f91404055da6" ]
[ "sequential_tracing/source/domain_tools/DomainAnalysis.py" ]
[ "import matplotlib.pylab as plt\nimport numpy as np\nimport pickle,os\nfrom mpl_toolkits.mplot3d import Axes3D\nfrom scipy.spatial.distance import pdist,cdist,squareform\nfrom sklearn.cluster import DBSCAN\ndef rg_med(zxy):\n zxy_ = np.array(zxy)\n zxy_ = zxy_[~np.isnan(zxy_[:,0])]\n zxy_ = zxy_ - np.media...
[ [ "numpy.nanmax", "scipy.signal.find_peaks", "sklearn.cluster.DBSCAN", "scipy.ndimage.interpolation.map_coordinates", "numpy.all", "numpy.max", "numpy.concatenate", "numpy.mean", "numpy.nanmean", "numpy.where", "numpy.unique", "matplotlib.pylab.xlim", "numpy.arang...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [ "1.6", "1.4", "1.5", "1.2", "1.7", "1.3" ], "tensorflow": [] } ]
rboman/progs
[ "c60b4e0487d01ccd007bcba79d1548ebe1685655", "c60b4e0487d01ccd007bcba79d1548ebe1685655" ]
[ "sandbox/qt/codingtrain/cc23_supershape2d.py", "sandbox/fortranpython/navaro/fortranarrays.py" ]
[ "#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\n\n# from \"SuperShape2D\" (Daniel Shiffman)\n# Video: https://youtu.be/ksRoh-10lak\n\n# supershapes: http://paulbourke.net/geometry/supershape/\n\nimport sys, os\nfrom PyQt5.QtWidgets import *\nfrom PyQt5.QtGui import *\nfrom PyQt5.QtCore import *\nimport math\nimpo...
[ [ "numpy.arange" ], [ "numpy.dot", "numpy.array" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
anthonyhu/domain-adapt
[ "8c390becdf7093e1cdb8e61c6be0f35e387db898" ]
[ "keras_model/utils.py" ]
[ "import numpy as np\nimport tensorflow as tf\nimport tensorflow.keras.backend as K\n\n\ndef preprocess_image(image, out_size):\n \"\"\" Tensorflow image preprocessing: bilinear resizing, and normalising to [-1, 1]\n\n Parameters\n ----------\n image: tf.Tensor\n output from tf.read_file\n...
[ [ "tensorflow.image.random_flip_left_right", "tensorflow.read_file", "tensorflow.image.resize_images", "numpy.uint8", "tensorflow.image.random_crop", "tensorflow.keras.backend.reshape", "tensorflow.keras.backend.constant", "tensorflow.Summary", "tensorflow.image.decode_jpeg" ] ...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10" ] } ]
TorchDrift/TorchDrift
[ "bda529a7a26c1a9b14d8d878a75122ece22b95d6" ]
[ "torchdrift/detectors/mmd.py" ]
[ "from typing import Optional\n\nimport torch\n\nfrom . import Detector\nimport torchdrift.utils\n\n\nclass Kernel:\n \"\"\"Base class for kernels\n\n Unless otherwise noted, all kernels implementing lengthscale detection\n use the median of pairwise distances as the lengthscale.\"\"\"\n\n pass\n\n\nclas...
[ [ "torch.true_divide", "torch.randperm", "torch.exp", "torch.cdist", "torch.stack", "torch.pow" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
enricovian/GraphSAGE
[ "0cdda29dbc075fb8f3441c15638d1b06de992a57" ]
[ "graphsage/layers.py" ]
[ "from __future__ import division\nfrom __future__ import print_function\n\nimport tensorflow as tf\n\nfrom graphsage.inits import zeros\n\nflags = tf.app.flags\nFLAGS = flags.FLAGS\n\n# DISCLAIMER:\n# Boilerplate parts of this code file were originally forked from\n# https://github.com/tkipf/gcn\n# which itself was...
[ [ "tensorflow.matmul", "tensorflow.name_scope", "tensorflow.contrib.layers.xavier_initializer", "tensorflow.contrib.layers.l2_regularizer", "tensorflow.variable_scope", "tensorflow.nn.dropout", "tensorflow.summary.histogram" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10" ] } ]
sindura-sriram/biobert
[ "a296da725d8631483a083cc18af14145653b4c58" ]
[ "extract_features.py" ]
[ "# Databricks notebook source\n# coding=utf-8\n# Copyright 2018 The Google AI Language Team 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/...
[ [ "tensorflow.contrib.tpu.TPUEstimator", "tensorflow.train.Scaffold", "tensorflow.constant", "tensorflow.gfile.Open", "tensorflow.gfile.GFile", "tensorflow.train.init_from_checkpoint", "tensorflow.logging.info", "tensorflow.logging.set_verbosity", "tensorflow.contrib.tpu.TPUConfi...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10" ] } ]
intuinno/visinsight
[ "94ef3f9f7921e272c59a4e503fde897414d9adab" ]
[ "sample.py" ]
[ "import torch\r\nimport matplotlib.pyplot as plt\r\nimport argparse\r\nimport pickle \r\nfrom torch.autograd import Variable \r\nfrom torchvision import transforms \r\nfrom data_loader import build_vocab \r\nfrom model import EncoderCNN, DecoderRNN\r\nfrom model import ResNet, ResidualBlock\r\nfrom attn_model impor...
[ [ "torch.load", "torch.cuda.is_available", "torch.autograd.Variable" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
CongBao/ImageEnhancer
[ "0f1b3131a2a573f9d00ec9cb6bb0ce69dac169f2" ]
[ "ie/utilities/image_io.py" ]
[ "\"\"\" Load images from file \"\"\"\n\nfrom __future__ import division\n\nimport os\nimport random\n\nimport numpy as np\nfrom scipy import misc\nfrom tqdm import tqdm\nfrom joblib import Parallel, delayed\n\n__author__ = 'Cong Bao'\n\ndef _load_img(img_list, img_dir, i):\n return misc.imread(img_dir + img_list...
[ [ "numpy.asarray", "numpy.shape", "scipy.misc.imread" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [ "0.13", "0.14", "0.15", "1.0", "0.19", "0.18", "1.2", "0.12", "0.10", "0.17", "0.16" ], "tensorflow": [] } ]
saeedm31/ACTIN
[ "44c3d4d729b5173cf1f5b0a5fd1e7a8659c6636e" ]
[ "actin/actin_files/ac_read_data.py" ]
[ "#!/usr/bin/env python\n\n\n# compatibility with python 2/3:\nfrom __future__ import print_function\nfrom __future__ import division\n\nimport sys, os\nimport numpy as np\nimport glob\n\nimport astropy.io.fits as pyfits\nimport matplotlib.pylab as plt\n\n# ACTIN modules:\nimport ac_tools\nimport ac_settings as ac_s...
[ [ "matplotlib.pylab.show", "numpy.poly1d", "numpy.asarray", "numpy.arange", "numpy.median", "numpy.diff", "matplotlib.pylab.ylabel", "matplotlib.pylab.plot", "matplotlib.pylab.xlabel", "numpy.zeros" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
mvoran/iTunesAppReviewScraper
[ "f51ab0575dc567e2f3e76f35c6a26b2d344abcd2" ]
[ "scraper/scraper.py" ]
[ "import requests\nimport xml.etree.ElementTree as ET\nimport re\nimport dateparser\nimport pandas as pd\n\nfrom itunes_app_review_scraper.config import Config\n\nbasepath = None\n\nclass iTunesScraper(object):\n @classmethod\n def _request_itunes(cls, app_id, store_id, page):\n headers = {'X-Apple-Stor...
[ [ "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": [] } ]
februarysea/machinelearning
[ "c82f62acf16aef66b44e5f06f9b288be44c3cb64" ]
[ "week3/algorithm4.py" ]
[ "# algorithm4.py\n# logistic regression\n\nimport numpy as np\nfrom matplotlib import pyplot as plt\n\ndef logistic_regression(x, y):\n cost_functions = []\n\n # the number of sample\n m = len(x)\n # the number of fearture\n n = len(x[0])\n # learning rate\n alpha = 0.001\n # initialization ...
[ [ "numpy.log", "matplotlib.pyplot.title", "numpy.matmul", "numpy.empty", "matplotlib.pyplot.plot", "numpy.exp", "matplotlib.pyplot.xlabel", "numpy.array", "numpy.zeros", "matplotlib.pyplot.show", "matplotlib.pyplot.ylabel" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
vishalbelsare/grblas
[ "d181ac4cb495d1bc806253137f53a42d65693b5e" ]
[ "grblas/_ss/prefix_scan.py" ]
[ "from math import ceil, log2\n\nimport numba\nimport numpy as np\n\nimport grblas as gb\n\nfrom .. import binary\nfrom ..operator import get_semiring, get_typed_op\n\n\n@numba.njit\ndef compact_indices(indptr, size): # pragma: no cover\n \"\"\"Given indptr from hypercsr, create a new col_indices array that is c...
[ [ "numpy.arange", "numpy.empty", "numpy.ones" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
keisuke-umezawa/ATRank
[ "391452ee1deacaa600f6cfc405afbed5fb389b87" ]
[ "atrank/train.py" ]
[ "import logging\nimport os\nimport time\nimport json\nimport joblib\nimport pickle\nimport random\nimport numpy as np\nfrom collections import OrderedDict, defaultdict\n\nimport torch\nimport torch.nn.functional as F\nfrom torchviz import make_dot\n\nfrom input import DataInput, DataInputTest\nfrom model import Mod...
[ [ "torch.sigmoid", "torch.LongTensor", "numpy.random.seed", "torch.Tensor", "torch.manual_seed", "torch.zeros_like", "torch.no_grad", "torch.cuda.is_available", "torch.IntTensor", "torch.ones_like" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
csbhr/OpenUtility
[ "0db908d5598275e0cf73b5bafb7e5be32c51a81e" ]
[ "utils/PerceptualSimilarity/models/__init__.py" ]
[ "\nfrom __future__ import absolute_import\nfrom __future__ import division\nfrom __future__ import print_function\n\nimport numpy as np\nfrom skimage.measure import compare_ssim\nimport torch\n\nfrom utils.PerceptualSimilarity.models import dist_model\n\nclass PerceptualLoss(torch.nn.Module):\n def __init__(self...
[ [ "numpy.maximum", "numpy.arange", "torch.sum", "numpy.concatenate", "numpy.max", "numpy.mean", "numpy.prod", "numpy.transpose", "numpy.where", "numpy.sum", "numpy.isclose" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
jonholdship/UCLCHEM
[ "a946815b2e6ab275f658ed64463dcd4e32fcdc17" ]
[ "scripts/example_plotting_script.py" ]
[ "\"\"\"\nA script largely intended for people unfamiliar with Python.\nIf you run run_uclchem_tests.py, you'll produce several example model outputs.\nThis script then uses those outputs to demonstrate some simple plotting.\n\"\"\"\n\nimport uclchem\nimport matplotlib.pyplot as plt\n#pick species, any number is fin...
[ [ "matplotlib.pyplot.subplots" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]