repo_name
stringlengths
6
130
hexsha
list
file_path
list
code
list
apis
list
possible_versions
list
kim-chae-yeon/Space_Bar
[ "d2520c44e81fce9cb0ecd4cd2665285083706acf" ]
[ "balance_test/gametest.py" ]
[ "from numpy import random\n\nmap_x_size = 10\nmap_list = [0 for i in range(map_x_size)]\n\nclass Character:\n def __init__(self,level, HP, atk, speed, attack_speed, critical_hit_rate, evasion_rate, exp):\n print(\"Character Production\")\n self.result = 0\n self.level = level\n self.H...
[ [ "numpy.random.binomial" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
babky/pandas
[ "2c912f139bddc828465794004a2f5435fffc9799" ]
[ "pandas/tests/io/formats/test_format.py" ]
[ "# -*- coding: utf-8 -*-\n\n\"\"\"\nTest output formatting for Series/DataFrame, including to_string & reprs\n\"\"\"\n\nfrom __future__ import print_function\nimport re\n\nimport pytz\nimport dateutil\nimport itertools\nfrom operator import methodcaller\nimport os\nimport sys\nimport warnings\nfrom datetime import ...
[ [ "pandas.to_datetime", "pandas.Series", "numpy.linspace", "pandas.core.config.reset_option", "pandas.MultiIndex.from_tuples", "pandas.DataFrame", "numpy.random.randn", "pandas.compat.lzip", "numpy.where", "pandas.util.testing.reset_display_options", "pandas.reset_option"...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
mathieu-charbonnel/GAN_brain_tumour_evolution
[ "b344329001acd8992b49f90f8b9c5ed138ba9fa1" ]
[ "data/aligned_dataset_time.py" ]
[ "import os.path\nimport random\nimport torchvision.transforms as transforms\nimport torch\nfrom data.base_dataset import BaseDataset\nfrom data.image_folder import make_dataset\nfrom PIL import Image\nfrom skimage import io\nimport SimpleITK as sitk\nimport numpy as np\nfrom PIL import ImageChops\n\n\n\n\n\nclass A...
[ [ "torch.LongTensor", "numpy.absolute", "numpy.zeros" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
aliyakamercan/open_spiel
[ "99e110fd22794e464296ef6c7763ad05a759948e" ]
[ "open_spiel/integration_tests/api_test.py" ]
[ "# Copyright 2019 DeepMind Technologies Ltd. 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 r...
[ [ "numpy.array_equal" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
ElephantGit/libfacedetection.train
[ "352659337a8117c10c368dad26b2b1c2096a8553" ]
[ "tasks/task1/detect.py" ]
[ "#!/usr/bin/python3\nfrom __future__ import print_function\n\nimport os\nimport sys\nimport torch\nimport torch.backends.cudnn as cudnn\nimport argparse\nimport cv2\nimport numpy as np\nfrom collections import OrderedDict\n\nsys.path.append(os.getcwd() + '/../../src')\n\nfrom config import cfg\nfrom prior_box impor...
[ [ "numpy.hstack", "torch.Tensor", "torch.load", "torch.cuda.current_device", "torch.from_numpy", "torch.set_grad_enabled", "numpy.float32", "torch.device", "numpy.array", "numpy.where" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
squatter1/skills-ml
[ "0c856328b73740aa343ccdbe6c7ca8fcfb797b69" ]
[ "algorithms/jobtitle_cleaner/clean.py" ]
[ "import pandas as pd\nimport re\nfrom collections import OrderedDict\nimport logging\n\nfrom datasets import negative_positive_dict\n\ndef clean_by_rules(jobtitle):\n \"\"\"\n Remove numbers\n :params string jobtitle: A job title string\n :return: A cleaned version of job title\n :rtype: string\n ...
[ [ "pandas.DataFrame" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "0.23", "0.21", "2.0", "1.4", "0.19", "1.1", "1.5", "1.2", "0.24", "0.20", "1.0", "0.25", "1.3" ], "scipy": [], "tensorflow": [] } ]
yuokamoto/PythonRobotics
[ "ac066ee6049adc6315a859127344ee5de1e48b30" ]
[ "PathTracking/move_to_pose/move_to_pose.py" ]
[ "\"\"\"\n\nMove to specified pose\n\nAuthor: Daniel Ingram (daniel-s-ingram)\n Atsushi Sakai(@Atsushi_twi)\n\nP. I. Corke, \"Robotics, Vision & Control\", Springer 2017, ISBN 978-3-319-54413-7\n\n\"\"\"\n\nimport matplotlib.pyplot as plt\nimport numpy as np\nfrom random import random\n\n# simulation paramete...
[ [ "numpy.sqrt", "matplotlib.pyplot.ylim", "matplotlib.pyplot.cla", "numpy.matmul", "numpy.cos", "numpy.sin", "matplotlib.pyplot.plot", "numpy.arctan2", "matplotlib.pyplot.xlim", "numpy.array", "matplotlib.pyplot.pause" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
AemaH/AemaH.github.io
[ "7ffbf9de550368c98109195da830f5bb2eb94026" ]
[ "source_code/DQN.py" ]
[ "import gym\nimport numpy as np\nimport random\nimport tensorflow as tf\n#import tensorflow.contrib.silm as slim\nimport matplotlib.pyplot as plt\nimport scipy.misc\nimport os\n\n\nslim = tf.contrib.slim\n\n\"\"\"\n本来想写成tensorboard的形式的 相关的参数和variable_scope也已经设置好了,也只差\n\"\"\"\n\n#加载环境 一个gridworld环境\nfrom gridworld i...
[ [ "numpy.mean", "tensorflow.train.AdamOptimizer", "tensorflow.summary.scalar", "numpy.random.randint", "numpy.reshape", "tensorflow.get_collection", "tensorflow.reset_default_graph", "tensorflow.name_scope", "tensorflow.Session", "tensorflow.square", "tensorflow.trainable...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10" ] } ]
wzhang2022/GraphGym
[ "b456a3c3e930e9e881da37803eefb24df2d4a858" ]
[ "graphgym/contrib/layer/idconv.py" ]
[ "import torch\nimport torch.nn as nn\nimport torch.nn.functional as F\nfrom torch.nn import Parameter\nfrom torch_scatter import scatter_add\nfrom torch_geometric.nn.conv import MessagePassing\nfrom torch_geometric.utils import add_remaining_self_loops\nfrom torch_geometric.utils import remove_self_loops, add_self_...
[ [ "torch.nn.functional.normalize", "torch.Tensor", "torch.nn.functional.dropout", "torch.cat", "torch.is_tensor", "torch.matmul", "torch.nn.Linear", "torch.nn.functional.leaky_relu", "torch.nn.ReLU", "torch.index_select" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
ttung/starfish
[ "1bd8abf55a335620e4b20abb041f478334714081" ]
[ "starfish/imagestack/imagestack.py" ]
[ "import collections\nimport warnings\nfrom copy import deepcopy\nfrom functools import partial\nfrom itertools import product\nfrom json import loads\nfrom pathlib import Path\nfrom typing import (\n Any,\n Callable,\n Iterable,\n Iterator,\n List,\n Mapping,\n MutableMapping,\n MutableSeque...
[ [ "numpy.linspace", "numpy.clip", "numpy.min", "pandas.DataFrame", "numpy.max", "numpy.random.normal", "numpy.random.poisson", "scipy.ndimage.filters.gaussian_filter", "numpy.iinfo", "numpy.moveaxis", "numpy.zeros" ] ]
[ { "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": [ "0.13", "1.6", "0.14", "0.15", "1...
azlyth/keras-retinanet
[ "46f96ee241894d8c2bb0b9560f4c8b73ac3141ff" ]
[ "keras_retinanet/backend/tensorflow_backend.py" ]
[ "\"\"\"\nCopyright 2017-2018 Fizyr (https://fizyr.com)\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable la...
[ [ "tensorflow.gather_nd", "tensorflow.range", "tensorflow.image.resize_images", "tensorflow.image.non_max_suppression", "tensorflow.nn.top_k", "tensorflow.where", "tensorflow.meshgrid" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10" ] } ]
triasamo1/OpenPCDet
[ "4210d223fbda7c8db5b2dc042b66cfc23ed6d895" ]
[ "pcdet/datasets/kitti/kitti_object_eval_python/eval_triasPEDCYCL.py" ]
[ "import io as sysio\n\nimport numba\nimport numpy as np\n\nimport csv # trias \n\nfrom .rotate_iou import rotate_iou_gpu_eval\n\n\n@numba.jit\ndef get_thresholds(scores: np.ndarray, num_gt, num_sample_pts=41):\n scores.sort()\n scores = scores[::-1]\n current_recall = 0\n thresholds = []\n for i, sco...
[ [ "numpy.linspace", "numpy.cos", "numpy.stack", "numpy.concatenate", "numpy.max", "numpy.array", "numpy.zeros", "numpy.sum" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
aisari/torchsar
[ "05a46610d68bc884743a483565279f361ade5384" ]
[ "torchsar/autofocus/maximum_contrast.py" ]
[ "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n# @Date : 2020-07-25 19:44:35\n# @Author : Zhi Liu (zhiliu.mind@gmail.com)\n# @Link : http://iridescent.ink\n# @Version : $1.0$\n\nfrom __future__ import print_function\nimport torch as th\nimport torchsar as ts\nfrom progressbar import *\n\n\ndef mcaf_sm(x, p...
[ [ "torch.abs", "matplotlib.pyplot.imshow", "torch.sum", "torch.from_numpy", "matplotlib.pyplot.plot", "matplotlib.pyplot.ylabel", "matplotlib.pyplot.subplot", "matplotlib.pyplot.grid", "matplotlib.pyplot.xlabel", "matplotlib.pyplot.show", "matplotlib.pyplot.figure" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
Jss7268/magenta
[ "10e0b2c50baaa01a9c942ed3334b5b2cca761bef" ]
[ "magenta/models/polyamp/full_model.py" ]
[ "# Copyright 2020 Jack Spencer Smith.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable law or...
[ [ "tensorflow.convert_to_tensor", "tensorflow.keras.models.Model", "tensorflow.keras.backend.int_shape", "tensorflow.roll", "tensorflow.keras.backend.expand_dims", "tensorflow.keras.backend.cast_to_floatx", "tensorflow.keras.backend.stop_gradient", "tensorflow.keras.preprocessing.seq...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "2.7", "2.6", "2.4", "2.3", "2.5", "2.2" ] } ]
Auburn-Automow/au_automow_common
[ "920be6a740aa6d738e9954417b41490e353efd04" ]
[ "automow_ekf/scripts/imu_listener.py" ]
[ "#!/usr/bin/env python\nimport roslib\nroslib.load_manifest('automow_ekf')\n\nimport rospy\nimport math\nimport numpy as np\nimport tf\nfrom sensor_msgs.msg import Imu\nfrom geometry_msgs.msg import Vector3\n\nfrom tf.transformations import euler_from_quaternion as efq\nfrom tf.transformations import quaternion_fro...
[ [ "numpy.mod" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
bikongyouran/tensorflow-1
[ "6fdb9ad1baf7686a75f9e660178f7ac595e7fc2e" ]
[ "tensorflow/python/ops/control_flow_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.ops.math_ops.greater_equal", "tensorflow.python.ops.math_ops.subtract", "tensorflow.python.framework.tensor_shape.TensorShape", "tensorflow.python.ops.control_flow_util.IsSwitch", "tensorflow.python.ops.gen_control_flow_ops._switch", "tensorflow.python.eager.context.in_e...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "2.8", "1.10", "2.7", "1.4", "2.2", "2.3", "2.4", "2.9", "1.5", "1.7", "2.5", "0.12", "1.0", "2.6", "1.2", "2.10" ] } ...
Kurene/cqt
[ "82f14ee660a84357e05102c6ee81e29c1a6cdb54" ]
[ "cqt.py" ]
[ "# -*- coding: utf-8 -*-\n\"\"\"\nWritten by kurene@https://www.wizard-notes.com\n\nReferences:\n\n - Brown, Judith C. \n \"Calculation of a constant Q spectral transform.\" \n The Journal of the Acoustical Society of America 89.1 (1991): 425-434.\n - Schörkhuber, Christian, and Anssi Klapuri. \n \"Const...
[ [ "numpy.sqrt", "matplotlib.pyplot.title", "numpy.fft.fft", "numpy.abs", "numpy.arange", "scipy.sparse.csr_matrix", "matplotlib.pyplot.colorbar", "numpy.ceil", "matplotlib.pyplot.clf", "matplotlib.pyplot.subplot", "numpy.array", "matplotlib.pyplot.show", "numpy.ze...
[ { "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"...
jiankaiwang/ioutracker
[ "8a55925fd5488a340b2ca5095d35105cc34b6cb8" ]
[ "ioutracker/inference/MOTDet17Main.py" ]
[ "#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\n\"\"\"\n@author: jiankaiwang\n@version: 0.0.1\n@date: 2020/03\n@desc: An Entry Example of IOU Tracker on MOT Datasets\n@note:\n Style: pylint_2015\n@reference:\n Article: http://elvera.nue.tu-berlin.de/files/1517Bochinski2017.pdf\n\"\"\"\n\nimport os\nimport time\...
[ [ "numpy.array", "numpy.random.seed", "numpy.random.randint" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
DecaYale/RNNPose
[ "18d1a2b12d2c82499b0da363a39f421cdc0f4b77" ]
[ "utils/visualize.py" ]
[ "import numpy as np \nimport cv2 \nimport copy\n\ndef vis_pointclouds_cv2(pc, K, win_size, init_transform=None, color=None, img=None):\n '''\n pc: input point cloud of shape Nx3\n K: camera intrinsic of shape 3x3\n win_size: visualization window size (Wx,Wy)\n '''\n x = (K@pc.T).T #Nx3\n \n ...
[ [ "numpy.around", "numpy.zeros_like" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
trnielsen/nexus-constructor
[ "65efb6eedca30250b75f142dd29a46bc909958df" ]
[ "definitions/manual/source/examples/h5py/BasicWriter.py" ]
[ "#!/usr/bin/env python\n'''Writes a NeXus HDF5 file using h5py and numpy'''\n\nimport h5py # HDF5 support\nimport numpy\nimport six\n\nprint(\"Write a NeXus HDF5 file\")\nfileName = u\"prj_test.nexus.hdf5\"\ntimestamp = u\"2010-10-18T17:17:04-0500\"\n\n# load data from two column format\ndata = numpy.loadtxt(u\"...
[ [ "numpy.asarray", "numpy.loadtxt" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
hscspring/hnlp
[ "20eb3172e6b3ecfe47fa6d657e7db4b3cf445404" ]
[ "hnlp/sampler/sampler_tf.py" ]
[ "import tensorflow as tf\n\n\ntf.random.set_seed(42)\n\n\ndef gen_input(\n batch_size: int = 3, seq_len: int = 20, inp_num: int = 1, label_num: int = 2\n):\n res = []\n for i in range(inp_num):\n inp = tf.random.uniform(\n shape=(batch_size, seq_len), minval=0, maxval=1000, dtype=tf.i...
[ [ "tensorflow.random.uniform", "tensorflow.random.set_seed" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
salasouza/tasksfordata
[ "ae1ef54aa431bf26433861d66112df33608dbefc" ]
[ "sankey_diagram.py" ]
[ "import pandas as pd\nimport holoviews as hv\nfrom holoviews import opts, dim\nhv.extension('bokeh')\nimport matplotlib.pyplot as plt\n\nsankey = hv.Sankey([\n ['a', 'b', 90],\n ['a', 'Desistência', 10],\n\n ['b', 'c', 80],\n ['b', 'Desistência', 10],\n\n ['c', 'd', 70],\n ['c', 'Desistência', 10]...
[ [ "matplotlib.pyplot.sankey.opts", "matplotlib.pyplot.show" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
ivanychev/catboost
[ "aec8b8beb11223840bdc0d41b5f473758700b5ad" ]
[ "catboost/python-package/catboost/utils.py" ]
[ "from . import _catboost\nfrom .core import Pool, CatBoostError, ARRAY_TYPES, STRING_TYPES, _update_params_quantize_part, _process_synonyms\nfrom collections import defaultdict\nfrom contextlib import contextmanager\nimport numpy as np\nimport warnings\n\n_eval_metric_util = _catboost._eval_metric_util\n_get_roc_cu...
[ [ "numpy.array", "matplotlib.pyplot.yticks", "matplotlib.pyplot.title", "matplotlib.pyplot.plot", "matplotlib.pyplot.ylabel", "matplotlib.pyplot.grid", "matplotlib.pyplot.xlabel", "matplotlib.pyplot.xticks", "matplotlib.pyplot.show", "matplotlib.pyplot.figure" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
christian-oreilly/acareeg
[ "341b328a3623e2a29cdc28bfe0378b0050681077" ]
[ "acareeg/visualization.py" ]
[ "# Authors: Christian O'Reilly <christian.oreilly@gmail.com>\n# License: MIT\n\nimport matplotlib.pyplot as plt\nfrom mne.externals.pymatreader import read_mat\nfrom mne.transforms import apply_trans\nimport numpy as np\nimport nibabel as nib\nimport pandas as pd\nfrom scipy.spatial import KDTree\nfrom nibabel.free...
[ [ "numpy.linspace", "numpy.unique", "numpy.asarray", "numpy.eye", "matplotlib.pyplot.get_cmap", "matplotlib.pyplot.subplots", "numpy.round", "scipy.spatial.KDTree", "matplotlib.cm.ScalarMappable", "numpy.any", "numpy.digitize", "numpy.array", "numpy.where", "m...
[ { "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"...
niannujiaowj/abusive-language-online-master
[ "3ce2cb77daa93dd8763dc58a176bbcdbd2e38438" ]
[ "lstm-2010-04-22.py" ]
[ "#coding=utf-8\n#!/usr/bin/env python\nimport numpy as np\nfrom numpy.random import choice\nimport os\nimport pandas as pd\nimport sys\nimport nltk\nimport tensorflow as tf\nimport time\n\nHOME = '.'\nsys.path.insert(0, HOME)\nfrom alo import dataset\nfrom alo import word_embed\nfrom alo import nn\nfrom alo import ...
[ [ "numpy.hstack", "tensorflow.Graph", "tensorflow.app.flags.DEFINE_integer", "tensorflow.global_variables_initializer", "tensorflow.app.flags.DEFINE_string", "tensorflow.Session", "tensorflow.app.flags.DEFINE_float", "tensorflow.train.Saver", "numpy.array", "numpy.vstack", ...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10" ] } ]
GaelLeFloch/simpletransformers
[ "d622248ac28080c7c126b6dafcf0e7e66eb2b5f9" ]
[ "simpletransformers/seq2seq/seq2seq_utils.py" ]
[ "import logging\nimport os\nimport pickle\nfrom multiprocessing import Pool\nfrom typing import Tuple\n\nimport pandas as pd\nimport torch\nfrom tokenizers.implementations import ByteLevelBPETokenizer\nfrom tokenizers.processors import BertProcessing\nfrom torch.utils.data import Dataset\nfrom tqdm.auto import tqdm...
[ [ "torch.flatten" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
JIceberg/CS-229
[ "464f42d853b321c6940a6d6547b674cf71691ea5" ]
[ "src/lesson3/perceptron.py" ]
[ "import numpy as np\nfrom random import randint\nimport matplotlib.pyplot as plt\n\nx1_red = np.array([randint(0, 10) for _ in range(randint(5, 10))])\nx2_red = np.array([randint(-10, 0) for _ in range(len(x1_red))])\nplt.plot(x1_red, x2_red, 'ro')\n\nx1_blue = np.array([randint(-10, 0) for _ in range(randint(5, 10...
[ [ "numpy.dot", "numpy.linspace", "matplotlib.pyplot.plot", "numpy.concatenate", "matplotlib.pyplot.show" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
eechava6/NumericalAnalysisMethods
[ "3eeb06bdb20d97f13a09fd0ed71bce045173ffef" ]
[ "Python/cholesky.py" ]
[ "from math import sqrt\r\nfrom pprint import pprint\r\nimport numpy as np\r\n\r\n\r\n#Cholesky\r\ndef cholesky(A):\r\n rows = len(A)\r\n columns = len(A[0])\r\n Z = np.zeros((rows,1), float)\r\n X = np.zeros((rows, 1), float)\r\n #X = np.array([[1],[1],[1],[1]])\r\n #Z = np.array([[1,1,1,1],[1,1,1...
[ [ "numpy.concatenate", "numpy.linalg.eigvals", "numpy.array", "numpy.zeros" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
stweil/sbb_ner
[ "319c29fc96667937f85d2cba111902386c95ba23" ]
[ "qurator/sbb_ner/ground_truth/germeval.py" ]
[ "import pandas as pd\nimport click\nimport os\n\n\ndef read_gt(files, datasets):\n sentence_number = 200000\n gt_data = list()\n\n for filename, dataset in zip(files, datasets):\n gt_lines = [l.strip() for l in open(filename)]\n\n word_number = 0\n\n for li in gt_lines:\n\n ...
[ [ "pandas.DataFrame" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "0.23", "0.21", "2.0", "1.4", "0.19", "1.1", "1.5", "1.2", "0.24", "0.20", "1.0", "0.25", "1.3" ], "scipy": [], "tensorflow": [] } ]
evgeny-izutov/mmaction
[ "c92d29af87f2373641e2d29bdb14705939fc5423" ]
[ "mmaction/core/ops/dropout.py" ]
[ "import torch\nimport torch.nn as nn\nimport torch.nn.functional as F\n\n\nclass Dropout(nn.Module):\n DISTRIBUTIONS = ['bernoulli', 'gaussian']\n\n def __init__(self, p=0.5, mu=0.5, sigma=0.2, dist='bernoulli'):\n super(Dropout, self).__init__()\n\n self.dist = dist\n assert self.dist in...
[ [ "torch.no_grad", "torch.nn.functional.dropout" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
hanwenyuan0907/sentence-transformers
[ "b704972c26c621279b94daab6168e57d1f27c122" ]
[ "examples/training/ms_marco/train_bi-encoder.py" ]
[ "\"\"\"\nThis examples show how to train a Bi-Encoder for the MS Marco dataset (https://github.com/microsoft/MSMARCO-Passage-Ranking).\n\nThe queries and passages are passed independently to the transformer network to produce fixed sized embeddings.\nThese embeddings can then be compared using cosine-similarity to ...
[ [ "torch.utils.data.DataLoader" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
cmougan/FairShift
[ "a065edb92da7c259a4f402eed3a81e36d65bd01d" ]
[ "folks/samplingOOD.py" ]
[ "# %%\nimport warnings\n\nwarnings.filterwarnings(\"ignore\")\nfrom folktables import (\n ACSDataSource,\n ACSIncome,\n ACSEmployment,\n ACSMobility,\n ACSPublicCoverage,\n ACSTravelTime,\n)\n\nimport pandas as pd\nfrom collections import defaultdict\nfrom scipy.stats import kstest, wasserstein_di...
[ [ "sklearn.ensemble.RandomForestRegressor", "sklearn.metrics.roc_auc_score", "sklearn.model_selection.cross_val_predict", "scipy.stats.wasserstein_distance", "numpy.random.seed", "sklearn.dummy.DummyRegressor", "pandas.DataFrame", "sklearn.svm.SVR", "sklearn.linear_model.LinearRe...
[ { "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": [ "1.6", "1.10", "1.4", "1.9", "1.5...
gsk-gagan/nft_analyser
[ "7a16d18500fcd48dce22f86251eaf6be6a272141" ]
[ "nft_analyser/main.py" ]
[ "import time\nimport json\nfrom importlib import resources\nfrom typing import Sequence, Union, Optional, Any\n\nimport pandas as pd\nimport numpy as np\nimport keras\nimport tensorflow as tf\nimport nltk\nfrom sklearn.model_selection import train_test_split, RandomizedSearchCV\nfrom scipy.stats import reciprocal\n...
[ [ "scipy.stats.reciprocal", "sklearn.model_selection.RandomizedSearchCV", "numpy.arange", "tensorflow.keras.utils.plot_model", "sklearn.model_selection.train_test_split", "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": [ "1.10", "2.7", "2.2", ...
KellyLBennett/malariagen-data-python
[ "ce4c7a88cd1cea88a7ee8f8681ef422e19003561" ]
[ "tests/test_ag3.py" ]
[ "import random\n\nimport dask.array as da\nimport numpy as np\nimport pandas as pd\nimport pytest\nimport scipy.stats\nimport xarray\nimport zarr\nfrom numpy.testing import assert_array_equal\nfrom pandas.testing import assert_frame_equal\n\nfrom malariagen_data import Ag3, Region\nfrom malariagen_data.ag3 import _...
[ [ "pandas.concat", "pandas.Series", "numpy.min", "numpy.all", "numpy.max", "pandas.testing.assert_frame_equal", "numpy.any", "numpy.count_nonzero", "numpy.array", "numpy.random.randint" ] ]
[ { "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": [] } ]
Yabing67/mmdetection3d
[ "b1068ce271ecc4c41ab0bd51e234879f3fb214c8" ]
[ "tools/test.py" ]
[ "import argparse\nimport mmcv\nimport os\nimport torch\nimport warnings\nfrom mmcv import Config, DictAction\nfrom mmcv.cnn import fuse_conv_bn\nfrom mmcv.parallel import MMDataParallel, MMDistributedDataParallel\nfrom mmcv.runner import (get_dist_info, init_dist, load_checkpoint,\n wrap_fp1...
[ [ "torch.cuda.current_device" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
Woife5/video-face-extractor
[ "d8f0c1c3e6567409dc60875ff074a4cb422f2877" ]
[ "extract-faces.py" ]
[ "## Set the filename for the next image to be written\ncounter = 0\n\n## Is this is set to true, existing images in /faces will be overwritten, otherwise\n## the existing image names will be skipped\noverwrite_images = False\n\n## Set set all videos you want to extract faces from\n## These videos should be located ...
[ [ "numpy.arccos" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
datamonday/FR-AttSys
[ "6fb34fea8515cd7612cce92beb2048c4c1e83a93" ]
[ "utils/GeneratorModel.py" ]
[ "from imutils import paths\nimport numpy as np\nimport imutils\nimport pickle\nimport cv2\nimport os\nimport sys\nfrom sklearn.preprocessing import LabelEncoder\nfrom sklearn.svm import SVC\n\nrootdir = \"D://Github//FR-AttSys//dataset//\"\nsys.path.append(rootdir)\n\n\ndef Generator():\n # 人脸数据所在路径\n face_da...
[ [ "numpy.array", "sklearn.preprocessing.LabelEncoder", "numpy.argmax", "sklearn.svm.SVC" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
TileDB-Inc/TileDB-Py
[ "a5b0371d34020c17c351d560edb786d2224ad32f" ]
[ "tiledb/tests/test_fragment_info.py" ]
[ "import itertools\n\nimport numpy as np\nimport pytest\n\nimport tiledb\nfrom tiledb.main import PyFragmentInfo\nfrom tiledb.tests.common import DiskTestCase\n\n\nclass FragmentInfoTest(DiskTestCase):\n def setUp(self):\n super().setUp()\n if not tiledb.libtiledb.version() >= (2, 2):\n p...
[ [ "numpy.arange", "numpy.array", "numpy.zeros", "numpy.datetime64" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
fisher335/facenet-retinaface-pytorch
[ "2010266f774c8e93b7c6c18b46470292a0db33a7" ]
[ "nets/facenet.py" ]
[ "import torch.nn as nn\nfrom torch.nn import functional as F\n\nfrom nets.inception_resnetv1 import InceptionResnetV1\nfrom nets.mobilenet import MobileNetV1\n\n\nclass mobilenet(nn.Module):\n def __init__(self):\n super(mobilenet, self).__init__()\n self.model = MobileNetV1()\n del self.mod...
[ [ "torch.nn.functional.normalize", "torch.nn.BatchNorm1d", "torch.nn.Dropout", "torch.nn.Linear", "torch.nn.AdaptiveAvgPool2d" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
dwu9/mazefun
[ "031111928c6e080e633910fb37d7fa4e7c05da33" ]
[ "Oldcrap/generatorv2.py" ]
[ "import numpy as np\nfrom random import randint\nfrom PIL import Image\nimport matplotlib.pyplot as pyplot\n\n# Basic implementation of recursive division maze generation\n# Credit to Wikipedia.org Maze Generation\n# 1s will represent wall 0s will represent white space\n# All positions are measured from the top lef...
[ [ "matplotlib.pyplot.imshow", "matplotlib.pyplot.yticks", "numpy.ones", "matplotlib.pyplot.xticks", "matplotlib.pyplot.show", "numpy.zeros", "matplotlib.pyplot.figure" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
semitable/torchbeast
[ "ea5a01b7f1268dd883861489074d6f35ce1ce5aa" ]
[ "torchbeast/monobeast.py" ]
[ "# Copyright (c) Facebook, Inc. and its affiliates.\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 app...
[ [ "torch.mean", "torch.nn.functional.softmax", "torch.optim.lr_scheduler.LambdaLR", "torch.load", "torch.cat", "torch.zeros", "torch.sum", "torch.no_grad", "torch.cuda.is_available", "torch.flatten", "torch.device", "torch.empty", "torch.nn.Conv2d", "torch.nn....
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
jasonshere/RecBole
[ "cc492fd8389af7a1a12ae69888ecf602d5299877" ]
[ "recbole/data/dataset/dataset.py" ]
[ "# @Time : 2020/6/28\n# @Author : Yupeng Hou\n# @Email : houyupeng@ruc.edu.cn\n\n# UPDATE:\n# @Time : 2021/7/14 2021/7/1, 2020/11/10\n# @Author : Yupeng Hou, Xingyu Pan, Yushuo Chen\n# @Email : houyupeng@ruc.edu.cn, xy_pan@foxmail.com, chenyushuo@ruc.edu.cn\n\n\"\"\"\nrecbole.data.dataset\n###################...
[ [ "numpy.split", "pandas.merge", "pandas.Series", "torch.nn.utils.rnn.pad_sequence", "numpy.cumsum", "numpy.concatenate", "numpy.max", "torch.FloatTensor", "pandas.read_csv", "numpy.unique", "numpy.arange", "numpy.intersect1d", "torch.arange", "numpy.zeros", ...
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.3", "1.1", "1.5", "1.2" ], "scipy": [], "tensorflow": [] } ]
gemenerik/FlowNetPytorch
[ "4101a9e20296754190a521930fd7d8ae1ef0310a" ]
[ "datasets/listdataset.py" ]
[ "import torch.utils.data as data\nimport os\nimport os.path\nfrom imageio import imread\nimport numpy as np\n\n\ndef load_flo(path):\n with open(path, 'rb') as f:\n magic = np.fromfile(f, np.float32, count=1)\n assert(202021.25 == magic),'Magic number incorrect. Invalid .flo file'\n h = np.f...
[ [ "numpy.fromfile", "numpy.resize" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
ruyueshuo/MaskTrackRCNN
[ "3c6ada36be3c2b2df32176349ec5c0ee5b24e724" ]
[ "mmdet/models/detectors/two_stage_flow_test.py" ]
[ "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n# @Time : 2020/1/10 下午2:19\n# @Author : FengDa\n# @File : two_stage_flow_test.py\n# @Software: PyCharm\nimport torch\nimport torch.nn as nn\nimport numpy as np\nimport mmcv\nimport torchvision.models as models\nimport torch.nn.functional as F\n\nfrom .base imp...
[ [ "numpy.maximum", "torch.max", "torch.nn.functional.log_softmax", "torch.cat", "torch.autograd.set_detect_anomaly", "torch.cuda.empty_cache", "numpy.stack", "numpy.ones", "torch.tensor", "torch.nn.functional.interpolate", "numpy.array" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
krematas/scannerapps
[ "03a312a7202f4998c9d217ab0d89e12e97018afe" ]
[ "soccer/instance_segmentation/instance_segmentation.py" ]
[ "import scannerpy\nimport cv2\nimport numpy as np\nfrom scannerpy import Database, DeviceType, Job, ColumnType, FrameType\nfrom scannerpy.stdlib import pipelines\nimport time\n\nfrom os.path import join, basename\nimport glob\nimport os\nimport subprocess as sp\n\nimport argparse\nimport soccer.instance_segmentatio...
[ [ "numpy.fromstring" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
Suchitra-Majumdar/olympic-hero
[ "ea5b56523a86afad72780da79f62dc2a0b607d09" ]
[ "code.py" ]
[ "# --------------\n#Importing header files\r\nimport pandas as pd\r\nimport numpy as np\r\nimport matplotlib.pyplot as plt\r\n\r\n#Path of the file\r\npath\r\ndata=pd.read_csv(path)\r\n#Code starts here\r\ndata.rename(columns={'Total':'Total_Medals'},inplace=True)\r\ndata.head(10)\r\n\n\n\n# --------------\n#Code s...
[ [ "pandas.read_csv", "matplotlib.pyplot.subplots", "matplotlib.pyplot.xlabel", "matplotlib.pyplot.xticks", "numpy.where", "matplotlib.pyplot.ylabel" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.1", "1.5", "1.2", "1.3" ], "scipy": [], "tensorflow": [] } ]
BruceK4t1qbit/stable-baselines
[ "d997d659de54bd14129d0af8df07e7c875cba7e5", "a6a8052e105369656d34fffc4f7ca4475dcc38df", "a6a8052e105369656d34fffc4f7ca4475dcc38df" ]
[ "stable_baselines/common/input.py", "stable_baselines/acktr/value_functions.py", "stable_baselines/acktr/run_mujoco.py" ]
[ "import numpy as np\nimport tensorflow as tf\nfrom gym.spaces import Discrete, Box, MultiBinary, MultiDiscrete\n\n\ndef observation_input(ob_space, batch_size=None, name='Ob', scale=False):\n \"\"\"\n Build observation input with encoding depending on the observation space type\n\n When using Box ob_space,...
[ [ "tensorflow.placeholder", "tensorflow.one_hot", "numpy.any", "tensorflow.to_float", "numpy.isinf" ], [ "tensorflow.shape", "tensorflow.get_collection", "numpy.arange", "tensorflow.placeholder", "numpy.ones", "numpy.concatenate", "tensorflow.stop_gradient", "...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10", "1.12", "1.4", "1.13", "1.5", "1.7", "0.12", "1.0", "1.2" ] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensor...
ekoops/SSD
[ "ab2b27054c3b97414b9b620d923c6a8675fd4db0" ]
[ "train.py" ]
[ "import argparse\nimport logging\nimport os\n\nimport torch\nimport torch.distributed as dist\n\nfrom ssd.data.loaders import AdainLoader\n\nfrom ssd.engine.inference import do_evaluation\nfrom ssd.config import cfg\nfrom ssd.data.build import make_data_loader\nfrom ssd.engine.trainer import do_train\nfrom ssd.mode...
[ [ "torch.distributed.init_process_group", "torch.cuda.set_device", "torch.cuda.empty_cache", "torch.cuda.is_available", "torch.device", "torch.nn.parallel.DistributedDataParallel" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
ja5per/MuddyMorph
[ "869ff199d9e0ce30e99d9b2289cf7c45fed7d8b8", "869ff199d9e0ce30e99d9b2289cf7c45fed7d8b8" ]
[ "sandbox/nodeclick.py", "muddymorph_mirage.py" ]
[ "#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\n\"\"\"\nManually assign motion paths for two key frames by clicking on an overlay.\n\nThe coordinates will be saved to a headerless CSV file\nwith columns [x_src, y_src, x_dst, y_dst],\nthus enabling morph and warp experiments elsewhere.\n\"\"\"\n\n\n############\n#...
[ [ "matplotlib.pyplot.ginput", "matplotlib.pyplot.imshow", "matplotlib.pyplot.close", "matplotlib.pyplot.axis" ], [ "numpy.ones", "numpy.ceil", "numpy.append", "numpy.floor", "numpy.column_stack", "numpy.zeros" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
laute/zipline
[ "d41aff9a9934d8df68de68cb0a2bdb848d0bab59" ]
[ "zipline/finance/trading.py" ]
[ "#\n# Copyright 2013 Quantopian, Inc.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable law or...
[ [ "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": [] } ]
EchizenG/MAD-GAN_synthetic
[ "01abe0dc1a501e8a3392b63c3566b0776dbdfc24" ]
[ "utils.py" ]
[ "import tensorflow as tf\nimport numpy as np\n\n\ndef get_trainable_params(scope_name):\n return tf.get_collection(tf.GraphKeys.GLOBAL_VARIABLES, scope=scope_name)\n\n\ndef ops_copy_vars(src_scope, dst_scope, exclude_keys=['RMSProp']):\n src_vars = tf.get_collection(tf.GraphKeys.GLOBAL_VARIABLES, scope=src_sc...
[ [ "tensorflow.nn.bias_add", "tensorflow.matmul", "numpy.sqrt", "tensorflow.summary.histogram", "tensorflow.shape", "tensorflow.get_collection", "tensorflow.random_normal_initializer", "tensorflow.minimum", "tensorflow.nn.conv2d_transpose", "tensorflow.constant_initializer", ...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10" ] } ]
timediv/tensorflow
[ "dd1088d0821ccacecc073111c7e818f5e973c4af" ]
[ "tensorflow/contrib/linear_optimizer/python/sdca_estimator_test.py" ]
[ "# Copyright 2017 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...
[ [ "numpy.dot", "tensorflow.contrib.linear_optimizer.python.sdca_estimator.SDCALogisticClassifier", "tensorflow.contrib.layers.python.layers.feature_column.crossed_column", "tensorflow.contrib.layers.python.layers.feature_column.sparse_column_with_hash_bucket", "tensorflow.contrib.layers.python.l...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10", "2.7", "1.12", "2.6", "2.2", "1.13", "2.3", "2.4", "1.4", "2.9", "1.5", "1.7", "2.5", "0.12", "1.0", "2.8", "1...
nprutan/Hubmetrix-backend
[ "e91c126fe7da851ae70aa113684df210a35fd910" ]
[ "metrics_computation.py" ]
[ "import pandas as pd\nimport pendulum\nimport math\n\n\ndef _extract_dates(itrable, date_column):\n return [item[date_column] for item in itrable]\n\n\ndef _get_date_index(itrable):\n return pd.to_datetime(itrable)\n\n\ndef filter_order_status(status):\n def filter_deco(func):\n def wrapper(itrable)...
[ [ "pandas.to_datetime", "pandas.to_numeric", "pandas.DataFrame" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "0.23", "0.21", "2.0", "1.4", "1.3", "0.19", "1.1", "1.5", "0.24", "0.20", "1.0", "0.25", "1.2" ], "scipy": [], "tensorflow": [] } ]
sirusb/DL_genomics_example
[ "a232306360ba996c4e6a003ee5bb0e4b839669c8" ]
[ "data_loader/conv_atac_data_loader.py" ]
[ "import pandas as pd\nimport numpy as np\nfrom pathlib import Path\nfrom utils.sequences import encodeDNA\nfrom rich.console import Console\nfrom tqdm import tqdm\n\nfrom base.base_data_loader import BaseDataLoader\n\n\nclass ConvATACseqDataLoader(BaseDataLoader):\n def __init__(self, config):\n super(Con...
[ [ "numpy.asanyarray", "pandas.read_csv" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.1", "1.5", "1.2", "1.3" ], "scipy": [], "tensorflow": [] } ]
urastogi885/cmac-neural-network
[ "00d15f33127e50dcc28a60f5883dca1d965f5776" ]
[ "headers/cmac.py" ]
[ "import math\nimport time\nimport numpy as np\nimport matplotlib.pyplot as plt\nimport headers.constants as constants\n\n\nclass CMAC:\n\n def __init__(self, generalization_factor, data_set, cmac_type='CONTINUOUS', local_convergence_threshold=0.01,\n learning_rate=0.15, global_convergence_thresho...
[ [ "matplotlib.pyplot.legend", "matplotlib.pyplot.figure", "matplotlib.pyplot.ylim", "matplotlib.pyplot.plot", "matplotlib.pyplot.subplot", "matplotlib.pyplot.xlabel", "numpy.array", "matplotlib.pyplot.show", "numpy.zeros", "matplotlib.pyplot.ylabel" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
Kardyne/libensemble
[ "566c8f5daafe2ad4deebc13198a1e131e4ce6542" ]
[ "examples/calling_scripts/test_6-hump_camel_persistent_uniform_sampling.py" ]
[ "# \"\"\"\n# Runs libEnsemble on the 6-hump camel problem. Documented here:\n# https://www.sfu.ca/~ssurjano/camel6.html\n#\n# Execute via the following command:\n# mpiexec -np 4 python3 {FILENAME}.py\n# The number of concurrent evaluations of the objective function will be 4-1=3.\n# \"\"\"\n\nfrom __future__ ...
[ [ "numpy.random.RandomState", "numpy.array", "numpy.random.seed" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
zhangxz1123/interpret
[ "6e528872d1e6d5664ee0fa8070b5ff87e2ec2fa8" ]
[ "src/python/interpret/visual/plot.py" ]
[ "# Copyright (c) 2019 Microsoft Corporation\n# Distributed under the MIT software license\n\n# NOTE: This module is going to through some major refactoring shortly. Do not use directly.\n\nimport plotly.graph_objs as go\nimport numpy as np\nfrom plotly import tools\nfrom numbers import Number\n\nCOLORS = [\"#1f77b4...
[ [ "numpy.argsort", "numpy.mean", "numpy.abs" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
Jadenyifanhe/Automated-DJ
[ "a066ca4c98a8dd61433cf31967e7c40a86b4695d" ]
[ "src/autodj/annotation/downbeat/features/mfcc.py" ]
[ "import numpy as np\nfrom essentia import *\nfrom essentia.standard import Windowing, MelBands, Spectrum\nfrom sklearn import preprocessing\n\nNUMBER_BANDS = 12\nNUMBER_COEFF = 5\n\n\ndef feature_allframes(input_features, frame_indexer=None):\n audio = input_features['audio']\n beats = input_features['beats']...
[ [ "sklearn.preprocessing.scale" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
axiom-data-science/pocean-core
[ "11ad6b8fc43a4c29fa8aa404bf52cb7d39a9c8b1" ]
[ "pocean/tests/dsg/trajectoryProfile/test_trajectoryProfile_cr.py" ]
[ "import os\nimport math\nimport tempfile\nimport unittest\n\nimport numpy as np\nfrom shapely.wkt import loads as wktloads\nfrom dateutil.parser import parse as dtparse\n\nfrom pocean.tests.dsg.test_new import test_is_mine\nfrom pocean.dsg import ContiguousRaggedTrajectoryProfile\n\nimport logging\nfrom pocean impo...
[ [ "numpy.isclose" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
kyeling/pvlib-python
[ "e3a3be970c44d227b6e49ea536e76be75689c7ab" ]
[ "pvlib/tests/test_inverter.py" ]
[ "# -*- coding: utf-8 -*-\n\nimport numpy as np\nimport pandas as pd\n\nfrom pandas.testing import assert_series_equal\nfrom numpy.testing import assert_allclose\n\nfrom pvlib import inverter\nfrom conftest import needs_numpy_1_10\n\n\ndef test_adr(adr_inverter_parameters):\n vdcs = pd.Series([135, 154, 390, 420,...
[ [ "pandas.testing.assert_series_equal", "pandas.Series", "numpy.linspace", "numpy.testing.assert_allclose", "numpy.array" ] ]
[ { "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": [] } ]
ssaturnn/computer_graphics
[ "b00c877dd53ed27178369337cdd2f9a32960f114" ]
[ "Lab_03/main.py" ]
[ "import copy\nimport math\nimport sys\nfrom math import fabs, floor\nfrom tkinter import Tk, Button, Label, Entry, Canvas, messagebox, Menu, Frame, SUNKEN, colorchooser\nfrom tkinter import ttk\nimport matplotlib.pyplot as plt\nimport numpy as np\nfrom colorutils import Color\n\nWIDTH = 1200\nHEIGHT = 600\nRADIUS =...
[ [ "matplotlib.pyplot.title", "matplotlib.pyplot.subplots", "matplotlib.pyplot.subplot", "matplotlib.pyplot.bar", "matplotlib.pyplot.show" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
constatza/fempy
[ "8c1435da0c570decd80591287ec093d9fcc54c1f" ]
[ "tests/test.py" ]
[ "# -*- coding: utf-8 -*-\n\"\"\"\nSpyder Editor\n\nThis is a temporary script file.\n\"\"\"\n\nimport matplotlib.pyplot as plt\nimport numpy as np\nimport mathematics.manilearn as ml\nimport scipy as sp\nplt.close('all')\n\nt = np.random.randn(2100)*np.pi/3 + np.pi/2\n\n\nr = sp.random.randn(2, 500)\n \ntheta = ...
[ [ "matplotlib.pyplot.scatter", "matplotlib.pyplot.subplots", "numpy.cos", "numpy.sin", "numpy.random.randn", "scipy.random.randn", "matplotlib.pyplot.close", "numpy.savetxt", "numpy.array", "matplotlib.pyplot.show" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
rodrigodesalvobraz/beanmachine-1
[ "1c0d5ffeb505167f581e518809ea1320861bdf18", "1c0d5ffeb505167f581e518809ea1320861bdf18", "1c0d5ffeb505167f581e518809ea1320861bdf18" ]
[ "src/beanmachine/ppl/inference/tests/sampler_test.py", "src/beanmachine/ppl/compiler/runtime.py", "src/beanmachine/ppl/compiler/hint.py" ]
[ "# Copyright (c) Meta Platforms, Inc. and affiliates.\n#\n# This source code is licensed under the MIT license found in the\n# LICENSE file in the root directory of this source tree.\n\nimport beanmachine.ppl as bm\nimport torch\nimport torch.distributions as dist\n\n\nclass SampleModel:\n @bm.random_variable\n ...
[ [ "torch.tensor", "torch.distributions.Normal" ], [ "torch.sigmoid", "torch.mm", "torch.expm1", "torch.tensor", "torch.exp", "torch.log", "torch.logsumexp" ], [ "torch.exp" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
iemdpk/models
[ "870d21ba872474a468e5628dc542424ee9202c2d" ]
[ "official/vision/beta/projects/volumetric_models/evaluation/segmentation_metrics.py" ]
[ "# Copyright 2021 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.stack", "tensorflow.math.divide_no_nan", "tensorflow.Variable" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10", "2.7", "2.6", "1.4", "2.2", "2.3", "2.4", "2.9", "1.5", "1.7", "2.5", "0.12", "1.0", "2.8", "1.2", "2.10" ] } ...
heitorbaldo/pyqpath
[ "f07b9ac20318356b19399fba181143c910707bb0" ]
[ "pyqpath/plot_digraph.py" ]
[ "'''\nThis code plots the connectivity digraph such that the nodes positions are \nin 10-20 system style configuration.\n'''\n\nimport numpy as np\nimport networkx as nx\nimport matplotlib.pyplot as plt\n\n#fixed positions :\npos = {0: (0,15), 1: (2,16), 2: (4,16), 3: (6, 15), \n 4: (-2,13), 5: (0,12), 6: (2...
[ [ "numpy.flipud", "matplotlib.pyplot.show", "numpy.zeros", "matplotlib.pyplot.figure" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
messiasoliveira/bkpextension_datalad
[ "d78bde8e2532d8299889bdb71cb50fbd19debb58" ]
[ "datalad_lgpdextension/tests/runner/actions.py" ]
[ "import unittest\nimport pandas as pd\nfrom datalad_lgpdextension.runner.actions import Actions\nfrom datalad_lgpdextension.utils.folder import Folder\nfrom datalad_lgpdextension.utils.dataframe import Dataframe\nclass TestActions(unittest.TestCase):\n def __init__(self,*args,**kwargs):\n unittest.TestCas...
[ [ "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": [] } ]
kevindavenport/statsmodels
[ "c8e980da57cb9d5be64872ad5e13893e6ae7cd0d" ]
[ "statsmodels/tsa/vector_ar/tests/test_var.py" ]
[ "\"\"\"\nTest VAR Model\n\"\"\"\nfrom __future__ import print_function\n# pylint: disable=W0612,W0231\nfrom statsmodels.compat.python import iteritems, StringIO, lrange, BytesIO, range\nfrom nose.tools import assert_raises\nimport nose\nimport os\nimport sys\n\nimport numpy as np\n\nimport statsmodels.api as sm\nim...
[ [ "numpy.testing.assert_equal", "numpy.log", "numpy.savez", "numpy.round", "numpy.testing.assert_almost_equal", "numpy.append", "pandas.rpy.common.convert_robj", "matplotlib.pyplot.close", "numpy.array" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "0.19" ], "scipy": [], "tensorflow": [] } ]
LuciusMos/DI-engine
[ "b040b1c36afce038effec9eb483f625131573824" ]
[ "ding/entry/main.py" ]
[ "\"\"\"\nMain entry\n\"\"\"\nfrom collections import deque\nimport torch\nimport numpy as np\nimport time\nfrom rich import print\nfrom functools import partial\nfrom ding.model import QAC\nfrom ding.utils import set_pkg_seed\nfrom ding.envs import BaseEnvManager, get_vec_env_setting\nfrom ding.config import compil...
[ [ "numpy.mean" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
R2D2oid/Multimodal-Action-Recognition
[ "9a7cb2abccb44a52c334ef00ad97163a95627757" ]
[ "layers/AEwithAttention.py" ]
[ "import torch\nimport torch.nn as nn\nfrom layers.AttentionLayer import AttentionLayer\n# AutoEncoder model with attention \n\nclass AEwithAttention(nn.Module):\n def __init__(self, n_feat, T, n_filt):\n super(AEwithAttention, self).__init__()\n \n z_dim = n_feat*n_filt\n \n se...
[ [ "torch.nn.Linear", "torch.nn.ReLU" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
Bazina/Bikeshare-Data-Analysis
[ "ec491e261dd5e9de5efa58ffab8403470e60a1dd" ]
[ "bikeshare.py" ]
[ "\"\"\"\nPython 3.9\nPandas 1.3.2\nStatistics is a built in library and its link\nhttps://docs.python.org/3/library/statistics.html\n\"\"\"\n\nimport time\nimport pandas as pd\nfrom tabulate import tabulate\n\nCITY_DATA = {'chicago': 'data/chicago.csv',\n 'new york': 'data/new_york_city.csv',\n ...
[ [ "pandas.read_csv", "pandas.to_datetime" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.3", "1.1", "1.5", "1.2" ], "scipy": [], "tensorflow": [] } ]
kuchynkm/game_of_life
[ "923a8252b105587ce851f3f06607ceb24c1d3259" ]
[ "game_of_life/processing.py" ]
[ "from queue import Queue\nimport threading\nimport time\nfrom typing import Any, Optional\nfrom PIL import ImageTk, Image, ImageColor\nfrom scipy.signal import convolve2d\nimport numpy as np\n\nfrom game_of_life import config, logger \n\n\nclass Message:\n \"\"\"Message objects to be send to Processor thread via...
[ [ "numpy.array", "numpy.zeros", "scipy.signal.convolve2d", "numpy.random.randint" ] ]
[ { "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"...
zmic/cocoapi
[ "f36160c6a24fe98b235e3f9e73ec7664bac4fda0" ]
[ "PythonAPI/setup.py" ]
[ "from setuptools import setup, Extension\nimport numpy as np\nimport shutil\nimport distutils.ccompiler\n\n# To compile and install locally run \"python setup.py build_ext --inplace\"\n# To install library to Python site-packages run \"python setup.py build_ext install\"\n\n\n#\n# If running on Windows, compiler_na...
[ [ "numpy.get_include" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
christian-oreilly/eegip
[ "521a408b65ec99b11ca7903f67288807704015e4" ]
[ "eegip/clustering.py" ]
[ "import numpy as np\nimport pandas as pd\nimport pickle\nimport scipy\nfrom scipy.cluster import hierarchy\nfrom scipy.spatial import distance\nfrom scipy.cluster.hierarchy import _LINKAGE_METHODS\nfrom multiprocessing import Pool\nfrom itertools import product, combinations\nfrom functools import partial\nfrom war...
[ [ "numpy.diag", "numpy.sqrt", "sklearn.metrics.silhouette_score", "numpy.in1d", "pandas.DataFrame", "numpy.concatenate", "numpy.max", "numpy.zeros_like", "numpy.any", "numpy.mean", "numpy.ma.is_masked", "numpy.where", "numpy.ones_like", "numpy.unique", "nu...
[ { "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": [ "0.13", "1.6", "0.14", "1.10", "0...
sgttwld/CNNs-with-tensorflow
[ "42020d0cd816050f5ff293d4039139914bd20329" ]
[ "3_CNN_midlevel.py" ]
[ "\"\"\"\nA mid-level implementation of a convolutional neural network \nfor MNIST classification using tensorflow.keras.layers\nAuthor: Sebastian Gottwald\nProject: https://github.com/sgttwld/classification\nDate: 2019-05-25\n\"\"\"\n\nimport numpy as np\nimport tensorflow as tf\nimport math, os, sys, time\nos.envi...
[ [ "tensorflow.keras.layers.Dense", "tensorflow.keras.layers.Conv2D", "tensorflow.placeholder", "tensorflow.keras.datasets.mnist.load_data", "tensorflow.global_variables_initializer", "tensorflow.contrib.optimizer_v2.AdamOptimizer", "tensorflow.one_hot", "tensorflow.Session", "ten...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10" ] } ]
malie/theano-rbm-on-word-tuples
[ "0ea673e3e99d64e93820617ca22eb3eb6183533b" ]
[ "read.py" ]
[ "import re\nfrom sklearn.feature_extraction.text import CountVectorizer\n\ndef find_common_words(all_words, num_most_frequent_words):\n vectorizer = CountVectorizer(\n stop_words=None, # 'english',\n max_features=num_most_frequent_words,\n binary=True)\n vectorizer.fit(all_words)\n ret...
[ [ "sklearn.feature_extraction.text.CountVectorizer" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
mikeljordan/pymor
[ "415b7aeab905c35ef76d7ba9b69af5d0b3af1939" ]
[ "src/pymor/bindings/pymess.py" ]
[ "# This file is part of the pyMOR project (https://www.pymor.org).\n# Copyright 2013-2021 pyMOR developers and contributors. All rights reserved.\n# License: BSD 2-Clause License (https://opensource.org/licenses/BSD-2-Clause)\n\nfrom pymor.core.config import config\n\n\nif config.HAVE_PYMESS:\n import numpy as n...
[ [ "numpy.asarray", "numpy.eye", "scipy.linalg.cholesky", "scipy.linalg.solve" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [ "0.13", "0.12", "0.14", "0.15" ], "tensorflow": [] } ]
ishine/TensorflowASR-1
[ "c0bcaec124dd96138ac401dfbde0b8c795737bb1" ]
[ "AMmodel/__init__.py" ]
[ "# Copyright 2020 Huy Le Nguyen (@usimarit)\r\n#\r\n# Licensed under the Apache License, Version 2.0 (the \"License\");\r\n# you may not use this file except in compliance with the License.\r\n# You may obtain a copy of the License at\r\n#\r\n# http://www.apache.org/licenses/LICENSE-2.0\r\n#\r\n# Unless require...
[ [ "tensorflow.keras.models.load_model" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10", "2.7", "2.2", "2.3", "2.4", "2.5", "2.6" ] } ]
jajajaqlt/nsg
[ "f2c4b8e60a97c58a6a1c549cc8b4753ebfe8a5e3" ]
[ "data_extraction/scripts/extract_transformer_data_raw.py" ]
[ "# Copyright 2017 Rice 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.0\n#\n# Unless required by applicable law or agre...
[ [ "numpy.array" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
avcopan/automechanic-history-save
[ "3140694950150d49c06545905413d9eeb163ff2d" ]
[ "automechanic_old/table.py" ]
[ "\"\"\" functions for working with pandas DataFrames\n\"\"\"\nfrom itertools import chain\nfrom collections import OrderedDict\nfrom more_itertools import unique_everseen\nimport pandas\n\n\ndef is_empty_value(val):\n \"\"\" check if a table value is missing, by value\n \"\"\"\n return pandas.isna(val)\n\n...
[ [ "pandas.isna", "pandas.DataFrame.sort_values", "pandas.DataFrame", "pandas.DataFrame.from_dict" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "0.23", "0.21", "2.0", "1.4", "1.3", "1.1", "1.5", "0.24", "1.0", "0.25", "1.2" ], "scipy": [], "tensorflow": [] } ]
1seokyoo/pcgr
[ "37e72b912160285c8040a1022cb11461ff1c9c80" ]
[ "src/pcgr/vcf2tsv.py" ]
[ "#!/usr/bin/env python\n\nimport argparse\nfrom cyvcf2 import VCF, Writer\nimport numpy as np\nimport re\nimport math\nimport subprocess\n\nversion = '0.3.5'\n\n\ndef __main__():\n parser = argparse.ArgumentParser(description='Convert a VCF file with genomic variants to a file with tab-separated values (TSV). One...
[ [ "numpy.ndarray.tolist" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
songanz/highway-env
[ "ac21d1da25e224dbdbf8ba39509f4013bd029f52" ]
[ "highway_env/vehicle/dynamics.py" ]
[ "from __future__ import division, print_function\nimport numpy as np\nimport pandas as pd\n\nfrom highway_env import utils\nfrom highway_env.logger import Loggable\n\n\nclass Vehicle(Loggable):\n \"\"\"\n A moving vehicle on a road, and its dynamics.\n\n The vehicle is represented by a dynamical sy...
[ [ "numpy.random.choice", "numpy.min", "numpy.linalg.norm", "pandas.DataFrame", "numpy.cos", "numpy.sin", "numpy.max", "numpy.tan", "numpy.array" ] ]
[ { "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": [] } ]
Bobo529019686/matplotlib-label-lines
[ "9cf37e99a8581f0477f6495433f09d284cc452e0" ]
[ "labellines/utils.py" ]
[ "from datetime import datetime\n\nimport numpy as np\nfrom matplotlib.dates import date2num\n\n\ndef ensure_float(value):\n \"\"\"Make sure datetime values are properly converted to floats.\"\"\"\n try:\n # the last 3 boolean checks are for arrays with datetime64 and with\n # a timezone, see the...
[ [ "numpy.asarray", "numpy.issubdtype", "matplotlib.dates.date2num" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
StanfordVL/lagom
[ "e5994df7f866e35cb30140bae0d997e3f63ea876", "e5994df7f866e35cb30140bae0d997e3f63ea876" ]
[ "lagom/networks/init.py", "baselines/cmaes/logs/default/source_files/agent.py" ]
[ "import torch.nn as nn\nimport torch.nn.modules.rnn as rnn # TODO: use nn.RNNCellBase for PyTorch 1.0\n\n\ndef ortho_init(module, nonlinearity=None, weight_scale=1.0, constant_bias=0.0):\n r\"\"\"Applies orthogonal initialization for the parameters of a given module.\n \n Args:\n module (nn.Module)...
[ [ "torch.nn.init.constant_", "torch.nn.init.calculate_gain", "torch.nn.init.orthogonal_" ], [ "numpy.asarray", "torch.is_tensor", "torch.nn.LayerNorm" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
bhadhy/TileDB-CF-Py
[ "7da95d5f56de9153b8518d068148ba61ec72cc64" ]
[ "tests/engines/netcdf4_engine/test_netcdf_coord_to_dim_converter.py" ]
[ "# Copyright 2021 TileDB Inc.\n# Licensed under the MIT License\nimport numpy as np\nimport pytest\n\nfrom tiledb.cf.creator import DataspaceRegistry\nfrom tiledb.cf.engines.netcdf4_engine import NetCDF4CoordToDimConverter\n\nnetCDF4 = pytest.importorskip(\"netCDF4\")\n\n\ndef test_coord_converter_simple():\n wi...
[ [ "numpy.dtype" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
bharatmonga/Supervised-learning-algorithms
[ "de2ecf6bd608870a3ef2a799763ef33815a33c04" ]
[ "Algorithm1/validation.py" ]
[ "import numpy as np\r\nimport pickle\r\nfrom duffing import Duffing\r\nimport matplotlib.pyplot as plt\r\n\r\n\"\"\" Initialize duffing object by loading parameters from the training data file \"\"\"\r\nf = open(\"learning_algorithm1_training_data\", \"rb\")\r\nd=pickle.load(f)\r\ndelta = d['delta']\r\ndf = Duf...
[ [ "matplotlib.pyplot.legend", "matplotlib.pyplot.savefig", "matplotlib.pyplot.plot", "matplotlib.pyplot.show", "numpy.zeros", "matplotlib.pyplot.figure" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
edwardfang/Genetic_Algorithm_Learning
[ "64ab8e73051d2c1565c6b5900b4e89851571ba6b" ]
[ "Intro_to_GA_practice/ex1_mu-1.py" ]
[ "# pylint: disable=no-member\nimport numpy as np\nimport functools\n\ndef evaluate(individual):\n return np.sum(individual)\n\n\ndef bitflip_mutation(bit, probability):\n if np.random.rand() < probability:\n if bit == 1:\n return 0.\n else:\n return 1.\n else:\n r...
[ [ "numpy.arange", "numpy.random.shuffle", "numpy.random.rand", "numpy.array", "numpy.sum", "numpy.empty", "numpy.random.randint" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
bopopescu/wired_cli
[ "844b5c2bf32c95ad2974663f0501a85ff6134bd4" ]
[ "venv/lib/python3.6/site-packages/gensim/models/wrappers/dtmmodel.py" ]
[ "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n#\n# Copyright (C) 2014 Artyom Topchyan <artyom.topchyan@live.com>\n# Licensed under the GNU LGPL v2.1 - http://www.gnu.org/licenses/lgpl.html\n# Based on Copyright (C) 2014 Radim Rehurek <radimrehurek@seznam.cz>\n\n\n\"\"\"Python wrapper for `Dynamic Topic Models (D...
[ [ "numpy.exp" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
geolovic/topopy
[ "0ccfc4bfc0364b99489d08a1d4b87582deb08b81" ]
[ "test/temp/temp_testing_channel.py" ]
[ "# -*- coding: utf-8 -*-\n\"\"\"\nEditor de Spyder\n\nEste es un archivo temporal\n\"\"\"\n\nfrom topopy import Network, Channel, Flow, BNetwork\nfrom osgeo import ogr\nimport numpy as np\n\n#def rivers_to_channels(path, net, idfield=\"\"):\n \npath = \"../data/in/jebja_channels.shp\"\nidfield=\"\"\nnet = Networ...
[ [ "matplotlib.pyplot.figure" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
OJ423/terminusdb-tutorials
[ "f314c773e5c8298c6b84af18968713ec338c8203" ]
[ "nobel_prize/nobel_prize.py" ]
[ "import singer\nimport pandas as pd\nfrom tqdm import tqdm\nimport tempfile\n\nschema = {\n 'properties': {\n 'firstname': {'type': 'string'},\n 'surname': {'type': 'string'},\n 'born': {'type': 'string'},\n 'died': {'type': 'string'},\n 'bornCountry': {'type': 'string'},\n ...
[ [ "pandas.read_csv" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.1", "1.5", "1.2", "1.3" ], "scipy": [], "tensorflow": [] } ]
EdVard-duff/DIP-Class
[ "b6e33c68edf54840db9c4e6f0904a4b10b1840c4" ]
[ "I2G/cal_landmark.py" ]
[ "import cv2\nimport dlib\nimport numpy as np\nfrom collections import OrderedDict\n\n'''\n提取convex\n'''\nFACIAL_LANDMARKS_68_IDXS = OrderedDict([\n ('mouth', (48, 68)),\n ('right_eyebrow', (17, 22)),\n ('left_eyebrow', (22, 27)),\n ('right_eye', (36, 42)),\n ('left_eye', (42, 48)),\n ('nose', (27,...
[ [ "numpy.zeros", "numpy.save" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
disruptiveplanets/tierra
[ "aa56550e30fe12af56cb60e46f54add14265c17f" ]
[ "tierra/PrecomputedScatter.py" ]
[ "import numpy as np\nimport os\nfrom bisect import bisect\n\ndef BinningDataNIRSpecPrism(WavelengthHS=None, ValuesHS=None):\n input(\"Wait here...\")\n Parameters = \"WavLow,WavUpp,WavC,BinnedNoise,Npix\"\n print(os.path.getcwd())\n input(\"Wait here please...\")\n Data = np.genfromtxt(\"./NIRSpecPri...
[ [ "numpy.zeros", "numpy.mean", "numpy.diff", "numpy.genfromtxt" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
Taek111/FlapPyBird-MPC
[ "3d5de55a0c1184f4dee1722f81ebbddb7eca2ee6" ]
[ "mip.py" ]
[ "import cvxpy as cvx\nimport numpy as np\nimport matplotlib.pyplot as plt\nimport copy \n\n\nN = 24 # time steps to look ahead\n# N = 40 # time steps to look ahead\npath = cvx.Variable((N, 2)) # initialize the y pos and y velocity\nflap = cvx.Variable(N-1, boolean=True) # initialize the inputs, whether or not the b...
[ [ "numpy.round", "numpy.sqrt" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
BoKleynen/P-O-3-Smart-Energy-Home
[ "4849038c47199aa0a752ff5a4f2afa91f4a9e8f0" ]
[ "src/simulation_scenarios/solar_panel_s_production_day_summer.py" ]
[ "from power_generators import SolarPanel\nimport pandas as pd\nimport datetime\nimport numpy as np\nimport matplotlib.pyplot as plt\nimport matplotlib.dates as mdates\nimport matplotlib.cbook as cbook\nfrom house import House\n\nirradiance_df = pd.read_csv(filepath_or_buffer=\"../../data/Irradiance.csv\",\n ...
[ [ "pandas.read_csv", "pandas.DateOffset", "pandas.Timestamp", "matplotlib.pyplot.gcf", "matplotlib.pyplot.show", "matplotlib.pyplot.ylabel" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
classifier-calibration/PyCalib
[ "181d87db5101e66519952e43eecf32c5edd51448" ]
[ "pycalib/tests/models/test_init.py" ]
[ "import unittest\nimport numpy as np\nfrom sklearn.linear_model import LogisticRegression\nfrom sklearn.datasets import make_blobs\nfrom pycalib.models import (IsotonicCalibration, LogisticCalibration,\n BinningCalibration, SigmoidCalibration,\n CalibratedModel)...
[ [ "sklearn.linear_model.LogisticRegression", "numpy.testing.assert_array_equal", "numpy.mean", "numpy.array", "sklearn.datasets.make_blobs" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
clark3493/finite_elements
[ "afdf465134b33a4090e4df9e5173f3c5b4cb31ac" ]
[ "test/element/test_D1.py" ]
[ "import sys\nsys.path.insert(0, r\"..\\..\\src\")\n\nimport numpy as np\nimport unittest\n\nfrom element import Node\nfrom element.D1 import Rod\n\n\nclass OneDimensionalElementTestCase(unittest.TestCase):\n\n def setup_rod1(self):\n node1 = Node(1, [1., 0., 0.])\n node2 = Node(2, [0., 1., 0.])\n ...
[ [ "numpy.array", "numpy.sqrt", "numpy.allclose" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
martinclehman/DS-Unit-3-Sprint-2-SQL-and-Databases
[ "8cc6213fb352195dc6d92c3296ed10687c56f353" ]
[ "module1-introduction-to-sql/rpg_queries.py" ]
[ "import sqlite3 \nimport pandas as pd\n\nconn = sqlite3.connect('rpg_db.sqlite3')\ncurs = conn.cursor()\n\ndef total_character_count():\n # How many total characters are there?\n print(pd.read_sql_query(\n '''SELECT COUNT(*) as character_count\n FROM charactercreator_character''',\n co...
[ [ "pandas.read_sql_query" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "0.23", "0.21", "2.0", "1.4", "0.19", "1.1", "1.5", "1.2", "0.24", "0.20", "1.0", "0.25", "1.3" ], "scipy": [], "tensorflow": [] } ]
kewlcoder/pytorch-cifar
[ "09da4c6b125883423d64b6c4c2d5efb0ef1b4f1e" ]
[ "models/mobilenetv2.py" ]
[ "'''MobileNetV2 in PyTorch.\n\nSee the paper \"Inverted Residuals and Linear Bottlenecks:\nMobile Networks for Classification, Detection and Segmentation\" for more details.\n'''\nimport torch\nimport torch.nn as nn\nimport torch.nn.functional as F\n\n\nclass Block(nn.Module):\n '''expand + depthwise + pointwise...
[ [ "torch.nn.Sequential", "torch.randn", "torch.nn.functional.avg_pool2d", "torch.nn.Conv2d", "torch.nn.Linear", "torch.nn.BatchNorm2d" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
yukihiko/hrm
[ "89bfb075d3c9ba91826c0c782ca6aff9507c663b" ]
[ "opendr/test_geometry.py" ]
[ "#!/usr/bin/env python\n# encoding: utf-8\n\"\"\"\nAuthor(s): Matthew Loper\n\nSee LICENCE.txt for licensing and contact information.\n\"\"\"\n\nimport sys\nimport os\nimport unittest\nimport chumpy as ch\nfrom chumpy import Ch\nimport numpy as np\nfrom util_tests import get_earthmesh\n\nclass TestGeometry(unittest...
[ [ "numpy.abs", "numpy.random.seed", "numpy.random.randn", "numpy.random.rand", "numpy.zeros" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
BenjaminIsaac0111/neworder
[ "354849b37f1594c252cfa0c79aa33f5af5bb05f7" ]
[ "examples/world/microsynth.py" ]
[ "\"\"\"\nLarge-scale version of population.py\n\"\"\"\n\nimport pandas as pd\nimport numpy as np\nimport humanleague\nimport neworder\n\nimport ethpop\nfrom helpers import *\n\nclass Microsynth:\n def __init__(self, countries):\n\n country_lookup = pd.read_csv(\"./examples/world/data/CountryLookup.csv\", sep=\"...
[ [ "pandas.read_csv", "numpy.isnan", "pandas.DataFrame", "numpy.ones", "numpy.array", "pandas.to_numeric" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.1", "1.5", "1.2", "1.3" ], "scipy": [], "tensorflow": [] } ]
StephenStorm/DETReg
[ "25ebc7792c7da4cc9c50a846149773b2684a040f", "25ebc7792c7da4cc9c50a846149773b2684a040f" ]
[ "datasets/coco.py", "models/deformable_transformer.py" ]
[ "# ------------------------------------------------------------------------\n# Deformable DETR\n# Copyright (c) 2020 SenseTime. All Rights Reserved.\n# Licensed under the Apache License, Version 2.0 [see LICENSE for details]\n# ------------------------------------------------------------------------\n# Modified fro...
[ [ "torch.stack", "torch.tensor", "torch.zeros", "torch.as_tensor" ], [ "torch.nn.Dropout", "torch.linspace", "torch.nn.MultiheadAttention", "torch.cat", "torch.Tensor", "torch.nn.init.constant_", "torch.split", "torch.topk", "torch.sum", "torch.nn.LayerNor...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]