repo_name stringlengths 8 130 | hexsha list | file_path list | code list | apis list |
|---|---|---|---|---|
apaleyes/xfer | [
"99cd83424bc7e76a2c2def9d5b1dacd06f6e9eb5"
] | [
"xfer/contrib/xfer_leap/synthetic_data.py"
] | [
"# Copyright 2018 Amazon.com, Inc. or its affiliates. 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# A copy of the License is located at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n... | [
[
"numpy.arange",
"matplotlib.pyplot.subplots"
]
] |
idharmateja/tensorflow | [
"1712002ad02f044f7569224bf465e0ea00e6a6c4"
] | [
"tensorflow/contrib/data/python/ops/readers.py"
] | [
"# Copyright 2017 The TensorFlow Authors. All Rights Reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless requ... | [
[
"tensorflow.python.util.deprecation.deprecated",
"tensorflow.python.data.ops.dataset_ops.Dataset.list_files",
"tensorflow.python.data.util.nest.flatten",
"tensorflow.python.data.ops.dataset_ops.Dataset.from_tensor_slices",
"tensorflow.python.platform.gfile.Glob",
"tensorflow.python.ops.par... |
yicrane/Real-SR | [
"a6e380b791129b80fe58bf282089c0cfd9159b36"
] | [
"codes/preprocess/collect_noise.py"
] | [
"from PIL import Image\nimport numpy as np\nimport os.path as osp\nimport glob\nimport os\nimport argparse\nimport yaml\n\nparser = argparse.ArgumentParser(description='create a dataset')\nparser.add_argument('--dataset', default='df2k', type=str, help='selecting different datasets')\nparser.add_argument('--artifac... | [
[
"numpy.array",
"numpy.var",
"numpy.mean"
]
] |
jalavery/gnomeR | [
"4f165774eb3c5f442881a915ee70e18a5f33b387",
"4f165774eb3c5f442881a915ee70e18a5f33b387"
] | [
"inst/CnaAnnotator.py",
"inst/AnnotatorCore.py"
] | [
"import argparse\n# from AnnotatorCore import *\nimport sys\nimport csv\nimport requests\nimport os.path\nimport logging\nimport re\nimport matplotlib\nmatplotlib.use('Agg')\nimport matplotlib.pyplot as plt\nfrom datetime import date\nimport logging\nlogging.basicConfig(level=logging.INFO)\nlog = logging.getLogger(... | [
[
"matplotlib.use"
],
[
"matplotlib.use",
"matplotlib.pyplot.gca"
]
] |
JunweiLiang/Object_Detection_Tracking | [
"f86caaec97669a6da56f1b402cca4e179a85d2f0"
] | [
"tmot/matching.py"
] | [
"import numpy as np\r\nimport scipy\r\nfrom scipy.spatial.distance import cdist\r\nimport lap # 0.4.0\r\n\r\nfrom cython_bbox import bbox_overlaps as bbox_ious\r\nfrom . import kalman_filter\r\n\r\ndef merge_matches(m1, m2, shape):\r\n O,P,Q = shape\r\n m1 = np.asarray(m1)\r\n m2 = np.asarray(m2)\r\n\r\n ... | [
[
"scipy.spatial.distance.cdist",
"numpy.empty",
"numpy.ascontiguousarray",
"numpy.asarray",
"numpy.where"
]
] |
cailab-tamu/scTenifoldXct | [
"d25ded8dfb7f2951217a30ab71eccd6b060178f6"
] | [
"tests/test_stat.py"
] | [
"import pytest\n\nimport itertools\n\nimport pandas as pd\nimport numpy as np\n\nfrom scTenifoldXct.core import null_test\n\n\ndef generate_fake_df_nn(n_ligand=3000, n_receptors=3000, n_cands=200):\n gene_names = [f\"GENE{i}\" for i in range(max(n_ligand, n_receptors))]\n iteration = itertools.product(gene_na... | [
[
"numpy.random.chisquare",
"numpy.random.lognormal",
"numpy.random.choice"
]
] |
andreyyec/Texas_Tech_AI | [
"e4e8e41c65b41a1a684f1f65d21cf5427abdb046"
] | [
"practices/week6/assignment_exercise_3.py"
] | [
"import numpy as np\nimport pandas as pd\nimport pickle\nimport tensorflow as tf\nimport sklearn.metrics\nimport matplotlib.pyplot as plt\n\n# Load the training and test data from the Pickle file\nwith open(\"../datasets/credit_card_default_dataset.pickle\", \"rb\") as f:\n train_data, train_labels, test_data,... | [
[
"tensorflow.nn.sigmoid",
"tensorflow.nn.sigmoid_cross_entropy_with_logits",
"tensorflow.placeholder",
"tensorflow.zeros",
"numpy.ceil",
"numpy.zeros",
"tensorflow.global_variables_initializer",
"matplotlib.pyplot.figure",
"tensorflow.train.AdamOptimizer",
"tensorflow.matmul... |
pengfei99/openfood | [
"2b65af02ce34bf8193d357ef3661da749d2d9671"
] | [
"siamesenetwork/siamesePreTrainedEmbeddings.py"
] | [
"# !/usr/bin/env python3\n# -*- coding: utf-8 -*-\n\"\"\"\nDefine the siamese network for one-shot learning,\nfor french short labels\n02/06/2021\n@author: milena-git, from jeremylhour courtesy\n\"\"\"\nimport torch\nimport torch.nn as nn\n\n\ndef _createEmbeddingLayer(weights_matrix, non_trainable=False):\n \"\... | [
[
"torch.nn.Linear",
"torch.tensor",
"torch.nn.Embedding.from_pretrained",
"torch.nn.Embedding",
"torch.nn.ReLU",
"torch.nn.Dropout"
]
] |
DwijayDS/fastestimator | [
"6061a4fbbeb62a2194ef82ba8017f651710d0c65",
"9b288cb2bd870f971ec4cee09d0b3205e1316a94",
"9b288cb2bd870f971ec4cee09d0b3205e1316a94"
] | [
"test/PR_test/unit_test/op/numpyop/univariate/test_autocontrast.py",
"fastestimator/trace/metric/mcc.py",
"fastestimator/backend/_iwd.py"
] | [
"# Copyright 2021 The FastEstimator 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 r... | [
[
"numpy.random.randint"
],
[
"numpy.round",
"numpy.argmax",
"sklearn.metrics.matthews_corrcoef"
],
[
"torch.cuda.is_available",
"tensorflow.is_tensor"
]
] |
yockgen/movidius | [
"cc32f1951a4d00d2250bb0d2b9000c5f2435b41a"
] | [
"ncappzoo/tensorflow/topcoder_andresduque/supporting/inferences.py"
] | [
"#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\n#\n#~ The MIT License (MIT)\n#~ Copyright 2018 ©klo86min\n#~ Permission is hereby granted, free of charge, to any person obtaining a copy \n#~ of this software and associated documentation files (the \"Software\"), to deal \n#~ in the Software without restriction, ... | [
[
"numpy.float",
"numpy.log",
"numpy.zeros"
]
] |
agarwalrounak/qmt | [
"5e8a7001cc020979636e492448abcfd894396038"
] | [
"tests/py3/test_property_map.py"
] | [
"import numpy as np\n\nfrom qmt.geometry import PropertyMap, MaterialPropertyMap\nfrom qmt.materials import Materials\n\n\nclass DummyPartMap:\n def __init__(self, part_ids):\n assert len(part_ids) == 2\n self.partIds = part_ids\n\n def __call__(self, x):\n assert np.ndim(x) >= 1\n ... | [
[
"numpy.ones",
"numpy.vectorize",
"numpy.asanyarray",
"numpy.ndim",
"numpy.where"
]
] |
abhaikollara/tensorflow | [
"4f96df3659696990cb34d0ad07dc67843c4225a9",
"4f96df3659696990cb34d0ad07dc67843c4225a9",
"4f96df3659696990cb34d0ad07dc67843c4225a9",
"4f96df3659696990cb34d0ad07dc67843c4225a9",
"4f96df3659696990cb34d0ad07dc67843c4225a9"
] | [
"tensorflow/python/kernel_tests/batch_scatter_ops_test.py",
"tensorflow/python/keras/datasets/cifar10.py",
"tensorflow/python/framework/kernels.py",
"tensorflow/python/kernel_tests/batch_matmul_op_test.py",
"tensorflow/python/keras/engine/input_spec_test.py"
] | [
"# Copyright 2015 The TensorFlow Authors. All Rights Reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless requ... | [
[
"tensorflow.python.framework.ops.IndexedSlices",
"numpy.random.seed",
"numpy.random.randn",
"numpy.ndenumerate",
"tensorflow.python.platform.test.main",
"tensorflow.python.ops.state_ops.batch_scatter_update",
"numpy.array",
"numpy.random.randint",
"tensorflow.python.ops.variabl... |
wenlianglaw/Tetris-in-Python | [
"d4f0a22c4827e7eeb44c55def3f024e0c6932ebe"
] | [
"game_client.py"
] | [
"# This file defines the back end of the Tetris game\n#\n# GameState is the base class of GameClient.\n#\n# GameClient.Run() will start two threads:\n# - _ProcessActions: Process the action list every x seconds\n# - _AutoDrop: Auto drops the current piece.\n#\n# GameClient:\n# - current piece\n# - held piece\... | [
[
"numpy.random.shuffle",
"numpy.zeros",
"numpy.packbits",
"numpy.copy",
"numpy.all",
"numpy.min",
"numpy.delete",
"numpy.array",
"numpy.pad"
]
] |
ZackPashkin/pytorch | [
"5b1f5c8f17ec4067dc9f9df98bbcc6757ab24444"
] | [
"test/test_binary_ufuncs.py"
] | [
"import torch\nimport numpy as np\n\nimport itertools\nfrom itertools import product\nimport math\nimport random\nimport unittest\nimport warnings\nimport operator\nfrom functools import partial\n\nfrom torch._six import inf, nan\nfrom torch.testing._internal.common_utils import (\n TestCase, iter_indices, TEST_... | [
[
"torch.result_type",
"torch.testing._internal.common_utils.run_tests",
"torch.rand",
"torch.testing.get_all_math_dtypes",
"torch.testing._internal.common_utils.set_default_dtype",
"torch.randn",
"torch.iinfo",
"numpy.right_shift",
"torch.device",
"torch.lerp",
"torch.sp... |
rkeulemans/exercise_public | [
"5f8020198b8b234169eea4d5e08c98344438de5d"
] | [
"helpers.py"
] | [
"from sympy import Rational, Symbol, latex, UnevaluatedExpr\nimport sympy as sp\nimport numpy as np\n\nu = lambda x : UnevaluatedExpr(x)\n\n# Helper functions\ndef explain_add(a, b):\n assert(np.shape(a) == np.shape(b))\n rows, columns = np.shape(a)\n return sp.Matrix([[Symbol(f\"({latex(u(a[i,j]))} + {lat... | [
[
"numpy.shape",
"numpy.empty"
]
] |
galactics/space-command | [
"496b054883c6464bcd8d73d72c8145ae80606336"
] | [
"space/station.py"
] | [
"import logging\nfrom numpy import degrees, pi, radians\n\nfrom beyond.frames import get_frame, create_station\nfrom beyond.errors import UnknownFrameError\n\nfrom .wspace import ws\nfrom .utils import dms2deg, deg2dms\n\n\nlog = logging.getLogger(__name__)\n\n\nclass StationDb:\n def __new__(cls):\n\n if... | [
[
"numpy.degrees",
"matplotlib.pyplot.figure",
"matplotlib.pyplot.subplots_adjust",
"matplotlib.pyplot.show",
"numpy.radians"
]
] |
boringlee24/keras_old | [
"1e1176c45c4952ba1b9b9e58e9cc4df027ab111d",
"1e1176c45c4952ba1b9b9e58e9cc4df027ab111d",
"1e1176c45c4952ba1b9b9e58e9cc4df027ab111d",
"1e1176c45c4952ba1b9b9e58e9cc4df027ab111d",
"1e1176c45c4952ba1b9b9e58e9cc4df027ab111d",
"1e1176c45c4952ba1b9b9e58e9cc4df027ab111d",
"1e1176c45c4952ba1b9b9e58e9cc4df027ab111... | [
"examples/pwr_run/checkpointing/final/final4_new2/job51.py",
"examples/pwr_run/checkpointing/final_trace/top50/job48.py",
"examples/pwr_run/checkpointing/debug/ovhd_profile/job6.py",
"examples/pwr_run/ml_regression/new_speedup_def/knn_k80.py",
"examples/pwr_run/checkpointing/nonpc_short/final1/job20.py",
... | [
"\"\"\"\n#Trains a ResNet on the CIFAR10 dataset.\n\n\"\"\"\n\nfrom __future__ import print_function\nimport keras\nfrom keras.layers import Dense, Conv2D, BatchNormalization, Activation\nfrom keras.layers import AveragePooling2D, Input, Flatten\nfrom keras.optimizers import Adam\nfrom keras.callbacks import ModelC... | [
[
"numpy.mean"
],
[
"numpy.mean"
],
[
"numpy.mean"
],
[
"sklearn.metrics.mean_squared_error",
"sklearn.neighbors.KNeighborsRegressor",
"pandas.read_csv",
"sklearn.linear_model.LinearRegression",
"matplotlib.use",
"sklearn.model_selection.train_test_split",
"numpy.... |
woanderer/neuroformer | [
"df3462d55977b6c9adcb6753e7c474b8b76e8021",
"df3462d55977b6c9adcb6753e7c474b8b76e8021"
] | [
".history/neuroformer/model_perceiver_20220116213408.py",
".history/neuroformer/model_perceiver_20220121144506.py"
] | [
"# from code.transformer_vid.utils import convert_weights\n# import rotary_embedding_torch\nfrom torch.nn.modules.activation import GELU, ReLU\n# from data.OneCombo3.trainer import TrainerConfig\nimport math\nimport numpy as np\nimport itertools\nimport logging\n\nimport torch\nimport torch.nn as nn\nfrom torch.nn ... | [
[
"torch.as_tensor",
"torch.nn.functional.softmax",
"torch.rand",
"torch.no_grad",
"torch.nn.KLDivLoss",
"scipy.optimize.linear_sum_assignment",
"torch.cuda.is_available",
"torch.log",
"torch.cat",
"torch.nn.Dropout",
"torch.cos",
"torch.optim.Adam",
"torch.sin",
... |
agramfort/pymultifracs | [
"3a8896f3f26180b05ccecb4a905b05a3ebc0308b"
] | [
"pymultifracs/simul/mrw.py"
] | [
"# Synthesis of multifractal random walk and derived processes.\n#\n# Roberto Fabio Leonarduzzi\n# January, 2019\n\nimport numpy as np\nfrom .fbm import fgn\nfrom .pzutils import gaussian_cme, gaussian_chol\nfrom numpy.fft import fft, ifft\n# import math\n# import matplotlib.pyplot as plt\n\n\ndef mrw(shape, H, lam... | [
[
"numpy.ones",
"numpy.fft.fft",
"numpy.ceil",
"numpy.fft.fft2",
"numpy.zeros",
"numpy.maximum",
"numpy.random.randn",
"numpy.exp",
"numpy.fft.ifftshift",
"numpy.arange",
"numpy.log",
"numpy.min",
"numpy.sqrt",
"numpy.mean"
]
] |
CatTiger/vnpy | [
"7901a0fb80a5b44d6fc752bd4b2b64ec62c8f84b"
] | [
"venv/lib/python3.7/site-packages/rqdatac/services/stock_status.py"
] | [
"# -*- coding: utf-8 -*-\nimport datetime\nimport warnings\n\nimport pandas as pd\nimport numpy as np\n\nfrom rqdatac.utils import to_datetime, to_date\nfrom rqdatac.validators import (\n ensure_date_range,\n ensure_date_or_today_int,\n ensure_list_of_string,\n check_items_in_container,\n ensure_orde... | [
[
"pandas.DataFrame",
"pandas.Panel"
]
] |
pazamelin/openvino | [
"b7e8ef910d7ed8e52326d14dc6fd53b71d16ed48",
"b7e8ef910d7ed8e52326d14dc6fd53b71d16ed48",
"031e998a15ec738c64cc2379d7f30fb73087c272"
] | [
"src/bindings/python/tests/test_ngraph/test_ops_binary.py",
"tools/mo/openvino/tools/mo/middle/passes/convert_data_type.py",
"src/bindings/python/tests_compatibility/test_ngraph/test_ops_multioutput.py"
] | [
"# Copyright (C) 2018-2021 Intel Corporation\n# SPDX-License-Identifier: Apache-2.0\n\nimport operator\n\nimport numpy as np\nimport pytest\n\nimport openvino.runtime.opset8 as ov\nfrom tests.runtime import get_runtime\nfrom tests.test_ngraph.util import run_op_node\n\n\n@pytest.mark.parametrize(\n \"ng_api_help... | [
[
"numpy.allclose",
"numpy.multiply",
"numpy.arange",
"numpy.power",
"numpy.array"
],
[
"numpy.array_equal",
"numpy.isfinite",
"numpy.count_nonzero"
],
[
"numpy.array",
"numpy.allclose"
]
] |
ihmeuw/cascade-at | [
"a5b1b5da1698163fd3bbafc6288968dd9c398096"
] | [
"tests/model/test_priors.py"
] | [
"import pytest\nimport numpy as np\nfrom numpy import isclose\nfrom numpy.random import RandomState\n\nfrom cascade_at.model.priors import (\n Constant,\n Gaussian,\n Uniform,\n Laplace,\n StudentsT,\n LogGaussian,\n LogLaplace,\n LogStudentsT,\n PriorError,\n)\n\n\ndef test_happy_constru... | [
[
"numpy.random.RandomState",
"numpy.all",
"numpy.isclose"
]
] |
jiangbestone/DetectRccn | [
"fb30491201f8c64d5ca75298d52aa1a20c4bc6e3"
] | [
"models/rcnn.py"
] | [
"\nfrom torch.autograd import Variable\nfrom models.proposal_target_layer_cascade import *\nimport torchvision.models as models\nfrom models.proposal import *\n#bocknet\nclass ResNet(nn.Module):\n def __init__(self, block, layers, num_classes=1000,dropout_prob=0.2):\n self.inplanes = 64\n super(Res... | [
[
"torch.autograd.Variable"
]
] |
httpsgithu/mindspore | [
"c29d6bb764e233b427319cb89ba79e420f1e2c64"
] | [
"tests/ut/python/dataset/test_rgb_hsv.py"
] | [
"# Copyright 2019 Huawei Technologies Co., Ltd\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 l... | [
[
"numpy.random.randint",
"numpy.vectorize"
]
] |
rtloftin/strategically_efficient_rl | [
"85a702b9361211d345a58cc60696e4e851d48ec4"
] | [
"algorithms/agents/intrinsic.py"
] | [
"import numpy as np\nimport scipy.signal\nfrom ray.rllib.policy.sample_batch import SampleBatch\nfrom ray.rllib.evaluation.postprocessing import Postprocessing\n\nfrom algorithms.curiosity import INTRINSIC_REWARD\n\nINTRINSIC_VALUE_TARGETS = \"intrinsic_value_targets\"\nINTRINSIC_VF_PREDS = \"intrinsic_vf_preds\"\n... | [
[
"numpy.stack",
"numpy.array"
]
] |
KaihuaTang/scene-graph-benchmark.pytorch | [
"45cd54f7465b81d3154e94fcab2b554a09637f6f"
] | [
"maskrcnn_benchmark/modeling/roi_heads/relation_head/model_transformer.py"
] | [
"\"\"\"\nBased on the implementation of https://github.com/jadore801120/attention-is-all-you-need-pytorch\n\"\"\"\nimport torch\nimport torch.nn as nn\nimport torch.nn.functional as F\nimport numpy as np\nfrom maskrcnn_benchmark.modeling.utils import cat\nfrom .utils_motifs import obj_edge_vectors, to_onehot, nms_o... | [
[
"torch.nn.utils.rnn.pad_sequence",
"torch.nn.Linear",
"torch.nn.init.xavier_normal_",
"torch.nn.functional.softmax",
"torch.nn.Softmax",
"torch.no_grad",
"torch.nn.Embedding",
"torch.nn.Conv1d",
"torch.nn.ReLU",
"torch.nn.LayerNorm",
"numpy.power",
"torch.arange",
... |
lenna-project/birds-plugin | [
"c548790dcb0593b80ea6da4605e7aa32e3f141ae"
] | [
"scripts/train.py"
] | [
"import logging\nimport numpy as np\nimport os\nimport PIL\nimport PIL.Image\nimport tensorflow as tf\n\nfrom tensorflow.keras.layers import Layer, Conv2D, MaxPool2D, Dense, Flatten, Dropout, GlobalAveragePooling2D\nfrom tensorflow.keras.applications import MobileNetV2\nfrom tensorflow.keras import layers\nfrom ten... | [
[
"tensorflow.keras.applications.MobileNetV2",
"tensorflow.keras.layers.RandomRotation",
"tensorflow.keras.layers.RandomZoom",
"tensorflow.keras.Model",
"tensorflow.keras.layers.RandomFlip",
"tensorflow.keras.layers.Dense",
"tensorflow.keras.callbacks.ModelCheckpoint",
"tensorflow.ke... |
tpimentelms/meaning2form | [
"624b3947b3ac2a7a521cf35c762fb56508236f74"
] | [
"learn_pipe/model/lstm.py"
] | [
"import torch.nn as nn\n\nfrom .base import BaseLM\n\n\nclass IpaLM(BaseLM):\n name = 'lstm'\n\n def __init__(self, vocab_size, hidden_size, nlayers=1, dropout=0.1, embedding_size=None, **kwargs):\n super().__init__(\n vocab_size, hidden_size, nlayers=nlayers, dropout=dropout, embedding_size... | [
[
"torch.nn.LSTM",
"torch.nn.Linear",
"torch.nn.Embedding",
"torch.nn.Dropout"
]
] |
j-towns/jax | [
"49f3f991d4faae22fcd9d8248f3d36575b5004f6"
] | [
"tests/lax_numpy_einsum_test.py"
] | [
"# Copyright 2018 Google LLC\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# https://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable law or agreed ... | [
[
"numpy.random.RandomState",
"numpy.ones",
"numpy.einsum"
]
] |
tanzhenyu/image_augmentation | [
"d1f8cc35cf25438556e7934e8e6c78827819ea9d"
] | [
"image_augmentation/callbacks/extra_eval.py"
] | [
"import tensorflow as tf\nfrom tensorflow.keras.callbacks import Callback\n\n\nclass ExtraValidation(Callback):\n \"\"\"Log evaluation metrics of an extra validation set. This callback\n is useful for model training scenarios where multiple validation sets\n are used for evaluation (as Keras by default, pr... | [
[
"tensorflow.summary.scalar",
"tensorflow.summary.create_file_writer"
]
] |
cristianMeli/ubatch | [
"fb3c6dccf0a9e25e25f5956e2e91ed70e9ea01ee"
] | [
"examples/flask_app.py"
] | [
"import random\nimport numpy as np\n\nfrom typing import Dict, List\n\nfrom flask import Flask\nfrom flask_restx import Resource, Api\n\n# from numpy import genfromtxt\n\nfrom ubatch import ubatch_decorator\n\n# from keras.models import load_model\nfrom sklearn.datasets import fetch_20newsgroups\nfrom sklearn.model... | [
[
"numpy.array",
"sklearn.model_selection.train_test_split",
"sklearn.datasets.fetch_20newsgroups"
]
] |
simonharris/pykmeans | [
"4d47eb12a2bbaf1b05d7ccfd0cfc9ccf78ddf86d"
] | [
"tests/initialisations/test_bradleyfayyad1998.py"
] | [
"\"\"\"\nTest for Bradley & Fayyad 1998 initialisation algorithm\n\"\"\"\n\nimport unittest\n\nimport numpy as np\n\nfrom datasets import testloader\nfrom initialisations import bradley as bfinit\nimport kmeans\n\n# pylint: disable=R0201,W0212\n\n\nclass BfTestSuite(unittest.TestCase):\n \"\"\"Test suite for B&F... | [
[
"numpy.array",
"numpy.testing.assert_array_equal"
]
] |
swharden/SWHLab | [
"a86c3c65323cec809a4bd4f81919644927094bf5"
] | [
"doc/oldcode/swhlab/core/memtest.py"
] | [
"\"\"\"\nMembrane test routines for voltage clamp experiments.\ncreates abf.MTs[sweep]={} #with keys like Ih, Ra, Rm, etc\n\nExample usage:\n abf=swhlab.ABF('../abfs/group/16701010.abf')\n swhlab.memtest.memtest(abf) #performs memtest on all sweeps\n swhlab.memtest.checkSweep(abf) #lets you eyeball check h... | [
[
"numpy.arange",
"numpy.max",
"numpy.array",
"numpy.where",
"numpy.average"
]
] |
JelleAalbers/lenstronomy | [
"6db785667ff099fa8338e972b66253b2901b2827"
] | [
"lenstronomy/LensModel/MultiPlane/multi_plane_base.py"
] | [
"import numpy as np\nfrom lenstronomy.Cosmo.background import Background\nfrom lenstronomy.LensModel.profile_list_base import ProfileListBase\nimport lenstronomy.Util.constants as const\n\n__all__ = ['MultiPlaneBase']\n\n\nclass MultiPlaneBase(ProfileListBase):\n\n \"\"\"\n Multi-plane lensing class\n\n Th... | [
[
"numpy.zeros_like",
"numpy.ones",
"numpy.argsort",
"numpy.max",
"numpy.array"
]
] |
benvcutilli/CountingPlusFriendly | [
"1947e2a765e20c87e080da22b4ecc4da1f272b02"
] | [
"Friendly/LaTeX/figures/cosinecomparison.py"
] | [
"# The Plotly^^^plotly^^^ package\nimport plotly\n\n# Importing ^^^numpy^^^\nimport numpy\n\n\n\n\ndef sigmoid(x):\n return (1 + numpy.exp(-x)) ** -1\n\n\n\n\n\n\n\n\n\nsamplesPerDimension = 500\n# Using numpy.linspace to create x and y values is from somewhere on ^^^plotly^^^'s website, most\n# likely. It is a ... | [
[
"numpy.linalg.norm",
"numpy.array",
"numpy.exp",
"numpy.expand_dims",
"numpy.stack",
"numpy.dot",
"numpy.linspace"
]
] |
530824679/YOLOv2 | [
"eff9ddbab58da970e7fb449cd1974fb810fd6023"
] | [
"model/ops.py"
] | [
"# -*- coding: utf-8 -*-\n# --------------------------------------\n# @Time : 2020/11/01\n# @Author : Oscar Chen\n# @Email : 530824679@qq.com\n# @File : ops.py\n# Description :base operators.\n# --------------------------------------\n\nimport tensorflow as tf\n\ndef leaky_relu(x):\n return tf.nn.leaky_... | [
[
"tensorflow.pad",
"tensorflow.layers.conv2d",
"tensorflow.layers.batch_normalization",
"tensorflow.space_to_depth",
"tensorflow.nn.leaky_relu",
"tensorflow.name_scope",
"tensorflow.layers.max_pooling2d"
]
] |
thaipduong/safe-control-gym | [
"69f8f627d232d50813a7fff6113dd6d5caccf930"
] | [
"safe_control_gym/controllers/mpc/gp_mpc_hexa.py"
] | [
"\"\"\"Model Predictive Control with a Gaussian Process model.\n\nBased on:\n * L. Hewing, J. Kabzan and M. N. Zeilinger, \"Cautious Model Predictive Control Using Gaussian Process Regression,\"\n in IEEE Transactions on Control Systems Technology, vol. 28, no. 6, pp. 2736-2743, Nov. 2020, doi: 10.1109/TCST.... | [
[
"numpy.diag",
"scipy.stats.norm.ppf",
"scipy.linalg.solve_discrete_are",
"numpy.vstack",
"torch.diagonal",
"numpy.savez",
"torch.from_numpy",
"numpy.absolute",
"torch.Tensor",
"numpy.eye",
"numpy.load",
"numpy.atleast_2d",
"numpy.zeros",
"numpy.arange",
... |
PouyaREZ/Wastewater_Energy_Optimization | [
"ead604b715337dc8c76871910d38965d1b8b1856"
] | [
"Plotters/Results/Plots_Paper_One.py"
] | [
"# -*- coding: utf-8 -*-\n\"\"\"\nCreated on Fri Feb 4 2020\n\n\n@Author: PouyaRZ\n\n____________________________________________________\nPlots to produce:\n1. LCC of equipment for each scenario for all the individuals\n2, SCC of equipment for each scenario for all the individuals\n\n3. SCC vs LCC scatter plot.\n\... | [
[
"matplotlib.pyplot.style.use",
"matplotlib.pyplot.legend",
"matplotlib.pyplot.xticks",
"matplotlib.pyplot.figure",
"matplotlib.pyplot.savefig",
"pandas.DataFrame",
"matplotlib.pyplot.ylabel",
"matplotlib.pyplot.close",
"matplotlib.pyplot.ylim",
"numpy.loadtxt",
"matplot... |
Felihong/wikidata-sequence-analysis | [
"1d86ad9812c90864eb2c9ab72e5e61474d439f1e"
] | [
"src/sequence_generator.py"
] | [
"import pandas as pd\nfrom itertools import groupby\nfrom operator import itemgetter\n\nclass SequenceGenerator:\n\n def __init__(self, csvfile, jsThreshold):\n self.datafile = csvfile\n self.jsThreshold = jsThreshold\n\n \"\"\"\n Convert the input csv file into dataframe\n \"\"\"\n def... | [
[
"pandas.read_csv"
]
] |
cvmxn1/OpenFermion | [
"cf53c063d0f124a02ff8776bb7f8afb110d4bde6"
] | [
"src/openfermion/resource_estimates/molecule/pyscf_utils.py"
] | [
"#coverage:ignore\n\"\"\" Drivers for various PySCF electronic structure routines \"\"\"\nfrom typing import Tuple, Optional\nimport sys\nimport h5py\nimport numpy as np\nfrom pyscf import gto, scf, ao2mo, mcscf, lo, tools, cc\nfrom pyscf.mcscf import avas\n\n\ndef stability(pyscf_mf):\n \"\"\"\n Test wave fu... | [
[
"numpy.sqrt",
"numpy.eye",
"numpy.sum",
"numpy.einsum",
"numpy.linalg.eigh",
"numpy.isclose",
"numpy.asarray",
"numpy.max",
"numpy.array"
]
] |
wenhaopeter/read_pytorch_code | [
"491f989cd918cf08874dd4f671fb7f0142a0bc4f",
"491f989cd918cf08874dd4f671fb7f0142a0bc4f",
"491f989cd918cf08874dd4f671fb7f0142a0bc4f",
"491f989cd918cf08874dd4f671fb7f0142a0bc4f",
"491f989cd918cf08874dd4f671fb7f0142a0bc4f"
] | [
"torch/testing/_internal/common_utils.py",
"test/distributed/test_ddp_under_dist_autograd.py",
"caffe2/python/data_parallel_model_test.py",
"test/test_show_pickle.py",
"caffe2/python/operator_test/bbox_transform_test.py"
] | [
"r\"\"\"Importing this file must **not** initialize CUDA context. test_distributed\nrelies on this assumption to properly run. This means that when this is imported\nno CUDA calls shall be made, including torch.cuda.device_count(), etc.\n\ntorch.testing._internal.common_cuda.py can freely initialize CUDA context wh... | [
[
"torch.testing._internal.common_cuda.initialize_cuda_context_rng",
"torch.testing._compare_tensors_internal",
"numpy.random.seed",
"numpy.array",
"torch.autograd.gradcheck",
"torch.autograd.gradcheck.gradgradcheck"
],
[
"torch.testing._internal.common_utils.run_tests"
],
[
... |
Geolem/nltk | [
"39b84d97bc857fce4fef185c69b94546b8474551"
] | [
"nltk/parse/dependencygraph.py"
] | [
"# Natural Language Toolkit: Dependency Grammars\n#\n# Copyright (C) 2001-2021 NLTK Project\n# Author: Jason Narad <jason.narad@gmail.com>\n# Steven Bird <stevenbird1@gmail.com> (modifications)\n#\n# URL: <http://nltk.org/>\n# For license information, see LICENSE.TXT\n#\n\n\"\"\"\nTools for reading and writ... | [
[
"matplotlib.pylab.savefig",
"matplotlib.pylab.yticks",
"matplotlib.pylab.show",
"matplotlib.pylab.xticks"
]
] |
leguiart/MSc_Thesis | [
"22ffc73c75d814856850f26c4586d90896b74cf3"
] | [
"evosoro_pymoo/Algorithms/RankAndNoveltySurvival.py"
] | [
"import numpy as np\n\nfrom pymoo.core.survival import Survival\nfrom pymoo.util.nds.non_dominated_sorting import NonDominatedSorting\nfrom pymoo.util.randomized_argsort import randomized_argsort\n\n# ---------------------------------------------------------------------------------------------------------\n# Surviv... | [
[
"numpy.array"
]
] |
robertklee/SENG474-DataMining | [
"85b6ff300e18320fe8b40c89d5f22fde51ba588e"
] | [
"notebooks/imgaug-playground.py"
] | [
"import imgaug as ia\nfrom imgaug import augmenters as iaa\nimport numpy as np\nfrom scipy import misc\nimport imageio\nimport cv2\n\nimport imgaug as ia\nimport imgaug.augmenters as iaa\nfrom imgaug.augmentables import Keypoint, KeypointsOnImage\n\n\nia.seed(1)\n\nimage = ia.quokka(size=(256, 256))\nkps = Keypoint... | [
[
"numpy.zeros"
]
] |
anmartinezs/pyseg_system | [
"5bb07c7901062452a34b73f376057cabc15a13c3"
] | [
"code/pyto/tomo/ctf.py"
] | [
"\"\"\"\nFunctions related to ctf.\n\nCurrently only few that allow running ctffind from console or notebook.\n\nWork in progress.\n\n# Author: Vladan Lucic (Max Planck Institute for Biochemistry)\n# $Id$\n\"\"\"\nfrom __future__ import unicode_literals\nfrom __future__ import print_function\nfrom __future__ import... | [
[
"numpy.sum",
"matplotlib.pyplot.legend",
"matplotlib.pyplot.figure",
"numpy.exp",
"matplotlib.pyplot.title",
"matplotlib.pyplot.show",
"matplotlib.pyplot.ylabel",
"numpy.log10",
"matplotlib.pyplot.ylim",
"matplotlib.pyplot.plot",
"matplotlib.pyplot.xlabel",
"numpy.l... |
a868111817/language-model-playground | [
"daecd4e39bbf8128b04aa236ad1d31cd22c3c1d9"
] | [
"test/lmp/model/_lstm/conftest.py"
] | [
"r\"\"\"Setup fixtures for testing :py:class:`lmp.model.LSTMModel`.\"\"\"\n\nimport pytest\nimport torch\n\nfrom lmp.model import LSTMModel\nfrom lmp.tknzr import BaseTknzr\n\n\n@pytest.fixture\ndef lstm_model(\n tknzr: BaseTknzr,\n d_emb: int,\n d_hid: int,\n n_hid_lyr: int,\n n_... | [
[
"torch.randint"
]
] |
hust-cec-2021/ma2bea | [
"196f8de33cc4902bd9cb1fdd5400e41f9c275b55"
] | [
"code/visualization/ucb.py"
] | [
"import os\nimport argparse\nimport numpy as np\nimport matplotlib.pyplot as plt\n\ndef get_args():\n # create argument parser\n parser = argparse.ArgumentParser()\n # parameter for problem\n parser.add_argument('--seed', type=int, default=1)\n parser.add_argument('--benchmark_id', type=int, default=... | [
[
"numpy.load",
"matplotlib.pyplot.legend",
"matplotlib.pyplot.cla",
"matplotlib.pyplot.clf",
"matplotlib.pyplot.ylabel",
"matplotlib.pyplot.ylim",
"numpy.array",
"numpy.mean"
]
] |
allisontam/chemprop | [
"87ac151c68d8a200d564b064103c4f514e29f6bd"
] | [
"chemprop/train/run_training.py"
] | [
"from argparse import Namespace\nimport csv\nfrom logging import Logger\nimport os\nfrom pprint import pformat\nfrom typing import List\n\nimport numpy as np\nfrom tensorboardX import SummaryWriter\nimport torch\nfrom tqdm import trange\nimport pickle\nfrom torch.optim.lr_scheduler import ExponentialLR\n\nfrom .eva... | [
[
"numpy.nanmean",
"numpy.array",
"torch.cuda.set_device"
]
] |
Lube-Project/ProgettoLube | [
"901ac307b68486d8289105c159ca702318bea5b0",
"cbf33971e2c2e865783ec1a2302625539186a338",
"cbf33971e2c2e865783ec1a2302625539186a338"
] | [
"ProgettoLube/WebInspector/venv/Lib/site-packages/skimage/color/tests/test_adapt_rgb.py",
"ProgettoLube/WebInspector/venv/Lib/site-packages/tensorflow_estimator/python/estimator/canned/v1/linear_testing_utils_v1.py",
"ProgettoLube/WebInspector/venv/Lib/site-packages/tensorflow/python/keras/api/_v1/keras/mixed_p... | [
"from functools import partial\n\nimport numpy as np\n\nfrom skimage import img_as_float, img_as_uint\nfrom skimage import color, data, filters\nfrom skimage.color.adapt_rgb import adapt_rgb, each_channel, hsv_value\n\n# Down-sample image for quicker testing.\nCOLOR_IMAGE = data.astronaut()[::5, ::6]\nGRAY_IMAGE = ... | [
[
"numpy.ones",
"numpy.rollaxis"
],
[
"tensorflow.queue.FIFOQueue",
"tensorflow.feature_column.categorical_column_with_hash_bucket",
"tensorflow.compat.v1.train.Optimizer",
"pandas.Series",
"numpy.sum",
"tensorflow.no_op",
"tensorflow.compat.v1.train.limit_epochs",
"tenso... |
Animatory/pytorch-image-models | [
"3ace100fcfdab3619dc71307613c42e53fb70221"
] | [
"timm/models/pit.py"
] | [
"\"\"\" Pooling-based Vision Transformer (PiT) in PyTorch\n\nA PyTorch implement of Pooling-based Vision Transformers as described in\n'Rethinking Spatial Dimensions of Vision Transformers' - https://arxiv.org/abs/2103.16302\n\nThis code was adapted from the original version at https://github.com/naver-ai/pit, orig... | [
[
"torch.nn.Linear",
"torch.nn.init.constant_",
"torch.randn",
"torch.nn.LayerNorm",
"torch.nn.Conv2d",
"torch.nn.ModuleList",
"torch.nn.Identity",
"torch.jit.is_scripting",
"torch.cat",
"torch.nn.Dropout"
]
] |
ningdez/Tianchi_Cancer_303 | [
"59e9b6f906e48e7508f455ce29b97d430791fcf5"
] | [
"mmdet/models/necks/m2fpn.py"
] | [
"'''\nThis code is based on pytorch_ssd and RFBNet.\nDetails about the modules:\n TUM - Thinned U-shaped Module\n MLFPN - Multi-Level Feature Pyramid Network\n M2Det - Multi-level Multi-scale single-shot object Detector\n\nAuthor: Qijie Zhao (zhaoqijie@pku.edu.cn)\nFinishe... | [
[
"torch.nn.BatchNorm2d",
"torch.nn.AdaptiveAvgPool2d",
"torch.nn.ModuleList",
"torch.nn.Conv2d",
"torch.nn.Sequential",
"torch.nn.Sigmoid",
"torch.nn.ReLU",
"torch.cat",
"torch.nn.functional.interpolate"
]
] |
wja30/cortex_0.31 | [
"522ec6226526dee6b4f8c3ed67bdf2b913d25de3"
] | [
"test/apis/tensorflow/sound-classifier/predictor.py"
] | [
"from scipy.io.wavfile import read\nimport numpy as np\nimport io\nimport csv\n\n\nclass TensorFlowPredictor:\n def __init__(self, tensorflow_client, config):\n self.client = tensorflow_client\n self.class_names = self.class_names_from_csv(\"class_names.csv\")\n\n def class_names_from_csv(self, ... | [
[
"numpy.array"
]
] |
MattKrecicki/PYTHON-ISOTOPIC-DEPLETION-PACKAGE | [
"d9da8be6eff4ba301f9689ce5c38a5e50856d033"
] | [
"pyIsoDep/tests/read_csv.py"
] | [
"# -*- coding: utf-8 -*-\n\"\"\"read_csv\n\nRead the different csv files\n\nCreated on Mon Oct 11 21:30:00 2021 @author: Dan Kotlyar\nLast updated on Mon Oct 11 21:45:00 2021 @author: Dan Kotlyar\n\n\"\"\"\n\nimport numpy as np\nimport pandas as pd\n\n\ndef ReadCsv(csvFile):\n\n data = pd.read_csv('bootstrap.csv... | [
[
"numpy.zeros",
"numpy.intersect1d",
"pandas.read_csv",
"numpy.array",
"numpy.unique"
]
] |
Sonata-Wang/tensorflow | [
"3e21fe5faedab3a8258d344c8ad1cec2612a8aa8"
] | [
"tensorflow/python/data/experimental/__init__.py"
] | [
"# Copyright 2017 The TensorFlow Authors. All Rights Reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless requ... | [
[
"tensorflow.python.util.all_util.remove_undocumented"
]
] |
DoranLyong/DeepFish | [
"3ea3e13653f708d4a8dcb54b990dcc2997edf4e9"
] | [
"trainval.py"
] | [
"import torch\nimport numpy as np\nimport argparse\nimport pandas as pd\nimport sys\nimport os\nfrom torch import nn\nfrom torch.nn import functional as F\nimport tqdm\nimport pprint\nfrom src import utils as ut\nimport torchvision\nfrom haven import haven_utils as hu\nfrom haven import haven_chk as hc\n\nfrom src ... | [
[
"torch.utils.data.DataLoader",
"torch.cuda.manual_seed_all",
"torch.load",
"torch.manual_seed",
"pandas.DataFrame",
"numpy.random.seed",
"torch.cuda.is_available"
]
] |
AshburnLee/models | [
"98fa58030f8ce352b3818f43897ac719ccffdffc"
] | [
"PaddleAudio/paddleaudio/features/augment.py"
] | [
"# Copyright (c) 2021 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 re... | [
[
"numpy.random.rand",
"numpy.random.randint",
"numpy.random.choice"
]
] |
bahia14/Fedot_Times_Series_Forecast | [
"995751068733541ba2f546065082709ce0fb63ae"
] | [
"fedot/core/pipelines/tuning/unified.py"
] | [
"from datetime import timedelta\nfrom functools import partial\n\nimport numpy as np\nfrom hyperopt import fmin, space_eval, tpe\n\nfrom fedot.core.data.data_split import train_test_data_setup\nfrom fedot.core.log import Log\nfrom fedot.core.pipelines.tuning.hyperparams import convert_params, get_node_params\nfrom ... | [
[
"numpy.array"
]
] |
zploskey/Theano | [
"9b3f6351d41d9f5e01b198e3de7538d7f032c409"
] | [
"theano/tensor/signal/pool.py"
] | [
"\n\"\"\"\nOps for downsampling images.\nPlanned:\nPool, DownsampleAvg, DownsampleSoftmax.\n\"\"\"\nfrom __future__ import absolute_import, print_function, division\n# This file should move along with conv.py\nimport warnings\nimport itertools\n\nimport numpy as np\nfrom six.moves import xrange\nimport six.moves.bu... | [
[
"numpy.zeros_like",
"numpy.empty",
"numpy.zeros",
"numpy.argmax",
"numpy.maximum",
"numpy.ndindex"
]
] |
huangruizhe/espresso | [
"ee658bcc959bfbe8a7a61d7374d532d082d2aa26"
] | [
"examples/classify_names/rough_work.py"
] | [
"# Online Python compiler (interpreter) to run Python online.\n# Write Python 3 code in this online editor and run it.\nimport numpy as np\nlist_a = []\nfor i in range(2):\n for j in range(5):\n list_a.append(i)\n\nlist_a = np.random.permutation(list_a)\nprint('class labels')\nprint(list_a)\nlist_a = np.a... | [
[
"numpy.random.permutation",
"numpy.where",
"numpy.array"
]
] |
jaedong27/calipy | [
"ed5b5af2654b2a25e16af4267683cafc83d72729"
] | [
"calipy/viewer.py"
] | [
"import vtk\nfrom vtk.qt.QVTKRenderWindowInteractor import QVTKRenderWindowInteractor\nimport math\nimport numpy as np\nimport numpy.matlib\nimport os\nimport json\nimport cv2\n\n# Z\n# /\n# /\n# /\n# ---------- X\n# |\n# |\n# |\n# Y\n\nclass vtkRenderer():\n def _... | [
[
"numpy.eye",
"numpy.ones",
"numpy.transpose",
"numpy.zeros",
"numpy.cross",
"numpy.matlib.repmat",
"numpy.array",
"numpy.dot",
"numpy.linalg.norm"
]
] |
wdar/cdippy | [
"ef38b3445351ec8d9d7ea30b5b0d15825d794b0b"
] | [
"cdippy/stndata.py"
] | [
"from datetime import datetime, timedelta\nfrom bisect import bisect_left\n\nimport numpy.ma as ma\n\nfrom cdippy.cdippy import CDIPnc, Archive, Realtime, RealtimeXY, Historic\nimport cdippy.timestamp_utils as tsu\nimport cdippy.utils as cu\n\n\nclass StnData(CDIPnc):\n \"\"\" \n Returns data and metadata... | [
[
"numpy.ma.concatenate"
]
] |
zoumt1633/pytorch-project-template | [
"871e00ebde6c2191de5f61b4cb7010c72b93c198"
] | [
"model/model.py"
] | [
"import torch\nimport torch.nn\nfrom torch.nn.parallel import DistributedDataParallel as DDP\n\nfrom collections import OrderedDict\nimport os.path as osp\nimport wandb\n\nfrom utils.utils import DotDict\n\n\nclass Model:\n def __init__(self, hp, net_arch, loss_f, rank=0, world_size=1):\n self.hp = hp\n ... | [
[
"torch.nn.parallel.DistributedDataParallel",
"torch.save",
"torch.device"
]
] |
ericagol/exoplanet | [
"ec270622f28cd53d3052ed44d20f30b5d2b4dcb6"
] | [
"src/exoplanet/distributions/physical_test.py"
] | [
"# -*- coding: utf-8 -*-\n\nimport numpy as np\nimport pymc3 as pm\nfrom scipy.stats import kstest\n\nfrom .base_test import _Base\nfrom .physical import ImpactParameter, QuadLimbDark\n\n\nclass TestPhysical(_Base):\n random_seed = 19860925\n\n def test_quad_limb_dark(self):\n with self._model():\n ... | [
[
"numpy.allclose",
"scipy.stats.kstest",
"numpy.all",
"numpy.shape",
"numpy.clip",
"numpy.isfinite"
]
] |
Leopard-X/MXNET | [
"7ac046c58f0815223712f77288722a7b06755ec3"
] | [
"python/mxnet/image.py"
] | [
"# pylint: disable=no-member, too-many-lines, redefined-builtin, protected-access, unused-import, invalid-name\n# pylint: disable=too-many-arguments, too-many-locals, no-name-in-module, too-many-branches, too-many-statements\n\"\"\"Read invidual image files and perform augmentations.\"\"\"\n\nfrom __future__ import... | [
[
"numpy.random.normal",
"numpy.sqrt",
"numpy.dot",
"numpy.array",
"numpy.frombuffer"
]
] |
qma16443/AIcamp_MTCNN | [
"431c3ce1cabf24266690322d525bdf7133666dc0"
] | [
"Detection/MtcnnDetector.py"
] | [
"import cv2\nimport time\nimport numpy as np\nimport sys\nsys.path.append(\"../\")\nfrom train_models.MTCNN_config import config\nfrom Detection.nms import py_nms\n\n\nclass MtcnnDetector(object):\n\n\n def __init__(self,\n detectors,\n min_face_size=25,\n stride=2... | [
[
"numpy.vstack",
"numpy.tile",
"numpy.zeros",
"numpy.round",
"numpy.hstack",
"numpy.expand_dims",
"numpy.maximum",
"numpy.where",
"numpy.array"
]
] |
stjordanis/graph4nlp | [
"c6ebde32bc77d3a7b78f86a93f19b1c057963ffa",
"c6ebde32bc77d3a7b78f86a93f19b1c057963ffa"
] | [
"graph4nlp/pytorch/test/seq_decoder/graph2seq/src/g2s_v2/core/utils/vocab_utils.py",
"graph4nlp/pytorch/modules/prediction/classification/link_prediction/ConcatFeedForwardNN.py"
] | [
"# -*- coding: utf-8 -*-\nfrom __future__ import print_function\nimport os\nimport re\nimport pickle\nimport numpy as np\nfrom collections import Counter\nfrom functools import lru_cache\n\nfrom . import constants\nfrom .data_utils import tokenize\n\nword_detector = re.compile('\\w')\n\nclass VocabModel(object):\n ... | [
[
"numpy.random.uniform",
"numpy.array",
"numpy.zeros"
],
[
"torch.tensor",
"torch.nn.ReLU"
]
] |
YinchaoGao/detectron2 | [
"04958b93e1232935e126c2fd9e6ccd3f57c3a8f3"
] | [
"detectron2/export/api.py"
] | [
"# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved.\nimport copy\nimport logging\nimport os\nimport torch\nfrom caffe2.proto import caffe2_pb2\nfrom torch import nn\n\nfrom detectron2.config import CfgNode as CN\n\nfrom .caffe2_export import export_caffe2_detection_model\nfrom .caffe2_export im... | [
[
"torch.no_grad",
"torch.jit.trace"
]
] |
UrielMaD/pandas | [
"b5233c447f3ed0ecfe256501e357326b82ce9120"
] | [
"pandas/core/frame.py"
] | [
"\"\"\"\nDataFrame\n---------\nAn efficient 2D container for potentially mixed-type time series or other\nlabeled data series.\n\nSimilar to its R counterpart, data.frame, except providing automatic data\nalignment and a host of useful data manipulation methods having to do with the\nlabeling information\n\"\"\"\nf... | [
[
"pandas.core.generic.NDFrame._set_item",
"pandas.core.reshape.melt.melt",
"pandas.core.reshape.concat.concat",
"numpy.asarray",
"pandas.core.indexing.convert_to_index_sliceable",
"pandas.core.nanops.nancorr",
"pandas.core.dtypes.cast.maybe_infer_to_datetimelike",
"pandas.core.dtype... |
gwtaylor/pyautodiff | [
"7973e26f1c233570ed4bb10d08634ec7378e2152"
] | [
"autodiff/examples/svm.py"
] | [
"\"\"\"\nLinear SVM\n==========\n\nThis script fits a linear support vector machine classifier to random data. It\nillustrates how a function defined purely by NumPy operations can be minimized\ndirectly with a gradient-based solver.\n\n\"\"\"\nimport numpy as np\nfrom autodiff.optimize import fmin_l_bfgs_b\n\n\nd... | [
[
"numpy.allclose",
"numpy.zeros",
"numpy.random.RandomState",
"numpy.maximum",
"numpy.dot",
"numpy.mean"
]
] |
hz-ants/CDPN-source- | [
"625f9a80858f8a2fb9e74f88ea83073495141693"
] | [
"lib/models/resnet_trans_head.py"
] | [
"import torch.nn as nn\nimport torch\n\nclass TransHeadNet(nn.Module):\n def __init__(self, in_channels, num_layers=3, num_filters=256, kernel_size=3, output_dim=3, freeze=False,\n with_bias_end=True):\n super(TransHeadNet, self).__init__()\n\n self.freeze = freeze\n\n if ker... | [
[
"torch.nn.BatchNorm2d",
"torch.nn.Linear",
"torch.nn.init.constant_",
"torch.no_grad",
"torch.nn.init.normal_",
"torch.nn.ModuleList",
"torch.nn.Conv2d",
"torch.nn.ReLU"
]
] |
sejaldua/duolingogogo | [
"226a2a9417238f9c3f0ce738d491b58cdf4dcbdc"
] | [
"app.py"
] | [
"import streamlit as st\nimport pandas as pd\nimport yaml\nimport duolingo\nimport seaborn as sns\nimport matplotlib.pyplot as plt\nimport matplotlib.font_manager\nfrom datetime import timezone, timedelta\nmatplotlib.rcParams['font.family'] = ['Source Han Sans CN']\n\nwith open(\"duo_credentials.yaml\", 'r') as str... | [
[
"matplotlib.pyplot.figure",
"pandas.DataFrame.from_records",
"pandas.to_datetime",
"matplotlib.pyplot.ylabel",
"pandas.pivot_table",
"matplotlib.pyplot.xlabel"
]
] |
Henley13/paper_translation_factories_2020 | [
"77558ed70467cf91062abf62e46c794bfbc08e4a"
] | [
"big-fish/bigfish/stack/postprocess.py"
] | [
"# -*- coding: utf-8 -*-\n\n\"\"\"\nFunctions used to format and clean any intermediate results loaded in or\nreturned by a bigfish method.\n\"\"\"\n\nimport numpy as np\nfrom scipy import ndimage as ndi\n\nfrom .utils import check_array, check_parameter, get_offset_value\n\nfrom skimage.measure import regionprops,... | [
[
"numpy.zeros",
"scipy.ndimage.binary_fill_holes",
"numpy.any",
"numpy.column_stack",
"numpy.isin",
"numpy.array",
"numpy.concatenate",
"numpy.nonzero"
]
] |
metamoles/metamoles | [
"251de6672029566d8becf2538684c0506fc297d0"
] | [
"deprecated/code/datacleaning.py"
] | [
"#!/usr/bin/env python\nimport Bio\nfrom Bio.KEGG import REST\nfrom Bio.KEGG import Enzyme\nimport re\nfrom Bio.KEGG import Compound\n\nimport gzip\nimport pandas as pd\nimport numpy as np\nimport matplotlib as mpl\nimport matplotlib.pyplot as plt\nimport seaborn as sns\n\ndef create_enzyme_df(path_to_file):\n \... | [
[
"pandas.DataFrame"
]
] |
rsuderman/iree-samples | [
"e7ba8e639c1bdd763793a6cf21930fb238607b3f"
] | [
"tflitehub/mobilenet_quant_test.py"
] | [
"# RUN: %PYTHON %s\n\nimport absl.testing\nimport numpy\nimport test_util\nimport urllib.request\n\nfrom PIL import Image\n\nmodel_path = \"https://tfhub.dev/tensorflow/lite-model/mobilenet_v2_1.0_224_quantized/1/default/1?lite-format=tflite\"\n\nclass MobilenetQuantTest(test_util.TFLiteModelTest):\n def __init__(... | [
[
"numpy.isclose"
]
] |
WyckliffeAluga/data-chronicles | [
"5219fe9cdbafb9fd7be88727483952c4c13f2790"
] | [
"Core Concepts/Deep Learning/3_RELU_activation_function.py"
] | [
"import numpy as np\n\ndef relu(input):\n '''Define your relu activation function here'''\n # Calculate the value for the output of the relu function: output\n output = max(input, 0)\n \n # Return the value just calculated\n return(output)\n\ninput_data = np.array([3,5])\n\n# Calculate node 0 valu... | [
[
"numpy.array"
]
] |
cwegg/astro-dynamo | [
"024f8aad8785488e9ae3328095d3d9c53b3e31b0"
] | [
"astro_dynamo/model.py"
] | [
"import math\nfrom typing import List, Union, Tuple\n\nimport torch\nimport torch.nn as nn\n\nfrom astro_dynamo.snap import SnapShot\nfrom .snaptools import align_bar\n\n\ndef _symmetrize_matrix(x, dim):\n \"\"\"Symmetrize a tensor along dimension dim\"\"\"\n return (x + x.flip(dims=[dim])) / 2\n\n\nclass Dyn... | [
[
"torch.sum",
"torch.stack",
"torch.cos",
"torch.asin",
"torch.as_tensor",
"torch.linspace",
"torch.zeros_like",
"torch.no_grad",
"torch.sin",
"torch.nn.ModuleList",
"torch.meshgrid",
"torch.isfinite",
"torch.atan2"
]
] |
HennyJie/BrainGB | [
"96cf6711e2f2e6fa48b699ce3c0d6e318955c4de"
] | [
"src/dataset/transforms.py"
] | [
"import torch\nfrom node2vec import Node2Vec as Node2Vec_\nfrom .brain_data import BrainData\nfrom torch_geometric.data import Data\nfrom networkx.convert_matrix import from_numpy_matrix\nfrom .utils import binning, LDP\nimport networkx as nx\nfrom .base_transform import BaseTransform\nfrom numpy import linalg as L... | [
[
"torch.ones",
"torch.sparse_coo_tensor",
"torch.zeros",
"torch.cat",
"torch.Tensor",
"torch.nan_to_num"
]
] |
oahziur/probability | [
"ca14fa8924749593fd21e2b6389551f964527eec",
"11645be43d2845da65a4fbafde4cfa95780280c0"
] | [
"tensorflow_probability/python/bijectors/tanh.py",
"tensorflow_probability/python/mcmc/transformed_kernel_test.py"
] | [
"# Copyright 2018 The TensorFlow Probability 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 a... | [
[
"tensorflow.nn.tanh",
"numpy.log",
"tensorflow.atanh",
"tensorflow.square",
"tensorflow.nn.softplus"
],
[
"tensorflow.stack",
"tensorflow.dimension_value",
"tensorflow.squared_difference",
"tensorflow.reduce_mean",
"tensorflow.matmul",
"tensorflow.Graph",
"numpy... |
iamlmn/monte_carlo_analysis | [
"45f7af2b439f80bce429a94257a1167c9d5f4a2c"
] | [
"scenario analysis/portfolio_evaluation.py"
] | [
"import yfinance\nimport pandas as pd\nimport numpy as np\nimport matplotlib.pyplot as plt\nfrom tqdm import tqdm\n\ndef _simulate_returns(historical_returns,forecast_days):\n return historical_returns.sample(n = forecast_days, \n replace = True).reset_index(drop = True)\n\n\ndef ... | [
[
"matplotlib.pyplot.legend",
"matplotlib.pyplot.grid",
"pandas.DataFrame",
"numpy.std",
"numpy.percentile",
"matplotlib.pyplot.show",
"matplotlib.pyplot.ylabel",
"matplotlib.pyplot.hist",
"numpy.sqrt",
"matplotlib.pyplot.plot",
"matplotlib.pyplot.fill_between",
"matp... |
rtg0795/tfx | [
"63c31b719896eef645df3850d0e6b946e44cd059",
"63c31b719896eef645df3850d0e6b946e44cd059",
"63c31b719896eef645df3850d0e6b946e44cd059"
] | [
"tfx/orchestration/portable/python_executor_operator_test.py",
"tfx/orchestration/kubeflow/kubeflow_dag_runner_test.py",
"tfx/utils/name_utils_test.py"
] | [
"# Copyright 2020 Google LLC. 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 required by appl... | [
[
"tensorflow.test.main"
],
[
"tensorflow.test.main"
],
[
"tensorflow.test.main"
]
] |
DamienIrving/ocean-analysis | [
"23a6dbf616fb84e6e158e32534ffd394e0df2e3e"
] | [
"visualisation/drift_paper/plot_ohc_drift.py"
] | [
"\"\"\"\nFilename: plot_ohc_drift.py\nAuthor: Damien Irving, irving.damien@gmail.com\nDescription: Create a bar chart showing drift in ocean heat content\n and its thermal and barystatic components \n\n\"\"\"\n\n# Import general Python modules\n\nimport sys\nimport os\nimport re\nimport pdb... | [
[
"matplotlib.pyplot.axvline",
"pandas.read_csv",
"matplotlib.pyplot.savefig",
"numpy.arange",
"matplotlib.pyplot.ylabel",
"matplotlib.pyplot.axhspan"
]
] |
vipavlovic/pyprobml | [
"59a2edc682d0163955db5e2f27491ad772b60141",
"59a2edc682d0163955db5e2f27491ad772b60141",
"59a2edc682d0163955db5e2f27491ad772b60141"
] | [
"scripts/emnist_viz_tf.py",
"scripts/spectral_clustering_demo.py",
"scripts/logreg_iris_bayes_2d_pymc3.py"
] | [
"\n\n\nimport superimport\n\nimport numpy as np\nimport matplotlib.pyplot as plt\nimport pyprobml_utils as pml\n\nimport tensorflow as tf\nimport tensorflow_datasets as tfds\n\nnp.random.seed(0)\n\nds, info = tfds.load('emnist', split='test', shuffle_files=False, with_info=True) # horribly slow\nprint(info)\n\n\npl... | [
[
"matplotlib.pyplot.xticks",
"matplotlib.pyplot.figure",
"matplotlib.pyplot.grid",
"numpy.random.seed",
"matplotlib.pyplot.title",
"matplotlib.pyplot.subplot",
"matplotlib.pyplot.show",
"matplotlib.pyplot.imshow",
"matplotlib.pyplot.yticks"
],
[
"numpy.sum",
"matplot... |
MatthiasDR96/industrial_robotics_simulator | [
"9039e7a581ce97c583c73294e9937664de90530b"
] | [
"src/Interpolator.py"
] | [
"import numpy as np\nfrom sympy import *\n\n\ndef interpolate_cubic(p1, p2, k_traj, t):\n '''\n Computes a smooth cubic polynomail between 2 N-dimensional points\n Input:\n p1: Nx1 numpy array the first point\n p2: Nx1 numpy array the second poi... | [
[
"numpy.sqrt",
"numpy.linalg.solve",
"numpy.zeros",
"numpy.subtract",
"numpy.asarray",
"numpy.delete",
"numpy.array",
"numpy.dot",
"numpy.linspace"
]
] |
AwhLorraine/mshoot | [
"d6981fa37c55da0457ac0371f9850743858a3543",
"d6981fa37c55da0457ac0371f9850743858a3543"
] | [
"test/test_mpc.py",
"examples/tutorial/tutorial.py"
] | [
"import unittest\nimport os\n\nimport numpy as np\nimport pandas as pd\nfrom scipy.signal import StateSpace\nimport matplotlib.pyplot as plt\n\nimport mshoot\n\n\ndef cfun(xdf, ydf):\n \"\"\"\n :param ydf: DataFrame, model states\n :param ydf: DataFrame, model outputs\n :return: float\n \"\"\"\n q... | [
[
"numpy.arange",
"numpy.sum",
"pandas.Index",
"numpy.full"
],
[
"numpy.zeros",
"pandas.Index",
"numpy.arange",
"matplotlib.pyplot.show",
"numpy.random.rand",
"numpy.sin",
"numpy.where",
"numpy.full"
]
] |
edges-collab/edges-cal | [
"9b7b28f71e1aa5347f901af38ef3bc0d28766e21"
] | [
"src/edges_cal/cal_coefficients.py"
] | [
"# -*- coding: utf-8 -*-\n\"\"\"\nThe main user-facing module of ``edges-cal``.\n\nThis module contains wrappers around lower-level functions in other modules, providing\na one-stop interface for everything related to calibration.\n\"\"\"\nfrom __future__ import annotations\n\nimport attr\nimport h5py\nimport numpy... | [
[
"numpy.ones_like",
"numpy.nanvar",
"numpy.nanmean",
"scipy.interpolate.InterpolatedUnivariateSpline",
"matplotlib.pyplot.gcf",
"numpy.abs",
"numpy.isnan",
"numpy.mean",
"matplotlib.pyplot.ticklabel_format",
"matplotlib.pyplot.subplots",
"numpy.poly1d",
"numpy.square... |
aivision2020/OctSceneScan | [
"3b22ecb4f701270f457a7c2d2702f758b8d584cf"
] | [
"test_module.py"
] | [
"from pathlib import Path\nimport copy\nimport time\nimport torch.optim as optim\nimport numpy as np\nimport torch\nfrom torch.autograd import Variable\nfrom model import *\nfrom data_utils import *\nimport torch.nn as nn\nfrom loguru import logger\n\nfeature_dim = 8\nblock_size = 16\npad=2\nn_conv=3\nthresh=0.5\nd... | [
[
"torch.utils.data.DataLoader",
"numpy.diff",
"torch.rand",
"torch.nn.BatchNorm3d",
"torch.save",
"numpy.abs",
"torch.nn.ConvTranspose3d",
"torch.all",
"torch.from_numpy",
"numpy.random.rand",
"torch.isfinite",
"torch.ones_like",
"torch.nn.ReplicationPad3d",
... |
soumitrasamanta/FragGenie | [
"9ce493d88e3479a286ce88dc0c5b199ea7c7e441"
] | [
"fragment.py"
] | [
"\"\"\"\n-----------------------------------------------------------------------------\nAUTHOR: Soumitra Samanta (soumitramath39@gmail.com)\n-----------------------------------------------------------------------------\n\"\"\"\n\nimport subprocess\nimport os\nimport numpy as np\nfrom datetime import datetime\nimpor... | [
[
"pandas.read_csv",
"numpy.fromstring",
"pandas.DataFrame.from_dict",
"numpy.random.random"
]
] |
BioGeek/annotated_deep_learning_paper_implementations | [
"e2516cc3063cdfdf11cda05f22a10082297aa33e"
] | [
"labml_nn/normalization/group_norm/experiment.py"
] | [
"\"\"\"\n---\ntitle: CIFAR10 Experiment to try Group Normalization\nsummary: >\n This trains is a simple convolutional neural network that uses group normalization\n to classify CIFAR10 images.\n---\n\n# CIFAR10 Experiment for Group Normalization\n\"\"\"\n\nimport torch.nn as nn\n\nfrom labml import experiment\nf... | [
[
"torch.nn.MaxPool2d",
"torch.nn.Linear",
"torch.nn.Conv2d",
"torch.nn.Sequential",
"torch.nn.ReLU"
]
] |
kdeweese/DualRandomizedKaczmarz | [
"3d339e893fe1dcb91677f3240047801ca3c43162"
] | [
"drkcode/python/kktmat.py"
] | [
"#!/usr/bin/env python\n# kktmat.py -- KKT matrix from Laplacian matrix\n#\n# Copyright (C) <2016> <Kevin Deweese>\n# All rights reserved.\n#\n# This software may be modified and distributed under the terms\n# of the BSD license. See the LICENSE file for details.\n\nimport scipy\n\ndef kktmat(L):\n mat=scipy.sp... | [
[
"scipy.concatenate",
"scipy.ones",
"scipy.sparse.coo_matrix",
"scipy.sparse.tril",
"scipy.arange",
"scipy.array"
]
] |
serre-lab/brownUnconference | [
"c51758f0bf695648832448c5c166e2a8dea14268"
] | [
"scripts/embeddings.py"
] | [
"import argparse\nimport csv\n\nimport torch\nimport transformers\n\n\ndef parse_arguments():\n parser = argparse.ArgumentParser(description=\"MiniConf Portal Command Line\")\n\n parser.add_argument(\"papers\", default=False, help=\"papers file to parse\")\n return parser.parse_args()\n\n\nif __name__ == \... | [
[
"torch.save",
"torch.no_grad"
]
] |
KeAWang/wilds | [
"3b808a84bd477d7877b77675eec2953128a87033"
] | [
"examples/algorithms/groupDRO.py"
] | [
"import torch\nfrom algorithms.single_model_algorithm import SingleModelAlgorithm\nfrom models.initializer import initialize_model\n\nclass GroupDRO(SingleModelAlgorithm):\n \"\"\"\n Group distributionally robust optimization.\n\n Original paper:\n @inproceedings{sagawa2019distributionally,\n ... | [
[
"torch.zeros",
"torch.exp"
]
] |
IewNixIl/graduation_project_under | [
"67d0345208511bb06c35c3453227b2fa4ebef4a3"
] | [
"DATA/Labeling.py"
] | [
"import numpy\nfrom matplotlib import pyplot\nimport gdal\nfrom skimage import io,exposure\nfrom skimage.segmentation import slic,mark_boundaries\nimport os\nfrom PIL import Image\nimport shelve\nimport sys\nsys.path.append('..')\nfrom Config import config\n\n\n\n\ndef seg(path,n_segments=500, compactness=20):\n ... | [
[
"numpy.zeros",
"matplotlib.pyplot.figure",
"matplotlib.pyplot.get_current_fig_manager",
"matplotlib.pyplot.show",
"numpy.array",
"numpy.where",
"numpy.unique"
]
] |
chenzhengda/tensorflow | [
"8debb698097670458b5f21d728bc6f734a7b5a53"
] | [
"tensorflow/python/ipu/keras/layers/recomputation.py"
] | [
"# Copyright 2021 The TensorFlow Authors. All Rights Reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless requ... | [
[
"tensorflow.python.ipu.ops.pipelining_ops.recomputation_checkpoint"
]
] |
leander-dsouza/Gazebo | [
"4e4c92115c9132b096f9b5a7fc9a9c0f5ed9e598"
] | [
"scripts/Tennis Ball Detection/ball_detection_taskphase.py"
] | [
"#!/usr/bin/env python3\nimport rospy\nimport cv2\nfrom sensor_msgs.msg import Image\nfrom cv_bridge import CvBridge\nimport numpy as np\n\n\n\nkernel = cv2.getStructuringElement(cv2.MORPH_ELLIPSE,(5, 5))\nkernel1= cv2.getStructuringElement(cv2.MORPH_ELLIPSE,(3, 3))\n\naratio = 1.0\n\ndef nothing(x):\n pass\n\n\... | [
[
"numpy.int0",
"numpy.vstack",
"numpy.zeros",
"numpy.arange",
"numpy.hstack",
"numpy.array",
"numpy.round"
]
] |
rcourivaud/video-to-pose3D | [
"b908014fe2c531c075c11cee72bb798120f970c2"
] | [
"joints_detectors/Alphapose/yolo/video_demo_half.py"
] | [
"from __future__ import division\nimport time\nimport torch \nimport torch.nn as nn\nfrom torch.autograd import Variable\nimport numpy as np\nimport cv2 \nfrom .util import *\nfrom .darknet import Darknet\nfrom .preprocess import prep_image, inp_to_image, letterbox_image\nimport pandas as pd\nimport random \nimport... | [
[
"torch.FloatTensor",
"torch.min",
"torch.autograd.Variable",
"torch.cuda.is_available",
"torch.from_numpy",
"torch.clamp"
]
] |
tinapiao/Software-IC-Automation | [
"74b23cd94aa6e4658b110e93b5deb635e014f3a6"
] | [
"laygo/generators/serdes/des_layout_generator_woM5.py"
] | [
"#!/usr/bin/python\n########################################################################################################################\n#\n# Copyright (c) 2014, Regents of the University of California\n# All rights reserved.\n#\n# Redistribution and use in source and binary forms, with or without modification... | [
[
"numpy.array"
]
] |
cypher-me/HAS-Qualifier-Challenges | [
"bb795303716155dad4a930880a58fecb5d9b50c5"
] | [
"centroids/challenge/ImageGen.py"
] | [
"from scipy import signal\nfrom scipy import misc\nfrom scipy import stats as st\nimport numpy as np\n\nW = 128\nL = 128\nBody_Width = 3\nBorder = Body_Width+1\nPoints = 10\nNoise_Max = 10\nBody_Separation = 15\nBody_Scale = 30\nOvScale = 3\n\n\ndef gkern(kernlen=21, nsig=3):\n ''' 2D Gaussian Kernel. '''\n x... | [
[
"numpy.ones",
"numpy.ceil",
"numpy.zeros",
"numpy.mean",
"numpy.floor",
"numpy.abs",
"numpy.max",
"scipy.signal.convolve2d",
"numpy.random.rand",
"numpy.array",
"numpy.linspace",
"numpy.outer",
"scipy.stats.norm.cdf"
]
] |
xuanxu/py-pde | [
"de33d938aea8680eff872ae1b64569895662a248"
] | [
"pde/trackers/trackers.py"
] | [
"\"\"\"\nModule defining classes for tracking results from simulations.\n\nThe trackers defined in this module are:\n\n.. autosummary::\n :nosignatures:\n\n CallbackTracker\n ProgressTracker\n PrintTracker\n PlotTracker\n DataTracker\n SteadyStateTracker\n RuntimeTracker\n ConsistencyTracker\n M... | [
[
"numpy.allclose",
"pandas.DataFrame",
"numpy.isclose",
"numpy.all",
"numpy.array",
"numpy.flatnonzero",
"numpy.isfinite"
]
] |
NunoEdgarGFlowHub/pgmpy | [
"ac0ecc8f5bdd14999c386c6b00a3ce77407b83ce"
] | [
"pgmpy/readwrite/XMLBIF.py"
] | [
"#!/usr/bin/env python\n\ntry:\n from lxml import etree\nexcept ImportError:\n try:\n import xml.etree.ElementTree as etree\n except ImportError:\n #try:\n # import xml.etree.cElementTree as etree\n # commented out because xml.etree.cElementTree is giving errors with dicti... | [
[
"numpy.array"
]
] |
peterwauligmann/sparse_mm | [
"344c06c183854f72224c1e88ad2ced2e092d4efb"
] | [
"matmul.py"
] | [
"from typing import Tuple\n\nfrom codegen.ast import *\nfrom codegen.sugar import *\nfrom codegen.forms import *\nfrom codegen.precision import *\n\nimport scripts.old_arm\nimport scripts.max_bn_knl\n\nfrom cursors import *\n\nimport architecture\nimport numpy\n\ndef decompose_pattern(k, n, pattern:Matrix[bool], bk... | [
[
"numpy.zeros"
]
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.