repo_name
stringlengths
6
130
hexsha
list
file_path
list
code
list
apis
list
Nishantjannu/dedo
[ "cb6bcbc9e3049d7de9385842b8d35f02c946fb94" ]
[ "dedo/internal/datasets.py" ]
[ "import sys\nimport time\nimport torch\nfrom torch.utils.data import IterableDataset\nimport numpy as np\n\n\ndef worker_init_fn(worker_id):\n '''Helper function to launch each worker's env with a different seed'''\n\n gym = __import__('gym')\n worker_info = torch.utils.data.get_worker_info()\n ds = wor...
[ [ "numpy.array", "numpy.random.randint", "torch.utils.data.get_worker_info" ] ]
pjrigali/Poker-Now-Analysis
[ "be33d04e246f0b80beaebf394bc1eed3eb56d0c6" ]
[ "poker/poker_class.py" ]
[ "from typing import List, Optional, Union\nfrom dataclasses import dataclass\nimport pandas as pd\nimport datetime\nfrom os import walk\nfrom poker.base import flatten, unique_values, round_to, native_max\nfrom poker.game_class import Game\n\n\ndef _poker_convert_shape(data: List[str]) -> list:\n \"\"\"Converts ...
[ [ "pandas.DataFrame.from_dict", "pandas.DataFrame", "pandas.read_csv" ] ]
guyhwilson/ssm
[ "4349d6b1fad93f49508e5ca1f8326d24d3cfb097" ]
[ "ssm/emissions.py" ]
[ "from warnings import warn\n\nimport autograd.numpy as np\nimport autograd.numpy.random as npr\nfrom autograd.scipy.special import gammaln\nfrom autograd import hessian\n\nfrom ssm.util import ensure_args_are_lists, \\\n logistic, logit, softplus, inv_softplus\nfrom ssm.preprocessing import interpolate_data, pca...
[ [ "sklearn.linear_model.LinearRegression" ] ]
mihaTrajbaric/application-optimisation
[ "45767c8b10c18645f71d96e275165c68c2479117" ]
[ "use-cases/SnowUC-SkylineExtraction/peaklens-gpuopt_training.py" ]
[ "# %%\n\"\"\"\n# Notebook to train PeakLens original model \n\"\"\"\n\n# %%\nimport sys\nimport os\nimport tensorflow as tf\nimport numpy as np\nimport glob\nimport multiprocessing\nimport time \n\n# %%\nprint(tf.__version__)\n\n# %%\n\"\"\"\n## Training parameters \n\"\"\"\n\n# %%\nMODEL_NAME = \"PeakLens_original...
[ [ "tensorflow.keras.callbacks.TensorBoard", "tensorflow.data.Dataset.from_tensor_slices", "tensorflow.image.random_flip_left_right", "tensorflow.io.read_file", "tensorflow.keras.layers.Reshape", "tensorflow.keras.callbacks.ModelCheckpoint", "tensorflow.image.decode_jpeg", "tensorflow...
justinjohn0306/uberduck-ml-dev
[ "439ec326eb7680c4fdd5ee97a09def8e355e0f7c" ]
[ "uberduck_ml_dev/utils/utils.py" ]
[ "# AUTOGENERATED! DO NOT EDIT! File to edit: nbs/utils.utils.ipynb (unless otherwise specified).\n\n__all__ = ['load_filepaths_and_text', 'window_sumsquare', 'griffin_lim', 'dynamic_range_compression',\n 'dynamic_range_decompression', 'to_gpu', 'get_mask_from_lengths', 'reduce_tensor', 'subsequent_mask',\...
[ [ "torch.sigmoid", "torch.rand", "torch.arange", "numpy.zeros", "torch.autograd.Variable", "torch.max", "torch.clamp", "torch.from_numpy", "torch.ones", "torch.cuda.is_available", "scipy.signal.get_window", "torch.distributed.all_reduce", "torch.zeros_like", "...
neurorishika/babySSH
[ "9239ce7243250bdd0f5f57e8919c0b15dca41c5a" ]
[ "babydes.py" ]
[ "import numpy as np\nfrom util import *\n\n'''\nServer has list of authorized public key.\nClient has public key and private key (unique to client).\n\nServer has to make sure that the client who is in contact is authorized.\n\nAuthentication:\n---------------\n - Server selects a message.\n - Encrypts with p...
[ [ "numpy.concatenate", "numpy.logical_xor", "numpy.copy", "numpy.roll", "numpy.array_split" ] ]
ilmcconnell/Cosmos
[ "84245034727c30e20ffddee9e02c7e96f3aa115e", "84245034727c30e20ffddee9e02c7e96f3aa115e" ]
[ "cosmos/ingestion/ingest/process/detection/src/torch_model/train/data_layer/xml_loader.py", "cosmos/ingestion/ingest/process/postprocess/converters/pdf_extractor.py" ]
[ "\"\"\"\nAn XML and image repo loader\nmeant to work with the GTDataset class\nAuthor: Josh McGrath\n\"\"\"\nfrom torch.utils.data import Dataset\nimport os\nfrom os.path import splitext\nfrom PIL import Image\nfrom torchvision.transforms import ToTensor\nfrom numpy import genfromtxt\nimport torch\nfrom torch.nn.ut...
[ [ "torch.zeros", "torch.stack", "torch.norm", "torch.nn.utils.rnn.pad_sequence", "torch.ones", "torch.abs" ], [ "pandas.DataFrame" ] ]
jercas/MLiA_Learning_Code
[ "1d8c09f2fcbc81342941f6af97403bd2eb07483b" ]
[ "machinelearninginaction/Ch13/extras/createFig3.py" ]
[ "'''\nCreated on Jun 1, 2011\n\n@author: Peter\n'''\nfrom numpy import *\nimport matplotlib\nimport matplotlib.pyplot as plt\nimport pca\n\nn = 1000 #number of points to create\nxcord0 = []; ycord0 = []\nxcord1 = []; ycord1 = []\nxcord2 = []; ycord2 = []\nmarkers =[]\ncolors =[]\nfw = open('testSet3.txt','w')\nfor ...
[ [ "matplotlib.pyplot.show", "matplotlib.pyplot.figure" ] ]
kant/redrock
[ "572d81c60a940f9c132b715dde793e2657962e00" ]
[ "rest-api/python/resources.py" ]
[ "#\n# (C) Copyright IBM Corp. 2015, 2016\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.load" ] ]
developmentseed/pg_mvt
[ "10fa599928fc96ea30fad63289e40e39e564845d" ]
[ "tests/routes/test_tiles.py" ]
[ "\"\"\"Test Tiles endpoints.\"\"\"\n\nimport mapbox_vector_tile\nimport numpy as np\n\n\ndef test_tilejson(app):\n \"\"\"Test TileJSON endpoint.\"\"\"\n response = app.get(\"/public.landsat_wrs/tilejson.json\")\n assert response.status_code == 200\n\n resp_json = response.json()\n assert resp_json[\"...
[ [ "numpy.testing.assert_almost_equal" ] ]
datvuthanh/SPIMNET
[ "aa1518511e2c910290b6a31b19e942b49e025b38" ]
[ "processing.py" ]
[ "import glob\nimport imageio\nimport matplotlib.pyplot as plt\nimport numpy as np\nimport os\nimport PIL\nfrom tensorflow.keras import layers\nimport time\nimport numpy as np\n\nfrom sklearn import metrics\nfrom scipy import interpolate\n\nimport tensorflow as tf\nimport tensorflow_addons as tfa\n\ndef load(image_f...
[ [ "tensorflow.shape", "tensorflow.io.read_file", "tensorflow.image.rot90", "tensorflow.random.uniform", "tensorflow.image.random_crop", "tensorflow.clip_by_value", "tensorflow.image.flip_left_right", "tensorflow.stack", "tensorflow.image.flip_up_down", "tensorflow.image.resiz...
josepfont65/neurodsp
[ "a7c5b72665eed6368e29bf4f15443a28a2e18732", "a7c5b72665eed6368e29bf4f15443a28a2e18732" ]
[ "neurodsp/plts/time_series.py", "neurodsp/sim/aperiodic.py" ]
[ "\"\"\"Plots for time series.\"\"\"\n\nfrom itertools import repeat, cycle\n\nimport numpy as np\nimport numpy.ma as ma\nimport matplotlib.pyplot as plt\n\nfrom neurodsp.plts.style import style_plot\nfrom neurodsp.plts.utils import check_ax, savefig\n\n###############################################################...
[ [ "numpy.invert", "matplotlib.pyplot.yticks" ], [ "numpy.random.randn", "numpy.exp", "numpy.where", "numpy.fft.fft", "numpy.sqrt", "numpy.fft.ifft", "numpy.convolve" ] ]
xinyandai/structural-nn
[ "373cec9ca2ee766ddb1d2a09eac4dd551d57e648" ]
[ "image/imagequantizer.py" ]
[ "import torch\nimport numpy as np\nfrom PIL import Image\nfrom glob import glob\nfrom image.dataquantizer import quantize\n\n\ndef load_image(location):\n img = Image.open(location)\n img.load()\n data = np.asarray(img, dtype=\"int32\")\n return data\n\n\ndef save_image(image, location):\n if isinsta...
[ [ "numpy.asarray", "numpy.clip" ] ]
lcampagn/vispy
[ "fa5e2eab9bb3d956f87ae68a56e342913e58a305" ]
[ "vispy/visuals/rectangle.py" ]
[ "# -*- coding: utf-8 -*-\n# Copradiusight (c) 2014, Vispy Development Team.\n# Distributed under the (new) BSD License. See LICENSE.txt for more info.\n\n\n\"\"\"\nSimple ellipse visual based on PolygonVisual\n\"\"\"\n\nfrom __future__ import division\n\nimport numpy as np\nfrom ..color import Color\nfrom .polygon ...
[ [ "numpy.concatenate", "numpy.full", "numpy.array", "numpy.sin", "numpy.empty", "numpy.cos", "numpy.linspace" ] ]
Vitalii36/full-cycle_ML_Solution
[ "8c449164fe6856ade851910642a149a6325337c0" ]
[ "utils/trainer.py" ]
[ "from sklearn.svm import SVC\n\nclass Estimator:\n @staticmethod\n def fit(train_x, train_y):\n return SVC(probability=True).fit(train_x, train_y)\n\n @staticmethod\n def predict(trained, test_x):\n return trained.predict(test_x)" ]
[ [ "sklearn.svm.SVC" ] ]
nuwanprabhath/kaggle-nba-career-prediction
[ "ff07bccd02faa7b0aa3a448884135f87927768d9" ]
[ "src/data/imputer.py" ]
[ "\ndef iterative_imputer(df, cols, operator, target_value ):\n \n# compare iterative imputation strategies for the horse colic dataset\n from numpy import mean\n from numpy import std\n from pandas import read_csv\n from sklearn.ensemble import RandomForestClassifier\n from sklearn.experimental im...
[ [ "sklearn.ensemble.RandomForestClassifier", "matplotlib.pyplot.boxplot", "sklearn.impute.IterativeImputer", "numpy.mean", "sklearn.model_selection.RepeatedStratifiedKFold", "numpy.std", "sklearn.model_selection.cross_val_score", "matplotlib.pyplot.show", "pandas.read_csv", "...
ghchen18/emnlp2021-sixt
[ "1081986bb1c867a64e84af186000008901294678" ]
[ "fairseq/modules/transformer_layer.py" ]
[ "# Copyright (c) Facebook, Inc. and its affiliates.\n#\n# This source code is licensed under the MIT license found in the\n# LICENSE file in the root directory of this source tree.\n\nfrom typing import Dict, List, Optional\nfrom numpy.random import uniform\n\nimport torch\nimport torch.nn as nn\nfrom fairseq impor...
[ [ "torch.nn.Linear", "torch.cat", "torch.nn.init.constant_", "torch.nn.init.xavier_uniform_", "numpy.random.uniform" ] ]
BeHappyForMe/retrieval-faq
[ "bdc060b5005fc26bc5d27e1577bfc5a17710804d" ]
[ "faq/round_trip_translation.py" ]
[ "import pandas as pd\nimport json\nimport requests\nimport time\n\npd_all = pd.read_csv('../data/baoxian_right.csv', sep='\\t')\nbest_title = pd_all['best_title'].tolist()\n\n\ndef translate(word, ip):\n # 有道词典 api\n url = 'http://fanyi.youdao.com/translate?smartresult=dict&smartresult=rule&smartresult=ugc&se...
[ [ "pandas.read_csv" ] ]
jeffin07/theseus
[ "3498bbddf9cca740c2703d0c1aa3a78a7264cb15" ]
[ "theseus/geometry/lie_group.py" ]
[ "# Copyright (c) Meta Platforms, Inc. and affiliates.\n#\n# This source code is licensed under the MIT license found in the\n# LICENSE file in the root directory of this source tree.\n\nimport abc\nfrom typing import Any, List, Optional, Tuple, cast\n\nimport torch\n\nfrom theseus.geometry.manifold import Manifold\...
[ [ "torch.matmul" ] ]
oxygenxo/openvino
[ "1c3848a96fdd325b044babe6d5cd26db341cf85b" ]
[ "ngraph/python/tests/test_ngraph/test_ops_fused.py" ]
[ "# ******************************************************************************\n# Copyright 2017-2020 Intel Corporation\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# ...
[ [ "numpy.array", "numpy.exp", "numpy.allclose", "numpy.float32", "numpy.subtract", "numpy.arange", "numpy.clip" ] ]
madhuv2002/pandas
[ "006f1e0efb3ec81d52ff4d080b0c770b7b79d041", "006f1e0efb3ec81d52ff4d080b0c770b7b79d041", "006f1e0efb3ec81d52ff4d080b0c770b7b79d041" ]
[ "pandas/core/indexes/datetimelike.py", "pandas/tests/series/indexing/test_where.py", "pandas/tests/groupby/test_apply.py" ]
[ "\"\"\"\nBase and utility classes for tseries type pandas objects.\n\"\"\"\nfrom datetime import datetime\nfrom typing import (\n TYPE_CHECKING,\n Any,\n Hashable,\n List,\n Optional,\n Tuple,\n Type,\n TypeVar,\n Union,\n cast,\n)\n\nimport numpy as np\n\nfrom pandas._libs import (\n ...
[ [ "pandas.core.indexes.extension.make_wrapped_arith_op", "numpy.array_equal", "pandas.core.indexes.extension.NDArrayBackedExtensionIndex.take", "pandas.compat.numpy.function.validate_max", "pandas.core.common.asarray_tuplesafe", "pandas.compat.numpy.function.validate_argmin", "pandas._li...
gusamarante/QuantFin
[ "ba8ae75095692b3e6a922220ef8cefc1bea7c35e" ]
[ "cqf_final_project/chart_value.py" ]
[ "import pandas as pd\nfrom matplotlib import rcParams\nimport matplotlib.pyplot as plt\nimport matplotlib.dates as mdates\n\nfile_path = r'/Users/gustavoamarante/Dropbox/CQF/Final Project/' # Mac\n# file_path = r'/Users/gusamarante/Dropbox/CQF/Final Project/' # Macbook\n\n# Read Bloomberg Tickers for renaming\ndf...
[ [ "matplotlib.dates.YearLocator", "matplotlib.pyplot.savefig", "pandas.read_excel", "matplotlib.pyplot.plot", "matplotlib.pyplot.legend", "matplotlib.dates.DateFormatter", "matplotlib.pyplot.figure", "matplotlib.pyplot.tick_params", "matplotlib.pyplot.tight_layout", "matplotl...
InduManimaran/pennylane
[ "375d25acc7bd2e6d5243b5273958b26513c33189" ]
[ "pennylane/beta/qnodes/qubit.py" ]
[ "# Copyright 2019 Xanadu Quantum Technologies Inc.\r\n\r\n# Licensed under the Apache License, Version 2.0 (the \"License\");\r\n# you may not use this file except in compliance with the License.\r\n# You may obtain a copy of the License at\r\n\r\n# http://www.apache.org/licenses/LICENSE-2.0\r\n\r\n# Unless req...
[ [ "numpy.array", "numpy.zeros", "numpy.round", "numpy.identity", "numpy.where", "numpy.diag" ] ]
jgueldenstein/urdf2webots
[ "39850f249baa8461d014e0ca9c4b4d05d19cf7ab" ]
[ "urdf2webots/writeProto.py" ]
[ "\"\"\"Import modules.\"\"\"\n\nimport math\nimport numpy as np\n\nfrom urdf2webots.math_utils import rotateVector, matrixFromRotation, multiplyMatrix, rotationFromMatrix\n\ntoolSlot = None\nstaticBase = False\nenableMultiFile = False\nmeshFilesPath = None\nrobotNameMain = ''\ninitPos = None\n\n\nclass RGB():\n ...
[ [ "numpy.array", "numpy.dot", "numpy.transpose" ] ]
Mishne-Lab/CIDAN
[ "30d1176773e3ad0f236ba342cba48c89492f4e63" ]
[ "cidan/GUI/ImageView/ROIPaintImageViewModule.py" ]
[ "import logging\n\nimport numpy as np\nfrom PySide2.QtWidgets import QErrorMessage\nfrom qtpy import QtCore\n\nfrom cidan.GUI.ImageView.ROIImageViewModule import ROIImageViewModule\n\nlogger1 = logging.getLogger(\"cidan.ImageView.ROIImageViewModule\")\n\n\nclass ROIPaintImageViewModule(ROIImageViewModule):\n def...
[ [ "numpy.percentile", "numpy.hstack", "numpy.zeros" ] ]
hadarohana/fairseq
[ "566341e3aae9271facf6b9181b3f51b5120a2774" ]
[ "fairseq/modules/transformer_sentence_encoder.py" ]
[ "# Copyright (c) Facebook, Inc. and its affiliates.\n#\n# This source code is licensed under the MIT license found in the\n# LICENSE file in the root directory of this source tree.\n\nfrom typing import Optional, Tuple\n\nimport torch\nimport torch.nn as nn\nimport torch.nn.functional as F\nfrom fairseq.modules imp...
[ [ "torch.nn.functional.dropout", "torch.nn.Embedding" ] ]
ishine/bolt
[ "ea734231f7085898ba5ca10da6d02da38058a705", "ea734231f7085898ba5ca10da6d02da38058a705" ]
[ "model_tools/tools/tensorflow2caffe/bert/albert/transform_albert.py", "model_tools/tools/tensorflow2caffe/bert/tinybert/tinybert-infer.py" ]
[ "#!/usr/local/bin/python\n# -*- coding: utf-8 -*-\n\nfrom tensorflow2caffe_albert import Tensorflow2CaffeALBert\nimport numpy as np\n\n\nif __name__ == '__main__':\n tensorflow_model_path = \"/data/bolt/model_zoo/tensorflow_models/albert_base_zh_additional_36k_steps/albert_model.ckpt\"\n encoder_layers = 12\n...
[ [ "numpy.array" ], [ "tensorflow.zeros_initializer", "tensorflow.trainable_variables", "numpy.array", "numpy.reshape", "tensorflow.argmax", "tensorflow.GraphDef", "tensorflow.matmul", "tensorflow.Session", "tensorflow.train.Saver", "tensorflow.transpose", "tensorf...
ultmaster/tianshou
[ "3ac67d9974b6bd3e3d7feac7738ca6de33b317c7", "3ac67d9974b6bd3e3d7feac7738ca6de33b317c7" ]
[ "test/discrete/test_a2c_with_il.py", "examples/mujoco/mujoco_reinforce.py" ]
[ "import os\nimport gym\nimport torch\nimport pprint\nimport argparse\nimport numpy as np\nfrom torch.utils.tensorboard import SummaryWriter\n\nfrom tianshou.utils import BasicLogger\nfrom tianshou.env import DummyVectorEnv\nfrom tianshou.utils.net.common import Net\nfrom tianshou.data import Collector, VectorReplay...
[ [ "numpy.random.seed", "torch.manual_seed", "torch.cuda.is_available", "torch.utils.tensorboard.SummaryWriter", "torch.set_num_threads" ], [ "numpy.max", "numpy.ceil", "torch.nn.init.constant_", "numpy.random.seed", "torch.distributions.Normal", "numpy.min", "torc...
DwayneDuane/tensorflow
[ "c90698124aa164e7683e3a9d03b69e9aa8461244" ]
[ "tensorflow/lite/python/lite_flex_test.py" ]
[ "# Copyright 2019 The TensorFlow Authors. All Rights Reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless requ...
[ [ "tensorflow.python.ops.variables.Variable", "tensorflow.nn.conv2d", "tensorflow.lite.TFLiteConverter.from_saved_model", "tensorflow.python.ops.nn_ops.l2_loss", "tensorflow.lite.python.test_util.get_ops_list", "tensorflow.lite.python.lite.TFLiteConverterV2.from_concrete_functions", "ten...
GLivshits/Transistors
[ "4452c17a910a706326de0b6d0c95e681fba030dd" ]
[ "Probestation_via_classes.py" ]
[ "import os\nimport serial\nimport pyvisa\nimport matplotlib as mpl\nfrom matplotlib import pyplot as plt\nimport pandas as pd\nimport numpy as np\nimport time\n\n\nclass Probestation_FETs(object):\n\n def __init__(self, measurement_type):\n\n self.measurement_type = measurement_type\n\n def turn_on_key...
[ [ "numpy.equal", "pandas.DataFrame", "matplotlib.ticker.SymmetricalLogLocator", "matplotlib.pyplot.subplots", "numpy.mean", "pandas.DataFrame.to_csv" ] ]
redachhaibi/FreeNN
[ "3323fed33a0a990f137c11f66c91c4195db9bd92" ]
[ "experiments/run_experiment.py" ]
[ "import torch\nimport torchvision\nimport torchvision.transforms as transforms\n\nimport numpy\n\n#from fiberedae.utils import nn as nnutils\n#from icecream import ic\n\nimport click\n\ndef _get_attr(obj, attr_name, human_err_message):\n try:\n thing = getattr(obj, attr_name)\n except (AttributeError, ...
[ [ "torch.nn.Linear", "numpy.array", "torch.nn.Sequential", "numpy.save", "torch.utils.data.DataLoader", "torch.flatten" ] ]
sbhadra2020/fastMRI
[ "a2b25fed53621c5d5c648993af13971b2d365fc3" ]
[ "banding_removal/fastmri/model/classifiers/resnet_r1.py" ]
[ "import torch\nfrom torch import nn\nfrom torch.nn import functional as F\nfrom torch.autograd import Variable\nimport torch.utils.data\nimport torch.utils.data.distributed\nimport numpy as np\nimport pdb\n\nkernel_size = 5\n\nclass Discriminator(nn.Module):\n \"\"\"\n Known to work well as a GAN discrimi...
[ [ "torch.nn.Linear", "torch.nn.AdaptiveAvgPool2d", "torch.nn.MaxPool2d", "torch.nn.Sequential", "torch.nn.init.constant_", "torch.nn.init.kaiming_normal_", "torch.nn.GroupNorm", "torch.nn.Conv2d", "torch.nn.InstanceNorm2d", "torch.nn.functional.relu" ] ]
HelloDyson/Sketch2Voxel
[ "55799301ece904f1b6e8696f569647748a2197c3" ]
[ "models/base_gru_net.py" ]
[ "from models.net import Net\nfrom lib.layers import SoftmaxWithLoss3D\n\nimport torch\nfrom torch.autograd import Variable\n\n\nclass BaseGRUNet(Net):\n \"\"\"\n This class is used to define some common attributes and methods that both GRUNet and \n ResidualGRUNet have. Note that GRUNet and ResidualGRUNet ...
[ [ "torch.zeros", "torch.cuda.is_available", "torch.autograd.Variable" ] ]
akinoriosamura/TorchSeg-mirror
[ "34033fe85fc24015bcef7a92aad39d2a25a001a5", "34033fe85fc24015bcef7a92aad39d2a25a001a5", "34033fe85fc24015bcef7a92aad39d2a25a001a5", "34033fe85fc24015bcef7a92aad39d2a25a001a5" ]
[ "model/cpn/ablation_study/cityscapes.cpn.R101_v1c.v2/train.py", "model/cpn/ade.cpn.R50_v1c.v7/network.py", "model/cpn/ade.cpn.R50_v1c.v37/train.py", "model/bisenet/cityscapes.bisenet.X39.speed/config.py" ]
[ "from __future__ import division\nimport os.path as osp\nimport sys\nimport argparse\nfrom tqdm import tqdm\n\nimport torch\nimport torch.nn as nn\nimport torch.nn.functional as F\nimport torch.distributed as dist\nimport torch.backends.cudnn as cudnn\n\nfrom config import config\nfrom dataloader import get_train_l...
[ [ "torch.cuda.manual_seed", "torch.optim.SGD", "torch.manual_seed", "torch.cuda.set_device", "torch.cuda.is_available", "torch.distributed.all_reduce" ], [ "torch.sigmoid", "torch.cat", "torch.nn.functional.interpolate", "torch.bmm", "torch.nn.functional.log_softmax",...
johnhw/complexitygraph
[ "2ed89bee365939665236fe434597f21144a68d96" ]
[ "docs/mkplot.py" ]
[ "from complexitygraph import complexity_graph\nimport matplotlib.pyplot as plt\n\ndef quadratic_time(n):\n s = 0\n for i in range(n):\n for j in range(n):\n s = s + 1\n\ncomplexity_graph(quadratic_time, range(1, 500, 20), reps=12, number=6)\nplt.savefig(\"quadratic.png\")\n" ]
[ [ "matplotlib.pyplot.savefig" ] ]
kunwu522/cs584-project
[ "4f93229bb7d9b9e185d692b47192dfa46e51d1fa" ]
[ "code/han_bias.py" ]
[ "import os\n# os.environ[\"CUDA_DEVICE_ORDER\"] = \"PCI_BUS_ID\" # see issue #152\n# os.environ[\"CUDA_VISIBLE_DEVICES\"] = \"1\"\n\nimport keras\nfrom keras.preprocessing import text\nfrom keras.engine.topology import Layer\nimport keras.layers as L\nfrom keras.models import Model\nfrom keras import initializers...
[ [ "pandas.DataFrame.from_dict", "numpy.ones" ] ]
mikeireland/chronostar
[ "fcf37614e1d145f3a5e265e54512bf8cd98051a0", "fcf37614e1d145f3a5e265e54512bf8cd98051a0", "fcf37614e1d145f3a5e265e54512bf8cd98051a0" ]
[ "chronostar/tabletool.py", "chronostar/naivefit-bak.py", "chronostar/datatool.py" ]
[ "\"\"\"\ntabletool.py\n\nA bunch of functions that help handle stellar data stored as\nastropy table.\n\"\"\"\n\nimport numpy as np\nfrom astropy.table import Table\nfrom astropy.units.core import UnitConversionError\nimport string\n\nfrom . import coordinate\nfrom . import transform\n\ndef load(filename, **kwargs)...
[ [ "numpy.logical_not", "numpy.logical_or", "numpy.array", "numpy.isnan", "numpy.triu_indices", "numpy.diagonal", "numpy.eye", "numpy.where", "numpy.einsum", "numpy.vstack" ], [ "numpy.round", "numpy.load", "numpy.save", "numpy.argmax", "numpy.all", ...
Morisset/python-workshop
[ "ec8b0c4f08a24833e53a22f6b52566a08715c9d0" ]
[ "Day_2_Software_engineering_best_practices/solutions/04_modules/spectra_analysis/regression.py" ]
[ "# -*- coding: utf-8 -*-\n\"\"\"\nSpectra analysis utilities for regression\n\n\n\"\"\"\n\nimport numpy as np\n\nfrom sklearn.decomposition import PCA\nfrom sklearn.ensemble import RandomForestRegressor\nfrom sklearn.linear_model import RidgeCV\nfrom sklearn.pipeline import make_pipeline\n\nfrom .plotting import pl...
[ [ "sklearn.linear_model.RidgeCV", "numpy.median", "numpy.percentile", "sklearn.ensemble.RandomForestRegressor", "sklearn.decomposition.PCA" ] ]
YukiHata-ITS/uda_c3_3D_Object_Detection
[ "f831f7098e0c37586199b1ef355f5880e4d6ee16" ]
[ "student/objdet_detect.py" ]
[ "# ---------------------------------------------------------------------\n# Project \"Track 3D-Objects Over Time\"\n# Copyright (C) 2020, Dr. Antje Muntzinger / Dr. Andreas Haja.\n#\n# Purpose of this file : Detect 3D objects in lidar point clouds using deep learning\n#\n# You should have received a copy of the Uda...
[ [ "torch.no_grad", "numpy.arctan2", "torch.load" ] ]
joesingo/tom_education
[ "9bf9ea3d465f83040e4618ce89efbab2a087b2fa" ]
[ "tom_education/tests.py" ]
[ "from datetime import datetime\nfrom io import BytesIO, StringIO\nimport json\nimport os\nfrom unittest.mock import patch\nimport tempfile\n\nfrom astropy.io import fits\nfrom django import forms\nfrom django.core import mail\nfrom django.core.exceptions import ValidationError\nfrom django.core.files.uploadedfile i...
[ [ "numpy.max", "numpy.full", "numpy.array", "numpy.ones", "numpy.linspace" ] ]
kevinyang8/deep-learning-models
[ "271ddfa106c99bc131023e8e159c1b8cc903fe0e", "271ddfa106c99bc131023e8e159c1b8cc903fe0e" ]
[ "models/vision/detection/awsdet/models/bbox_heads/cascade_head.py", "models/vision/classification/resnet.py" ]
[ "from .. import builder\nfrom ..registry import HEADS\nfrom awsdet.core.bbox import bbox_target, transforms\nfrom awsdet.models.losses import losses\nimport tensorflow as tf\n\n\n\n@HEADS.register_module\nclass CascadeHead(tf.keras.Model): \n def __init__(self, \n num_stages=3,\n ...
[ [ "tensorflow.split", "tensorflow.shape", "tensorflow.function" ], [ "tensorflow.keras.Model", "tensorflow.keras.initializers.TruncatedNormal", "tensorflow.keras.regularizers.l2", "numpy.zeros" ] ]
sourabbapusridhar/master-thesis
[ "7ca0b36230dcab2e37a9501bcb519390d68b3b26" ]
[ "train.py" ]
[ "# Implementation of Training\n\nimport torch\nimport argparse\nimport numpy as np\nimport sys\nimport collections\nfrom trainer import Trainer\nimport model.loss as lossModule\nfrom utils import prepare_device\nimport model.metric as metricModule\nimport torch.nn.functional as F\nfrom parse_config import ConfigPar...
[ [ "torch.round", "numpy.random.seed", "torch.sub", "torch.autograd.set_detect_anomaly", "torch.ones", "torch.manual_seed", "torch.cuda.is_available", "torch.set_default_dtype", "torch.mean" ] ]
SyrekGMR/Gradient-Descent-Optimisation
[ "a3b891108a8b4260d64eb8dfd7958fe686150dc6", "a3b891108a8b4260d64eb8dfd7958fe686150dc6" ]
[ "Evaluate.py", "Optimisers/KFAC.py" ]
[ "import torch\n\ndef evaluate(model, device, test_data_loader):\n model.eval()\n correct = 0\n total = 0\n\n with torch.no_grad():\n for images, labels in test_data_loader:\n images = images.to(device)\n labels = labels.to(device)\n\n output = model.forward(images...
[ [ "torch.sum", "torch.no_grad", "torch.max" ], [ "torch.is_grad_enabled", "torch.nn.functional.pad", "torch.symeig", "torch.zeros_like" ] ]
TimoKuenstle/timeseries
[ "0e55710631f148c27c74b50dd7e960c7d4bf6601" ]
[ "generate6.py" ]
[ "# -*- coding: utf-8 -*-\nimport sugartensor as tf\nimport numpy as np\nimport matplotlib.pyplot as plt\nimport pandas as pd\n\n\n__author__ = 'njkim@jamonglab.com'\n\n\ntf.sg_verbosity(10)\n\n\n\nbatch_size = 100 \nnum_category = 10 \nnum_cont = 6 \nnum_dim = 30 \n\n\n\n\ntarget_num = tf.placeholder(dtype=t...
[ [ "matplotlib.pyplot.savefig", "pandas.DataFrame", "numpy.ones", "matplotlib.pyplot.close", "matplotlib.pyplot.subplots", "numpy.random.uniform", "numpy.random.randint", "numpy.arange", "numpy.linspace" ] ]
shoaibahmed/pl-cnn
[ "75f06630c755168771d049b7dbca300a21f27267" ]
[ "src/tests/svm.py" ]
[ "import unittest\nimport theano\nimport theano.tensor as T\nimport numpy as np\n\nfrom layers.svm import SVMLayer\n\n\ndef compile_objective():\n\n scores = T.matrix()\n y_truth = T.ivector()\n\n objective, acc = SVMLayer.objective(scores, y_truth)\n\n return theano.function([scores, y_truth], [objectiv...
[ [ "numpy.random.normal", "numpy.random.randint", "numpy.isclose", "numpy.argmax" ] ]
isabella232/flax
[ "39a04e82d6f97ef90c59425599018f2b9df8b6ea" ]
[ "examples/wip/moco/train_moco.py" ]
[ "# Copyright 2020 The Flax 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 required by applicable law or a...
[ [ "tensorflow.config.experimental.set_visible_devices" ] ]
georg-wenzel/ml-data-smell-detection
[ "7dddd401ca1f1a830dfd8b00760659911e5b1086", "7dddd401ca1f1a830dfd8b00760659911e5b1086" ]
[ "WebApp/main/views_datasets.py", "WebApp/main/utility/TensorflowUtility.py" ]
[ "from django.shortcuts import render, redirect\nfrom main.forms import AddDatasetForm, EditDatasetForm, DeleteDatasetForm, EditColumnFormSet\nfrom django.http import HttpResponseBadRequest\nfrom main.utility.DatabaseUtility import safe_get\nfrom main.utility import StringUtility\nfrom main.models import Dataset, Co...
[ [ "pandas.read_csv" ], [ "tensorflow.keras.preprocessing.sequence.pad_sequences", "tensorflow.keras.utils.normalize", "numpy.array", "tensorflow.keras.utils.to_categorical", "tensorflow.keras.layers.Input", "tensorflow.keras.layers.Dense", "numpy.argmax", "tensorflow.keras.lo...
thequilo/padertorch
[ "5e7ff6c2570739a0556d7c88bb93cd77017662a2" ]
[ "padertorch/contrib/je/models/vae.py" ]
[ "import numpy as np\nimport torch\nfrom einops import rearrange\nfrom padertorch.base import Model\nfrom padertorch.contrib.je.modules.conv import CNN1d, CNNTranspose1d\nfrom padertorch.contrib.je.modules.gmm import GMM\nfrom padertorch.contrib.je.modules.hmm import HMM\nfrom padertorch.contrib.je.modules.features ...
[ [ "torch.max", "sklearn.metrics.cluster.contingency_matrix", "torch.split", "numpy.mean", "torch.randn_like", "numpy.argmax", "torch.ones_like", "torch.exp", "numpy.unique", "numpy.maximum" ] ]
s1113950/models
[ "87261e70a902513f934413f009364c4f2eed6642" ]
[ "models/recommendation/tensorflow/wide_deep_large_ds/dataset/preprocess_csv_tfrecords.py" ]
[ "#\n# -*- coding: utf-8 -*-\n#\n# Copyright (c) 2018 Intel Corporation\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unle...
[ [ "numpy.array", "tensorflow.python_io.TFRecordWriter", "tensorflow.enable_eager_execution", "tensorflow.string_to_hash_bucket_fast", "tensorflow.train.Example", "pandas.read_csv" ] ]
AmeerFaisalAdanan/Malaya
[ "706efa5e78e87f74981adebe9974b6df0324fe0a" ]
[ "malaya/_utils/_utils.py" ]
[ "from tqdm import tqdm\nimport tensorflow as tf\nimport sentencepiece as spm\nimport numpy as np\nimport requests\nimport os\nfrom pathlib import Path\nfrom .. import _delete_folder\nfrom tensorflow.contrib.seq2seq.python.ops import beam_search_ops\n\n\ndef sentencepiece_tokenizer_xlnet(path_tokenizer):\n sp_mod...
[ [ "numpy.concatenate", "tensorflow.GraphDef", "tensorflow.Graph", "tensorflow.import_graph_def", "tensorflow.gfile.GFile", "numpy.maximum", "tensorflow.InteractiveSession" ] ]
vitalstarorg/docker-ml.py
[ "9d49739f0bf5806c2c44dc3b6f56fd0bfc4598d8" ]
[ "bin/sample1.py" ]
[ "#!/usr/bin/env python3\n\nimport matplotlib\nimport matplotlib.pyplot as plt\nimport numpy as np\n\n# Data for plotting\nt = np.arange(0.0, 2.0, 0.01)\ns = 1 + np.sin(2 * np.pi * t)\n\nfig, ax = plt.subplots()\nax.plot(t, s)\n\nax.set(xlabel='time (s)', ylabel='voltage (mV)',\n title='About as simple as it g...
[ [ "matplotlib.pyplot.show", "numpy.sin", "numpy.arange", "matplotlib.pyplot.subplots" ] ]
thu-pacman/AIPerf-MoE
[ "fda4f381b4b974721b187cece968dd7bc96a81f4", "fda4f381b4b974721b187cece968dd7bc96a81f4" ]
[ "megatron/model/multiple_choice.py", "megatron/global_vars.py" ]
[ "# coding=utf-8\n# Copyright (c) 2020, NVIDIA CORPORATION. All rights reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0...
[ [ "torch.nn.Dropout" ], [ "torch.distributed.get_world_size", "torch.cuda.synchronize", "torch.distributed.is_initialized", "torch.distributed.get_rank", "torch.utils.tensorboard.SummaryWriter" ] ]
wogong/pytorch-adda
[ "56ed179ced25fda3082b592e7f1751f4a62ac489" ]
[ "core/pretrain.py" ]
[ "\"\"\"Pre-train encoder and classifier for source dataset.\"\"\"\n\nimport torch.nn as nn\nimport torch.optim as optim\n\nfrom utils import make_variable, save_model\nfrom .test import eval\n\ndef train_src(encoder, classifier, src_data_loader, tgt_data_loader, params):\n \"\"\"Train classifier for source domai...
[ [ "torch.nn.CrossEntropyLoss" ] ]
fanmeilin/MOST_segmentation
[ "31d6bd6d77ae5c3dff6aefb9adfc23ea08072ae9" ]
[ "utils.py" ]
[ "import os\nimport cv2\nimport pickle\nimport numpy as np\nimport matplotlib.pyplot as plt\n\nimport tensorflow as tf\nfrom tensorflow.python.framework import ops\nfrom tensorflow.python.ops import array_ops\nfrom tensorflow.python.ops import math_ops\n\n# 注意权重设置能够保证至少过半样本被认为是正确样本\ndef sample_weights_boosted(y_pred...
[ [ "numpy.dot", "matplotlib.pyplot.xlim", "numpy.mean", "numpy.where", "tensorflow.cast", "tensorflow.python.ops.math_ops.cast", "numpy.log", "matplotlib.pyplot.subplot", "numpy.array", "numpy.zeros", "numpy.percentile", "matplotlib.pyplot.title", "matplotlib.pyplo...
CCS-Lab/pytorch_car_caring
[ "8a36d3f689e42afa81c753b4cfa0b890ab8e1000" ]
[ "src/models/dqn_linear.py" ]
[ "import torch.nn as nn\nimport torch.nn.functional as F\n\n\nclass DQNLinear(nn.Module):\n \"\"\"\n A feedforward, non-convolutional network.\n There is nothing about this architecture which is specific to Deep-q-learning - in fact,\n the algorithm's performance should be fairly robust to the number and...
[ [ "torch.nn.Linear" ] ]
vermashresth/chainer-compiler
[ "5f5ad365d14398d6ae0214fa012eb10360db8e7e", "5f5ad365d14398d6ae0214fa012eb10360db8e7e" ]
[ "testcases/ch2o_tests/node/EmbedID.py", "testcases/ch2o_tests/model/seq2seq.py" ]
[ "# coding: utf-8\n\nimport chainer\nimport chainer.links as L\n\n# Network definition\n\n\nclass A(chainer.Chain):\n\n def __init__(self, n_vocab, n_out):\n super(A, self).__init__()\n with self.init_scope():\n self.l1 = L.EmbedID(n_vocab, n_out)\n\n def forward(self, x):\n ret...
[ [ "numpy.random.seed", "numpy.random.randint" ], [ "numpy.random.seed", "numpy.random.rand", "numpy.cumsum" ] ]
sylvanding/detect-financial-risk
[ "dd2a143bb3c3a0fe943261954f3d836bbee08983" ]
[ "website/model_pred.py" ]
[ "# -*- coding: utf-8 -*-\nimport warnings\nwarnings.simplefilter(action='ignore', category=Warning)\nimport numpy as np\nfrom tensorflow.keras.models import load_model\n\n\ndef predictFinRisk(fin_ind):\n \"\"\"\n Predict a company's financial risk according to its indexes.\n :param fin_ind: financi...
[ [ "tensorflow.keras.models.load_model", "numpy.loadtxt", "numpy.asarray" ] ]
Florian-Barthel/stylegan2
[ "4ef87038bf9370596cf2b729e1d1a1bc3ebcddd8", "4ef87038bf9370596cf2b729e1d1a1bc3ebcddd8", "4ef87038bf9370596cf2b729e1d1a1bc3ebcddd8" ]
[ "dnnlib/tflib/ops/fused_bias_act.py", "sandbox/unit_circle_animation/unit_circle_multiple.py", "3_rotation_experiments/05_new_label/classifier/confusion_matrix.py" ]
[ "# Copyright (c) 2019, NVIDIA Corporation. All rights reserved.\n#\n# This work is made available under the Nvidia Source Code License-NC.\n# To view a copy of this license, visit\n# https://nvlabs.github.io/stylegan2/license.html\n\n\"\"\"Custom TensorFlow ops for efficient bias and activation.\"\"\"\n\nimport os\...
[ [ "tensorflow.convert_to_tensor", "tensorflow.nn.relu", "tensorflow.nn.leaky_relu", "tensorflow.constant", "tensorflow.nn.selu", "tensorflow.nn.softplus", "tensorflow.nn.softmax", "numpy.sqrt", "tensorflow.nn.elu", "tensorflow.nn.tanh", "tensorflow.nn.sigmoid" ], [ ...
spatialaudio/aes148-shelving-filter
[ "a11de97d6be79c23ffc55084ca95d9da15f3e3eb" ]
[ "python/mkfig-ripple-and-zp-frequency.py" ]
[ "\"\"\"Shelving Filter Cascade with Adjustable Transition Slope and Bandwidth\nFrank Schultz, Nara Hahn, Sascha Spors\nIn: Proc. of 148th AES Convention, Virtual Vienna, May 2020, Paper 10339\nhttp://www.aes.org/e-lib/browse.cfm?elib=20756\n\nFig. 4c, slide 10/12\n\n\"\"\"\n\nimport numpy as np\nimport matplotlib.p...
[ [ "matplotlib.ticker.MultipleLocator", "matplotlib.cm.get_cmap", "matplotlib.pyplot.savefig", "numpy.ones", "scipy.signal.sos2zpk", "matplotlib.pyplot.subplots", "numpy.sqrt", "numpy.abs", "numpy.log10", "numpy.log2" ] ]
threexc/SiGPyC
[ "81bdf2b691c601e266b2ea0249ad0bad074a567a" ]
[ "ants/analyzer.py" ]
[ "import math\nimport os\nimport re\nimport sys\nfrom textwrap import dedent\nimport matplotlib\nimport matplotlib.pyplot as plt\nimport numpy as np\n\nclass IQSamplesFile():\n def __init__(self, iq_samples_file_name, sample_rate = 20e6, noise_threshold = 0.02):\n match = re.search(\"iqsamples_(video|voice...
[ [ "matplotlib.pyplot.xlim", "numpy.min", "numpy.mean", "numpy.exp", "numpy.multiply", "numpy.where", "matplotlib.pyplot.draw", "matplotlib.pyplot.bar", "numpy.max", "numpy.concatenate", "numpy.count_nonzero", "matplotlib.pyplot.savefig", "numpy.arange", "numpy...
esnmrdi/phd
[ "2eede68a52e3e9c5931cad55dc6989c14f2e5d5b" ]
[ "model-ensemble-lookback.py" ]
[ "# %%\n# Ensemble Forecasting of RNN Models Trained for Lookbacks Ranging from 1 to 6\n# Ehsan Moradi, Ph.D. Candidate\n\n# %%\n# Import required libraries\nimport pandas as pd\nimport numpy as np\nimport csv\nfrom scipy.stats.mstats import trimmed_mean, winsorize\nfrom sklearn.ensemble import (\n GradientBoosti...
[ [ "sklearn.ensemble.AdaBoostRegressor", "numpy.array", "sklearn.ensemble.GradientBoostingRegressor", "sklearn.linear_model.LinearRegression", "pandas.DataFrame", "pandas.read_excel", "sklearn.linear_model.Ridge", "sklearn.utils.check_random_state", "sklearn.svm.SVR", "sklearn...
GateBuilder/Qcodes
[ "b3729f188847f9a7db77f23f8c1b3a2a635a2ac2" ]
[ "qcodes/instrument_drivers/stanford_research/SR830.py" ]
[ "from functools import partial\nimport numpy as np\n\nfrom qcodes import VisaInstrument\nfrom qcodes.instrument.parameter import ArrayParameter\nfrom qcodes.utils.validators import Numbers, Ints, Enum, Strings\n\nfrom typing import Tuple\n\n\nclass ChannelBuffer(ArrayParameter):\n \"\"\"\n Parameter class for...
[ [ "numpy.linspace", "numpy.fromstring", "numpy.arange" ] ]
IINemo/libact
[ "f9ddedcc009bfc70beeb04c9018b22eeaeafb155" ]
[ "libact/query_strategies/uncertainty_sampling.py" ]
[ "\"\"\" Uncertainty Sampling\n\nThis module contains a class that implements two of the most well-known\nuncertainty sampling query strategies: the least confidence method and the\nsmallest margin method (margin sampling).\n\n\"\"\"\nimport numpy as np\n\nfrom libact.base.interfaces import QueryStrategy, Continuous...
[ [ "numpy.max", "numpy.log", "numpy.shape", "numpy.argmax", "numpy.abs", "numpy.partition" ] ]
tagny/iLID
[ "38f5dcae0dc84fd9b78e170748aa38cd8f524c70" ]
[ "web-server/server.py" ]
[ "# System imports\nimport sys, subprocess, time\nimport numpy as np\nfrom os import path\nfrom flask.ext.cors import CORS\nfrom flask import *\nfrom flask.json import jsonify\nfrom werkzeug import secure_filename\nfrom flask_extensions import *\n\nlib_path = os.path.abspath(os.path.join('../evaluation'))\nsys.path....
[ [ "numpy.mean" ] ]
heavengate/models
[ "f05c910f8a8e3105de8c2f1d81e83ca00d2c7ec7", "f05c910f8a8e3105de8c2f1d81e83ca00d2c7ec7", "f05c910f8a8e3105de8c2f1d81e83ca00d2c7ec7" ]
[ "PaddleCV/PaddleVideo/utils/train_utils.py", "PaddleRec/gnn/train.py", "PaddleCV/PaddleDetection/ppdet/data/tools/x2coco.py" ]
[ "# Copyright (c) 2018 PaddlePaddle Authors. All Rights Reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless ...
[ [ "numpy.array", "numpy.mean" ], [ "numpy.arange", "numpy.mean" ], [ "numpy.max", "numpy.array", "numpy.asarray", "numpy.zeros", "numpy.min", "numpy.argwhere" ] ]
Aiden-Jeon/pytorch-lightning
[ "963c26764682fa4cf64c93c5a7572ae0040e9c32" ]
[ "tests/callbacks/test_early_stopping.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...
[ [ "numpy.mean", "torch.tensor", "torch.load", "numpy.diff" ] ]
beppeben/wavebet
[ "74e1019b78139018c44c5993c1318db237ea8e60" ]
[ "train.py" ]
[ "\"\"\"Training script for the WaveNet network on the VCTK corpus.\n\nThis script trains a network with the WaveNet using data from the VCTK corpus,\nwhich can be freely downloaded at the following site (~10 GB):\nhttp://homepages.inf.ed.ac.uk/jyamagis/page3/page58/page58.html\n\"\"\"\n\nfrom __future__ import prin...
[ [ "tensorflow.RunOptions", "tensorflow.trainable_variables", "tensorflow.train.start_queue_runners", "tensorflow.summary.merge", "tensorflow.python.client.timeline.Timeline", "tensorflow.train.Coordinator", "tensorflow.summary.scalar", "tensorflow.get_default_graph", "tensorflow....
AlexJew/CityEnergyAnalyst
[ "6eb372c79e5100a2d0abce78561ae368fb409cd1" ]
[ "legacy/4D_plots_ArcGIS/radiation_total.py" ]
[ "\"\"\"\nTotal radiation calculator from the insolation files\n\"\"\"\nfrom __future__ import division\nimport pandas as pd\nfrom cea.utilities import dbf\nimport cea.inputlocator\nimport cea.config\nfrom cea.utilities import epwreader\nfrom cea.constants import HOURS_IN_YEAR\n\n\n__author__ = \"Sreepathi Bhargava ...
[ [ "pandas.DataFrame", "pandas.date_range" ] ]
goshdarngames/Autumn-CA
[ "85bd1db5aa08882a01d6954e085b76e316ac5712" ]
[ "autumn_ca/benchmark.py" ]
[ "import numpy as np\r\n\r\nfrom lib.simulation import Simulation\r\n\r\nfrom lib.rule_function import conway_rule\r\n\r\nfrom Conway.lib.neighbourhood import moore_neighbourhood\r\n\r\n\r\nSIMULATION_SIZE = (100,100)\r\nNUMBER_OF_STEPS = 2 \r\n\r\nsim = Simulation( SIMULATION_SIZE, conway_rule) \r\n \r\...
[ [ "numpy.zeros" ] ]
joll05/AdventOfCode2019
[ "faa61058dd048dfc039889eaa4bd361d34b9dc7b", "faa61058dd048dfc039889eaa4bd361d34b9dc7b" ]
[ "Day 3/solution1.py", "Day 11/solution1.py" ]
[ "import numpy as np\n\ndef manhattan(x, y):\n return abs(x) + abs(y)\n\nf = open(\"input.txt\")\n\nwires = f.readlines()\nwires[0] = wires[0].split(\",\")\nwires[1] = wires[1].split(\",\")\n\nmax = int(input(\"Max: \"))\n\ncrossedPositions = np.zeros((max, max), dtype=bool)\n\nclosestCrossing = [999999, 999999]\...
[ [ "numpy.zeros" ], [ "numpy.full" ] ]
oicr-gsi/dashi
[ "34bf96a7d447095df525df3ad27dbe10f4e3dde0" ]
[ "application/dash_application/views/rnaseqc.py" ]
[ "import dash_html_components as html\nimport dash_core_components as core\nfrom dash.dependencies import Input, Output\nfrom ..dash_id import init_ids\nimport pandas\nimport gsiqcetl.load\nfrom gsiqcetl.rnaseqqc.constants import CacheSchema\nfrom gsiqcetl.pinery.sampleprovenance.constants import (\n CacheSchema ...
[ [ "pandas.to_datetime" ] ]
skphy/autodE
[ "fd80995206ac601299d2f78105d0fe4deee8c2cf" ]
[ "tests/test_values.py" ]
[ "import numpy as np\nfrom autode.units import ang, ha, ha_per_ang, ha_per_a0, ev\nfrom autode.values import (ValueArray, Gradient, Coordinate, Coordinates,\n MomentOfInertia)\n\n\nclass TmpValues(ValueArray):\n\n implemented_units = [ha, ev]\n\n def __repr__(self):\n return ''...
[ [ "numpy.array", "numpy.arange", "numpy.zeros" ] ]
zmoon92/proplot
[ "2c6f7af8a044567bb9409d3f67d844bac05c7d14" ]
[ "proplot/axes/plot.py" ]
[ "#!/usr/bin/env python3\n\"\"\"\nThe plotting wrappers that add functionality to various `~matplotlib.axes.Axes`\nmethods. \"Wrapped\" `~matplotlib.axes.Axes` methods accept the additional keyword\narguments documented by the wrapper function. In a future version, these features will\nbe documented on the individua...
[ [ "matplotlib.cm.ScalarMappable", "numpy.meshgrid", "matplotlib.patches.FancyBboxPatch", "matplotlib.ticker.IndexFormatter", "numpy.min", "numpy.mean", "numpy.where", "numpy.sign", "numpy.ma.concatenate", "numpy.issubdtype", "matplotlib.colors.Colormap", "numpy.max", ...
hotosm/ml-enabler-cli
[ "287d929fb0cf5be41100bdff41261ef99ded0ceb" ]
[ "ml_enabler/utils/osm.py" ]
[ "from area import area\nfrom geopy.distance import great_circle\nimport json\nimport numpy as np\nimport os\nimport subprocess\nimport tempfile\n\n\ndef get_osm(aoi):\n # convert AOI to bounding box\n pass\n\n\nclass OSMData(object):\n\n def __init__(self, aoi, overpass_url='https://lz4.overpass-api.de/api...
[ [ "numpy.array" ] ]
nalkhish/MachineLearning
[ "591c9e351f9f02fbcf6921dd84b679a45de2c66c" ]
[ "Coursera/costs.py" ]
[ "import numpy as np\n\n\ndef regularization_cost(kwargs):\n thetas = kwargs.get('thetas', np.array([0]))\n return kwargs.get('reg_p', 0) * thetas.T.dot(thetas)\n\ndef regularization_cost_2(thetas, kwargs):\n return kwargs.get('reg_p', 0) * thetas.T.dot(thetas)\n\ndef calc_cost_linear(m, **kwargs):\n return kwar...
[ [ "numpy.array", "numpy.log" ] ]
asongtoruin/album_plots
[ "639ca31379f10364dc0a628889419e9a4fcaa9a2" ]
[ "draw.py" ]
[ "import argparse\nfrom pathlib import Path\nfrom textwrap import wrap\n\nimport matplotlib.patheffects as pe\nimport matplotlib.pyplot as plt\nimport palbums\nimport pandas as pd\nfrom PIL import Image\nimport seaborn as sns\nimport spotipy\nfrom spotipy.oauth2 import SpotifyClientCredentials\nimport yaml\n\nimport...
[ [ "matplotlib.patheffects.withSimplePatchShadow", "matplotlib.pyplot.savefig", "matplotlib.pyplot.subplots", "matplotlib.pyplot.tight_layout", "matplotlib.pyplot.style.use", "matplotlib.patheffects.Normal", "matplotlib.pyplot.imread" ] ]
seyfullah/stockprediction
[ "aab0547cc1316a116ad032137722b73a36e67a51" ]
[ "experiments/2.py" ]
[ "import torch\nimport matplotlib.pyplot as plt\nfrom bindsnet.network import Network\nfrom bindsnet.network.nodes import Input, LIFNodes\nfrom bindsnet.network.topology import Connection\nfrom bindsnet.network.monitors import Monitor\nfrom bindsnet.analysis.plotting import plot_spikes, plot_voltages\n\n# Simulation...
[ [ "torch.ones", "matplotlib.pyplot.show", "torch.eye", "matplotlib.pyplot.ioff", "torch.randn" ] ]
karolciba/playground
[ "bfba14eaacfb6e7f820b85f95d9a1a72e251489e" ]
[ "ecg/ecg_hmm.py" ]
[ "#!/usr/bin/env python\n#\n# changes to hmmlearn:\n# 0. negative delta doesnt end \n# 1. prevent overfitting by not allowing for setting transition prob to 0\n\n# ideas:\n# 0. negative delta in logprobability is not wrong - it means model is rebuilding\n# lower train signal probability is exchange for better dis...
[ [ "sklearn.externals.joblib.dump", "numpy.sort", "numpy.cumsum", "scipy.signal.decimate", "numpy.random.random", "numpy.concatenate", "numpy.bincount", "numpy.random.binomial", "numpy.argmax", "numpy.empty_like", "matplotlib.pyplot.subplot", "numpy.diff", "numpy.a...
prajakta0111/pytorch-lightning
[ "3df02b880a6d145ff0aca24ea429c12c0d8f1181", "3df02b880a6d145ff0aca24ea429c12c0d8f1181", "3df02b880a6d145ff0aca24ea429c12c0d8f1181", "3df02b880a6d145ff0aca24ea429c12c0d8f1181" ]
[ "tests/metrics/regression/test_ssim.py", "pytorch_lightning/metrics/functional/roc.py", "tests/metrics/functional/test_reduction.py", "tests/accelerators/test_tpu_backend.py" ]
[ "from collections import namedtuple\nfrom functools import partial\n\nimport pytest\nimport torch\nfrom skimage.metrics import structural_similarity\n\nfrom pytorch_lightning.metrics.functional import ssim\nfrom pytorch_lightning.metrics.regression import SSIM\nfrom tests.metrics.utils import BATCH_SIZE, MetricTest...
[ [ "torch.manual_seed", "torch.rand" ], [ "torch.zeros", "torch.cat" ], [ "torch.rand", "torch.randint", "torch.mean", "torch.sum" ], [ "torch.nn.Linear", "torch.device", "torch.load" ] ]
rehohoho/models
[ "3577bc5959d7e2a3513ff1c5ec8b42c4f5bedca8" ]
[ "official/vision/beta/ops/yolo_ops.py" ]
[ "\"\"\"Utility ops for yolo data.\nReferenced from https://github.com/hunglc007/tensorflow-yolov4-tflite.\n\"\"\"\n\nfrom typing import List, Tuple, Mapping\n\nimport tensorflow as tf\nimport tensorflow_addons as tfa\n\n\ndef resize_image_and_bboxes(image: tf.Tensor, \n bboxes: tf.Tensor,...
[ [ "tensorflow.reshape", "tensorflow.zeros_like", "tensorflow.stack", "tensorflow.one_hot", "tensorflow.cast", "tensorflow.shape", "tensorflow.concat", "tensorflow.subtract", "tensorflow.constant", "tensorflow.image.pad_to_bounding_box", "tensorflow.split", "tensorflow...
pranjalg96/Stylized-Image-captioning
[ "e95111f36e3eed83478c990fdd70c5b9604bf57a" ]
[ "FLICKR/model_flickr.py" ]
[ "import numpy as np\nimport torch\nimport torch.nn as nn\nimport torch.nn.functional as F\nfrom torch.autograd import Variable\nfrom itertools import chain\n\n\nclass RNN_VAE(nn.Module):\n \"\"\"\n 1. Hu, Zhiting, et al. \"Toward controlled generation of text.\" ICML. 2017.\n 2. Bowman, Samuel R., et al. \...
[ [ "torch.nn.Linear", "torch.zeros", "torch.cat", "torch.nn.Dropout", "torch.nn.LSTM", "torch.nn.ModuleList", "torch.autograd.Variable", "torch.randn", "torch.nn.Conv2d", "torch.multinomial", "torch.LongTensor", "torch.nn.functional.softmax", "torch.exp", "torc...
igorss77/diabetes_project
[ "0353ec812989c90c43a61b6aee4e02f943c51944" ]
[ "data_preparation.py" ]
[ "import pandas as pd\nimport logging\nfrom sklearn.feature_selection import SelectKBest, chi2\nfrom sklearn.ensemble import RandomForestClassifier\nfrom sklearn.model_selection import GridSearchCV\nimport pickle\nfrom sklearn.metrics import classification_report\n\n\nlogger = logging.getLogger(__name__)\n\ndef colu...
[ [ "sklearn.ensemble.RandomForestClassifier", "pandas.DataFrame", "sklearn.metrics.classification_report", "sklearn.feature_selection.SelectKBest", "pandas.Series", "pandas.get_dummies" ] ]
aneeshnaik/spam
[ "f66212bf77d72c8528c1a0d6cbe814cd360794c7" ]
[ "fit/likelihood.py" ]
[ "#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\n\"\"\"\nCreated: 2018\nAuthor: A. P. Naik\nDescription: File containing likelihood function 'lnlike', to be fed to\nemcee sampler.\n\"\"\"\nimport numpy as np\nfrom .rotcurve import v_model\n\n\ndef lnlike(theta, theta_dict, galaxy, **kwargs):\n \"\"\"\n For g...
[ [ "numpy.log", "numpy.sum", "numpy.sqrt" ] ]
3vivekb/hail
[ "82c9e0f3ec2154335f91f2219b84c0fb5dbac526" ]
[ "hail/python/hail/expr/types.py" ]
[ "import abc\nimport json\nimport math\nfrom collections.abc import Mapping, Sequence\n\nimport numpy as np\n\nimport hail as hl\nfrom hail import genetics\nfrom hail.expr.nat import NatBase, NatLiteral\nfrom hail.expr.type_parsing import type_grammar, type_node_visitor\nfrom hail.genetics.reference_genome import re...
[ [ "numpy.array", "numpy.nditer" ] ]
YaoYinYing/OpenFold2
[ "57fd3cfba0bc70a2ca4c6943ba00e1c4892c1945" ]
[ "alphafold/Tests/utils.py" ]
[ "import torch\nimport numpy as np\nfrom pathlib import Path\nimport pickle\n\nfrom pytorch_memlab import MemReporter\nfrom pytorch_memlab.utils import readable_size as mem_to_str\nreporter = MemReporter()\n\n\ndef convert(arg, device:torch.device=None):\n\tif isinstance(arg, tuple):\n\t\treturn tuple([convert(arg_i...
[ [ "torch.device", "torch.max", "numpy.sum", "numpy.mean", "torch.from_numpy", "torch.Tensor", "torch.mean" ] ]
AWSjswinney/LightGBM
[ "abdb234f7051b15d486902f2bda93eb5a2221e06" ]
[ "tests/python_package_test/test_engine.py" ]
[ "# coding: utf-8\nimport copy\nimport itertools\nimport math\nimport pickle\nimport platform\nimport random\nfrom pathlib import Path\n\nimport numpy as np\nimport psutil\nimport pytest\nfrom scipy.sparse import csr_matrix, isspmatrix_csc, isspmatrix_csr\nfrom sklearn.datasets import load_svmlight_file, make_multil...
[ [ "numpy.testing.assert_allclose", "numpy.random.rand", "numpy.random.choice", "scipy.sparse.isspmatrix_csr", "numpy.testing.assert_raises_regex", "numpy.mean", "sklearn.metrics.average_precision_score", "numpy.cos", "numpy.random.random", "numpy.concatenate", "numpy.rand...
eo1989/VectorBTanalysis
[ "bea3deaf2ee3fc114b308146f2af3e4f35f70197", "bea3deaf2ee3fc114b308146f2af3e4f35f70197", "3dc84b260e5bced65ebc2c45c40c8fa65f9b5aa9", "bea3deaf2ee3fc114b308146f2af3e4f35f70197", "bea3deaf2ee3fc114b308146f2af3e4f35f70197" ]
[ ".venv/lib/python3.8/site-packages/pypfopt/efficient_frontier.py", ".venv/lib/python3.8/site-packages/pandas_datareader/compat/__init__.py", ".venv/lib/python3.8/site-packages/dill/tests/test_source.py", ".venv/lib/python3.8/site-packages/vectorbt/utils/array.py", ".venv/lib/python3.8/site-packages/findatap...
[ "\"\"\"\nThe ``efficient_frontier`` module houses the EfficientFrontier class, which\ngenerates optimal portfolios for various possible objective functions and parameters.\n\"\"\"\n\nimport warnings\nimport numpy as np\nimport pandas as pd\nimport cvxpy as cp\n\nfrom . import objective_functions, base_optimizer\n\n...
[ [ "numpy.any", "numpy.array", "numpy.linalg.inv" ], [ "pandas.concat", "pandas.io.common.get_filepath_or_buffer" ], [ "numpy.array" ], [ "numpy.all" ], [ "pandas.Timestamp" ] ]
gngdb/smplx
[ "ba72def2038712784458a91f94371de6550d7e65" ]
[ "transfer_model/merge_output.py" ]
[ "# merges the output of the main transfer_model script\n\nimport torch\nfrom pathlib import Path\nimport pickle\nfrom scipy.spatial.transform import Rotation as R\n\nKEYS = [\n\"transl\",\n\"global_orient\",\n\"body_pose\",\n\"betas\",\n\"left_hand_pose\",\n\"right_hand_pose\",\n\"jaw_pose\",\n\"leye_pose\",\n\"rey...
[ [ "torch.cat" ] ]
kolojoe/scipy
[ "3b4a30cbf580a1ea07bf48abf4bbea708b2018dd" ]
[ "scipy/stats/tests/test_distributions.py" ]
[ "\"\"\"\nTest functions for stats module\n\"\"\"\n\nimport warnings\nimport re\nimport sys\nimport pickle\nimport os\n\nfrom numpy.testing import (assert_equal, assert_array_equal,\n assert_almost_equal, assert_array_almost_equal,\n assert_allclose, assert_, asser...
[ [ "scipy.stats._continuous_distns.gamma_gen", "scipy.stats.tukeylambda.pdf", "scipy.stats.beta", "scipy.stats.binom.rvs", "scipy.stats.triang.pdf", "scipy.stats.geom.cdf", "scipy.stats.gamma", "scipy.stats.loggamma.stats", "scipy.stats.gamma.stats", "scipy.stats.triang.cdf", ...
zlpmichelle/crackingtensorflow
[ "66c3517b60c3793ef06f904e5d58e4d044628182" ]
[ "crackingcode/day4/cc_tf_day4_1.py" ]
[ "\n# coding: utf-8\n\n# In[1]:\n\n\nimport tensorflow as tf\n\n\n# In[2]:\n\n\nnode1 = tf.constant(3.0, tf.float32)\nnode2 = tf.constant(4.0) # also tf.float32 implicity\nprint(node1, node2)\n\n\n# In[3]:\n\n\nsess = tf.Session()\nprint(sess.run([node1, node2]))\n\n\n# In[5]:\n\n\nnode3 = tf.add(node1, node2)\nprin...
[ [ "tensorflow.contrib.learn.LinearRegressor", "tensorflow.contrib.learn.ModelFnOps", "tensorflow.assign_add", "tensorflow.contrib.learn.Estimator", "tensorflow.global_variables_initializer", "tensorflow.train.GradientDescentOptimizer", "tensorflow.Variable", "tensorflow.constant", ...
iro-upgto/cime
[ "1e71927f8dc029d5968f63a1c86991eca1456dd0" ]
[ "cime/_experimental.py" ]
[ "from sympy import *\nfrom sympy.matrices import *\nfrom sympy.physics.mechanics import dynamicsymbols, init_vprinting\nimport matplotlib.pyplot as plt\ninit_vprinting()\n\ndef kinvars(*args,**kwargs):\n return dynamicsymbols(*args,**kwargs)\n\nclass Vector2D(object):\n def __init__(self,*args,**kwargs):\n ...
[ [ "matplotlib.pyplot.plot" ] ]
ElgaSalvadore/watools
[ "daaaad474add572f32dd6a45a4230ccf636c479a", "daaaad474add572f32dd6a45a4230ccf636c479a" ]
[ "Collect/RFE/DataAccess.py", "General/data_conversions.py" ]
[ "# -*- coding: utf-8 -*-\n\"\"\"\nAuthors: Tim Hessels\n UNESCO-IHE 2016\nContact: t.hessels@unesco-ihe.org\nRepository: https://github.com/wateraccounting/wa\nModule: Collect/RFE\n\"\"\"\nfrom __future__ import print_function\n\nimport numpy as np\nimport os\nimport pandas as pd\nfrom ftplib import FTP\nfr...
[ [ "numpy.max", "numpy.ceil", "pandas.date_range", "numpy.min", "pandas.Timestamp", "numpy.floor" ], [ "numpy.isnan", "numpy.float", "pandas.date_range", "numpy.ones", "numpy.shape", "numpy.arange", "numpy.argwhere", "numpy.indices" ] ]
Tomwmg/player-detection
[ "a5212bf80353a3b56c92f64bc07562161fa386f3" ]
[ "train.py" ]
[ "# general packages\nimport numpy as np\nimport random\nimport os\nimport errno\nimport argparse\nimport torch\nfrom torch.utils import model_zoo\nfrom torch.autograd import Variable\nfrom torch.optim import lr_scheduler\n\nfrom data_loader import YC2_train_data\nfrom model import DVSA\nfrom datetime import datetim...
[ [ "torch.cuda.manual_seed_all", "numpy.random.seed", "torch.autograd.Variable", "torch.manual_seed", "torch.cuda.is_available", "torch.utils.data.DataLoader", "torch.load" ] ]
robfatland/nlp
[ "f4cab048d21a4c63726d19c1d453f1d68b2589a0" ]
[ "austen-kmeans.py" ]
[ "from collections import Counter\r\nfrom collections import defaultdict\r\nimport glob, os\r\nimport pandas as pd\r\nfrom sklearn.cluster import KMeans\r\nfrom sklearn.decomposition import PCA\r\nimport matplotlib.pyplot as plt \r\n\r\n\r\n\r\n'''\r\nThe 'austen_alcott' folder contains a set of novels by Jane Auste...
[ [ "matplotlib.pyplot.text", "matplotlib.pyplot.arrow", "matplotlib.pyplot.xlabel", "matplotlib.pyplot.savefig", "matplotlib.pyplot.title", "pandas.DataFrame", "sklearn.cluster.KMeans", "matplotlib.pyplot.figure", "matplotlib.pyplot.show", "matplotlib.pyplot.ylabel", "matp...
dadu0699/tytus
[ "e1920f6932c840859e3e79eb8756a1d3da88bd77" ]
[ "bases_2021_1S/Grupo 10/server/utilities/analisys_parser/analizer/statement/instructions/select/from_.py" ]
[ "from utilities.analisys_parser.analizer.reports import Nodo\nfrom utilities.analisys_parser.analizer.abstract import instruction\nfrom utilities.analisys_parser.analizer.statement.instructions.select.select import Select\nfrom utilities.analisys_parser.analizer.symbol.symbol import Symbol\nfrom utilities.analisys_...
[ [ "pandas.DataFrame", "pandas.merge" ] ]
deisemaia/Higra
[ "82cb78b606a383f3961faa882457a9a987f802e0", "82cb78b606a383f3961faa882457a9a987f802e0" ]
[ "higra/hierarchy/random_hierarchy.py", "higra/hierarchy/constrained_connectivity_hierarchy.py" ]
[ "############################################################################\n# Copyright ESIEE Paris (2018) #\n# #\n# Contributor(s) : Benjamin Perret #\n# ...
[ [ "numpy.arange", "numpy.zeros" ], [ "numpy.maximum.at", "numpy.logical_and" ] ]
Chinmay-jain767/itr
[ "041d276c2c9973ea7e33d4a293914c6e20acf968" ]
[ "itr/train_util2.py" ]
[ "import time\r\nimport torch\r\nimport numpy as np\r\nfrom pathlib import Path\r\nfrom transformers import WEIGHTS_NAME, CONFIG_NAME\r\n\r\n\r\ndef init_seed():\r\n seed_val = 42\r\n np.random.seed(seed_val)\r\n torch.manual_seed(seed_val)\r\n torch.cuda.manual_seed_all(seed_val)\r\n\r\n\r\ndevice = tor...
[ [ "torch.device", "numpy.equal", "torch.cat", "torch.cuda.manual_seed_all", "torch.stack", "numpy.random.seed", "torch.no_grad", "torch.manual_seed", "torch.cuda.is_available", "numpy.argmax", "torch.argmax" ] ]
monchier/streamlit-1
[ "202cd80bad8c8eb51d3e75d3923b225b0092c882" ]
[ "e2e/scripts/st_map.py" ]
[ "# -*- coding: utf-8 -*-\n# Copyright 2018-2020 Streamlit Inc.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless requi...
[ [ "pandas.DataFrame", "numpy.random.randn" ] ]
vishalbelsare/KramersMoyal
[ "57e50278b0d31567054f763f3e0f3cc2c1e08315", "57e50278b0d31567054f763f3e0f3cc2c1e08315", "57e50278b0d31567054f763f3e0f3cc2c1e08315" ]
[ "test/kmc_test.py", "test/bincount_test.py", "older versions/older_version_1d_calculator.py" ]
[ "import numpy as np\n\nfrom kramersmoyal import km\nfrom kramersmoyal import kernels\n\ndef test_kmc():\n for t in [1,0.1,0.01,0.001]:\n for lag in [None, [1,2,3]]:\n\n X = np.random.normal(loc = 0, scale = np.sqrt(t), size = 10000)\n\n bins = np.array([5000])\n\n powers =...
[ [ "numpy.array", "numpy.sqrt" ], [ "numpy.random.randint", "numpy.random.rand" ], [ "numpy.linspace", "numpy.zeros", "numpy.unique" ] ]
vanshhhhh/datasets
[ "aee32f95273ca3bfe83e09fb9b00ba4bf23597a5", "aee32f95273ca3bfe83e09fb9b00ba4bf23597a5" ]
[ "tensorflow_datasets/ranking/libsvm_ranking_parser.py", "tensorflow_datasets/video/ucf101.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 ...
[ [ "numpy.array" ], [ "tensorflow.io.gfile.exists", "tensorflow.io.gfile.GFile" ] ]