repo_name stringlengths 6 130 | hexsha list | file_path list | code list | apis list | possible_versions list |
|---|---|---|---|---|---|
bastianbeischer/astropy | [
"6054cc78b22a6bcd4b37fdfdec02f5331b957355",
"6054cc78b22a6bcd4b37fdfdec02f5331b957355",
"6054cc78b22a6bcd4b37fdfdec02f5331b957355",
"6054cc78b22a6bcd4b37fdfdec02f5331b957355"
] | [
"astropy/io/votable/tests/converter_test.py",
"astropy/modeling/tests/test_quantities_fitting.py",
"astropy/table/table.py",
"astropy/io/misc/tests/test_hdf5.py"
] | [
"# Licensed under a 3-clause BSD style license - see LICENSE.rst\n\nimport io\n\n# THIRD-PARTY\nimport numpy as np\nfrom numpy.testing import assert_array_equal\nimport pytest\n\n# LOCAL\nfrom astropy.io.votable import converters\nfrom astropy.io.votable import exceptions\nfrom astropy.io.votable import tree\n\nfro... | [
[
"numpy.testing.assert_array_equal"
],
[
"numpy.linspace",
"numpy.arange",
"numpy.random.normal",
"numpy.random.sample",
"numpy.exp"
],
[
"pandas.Series",
"numpy.asarray",
"numpy.around",
"numpy.issubdtype",
"pandas.DataFrame",
"numpy.dtype",
"numpy.timed... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [
"0.23",
"0.21",
"2.0",
"1.4... |
tomato18/openpilot | [
"2b4b53f0405c92a789427e085c797a8719658148"
] | [
"selfdrive/controls/lib/planner.py"
] | [
"#!/usr/bin/env python3\nimport math\nimport numpy as np\nfrom common.params import Params\nfrom common.numpy_fast import interp\n\nimport cereal.messaging as messaging\nfrom cereal import car\nfrom common.realtime import sec_since_boot\nfrom selfdrive.swaglog import cloudlog\nfrom selfdrive.config import Conversio... | [
[
"numpy.arange",
"numpy.vstack"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ksangeek/cuml | [
"1f508d989c1d7974c475f115f6ea063aea8aab39",
"1f508d989c1d7974c475f115f6ea063aea8aab39"
] | [
"python/cuml/test/test_random_projection.py",
"python/cuml/test/test_lasso.py"
] | [
"# Copyright (c) 2018-2019, NVIDIA CORPORATION.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applica... | [
[
"numpy.asarray",
"numpy.all",
"scipy.spatial.distance.pdist",
"sklearn.random_projection.johnson_lindenstrauss_min_dim",
"numpy.random.rand",
"sklearn.datasets.samples_generator.make_blobs",
"numpy.random.randint"
],
[
"numpy.int32",
"pandas.DataFrame",
"sklearn.metrics... | [
{
"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"
... |
lmasieri/iot-central-docs-samples | [
"90b4d204a43c249481ddd574876e685b18b8e1e8"
] | [
"databricks/IoT Central Analysis.py"
] | [
"# Databricks notebook source\n# MAGIC %md # IoT Central streaming to Azure Databricks\n# MAGIC \n# MAGIC This python script is an example of how [IoT Central](https://azure.microsoft.com/services/iot-central/) can stream data to [Azure Databricks](https://azure.microsoft.com/services/databricks/) using Apache Spar... | [
[
"matplotlib.pyplot.clf"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
JsBlueCat/SACN | [
"19abce5ac3d8e5880c4334a2192a78b86f106701"
] | [
"train/operations.py"
] | [
"import torch\nimport torch.nn as nn\n\nOPS = {\n 'none': lambda C, stride, affine: Zero(stride),\n 'avg_pool_3x3': lambda C, stride, affine: nn.AvgPool2d(3, stride=stride, padding=1, count_include_pad=False),\n 'max_pool_3x3': lambda C, stride, affine: nn.MaxPool2d(3, stride=stride, padding=1),\n 'skip... | [
[
"torch.nn.Conv2d",
"torch.nn.MaxPool2d",
"torch.nn.AvgPool2d",
"torch.nn.BatchNorm2d",
"torch.nn.ReLU"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
vineethbabu/mmaction2 | [
"3f3ad9cae291c991b822cbc2ecfb88c1188e87c5",
"3f3ad9cae291c991b822cbc2ecfb88c1188e87c5"
] | [
"mmaction/core/evaluation/accuracy.py",
"tools/deployment/publish_model.py"
] | [
"# Copyright (c) OpenMMLab. All rights reserved.\nimport numpy as np\n\n\ndef confusion_matrix(y_pred, y_real, normalize=None):\n \"\"\"Compute confusion matrix.\n\n Args:\n y_pred (list[int] | np.ndarray[int]): Prediction labels.\n y_real (list[int] | np.ndarray[int]): Ground truth labels.\n ... | [
[
"numpy.diag",
"numpy.dot",
"numpy.expand_dims",
"numpy.minimum",
"numpy.linspace",
"numpy.squeeze",
"numpy.nan_to_num",
"numpy.cumsum",
"numpy.concatenate",
"numpy.max",
"numpy.mean",
"numpy.where",
"numpy.trapz",
"numpy.hstack",
"numpy.arange",
"num... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
noriyukipy/gptchat | [
"15febcc69cf79ffbca50bd8897447b5804bcef54"
] | [
"gptchat/callback.py"
] | [
"import tensorflow.keras as keras\n\n\nclass WarmupScheduler(keras.callbacks.Callback):\n def __init__(self, warmup_steps, learning_rate):\n super().__init__()\n\n self._warmup_steps = warmup_steps\n self._learning_rate = learning_rate\n\n # The argument passed to on_train_batch_begin... | [
[
"tensorflow.keras.backend.get_value",
"tensorflow.keras.backend.set_value"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10",
"2.7",
"2.6",
"2.4",
"2.3",
"2.5",
"2.2"
]
}
] |
GJBoth/DeePyMoD_torch | [
"b4b90080f4f9fea8fdf4426e0708e807b193242f",
"b4b90080f4f9fea8fdf4426e0708e807b193242f"
] | [
"paper/figures/3/run_deepmod.py",
"src/DeePyMoD_SBL/deepymod_torch/network.py"
] | [
"# Imports\nimport numpy as np\nimport torch\n\nfrom phimal_utilities.data import Dataset\nfrom phimal_utilities.data.burgers import BurgersDelta\nfrom DeePyMoD_SBL.deepymod_torch.library_functions import library_1D_in\nfrom DeePyMoD_SBL.deepymod_torch.DeepMod import DeepMod\n\nimport time\nfrom DeePyMoD_SBL.deepym... | [
[
"torch.set_default_tensor_type",
"torch.abs",
"numpy.random.seed",
"numpy.linspace",
"torch.manual_seed",
"numpy.arange",
"torch.sum",
"torch.tensor",
"torch.inverse",
"torch.cuda.is_available",
"torch.arange",
"numpy.meshgrid"
],
[
"torch.norm",
"torch.... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
kalingibbons/artifact | [
"fbcbd277e0d48abb3f2f55f80c81ca0b4cb7d090"
] | [
"notebooks/04-kg-hyperparameter-tuning.py"
] | [
"# %% [markdown]\n# # Comprehensive Exam\n#\n# ## Coding Artifact\n#\n# Kalin Gibbons\n#\n# Nov 20, 2020\n#\n# > Note: A hyperparameter is a numerical or other measurable factor\n# responsible for some aspect of training a machine learning model, whose value\n# cannot be estimated from the data, unlike regul... | [
[
"sklearn.tree.DecisionTreeRegressor",
"sklearn.linear_model.Ridge",
"sklearn.linear_model.LinearRegression",
"pandas.set_option",
"sklearn.preprocessing.StandardScaler",
"sklearn.ensemble.AdaBoostRegressor"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
michael-lazar/playscii | [
"dcefdd1deef9bdb3517c39d0129e948d238d4978"
] | [
"framebuffer.py"
] | [
"import numpy as np\nfrom OpenGL import GL\n\n\nclass Framebuffer:\n \n start_crt_enabled = False\n disable_crt = False\n clear_color = (0, 0, 0, 1)\n # declared as an option here in case people want to sub their own via CFG\n crt_fragment_shader_filename = 'framebuffer_f_crt.glsl'\n \n def ... | [
[
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
tkeech1/aws_ml | [
"512fd8c8770cbf5128ce9e0c03655c3d3021776b"
] | [
"code/python_data_science_handbook/mprun_demo.py"
] | [
"\nimport numpy as np\nimport pandas as pd\n\ndef sum_of_lists():\n #a = [1] * (10 ** 6)\n #b = [2] * (2 * 10 ** 7)\n #del b\n a = np.ones((2 ** 30), dtype=np.uint8)\n #df = pd.read_csv(\"../../data/nyc_taxi.csv\")\n #df2 = df.dropna()\n #df3 = df2.set_index('timestamp')\n test = np.ones((2*... | [
[
"numpy.ones"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
KoksiHub/Methods-For-SHREC-2021-Protein-Retrieval-and-Classification-Datasets | [
"c0565ee5290ce658e03b7770fdfb798dd619c106"
] | [
"method HAPPS for Geometry Data/HAPPS_3Dretrievalmethod.py"
] | [
"\n'''\nThis Script Can Run Alone.\n\nAuthor: Ekpo Otu (e-mail: eko @aber.ac.uk)\n\n\nShape Retrieval Contest (SHREC 2021 Protein Shape Benchmark Dataset): Track 3: Retrieval and Classification of Protein Surfaces Equiped with Physical and Chemical Properties\nDATASET: Geometry (i.e. 3D triangular Meshes)\nTRAININD... | [
[
"matplotlib.pyplot.legend",
"numpy.einsum",
"numpy.core.umath_tests.inner1d",
"numpy.squeeze",
"matplotlib.pyplot.plot",
"numpy.arctan2",
"numpy.mean",
"numpy.cross",
"numpy.histogram",
"numpy.hstack",
"matplotlib.pyplot.close",
"numpy.column_stack",
"numpy.nonz... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
AbbyGi/tiled | [
"a7f1809f0d8448fce3540c15d7697cb9454fedca"
] | [
"tiled/adapters/hdf5.py"
] | [
"import collections.abc\nimport warnings\n\nimport dask.array\nimport h5py\nimport numpy\n\nfrom ..adapters.utils import IndexersMixin, tree_repr\nfrom ..utils import DictView\nfrom .array import ArrayAdapter\n\n\nclass HDF5DatasetAdapter(ArrayAdapter):\n # TODO Just wrap h5py.Dataset directly, not via dask.arra... | [
[
"numpy.array",
"numpy.dtype"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ZhengyiLuo/humor | [
"72c1d507c025de2d214c2d7def815f6da225befa"
] | [
"humor/utils/torch.py"
] | [
"\nimport sys, os, time\nimport torch\nimport torch.nn as nn\nimport numpy as np\n\ndef get_device(gpu_idx=0):\n '''\n Returns the pytorch device for the given gpu index.\n '''\n gpu_device_str = 'cuda:%d' % (gpu_idx)\n device_str = gpu_device_str if torch.cuda.is_available() else 'cpu'\n if devic... | [
[
"torch.device",
"torch.load",
"torch.cuda.is_available",
"torch.save"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ronicamja/imageFilters | [
"d46f4c33b60ddf787fc03d0a1fa60a3d8fa0259a"
] | [
"imageIO.py"
] | [
"import imageio\nimport numpy as np\nimport os, log\ndef readImage(filename):\n if os.path.exists(filename):\n log.status(\"reading from \" + filename)\n first = imageio.imread(filename)\n first.tofile('.temp.raw')\n imageMemmap = np.memmap('.temp.raw', dtype=np.uint8, shape=first.sha... | [
[
"numpy.memmap"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ozendelait/pytorch-semseg | [
"200491febd653bd26befcd5b3d52c614aa832b7e"
] | [
"ptsemseg/models/utils.py"
] | [
"import torch\nimport torch.nn as nn\nimport numpy as np\nimport torch.nn.functional as F\n\nfrom torch.autograd import Variable\n\n\nclass conv2DBatchNorm(nn.Module):\n def __init__(\n self,\n in_channels,\n n_filters,\n k_size,\n stride,\n padding,\n bias=True,\... | [
[
"torch.zeros",
"torch.cat",
"torch.nn.functional.interpolate",
"torch.autograd.Variable",
"torch.from_numpy",
"torch.nn.functional.relu",
"torch.nn.Conv2DBatchNorm",
"torch.arange",
"numpy.zeros",
"torch.nn.functional.pad",
"torch.nn.Sequential",
"torch.nn.ConvTrans... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
MyNameJeremy/Sorting | [
"eec69ae01994704501e5228434473cc643b60a3d"
] | [
"Quicksort.py"
] | [
"'''\r\nWie benutzt man das Programm?\r\nGanz einfach: Man gibt ein, wie lang das array sein soll\r\n(Ich empfehle eine hohe Zahl, damit sich Quicksort überhaupt lohnt.).\r\nDann drückt man Enter und bekommt die zufälligen Zahlen, die gewählt wurden als ein Diagramm angezeigt.\r\nDas Diagramm schließt man dann wied... | [
[
"matplotlib.pyplot.plot",
"matplotlib.pyplot.show"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
koshian2/SNGAN | [
"117fbb19ac79bbc561c3ccfe285d6890ea0971f9"
] | [
"train_stl_resnet_postact.py"
] | [
"import torch\nimport torchvision\nfrom torchvision import transforms\nfrom tqdm import tqdm\nimport os\nimport pickle\nimport statistics\nimport glob\n\nimport losses\nimport models.post_act_resnet as post_act_resnet\nfrom inception_score import inceptions_score_all_weights\n\ndef load_stl(batch_size):\n # firs... | [
[
"torch.cat",
"torch.randn",
"torch.utils.data.TensorDataset",
"torch.eye",
"torch.utils.data.DataLoader"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
akash5100/sunpy | [
"6f586392f9799383017e0566d4303928183c06be"
] | [
"sunpy/io/tests/test_fits.py"
] | [
"import mmap\nfrom pathlib import Path\nfrom collections import OrderedDict\n\nimport numpy as np\nimport pytest\n\nimport astropy.io.fits as fits\n\nfrom sunpy.data.test import get_test_filepath, test_data_filenames\nfrom sunpy.data.test.waveunit import MEDN_IMAGE, MQ_IMAGE, NA_IMAGE, SVSM_IMAGE\nfrom sunpy.io imp... | [
[
"numpy.array",
"numpy.abs"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
jetsonworld/TensorFlow_On_JetsonNano | [
"216b21f63cb0a33e1a2a4d39be8d250c5ce1b504"
] | [
"06_Gradient_Boosting/09_xgboost_for_Classification.py"
] | [
"# xgboost for classification\nfrom numpy import asarray\nfrom numpy import mean\nfrom numpy import std\nfrom sklearn.datasets import make_classification\nfrom xgboost import XGBClassifier\nfrom sklearn.model_selection import cross_val_score\nfrom sklearn.model_selection import RepeatedStratifiedKFold\nfrom matplot... | [
[
"sklearn.datasets.make_classification",
"sklearn.model_selection.cross_val_score",
"numpy.asarray",
"numpy.std",
"sklearn.model_selection.RepeatedStratifiedKFold",
"numpy.mean"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
danielmoreira/medifor | [
"7d2cd460e3a712d716d288442b2d3dc85d081e9f"
] | [
"python/examples/provenance/filter_svc/notredame/facade.py"
] | [
"# Implements a facade to call Notre Dame's fitlering implementation.\n\nimport sys\nimport os\nimport numpy\nimport cv2\n\nsys.path.append(os.path.dirname(os.path.abspath(__file__)) + '/image_lib/') # image library path\nimport image_reader\nimport image_descriptor\nimport image_matcher\n\n\n# Reads an image, giv... | [
[
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ddajing/multilayer-cnn-text-classification | [
"ea97105de2e4411eb492e0c268045006a9a3669f"
] | [
"data_helpers.py"
] | [
"import numpy as np\r\nimport re\r\nfrom collections import defaultdict\r\n\r\ndef clean_str(string, TREC=False):\r\n \"\"\"\r\n Tokenization/string cleaning for all datasets except for SST.\r\n Original taken from https://github.com/yoonkim/CNN_sentence/blob/master/process_data.py\r\n \"\"\"\r\n str... | [
[
"numpy.asarray",
"numpy.random.uniform",
"numpy.zeros",
"numpy.dtype"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
europa1610/ALPR-Project | [
"6c101b16dd3082bfcf5284efb65f4adc7d44a3df"
] | [
"utils/roi_pooling.py"
] | [
"import torch\nimport torch.nn as nn\nimport torch.autograd as ag\nfrom torch.autograd.function import Function\n#from torch._thnn import type2backend\n\n'''\nclass AdaptiveMaxPool2d(Function):\n def __init__(self, out_w, out_h):\n super(AdaptiveMaxPool2d, self).__init__()\n self.out_w = out_w\n ... | [
[
"torch.nn.AdaptiveMaxPool2d",
"torch.cat"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
tobiasraabe/crypto | [
"5b40049169cfbf02f4979a55e8abdb77b834b820"
] | [
"src/transformers/financial_indicators.py"
] | [
"#!/usr/bin/env python3\n\n\"\"\"This module provides many commonly used financial indicators.financial\n\nThe design of the classes has to be in line with the base classes from sklearn.\nThen, the classes can be used as parts of scikit-learn pipeline.\n\n\"\"\"\n\nimport numpy as np\n\nfrom sklearn.base import Tra... | [
[
"numpy.nan_to_num"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
SiriusKY/pytorch-ocr | [
"c739a13116c6833e8dca3be4bc7b66fc757328b4"
] | [
"test.py"
] | [
"import argparse\nimport torch\nfrom tqdm import tqdm\nimport data_loader.data_loaders as module_data\nimport model.loss as module_loss\nimport model.metric as module_metric\nimport model.model as module_arch\nfrom parse_config import ConfigParser\n\n\ndef main(config):\n logger = config.get_logger('test')\n\n ... | [
[
"torch.nn.DataParallel",
"torch.no_grad",
"torch.cuda.is_available",
"torch.load"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ClaudsFalse/neural_machine_translation | [
"253c736af32552d0be5fecd05eb801a776c17f5c"
] | [
"nmt_toolkit/seq2seq/models/lstm.py"
] | [
"import torch\nimport torch.nn as nn\nimport torch.nn.functional as F\n\nfrom seq2seq import utils\nfrom seq2seq.models import Seq2SeqModel, Seq2SeqEncoder, Seq2SeqDecoder\nfrom seq2seq.models import register_model, register_model_architecture\n\n\n@register_model('lstm')\nclass LSTMModel(Seq2SeqModel):\n \"\"\"... | [
[
"torch.nn.functional.softmax",
"torch.nn.functional.dropout",
"torch.nn.LSTM",
"torch.cat",
"torch.nn.utils.rnn.pack_padded_sequence",
"torch.nn.LSTMCell",
"torch.nn.Linear",
"torch.nn.utils.rnn.pad_packed_sequence",
"torch.bmm"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Vaderico/LSTM-Camera-Game | [
"3ccc05f2f6ea5c06eb36f4e5a755dca51d913bcc"
] | [
"model.py"
] | [
"import torch\nimport torch.nn as nn\nimport torchvision\nfrom torchvision import models\nimport sys\n\nclass LSTMController(nn.Module):\n def __init__(self, hidden_dim, middle_out_dim):\n super(LSTMController, self).__init__()\n self.hidden_dim = hidden_dim\n\n self.init_resnet()\n r... | [
[
"torch.zeros",
"torch.nn.LSTM",
"torch.randn",
"torch.nn.Linear",
"torch.no_grad"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
thomasw21/DeepSpeed | [
"99bd592d253c6c2e995c49978c4444f989cfd7be"
] | [
"deepspeed/moe/sharded_moe.py"
] | [
"'''\nCopyright 2021 The Microsoft DeepSpeed Team\n'''\n# The file has been adapted from two fairscale files:\n# (1) https://github.com/facebookresearch/fairscale/blob/master/fairscale/nn/moe/moe_layer.py\n# (2) https://github.com/facebookresearch/fairscale/blob/master/fairscale/nn/moe/top2gate.py\n# Git commit has... | [
[
"torch.mean",
"torch.nn.functional.softmax",
"torch.empty_like",
"torch.finfo",
"torch.distributed.all_to_all_single",
"torch.distributions.gumbel.Gumbel",
"torch.topk",
"torch.einsum",
"torch.sum",
"torch.lt",
"torch.zeros_like",
"torch.tensor",
"torch.nn.Linea... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
phil-mansfield/guppy | [
"5394d20b83912cd072a358c38bae18a06853f419"
] | [
"scripts/plot_phi_pts.py"
] | [
"import numpy as np\nimport matplotlib.pyplot as plt\nimport palette\nfrom palette import pc\n\ndef mvir_to_rvir(mvir):\n return 0.4459216 * (mvir/1e13)**(1.0/3)\n\ndef mvir_to_vvir(mvir):\n return 310.6 * (mvir/1e13)**(1.0/3)\n\ndef main():\n palette.configure(True)\n\n file_names = [\n \"profil... | [
[
"matplotlib.pyplot.ylim",
"matplotlib.pyplot.savefig",
"matplotlib.pyplot.plot",
"matplotlib.pyplot.xlim",
"numpy.log10",
"matplotlib.pyplot.xlabel",
"numpy.loadtxt",
"matplotlib.pyplot.ylabel"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
chenbo123222/MegEngine | [
"2e8742086563ea442c357b14560245c54e0aa0a3"
] | [
"imperative/python/test/unit/core/test_dtype_intbx.py"
] | [
"# MegEngine is Licensed under the Apache License, Version 2.0 (the \"License\")\n#\n# Copyright (c) 2014-2020 Megvii Inc. All rights reserved.\n#\n# Unless required by applicable law or agreed to in writing,\n# software distributed under the License is distributed on an\n# \"AS IS\" BASIS, WITHOUT ARRANTIES OR CON... | [
[
"numpy.arange",
"numpy.array",
"numpy.random.randint",
"numpy.testing.assert_equal"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
doronbehar/sundials | [
"6ddce5d90084d8d1cbb8e12bb5a4402168325efe"
] | [
"examples/arkode/CXX_serial/plot_heat2D.py"
] | [
"#!/usr/bin/env python\n# ------------------------------------------------------------------------------\n# Programmer(s): Daniel R. Reynolds @ SMU\n# David J. Gardner @ LLNL\n# ------------------------------------------------------------------------------\n# SUNDIALS Copyright Start\n# Copyright (... | [
[
"numpy.linspace",
"numpy.reshape",
"matplotlib.pyplot.close",
"numpy.meshgrid",
"numpy.zeros",
"numpy.loadtxt",
"matplotlib.pyplot.figure"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
emreay-/cyclops | [
"72c4af694f51918eebea45a0fcd4c8c5ca3c19bd"
] | [
"cyclops/utility.py"
] | [
"#\n# Emre Ay, April 2017\n# Cyclops project: Localization system with an overhead camera\n#\n\nimport argparse\nfrom typing import Callable\n\nimport numpy as np\nimport cv2\nimport yaml\n\nfrom cyclops.scale_estimation import scale_estimation\n\n\nclass Keys:\n space = 32\n esc = 27\n enter = 10\n c =... | [
[
"numpy.array",
"numpy.zeros",
"numpy.mean"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Wenlin-Chen/PILCO | [
"8a3a3eba26a3524beae86e050be108efb4f4113b"
] | [
"pilco/models/smgpr.py"
] | [
"import gpflow\nimport tensorflow as tf\nimport numpy as np\n\nfrom .mgpr import MGPR\n\nfrom gpflow import config\nfloat_type = config.default_float()\n\n\nclass SMGPR(MGPR):\n def __init__(self, data, num_induced_points, name=None):\n self.num_induced_points = num_induced_points\n MGPR.__init__(s... | [
[
"tensorflow.matmul",
"tensorflow.transpose",
"tensorflow.linalg.cholesky_solve",
"tensorflow.linalg.triangular_solve",
"tensorflow.eye",
"tensorflow.ones",
"numpy.random.rand",
"tensorflow.square",
"tensorflow.sqrt",
"tensorflow.linalg.cholesky"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
campos20/wca-statistics | [
"ff7218038c526e8005435ad7ea762fdbc3eba9b0"
] | [
"src/utils.py"
] | [
"import json\nimport pandas as pd\nfrom math import *\nimport re\n\n# WCA_export_Competitions labels\n\"\"\"id name cityName countryId information [0-4]\nyear month day endMonth endDay [5-9]\neventSpecs wcaDelegate organiser [10-12]\nvenue venueAddress venueDetails [13-15]\nexternal_website cellName latitude longit... | [
[
"pandas.read_csv"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
nilsgawlik/gdmc_2021_submission | [
"79b14af744f43b7af190f18dd5fa8dcdf5db10e3"
] | [
"wfc_test.py"
] | [
"from ast import walk\nimport cv2\nimport numpy as np\nimport time\nimport wfc_implementation\nimport mapUtils\nimport interfaceUtils\nfrom worldLoader import WorldSlice\nimport math\n\ntiles = np.array([\n [[2,2,2,2,2],[2,2,2,2,2],[2,2,2,2,2],[2,2,2,2,2],[2,2,2,2,2]],[[2,2,1,0,0],[2,2,1,0,0],[1,1,1,0,0],[0,0,0,... | [
[
"numpy.array",
"numpy.where",
"numpy.transpose"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
xiemenghua/Q-learing--robort-model | [
"68b7415d28ce83c19788f3167456c317db553d4b"
] | [
"Q-learing-robot-5.py"
] | [
"\n# coding: utf-8\n\n# In[1]:\n\nfrom itertools import product as selfcrossjoin\nimport numpy as np\nQtable = {}\n\n\n#分两次更新Q表,当落子没有占满棋盘时,当落子占满棋盘\n\n\n# In[ ]:\n\n\n\n\n# In[ ]:\n\n#利用itertools 笛卡尔生成器生成 Q表,并初始化Q值为全部0\n#因为9个位置,每个位置有3种可能组合0,1,2。期盘有9个格子 因此排列组合的可能性有 3^9=19683种组合\nx=0\nfor i in selfcrossjoin([0,1,2], r... | [
[
"numpy.random.randint"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
emac1234/supportagent | [
"c84c1d4f8ac4f0fc73310331b9195b1ccbce89b3"
] | [
"supportagent/utils.py"
] | [
"# -*- coding: utf-8 -*-\n\"\"\"Zendesk Generator.ipynb\n\nAutomatically generated by Colaboratory.\n\nOriginal file is located at\n https://colab.research.google.com/drive/1fqcKvmj376PXj1Yifu5dQ6gJq_hsqH9l\n\"\"\"\n\n# Commented out IPython magic to ensure Python compatibility.\n# %%capture\n# !pip install tran... | [
[
"torch.softmax",
"torch.no_grad",
"torch.cuda.is_available",
"torch.load"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
capslockwizard/drsip | [
"ad6a6fe185629a5f3801ce548f0adb86f1684877"
] | [
"drsip/save_load.py"
] | [
"\"\"\"\r\n=====================================================\r\nSaving and Loading (:mod:`drsip.save_load`)\r\n=====================================================\r\n\r\nModule contains helper functions to save and load DR-SIP data files.\r\n\r\nFunctions\r\n---------\r\n\r\n.. autofunction:: save_pd_table\r\... | [
[
"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": []
}
] |
Flamexmt/LMA | [
"bb500b7ae48a3f6751d6434126de9845b58d2d65"
] | [
"datasets/MNIST.py"
] | [
"import os\nimport torchvision\nimport torchvision.transforms as vision_transforms\nimport datasets\nimport torch\nimport datasets.torchvision_extension as vision_transforms_extension\n\n\nmeanstd = {\n 'mean':(0.1307,),\n 'std': (0.3081,),\n}\n\nclass MNIST(object):\n def __init__(self, dataFolder=None, pin... | [
[
"torch.utils.data.DataLoader"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Jayram999/Alert-Generation-on-Detection-of-Suspicious-Activity-using-Transfer-Learning | [
"4c8a257d76d57fbfcb76758039fc393b7ad1f5d6"
] | [
"videoClassification/predict_video_realtime.py"
] | [
"#python predict_video_realtime.py --model model/activity_gpu.model --label-bin model/lb.pickle --output output/shoplifting.avi --size 64\n\n# import the necessary packages\nfrom keras.models import load_model\nfrom imutils.video import VideoStream\nfrom collections import deque\nimport numpy as np\nimport argparse... | [
[
"numpy.expand_dims",
"numpy.max",
"numpy.append",
"numpy.argmax",
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
1at7/Travelling-Thief-Problem | [
"e62335af29b7503808b69b57984f6758398d1150"
] | [
"tsp.py"
] | [
"# -*- coding: utf-8 -*-\r\n\r\nimport random\r\nimport math\r\nimport numpy\r\nimport matplotlib.pyplot as plt\r\nfrom collections import deque\r\n\r\n\r\ndef decide_to(p):\r\n '''\r\n Randomly returns True/False based on probability.\r\n \r\n Args:\r\n p :float of [0,1]; probability of the re... | [
[
"matplotlib.pyplot.title",
"matplotlib.pyplot.plot",
"matplotlib.pyplot.subplot",
"matplotlib.pyplot.yticks",
"matplotlib.pyplot.show",
"numpy.zeros",
"matplotlib.pyplot.xticks"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
zhu2014yi/CRPN | [
"5da5bf42eb8c86a17bdff52680c3827a2ef18590"
] | [
"siamese_tracking/loss.py"
] | [
"\nimport torch\nimport torch.nn as nn\n\n\n\ndef giou_bbox_overlaps(bboxes1, bboxes2, is_aligned=False):\n '''Calculate generative overlap between two set of bboxes.\n\n If ``is_aligned`` is ``False``, then calculate the ious between each bbox\n of bboxes1 and bboxes2, otherwise the ious between each al... | [
[
"torch.any",
"torch.min",
"torch.max"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
TakuTsuzuki/Growing-Neural-Cellular-Automata | [
"baa475842a72a2f318e76b5e52d738d8911b069d"
] | [
"lib/CAModel.py"
] | [
"import numpy as np\nimport torch\nimport torch.nn as nn\nimport torch.optim as optim\nimport torch.nn.functional as F\n\nclass CAModel(nn.Module):\n # Network structure\n def __init__(self, channel_n, fire_rate, device, hidden_size=128):\n super(CAModel, self).__init__()\n\n self.device = devic... | [
[
"torch.cat",
"torch.nn.functional.conv2d",
"numpy.cos",
"numpy.sin",
"torch.nn.Linear",
"torch.nn.functional.relu",
"torch.no_grad",
"numpy.outer",
"torch.nn.functional.max_pool2d"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
eltociear/chaos_genius | [
"eb3bc27181c8af4144b95e685386814109173164",
"eb3bc27181c8af4144b95e685386814109173164"
] | [
"chaos_genius/core/rca/root_cause_analysis.py",
"chaos_genius/alerts/base_alerts.py"
] | [
"\"\"\"Provides RootCauseAnalysis class for computing RCA.\"\"\"\n\nimport warnings\nfrom itertools import combinations\nfrom math import isclose\nfrom textwrap import wrap\nfrom typing import Dict, List, Tuple\n\nimport matplotlib.pyplot as plt\nimport numpy as np\nimport pandas as pd\n\nfrom chaos_genius.core.rca... | [
[
"pandas.concat",
"numpy.isinf",
"numpy.isnan",
"pandas.DataFrame",
"pandas.isna",
"matplotlib.pyplot.show",
"pandas.qcut"
],
[
"pandas.concat",
"pandas.read_pickle",
"pandas.DataFrame"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"0.23",
"0.21",
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"0.24",
"1.0",
"0.25",
"1.3"
],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [
... |
modelearth/useeio_api | [
"2a4cd9776be69afd2560fff733a4e6cc31dad8cc"
] | [
"python/useeioapi/data.py"
] | [
"import csv\nimport json\nimport os\nimport struct\n\nimport numpy\n\n\ndef read_sectors(folder: str, model_id: str) -> list:\n path = folder + '/' + model_id + '/sectors.csv'\n sectors = []\n for row in read_csv(path):\n sectors.append({\n 'index': int(row[0]),\n 'id': row[1],... | [
[
"numpy.memmap"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
matthoffman/degas | [
"878f10b40fa2efa008986823e0c7fba27df8a2d4"
] | [
"degas/dataset.py"
] | [
"# -*- coding: utf-8 -*-\nimport logging\nfrom typing import List\nfrom csv import QUOTE_ALL\nfrom pathlib import Path\nfrom glob import glob\nimport pandas as pd\n\n\n##########################################\n# some constants for use in other files\n##########################################\n\n# key for our dat... | [
[
"pandas.concat",
"pandas.read_csv",
"pandas.DataFrame"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
cdchushig/smote_variants | [
"c6a0f57dc8b4002800a5a413879323aaba04e0dd"
] | [
"smote_variants/_smote_variants.py"
] | [
"#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\n\"\"\"\nCreated on Sat Sep 15 11:15:24 2018\n\n@author: gykovacs\n\"\"\"\n\n# import system packages\nimport os\nimport pickle\nimport itertools\nimport logging\nimport re\nimport time\nimport glob\nimport inspect\n\n# used to parallelize evaluation\nfrom joblib imp... | [
[
"scipy.spatial.Voronoi",
"numpy.linalg.matrix_rank",
"numpy.sqrt",
"sklearn.model_selection.KFold",
"numpy.all",
"sklearn.cluster.AgglomerativeClustering",
"numpy.exp",
"numpy.where",
"sklearn.preprocessing.MinMaxScaler",
"tensorflow.random.set_seed",
"numpy.unique",
... | [
{
"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": []
}
] |
JonathanCamargo/Eris | [
"34c389f0808c8b47933605ed19d98e62280e56dd"
] | [
"python/Examples/BandwidthTest.py"
] | [
"import rospy\nimport threading\nimport numpy as np\nfrom std_msgs.msg import Header,String\nfrom custom_msgs.msg import Float32\n\nimport copy\n\n#ROS TEST to exceed WLAN bandwidth\nfrom threading import Thread,Lock\nfrom time import sleep\n\ndataMutex=Lock()\nrospy.init_node('talker', anonymous=True)\n\nglobal pu... | [
[
"numpy.arange",
"numpy.std",
"numpy.mean",
"numpy.min"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
cow8/PupilTracking | [
"02977de83c9f1481b700a3bb0ac37f0f814b1faa"
] | [
"train_evaluator/train.py"
] | [
"# import alexnet\n# import resnet_v1\nimport platform\n\nimport tensorflow as tf\n\nfrom MakeDataset import TFRecord_Slim_Reader as TFRS_Reader\nfrom Train.VGG import vgg\n\nslim=tf.contrib.slim\nnetname=\"VGG16\"\nrate=1\nnet=vgg.vgg_16\nTFRECORDFILE=\"./dataset.tfrecord\"\nIS_PRETRAIN=True\nPRETRAIN_FILEPATH=\".... | [
[
"tensorflow.Print",
"tensorflow.contrib.framework.assign_from_checkpoint_fn",
"tensorflow.reshape",
"tensorflow.image.resize_bicubic",
"tensorflow.nn.top_k",
"tensorflow.train.GradientDescentOptimizer",
"tensorflow.one_hot",
"tensorflow.train.shuffle_batch"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
lytai1/difusion_imaging | [
"4884e63d7c36cb05564a736a2f31f2beaacde6d4"
] | [
"diffusion_imaging/preprocessing/preprocessing.py"
] | [
"from dipy.segment.mask import median_otsu\nfrom abc import (\n ABC,\n abstractmethod\n)\nfrom dependency_injector import providers, containers\nimport numpy as np\nfrom dipy.segment.mask import median_otsu\n\nclass Preprocess(ABC):\n \"\"\"\n Base class for the preprocessing step\n \"\"\"\n \n ... | [
[
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
evijit/hci_updates | [
"7e6f564fe3f819f83baaffa7fd6fcd7ecbb58bfa"
] | [
"code/ner_stuff.py"
] | [
"from pathlib import Path\nimport spacy\nfrom nltk.tokenize import TweetTokenizer\nimport sys\nimport csv\nimport json\nimport re\nfrom pandas.io.json import json_normalize\n\ntknzr = TweetTokenizer()\ntknzr = TweetTokenizer(reduce_len=True)\n\nnlp2 = spacy.load(Path('ner_model_50'))\n\n\nfull_data = []\ncounter = ... | [
[
"pandas.io.json.json_normalize"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"0.23",
"0.21",
"0.19",
"0.24",
"0.20",
"0.25"
],
"scipy": [],
"tensorflow": []
}
] |
Mucephie/ccdprocx | [
"da8e64f685045db22b40df960b03257b6a6c854b"
] | [
"ccdprocx/tests/test_rebin.py"
] | [
"# Licensed under a 3-clause BSD style license - see LICENSE.rst\n\nimport numpy as np\nimport pytest\n\nfrom astropy.nddata import StdDevUncertainty\n\nfrom astropy.tests.helper import catch_warnings\nfrom astropy.utils.exceptions import AstropyDeprecationWarning\n\nfrom ccdprocx.core import rebin\nfrom ccdprocx.t... | [
[
"numpy.testing.assert_array_equal",
"numpy.random.normal",
"numpy.zeros_like"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Extracheesy/KerasPlaypen | [
"cdd6eb9c82d57e36c8a5e0509b50a00f163fc734"
] | [
"main.py"
] | [
"# This is a sample Python script.\n\n# Press Maj+F10 to execute it or replace it with your code.\n# Press Double Shift to search everywhere for classes, files, tool windows, actions, and settings.\n\n\n# from numpy import loadtxt\nimport numpy as np\nimport tensorflow as tf\n\nfrom keras.optimizers import SGD\nfro... | [
[
"numpy.loadtxt"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
tschaume/fireworks | [
"0701e22f979472e5eb1b40db1d21a798462858dc"
] | [
"fireworks/utilities/fw_utilities.py"
] | [
"import contextlib\nimport datetime\nimport errno\nimport logging\nimport multiprocessing\nimport os\nimport socket\nimport string\nimport sys\nimport traceback\nfrom logging import Formatter, Logger\nfrom multiprocessing.managers import BaseManager\nfrom typing import Tuple\n\nfrom fireworks.fw_config import DS_PA... | [
[
"matplotlib.pyplot.plot",
"matplotlib.pyplot.text",
"matplotlib.pyplot.savefig",
"matplotlib.pyplot.axis"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
IntroCursos/PyQTEjemplos | [
"e465f825e09a01b98f5d1d40431658db67342da7"
] | [
"VentanaLecturaDeExcel/OpenSavePandasGUI.py"
] | [
"\n#pyuic5 -x mainwindow.ui -o output.py\n\n# -*- coding: utf-8 -*-\n\n# Form implementation generated from reading ui file 'mainwindow.ui'\n#\n# Created by: PyQt5 UI code generator 5.9.2\n#\n# WARNING! All changes made in this file will be lost!\n\nfrom PyQt5 import QtCore, QtGui, QtWidgets\nfrom PandasData import... | [
[
"pandas.ExcelWriter"
]
] | [
{
"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": []
}
] |
rohith-bs/dgraphpandas | [
"29e91e2e7bb1d5d991ab94709a2d7e27f7dd7316"
] | [
"tests/strategies/test_horizontal.py"
] | [
"import unittest\nfrom unittest.mock import patch, Mock\n\nimport pandas as pd\nfrom pandas.testing import assert_frame_equal\nfrom parameterized import parameterized\n\nfrom dgraphpandas.strategies.horizontal import horizontal_transform\n\n\nclass HorizontalTests(unittest.TestCase):\n\n @parameterized.expand([\... | [
[
"pandas.to_datetime",
"pandas.testing.assert_frame_equal",
"pandas.Series",
"pandas.DataFrame"
]
] | [
{
"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": []
}
] |
jjimmykang/bwsi-backprojection | [
"440e21f90e2a1d0d1c28bfd9a0faaf97129378a5"
] | [
"legacy/main_code/pulson440/unpack_batch.py"
] | [
"import numpy as np\nfrom control import unpack\nimport argparse\nimport pickle\n\n\ndef main():\n parser = argparse.ArgumentParser(description='batch unpacks data')\n parser.add_argument('data_dir', type=str, help='the directory for all of the scan datas')\n parser.add_argument('num_files', type=int, help... | [
[
"numpy.asarray"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
KiloSat/ML_Algos | [
"4375bdadeca91a8bfa5ca9dedf6202d3252b96d7"
] | [
"ML_Algos/apps/linear_regression_2.py"
] | [
"import streamlit as st \r\n\r\ndef app():\r\n\tst.write(\"Predicting House Prices with multiple variables\")\r\n\timport pandas as pd\r\n\timport matplotlib.pyplot as plt\r\n\timport numpy as np\r\n\tfrom sklearn import linear_model\r\n\r\n\tdata = pd.read_csv('housing.csv')\r\n\tdata = data[:50] #taking just 50 r... | [
[
"pandas.read_csv",
"matplotlib.pyplot.scatter",
"sklearn.linear_model.LinearRegression",
"matplotlib.pyplot.xlabel",
"matplotlib.pyplot.ylabel"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
trevorki/dsci-532_group-20 | [
"6bba74c08a0b66c4f7986c20a05b4a2dfce7f279"
] | [
"src/hotel_cleaner.py"
] | [
"# hotel_cleaner.py\n# author: Trevor Kinsey\n# date: 2021-01-19\n\n'''This script cleans and wrangles the hotels.csv file to be used\n in a visualization dashboard app\n\nUsage: python hotel_cleaner.py\n\n'''\nimport numpy as np\nimport pandas as pd\n\n# import the data\nhotels = pd.read_csv(\"data/raw/hotels.cs... | [
[
"pandas.read_csv",
"pandas.to_datetime"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.3",
"1.1",
"1.5",
"1.2"
],
"scipy": [],
"tensorflow": []
}
] |
i5misswrong/CA_RL | [
"123df432276e3718e8287ee0835c9a0ba5fa9698"
] | [
"tensorflow_book/MNIST_Learning/cnn_view_01.py"
] | [
"import tensorflow as tf\r\nimport numpy as np\r\nimport matplotlib.pyplot as plt\r\nimport matplotlib.image as mpimg\r\nfrom tensorflow.examples.tutorials.mnist import input_data\r\n\r\nmnist = input_data.read_data_sets(\"MNIST_data/\", one_hot=True)\r\n# GPU参数配置\r\nconfig = tf.ConfigProto()\r\nconfig.gpu_options.... | [
[
"matplotlib.pyplot.imshow",
"numpy.sqrt",
"tensorflow.nn.max_pool",
"tensorflow.cast",
"matplotlib.image.imread",
"tensorflow.train.AdamOptimizer",
"numpy.random.randint",
"tensorflow.nn.conv2d",
"tensorflow.Variable",
"tensorflow.ConfigProto",
"tensorflow.Session",
... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
binzhihao/py-ai-project | [
"64491f6e5ff2007fd7abad5ee0c6058a914d1f84"
] | [
"nn/tf_fnn_bn.py"
] | [
"from functools import partial\nimport tensorflow as tf\nimport numpy as np\nimport data.mnist.loader as loader\n\nOPTIMIZER = 'adam'\n\nif __name__ == '__main__':\n\n n_inputs = 28 * 28\n n_hidden1 = 300\n n_hidden2 = 100\n n_outputs = 10\n\n learning_rate = 0.01\n n_epochs = 40\n batch_size =... | [
[
"tensorflow.contrib.layers.variance_scaling_initializer",
"tensorflow.reduce_mean",
"tensorflow.get_collection",
"tensorflow.placeholder_with_default",
"tensorflow.cast",
"tensorflow.placeholder",
"tensorflow.global_variables_initializer",
"tensorflow.train.GradientDescentOptimizer... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
artzaza7/WebAppZescampGroup_9 | [
"fa6ae018db399104af1a4837046d519ba74aad93"
] | [
"Test.py"
] | [
"from scipy.spatial import distance as dist\nimport numpy as np\nimport imutils\nimport cv2\nimport os\n\n# base path to YOLO directory\nMODEL_PATH = \"yolo-coco\"\n\n# initialize minimum probability to filter weak detections along with\n# the threshold when applying non-maxima suppression\nMIN_CONF = 0.3\nNMS_THRE... | [
[
"numpy.array",
"numpy.argmax",
"scipy.spatial.distance.cdist"
]
] | [
{
"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"
... |
ramkpari/mne-python | [
"7b428b96c2a719902ae72a498618062f879d674c"
] | [
"mne/viz/backends/_notebook.py"
] | [
"\"\"\"Notebook implementation of _Renderer and GUI.\"\"\"\n\n# Authors: Guillaume Favelier <guillaume.favelier@gmail.com>\n#\n# License: Simplified BSD\n\nfrom contextlib import contextmanager\nfrom IPython.display import display\nfrom ipywidgets import (Button, Dropdown, FloatSlider, FloatText, HBox,\n ... | [
[
"matplotlib.backends.backend_nbagg.FigureCanvasNbAgg",
"matplotlib.backends.backend_nbagg.FigureManager"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
raunakkmr/Graph-Attention-Networks | [
"276e3a1dfb4f9b50944009f796b12b546d05136a"
] | [
"src/main.py"
] | [
"from math import ceil\nimport os\nimport sys\n\nimport torch\nimport torch.nn as nn\nimport torch.optim as optim\nfrom torch.utils.data import DataLoader\n\nfrom datasets import node_classification\nimport models\nimport utils\n\ndef main():\n config = utils.parse_args()\n\n if config['cuda'] and torch.cuda.... | [
[
"torch.max",
"torch.load",
"torch.sum",
"torch.utils.data.DataLoader",
"torch.no_grad",
"torch.cuda.is_available"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
sinhars/Data-Structures-And-Algorithms | [
"92f42ac347a69260a28cfb37d3013bfe9b045448"
] | [
"Course1/Week2/1_fibonacci.py"
] | [
"# Uses python3\n\nimport sys\nimport numpy as np\n\ndef calc_fib(n):\n if (n <= 1):\n return n\n return calc_fib(n - 1) + calc_fib(n - 2)\n\ndef calc_fib_by_sum(n):\n fib_arr = np.zeros(n + 1, dtype=np.longlong)\n for i in range(n + 1):\n fib_arr[i] = i if (i <= 1) else (fib_arr[i - 1] + ... | [
[
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
dtish6/CPPN_Runway | [
"814c94cf1a5aae9e19f4ea81ad0ae51a057fe38f"
] | [
"example_model.py"
] | [
"# MIT License\n\n# Copyright (c) 2019 Runway AI, Inc\n\n# Permission is hereby granted, free of charge, to any person obtaining a copy\n# of this software and associated documentation files (the \"Software\"), to deal\n# in the Software without restriction, including without limitation the rights\n# to use, copy, ... | [
[
"numpy.linspace",
"tensorflow.keras.layers.Dense",
"numpy.uint8",
"tensorflow.keras.Sequential",
"numpy.linalg.norm",
"tensorflow.keras.initializers.VarianceScaling",
"numpy.repeat",
"numpy.meshgrid",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"2.7",
"2.2",
"2.3",
"2.4",
"2.5",
"2.6"
]
}
] |
vietdelta/TopicModelling | [
"3c5ba81bcfe3d7fcb418f21532e82413fc5474ad"
] | [
"lda_simple.py"
] | [
"# -*- coding: utf-8 -*-\nimport os\nfrom sklearn.feature_extraction.text import CountVectorizer\nimport lda\nimport numpy as np\nimport pickle\ndata_folder = \"/home/vietphan/Downloads/fbcrawl/Data-Celeb-Nov/\"\nfilename = data_folder+\"model/\"+\"done_processing.txt\"\ncorpus = []\npage_id = []\ndoc_count = 0\nwi... | [
[
"sklearn.feature_extraction.text.CountVectorizer"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ram-ki/SMS-organizer | [
"0ee28b07b736cdef84eb58892215b71a43303eda"
] | [
"prune.py"
] | [
"import pandas as pd\nimport numpy as np\nimport glob\n\nimport data.normalise as nm\nfrom data.duplicates import group_duplicates\nfrom data.features import compute_features\n\nnw_features_disc = {\n\t'Time': {\n\t\t'func': nm.change_time,\n\t\t'input': 'time'\n\t},\n\t'Date': {\n\t\t'func': nm.has_dates,\n\t\t'in... | [
[
"numpy.savetxt",
"pandas.concat",
"pandas.read_csv",
"numpy.append"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.3",
"1.1",
"1.5",
"1.2"
],
"scipy": [],
"tensorflow": []
}
] |
yashk2000/ai-economist | [
"b9424f2283023748399b9b56999d213164d2f258"
] | [
"Experiment 2/training_scripts/aie/plotting.py"
] | [
"# Copyright (c) 2020, 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\n# or https://opensource.org/licenses/BSD-3-Clause\n\nimport matplotlib.pyplot as plt\nimport numpy as np\n\nfrom ai_economist.foundation impor... | [
[
"numpy.minimum",
"numpy.abs",
"numpy.linspace",
"matplotlib.pyplot.get_cmap",
"matplotlib.pyplot.subplots",
"numpy.stack",
"numpy.zeros_like",
"numpy.mean",
"numpy.transpose",
"numpy.argsort",
"numpy.array",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
wrongu/modularity | [
"9186744916aa4b2ef808e6ee542b18e73ba5c9e1"
] | [
"generate_dummy_checkpoints.py"
] | [
"import torch\nfrom models import LitWrapper\nfrom pathlib import Path\nimport argparse\n\n\ndef create_dummy_checkpoint(dataset, task, uid, save_dir=Path()):\n mdl = LitWrapper(dataset=dataset, task=task, l2=0., l1=0., drop=0., run=uid)\n\n the_path = save_dir / mdl.get_uid()\n the_path.mkdir(exist_ok=Tru... | [
[
"torch.save"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Toraudonn/RecordWithRS | [
"4793416b1b3fd3ec5339bd4b070f980a401f11fd"
] | [
"python/rendering.py"
] | [
"import chainer\nimport open3d as o3\nimport numpy as np\nimport csv\nimport cv2\nfrom pprint import pprint \n\nimport argparse\nimport sys\nimport os\nimport time\n\ndir_path = os.path.dirname(os.path.realpath(__file__))\nabs_op_lib = os.path.join(dir_path, 'openpose')\nfrom openpose import params, JointType\n\n\n... | [
[
"numpy.dot",
"numpy.asarray",
"numpy.matmul",
"numpy.linalg.norm",
"numpy.all",
"numpy.concatenate",
"numpy.any",
"numpy.cross",
"numpy.array",
"numpy.zeros",
"numpy.loadtxt"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
apexrl/CoDAIL | [
"d6996698155677b51f5b844d848bf2bdce0f8a5f"
] | [
"multi-agent-particle-envs/multiagent/scenarios/simple_tag.py"
] | [
"import numpy as np\nfrom multiagent.core import World, Agent, Landmark\nfrom multiagent.scenario import BaseScenario\n\n\nclass Scenario(BaseScenario):\n def make_world(self):\n world = World()\n # set any world properties first\n world.dim_c = 2\n num_good_agents = 1\n num_ad... | [
[
"numpy.square",
"numpy.concatenate",
"numpy.exp",
"numpy.random.uniform",
"numpy.array",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
dmarx/lightning-flash | [
"4cda031c1f9c8d8754fd36b5720d2a5a7d866765"
] | [
"tests/core/data/io/test_input_transform.py"
] | [
"# Copyright The PyTorch Lightning team.\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... | [
[
"torch.nn.Identity"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
jscarlson/restyle-encoder | [
"8b0c97a6e44ad244efe7bd77f80d7201817c314c"
] | [
"models/mtcnn/mtcnn_pytorch/src/detector.py"
] | [
"import numpy as np\nimport torch\nfrom .get_nets import PNet, RNet, ONet\nfrom .box_utils import nms, calibrate_box, get_image_boxes, convert_to_square\nfrom .first_stage import run_first_stage\n\n\ndef detect_faces(image, min_face_size=20.0,\n thresholds=[0.6, 0.7, 0.8],\n nms_thre... | [
[
"numpy.expand_dims",
"numpy.round",
"torch.FloatTensor",
"torch.no_grad",
"numpy.where",
"numpy.vstack"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
raphael-sch/tensor2tensor | [
"6ad82d4001145348922e915d383e375c833a929c"
] | [
"tensor2tensor/data_generators/gym_utils.py"
] | [
"# coding=utf-8\n# Copyright 2018 The Tensor2Tensor 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 requir... | [
[
"numpy.argwhere"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ZhichaoOuyang/reviews4rec | [
"479160aba57271c1109b8857d3cb3a54881898fc"
] | [
"MPCN/tf_models/exp_model2.py"
] | [
"#!/usr/bin/env python\nfrom __future__ import absolute_import\nfrom __future__ import division\nfrom __future__ import print_function\n\nimport numpy as np\nfrom sklearn.metrics import roc_auc_score\nfrom sklearn.metrics import average_precision_score\nfrom sklearn.preprocessing import OneHotEncoder\nfrom sklearn.... | [
[
"tensorflow.device",
"tensorflow.get_variable",
"tensorflow.concat",
"tensorflow.count_nonzero",
"tensorflow.control_dependencies",
"tensorflow.reduce_sum",
"tensorflow.cast",
"tensorflow.nn.sigmoid_cross_entropy_with_logits",
"tensorflow.nn.l2_loss",
"tensorflow.train.Adam... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
vogelta/vogelta.github.io | [
"24c354db961e5e620557c8f4d4d960bea05f3f7d"
] | [
"Parameters/MNIST_MinCOOL.py"
] | [
"from __future__ import absolute_import\nfrom __future__ import division\nfrom __future__ import print_function\n\nimport tensorflow as tf\nfrom data_wrappers import mnist_wrapper\nfrom utils import Layer, cool_layer\n\n\ndata_wrap = mnist_wrapper\nimage_dim = [28,28,1]\nn_classes = 10\n\nbatch_size = 50\nn_batches... | [
[
"tensorflow.constant_initializer",
"tensorflow.truncated_normal_initializer"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.4",
"1.5",
"1.7",
"0.12",
"1.0",
"1.2"
]
}
] |
gem763/stockpricer | [
"f391617725897f5ad47e2e8cf1cfe22ffd657107"
] | [
"stockpricer/model.py"
] | [
"import numpy as np\nimport pandas as pd\n\nfrom sklearn.naive_bayes import GaussianNB, MultinomialNB\nfrom sklearn.svm import SVC\nfrom sklearn.neighbors import KNeighborsClassifier\nfrom sklearn.decomposition import PCA, KernelPCA, FastICA\nfrom sklearn.linear_model import LogisticRegression\nfrom sklearn.ensembl... | [
[
"numpy.log",
"pandas.DataFrame",
"sklearn.preprocessing.StandardScaler",
"numpy.exp",
"sklearn.decomposition.PCA"
]
] | [
{
"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": []
}
] |
ComicShrimp/scikit-image-filters | [
"973ef190bf4dc74c8c9a89ffe8092d94d51d4bbd"
] | [
"src/niblack_sauvola_thresholding.py"
] | [
"import matplotlib\nimport matplotlib.pyplot as plt\n\nfrom skimage.data import page\nfrom skimage.filters import threshold_otsu, threshold_niblack, threshold_sauvola\nfrom skimage import io\nfrom skimage.color import rgb2gray\n\n\nimage = io.imread(\"./images/book.jpg\")\nimage_in_greyscale = rgb2gray(image)\n\nma... | [
[
"matplotlib.pyplot.imshow",
"matplotlib.pyplot.title",
"matplotlib.pyplot.subplot",
"matplotlib.pyplot.axis",
"matplotlib.pyplot.show",
"matplotlib.pyplot.figure"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
nkoep/matplotlib | [
"6ed04252994443a4cecf95f0da0efedb6d514b38",
"6ed04252994443a4cecf95f0da0efedb6d514b38",
"6ed04252994443a4cecf95f0da0efedb6d514b38",
"c9898ea9a30c67c579ab27cd61b68e2abae0fb0e"
] | [
"examples/pylab_examples/line_collection.py",
"examples/pylab_examples/data_helper.py",
"examples/pylab_examples/gradient_bar.py",
"examples/specialty_plots/topographic_hillshading.py"
] | [
"import matplotlib.pyplot as plt\nfrom matplotlib.collections import LineCollection\nfrom matplotlib.colors import colorConverter\n\nimport numpy as np\n\n# In order to efficiently plot many lines in a single set of axes,\n# Matplotlib has the ability to add the lines all at once. Here is a\n# simple example showin... | [
[
"numpy.arange",
"matplotlib.pyplot.axes",
"matplotlib.colors.colorConverter.to_rgba",
"numpy.ma.masked_where",
"numpy.zeros",
"matplotlib.pyplot.show"
],
[
"matplotlib.cbook.get_sample_data",
"numpy.array",
"numpy.resize"
],
[
"numpy.arange",
"matplotlib.pyplot.... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
... |
flowersteam/mlagents-environments | [
"140415b209460d5c8c2e57dc91f874c24de6d6cb"
] | [
"ml-agents/mlagents/envs/brain.py"
] | [
"import logging\nimport numpy as np\nimport io\nimport orjson\n\nfrom typing import Dict\nfrom PIL import Image\n\nlogger = logging.getLogger(\"mlagents.envs\")\n\n\nclass BrainInfo:\n def __init__(self, visual_observation, vector_observation, text_observations, info_dict, memory=None, reward=None, agents=None, ... | [
[
"numpy.reshape",
"numpy.isnan",
"numpy.mean",
"numpy.array",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ArnaudHemmerle/FluoJupyter | [
"ed348c04604d828b9e40a86d4427d9fc2bcc4534"
] | [
"lib/extraction/XRF.py"
] | [
"'''\nModule for extracting, plotting, and saving an XRF scan.\n'''\nimport os\nimport sys\nimport io\nfrom contextlib import redirect_stdout\nimport matplotlib.pyplot as plt\nfrom matplotlib import colors\nimport numpy as np\nfrom lib.extraction import PyNexus as PN\n\n# Define colors for prints\n_RED='\\x1b[31;01... | [
[
"matplotlib.pyplot.gca",
"matplotlib.colors.LogNorm",
"numpy.isnan",
"numpy.arange",
"numpy.isclose",
"numpy.genfromtxt",
"numpy.array",
"numpy.zeros",
"numpy.sum",
"matplotlib.pyplot.show",
"matplotlib.pyplot.figure"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
siraferradans/scikit-image-temp | [
"db3b97aec1824d8f49116b8918ff95639af441d4",
"db3b97aec1824d8f49116b8918ff95639af441d4"
] | [
"skimage/color/colorconv.py",
"doc/examples/filters/plot_gabor_vs_morlet.py"
] | [
"#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n\n\"\"\"Functions for converting between color spaces.\n\nThe \"central\" color space in this module is RGB, more specifically the linear\nsRGB color space using D65 as a white-point [1]_. This represents a\nstandard monitor (w/o gamma correction). For a good FAQ on... | [
[
"numpy.dot",
"numpy.asarray",
"numpy.squeeze",
"numpy.concatenate",
"numpy.seterr",
"numpy.arctan2",
"numpy.any",
"numpy.cross",
"numpy.exp",
"numpy.where",
"numpy.hypot",
"numpy.ones_like",
"numpy.reshape",
"numpy.empty_like",
"numpy.finfo",
"numpy.... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [
"0.13",
"0.12",
"0.14",
"0.15"
],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [
"1.7",
"1.0",
"0.10",
"1.2",
"0.14",
"0.19... |
maxhutch/packtets | [
"eba7d3d354da9bef50bfdbc48e6934c4e17f165c"
] | [
"packtets/utils/vis.py"
] | [
"try:\n import mpl_toolkits.mplot3d as a3\n import matplotlib.pyplot as plt\nexcept ImportError:\n pass\n\ndef plot_packing(packing, box=None, use_symmetry=False):\n \"\"\"Plot packing within box\"\"\"\n ax = a3.Axes3D(plt.figure(10))\n\n if box is not None:\n bounding = [box.vx, box.vy, bo... | [
[
"matplotlib.pyplot.figure"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
hugorichard/fmralign | [
"b8990cc22204591399b731460375b99254b38527",
"b8990cc22204591399b731460375b99254b38527"
] | [
"fmralign/metrics.py",
"fmralign/fetch_example_data.py"
] | [
"# -*- coding: utf-8 -*-\nimport numpy as np\nfrom scipy.stats import pearsonr\nfrom sklearn.metrics import r2_score\n\n\ndef score_voxelwise(ground_truth, prediction, masker, loss,\n multioutput='raw_values'):\n \"\"\"\n Calculates loss function for predicted, ground truth\n arrays. Sup... | [
[
"numpy.maximum",
"sklearn.metrics.r2_score",
"scipy.stats.pearsonr",
"numpy.ones",
"numpy.mean",
"numpy.average"
],
[
"pandas.read_csv"
]
] | [
{
"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"
... |
KristinaUlicna/NanoPush | [
"7d9be1ea5b0c686920b33c2278fb9a7b30c0f7d0"
] | [
"NanoPush/Function - Alignment (my initial approach).py"
] | [
"# General directory for HDF5 files:\n\"/Users/kristinaulicna/Documents/Rotation_1_Rob_Lowe/Nanopore sequences(fast5)/...\"\n\n\n# UNIVERSAL FUNCTION FOR THE ENTIRE ANALYSIS OF ALL (+ve or -ve) HDF5 FILES:\n\ndef AlignQueToRef(HDF5_file):\n \"\"\"Insert file name into \"\" with a full directory (from /Users/...)... | [
[
"numpy.array",
"numpy.mean"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
chidperi/deep_learning_python | [
"d76b709754b5aa2b333fe3c41f499349af9b596b"
] | [
"NNActivations.py"
] | [
"# File name: NNActivations\n# Copyright 2017 Chidambaram Periakaruppan\n# Licensed under the Apache License, Version 2.0 (the \"License\"); you may not use this file except in compliance with the\n# License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0\n\nimport numpy as np\n\... | [
[
"numpy.exp",
"numpy.maximum",
"numpy.multiply"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
marvahm12/PyEng | [
"4a4bf8f9d3bcd242243e91d86a598e19c7841601"
] | [
"Image_Video/image_video_newcode/blur_new.py"
] | [
"import cv2\nimport sys\nimport matplotlib.pyplot as plt\n\n\ndef blur_display(infile, nogui=False):\n # The first argument is the image\n image = cv2.imread(infile)\n\n #conver to grayscale\n gray_image = cv2.cvtColor(image, cv2.COLOR_BGR2GRAY)\n\n #blur it\n blurred_image = cv2.GaussianBlur(imag... | [
[
"matplotlib.pyplot.savefig"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
IBM/Simultaneous-diagonalization | [
"385545401395a2e07f109441db4751a5dcf8f0a4"
] | [
"verify_diag_y.py"
] | [
"# Copyright 2022 IBM Inc. All rights reserved\n# SPDX-License-Identifier: Apache2.0\n\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2... | [
[
"numpy.asarray",
"numpy.linalg.eig",
"numpy.exp",
"numpy.linalg.norm"
]
] | [
{
"matplotlib": [],
"numpy": [
"1.10",
"1.12",
"1.11",
"1.19",
"1.24",
"1.13",
"1.16",
"1.9",
"1.18",
"1.23",
"1.21",
"1.22",
"1.20",
"1.7",
"1.15",
"1.14",
"1.17",
"1.8"
],
"pandas": [],
... |
leonardoedgar/raveutils | [
"b4f355249926ada87d863d8f25f2f6ae5d0c0a53"
] | [
"tests/test_planning.py"
] | [
"#! /usr/bin/env python\nimport unittest\nimport numpy as np\nimport openravepy as orpy\n# Tested package\nimport raveutils as ru\n\n\nclass Test_planning(unittest.TestCase):\n @classmethod\n def setUpClass(cls):\n np.set_printoptions(precision=6, suppress=True)\n scene = 'robots/puma.robot.xml'\n env = ... | [
[
"numpy.random.seed",
"numpy.set_printoptions",
"numpy.linalg.norm",
"numpy.deg2rad",
"numpy.random.rand",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
srikar1001/mymmdetection3d | [
"01592d4caeeb6b29df965533437d19b62b23da61"
] | [
"mmdet3d/datasets/pipelines/loading.py"
] | [
"import mmcv\nimport numpy as np\n\nfrom mmdet3d.core.points import BasePoints, get_points_type\nfrom mmdet.datasets.builder import PIPELINES\nfrom mmdet.datasets.pipelines import LoadAnnotations\n\n\n@PIPELINES.register_module()\nclass LoadMultiViewImageFromFiles(object):\n \"\"\"Load multi channel images from ... | [
[
"numpy.fromfile",
"numpy.expand_dims",
"numpy.abs",
"numpy.arange",
"numpy.percentile",
"numpy.ones",
"numpy.frombuffer",
"numpy.copy",
"numpy.load",
"numpy.array",
"numpy.logical_and",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
AmazingDD/IF4RecSys | [
"91b93fa53e7d9b8f5cb78afcd413ad53fe7f16ad"
] | [
"src/scalability/offline.py"
] | [
"import pickle\r\nimport pandas as pd\r\nfrom surprise import SVD, Reader, Dataset\r\n\r\nprint('Now offline-train Amazon')\r\ndf = pd.read_csv('./exp_data/amazon_exp.csv')\r\n\r\nreader = Reader()\r\ndata = Dataset.load_from_df(\r\n df=df[['user_id', 'item_id', 'rating']], reader=reader, rating_scale=(1, 5))\r\... | [
[
"pandas.read_csv"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
hadivafaii/network-portrait-divergence | [
"b6fdfbb607ffadbd60dccc2f7ae306351611a1a4"
] | [
"example_use.py"
] | [
"#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n\n# example_use.py\n# Jim Bagrow\n# Last Modified: 2018-04-22\n\nimport sys, os\nimport itertools\nimport networkx as nx\nimport numpy as np\nfrom portrait_divergence import portrait_divergence\n\n\n# make n ER graphs and n BA graphs:\nn = 10\nlist_ER = [ nx.erdos_re... | [
[
"matplotlib.pyplot.legend",
"matplotlib.pyplot.tight_layout",
"matplotlib.pyplot.xlabel",
"matplotlib.pyplot.show",
"matplotlib.pyplot.hist",
"matplotlib.pyplot.ylabel"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Lee-zix/MARLPaR | [
"79269139709ade3d7299eef91cfd6d19bb9e33b3"
] | [
"code/model/trainer.py"
] | [
"from __future__ import absolute_import\nfrom __future__ import division\nfrom tqdm import tqdm\nimport json\nimport time\nimport os\nimport logging\nimport numpy as np\nimport tensorflow as tf\nfrom code.model.agent import Agent\nfrom code.options import read_options\nfrom code.model.environment import env\nimport... | [
[
"tensorflow.control_dependencies",
"tensorflow.stack",
"numpy.mean",
"tensorflow.train.AdamOptimizer",
"tensorflow.Variable",
"numpy.reshape",
"numpy.arange",
"tensorflow.nn.moments",
"tensorflow.gradients",
"numpy.stack",
"tensorflow.train.exponential_decay",
"tens... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [
"0.13",
"0.14",
"0.15",
"0.19",
"0.18",
"1.2",
"0.12",
"1.0",
"0.17",
"0.16"
],
"tensorflow": [
"1.10"
]
}
] |
ybbaigo/tensor2tensor | [
"211c8245bb4303a6a2519fa570ae170b26c99801"
] | [
"tensor2tensor/layers/common_attention_test.py"
] | [
"# coding=utf-8\n# Copyright 2019 The Tensor2Tensor 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 requir... | [
[
"numpy.dot",
"tensorflow.contrib.eager.run_test_in_graph_and_eager_modes",
"tensorflow.zeros",
"tensorflow.compat.v1.enable_eager_execution",
"numpy.concatenate",
"numpy.exp",
"numpy.pad",
"numpy.reshape",
"tensorflow.gradients",
"tensorflow.test.main",
"tensorflow.to_f... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.4",
"1.5",
"1.7",
"0.12",
"1.0",
"1.2"
]
}
] |
jaggernaut007/margipose-1 | [
"ae0580cb7b3b41c21965cd32e280d2af0e8cf2c3"
] | [
"margipose/bin/hyperparam_search.py"
] | [
"#!/usr/bin/env python3\n\n\"\"\"Search for good training hyperparameters.\n\nThis code runs the LR range test proposed in \"Cyclical Learning Rates for Training Neural Networks\"\nby Leslie N. Smith.\n\"\"\"\n\nimport json\nfrom os import path, environ\n\nimport numpy as np\nimport plotly.graph_objs as go\nimport ... | [
[
"numpy.geomspace"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
mwoedlinger/compression | [
"387742e6efaa85ddf85510c461a14e1a33125404"
] | [
"test.py"
] | [
"import os\nimport argparse\nfrom model import *\nimport torch\nimport torch.optim as optim\nfrom torch.utils.data import DataLoader\nimport json\nimport time\nfrom datasets import Datasets, TestKodakDataset\nfrom torch.utils.tensorboard import SummaryWriter\nfrom Meter import AverageMeter\ntorch.backends.cudnn.ena... | [
[
"torch.mean",
"torch.manual_seed",
"torch.utils.data.DataLoader",
"torch.no_grad",
"torch.log",
"torch.device"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
DVSimon/XGB-SF-Crime-Categorization | [
"5eb2a0a8f01abcf1a117116f7ee834209f76ca85"
] | [
"XGB Source Code/Central.py"
] | [
"\n# coding: utf-8\n\n# In[1]:\n\n\n#libraries\nimport pandas as pd\nimport numpy as np\nfrom numpy import column_stack\nfrom xgboost import XGBClassifier\nfrom sklearn.preprocessing import LabelEncoder\nfrom sklearn.preprocessing import OneHotEncoder\nfrom sklearn.model_selection import StratifiedKFold\nfrom sklea... | [
[
"pandas.read_csv",
"sklearn.model_selection.RandomizedSearchCV",
"sklearn.preprocessing.OneHotEncoder",
"sklearn.model_selection.train_test_split",
"scipy.sparse.csr_matrix",
"sklearn.model_selection.StratifiedKFold",
"pandas.DataFrame",
"sklearn.metrics.f1_score.append",
"scip... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.3",
"1.1",
"1.5",
"1.2"
],
"scipy": [],
"tensorflow": []
}
] |
SCAuFish/GraphGym | [
"85db2957e7aa406ee42ae5260092939fd0f67bab"
] | [
"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": []
}
] |
LEO1222/DMAT_test | [
"6fee58fc811922bcdc6c8bd380a7f9d1acd4b817"
] | [
"Aplan.py"
] | [
"#!/usr/bin/env python3\r\nimport mhi.pscad\r\nimport logging\r\nimport mhi.pscad.handler\r\nimport os, openpyxl\r\nimport pandas as pd\r\n\r\n\r\nclass BuildEventHandler(mhi.pscad.handler.BuildEvent):\r\n\r\n def __init__(self):\r\n super().__init__()\r\n self._start = {}\r\n\r\n def _build_eve... | [
[
"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": []
}
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.