repo_name stringlengths 6 130 | hexsha list | file_path list | code list | apis list | possible_versions list |
|---|---|---|---|---|---|
ChenChunShenG19/PyTorch-StackGAN | [
"1aadc6488aafa4aaf3a883667215f4684a684f71"
] | [
"src/trainer.py"
] | [
"from __future__ import print_function\nfrom six.moves import range\nfrom PIL import Image\n\nimport torch.backends.cudnn as cudnn\nimport torch\nimport torch.nn as nn\nfrom torch.autograd import Variable\nimport torch.optim as optim\nimport os\nimport time\n\nimport numpy as np\nimport torchfile\n\nfrom miscc.conf... | [
[
"torch.optim.Adam",
"torch.utils.tensorboard.FileWriter",
"numpy.minimum",
"torch.cuda.set_device",
"torch.load",
"torch.nn.parallel.data_parallel",
"torch.utils.tensorboard.summary.scalar",
"numpy.concatenate",
"torch.FloatTensor",
"numpy.transpose",
"torch.autograd.Va... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Bhaskers-Blu-Org2/PDP-Solver | [
"e5fa96802500f8e38525a47e1276497cba08b835"
] | [
"src/satyr.py"
] | [
"#!/usr/bin/env python3\n\"\"\"\nMain script to run a trained PDP solver against a test dataset.\n\"\"\"\n\n# Copyright (c) Microsoft. All rights reserved.\n# Licensed under the MIT license. See LICENSE.md file\n# in the project root for full license information.\n\nimport argparse\nimport yaml, os, logging, sys\ni... | [
[
"torch.manual_seed",
"numpy.random.seed"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
rudsonramon/machine_learning_udacity_ud120-projects | [
"b3254e3b053c84283a779005d3dcc4f84bfae4b5"
] | [
"svm/svm_author_id.py"
] | [
"#!/usr/bin/python\n\n\"\"\" \n This is the code to accompany the Lesson 2 (SVM) mini-project.\n\n Use a SVM to identify emails from the Enron corpus by their authors: \n Sara has label 0\n Chris has label 1\n\"\"\"\n \nimport sys\nfrom time import time\nsys.path.append(\"../tools/\")\nimport matp... | [
[
"sklearn.svm.SVC",
"sklearn.metrics.accuracy_score"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
gokhankuscu/CNN-layer-reuse | [
"1dd8d42bf58442c9530dd660fabe054d434008ed"
] | [
"models/mobilenet.py"
] | [
"'''MobileNet in PyTorch.\n\nSee the paper \"MobileNets: Efficient Convolutional Neural Networks for Mobile Vision Applications\" for more details.\n'''\nimport torch\nimport torch.nn as nn\nimport torch.nn.functional as F\n\n\ndef conv_bn(inp, oup, stride):\n return nn.Sequential(\n nn.Conv2d(inp, oup, k... | [
[
"torch.nn.Sequential",
"torch.nn.Dropout",
"torch.randn",
"torch.nn.Conv2d",
"torch.nn.Linear",
"torch.nn.BatchNorm2d",
"torch.nn.ReLU"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ilyankou/leeds-gis-python-practicals | [
"0d861ba88fe832201665353ff0afcac972e4b2e2"
] | [
"model/__main__.py"
] | [
"import random\nimport operator\nimport csv\nimport sys\n\nimport tkinter\nimport requests\nimport bs4\n\nimport matplotlib\nmatplotlib.use('TkAgg')\nimport matplotlib.pyplot\nimport matplotlib.animation\n\nimport agentframework\n\n\ndef total_stored(agents):\n \"\"\"Calculate total stored by all agents and append... | [
[
"matplotlib.pyplot.imshow",
"matplotlib.pyplot.scatter",
"matplotlib.use",
"matplotlib.pyplot.figure",
"matplotlib.animation.FuncAnimation",
"matplotlib.backends.backend_tkagg.FigureCanvasTkAgg"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
rdocking/bcbio-nextgen | [
"858c4e02dbf0b03418a51741d62f7ab2dbcc8431"
] | [
"bcbio/qc/multiqc.py"
] | [
"\"\"\"High level summaries of samples and programs with MultiQC.\n\nhttps://github.com/ewels/MultiQC\n\"\"\"\nimport collections\nimport glob\nimport io\nimport json\nimport mimetypes\nimport os\nimport pandas as pd\nimport shutil\nimport numpy as np\nfrom collections import OrderedDict\n\nimport pybedtools\nimpor... | [
[
"numpy.median",
"pandas.read_csv",
"pandas.DataFrame"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.3",
"1.1",
"1.5",
"1.2"
],
"scipy": [],
"tensorflow": []
}
] |
csukuangfj/lhotse | [
"9b12055ca75718914c5457b33e498d1c8e8b86d8"
] | [
"lhotse/dataset/vis.py"
] | [
"from typing import Any, Mapping\n\n\ndef plot_batch(batch: Mapping[str, Any], supervisions: bool = True, text=True):\n import matplotlib.pyplot as plt\n\n batch_size = _get_one_of(batch, 'features', 'audio', 'inputs').shape[0]\n fig, axes = plt.subplots(batch_size, figsize=(16, batch_size), sharex=True)\n... | [
[
"matplotlib.pyplot.subplots"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
WeChatCV/up-detr | [
"1d953f2c3c9e3343dea4fb128046488869f87709"
] | [
"datasets/selfdet.py"
] | [
"# ------------------------------------------------------------------------\n# UP-DETR\n# Copyright (c) Tencent, Inc. and its affiliates. All Rights Reserved.\n# ------------------------------------------------------------------------\nfrom torch.utils.data import Dataset\nimport os\nfrom PIL import Image\nimport t... | [
[
"torch.stack",
"torch.tensor",
"numpy.random.randint"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
LukePeltier/cassiopeia | [
"3abdc3e6aab69996344a05da6212f83070439dd0"
] | [
"cassiopeia/core/match.py"
] | [
"import functools\nimport arrow\nimport datetime\nimport itertools\nfrom collections import Counter\nfrom typing import List, Dict, Union, Generator\n\nfrom datapipelines import NotFoundError\nfrom merakicommons.cache import lazy, lazy_property\nfrom merakicommons.container import searchable, SearchableList, Search... | [
[
"matplotlib.pyplot.show",
"matplotlib.pyplot.axis",
"matplotlib.pyplot.scatter",
"matplotlib.pyplot.figure"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
bootml/agent | [
"84235db931d6e4ef956962961c619994898ebdd5"
] | [
"utilities/architectures/mlp.py"
] | [
"#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\nfrom .architecture import Architecture\n\n__author__ = 'cnheider'\n\n'''\nDescription: Multi Layer Perceptron\nAuthor: Christian Heider Nielsen\n'''\nimport torch\nfrom torch import nn, Tensor\nfrom torch.nn import functional as F\n\n\nclass MLP(Architecture):\n ''... | [
[
"torch.nn.Linear",
"torch.nn.functional.softmax",
"torch.cat",
"torch.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
huynhngoc/head-neck-analysis | [
"f723e81509545c13c65c88b41d8b0465a35b017e"
] | [
"run_test.py"
] | [
"\"\"\"\nExample of running a single experiment of unet in the head and neck data.\nThe json config of the main model is 'examples/json/unet-sample-config.json'\nAll experiment outputs are stored in '../../hn_perf/logs'.\nAfter running 3 epochs, the performance of the training process can be accessed\nas log file a... | [
[
"tensorflow.config.LogicalDeviceConfiguration",
"tensorflow.config.experimental.list_logical_devices",
"tensorflow.config.list_physical_devices"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
TripleRD/Pulser | [
"7405d8cd7463782891cbbf40335f163dc8f284cc"
] | [
"pulser/simulation/simulation.py"
] | [
"# Copyright 2020 Pulser Development 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... | [
[
"numpy.dot",
"numpy.logical_not",
"numpy.sqrt",
"numpy.min",
"numpy.arange",
"numpy.linalg.norm",
"matplotlib.pyplot.savefig",
"numpy.ones",
"numpy.sort",
"numpy.max",
"numpy.append",
"numpy.random.normal",
"numpy.any",
"numpy.insert",
"numpy.exp",
"... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
artemyk/pandas | [
"a3cca397fd07a7ddd607d892aee9e307413c9856"
] | [
"pandas/core/ops.py"
] | [
"\"\"\"\nArithmetic operations for PandasObjects\n\nThis is not a public API.\n\"\"\"\n# necessary to enforce truediv in Python 2.X\nfrom __future__ import division\nimport operator\nimport numpy as np\nimport pandas as pd\nfrom pandas import compat, lib, tslib\nimport pandas.index as _index\nfrom pandas.util.decor... | [
[
"pandas.core.common.is_list_like",
"pandas.Series",
"pandas.core.common.is_integer_dtype",
"pandas.core.common.is_categorical_dtype",
"pandas.lib.scalar_compare",
"numpy.asarray",
"pandas.tslib.array_to_datetime",
"pandas.core.common.is_bool_dtype",
"pandas.core.common.bind_met... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"0.19"
],
"scipy": [],
"tensorflow": []
}
] |
aldakata/ClassConditionalC2D | [
"dd73e1d4d5f0f82438340211e3c479dbd16b8ffc"
] | [
"main_cifar.py"
] | [
"from __future__ import print_function\n\nimport argparse\nimport os, sys\nimport tables\nimport random\n\nimport numpy as np\nimport torch.backends.cudnn as cudnn\nimport torch.optim as optim\nfrom torchvision import models\n\nfrom dataloaders import dataloader_cifar as dataloader\nfrom models import bit_models\nf... | [
[
"numpy.load",
"numpy.clip"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
cbc-group/stitching | [
"f1baca2f34394e072c2f5c5787882b108d1b7c27"
] | [
"stitching/reader.py"
] | [
"import glob\r\nimport logging\r\nimport os\r\nimport re\r\n\r\nimport pandas as pd\r\nfrom re import X\r\n\r\n__all__ = [\"filename_to_tile\", \"read_script\", \"read_settings\"]\r\n\r\nlogger = logging.getLogger(__name__)\r\n\r\n\r\ndef read_script(script_path):\r\n # summary section\r\n df = pd.read_csv(sc... | [
[
"pandas.read_csv"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
bgyori/pyobo | [
"f199f62f65fc7faff307b56f979a369202c8ad33"
] | [
"src/pyobo/sources/hgncgenefamily.py"
] | [
"# -*- coding: utf-8 -*-\n\n\"\"\"Converter for HGNC Gene Families.\"\"\"\n\nfrom collections import defaultdict\nfrom typing import Iterable, List, Mapping\n\nimport pandas as pd\nfrom tqdm import tqdm\n\nfrom ..path_utils import ensure_path\nfrom ..struct import Obo, Reference, Synonym, SynonymTypeDef, Term, from... | [
[
"pandas.notna",
"pandas.isna",
"pandas.read_csv"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.3",
"1.1",
"1.5",
"1.2"
],
"scipy": [],
"tensorflow": []
}
] |
sanketvmehta/continual-learning | [
"9945f84c13a9f63831a11568f5b4a2e1cd6cc96b"
] | [
"_compare_taskID.py"
] | [
"#!/usr/bin/env python3\nimport argparse\nimport os\nimport numpy as np\nfrom param_stamp import get_param_stamp_from_args\nimport visual_plt\nimport main\nfrom param_values import set_default_values\n\n\ndescription = 'Compare two ways of using task-ID info (with different CL strategies) on permuted / split MNIST.... | [
[
"numpy.var",
"numpy.mean"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
ivanliu1989/pandas | [
"5bbe99e7cd26651e9ecb4ab59a4cdcd335535874"
] | [
"pandas/tools/plotting.py"
] | [
"# being a bit too dynamic\n# pylint: disable=E1101\nimport datetime\nimport warnings\nimport re\nfrom collections import namedtuple\nfrom contextlib import contextmanager\nfrom distutils.version import LooseVersion\n\nimport numpy as np\n\nfrom pandas.util.decorators import cache_readonly, deprecate_kwarg\nimport ... | [
[
"pandas.core.common.is_list_like",
"pandas.util.decorators.deprecate_kwarg",
"numpy.expand_dims",
"numpy.sqrt",
"numpy.linspace",
"numpy.asarray",
"matplotlib.ticker.AutoLocator",
"pandas.tseries.frequencies.get_freq",
"numpy.max",
"pandas.compat.map",
"matplotlib.artis... | [
{
"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"... |
eman/censusacs | [
"602c98d29c83462761f436c9cab6872e54079f6a"
] | [
"censusacs.py"
] | [
"import json\nimport os\n\nimport pandas as pd\nimport requests\n\nACS_ENDPOINT = \"https://api.census.gov/data/{year}/{program}/{frequency}\"\nVARIABLES = {\n \"NAME\": \"geography_name\",\n \"B01001_001E\": \"total_population\",\n \"B19013_001E\": \"median_household_income\",\n \"B11011_001E\": \"tota... | [
[
"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": []
}
] |
rushic24/Multi-Language-RTVC | [
"f61f79ea119d10c876bd69b825f5cb84c9b66ac8"
] | [
"mlrtvc/src/core/encoder/data_objects/speaker_batch.py"
] | [
"import numpy as np\nfrom typing import List\nfrom core.encoder.data_objects.speaker import Speaker\n\n\nclass SpeakerBatch:\n def __init__(\n self, speakers: List[Speaker], utterances_per_speaker: int, n_frames: int\n ):\n self.speakers = speakers\n self.partials = {\n s: s.ra... | [
[
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
crizCraig/baselines | [
"4a8219c73282f459c75b7b2a5284b7215fa336e5",
"4a8219c73282f459c75b7b2a5284b7215fa336e5"
] | [
"baselines/acktr/utils.py",
"baselines/acktr/kfac_utils.py"
] | [
"import os\nimport numpy as np\nimport tensorflow as tf\nimport baselines.common.tf_util as U\nfrom collections import deque\n\ndef sample(logits):\n noise = tf.random_uniform(tf.shape(logits))\n return tf.argmax(logits - tf.log(-tf.log(noise)), 1)\n\ndef std(x):\n mean = tf.reduce_mean(x)\n var = tf.re... | [
[
"tensorflow.reduce_sum",
"tensorflow.nn.l2_loss",
"numpy.mean",
"tensorflow.nn.conv2d",
"numpy.linalg.svd",
"numpy.reshape",
"tensorflow.square",
"tensorflow.trainable_variables",
"tensorflow.matmul",
"tensorflow.shape",
"tensorflow.exp",
"tensorflow.reduce_max",
... | [
{
"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... |
pasin30055/planning-evaluation-framework | [
"ba5fc3b553fee0b4f5beb50076ecaa7b634dac23"
] | [
"src/driver/experimental_trial.py"
] | [
"# Copyright 2021 The Private Cardinality Estimation Framework 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# Un... | [
[
"pandas.concat",
"pandas.read_csv",
"numpy.abs",
"numpy.random.seed",
"numpy.arange",
"pandas.DataFrame",
"numpy.mean",
"numpy.random.default_rng"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
JPchico/aiida-lammps | [
"8f618541784bbd6360efc653350570cf76398e83",
"8f618541784bbd6360efc653350570cf76398e83"
] | [
"aiida_lammps/calculations/lammps/combinate.py",
"conftest.py"
] | [
"# Not working with Aiida 1.0\n\nfrom aiida.common.exceptions import InputValidationError\nfrom aiida.orm import ArrayData, Dict\nfrom aiida_phonopy.common.raw_parsers import (\n get_force_constants,\n get_FORCE_SETS_txt,\n get_poscar_txt,\n)\nimport numpy as np\n\nfrom aiida_lammps.calculations.lammps imp... | [
[
"numpy.array",
"numpy.random.randint"
],
[
"numpy.dot"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
anajikadam17/nlp-dl-prework | [
"cc19eb08d08843a0c64a77032edd3c46c91d9629"
] | [
"PageRank/code.py"
] | [
"# --------------\n# Code starts here\n\nimport numpy as np\n\n# Code starts here\n\n# Adjacency matrix\nadj_mat = np.array([[0,0,0,0,0,0,1/3,0],\n [1/2,0,1/2,1/3,0,0,0,0],\n [1/2,0,0,0,0,0,0,0],\n [0,1,0,0,0,0,0,0],\n [0,0,1/2,1/3,0,0,1/3,0],\n... | [
[
"numpy.dot",
"numpy.linalg.eig",
"numpy.linalg.norm",
"numpy.ones",
"numpy.max",
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
solve-fx/fxdatalamda | [
"73fec613c78545cfcef7072eb4066085904cc1c8"
] | [
"lambda_ETL.py"
] | [
"import pandas as pd\nimport numpy as np\nfrom datetime import date, timedelta\n\ndef price_resampler(data, timeframe, timeframe_label):\n\n resampled_data = data.resample(timeframe).agg({'Open': 'first', \n 'High': 'max', \n ... | [
[
"pandas.to_datetime",
"numpy.where",
"pandas.read_csv",
"pandas.DateOffset"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
imwillhang/multimodal-healthcare | [
"4959fa1a8c99e23334c926b73202c944f1eda457"
] | [
"util/BatcherMassager.py"
] | [
"import dicom\nimport numpy as np\nfrom PIL import Image\nimport csv\nimport os\nfrom scipy.misc import imresize, imsave\nimport matplotlib.pyplot as plt\n\npathology_dict = {'MALIGNANT': 1, 'BENIGN': 0, 'BENIGN_WITHOUT_CALLBACK': 0}\nclass Batcher:\n def __init__(self, batch_sz, metadata, indices, mass_headers,... | [
[
"matplotlib.pyplot.imshow",
"scipy.misc.imresize",
"numpy.amax",
"numpy.take",
"numpy.amin",
"numpy.arange",
"numpy.asarray",
"numpy.load",
"numpy.save",
"numpy.std",
"numpy.ravel",
"matplotlib.pyplot.show",
"numpy.sum"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [
"0.13",
"0.14",
"0.15",
"1.0",
"0.19",
"0.18",
"1.2",
"0.12",
"0.10",
"0.17",
"0.16"
],
"tensorflow": []
}
] |
ProjectCaelus/DesignLiquidEngine | [
"a7e4a4f0146bbf0f056efc92a931a08ffff4f3a5"
] | [
"helpers/PropSim2/PropSimPython/helpers/n2o.py"
] | [
"# Nitrous-related helper methods for PropSimPython\n# Project Caelus, Aphlex 1C Engine\n# Liam West, Anya Mischel, & Jason Chen, 10 February, 2021\n\n\nimport numpy as np\nfrom scipy.interpolate import InterpolatedUnivariateSpline\nfrom classes import Struct\n\n\ndef n2o_properties(temp: int or float) -> Struct:\n... | [
[
"numpy.matlib.repmat",
"numpy.amax",
"scipy.interpolate.InterpolatedUnivariateSpline",
"numpy.linspace",
"numpy.meshgrid",
"numpy.multiply",
"numpy.sqrt",
"numpy.ones",
"numpy.argmax",
"numpy.interp",
"numpy.array",
"numpy.exp",
"numpy.zeros",
"numpy.divide"... | [
{
"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"... |
lukasz-starosta/imputation | [
"64a911a659c37ba415ebca0e21f7ae9f5ed2e2c5"
] | [
"methods/interpolate.py"
] | [
"from utils.extract import extract\nimport pandas as pd\n\ndef interpolate(filename):\n names, headers, numeric_data = extract(filename)\n row_length = len(numeric_data)\n column_length = len(numeric_data[0])\n df = pd.read_csv(filename)\n print(df)\n return df"
] | [
[
"pandas.read_csv"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
maayane/PhotoFit | [
"e5461bc50a9587ed0fe5d323f6b6bbea8aa968d5"
] | [
"PhotoFit/black_body_flux_density.py"
] | [
"\n\nimport astropy\nfrom astropy import constants as const\nimport math\nfrom . import distances_conversions\nfrom . import extinction\nimport numpy as np\nimport pdb\nimport pylab\n\n#def planck(wav, T):\n# a=2*6.626070040e-34*(3e8)**2\n# b=6.626070040e-34*(3e8)/(wav*T*1.38064852e-23)\n# #a = 2*const.h.v... | [
[
"numpy.exp",
"numpy.shape",
"numpy.float64"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
madsbk/distributed | [
"2c5d2cf814f13b0efc0fb21acc890476158468da"
] | [
"distributed/dashboard/components/scheduler.py"
] | [
"from collections import defaultdict\nimport logging\nimport math\nfrom numbers import Number\nimport operator\nimport os\n\nfrom bokeh.layouts import column, row\nfrom bokeh.models import (\n ColumnDataSource,\n ColorBar,\n DataRange1d,\n HoverTool,\n ResetTool,\n PanTool,\n WheelZoomTool,\n ... | [
[
"numpy.array",
"numpy.histogram"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
karthikbhamidipati/image-classification-deeper-networks | [
"d6fececa08092a0b8af6fd01fe89485958e61c01",
"d6fececa08092a0b8af6fd01fe89485958e61c01"
] | [
"tests/test_metrics.py",
"model/predict.py"
] | [
"import unittest\n\nimport torch\n\nfrom model.metrics import Metrics\n\n\nclass TestMetrics(unittest.TestCase):\n def test_metrics_initialization(self):\n metrics = Metrics(2)\n self.assertEqual(metrics.asdict(), {'loss': 0.0, 'accuracy': 0.0,\n 'precisio... | [
[
"torch.Tensor",
"torch.tensor"
],
[
"torch.no_grad"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
xuyuluo/spreco | [
"e9c720fb0d8a9c59a0e83696d2b7efcdc90b2cc3"
] | [
"spreco/model/refine_net.py"
] | [
"from spreco.model import nn, utils\n\nimport tensorflow.compat.v1 as tf\ntf.disable_eager_execution()\nfrom tf_slim import add_arg_scope\nfrom tf_slim import arg_scope\n\n@add_arg_scope\ndef cond_crp_block(x, h, nr_filters, nr_stages, nonlinearity, normalizer, **kwargs):\n \"\"\"\n chained residual pool bloc... | [
[
"tensorflow.compat.v1.reduce_sum",
"tensorflow.compat.v1.make_template",
"tensorflow.compat.v1.disable_eager_execution",
"tensorflow.compat.v1.nn.avg_pool2d",
"tensorflow.compat.v1.image.resize"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
mbarylsk/puzzles | [
"e320a880062b6b6a6670bcd4379611f4feb43c21"
] | [
"architect/architect.py"
] | [
"#\n# Copyright 2019, Marcin Barylski\n#\n# Permission is hereby granted, free of charge, to any person obtaining a copy of this software \n# and associated documentation files (the \"Software\"), to deal in the Software without restriction, \n# including without limitation the rights to use, copy, modify, merge, p... | [
[
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
omer11a/digital-gimbal | [
"3d193e8fc9548bab816ddb5f83fc1f1093e46e4c",
"3d193e8fc9548bab816ddb5f83fc1f1093e46e4c"
] | [
"utils.py",
"estimators.py"
] | [
"import numpy as np\nimport torch\nimport tensorboardX\nimport torchvision\n\nimport itertools\nimport collections\nimport os\nimport datetime\nimport shutil\nimport time\n\ndef forward_in_patches(model, x, patch_size, stride=1, *args, **kwargs):\n original_shape = x.shape\n x = x.reshape(-1, *original_shape[... | [
[
"torch.nn.functional.fold",
"torch.ones",
"torch.distributed.init_process_group",
"torch.cuda.set_device",
"torch.load",
"torch.reshape",
"torch.nn.Conv2d",
"torch.nn.ReLU",
"torch.stack",
"torch.nn.functional.unfold",
"torch.cuda.device_count",
"torch.nn.functional... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
NREL/VirtualEngineering | [
"f23f409132bc7965334db1e29d83502001ec4e09"
] | [
"EH_OpenFOAM/tests/RushtonNonReact/get_solids.py"
] | [
"# trace generated using paraview version 5.8.1\n#\n# To ensure correct image size when batch processing, please search \n# for and uncomment the line `# renderView*.ViewSize = [*,*]`\n\n#### import the simple module from the paraview\nimport numpy as np\nfrom paraview import simple as pv\nimport vtk.numpy_interfac... | [
[
"numpy.array",
"numpy.transpose"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
rubenvillegas/icml2017hierchvid | [
"9584bd3c97ed3e5869cf79e906c850deed098349",
"9584bd3c97ed3e5869cf79e906c850deed098349"
] | [
"imggen_src/model_analogy.py",
"imggen_src/alexnet.py"
] | [
"import os\nimport time\nfrom glob import glob\nimport tensorflow as tf\n\nfrom alexnet import alexnet\nfrom hg_stacked import hg_forward\nfrom ops import *\nfrom utils import *\n\n\nclass IMGGEN(object):\n def __init__(self,\n image_size=128,\n batch_size=32,\n c_dim=3,\n... | [
[
"tensorflow.train.get_checkpoint_state",
"tensorflow.concat",
"tensorflow.nn.sigmoid",
"tensorflow.reduce_mean",
"tensorflow.reshape",
"tensorflow.ones_like",
"tensorflow.placeholder",
"tensorflow.trainable_variables",
"tensorflow.zeros_like",
"tensorflow.variable_scope",
... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
fuzzy-string-matching/JaroWinkler | [
"736981e52c05b0815c5cb0de889f5cf51981f006"
] | [
"bench/benchmark_visualize.py"
] | [
"import pandas as pd\nimport matplotlib.pyplot as plt\n\ndf=pd.read_csv(\"results/jaro_winkler.csv\")\n\ndf *= 1000 * 1000\ndf[\"length\"] /= 1000 * 1000\n\n\nax=df.plot(x=\"length\")\n\nplt.xticks(list(range(0, 513, 64)))\n\nplt.title(\"Performance comparision of the \\nJaro-Winkler similarity in different librari... | [
[
"pandas.read_csv",
"matplotlib.pyplot.title",
"matplotlib.pyplot.grid",
"matplotlib.pyplot.xlabel",
"matplotlib.pyplot.show",
"matplotlib.pyplot.ylabel"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
Jacobvs/ML-Music-Analyzer | [
"00b694e26cee6ccddb9b727deca6288fda37f9b6"
] | [
"test.py"
] | [
"import os\nimport time\nimport librosa\nimport vampyhost\nimport numpy as np\nimport collections\nimport vamp.frames\nimport scipy.signal\nimport youtube_dl\nimport pygame, pygame.sndarray\nfrom vampyhost import load_plugin\nfrom keras.models import load_model\n#from matplotlib import pyplot as plt\nfrom music21 i... | [
[
"numpy.set_printoptions",
"numpy.array",
"numpy.resize",
"numpy.sin"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
mbercx/cage | [
"90f34135c251f438c8709fdd9e814a47f7aa12e1"
] | [
"cage/utils.py"
] | [
"# Encoding = utf-8\n\nimport numpy as np\nimport pymatgen.io.nwchem as nw\n\n\"\"\"\nA collection of utility methods for other modules.\n\n\"\"\"\n\n\ndef distance(coord1, coord2):\n \"\"\"\n Calculate the distance between two coordinates, defined by arrays.\n :param coord1:\n :param coord2:\n :retu... | [
[
"numpy.dot",
"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": [],
... |
dringeis/VP_rheologies | [
"5c4835eeb4bb3d15b481825ccc609580d67abf14"
] | [
"VP_rheology.py"
] | [
"#!/usr/bin python\nimport numpy as np\nfrom matplotlib.patches import Ellipse\nimport pylab as plt\nfrom mpl_toolkits.mplot3d import Axes3D\nimport copy\nfrom matplotlib.colors import SymLogNorm\nfrom math import copysign\n\n#import functions defining the VP rheologies\nfrom VP_rheology_functions import *\n\n# imp... | [
[
"numpy.nanstd",
"numpy.nanmedian",
"numpy.nanmean"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Tbabm/compare-mt | [
"e68b4b0f4d8682cc61558f8fbca2d380b534a107"
] | [
"compare_mt/bucketers.py"
] | [
"import sys\nimport itertools\nimport numpy as np\nfrom collections import defaultdict\n\nfrom compare_mt import corpus_utils\nfrom compare_mt import scorers\nfrom compare_mt import arg_utils\n\nclass Bucketer:\n\n def set_bucket_cutoffs(self, bucket_cutoffs, num_type='int'):\n self.bucket_cutoffs = bucket_cuto... | [
[
"numpy.random.choice",
"numpy.reshape",
"numpy.ceil",
"numpy.argsort",
"numpy.array",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
MartinKlevs/PyDMD | [
"2c50b775d00bf16b0f41d248040d884ee22e72c0"
] | [
"pydmd/mosesdmd.py"
] | [
"\"\"\"\r\nDerived module from dmdbase.py for higher order dmd.\r\n\r\nReference:\r\n- S. L Clainche, J. M. Vega, Higher Order Dynamic Mode Decomposition.\r\nJournal on Applied Dynamical Systems, 16(2), 882-925, 2017.\r\n\"\"\"\r\nfrom past.utils import old_div\r\nimport numpy as np\r\nimport scipy as sp\r\nfrom sc... | [
[
"numpy.diag",
"numpy.dot",
"numpy.log",
"numpy.linalg.solve",
"numpy.linalg.inv",
"numpy.linalg.eig",
"numpy.finfo",
"numpy.linalg.lstsq",
"numpy.meshgrid",
"numpy.zeros",
"numpy.vstack"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
giadarol/hellofrom | [
"18f4030dc35bd4a7f61f4417f6fdc649f6ed0211"
] | [
"tests/test_sqrts.py"
] | [
"import pypkgexample as pe\nimport numpy as np\n\ndef test_sqrt_python():\n assert np.max(\n pe.sqrt_array_python([1., 4., 9.])-\n - np.array([1., 2., 3.])) < 1e30\n\ndef test_sqrt_fortran():\n assert np.max(\n pe.sqrt_array_fortran([1., 4., 9.])-\n - np.array([1., 2.... | [
[
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
juliette-r/WarpX | [
"4974f07209ebc5e0578fc383057b4be383cdf318"
] | [
"Examples/Physics_applications/laser_acceleration/PICMI_inputs_laser_acceleration.py"
] | [
"#!/usr/bin/env python3\n#\nimport numpy as np\nfrom pywarpx import picmi\n#from warp import picmi\n\nconstants = picmi.constants\n\n##########################\n# physics parameters\n##########################\n\n# --- laser\n\nlaser_a0 = 4. # Normalized potential vector\nlaser_wavelength =... | [
[
"numpy.cos",
"numpy.sin"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
rohanharode/DRAW-Drug-Review-Analysis-Work | [
"89d8df82e1f0b67129727f16c32c038d64af35e2"
] | [
"ETL/Data_Aggregation/postgresql_db_creation.py"
] | [
"import psycopg2\nimport sqlalchemy\nimport pandas as pd\n\n\ndef postgres_table():\n engine = sqlalchemy.create_engine('postgresql://Shubham:@localhost:5432/draw')\n\n side_effect_df = pd.read_csv('../../side_effects.csv')\n\n side_effect_df.to_sql(\n name='drug_side_effects',\n con=engine,\... | [
[
"pandas.read_csv"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
xrcui/pytorch-CycleGAN-and-pix2pix | [
"07821024f73ab1eb4cb2d9866f55deb0910b6c7e"
] | [
"models/pix2pix_model.py"
] | [
"import torch\nfrom .base_model import BaseModel\nfrom . import networks\nimport copy\n\n\nclass Pix2PixModel(BaseModel):\n \"\"\" This class implements the pix2pix model, for learning a mapping from input images to output images given paired data.\n\n The model training requires '--dataset_mode aligned' data... | [
[
"torch.nn.L1Loss",
"torch.cat"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
nikolasmorshuis/advchain | [
"f24eaca30d78677c8a8c3eb08b28e767b6c08435"
] | [
"advchain/models/unet.py"
] | [
"# Created by cc215 at 17/03/19\n# Enter feature description here\n# Enter scenario name here\n# Enter steps here\n\nimport math\nimport torch.nn as nn\nfrom torch.autograd import Variable\nimport numpy as np\n# noqa\nfrom advchain.models.custom_layers import BatchInstanceNorm2d\nfrom advchain.models.custom_layers ... | [
[
"torch.nn.Upsample",
"torch.nn.Dropout2d"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
yf225/functorch | [
"4f0603569827ff0249c5f58f36d39b3fc6ee7103"
] | [
"test/discover_coverage.py"
] | [
"import torch\nimport copy\nfrom torch.testing._internal.common_methods_invocations import op_db\nfrom functorch_additional_op_db import additional_op_db\nfrom enum import Enum\nimport functorch._src.top_operators_github_usage as top_ops\nimport pprint\nimport unittest\nimport enum\nfrom functorch_lagging_op_db imp... | [
[
"torch.overrides.get_testing_overrides"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
jeetbhatt-sys/DataPreProcess | [
"b2ead76c9369ee4e18c60bf244d5c2582d6958b1"
] | [
"src/preJPProcess.py"
] | [
"# -*- coding: utf-8 -*-\r\n\"\"\"\r\nCreated on Wed Sep 1 14:16:15 2021\r\n\r\n@author: jbhatt\r\n\"\"\"\r\n\r\nfrom sklearn.preprocessing import StandardScaler\r\n\r\nclass preJPProcess():\r\n \r\n \"\"\"\r\n To initialize:\r\n \r\n e.g p = preProcess(dataFrame)\r\n \r\n A class used to... | [
[
"sklearn.preprocessing.StandardScaler"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Sargunan/Sargunan | [
"baf480213c8f3888bc4b168a767db00884982b8f"
] | [
"SignatureDataGenerator.py"
] | [
"import numpy as np\nnp.random.seed(1337) # for reproducibility\nfrom keras.preprocessing import image\nfrom scipy import linalg\nimport warnings\nfrom keras import backend as K\nimport getpass as gp\nimport random\nrandom.seed(1337)\n\nclass SignatureDataGenerator(object): \n \n def __init__(self, datase... | [
[
"numpy.dot",
"scipy.linalg.svd",
"numpy.sqrt",
"numpy.random.seed",
"numpy.random.choice",
"numpy.reshape",
"numpy.copy",
"numpy.std",
"numpy.mean",
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [
"0.13",
"0.14",
"0.15",
"0.12",
"0.10"
],
"tensorflow": []
}
] |
kewlbear/TensorFlowTTS | [
"c54b7b34091e6b1dd66587a70cd11fa11bb436f9"
] | [
"examples/tacotron2/decode_tacotron2.py"
] | [
"# -*- coding: utf-8 -*-\n# Copyright 2020 Minh Nguyen (@dathudeptrai)\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# Unl... | [
[
"tensorflow.math.equal",
"tensorflow.nn.sigmoid"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
JiaWeiTeh/BounceGame | [
"8a081bb66b03c71d4819e650e74b7425492d6c89"
] | [
"main.py"
] | [
"# -*- coding: utf-8 -*-\n\nimport matplotlib.pyplot as plt\nimport numpy as np\nimport matplotlib.animation as animation\nimport functions\n\n# =============================================================================\n# Initial setup\n# =========================================================================... | [
[
"numpy.sqrt",
"matplotlib.pyplot.axes",
"numpy.deg2rad",
"matplotlib.animation.FuncAnimation",
"matplotlib.pyplot.figure"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
9929105/KEEP | [
"a3e8b00f82367e13835e5137bd5c0eaa7c8d26d2"
] | [
"keep_backend/privacy/map.py"
] | [
"# -*-Python-*-\n###############################################################################\n#\n# File: map2d.py\n# RCS: $Header: $\n# Description: Transform 2d map coordinates providing Differential Privacy\n# Author: Staal Vinterbo\n# Created: Wed Mar 27 17:07:29 2013\n# Modified... | [
[
"numpy.reshape",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
bjuggler/lvrobi | [
"f7831b471058414d9ca383ab3729f3f6f26990c9"
] | [
"_lib/data_preparation.py"
] | [
"import os\nimport pandas as pd\nimport numpy as np\nimport gpxpy\n\nfrom tqdm import tqdm\nfrom .helper import distance\n\n\ndef remove_substandard_trips(dataframe):\n df = dataframe.copy()\n\n tripids4removing = df[(df['latitude'] == 0.0) | (df['latitude'].isna()) \n | (df['longit... | [
[
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
carpeanon/input_convex | [
"1d3ade6b2c926fb2b1d06d57870b820da21458f1"
] | [
"RL/src/main.py"
] | [
"# Code from Repo SimonRamstedt/ddpg\n# Heavily modified\n\nimport os\nimport pprint\n\nimport gym\nimport numpy as np\nimport tensorflow as tf\n\nimport agent\nimport normalized_env\nimport runtime_env\n\nflags = tf.app.flags\nFLAGS = flags.FLAGS\nflags.DEFINE_string('env', '', 'gym environment')\nflags.DEFINE_str... | [
[
"tensorflow.set_random_seed",
"numpy.mean",
"numpy.random.rand",
"numpy.random.seed"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10",
"1.12",
"1.4",
"1.13",
"1.5",
"1.7",
"0.12",
"1.0",
"1.2"
]
}
] |
aalikadic/transformer-location-prediction | [
"18a787794123a31cf99b22e80bb0ccf8c717e9ea"
] | [
"BERT_Quantized.py"
] | [
"import argparse\nimport baselineUtils\nimport torch\nimport torch.utils.data\nimport torch.nn as nn\nimport torch.nn.functional as F\nimport os\nimport time\nfrom transformer.batch import subsequent_mask\nfrom torch.optim import Adam,SGD,RMSprop,Adagrad\nfrom transformer.noam_opt import NoamOpt\nimport numpy as np... | [
[
"torch.nn.functional.softmax",
"torch.ones",
"torch.Tensor",
"torch.cat",
"torch.zeros",
"torch.utils.data.DataLoader",
"torch.tensor",
"numpy.concatenate",
"torch.nn.Linear",
"torch.no_grad",
"torch.utils.tensorboard.SummaryWriter",
"torch.cuda.is_available",
"... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
minhbau/PyCSP | [
"52ab6ebea39f047e9fac947d1a98b0826c52b4b4"
] | [
"PyCSP/ThermoKinetics.py"
] | [
"#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\n\"\"\"\n@author: Riccardo Malpica Galassi, Sapienza University, Roma, Italy\n\"\"\"\nimport numpy as np\nimport cantera as ct\n\n\nclass CanteraThermoKinetics(ct.Solution):\n def __init__(self, *args, **kwargs):\n super().__init__(*args, **kwargs) \n\n ... | [
[
"numpy.dot",
"numpy.sqrt",
"numpy.finfo",
"numpy.concatenate",
"numpy.outer",
"numpy.zeros",
"numpy.sum",
"numpy.vstack"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
deacona/the-ball-is-round | [
"8e91a72084d13d754deb82e4852fa37a86a77084"
] | [
"notebooks/output/intl_02_euro_2020_live.py"
] | [
"#!/usr/bin/env python\n# coding: utf-8\n\n# # Euro 2020 (2021) Predictions\n# \n# <!-- Written report for this analysis can be found [here](../reports/boro_01_market_value.md) -->\n\n# ## 1. Business Understanding\n# \n# * Determine Busines Objectives\n# * Situation Assessment\n# * Determine Data Mining Goal\n# * ... | [
[
"pandas.read_csv",
"pandas.notnull",
"pandas.isnull",
"matplotlib.pyplot.xticks",
"matplotlib.pyplot.show",
"matplotlib.pyplot.style.use"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
williamd4112/chainerrl | [
"a1fe94e95fb1577232b7cc5c45a7cd9bd4385090"
] | [
"chainerrl/distribution.py"
] | [
"from __future__ import division\nfrom __future__ import unicode_literals\nfrom __future__ import print_function\nfrom __future__ import absolute_import\nfrom builtins import * # NOQA\nfrom future import standard_library\nstandard_library.install_aliases() # NOQA\n\nfrom abc import ABCMeta\nfrom abc import abstra... | [
[
"numpy.log",
"numpy.argmax"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
bynoud/ray | [
"bfa06052828f83ab790e6b6bbfa5b56edb42b45e"
] | [
"python/ray/tests/test_advanced_3.py"
] | [
"# coding: utf-8\nimport glob\nimport logging\nimport os\nimport shutil\nimport json\nimport sys\nimport socket\nimport tempfile\nimport time\n\nimport numpy as np\nimport pickle\nimport pytest\n\nimport ray\nimport ray.ray_constants as ray_constants\nimport ray.cluster_utils\nimport ray.test_utils\nimport setproct... | [
[
"numpy.zeros",
"pandas.DataFrame",
"numpy.ones"
]
] | [
{
"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": []
}
] |
ehultee/VE-cauldrons | [
"52afe581c0ab32b93cee305e86e023c39e84ee69"
] | [
"ESkafta-2015/Skafta-ArcticDEM-transecting.py"
] | [
"# Reading in ArcticDEM, sampling transect across Skafta Cauldron\n# 4 Dec 2018 EHU\n# Edit 21 Feb 2019 - plot analytical elastic/viscoelastic\n# Edit 16 July - move functions to helper module\n\nimport numpy as np\nimport scipy.misc as scp\nfrom scipy import interpolate\nfrom scipy.ndimage import gaussian_filter\n... | [
[
"matplotlib.pyplot.legend",
"numpy.linspace",
"numpy.arange",
"matplotlib.pyplot.plot",
"matplotlib.pyplot.axes",
"scipy.interpolate.interp1d",
"numpy.mean",
"matplotlib.pyplot.fill_between",
"matplotlib.cm.get_cmap",
"scipy.interpolate.interp2d",
"numpy.ma.masked_where... | [
{
"matplotlib": [],
"numpy": [
"1.10",
"1.12",
"1.11",
"1.19",
"1.13",
"1.16",
"1.9",
"1.18",
"1.20",
"1.7",
"1.15",
"1.14",
"1.17",
"1.8"
],
"pandas": [],
"scipy": [
"0.13",
"1.6",
"0.14",
... |
minouei-kl/CBNetV2 | [
"3eeb20b1aaab101091164800e954df719c446bba"
] | [
"mmdet/models/detectors/two_stage.py"
] | [
"import warnings\n\nimport torch\n\nfrom ..builder import DETECTORS, build_backbone, build_head, build_neck\nfrom .base import BaseDetector\n\n\n@DETECTORS.register_module()\nclass _TwoStageDetector(BaseDetector):\n \"\"\"Base class for two-stage detectors.\n\n Two-stage detectors typically consisting of a re... | [
[
"torch.randn",
"torch._shape_as_tensor"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
federico-giannoni/pyramid-nested-ner | [
"cc5247a72a936219a11fcf53cf69b75b42f4b61c"
] | [
"pyramid_nested_ner/vectorizers/labels/__init__.py"
] | [
"from pyramid_nested_ner.utils.text import default_tokenizer\nfrom torch.nn.utils.rnn import pad_sequence\n\nimport torch\n\n\nclass PyramidLabelEncoder(object):\n \"\"\"\n Label encoder class responsible for transforming entity annotations\n into torch.Tensors. The `transform` API returns two tensors: one... | [
[
"torch.stack",
"torch.nn.utils.rnn.pad_sequence",
"torch.tensor"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
mwtoews/pandas | [
"896622165ce73f1c0fdf64e085fa80a3227bb51d"
] | [
"pandas/tests/extension/test_boolean.py"
] | [
"\"\"\"\nThis file contains a minimal set of tests for compliance with the extension\narray interface test suite, and should contain no other tests.\nThe test suite for the full functionality of the array is located in\n`pandas/tests/arrays/`.\n\nThe tests in this file are inherited from the BaseExtensionTests, and... | [
[
"pandas.util.testing.assert_extension_array_equal",
"pandas.util.testing.assert_numpy_array_equal",
"pandas.Series",
"numpy.isnan",
"pandas.factorize",
"pandas.array",
"pandas.Index",
"pandas.DataFrame",
"numpy.ones",
"pandas.util.testing.assert_almost_equal",
"pandas.u... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"1.4",
"1.1",
"1.5",
"1.2",
"1.0",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
timeeehd/modern-ai-course | [
"78d1dd8e0150b7455848991119bf60ff9a448274"
] | [
"lecture-09/exercise_DL_pcg/exercise_DL_pcg/example_sampling_random_levels.py"
] | [
"\"\"\"\nIn this example I show how to load the network,\nsample 4 levels at random from the latent space\nand then plot them using matplotlib.\n\"\"\"\nimport torch\nimport matplotlib.pyplot as plt\n\nfrom vae_mario import VAEMario\nfrom plotting_utilities import plot_decoded_level\n\n# Loading the model\nmodel_na... | [
[
"matplotlib.pyplot.tight_layout",
"torch.load",
"torch.randn",
"matplotlib.pyplot.subplots",
"matplotlib.pyplot.show"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
youngeun1209/beetlCompetiton | [
"8d3b0669cbc5809cdcee55f828789aa4e5b375a2"
] | [
"task1_sleep/train_sleep_DSN.py"
] | [
"#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\n\"\"\"\nCreated on Tue Sep 28 00:10:41 2021\n\n@author: yelee\n\"\"\"\n\n#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\n\"\"\"\nCreated on Mon Aug 23 17:17:58 2021\n\n@author: yelee\n\"\"\"\n\nfrom braindecode.util import set_random_seeds\nfrom braindecode.util im... | [
[
"matplotlib.pyplot.legend",
"torch.load",
"numpy.concatenate",
"matplotlib.pyplot.plot",
"numpy.mean",
"torch.cuda.is_available",
"torch.nn.CrossEntropyLoss",
"numpy.unique",
"torch.from_numpy",
"torch.tensor",
"numpy.std",
"numpy.argmax",
"matplotlib.pyplot.fig... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
commoncdp2021/Gun-Gaja-Gun | [
"95295f4ad97500d424b90c270bba6360f455844a"
] | [
"Plotting/list_comp.py"
] | [
"#! /usr/bin/python\n\nimport numpy as np\n\ndef main():\n x = [5,10,15,20,25]\n\n # declare y as an empty list\n y = []\n\n # The not so good way\n for counter in x:\n y.append(counter / 5)\n\n print(\"\\nOld fashioned way: x = {} y = {} \\n\".format(x, y))\n\n\n # The Pythonic way\n ... | [
[
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
bobo0810/classification | [
"b27397308c5294dcc30a5aaddab4692becfc45d3"
] | [
"Models/Backbone/mynet_metric.py"
] | [
"import torch\nimport torch.nn as nn\nimport torch.nn.functional as F\nfrom typing import Any\nimport timm\nfrom timm.models import register_model\n\n\nclass MyNet_Metric(nn.Module):\n \"\"\"\n 特征提取网络 输出feature\n \"\"\"\n\n def __init__(self, pretrained, model_name, embedding_size):\n super(MyNet... | [
[
"torch.nn.functional.normalize",
"torch.nn.BatchNorm1d"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
rub-ksv/-lrs_avsr1_local- | [
"c743803d5d09461f72ab7dbaf0af73a7077f3c0e",
"c743803d5d09461f72ab7dbaf0af73a7077f3c0e"
] | [
"training/trainaudio/asr_train_audio.py",
"training/finetuneav/nets_utils.py"
] | [
"#!/usr/bin/env python3\n# encoding: utf-8\n\n# Copyright 2017 Tomoki Hayashi (Nagoya University)\n# Apache 2.0 (http://www.apache.org/licenses/LICENSE-2.0)\n\n\"\"\"Automatic speech recognition model training script.\"\"\"\n\nimport configargparse\nimport logging\nimport multiprocessing as mp\nimport numpy as np... | [
[
"numpy.random.seed"
],
[
"torch.sum",
"torch.from_numpy",
"torch.arange"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
HxJi/google-research | [
"3f76493a1e194198f1d6a48e4e1c4381b2433170"
] | [
"state_of_sparsity/sparse_rn50/imagenet_train_eval.py"
] | [
"# coding=utf-8\n# Copyright 2019 The Google Research Authors.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless requ... | [
[
"tensorflow.contrib.cluster_resolver.TPUClusterResolver",
"tensorflow.contrib.tpu.bfloat16_scope",
"tensorflow.metrics.accuracy",
"tensorflow.control_dependencies",
"tensorflow.contrib.training.python.training.evaluation.checkpoints_iterator",
"tensorflow.cast",
"tensorflow.global_vari... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Magnushhoie/mlops_MH | [
"2875ecee4a7a935f517eddda56c8bc7b424880fb"
] | [
"src/visualization/visualize.py"
] | [
"import matplotlib.pyplot as plt\nimport numpy as np\nimport seaborn as sns\nfrom torch import nn, optim\nfrom torch.autograd import Variable\n\n\ndef plot_metric(value_list, value_string, dataset=\"Training\"):\n plt.figure()\n epoch_list = list(range(len(value_list)))\n sns.lineplot(x=epoch_list, y=value... | [
[
"matplotlib.pyplot.tight_layout",
"numpy.clip",
"matplotlib.pyplot.figure",
"numpy.arange",
"matplotlib.pyplot.subplots",
"matplotlib.pyplot.ylabel",
"matplotlib.pyplot.xlabel",
"numpy.array",
"torch.nn.MSELoss",
"torch.autograd.Variable"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
vnmabus/scikit-datasets | [
"ef6f4f9dda7f6c929e438d186806553ba04c2809"
] | [
"tests/utils/test_scores.py"
] | [
"\"\"\"\n@author: David Diaz Vico\n@license: MIT\n\"\"\"\n\nimport numpy as np\n\nfrom skdatasets.utils.scores import scores_table, hypotheses_table\n\n\ndatasets = ['a4a', 'a8a', 'combined', 'dna', 'ijcnn1', 'letter', 'pendigits',\n 'satimage', 'shuttle', 'usps', 'w7a', 'w8a']\nestimators = ['LogisticRe... | [
[
"numpy.asarray"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
YiranK/pytorch-yolo2 | [
"08772feb4702b886ad0ac29cbf04cb58623e502b"
] | [
"image.py"
] | [
"#!/usr/bin/python\n# encoding: utf-8\nimport random\nimport os\nfrom PIL import Image\nimport numpy as np\n\n\ndef scale_image_channel(im, c, v):\n cs = list(im.split())\n cs[c] = cs[c].point(lambda i: i * v)\n out = Image.merge(im.mode, tuple(cs))\n return out\n\ndef distort_image(im, hue, sat, val):\... | [
[
"numpy.reshape",
"numpy.concatenate",
"numpy.load",
"numpy.array",
"numpy.zeros"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Accern/accern-xyme | [
"887536144539eb93a798830f312aaebf09c4afc9"
] | [
"packages/python/accern_xyme/util.py"
] | [
"from typing import (\n Any,\n Callable,\n cast,\n Dict,\n IO,\n Iterable,\n List,\n Optional,\n Tuple,\n TypeVar,\n Union,\n)\nimport io\nimport json\nimport shutil\nimport time\nimport threading\nfrom io import BytesIO, TextIOWrapper\nimport pandas as pd\nfrom scipy import sparse\... | [
[
"pandas.concat",
"torch.load",
"torch.cat",
"scipy.sparse.load_npz",
"pandas.read_parquet",
"pandas.plotting.register_matplotlib_converters",
"scipy.sparse.vstack",
"pandas.Timestamp"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [
"1.6",
"1.10",
"1.4",
"1.3",
"1.9",
"0.19",
"1.5",
"1.7",
"1.0",
"1.2",
"1.8"
],
"tensorflow": []
}
] |
HazyResearch/torchhalp | [
"58dbfc5bd2997660ded3ea7a27f6df686d251a66"
] | [
"examples/regression/utils.py"
] | [
"import torch\nimport torch.utils.data as data\n\nclass SynthDataset(data.Dataset):\n def __init__(self, data, labels):\n self.data = data\n self.labels = labels\n\n def __len__(self):\n return len(self.labels)\n\n def __getitem__(self, idx):\n return self.data[idx], self.labels... | [
[
"torch.nn.Linear",
"torch.nn.Sequential",
"torch.from_numpy"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
MollsAndHersh/AdaptiveCards | [
"f43104dd7bf4d4451cb4b7cb76dc4911feb84dc5"
] | [
"source/pic2card/mystique/utils.py"
] | [
"import time\nimport io\nimport re\nfrom typing import Optional, Dict\nimport glob\nimport xml.etree.ElementTree as Et\nfrom contextlib import contextmanager\nfrom importlib import import_module\n\nimport numpy as np\nimport pandas as pd\nimport matplotlib.pyplot as plt\nfrom PIL import Image\n\nfrom mystique impor... | [
[
"matplotlib.pyplot.Rectangle",
"matplotlib.pyplot.gca",
"matplotlib.pyplot.imshow",
"matplotlib.pyplot.margins",
"pandas.DataFrame",
"matplotlib.pyplot.savefig",
"matplotlib.pyplot.close",
"matplotlib.pyplot.axis"
]
] | [
{
"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": []
}
] |
3sky/mlflow-example | [
"9ff864ad68f0e65dee494d1d73a6b3923a399cfc"
] | [
"train.py"
] | [
"# The data set used in this example is from http://archive.ics.uci.edu/ml/datasets/Wine+Quality\n# P. Cortez, A. Cerdeira, F. Almeida, T. Matos and J. Reis.\n# Modeling wine preferences by data mining from physicochemical properties. In Decision Support Systems, Elsevier, 47(4):547-553, 2009.\n\nimport os\nimport ... | [
[
"pandas.read_csv",
"sklearn.metrics.r2_score",
"numpy.random.seed",
"sklearn.linear_model.ElasticNet",
"sklearn.metrics.mean_absolute_error",
"sklearn.model_selection.train_test_split",
"sklearn.metrics.mean_squared_error"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
eli-osherovich/datasets | [
"4da1816088ea9e72b5761efc2534a4d032a2a438"
] | [
"tensorflow_datasets/core/features/class_label_feature.py"
] | [
"# coding=utf-8\n# Copyright 2021 The TensorFlow Datasets 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 ... | [
[
"tensorflow.compat.v2.io.gfile.GFile",
"tensorflow.compat.v2.io.gfile.exists",
"tensorflow.compat.v2.compat.as_text"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
MichelBartels/haystack | [
"b63669d1bc60b6c773b8b89d631afdd0ebbf4c4c"
] | [
"haystack/modeling/model/adaptive_model.py"
] | [
"import copy\nimport json\nimport logging\nimport multiprocessing\nimport os\nfrom pathlib import Path\nfrom typing import Iterable, Dict, Union, List, Optional, Callable\n\nimport numpy\nimport torch\nfrom torch import nn\nfrom transformers import AutoConfig\nfrom transformers.convert_graph_to_onnx import convert,... | [
[
"torch.nn.Dropout",
"torch.no_grad",
"torch.Tensor",
"numpy.stack"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
kerwenwwer/pensive-pytorch-py3 | [
"76292fa92078a7d2294d9438503e5fd5187804e4"
] | [
"rl_test.py"
] | [
"import os\nimport sys\nimport torch\nimport load_trace\nimport numpy as np\nimport fixed_env as env\nfrom Network import ActorNetwork\nfrom torch.distributions import Categorical\n\n\nS_INFO = 6 # bit_rate, buffer_size, next_chunk_size, bandwidth_measurement(throughput and time), chunk_til_video_end\nS_LEN = 8 #... | [
[
"numpy.abs",
"numpy.random.seed",
"torch.load",
"torch.zeros",
"torch.manual_seed",
"torch.tensor",
"numpy.max",
"torch.distributions.Categorical",
"torch.set_num_threads",
"torch.no_grad",
"torch.roll"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
gttm/eth-deep-learning | [
"6480e2ae794bc5f6e2e1af17923c5a02548a122d"
] | [
"dcpo/code/reinforced_epos/helpers/oop/Worker.py"
] | [
"from builtins import print\nimport os\nfrom reinforced_epos.helpers.oop.Network import Network as AC_Network\nimport tensorflow as tf\nfrom reinforced_epos.helpers.oop.helpers import *\nfrom reinforced_epos.helpers.oop.Environment import Environment\nfrom reinforced_epos.helpers.config import get_experiement_fold... | [
[
"tensorflow.Summary",
"tensorflow.summary.FileWriter"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": [
"1.10"
]
}
] |
leabeusch/pysteps | [
"5f162d4b1155e4cfd894c9635eed3f0e823adedd",
"5f162d4b1155e4cfd894c9635eed3f0e823adedd"
] | [
"pysteps/visualization/thunderstorms.py",
"pysteps/utils/fft.py"
] | [
"# -*- coding: utf-8 -*-\n\"\"\"\npysteps.visualization.tstorm\n============================\n\nMethods for plotting thunderstorm cells.\n\nCreated on Wed Nov 4 11:09:44 2020\n\n@author: mfeldman\n\n.. autosummary::\n :toctree: ../generated/\n\n plot_track\n plot_cart_contour\n\"\"\"\n\nimport matplotlib.... | [
[
"matplotlib.pyplot.gca"
],
[
"numpy.fft.irfft2"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
},
{
"matplotlib": [],
"numpy": [
"1.10",
"1.12",
"1.11",
"1.19",
"1.13",
"1.16",
"1.9",
"1.18",
"1.21",
"1.20",
"1.7",
"1.15",
"... |
andrewcistola/healthy-neighborhoods | [
"08bd0cd9dcb81b083a003943cd6679ca12237a1e"
] | [
"_archive/neville/neville_nhanes_crc_alpha.py"
] | [
"#### Healthy Neighborhoods Project: Using Ecological Data to Improve Community Health\n### Neville Subproject: Using Random Forestes, Factor Analysis, and Logistic regression to Screen Variables for Imapcts on Public Health\n## NHANES 2015-2016: Detecting different factors between individuals with a BMI over 30 an... | [
[
"pandas.merge",
"pandas.read_csv",
"sklearn.linear_model.LogisticRegression",
"sklearn.ensemble.RandomForestClassifier",
"sklearn.impute.SimpleImputer",
"pandas.DataFrame",
"numpy.std",
"numpy.mean",
"sklearn.feature_selection.RFECV",
"sklearn.preprocessing.StandardScaler",... | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
pchandrasekaran1595/Female-and-Male-Eyes | [
"5b5e98e7dafb83eb91822e9e272f148918e6ec8c"
] | [
"build_dataloaders.py"
] | [
"import os\nimport torch\nimport numpy as np\nfrom torch.utils.data import Dataset\nfrom torch.utils.data import DataLoader as DL\nfrom sklearn.model_selection import train_test_split\n\nimport utils as u\n\n#####################################################################################################\n\ncla... | [
[
"torch.manual_seed",
"torch.utils.data.DataLoader",
"sklearn.model_selection.train_test_split",
"numpy.concatenate",
"torch.FloatTensor"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
thu-coai/NAST | [
"ef765d412f6e9a2ebdcc7d62c99ec2e883d0e17a"
] | [
"eval/classifier/cls.py"
] | [
"import numpy as np\nimport logging\nimport time\nimport os\nfrom itertools import chain\n\nimport torch\nfrom torch import nn\n\nfrom utils import Storage, BaseModel, SummaryHelper, storage_to_list, CheckpointManager, RAdam\n\nfrom .model import Network\n\nclass Classifier(BaseModel):\n\tdef __init__(self, param):... | [
[
"torch.tensor",
"numpy.concatenate",
"torch.no_grad",
"numpy.mean",
"numpy.array",
"numpy.sum"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
timestocome/RaspberryPi-Robot | [
"b10d25cbfe2f7a60b82649503ea18213bdfd0f66"
] | [
"RobotBrain/BlackRobot_SARSA_Trace.py"
] | [
"# http://github.com/timestocome\n\n\n# train a raspberry pi robot to wander the house while avoiding obstacles\n# and looking for cats\n\n# this robot uses wheels for steering\n# 4 wheel drive with separate controls each side\n\n\n# change from off policy learning in first try\n# adapted from https://morvanzhou.gi... | [
[
"numpy.save",
"numpy.random.uniform",
"numpy.argmax",
"numpy.load",
"numpy.zeros",
"numpy.sum",
"numpy.random.randint"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
sadrayan/vote-roll-call | [
"3c19ef3213fcc10339159ae29f9d8d2fb5b4cb2a"
] | [
"ConvMF/text_analysis/models.py"
] | [
"'''\nCreated on Dec 8, 2015\n\n@author: donghyun\n'''\nimport numpy as np\nnp.random.seed(1337)\n\nfrom keras.callbacks import EarlyStopping\nfrom keras.layers.containers import Sequential\nfrom keras.layers.convolutional import Convolution2D, MaxPooling2D\nfrom keras.layers.core import Reshape, Flatten, Dropout, ... | [
[
"numpy.random.permutation",
"numpy.random.seed"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
agencyenterprise/mne-nirs | [
"e436c295fa6be7fe0d8d1c1475c60ba0a98d6118"
] | [
"mne_nirs/io/snirf/_snirf.py"
] | [
"# Authors: Robert Luke <mail@robertluke.net>\n#\n# License: BSD (3-clause)\n\nimport h5py as h5py\nimport re\nimport numpy as np\nfrom mne.io.pick import _picks_to_idx\n\n\ndef write_raw_snirf(raw, fname):\n \"\"\"Write continuous wave data to disk in SNIRF format.\n\n Parameters\n ----------\n raw : i... | [
[
"numpy.where",
"numpy.unique"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
swilcock0/vs068_ikfast | [
"624ecccd72fb95489daa7f36a9fa612184a2809e"
] | [
"tests/utils.py"
] | [
"import numpy as np\n\ndef best_sol(sols, q_guess, weights, feasible_ranges):\n \"\"\"get the best solution based on UR's joint domain value and weighted joint diff\n modified from :\n https://github.com/ros-industrial/universal_robot/blob/kinetic-devel/ur_kinematics/src/ur_kinematics/test_analytical_ik.py... | [
[
"numpy.all",
"numpy.array",
"numpy.ones"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
mathrho/Lasagne | [
"ddd44fddcd17603bfa16bd26c246a1cd4123f692"
] | [
"lasagne/utils.py"
] | [
"import numpy as np\n\nimport theano\nimport theano.tensor as T\n\n\ndef floatX(arr):\n \"\"\"Converts data to a numpy array of dtype ``theano.config.floatX``.\n\n Parameters\n ----------\n arr : array_like\n The data to be converted.\n\n Returns\n -------\n numpy ndarray\n The in... | [
[
"numpy.asarray",
"numpy.zeros",
"numpy.sum"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
OPTML-Group/RED-ICLR22 | [
"660b41e01465dd0c3a21829f6bc34e4796e96f94"
] | [
"RED_Dataset.py"
] | [
"# coding: utf-8\nimport cv2\nfrom torch.utils.data import Dataset\nimport Transform_Model as TM\nimport random\n# import dlib\nimport numpy as np\nfrom PIL import Image\nimport torchvision.transforms.functional as tf\nfrom torchvision import transforms\nimport torch\n\nclass FaceDataset(Dataset):\n def __init__... | [
[
"torch.cat"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
LaGuer/DeepSphere | [
"ebcf162eaa6e23c1c92dbc84e0908695bb7245d7"
] | [
"experiments_psd.py"
] | [
"#!/usr/bin/env python3\n# coding: utf-8\n\n\"\"\"\nScript to run the baseline experiment:\nSVM classification with power spectral densities (PSD) features.\n\"\"\"\n\nimport os\nimport sys\n\nimport numpy as np\n\nfrom deepsphere import experiment_helper\nfrom grid import pgrid\n\n\ndef single_experiment(sigma, or... | [
[
"numpy.load",
"numpy.savez",
"numpy.linspace"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
entn-at/AGAIN-VC | [
"dbf94bf55882f897c312c7760cd892c51c93c9ab"
] | [
"util/mytorch.py"
] | [
"import torch\nimport os\nimport numpy as np\nimport random\nimport shutil\nimport logging\n\nlogger = logging.getLogger(__name__)\n\n\ndef np2pt(array):\n return torch.from_numpy(array[None]).float()\n\ndef same_seeds(seed):\n torch.manual_seed(seed)\n if torch.cuda.is_available():\n torch.cuda.man... | [
[
"numpy.random.seed",
"torch.load",
"torch.cuda.manual_seed",
"torch.manual_seed",
"torch.from_numpy",
"torch.cuda.is_available",
"torch.cuda.manual_seed_all",
"torch.save"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
regasinaga/kmeans-clustering | [
"2a8df970287d1571fb654973bf9dcf152c6914fa"
] | [
"rgx.py"
] | [
"import numpy as np\nimport matplotlib.pyplot as plot\nimport matplotlib.patches as mpatches\ncolors = np.array(['#ff3333', '#ff6633','#ff9933',\n\t\t\t\t\t\t\t'#ffcc33', '#ffff33','#ccff33',\n\t\t\t\t\t\t\t'#99ff33', '#33ff33', '#33ff99',\n\t\t\t\t\t\t\t'#33ffff', '#3399ff', '#3333ff',\n\t\t\t\t\t\t\t'#9933ff', '#... | [
[
"numpy.abs",
"matplotlib.pyplot.scatter",
"matplotlib.pyplot.title",
"numpy.unique",
"numpy.power",
"numpy.random.permutation",
"numpy.argmin",
"numpy.mean",
"numpy.array",
"numpy.where"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
sebtsh/PBO | [
"e40adbb488fbf848de2ac8fa01de77cf2ca71e7d"
] | [
"objectives.py"
] | [
"import numpy as np\n\n\ndef forrester(x):\n \"\"\"\n 1-dimensional test function by Forrester et al. (2008)\n Defined as f(x) = (6x-2)^2 * sin(12x-4)\n :param x: tensor of shape (..., 1), x1 in [0, 1]\n :return: tensor of shape (..., )\n \"\"\"\n x0 = x[..., 0]\n return (6 * x0 - 2) * (6 * ... | [
[
"numpy.take_along_axis",
"numpy.expand_dims",
"numpy.reshape",
"numpy.sin",
"numpy.argmin",
"numpy.array",
"numpy.zeros",
"numpy.sum"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
BARarch/contacts-scraper | [
"b1cad99c97c94d3ccd73bf0456001eb973de2a67"
] | [
"scrapeContactsToday.py"
] | [
"import pandas as pd\nimport scraperModelGS as smgs\n\nimport directoryManager as dm\nimport contactChecker as cc\n\ndef getContacts():\n \"\"\"Google Sheets API Code.\n Pulls urls for all NFL Team RSS Feeds\n https://docs.google.com/spreadsheets/d/1p1LNyQhNhDBNEOkYQPV9xcNRe60WDlmnuiPp78hxkIs/\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": []
}
] |
georgen117/onnxruntime | [
"6f2f4721ecac719c6329fc2491a4f3a7cdf43336"
] | [
"onnxruntime/python/tools/tensorrt/perf/benchmark.py"
] | [
"import os\nimport csv\nimport timeit\nfrom datetime import datetime\nimport numpy\nimport logging\nimport coloredlogs\nimport numpy as np\nimport argparse\nimport copy\nimport json\nimport re\nimport sys\nimport onnxruntime\nfrom onnx import numpy_helper\nfrom perf_utils import *\nimport pprint\nimport time\nimpor... | [
[
"pandas.read_csv",
"numpy.random.random_sample",
"numpy.dtype",
"numpy.percentile",
"numpy.max",
"numpy.testing.assert_allclose",
"numpy.var",
"numpy.array"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [
"2.0",
"1.4",
"1.1",
"1.5",
"1.2",
"1.3"
],
"scipy": [],
"tensorflow": []
}
] |
LuCeHe/home-platform | [
"06f9370bfacecebd0c8623a3b8f0511532a9a1f0"
] | [
"tests/home_platform/test_core.py"
] | [
"# Copyright (c) 2017, IGLU consortium\n# All rights reserved.\n#\n# Redistribution and use in source and binary forms, with or without modification,\n# are permitted provided that the following conditions are met:\n#\n# - Redistributions of source code must retain the above copyright notice,\n# this list of co... | [
[
"numpy.seterr"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
sciris/openpyexcel | [
"1fde667a1adc2f4988279fd73a2ac2660706b5ce"
] | [
"openpyexcel/compat/tests/test_compat.py"
] | [
"from __future__ import absolute_import\n# Copyright (c) 2010-2019 openpyexcel\nimport pytest\n\n\n@pytest.mark.parametrize(\"value, result\",\n [\n ('s', 's'),\n (2.0/3, '0.6666666666666666'),\n (1, '1'),\n ... | [
[
"numpy.bool_",
"numpy.float_"
]
] | [
{
"matplotlib": [],
"numpy": [],
"pandas": [],
"scipy": [],
"tensorflow": []
}
] |
Aniket-Wali/Measure-Of-Document-Similarities-MODS- | [
"d6632082bdd114edbb072e0ffaa0397804e40dce"
] | [
"backend.py"
] | [
"import pymysql as py\nimport pandas as pd\nimport matplotlib as mplot\n\ncon = py.connect('DB_HOST', 'DB_USER', 'DB_PASSWORD', 'DB_NAME')\ncur = con.cursor()\n\n\ndef facultyLogin(usr, pwd):\n qry = \"select * from faculty where Emailid = '%s'\" % (usr)\n cur.execute(qry)\n row = cur.fetchone()\n con.c... | [
[
"pandas.read_sql"
]
] | [
{
"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.