repo_name
stringlengths
6
130
hexsha
list
file_path
list
code
list
apis
list
koelling/amplimap
[ "cbd5b7b8c2f703982d8964a3c77bd350a47f08a6" ]
[ "amplimap/coverage.py" ]
[ "# -*- coding: utf-8 -*-\n\"\"\"\nThis module contains methods for processing and aggregating coverage files generated by ``bedtools``.\n\"\"\"\n\nimport pandas as pd\nimport numpy as np\nimport re\nimport os\n\nfrom .reader import read_sample_info\n\ncov_cols = ['Target', 'min_coverage', 'sum_coverage', 'basepairs...
[ [ "pandas.read_csv" ] ]
joey12300/Paddle
[ "59102c6dcd2def3091f5c37816354ac69d669809" ]
[ "python/paddle/fluid/tests/unittests/xpu/test_softmax_with_cross_entropy_op_xpu.py" ]
[ "# Copyright (c) 2020 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.log", "numpy.full", "numpy.apply_along_axis", "numpy.zeros_like", "numpy.prod", "numpy.random.uniform", "numpy.sum", "numpy.random.randint" ] ]
computationalartist/tensorflow
[ "b89cf636c412abdff53b3e8f201bde671c92209d", "b89cf636c412abdff53b3e8f201bde671c92209d", "b89cf636c412abdff53b3e8f201bde671c92209d" ]
[ "tensorflow/python/kernel_tests/math_ops/argmax_op_test.py", "tensorflow/compiler/mlir/tfrt/python_tests/tf_const_test.py", "tensorflow/lite/testing/op_tests/multinomial.py" ]
[ "# Copyright 2015 The TensorFlow Authors. All Rights Reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless requ...
[ [ "tensorflow.python.ops.math_ops.argmax", "numpy.arange", "numpy.random.shuffle", "tensorflow.python.ops.array_ops.zeros", "tensorflow.python.platform.test.main", "numpy.random.randn", "tensorflow.python.framework.test_util.is_xla_enabled", "numpy.array", "numpy.zeros", "ten...
QuESt-Calculator/pyscf
[ "0ed03633b699505c7278f1eb501342667d0aa910", "0ed03633b699505c7278f1eb501342667d0aa910", "0ed03633b699505c7278f1eb501342667d0aa910", "0ed03633b699505c7278f1eb501342667d0aa910", "0ed03633b699505c7278f1eb501342667d0aa910", "0ed03633b699505c7278f1eb501342667d0aa910", "0ed03633b699505c7278f1eb501342667d0aa91...
[ "pyscf/grad/casci.py", "pyscf/symm/test/test_Dmatrix.py", "pyscf/ao2mo/test/test_incore.py", "pyscf/lib/test/test_misc.py", "pyscf/mp/test/test_ump2.py", "pyscf/pbc/cc/eom_kccsd_rhf_ip.py", "pyscf/scf/_response_functions.py", "pyscf/dft/uks.py", "pyscf/gw/gw_exact.py", "pyscf/agf2/mpi_helper.py" ]
[ "#!/usr/bin/env python\n# Copyright 2014-2020 The PySCF Developers. 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/LIC...
[ [ "numpy.dot", "numpy.einsum", "numpy.arange", "numpy.zeros_like", "numpy.zeros" ], [ "numpy.dot", "numpy.random.random", "numpy.linalg.norm", "numpy.random.seed" ], [ "numpy.random.random", "numpy.allclose", "numpy.random.seed" ], [ "numpy.all", "...
tsheaff/keras
[ "ee227dda766d769b7499a5549e8ed77b5e88105b", "ee227dda766d769b7499a5549e8ed77b5e88105b", "ee227dda766d769b7499a5549e8ed77b5e88105b", "ee227dda766d769b7499a5549e8ed77b5e88105b", "ee227dda766d769b7499a5549e8ed77b5e88105b", "ee227dda766d769b7499a5549e8ed77b5e88105b", "ee227dda766d769b7499a5549e8ed77b5e88105...
[ "keras/utils/layer_utils_test.py", "keras/optimizers/optimizer_v2/rmsprop.py", "keras/layers/preprocessing/hashing_test.py", "keras/engine/base_layer_test.py", "keras/layers/reshaping/up_sampling3d.py", "keras/preprocessing/dataset_utils.py", "keras/layers/reshaping/permute.py", "keras/layers/pooling/...
[ "# Copyright 2020 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.compat.v2.io.gfile.exists", "numpy.random.random", "tensorflow.compat.v2.test.main", "tensorflow.compat.v2.__internal__.tf2.enabled" ], [ "tensorflow.compat.v2.compat.v1.assign", "tensorflow.compat.v2.raw_ops.ResourceApplyCenteredRMSProp", "tensorflow.compat.v2.control_...
systemquant/book-pandas-for-finance
[ "90b7eb9be1de20a12ae72b9bb5d51424a979b174", "90b7eb9be1de20a12ae72b9bb5d51424a979b174" ]
[ "old/03/08.py", "old/02/28.py" ]
[ "from pandas import Series\n\ndata = [1000, 2000, 3000]\nindex = [\"메로나\", \"구구콘\", \"하겐다즈\"]\ns = Series(data=data, index=index)\n\nprint(s.loc['메로나':'구구콘'])\n", "import numpy as np\n\ndata = [1, 2, 3]\narr = np.array(data)\ndata2 = arr * 10\nprint(data2)" ]
[ [ "pandas.Series" ], [ "numpy.array" ] ]
vidursatija/SongWCT
[ "c892c2833ff9f85cfb31788babf016699c5eec8f" ]
[ "models.py" ]
[ "import torch\nimport torch.nn as nn\ntry:\n from torch.hub import load_state_dict_from_url\nexcept ImportError:\n from torch.utils.model_zoo import load_url as load_state_dict_from_url\nfrom torchsummary import summary\nimport numpy as np\n\n\nclass X_Enc(nn.Module):\n def __init__(self, layers, num_class...
[ [ "torch.nn.Sequential", "torch.load", "torch.nn.init.constant_", "torch.nn.MaxPool1d", "torch.nn.init.normal_", "torch.cuda.is_available", "torch.nn.Conv1d", "torch.nn.ConvTranspose1d", "torch.nn.ReLU", "torch.nn.MaxUnpool1d", "numpy.zeros", "torch.nn.init.kaiming_no...
eembees/solar_flares
[ "9022f92c0577efaf06d7425002995e4fa4df74b4" ]
[ "reading_data.py" ]
[ "from pathlib import Path\nimport ijson\nimport numpy as np # linear algebra\nimport pandas as pd # data processing, CSV file I/O (e.g. pd.read_csv)\nfrom json import JSONDecoder, JSONDecodeError # for reading the JSON data files\nimport re # for regular expressions\nimport os # for os related operations\nfrom...
[ [ "pandas.concat", "numpy.savez", "pandas.Series", "numpy.isnan", "numpy.arange", "numpy.nan_to_num", "pandas.Index", "pandas.read_json", "pandas.DataFrame.from_dict", "numpy.load", "numpy.array" ] ]
geoffreynyaga/ostrich-project
[ "157cd7a3c3d9014e31ef21ca21de43f04d039997" ]
[ "CORE/engines/constraint.py" ]
[ "#!/usr/bin/env python3\r\n# -*- coding:utf-8 -*-\r\n##################################################################################\r\n# File: c:\\Projects\\KENYA ONE PROJECT\\CORE\\engines\\constraint.py #\r\n# Project: c:\\Projects\\KENYA ONE PROJECT\\CORE\\engines #...
[ [ "matplotlib.pylab.show", "numpy.sqrt", "numpy.abs", "numpy.arange", "numpy.cos", "matplotlib.pylab.plot", "matplotlib.pylab.legend", "numpy.array", "matplotlib.pylab.axvline" ] ]
nkuxx161/baseline-SR
[ "c4caf06c5a5a88d7f8e27069018316b319f0913b" ]
[ "plot.py" ]
[ "import pandas as pd\nimport os\n\ncurve_name = '5_k7'\n\ndata = pd.read_csv(os.path.join('result', curve_name+'.csv'))\ntimestamp = data['timestamp']\nvalue = data['value']\nmag = data['mag']\nisAnomaly = data['isAnomaly']\n\nimport matplotlib\nmatplotlib.use(\"Agg\")\nimport matplotlib.pyplot as plt \n\nplt.subpl...
[ [ "matplotlib.pyplot.title", "matplotlib.use", "matplotlib.pyplot.plot", "matplotlib.pyplot.subplot", "matplotlib.pyplot.close", "matplotlib.pyplot.show" ] ]
catniplab/ML-music-analysis
[ "793d54ed16166fbcd9acf4eec24998892334e064", "793d54ed16166fbcd9acf4eec24998892334e064" ]
[ "models/_sources/model_trainer_c4d127b7cc8008ff2c0c849733ead6e1.py", "models/_sources/logistic_regression_207b05cd2ed83ee471bd1fd9fb4270d4.py" ]
[ "\"\"\"\nThis script creates an instance of a sacred experiment and defines default configurations for training a neural network or a regression model.\n\"\"\"\n\nfrom src.neural_nets.models import get_model\nfrom src.neural_nets.load_data import get_loader\nfrom src.neural_nets.metrics import MaskedBCE, Accuracy, ...
[ [ "torch.optim.lr_scheduler.LambdaLR", "numpy.random.seed", "numpy.linspace", "torch.autograd.set_detect_anomaly", "torch.manual_seed", "torch.cuda.device", "numpy.save", "torch.cuda.is_available", "torch.device", "torch.distributions.Uniform", "numpy.zeros", "torch.s...
dutxubo/nni
[ "c16f4e1c89b54b8b80661ef0072433d255ad2d24", "c16f4e1c89b54b8b80661ef0072433d255ad2d24", "c16f4e1c89b54b8b80661ef0072433d255ad2d24", "c16f4e1c89b54b8b80661ef0072433d255ad2d24", "c16f4e1c89b54b8b80661ef0072433d255ad2d24", "c16f4e1c89b54b8b80661ef0072433d255ad2d24", "c16f4e1c89b54b8b80661ef0072433d255ad2d2...
[ "test/ut/tools/annotation/testcase/usercode/mnist.py", "nni/algorithms/feature_engineering/gradient_selector/gradient_selector.py", "examples/trials/mnist-keras/mnist-keras.py", "test/ut/sdk/test_networkmorphism_tuner.py", "test/ut/compression/v1/test_transformer_pruners.py", "test/ut/compression/v2/test_...
[ "# -*- encoding:utf8 -*-\n\n\"\"\"A deep MNIST classifier using convolutional layers.\n\"\"\"\n\nfrom __future__ import absolute_import\nfrom __future__ import division\nfrom __future__ import print_function\n\nimport logging\nimport math\nimport tempfile\nimport tensorflow as tf\n\nfrom tensorflow.examples.tutoria...
[ [ "tensorflow.nn.softmax_cross_entropy_with_logits", "tensorflow.nn.max_pool", "tensorflow.cast", "tensorflow.train.AdamOptimizer", "tensorflow.get_default_graph", "tensorflow.nn.conv2d", "tensorflow.Variable", "tensorflow.name_scope", "tensorflow.Session", "tensorflow.argmax...
jessehui/occlum
[ "8a5f3033881c090340d678f2aecdca4ac6355bf4" ]
[ "demos/python/python_musl/demo.py" ]
[ "import pandas as pd\nimport numpy as np\nfrom sklearn.datasets import dump_svmlight_file\n\ndf1 = pd.read_csv(\"./dataset/input_label.csv\")\ndf2 = pd.read_csv(\"./dataset/input.csv\")\nres = pd.merge(df1, df2, how='left', left_on='id', right_on='id')\n\nX = res[np.setdiff1d(res.columns,['label','id'])]\ny = res.l...
[ [ "pandas.merge", "pandas.read_csv", "sklearn.datasets.dump_svmlight_file", "numpy.setdiff1d" ] ]
adrenadine33/graphvite
[ "34fc203f96ff13095073c605ecfcae32213e7f6a" ]
[ "python/graphvite/application/application.py" ]
[ "# Copyright 2019 MilaGraph. 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 appli...
[ [ "numpy.linspace", "numpy.asarray", "torch.sum", "numpy.concatenate", "numpy.all", "torch.set_grad_enabled", "numpy.mean", "torch.topk", "numpy.where", "torch.ones", "numpy.ones_like", "numpy.uint32", "numpy.unique", "numpy.arange", "numpy.std", "nump...
zhoudoufu/lingvo
[ "bd0f89809942fd0508ff43bd4b6bca1b598220cb", "bd0f89809942fd0508ff43bd4b6bca1b598220cb", "bd0f89809942fd0508ff43bd4b6bca1b598220cb", "bd0f89809942fd0508ff43bd4b6bca1b598220cb", "bd0f89809942fd0508ff43bd4b6bca1b598220cb" ]
[ "lingvo/core/test_utils_test.py", "lingvo/tasks/asr/model_test.py", "lingvo/core/conv_layers_with_time_padding.py", "lingvo/core/base_model.py", "lingvo/tasks/asr/frontend.py" ]
[ "# Lint as: python2, python3\n# Copyright 2018 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/...
[ [ "tensorflow.test.main" ], [ "tensorflow.Graph", "tensorflow.all_variables", "tensorflow.test.main", "tensorflow.trainable_variables", "tensorflow.global_variables_initializer", "tensorflow.set_random_seed" ], [ "tensorflow.nn.l2_normalize", "tensorflow.nn.convolution", ...
garaytc/reinforcement
[ "e6af258bf2ac3b45c20e0ed3d2f58ca7bc2b232f" ]
[ "tests/agents/test_agent_interface.py" ]
[ "import pytest\nimport torch\nfrom gym.spaces import Discrete, MultiDiscrete, MultiBinary, Dict, Tuple, Box\n\nfrom blobrl.agents import AgentInterface\n\n\nclass MOCKAgentInterface(AgentInterface):\n def __init__(self, observation_space, action_space, device):\n super().__init__(observation_space, action...
[ [ "torch.device", "torch.cuda.is_available" ] ]
ivary43/pandas
[ "46adc5b1c2aacb312d72729af72bc0ad600917c0", "46adc5b1c2aacb312d72729af72bc0ad600917c0", "46adc5b1c2aacb312d72729af72bc0ad600917c0" ]
[ "pandas/tests/series/test_alter_axes.py", "pandas/tests/plotting/common.py", "pandas/tests/plotting/test_hist_method.py" ]
[ "from datetime import datetime\n\nimport numpy as np\nimport pytest\n\nfrom pandas import DataFrame, Index, MultiIndex, RangeIndex, Series\nimport pandas.util.testing as tm\n\n\nclass TestSeriesAlterAxes:\n\n def test_setindex(self, string_series):\n # wrong type\n msg = (r\"Index\\(\\.\\.\\.\\) mu...
[ [ "pandas.util.testing.assert_numpy_array_equal", "pandas.Series", "pandas.MultiIndex", "pandas.RangeIndex", "numpy.arange", "pandas.util.testing.assert_produces_warning", "pandas.util.testing.assert_series_equal", "pandas.DataFrame", "pandas.MultiIndex.from_arrays", "pandas....
Hemankita/refarch-kc-container-ms
[ "c2e85eacabe8a194782835b04f3410c2d7956a9b" ]
[ "tools/generateData_sensor_malfunction.py" ]
[ "import csv\nimport json\nfrom random import gauss\nimport random\nimport datetime\nimport numpy as np\nimport sys\nimport pandas as pd\n\ndf = pd.DataFrame(columns=['Timestamp', 'ID', 'Temperature(celsius)', 'Target_Temperature(celsius)', 'Amp', 'CumulativePowerConsumption', 'ContentType', 'Humidity', 'CO2', 'Time...
[ [ "pandas.DataFrame", "numpy.linspace" ] ]
xvinay28x/cat_dog_classifier_library
[ "4d56f90f9d3e91051dba71dcdea78930c4ac0e52" ]
[ "animal-classifier/__init__.py" ]
[ "from tensorflow import keras\n\ndef classify(path):\n model = keras.models.load_model(\"Cat_Dog_Classification.h5\")\n load_image = keras.preprocessing.image.load_image(path,target_size=(200,200))\n image_array = keras.preprocessing.image.img_to_array(load_image)\n reshape_array = image_array.reshape(1...
[ [ "tensorflow.keras.models.load_model", "tensorflow.keras.preprocessing.image.img_to_array", "tensorflow.keras.preprocessing.image.load_image" ] ]
ericlearning/style-transfer
[ "f387515b4ffe441c4677400a65b9e7fdb50c979f" ]
[ "FastStyleTransfer/utils.py" ]
[ "import os\nimport glob\nimport torch\nimport pandas as pd\nimport seaborn as sn\nimport torch.nn as nn\nimport torch.optim as optim\nimport matplotlib.pyplot as plt\nfrom torch.optim.lr_scheduler import _LRScheduler\nfrom sklearn.metrics import confusion_matrix\nfrom PIL import Image\n\ndef set_lr(optimizer, lrs):...
[ [ "torch.optim.Adam", "sklearn.metrics.confusion_matrix", "pandas.DataFrame", "matplotlib.pyplot.subplot", "matplotlib.pyplot.show", "matplotlib.pyplot.hist", "matplotlib.pyplot.figure" ] ]
chathurawidanage/cylon
[ "ac61b7a50880138fe67de21adee208016a94979a" ]
[ "cpp/src/experiments/generate_csv.py" ]
[ "##\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 agreed to in writing, software\n# distri...
[ [ "numpy.random.rand" ] ]
ZoRoronoa/Camera-Aware-Proxy
[ "352f900bbae330f18c2bfe2b3f2516fb4e31adea", "352f900bbae330f18c2bfe2b3f2516fb4e31adea", "352f900bbae330f18c2bfe2b3f2516fb4e31adea" ]
[ "reid/utils/evaluation_metrics/retrieval.py", "reid/utils/evaluation_metrics/ranking.py", "CAP-newCluster/reid/utils/clustering.py" ]
[ "import numpy as np\nfrom sklearn import metrics as sk_metrics\nimport torch\n\nclass PersonReIDMAP:\n '''\n Compute Rank@k and mean Average Precision (mAP) scores\n Used for Person ReID\n Test on MarKet and Duke\n '''\n\n def __init__(self, query_feature, query_cam, query_label, gallery_feature, ...
[ [ "numpy.square", "numpy.in1d", "torch.from_numpy", "numpy.argwhere", "sklearn.metrics.pairwise.euclidean_distances", "numpy.append", "sklearn.metrics.pairwise.cosine_distances", "numpy.mean", "numpy.argsort", "torch.clamp", "numpy.array", "torch.pow" ], [ "nu...
miketrumpis/lfp_scroller
[ "ce4dbf85bb4d31f2eacfb5d68a5049499637722c" ]
[ "fast_scroller/h5data.py" ]
[ "import numpy as np\nfrom scipy.linalg import LinAlgError\nfrom scipy.signal import lfilter, lfilter_zi, hilbert\nfrom scipy.interpolate import interp1d\nimport h5py\nfrom tqdm import tqdm\nfrom ecogdata.util import input_as_2d\nfrom ecogdata.util import nextpow2\n\n\ndef h5mean(array, axis, rowmask=(), start=0, st...
[ [ "numpy.abs", "numpy.linspace", "numpy.isnan", "numpy.arange", "numpy.empty_like", "scipy.signal.lfilter_zi", "numpy.cumsum", "scipy.interpolate.interp1d", "numpy.iterable", "scipy.signal.lfilter", "numpy.array", "numpy.zeros", "numpy.sum", "scipy.signal.hilb...
fakecoinbase/TheCyberHeadslashCyberHead
[ "b1c5d8c157ff5bb976778ff5f7901d82e41d7d3e" ]
[ "cyberhead/modules/brokers/coinbase/Coinbase.py" ]
[ "import cbpro\nimport pandas as pd\nfrom base64 import b64encode\n\nclass Coinbase:\n\tdef __init__(self, API_KEY, API_SECRET, API_PASS, ENV_URL=\"https://api-public.sandbox.pro.coinbase.com\"):\n\t\tself.API_KEY = API_KEY\n\t\tself.API_SECRET = API_SECRET\n\t\tself.API_PASS = API_PASS\n\t\tself.ENV_URL = ENV_URL\n...
[ [ "pandas.DataFrame" ] ]
jdlaubrie/shell-elem
[ "f87cb9ca9179533d3a645a494e7ef4d39666ddc6" ]
[ "3rd_check/surgery/penalty.py" ]
[ "# -*- coding: utf-8 -*-\r\nimport numpy as np\r\nimport pandas as pd\r\nimport matplotlib.pyplot as plt\r\n\r\nNbrOfNodes = 35\r\nkeygnra = ' TIME: GANDRA STEP: 80.000 FRAME: 1.000'\r\nkeystent = ' TIME: STENT STEP: 1.000 FRAME: 1.000'\r\nkeygnrb = ' TIME: GANDRB STEP: 100.000 FRAME: 1.000'\r...
[ [ "matplotlib.pyplot.legend", "matplotlib.pyplot.gca", "pandas.Series", "matplotlib.pyplot.rc", "matplotlib.pyplot.savefig", "matplotlib.pyplot.plot", "numpy.append", "matplotlib.pyplot.subplot", "matplotlib.pyplot.close", "matplotlib.pyplot.axis", "numpy.argsort", "m...
NRuf77/proset
[ "101d491e05c2423faddca31029232982f46d8831", "101d491e05c2423faddca31029232982f46d8831", "101d491e05c2423faddca31029232982f46d8831", "101d491e05c2423faddca31029232982f46d8831", "101d491e05c2423faddca31029232982f46d8831", "101d491e05c2423faddca31029232982f46d8831", "101d491e05c2423faddca31029232982f46d883...
[ "scripts/wine/wine_explain.py", "scripts/checker/checker_knn_fit.py", "proset/utility/other.py", "scripts/cancer/cancer_prepare_data.py", "scripts/iris_2f/iris_2f_xgb_diagnostics.py", "scripts/xor_6_6f/xor_6_6f_xgb_diagnostics.py", "scripts/checker_rot/checker_rot_xgb_fit.py", "scripts/wine/wine_knn_d...
[ "\"\"\"Explain proset classifier trained on wine classification data.\r\n\r\nCopyright by Nikolaus Ruf\r\nReleased under the MIT license - see LICENSE file for details\r\n\"\"\"\r\n\r\nfrom copy import deepcopy\r\nimport gzip\r\nimport os\r\nimport pickle\r\n\r\nimport matplotlib.pyplot as plt\r\nimport numpy as np...
[ [ "matplotlib.pyplot.gca", "numpy.abs", "numpy.sqrt", "numpy.arange", "numpy.argsort", "matplotlib.pyplot.figure" ], [ "sklearn.preprocessing.StandardScaler", "numpy.random.RandomState" ], [ "sklearn.metrics.pairwise_distances", "numpy.log", "numpy.unique", "n...
joelnmdyer/SignatuRE
[ "085a9d727e504bd25bbebdebaa58867211a52c8d", "085a9d727e504bd25bbebdebaa58867211a52c8d" ]
[ "signature/train_and_sample.py", "signature/utils/compute_metrics.py" ]
[ "import argparse\nimport logging\nimport numpy as np\nimport os\nimport sbi.utils as utils\nfrom sbi.inference.base import infer\nfrom sbi import analysis as analysis\nfrom sbi.inference import SMCABC, SNRE_A, simulate_for_sbi, prepare_for_sbi\nfrom sklearn.linear_model import LinearRegression\nimport statsmodels.a...
[ [ "numpy.dot", "numpy.log", "numpy.sqrt", "numpy.var", "numpy.cov", "numpy.mean", "sklearn.linear_model.LinearRegression", "numpy.savetxt", "numpy.array", "torch.as_tensor" ], [ "numpy.mean" ] ]
tlunet/pySDC
[ "209e0015a46f861e3658691b7f8724cb1b36c97e", "209e0015a46f861e3658691b7f8724cb1b36c97e", "209e0015a46f861e3658691b7f8724cb1b36c97e" ]
[ "pySDC/playgrounds/fft/AllenCahn_contracting_circle_FFT.py", "pySDC/projects/RDC/equidistant_RDC.py", "pySDC/playgrounds/deprecated/Dedalus/playground_datatypes.py" ]
[ "import os\n\nimport dill\nimport matplotlib.ticker as ticker\nimport numpy as np\n\nimport pySDC.helpers.plot_helper as plt_helper\nfrom pySDC.helpers.stats_helper import filter_stats, sort_stats\nfrom pySDC.implementations.collocation_classes.gauss_radau_right import CollGaussRadau_Right\nfrom pySDC.implementatio...
[ [ "numpy.ptp", "numpy.std", "numpy.argmax", "numpy.mean", "numpy.argmin", "numpy.var", "matplotlib.ticker.FormatStrFormatter", "numpy.array" ], [ "scipy.special.orthogonal.roots_legendre", "numpy.prod", "numpy.roll", "numpy.array", "numpy.zeros", "numpy.su...
Shuai-Xie/LP-DeepSSL
[ "9389c6cb0b83c7ca509ce284c4d86b600ca44a9b" ]
[ "mean_teacher/losses.py" ]
[ "# Copyright (c) 2018, Curious AI Ltd. All rights reserved.\n#\n# This work is licensed under the Creative Commons Attribution-NonCommercial\n# 4.0 International License. To view a copy of this license, visit\n# http://creativecommons.org/licenses/by-nc/4.0/ or send a letter to\n# Creative Commons, PO Box 1866, Mou...
[ [ "torch.nn.functional.kl_div", "torch.nn.functional.softmax", "torch.nn.functional.log_softmax", "torch.sum", "torch.nn.functional.mse_loss" ] ]
balrajmarimuthu/CarND-Capstone
[ "bc3e52c5e940e3da51efad219ab89fb3580fb717" ]
[ "ros/src/tl_detector/tl_detector.py" ]
[ "#!/usr/bin/env python\nimport rospy\nfrom std_msgs.msg import Int32\nfrom geometry_msgs.msg import PoseStamped, Pose\nfrom styx_msgs.msg import TrafficLightArray, TrafficLight\nfrom styx_msgs.msg import Lane\nfrom sensor_msgs.msg import Image\nfrom cv_bridge import CvBridge\nfrom light_classification.tl_classifier...
[ [ "scipy.spatial.KDTree" ] ]
uunal/adapter-transformers
[ "73a95a75f803e8fd243fc3d55ff3a9d557891377" ]
[ "src/transformers/adapters/models/distilbert.py" ]
[ "from typing import Union\n\nimport torch\nfrom torch import nn\n\nfrom ..composition import AdapterCompositionBlock, parse_composition\nfrom ..model_mixin import InvertibleAdaptersMixin, ModelAdaptersMixin\nfrom .bert import BertEncoderAdaptersMixin, BertModelHeadsMixin, BertOutputAdaptersMixin, BertSelfOutputAdap...
[ [ "torch.zeros" ] ]
gsyqax/pandas
[ "cb35d8a938c9222d903482d2f66c62fece5a7aae", "cb35d8a938c9222d903482d2f66c62fece5a7aae", "148f9fd74fc71cb7509c0898883036316efc6f89", "cb35d8a938c9222d903482d2f66c62fece5a7aae", "cb35d8a938c9222d903482d2f66c62fece5a7aae" ]
[ "pandas/tests/arrays/boolean/test_construction.py", "pandas/core/missing.py", "pandas/tests/frame/test_subclass.py", "asv_bench/benchmarks/arithmetic.py", "pandas/tests/tseries/frequencies/test_freq_code.py" ]
[ "import numpy as np\nimport pytest\n\nimport pandas as pd\nimport pandas._testing as tm\nfrom pandas.arrays import BooleanArray\nfrom pandas.core.arrays.boolean import coerce_to_array\n\n\n@pytest.fixture\ndef data():\n return pd.array(\n [True, False] * 4 + [np.nan] + [True, False] * 44 + [np.nan] + [Tru...
[ [ "pandas._testing.assert_numpy_array_equal", "pandas.core.arrays.boolean.coerce_to_array", "pandas.arrays.BooleanArray._from_sequence_of_strings", "pandas.array", "pandas.arrays.BooleanArray", "pandas._testing.assert_extension_array_equal", "pandas.date_range", "numpy.array" ], ...
VitoRazor/Lidar_RGB_detector
[ "5308ba24a90d6e8d73940be4b40d31eccb4df94b" ]
[ "second/pytorch/train.py" ]
[ "import copy\nimport json\nimport os\nfrom pathlib import Path\nimport pickle\nimport shutil\nimport time\nimport re \nimport fire\nimport numpy as np\nimport torch\nfrom google.protobuf import text_format\n\nimport second.data.kitti_common as kitti\nimport torchplus\nfrom second.builder import target_assigner_buil...
[ [ "numpy.random.get_state", "torch.cuda.synchronize", "numpy.random.seed", "torch.load", "torch.cuda.device_count", "torch.utils.data.DataLoader", "torch.tensor", "torch.no_grad", "numpy.mean", "torch.cuda.is_available", "torch.device", "torch.nn.DataParallel", "n...
KyunghoWon-GIST/PyRiemann-with-OpenViBE
[ "2a070fdadb040ce6edad81aef497d054ddd70130" ]
[ "python-Riemann-online.py" ]
[ "import pickle\r\nimport numpy as np\r\nimport pyriemann\r\nimport sklearn\r\nimport scipy\r\nimport matplotlib as mpl\r\nmpl.use('Qt5Agg') # for using pyplot (pip install pyqt5)\r\nimport matplotlib.pyplot as plt\r\nfrom scipy import signal\r\nfrom scipy.signal import butter, filtfilt, sosfiltfilt\r\n\r\n# Pyriema...
[ [ "matplotlib.pyplot.gca", "numpy.expand_dims", "matplotlib.use", "matplotlib.pyplot.ylim", "matplotlib.pyplot.plot", "matplotlib.pyplot.ioff", "scipy.signal.butter", "matplotlib.pyplot.clf", "numpy.mean", "matplotlib.pyplot.xlim", "scipy.signal.sosfiltfilt", "matplot...
yage99/tensorflow
[ "c7fa71b32a3635eb25596ae80d007b41007769c4", "be084bd7a4dd241eb781fc704f57bcacc5c9b6dd", "be084bd7a4dd241eb781fc704f57bcacc5c9b6dd", "be084bd7a4dd241eb781fc704f57bcacc5c9b6dd", "be084bd7a4dd241eb781fc704f57bcacc5c9b6dd", "be084bd7a4dd241eb781fc704f57bcacc5c9b6dd", "be084bd7a4dd241eb781fc704f57bcacc5c9b6d...
[ "tensorflow/python/data/experimental/service/server_lib_test.py", "tensorflow/compiler/mlir/tensorflow/tests/tf_saved_model/exported_python_args.py", "tensorflow/python/kernel_tests/signal/spectral_ops_test.py", "tensorflow/python/kernel_tests/confusion_matrix_test.py", "tensorflow/python/keras/layers/einsu...
[ "# Copyright 2020 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.data.experimental.service.server_lib.DispatchServer", "tensorflow.python.data.experimental.service.server_lib.WorkerServer", "tensorflow.python.platform.test.main" ], [ "tensorflow.compiler.mlir.tensorflow.tests.tf_saved_model.common.do_test", "tensorflow.compat.v2.Tenso...
evanloshin/CarND-Behavioral-Cloning-P3
[ "22ec89cdea5257a10512f07b07fc4c074bc7c649" ]
[ "drive.py" ]
[ "import argparse\nimport base64\nfrom datetime import datetime\nimport os\nimport shutil\n\nimport numpy as np\nimport socketio\nimport eventlet\nimport eventlet.wsgi\nfrom PIL import Image\nfrom flask import Flask\nfrom io import BytesIO\n\nfrom keras.models import load_model\nimport h5py\nfrom keras import __vers...
[ [ "numpy.asarray" ] ]
frederikschubert/rltime
[ "d1722ffd4cf7b4599655b8d9c64abc243919afc9" ]
[ "rltime/eval.py" ]
[ "\"\"\" Entry point for evaluating/rendering a trained policy. \"\"\"\n\nimport argparse\nimport json\nimport os\nimport numpy as np\nimport time\nimport datetime\n\nfrom rltime.general.config import load_config\nfrom rltime.general.utils import deep_dictionary_update\nfrom rltime.general.type_registry import get_r...
[ [ "numpy.min", "numpy.median", "numpy.max", "numpy.std", "numpy.mean", "numpy.random.rand", "numpy.array" ] ]
apexrl/EBIL-torch
[ "8d257d5efa36f7c608085e34a7cdd3e996962d3f" ]
[ "rlkit/core/base_algorithm.py" ]
[ "import abc\nimport pickle\nimport time\nfrom collections import OrderedDict\nfrom copy import deepcopy\n\nimport gtimer as gt\nimport numpy as np\n\nfrom rlkit.core import logger, eval_util\nfrom rlkit.data_management.env_replay_buffer import EnvReplayBuffer\nfrom rlkit.data_management.path_builder import PathBuil...
[ [ "numpy.array", "numpy.random.randint" ] ]
VolkerH/gputools
[ "b8732c3cf82b96c6960497e6d82ce6b2bac463aa" ]
[ "gputools/convolve/minmax_filter.py" ]
[ "from __future__ import print_function, unicode_literals, absolute_import, division\nimport logging\n\nlogger = logging.getLogger(__name__)\n\nimport os\nimport numpy as np\nfrom gputools import OCLArray, OCLProgram, get_device\n\nfrom gputools.core.ocltypes import assert_bufs_type\nfrom gputools.utils.tile_iterato...
[ [ "numpy.ascontiguousarray", "numpy.int32", "numpy.ceil", "numpy.isscalar", "numpy.empty" ] ]
domingoesteban/robolearn
[ "0d20125425c352b80ef2eeed1c0b11ab6497b11a", "0d20125425c352b80ef2eeed1c0b11ab6497b11a" ]
[ "robolearn/torch/policies/tanh_gaussian_promp_multi_policy.py", "robolearn/torch/policies/tanh_gaussian_composed_multi_policy.py" ]
[ "import math\nimport torch\nfrom torch import nn as nn\nfrom torch.distributions import Normal\nfrom robolearn.torch.core import PyTorchModule\nfrom robolearn.torch.utils.pytorch_util import np_ify\nfrom torch.nn.modules.normalization import LayerNorm\nimport robolearn.torch.utils.pytorch_util as ptu\nfrom robolear...
[ [ "torch.nn.BatchNorm1d", "torch.sqrt", "torch.sum", "torch.nn.Sigmoid", "torch.tanh", "torch.nn.Linear", "torch.exp", "torch.log", "torch.nn.modules.normalization.LayerNorm", "torch.index_select", "torch.batch_norm" ], [ "torch.nn.BatchNorm1d", "torch.isnan",...
kcexn/singular-value-decomposition
[ "63e2a23f9f0db9aa361e338b8065d59b80f7649e" ]
[ "coded_distributed_computing.py" ]
[ "''' coded_distributed_computing\nThis module contains functions related to a study of the coded distributed computing model.\n\n'''\nimport numpy as np\n\ndef encode_matrix(A: np.matrix, G: np.matrix) -> np.matrix:\n ''' encode_matrix\n Parameters:\n ---\n A: np.matrix, input matrix to code.\n G: np...
[ [ "numpy.matmul" ] ]
sanzgiri/MaatPy
[ "381a0d31f1afdd2c53b9ccbb410eb0df6b4b9965" ]
[ "maatpy/dataset.py" ]
[ "import warnings\nimport numpy as np\nimport pandas as pd\n\nfrom collections import Counter\n\nfrom sklearn.datasets import make_classification\nfrom sklearn.utils import check_X_y\nfrom sklearn.utils import Bunch\nfrom sklearn.preprocessing import LabelEncoder\nfrom imblearn.under_sampling.prototype_selection imp...
[ [ "pandas.read_csv", "sklearn.datasets.make_classification", "sklearn.utils.check_X_y", "numpy.unique", "sklearn.preprocessing.LabelEncoder" ] ]
beesk135/ReID-Survey
[ "d1467c0ce5d3ca78640196360a05df9ff9f9f42a" ]
[ "evaluate/__init__.py" ]
[ "import torch \n\nfrom .eval_reid import eval_func\n\ndef euclidean_dist(x, y):\n m, n = x.size(0), y.size(0)\n xx = torch.pow(x, 2).sum(1, keepdim=True).expand(m, n)\n yy = torch.pow(y, 2).sum(1, keepdim=True).expand(n, m).t()\n dist = xx + yy\n dist.addmm_(1, -2, x, y.t())\n dist = dist.clamp(mi...
[ [ "torch.pow" ] ]
xujin1184104394/coco-analyze
[ "fefe16025554dbf831e71d32d6601dd8f00286a8" ]
[ "analysisAPI/scoringErrors.py" ]
[ "## imports\nimport os, time\nimport numpy as np\nimport matplotlib.pyplot as plt\n\n# package imports \nfrom . import utilities\n\ndef scoringErrors( coco_analyze, oks, imgs_info, saveDir ):\n loc_dir = saveDir + '/scoring_errors'\n if not os.path.exists(loc_dir):\n os.makedirs(loc_dir)\n f = open(...
[ [ "matplotlib.pyplot.legend", "numpy.sqrt", "matplotlib.pyplot.title", "numpy.linspace", "matplotlib.pyplot.subplots", "matplotlib.pyplot.savefig", "matplotlib.pyplot.xlim", "numpy.argmax", "matplotlib.pyplot.grid", "matplotlib.pyplot.close", "numpy.argsort", "matplot...
sirjamesmeddel-gitty/intuition
[ "cd517e6b3b315a743eb4d0d0dc294e264ab913ce", "cd517e6b3b315a743eb4d0d0dc294e264ab913ce", "cd517e6b3b315a743eb4d0d0dc294e264ab913ce", "cd517e6b3b315a743eb4d0d0dc294e264ab913ce" ]
[ "tests/core/test_configuration.py", "intuition/api/datafeed.py", "intuition/core/analyzes.py", "tests/api/test_datafeed.py" ]
[ "'''\nTests for intuition.core.configuration\n'''\n\nimport unittest\nfrom nose.tools import raises\nimport dna.test_utils as test_utils\nimport pandas as pd\nimport intuition.core.configuration as configuration\nfrom dna.errors import DynamicImportFailed\nfrom intuition.errors import InvalidConfiguration\n\n\nclas...
[ [ "pandas.date_range" ], [ "pandas.DataFrame" ], [ "pandas.Series", "pandas.datetime.date", "pandas.DatetimeIndex", "pandas.DataFrame", "numpy.mean", "pandas.datetime.strptime", "pandas.datetools.BDay", "pandas.datetools.MonthBegin", "numpy.array" ], [ "pa...
rkripa/PS-FCN
[ "eb8ddbd60964830c06432a734a2cf6dce34f70f0" ]
[ "models/PS_FCN_run.py" ]
[ "import torch\nimport torch.nn as nn\nfrom torch.nn.init import kaiming_normal_\nfrom models import model_utils\n\nclass FeatExtractor(nn.Module):\n def __init__(self, batchNorm=False, c_in=3, other={}):\n super(FeatExtractor, self).__init__()\n self.other = other\n self.conv1 = model_utils....
[ [ "torch.nn.functional.normalize", "torch.Tensor", "torch.cat", "torch.nn.Conv2d", "torch.split", "torch.stack", "torch.nn.init.kaiming_normal_" ] ]
ComputationalMechanics/SurfaceTopography
[ "6751be427c89d526ef4857300409596c79119029", "6751be427c89d526ef4857300409596c79119029", "7dc7346cb9545326a3323fda0d402f254eae8c0e", "6751be427c89d526ef4857300409596c79119029", "7dc7346cb9545326a3323fda0d402f254eae8c0e" ]
[ "SurfaceTopography/Uniform/Filtering.py", "test/test_reliability_cutoff.py", "examples/bicubic_interpolation.py", "test/IO/test_io.py", "SurfaceTopography/Nonuniform/common.py" ]
[ "#\n# Copyright 2020-2021 Lars Pastewka\n# 2020-2021 Antoine Sanner\n#\n# ### MIT license\n#\n# Permission is hereby granted, free of charge, to any person obtaining a copy\n# of this software and associated documentation files (the \"Software\"), to deal\n# in the Software without restriction, including ...
[ [ "numpy.abs", "numpy.fft.rfft", "scipy.signal.get_window", "numpy.fft.rfftfreq", "numpy.arange", "numpy.sqrt", "numpy.real", "numpy.where" ], [ "numpy.isfinite", "numpy.testing.assert_almost_equal", "numpy.mean", "numpy.testing.assert_allclose", "numpy.array"...
georgetown-analytics/DC-Bikeshare
[ "42676654d103cdaddfb76db76d1eece533251261", "42676654d103cdaddfb76db76d1eece533251261" ]
[ "final_plots/read_aws.py", "report_queries/dockless_trips_by_operator.py" ]
[ "import psycopg2\nimport psycopg2.extras\nimport pandas as pd\nimport os\nimport time\nfrom pathlib import Path\nfrom dotenv import load_dotenv\n\n\ndef read_only_connect_aws():\n env_path = 'env_readonly.env'\n load_dotenv(dotenv_path=env_path)\n host = \"bikeshare-restored.cs9te7lm3pt2.us-east-1.rds.amaz...
[ [ "pandas.read_sql" ], [ "pandas.read_sql" ] ]
daroari/pygmt
[ "e022851d62814a9255ed2bb63ae092b666b832b9" ]
[ "pygmt/tests/test_datasets_earth_relief.py" ]
[ "\"\"\"\nTest basic functionality for loading Earth relief datasets.\n\"\"\"\nimport numpy as np\nimport numpy.testing as npt\nimport pytest\nfrom pygmt.datasets import load_earth_relief\nfrom pygmt.exceptions import GMTInvalidInput\n\n\ndef test_earth_relief_fails():\n \"\"\"\n Make sure earth relief fails f...
[ [ "numpy.arange" ] ]
minhmanho/rrdncnn
[ "f09ef7d92e31bfd43a548bb476970cfe38d32508" ]
[ "pytorch_ssim.py" ]
[ "import torch\r\nimport torch.nn.functional as F\r\nfrom torch.autograd import Variable\r\nimport numpy as np\r\nfrom math import exp\r\n\r\ndef gaussian(window_size, sigma):\r\n gauss = torch.Tensor([exp(-(x - window_size//2)**2/float(2*sigma**2)) for x in range(window_size)])\r\n return gauss/gauss.sum()\r\...
[ [ "torch.nn.functional.conv2d" ] ]
kay-wong/DiscoBERT
[ "814c741e2a049de3afc489835e0df3ccf9fb4fe9" ]
[ "model/archival_gnns.py" ]
[ "# Graph Conv and Relational Graph Conv\nimport itertools\nimport torch\nfrom typing import List, Union\n\nimport dgl\nimport torch.nn as nn\nimport torch.nn.functional as F\nfrom allennlp.common import FromParams\nfrom allennlp.common import Registrable\nfrom allennlp.modules.encoder_base import _EncoderBase\nfrom...
[ [ "torch.nn.Dropout", "torch.nn.ModuleList", "torch.sum", "torch.nn.Linear", "torch.bmm", "torch.stack" ] ]
paigeco/VirtualGoniometer
[ "536e7e77fbb036ad8d777b42e751a0f3e80b8242" ]
[ "src/AngleMeasurement/RP1DClustering.py" ]
[ "import numpy as np\nfrom .PCASmallestEig import pca_smallest_eig, pca_smallest_eig_powermethod\nfrom .Withness import withness\nfrom .CalculateAngle import get_angle\n\n#RP1D clustering from\n#Han, Sangchun, and Mireille Boutin. \"The hidden structure of image datasets.\" 2015 IEEE International Conference on Imag...
[ [ "numpy.dot", "numpy.reshape", "numpy.linalg.norm", "numpy.max", "numpy.mean", "numpy.argmin", "numpy.random.rand", "numpy.cross", "numpy.zeros", "numpy.sum" ] ]
nipreps/mriqc
[ "e021008da0a2ef1c48e882baf932139a673349f9" ]
[ "mriqc/interfaces/anatomical.py" ]
[ "# emacs: -*- mode: python; py-indent-offset: 4; indent-tabs-mode: nil -*-\n# vi: set ft=python sts=4 ts=4 sw=4 et:\n#\n# Copyright 2021 The NiPreps Developers <nipreps@gmail.com>\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the Licen...
[ [ "scipy.ndimage.binary_erosion", "numpy.issubdtype", "numpy.all", "numpy.max", "numpy.zeros_like", "numpy.mean", "scipy.ndimage.binary_opening", "numpy.ones_like", "numpy.pad", "scipy.ndimage.generate_binary_structure", "numpy.asanyarray", "numpy.min", "numpy.med...
GrumpyMeow/ownphotos-backend
[ "98d8e9136e9188009afe08657f943dba3df80ccb" ]
[ "api/util.py" ]
[ "import base64\nimport pickle\nimport itertools\n\nfrom scipy import linalg\nfrom sklearn.decomposition import PCA\nimport numpy as np\nfrom sklearn import cluster\nfrom sklearn import mixture\nfrom scipy.spatial import distance\nfrom sklearn.preprocessing import StandardScaler\n\n\nimport requests\n\nfrom config i...
[ [ "numpy.log", "numpy.where", "numpy.bincount" ] ]
matham/Ceed
[ "b81a14a6b8211e5f4582418ddea34c951ab2667e" ]
[ "ceed/tests/test_app/test_stage.py" ]
[ "import os\nimport sys\nimport math\nfrom contextlib import contextmanager\nfrom math import isclose\nimport numpy as np\nimport pytest\n\nimport ceed\nfrom .examples.stages import create_test_stages, make_stage, StageWrapper, \\\n stage_classes, assert_stages_same\nfrom typing import Type, List, Union\nfrom cee...
[ [ "numpy.asarray", "numpy.arange", "numpy.all", "numpy.array", "numpy.sum", "numpy.isin" ] ]
igorlucci/koalas
[ "8803344d620261981003175bd1edc3c4120b84e2" ]
[ "databricks/koalas/base.py" ]
[ "#\n# Copyright (C) 2019 Databricks, Inc.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable la...
[ [ "numpy.timedelta64", "pandas.api.types.is_list_like" ] ]
abhi526691/Covid-Guard
[ "9c050ef44201c01f512169ffb146ad0da5278ec1", "9c050ef44201c01f512169ffb146ad0da5278ec1" ]
[ "main.py", "video_recorder.py" ]
[ "# import the necessary packages\r\nfrom tensorflow.keras.preprocessing.image import img_to_array\r\nfrom tensorflow.keras.applications.mobilenet_v2 import preprocess_input\r\nfrom tensorflow.keras.models import load_model\r\nfrom imutils.video import VideoStream,FileVideoStream\r\nimport imutils\r\nimport numpy as...
[ [ "tensorflow.keras.models.load_model", "numpy.random.seed", "tensorflow.keras.applications.mobilenet_v2.preprocess_input", "numpy.ones", "numpy.argmax", "numpy.array", "tensorflow.keras.preprocessing.image.img_to_array" ], [ "numpy.array" ] ]
fmamitrotta/pyNastran
[ "90f957887a4f68f8e58b07c15e1ac69c66b9c6f4" ]
[ "pyNastran/op2/tables/geom/ept.py" ]
[ "\"\"\"\ndefines readers for BDF objects in the OP2 EPT/EPTS table\n\"\"\"\n#pylint: disable=C0103,R0914\nfrom __future__ import annotations\nfrom struct import unpack, Struct\nfrom functools import partial\nfrom typing import Tuple, List, TYPE_CHECKING\n\nimport numpy as np\n\n#from pyNastran import is_release\nfr...
[ [ "numpy.frombuffer", "numpy.where" ] ]
FelipeH92/Task-Space-Control-Vision
[ "77d9f709d7cb0afb50ef9baf6ba39304aca445e5", "77d9f709d7cb0afb50ef9baf6ba39304aca445e5" ]
[ "Experiments/src/Task Control - Python/UR5Class.py", "Experiments/src/Task Control - Python/trajectoryCheck.py" ]
[ "#!/usr/bin/python\r\n# -*- coding: utf-8 -*-\r\n## @package UR5\r\n# Documentação para o pacote de classes UR5.\r\n#\r\n# Documentação do código produzido para controle do manipulador UR5 e geração e controle de suas posições.\r\n# Cada código aqui documentado possui uma breve descrição de sua função, suas entr...
[ [ "numpy.dot", "numpy.radians", "numpy.sqrt", "numpy.asarray", "numpy.nan_to_num", "numpy.arctan2", "numpy.all", "numpy.concatenate", "numpy.mean", "numpy.any", "numpy.hstack", "numpy.eye", "numpy.sin", "scipy.signal.butter", "numpy.real", "scipy.signa...
piojanu/tf_utils
[ "169bd3334dd11954cf8f411f2c918f76cd609fab" ]
[ "samples/mnist_vae.py" ]
[ "import argparse\nimport io\nimport os.path\n\nimport matplotlib.pyplot as plt\nimport numpy as np\nimport tensorflow as tf\nimport tensorflow_probability as tfp\nfrom tqdm import tqdm\n\nfrom tf_utils import AttrDict, attrdict_from_yaml, lazy_property_with_scope, share_variables\n\ntfd = tfp.distributions\ntfl = t...
[ [ "tensorflow.convert_to_tensor", "tensorflow.norm", "numpy.product", "tensorflow.reduce_mean", "tensorflow.zeros", "tensorflow.summary.image", "tensorflow.train.MonitoredSession", "tensorflow.reshape", "matplotlib.pyplot.subplots", "tensorflow.keras.datasets.mnist.load_data"...
pkyIntelligence/FasterRCNN
[ "230953938efdba8f8c127fcc0bb746fcce8d9463", "230953938efdba8f8c127fcc0bb746fcce8d9463" ]
[ "FasterRCNN/layers/roi_align.py", "FasterRCNN/data/samplers/grouped_batch_sampler.py" ]
[ "import torch\nimport math\n\nfrom torch import nn\nfrom ..utils.utils import point_interpolate\n\n\nclass ROIAlign(nn.Module):\n def __init__(self, output_size, spatial_scale, sampling_ratio):\n \"\"\"\n Args:\n output_size (tuple): h, w\n spatial_scale (float): scale the inp...
[ [ "torch.Tensor", "torch.split" ], [ "numpy.asarray", "numpy.unique" ] ]
dhingratul/RNN
[ "9e1ac582dbf8251769817b34fc9d791fa8c20376" ]
[ "Memory_RNN.py" ]
[ "#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\n\"\"\"\nCreated on Wed May 24 11:28:50 2017\n\n@author: dhingratul\n\"\"\"\nfrom __future__ import print_function, division\nimport numpy as np\nimport tensorflow as tf\nimport helpers\n# hyperparams\nnum_epochs = 10000\ntotal_series_length = 100\ntruncated_backprop...
[ [ "tensorflow.matmul", "tensorflow.nn.softmax", "tensorflow.concat", "tensorflow.train.AdagradOptimizer", "tensorflow.unstack", "tensorflow.reduce_mean", "tensorflow.reshape", "tensorflow.placeholder", "tensorflow.global_variables_initializer", "tensorflow.nn.sparse_softmax_c...
ashok-arjun/few-shot-ssl-public
[ "3cf522031aa40b4ffb61e4693d0b48fdd5669276" ]
[ "fewshot/data/compress_tiered_imagenet.py" ]
[ "# Copyright (c) 2018 Mengye Ren, Eleni Triantafillou, Sachin Ravi, Jake Snell,\n# Kevin Swersky, Joshua B. Tenenbaum, Hugo Larochelle, Richars S. Zemel.\n#\n# Permission is hereby granted, free of charge, to any person obtaining a copy\n# of this software and associated documentation files (the \"Software\"), to d...
[ [ "numpy.load", "numpy.savez" ] ]
selimfirat/pysad
[ "dff2ff38258eb8a85c9d34cf5f0b876fc1dc9ede", "dff2ff38258eb8a85c9d34cf5f0b876fc1dc9ede" ]
[ "tests/transform/preprocessing/test_instance_unit_norm_scaler.py", "pysad/models/loda.py" ]
[ "\n\ndef test_instance_unit_norm_scaler():\n import numpy as np\n from pysad.transform.preprocessing import InstanceUnitNormScaler\n\n X = np.random.rand(100, 25)\n scaler = InstanceUnitNormScaler()\n\n scaled_X = scaler.fit_transform(X)\n assert np.all(np.isclose(np.linalg.norm(scaled_X, axis=1),...
[ [ "numpy.linalg.norm", "numpy.random.rand" ], [ "numpy.log", "numpy.sqrt", "numpy.ones", "numpy.int", "numpy.random.permutation", "numpy.random.randn", "numpy.searchsorted", "numpy.histogram", "numpy.sum", "numpy.zeros" ] ]
corganhejijun/frontal-trans
[ "1509babf2447a53a772703b09cb6a2daec6968a7" ]
[ "test_sample.py" ]
[ "# -*- coding: utf-8 -*- \nimport os\nimport cv2\nfrom scipy import misc\nfrom PIL import Image\n\nsample_path = 'datasets/celeb_train/lfw_trans'\ndest_path = sample_path + \"/../dest\"\nmiddleSize = 64\nimgSize = 256\nkernel_size = (5, 5)\nsigma = 5\n\nif not os.path.exists(dest_path):\n os.mkdir(dest_path)\n\n...
[ [ "scipy.misc.imresize" ] ]
YusrilHasanuddin/bangkit-capstone-CAP0166
[ "51742f7af47fa285154793a6ea74de1d78d945b3" ]
[ "ml-project/extract_face_yusril.py" ]
[ "import sys\nimport os\nimport traceback\nfrom PIL import Image\nfrom facenet_pytorch import MTCNN\nimport matplotlib.image as mpimg\nimport numpy as np\n\n\ndef detect_faces(image_path):\n mtcnn = MTCNN(margin=20, keep_all=True,\n post_process=False, device='cuda:0')\n image = image_path\n ...
[ [ "matplotlib.image.imread" ] ]
sailab-code/SAILenv
[ "e202be04de468a58e58ae858693245f5556c3597" ]
[ "example_unity_socket.py" ]
[ "#\n# Copyright (C) 2020 Enrico Meloni, Luca Pasqualini, Matteo Tiezzi\n# University of Siena - Artificial Intelligence Laboratory - SAILab\n#\n#\n# SAILenv is licensed under a MIT license.\n#\n# You should have received a copy of the license along with this\n# work. If not, see <https://en.wikipedia.org/wiki/MIT_L...
[ [ "numpy.reshape", "numpy.max", "numpy.zeros" ] ]
georgeAccnt-GH/Azure2019
[ "5c9774b644d3ea15590d72d3de9363df72abf7ab" ]
[ "src/AzureFunctions/ComputeGradient/AzureUtilities.py" ]
[ "import numpy as np\nimport segyio\nimport subprocess\nimport os, h5py\nfrom scipy import interpolate\nfrom devito import Eq, Operator\nfrom azure.storage.blob import BlockBlobService, PublicAccess\n\nblob_service = BlockBlobService(account_name='', account_key='')\n\n###############################################...
[ [ "scipy.interpolate.splrep", "numpy.abs", "numpy.linspace", "numpy.min", "numpy.arange", "scipy.interpolate.splev", "numpy.concatenate", "numpy.max", "numpy.ones", "numpy.fromstring", "numpy.zeros" ] ]
TwinIsland/img2java
[ "6b6788daa0a97acb1e455ead9d7bd09d7d881ab2" ]
[ "treat.py" ]
[ "from matplotlib import pyplot as plt\nimport numpy as np\nimport cv2\nfrom scipy import stats\nimport translate\nfrom skimage import transform\n\n#####################################\nimgData = cv2.imread('van.jpg',0)\ncompressRate = 0.4\n#####################################\n\nimgData = np.array(imgData)\nshape...
[ [ "matplotlib.pyplot.imshow", "numpy.array", "scipy.stats.zscore", "matplotlib.pyplot.show" ] ]
MinhTuDo/MD-MOENAS
[ "edd6ec8c3f89cfbe9674873425c5056e72899edb" ]
[ "procedure/problem/efficiency_performance/mo_nats.py" ]
[ "from procedure.problem.base import nats as base\n\nimport numpy as np\n\nclass EfficiencyAccuracyNATS(base.NATS):\n def __init__(self, efficiency, **kwargs):\n super().__init__(n_obj=2, **kwargs)\n self.msg += efficiency + '={:.3f}, ' + 'valid-error' + '={:.3f}'\n self.efficiency = efficien...
[ [ "numpy.row_stack", "numpy.mean", "numpy.column_stack" ] ]
Gaskell-1206/MSI_vs_MSS_Classification
[ "be6fd8a6961624367b2bb0e1299219e940f6f418" ]
[ "Step2_Training_MIL/train_MIL_classification_trained_cnn_models.py" ]
[ "# Run MIL classification use pretrained CNN models\n# Reference: 1.Campanella, G. et al. Clinical-grade computational pathology using weakly supervised\n# deep learning on whole slide images. Nat Med 25, 1301–1309 (2019).\n# doi:10.1038/s41591-019-0508-1. Available from http://www.nature.com/...
[ [ "sklearn.metrics.roc_auc_score", "torch.nn.CrossEntropyLoss", "pandas.read_csv", "torch.Tensor", "numpy.logical_and", "torch.utils.data.DataLoader", "numpy.lexsort", "torch.no_grad", "numpy.equal", "torch.utils.tensorboard.SummaryWriter", "numpy.not_equal", "sklearn...
siddhantwahal/scipy
[ "411fbbda0f942fcce3e4b314efb11c4553baaa7c" ]
[ "scipy/stats/_distn_infrastructure.py" ]
[ "#\n# Author: Travis Oliphant 2002-2011 with contributions from\n# SciPy Developers 2004-2011\n#\nfrom scipy._lib._util import getfullargspec_no_self as _getfullargspec\n\nimport sys\nimport keyword\nimport re\nimport types\nimport warnings\nimport inspect\nfrom itertools import zip_longest\n\nfrom scipy...
[ [ "scipy.special.rel_entr", "numpy.sqrt", "scipy.special.ive", "numpy.asarray", "numpy.cumsum", "numpy.all", "numpy.max", "scipy._lib.doccer.docformat", "numpy.any", "numpy.place", "scipy.misc.derivative", "scipy.special.entr", "scipy.special.chndtr", "numpy.a...
saikrishna-pallerla/efficientdet-pytorch
[ "dc7b790f537d28476a26af6f793acc4757becd0d" ]
[ "effdet/data/transforms.py" ]
[ "\"\"\" COCO transforms (quick and dirty)\n\nHacked together by Ross Wightman\n\"\"\"\nimport torch\nfrom PIL import Image\nimport numpy as np\nimport random\nimport math\n\nIMAGENET_DEFAULT_MEAN = (0.485, 0.456, 0.406)\nIMAGENET_DEFAULT_STD = (0.229, 0.224, 0.225)\nIMAGENET_INCEPTION_MEAN = (0.5, 0.5, 0.5)\nIMAGEN...
[ [ "numpy.expand_dims", "numpy.clip", "torch.from_numpy", "numpy.stack", "numpy.moveaxis", "numpy.array" ] ]
jtwhite79/MetPy
[ "8f1880be1ee98c17cd00ae556324386d2a6301ac" ]
[ "metpy/calc/tests/test_basic.py" ]
[ "# Copyright (c) 2008-2015 MetPy Developers.\n# Distributed under the terms of the BSD 3-Clause License.\n# SPDX-License-Identifier: BSD-3-Clause\n\nimport numpy as np\nfrom numpy.testing import assert_array_equal\n\nfrom metpy.units import units\nfrom metpy.testing import assert_almost_equal, assert_array_almost_e...
[ [ "numpy.testing.assert_array_equal", "numpy.array", "numpy.sqrt", "numpy.ma.array" ] ]
LBJ-Wade/GALLUMI_public
[ "4529ab32ccfc281e5976f482fe556b672b8f464f" ]
[ "Scripts/Plotting/Posteriors_cosmo_model1/Posteriors_cosmo_model1_alternative_dust.py" ]
[ "import numpy as np\nfrom matplotlib import pyplot as plt\nimport glob\nfrom matplotlib import patches as mpatches\nimport scipy.ndimage\nfrom scipy.interpolate import PchipInterpolator\nplt.style.use(\"../template.mplstyle\")\n\n# purple - green - darkgoldenrod - blue - red\ncolors = ['purple', '#306B37', 'darkgol...
[ [ "matplotlib.patches.Patch", "numpy.log", "matplotlib.colors.to_rgb", "numpy.linspace", "numpy.cumsum", "matplotlib.pyplot.savefig", "numpy.transpose", "matplotlib.pyplot.subplot", "scipy.interpolate.PchipInterpolator", "numpy.histogram2d", "numpy.searchsorted", "num...
Yugeeth/chat-bot
[ "3198fb160f743c7be1f377d2febb889423da8c06" ]
[ "train.py" ]
[ "import numpy as np\r\nimport random\r\nimport json\r\n\r\nimport torch\r\nimport torch.nn as nn\r\nfrom torch.utils.data import Dataset, DataLoader\r\n\r\nfrom nltk_utils import bag_of_words, tokenize, stem\r\nfrom model import NeuralNet\r\n\r\nwith open('intents.json', 'r') as f:\r\n intents = json.load(f)\r\n...
[ [ "torch.nn.CrossEntropyLoss", "torch.utils.data.DataLoader", "torch.cuda.is_available", "numpy.array", "torch.save" ] ]
TurkuNLP/paraphrase-classification
[ "625f0cf5223ecff9d25c2a4f558ca39fa5ecc794" ]
[ "para_averaging.py" ]
[ "import torch.nn.functional as F\nimport torch\nimport para_model\n\nclass ParaAvgModel(para_model.PARAModel):\n\n def __init__(self, **args):\n super().__init__(**args)\n # self.drop_layer=torch.nn.Dropout(p=0.2)\n self.cls_layer=torch.nn.Linear(self.bert.config.hidden_size*5, args['num_cla...
[ [ "torch.nn.Linear", "torch.cat" ] ]
joewalter/mne-python
[ "b0629bea7f5e8e94d9e2e889f45a35f9657e6dbc", "b0629bea7f5e8e94d9e2e889f45a35f9657e6dbc", "b0629bea7f5e8e94d9e2e889f45a35f9657e6dbc", "b0629bea7f5e8e94d9e2e889f45a35f9657e6dbc", "b0629bea7f5e8e94d9e2e889f45a35f9657e6dbc" ]
[ "mne/viz/circle.py", "mne/io/meas_info.py", "mne/gui/tests/test_file_traits.py", "mne/beamformer/tests/test_lcmv.py", "mne/io/tests/test_reference.py" ]
[ "\"\"\"Functions to plot on circle as for connectivity\n\"\"\"\nfrom __future__ import print_function\n\n# Authors: Alexandre Gramfort <alexandre.gramfort@telecom-paristech.fr>\n# Denis Engemann <denis.engemann@gmail.com>\n# Martin Luessi <mluessi@nmr.mgh.harvard.edu>\n#\n# License: Simplified BSD...
[ [ "numpy.linspace", "numpy.cumsum", "matplotlib.pyplot.get_cmap", "numpy.max", "numpy.zeros_like", "numpy.any", "numpy.where", "matplotlib.patches.PathPatch", "numpy.unique", "numpy.tril_indices", "numpy.size", "matplotlib.pyplot.subplot", "numpy.diff", "numpy...
jsaez8/qtt
[ "fa6497ace86a255f33a2192ba01d063d07d6895e" ]
[ "src/qtt/instrument_drivers/virtual_awg.py" ]
[ "# -*- coding: utf-8 -*-\n\"\"\"\nCreated on Wed Aug 31 13:04:09 2016\n\n@author: diepencjv\n\"\"\"\n\n# %%\nimport numpy as np\nimport scipy.signal\nimport logging\nimport warnings\n\nimport qcodes\nfrom qcodes import Instrument\nfrom qcodes.plots.pyqtgraph import QtPlot\nfrom qcodes.data.data_array import DataArr...
[ [ "numpy.arange", "numpy.tile", "numpy.ones", "numpy.ceil", "numpy.floor", "numpy.array", "numpy.zeros", "numpy.roll" ] ]
MarkusHaak/fieldbioinformatics
[ "3d291477a3d84968816c8e57e6078fc80135f422" ]
[ "artic/deprecated/plot_amplicon_depth.py" ]
[ "#!/usr/bin/env python3\n\n\"\"\"\nPlot the mean read depth per amplicon.\n\nThis has been written for use in the ARTIC pipeline so there are no file checks - it assumes the following:\n * the primer scheme is in ARTIC format\n * the input depth files are in the format: `chrom\\treadgroup\\tposition\\tdepth\n * rea...
[ [ "matplotlib.pyplot.legend", "pandas.concat", "pandas.read_csv", "matplotlib.use", "matplotlib.pyplot.savefig", "pandas.cut", "matplotlib.pyplot.close", "matplotlib.pyplot.xticks" ] ]
cperales/pygsom
[ "ac4d4818f441d862cb5183e1d2ea814e3f805759" ]
[ "gsom.py" ]
[ "# -*- coding: utf-8 -*-\n\"\"\"\nThe MIT License (MIT)\n\nCopyright (c) 2015 Philipp Ludwig <git@philippludwig.net>\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, ...
[ [ "scipy.array" ] ]
eEcoLiDAR/lcMacroPipeline
[ "91709f93ef53a3e453f0ce967e1094688688f684" ]
[ "tests/test_grid.py" ]
[ "from pathlib import Path\nimport unittest\nimport numpy as np\nimport pylas\n\nfrom laserfarm.grid import Grid\n\ntry:\n import matplotlib\n matplotlib_available = True\nexcept ModuleNotFoundError:\n matplotlib_available = False\n\nif matplotlib_available:\n matplotlib.use('Agg')\n import matplotlib...
[ [ "matplotlib.pyplot.scatter", "matplotlib.use", "numpy.rint", "matplotlib.pyplot.show", "matplotlib.pyplot.savefig", "matplotlib.pyplot.plot", "numpy.all", "numpy.column_stack", "numpy.array", "numpy.testing.assert_allclose", "matplotlib.pyplot.figure" ] ]
madhawav/plan2scene
[ "cc3481f503fc096d1a50ea4fbcc668b2a3b75fb5", "cc3481f503fc096d1a50ea4fbcc668b2a3b75fb5" ]
[ "code/src/plan2scene/texture_gen/custom_ops/noise.py", "code/src/plan2scene/texture_prop/graph_util.py" ]
[ "# Code adapted from https://github.com/henzler/neuraltexture/blob/master/code/custom_ops/noise/noise.py\n\nfrom torch import nn\nfrom torch.autograd import Function\nimport plan2scene.texture_gen.utils.neural_texture_helper as utils_nt\nimport noise_cuda\nimport torch\nimport numpy as np\nfrom torch.autograd impor...
[ [ "torch.zeros_like" ], [ "torch.tensor", "torch.zeros", "torch.cat" ] ]
liloganle/Reinforcement-Learning
[ "29ffb74a1c8e506c544245c9aff37e958e503f26", "29ffb74a1c8e506c544245c9aff37e958e503f26", "29ffb74a1c8e506c544245c9aff37e958e503f26" ]
[ "Chapter9/Figure9-1.py", "Chapter8/Figure8-8.py", "Chapter5/Figure5-1.py" ]
[ "# -*- coding:utf-8 -*-\n\nimport numpy as np\nfrom tqdm import tqdm\nimport matplotlib.pyplot as plt\n\n\nclass RandomWalk(object):\n def __init__(self, num_states=1000, groups=10, alpha=2e-5):\n self.num_states = num_states # the number of states\n self.groups = groups ...
[ [ "matplotlib.pyplot.legend", "matplotlib.pyplot.figure", "numpy.arange", "numpy.linalg.norm", "matplotlib.pyplot.savefig", "matplotlib.pyplot.plot", "numpy.random.randint", "matplotlib.pyplot.close", "numpy.random.binomial", "matplotlib.pyplot.xlabel", "matplotlib.pyplot...
timelyportfolio/bokeh
[ "6cecb7211277b9d838039d0eb15e50a10f9ac3d1", "6cecb7211277b9d838039d0eb15e50a10f9ac3d1", "a976a85535cf137c6238ce9e90b41ab14ae8ce22", "a976a85535cf137c6238ce9e90b41ab14ae8ce22", "a976a85535cf137c6238ce9e90b41ab14ae8ce22", "a976a85535cf137c6238ce9e90b41ab14ae8ce22" ]
[ "sphinx/source/tutorial/solutions/les_mis.py", "examples/glyphs/prim_server.py", "bokeh/charts/builder/tests/test_area_builder.py", "bokeh/properties.py", "examples/plotting/file/ajax_source.py", "tests/glyphs/Text.py" ]
[ "import numpy as np\n\nfrom bokeh.plotting import figure, output_file, show\nfrom bokeh.models import HoverTool, ColumnDataSource\nfrom bokeh.sampledata.les_mis import data\n\n# EXERCISE: try out different sort orders for the names\nnodes = data['nodes']\nnames = [node['name'] for node in sorted(data['nodes'], key=...
[ [ "numpy.empty" ], [ "numpy.arange" ], [ "pandas.DataFrame", "numpy.testing.assert_array_equal", "numpy.array", "numpy.zeros", "numpy.testing.assert_array_almost_equal" ], [ "numpy.array" ], [ "numpy.random.random" ], [ "numpy.linspace" ] ]
aristoteleo/scribe-py
[ "ea28d2b588f8648b9ce1679fe18c3142aee2aa58" ]
[ "Scribe/other_estimators.py" ]
[ "import pandas\nimport numpy as np\nfrom multiprocessing import Pool\n\n\ndef __individual_corr(id1, id2, x, y):\n return (id1, id2, corr(x, y)[0])\n\n\ndef __individual_mi(id1, id2, x, y):\n return (id1, id2, mi(x, y))\n\n\ndef corr(self, number_of_processes=1):\n \"\"\"Calculate pairwise correlation over...
[ [ "pandas.DataFrame" ] ]
frankilepro/LiTeFlow
[ "d07105ea00ad29b701e1b100d9cda2297eef19de" ]
[ "liteflow/input.py" ]
[ "\"\"\"Utilities for input pipelines.\"\"\"\n\nimport tensorflow as tf\n\n\ndef shuffle(tensors,\n capacity=32,\n min_after_dequeue=16,\n num_threads=1,\n dtypes=None,\n shapes=None,\n seed=None,\n shared_name=None,\n name='shuf...
[ [ "tensorflow.train.QueueRunner", "tensorflow.train.add_queue_runner", "tensorflow.RandomShuffleQueue", "tensorflow.name_scope", "tensorflow.train.batch" ] ]
Nickwangpeng/tsfresh
[ "48118627d9d4644906613e25b077ce2ec82ca2f9" ]
[ "tsfresh/feature_selection/relevance.py" ]
[ "# -*- coding: utf-8 -*-\n# This file as well as the whole tsfresh package are licenced under the MIT licence (see the LICENCE.txt)\n# Maximilian Christ (maximilianchrist.com), Blue Yonder Gmbh, 2016\n\"\"\"\nContains a feature selection method that evaluates the importance of the different extracted features. To d...
[ [ "pandas.concat", "pandas.Series" ] ]
moonieann/welib
[ "0e430ad3ca034d0d2d60bdb7bbe06c947ce08f52", "0e430ad3ca034d0d2d60bdb7bbe06c947ce08f52", "0e430ad3ca034d0d2d60bdb7bbe06c947ce08f52", "0e430ad3ca034d0d2d60bdb7bbe06c947ce08f52", "0e430ad3ca034d0d2d60bdb7bbe06c947ce08f52", "0e430ad3ca034d0d2d60bdb7bbe06c947ce08f52", "0e430ad3ca034d0d2d60bdb7bbe06c947ce08f5...
[ "welib/FEM/reduction.py", "welib/FEM/utils.py", "welib/tools/external/setup.py", "welib/fast/olaf.py", "welib/tools/spectral.py", "welib/FEM/fem_beam.py", "welib/weio/tecplot_file.py" ]
[ "import numpy as np\n\nfrom welib.system.eva import eig\n\n\ndef CraigBampton(MM, KK, Ileader, nModesCB=None, Ifollow=None, F=None, DD=None, fullModesOut=False): \n \"\"\"\n Performs the CraigBampton (CB) reduction of a system given some input master dofs index\n and a number of modes. Reduced matrices, an...
[ [ "numpy.diag", "numpy.ix_", "numpy.sqrt", "numpy.asarray", "numpy.arange", "numpy.eye", "numpy.set_printoptions", "numpy.setdiff1d", "numpy.linalg.lstsq", "numpy.block", "numpy.transpose", "numpy.array", "numpy.zeros" ], [ "numpy.asarray", "numpy.arra...
c4dt/mlbench-core
[ "8a5cf6e00ff4535b2aea23b213241858a5ee5f00" ]
[ "mlbench_core/optim/pytorch/fp_optimizers.py" ]
[ "# import ctypes\nimport logging\nimport math\n\nimport torch\nimport torch.distributed as dist\nfrom torch.nn.utils import clip_grad_norm_\n\nfrom mlbench_core.utils.pytorch.distributed import (\n AllReduceAggregation,\n AllReduceAggregationHVD,\n)\n\ntry:\n from apex.optimizers import FusedAdam\n from...
[ [ "torch.nn.utils.clip_grad_norm_", "torch.device", "torch.distributed.get_world_size", "torch.nn.Parameter" ] ]
yj1990/sec_mmf
[ "72a8c0d5a6aadb4362c07a5606c70e51b08a53cd" ]
[ "secmmf/mmf_data_loader/form_parsers.py" ]
[ "import pandas as pd\nimport bs4 as bs\nimport untangle as ut\nimport requests\nimport urllib.request as rq\nfrom collections import OrderedDict\n\nfrom secmmf.mmf_data_loader.utils import get_edgar_url\n\nclass N_MFP2:\n\n def __init__(self):\n self.select_cols()\n\n def born(self, tag):\n # if...
[ [ "pandas.wide_to_long", "pandas.DataFrame" ] ]
wjwainwright/Capstone
[ "a2ea661079ece6ff5008f4399b3f0f6d32c598d3" ]
[ "IsoFit.py" ]
[ "try:\n runCount += 1\nexcept:\n isoIn = False\n clIn = False\n cataIn = False\n closePlots = False\n resultsIn = False\n clusterList = []\n clusters=[]\n isochrones = []\n isoList = []\n catalogue = []\n runCount = 1\n\nclass resultClusterObj:\n def __init__(self,cl):\n ...
[ [ "matplotlib.pyplot.legend", "numpy.polyfit", "numpy.amax", "numpy.sqrt", "numpy.linspace", "numpy.arctan", "matplotlib.colors.to_rgba", "numpy.asarray", "numpy.vstack", "matplotlib.pyplot.get_cmap", "matplotlib.pyplot.axes", "matplotlib.pyplot.plot", "numpy.max"...
aripekka/tbcalc
[ "a0337db245f5391bfa9a42123994832c299b1fbe" ]
[ "tests/test_tensor_transform.py" ]
[ "# -*- coding: utf-8 -*-\n\"\"\"\nTests for the tensor transform functions. Run with pytest.\n\nCreated on Sat May 9 00:09:00 2020\n\n@author: aripekka\n\"\"\"\n\nimport sys\nimport os.path\nimport numpy as np\n\nsys.path.insert(1, os.path.join(os.path.dirname(__file__),'..'))\n\nfrom tbcalc.transverse_deformation ...
[ [ "numpy.sqrt", "numpy.linspace", "numpy.isnan", "numpy.finfo", "numpy.arctan2", "numpy.meshgrid" ] ]
liyunze-coding/Trigger-Me-Elmo-2
[ "6950ffa4bfd264e213626f1ab3cff249fbab36da" ]
[ "app.py" ]
[ "from flask import Flask, render_template, request, jsonify\nimport base64\nimport logging\nimport numpy as np\nfrom deepface import DeepFace\nfrom PIL import Image\nfrom io import BytesIO\nimport subprocess\nimport os\nimport cv2\nimport random\nimport webbrowser\n\napp = Flask(__name__)\nlog = logging.getLogger('...
[ [ "numpy.array" ] ]
pyrito/SpeechSplit
[ "ee70ee77e54d5b7cd1b39e7bef1cb96ae78f8beb" ]
[ "solver.py" ]
[ "from torch.utils.tensorboard.summary import hparams\nfrom model import Generator_3 as Generator\nfrom model import InterpLnr\nimport matplotlib.pyplot as plt\nimport torch\nimport torch.nn.functional as F\nimport numpy as np\nimport os\nimport time\nimport datetime\nimport pickle\n\nfrom utils import pad_seq_to_2,...
[ [ "numpy.hstack", "numpy.pad", "torch.cat", "torch.load", "numpy.squeeze", "torch.zeros_like", "torch.from_numpy", "torch.tensor", "torch.nn.functional.mse_loss", "numpy.mean", "torch.utils.tensorboard.SummaryWriter", "torch.cuda.is_available", "torch.no_grad" ]...
snsnlou/mars
[ "6b8eec162eccc8bb980a98ca2cf1e6a4b866d302", "6b8eec162eccc8bb980a98ca2cf1e6a4b866d302", "6b8eec162eccc8bb980a98ca2cf1e6a4b866d302", "6b8eec162eccc8bb980a98ca2cf1e6a4b866d302", "6b8eec162eccc8bb980a98ca2cf1e6a4b866d302" ]
[ "mars/dataframe/datastore/tests/test_datastore_execute.py", "mars/tensor/datasource/diag.py", "mars/dataframe/indexing/setitem.py", "mars/tensor/datasource/eye.py", "mars/tensor/base/isin.py" ]
[ "# Copyright 1999-2020 Alibaba Group Holding 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 appl...
[ [ "pandas.concat", "numpy.random.choice", "pandas.RangeIndex", "numpy.arange", "pandas.testing.assert_frame_equal", "numpy.random.rand", "pandas.read_sql" ], [ "numpy.cumsum" ], [ "numpy.isnan", "pandas.api.types.is_scalar", "pandas.api.types.is_list_like", "n...
candleinwindsteve/Stratipy
[ "ea505df1e4830141c590922d654edfbde498b924", "ea505df1e4830141c590922d654edfbde498b924" ]
[ "stratipy/filtering_diffusion.py", "stratipy/nbs_cluster.py" ]
[ "#!/usr/bin/env python\n# coding: utf-8\nimport sys\nimport numpy as np\nimport scipy.sparse as sp\nfrom scipy.sparse.linalg import norm\nfrom scipy.io import loadmat, savemat\nfrom nbs_class import Ppi, Patient\nfrom subprocess import call\n# import h5py\nimport os\nimport glob\nimport time\nimport datetime\n\n# N...
[ [ "scipy.sparse.csc_matrix", "scipy.sparse.eye", "numpy.asarray", "numpy.arange", "numpy.isnan", "scipy.io.loadmat", "numpy.dstack", "scipy.sparse.linalg.norm", "numpy.zeros_like", "numpy.argpartition", "scipy.sparse.vstack", "scipy.sparse.lil_matrix.transpose", "...
MohammadWasil/Self-Driving-Car
[ "9ef5b77e1268623c11e4c39d5c8e1e990caee273", "9ef5b77e1268623c11e4c39d5c8e1e990caee273" ]
[ "Self Driving Car/Python with Tensorflow/driveSDC.py", "Self Driving Car/Python with Tensorflow/CNN_Model.py" ]
[ "import socket\r\n\r\nfrom tensorflow.keras.models import load_model\r\n\r\n\r\nfrom PIL import ImageGrab\r\nimport numpy as np\r\nimport cv2\r\nimport os\r\n\r\n#Load the model.\r\nmodel = load_model(r\"D:\\Unity Game\\Self Driving Car\\SDCProgram\\Best Models\\data-003.h5\") \t# Directory to load the model\r\n\r\...
[ [ "numpy.asarray", "tensorflow.keras.models.load_model", "numpy.array" ], [ "tensorflow.keras.callbacks.ModelCheckpoint", "pandas.read_csv", "numpy.expand_dims", "tensorflow.keras.models.Sequential", "tensorflow.keras.layers.Lambda", "tensorflow.keras.layers.Dense", "tens...
fluxtransport/fiasco
[ "9d70d8bdb03197be1ddfd433e1392e214a1468e8", "9d70d8bdb03197be1ddfd433e1392e214a1468e8" ]
[ "fiasco/element.py", "fiasco/fiasco.py" ]
[ "\"\"\"\nClasses and functions for element-level operations\n\"\"\"\nimport numpy as np\nimport astropy.units as u\nimport plasmapy\n\nimport fiasco\n\n__all__ = ['Element']\n\n\nclass Element(fiasco.IonCollection):\n \"\"\"\n Collection of all ions for a particular element.\n\n The `Element` object provid...
[ [ "numpy.linalg.svd", "numpy.zeros", "numpy.fabs" ], [ "scipy.interpolate.interp1d", "numpy.zeros" ] ]
yigitozgumus/Polimi_Thesis
[ "711c1edcf1fdb92fc6c15bf5ab1be141c13995c3", "711c1edcf1fdb92fc6c15bf5ab1be141c13995c3", "711c1edcf1fdb92fc6c15bf5ab1be141c13995c3" ]
[ "models/new/sencebgan.py", "trainers/bigan_trainer.py", "trainers/sencebgan_denoiser_trainer.py" ]
[ "import tensorflow as tf\n\nfrom base.base_model import BaseModel\nfrom utils.alad_utils import get_getter\nimport utils.alad_utils as sn\n\n\nclass SENCEBGAN(BaseModel):\n def __init__(self, config):\n super(SENCEBGAN, self).__init__(config)\n self.build_model()\n self.init_saver()\n\n d...
[ [ "tensorflow.get_variable", "tensorflow.concat", "tensorflow.control_dependencies", "tensorflow.layers.dropout", "tensorflow.reduce_sum", "tensorflow.train.ExponentialMovingAverage", "tensorflow.tanh", "tensorflow.train.AdamOptimizer", "tensorflow.group", "tensorflow.summary...