repo_name stringlengths 6 130 | hexsha list | file_path list | code list | apis list |
|---|---|---|---|---|
MUTTERSCHIFF/ngraph-neon | [
"8988ab90ee81c8b219ea5c374702e56d7f383302"
] | [
"tests/frontend_api/test_dropout.py"
] | [
"# ******************************************************************************\n# Copyright 2014-2018 Intel Corporation\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# ... | [
[
"numpy.random.uniform"
]
] |
Alopex4/spruce | [
"2bf0bae18fe9b0d13691f2ee926071635cbe7c6f"
] | [
"src/dialogs/statisticDialog.py"
] | [
"#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\nimport sys\nfrom PyQt5 import QtWidgets\n\nfrom matplotlib.backends.backend_qt5agg import FigureCanvasQTAgg as FigureCanvas\nfrom matplotlib.backends.backend_qt5agg import \\\n NavigationToolbar2QT as NavigationToolbar\nimport matplotlib.pyplot as plt\n\n\nclass ... | [
[
"matplotlib.backends.backend_qt5agg.NavigationToolbar2QT",
"matplotlib.backends.backend_qt5agg.FigureCanvasQTAgg",
"matplotlib.pyplot.figure"
]
] |
chahuja/mix-stage | [
"6f47626ce46bd9b28c45d1255b328b17b3650c4f"
] | [
"src/model/speech2gesture.py"
] | [
"import os\nimport sys\nsys.path.append(os.path.dirname(os.path.abspath(__file__)))\nsys.path.append(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))\n\nimport pdb\n\nfrom .layers import *\n\nimport torch\nimport torch.nn as nn\n\nclass Speech2Gesture_G(nn.Module):\n '''\n Baseline: http://people.eecs... | [
[
"torch.nn.Sequential",
"torch.nn.LeakyReLU",
"torch.nn.ModuleList",
"torch.nn.Conv1d"
]
] |
ishine/neural_sp | [
"7995613541d994976b00d80dcc12e2835163acfb"
] | [
"neural_sp/models/lm/transformer_xl.py"
] | [
"# Copyright 2020 Kyoto University (Hirofumi Inaguma)\n# Apache 2.0 (http://www.apache.org/licenses/LICENSE-2.0)\n\n\"\"\"TransformerXL language model.\"\"\"\n\nimport copy\nimport logging\nimport math\nimport os\nimport random\nimport shutil\nimport torch\nimport torch.nn as nn\n\nfrom neural_sp.models.lm.lm_bas... | [
[
"matplotlib.use",
"torch.nn.Linear",
"torch.nn.Dropout",
"torch.nn.LayerNorm",
"torch.cat",
"matplotlib.ticker.MaxNLocator",
"torch.no_grad",
"torch.tril",
"matplotlib.pyplot.close",
"matplotlib.pyplot.subplots",
"matplotlib.pyplot.clf",
"torch.empty",
"torch.Te... |
mosalen/Keras-Spam-Detection-with-CNN-W2V | [
"0a2660c50de1d6e37175b30b3e45689bce8aa58c"
] | [
"w2v_cnn+lstm.py"
] | [
"#coding:utf-8\nimport sys\nimport keras\n\nVECTOR_DIR = 'D:/TBdata/baike26g_news13g_novel229g_128.bin'\n#'D:/first/text_classification/wiki.zh.vector.bin'\n\n\nMAX_SEQUENCE_LENGTH = 200\nEMBEDDING_DIM = 128\nVALIDATION_SPLIT = 0.2\nTEST_SPLIT = 0.2\n\n\nprint ('(1) load texts...')\ntrain_texts = open('D:/TBdata/我的... | [
[
"sklearn.metrics.confusion_matrix",
"numpy.delete",
"numpy.asarray",
"sklearn.metrics.classification_report",
"numpy.argmax",
"numpy.diag"
]
] |
BoiseStatePlanetary/eleanor | [
"823cfb8e9972b0600cfe20e6a66b5956a9a177d5"
] | [
"make_postcards.py"
] | [
"#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n\nfrom __future__ import division, print_function\n\n__all__ = [\"make_postcards\"]\n\nimport os\nimport glob\nimport tqdm\nimport fitsio\nimport numpy as np\nfrom time import strftime\nfrom astropy.wcs import WCS\nfrom astropy.table import Table\nfrom astropy.stats ... | [
[
"numpy.arange",
"numpy.shape"
]
] |
matthewfeickert/lumin | [
"00c5f9f3d8a630d780ce09017ff13eb27485534c"
] | [
"lumin/nn/metrics/reg_eval.py"
] | [
"import numpy as np\nfrom typing import Optional, Callable\nimport pandas as pd\nfrom statsmodels.stats.weightstats import DescrStatsW\nfrom fastcore.all import store_attr\n\nfrom ...utils.statistics import bootstrap_stats\nfrom .eval_metric import EvalMetric, OldEvalMetric\nfrom ..data.fold_yielder import FoldYiel... | [
[
"numpy.average",
"numpy.mean"
]
] |
Carrie2001/Chinese-poems-generation-based-on-pictures | [
"63e180c207bde1559b290e79e70b0fa0ce8b0c33"
] | [
"key_word_num/cifar100vgg.py"
] | [
"\nfrom __future__ import print_function\nimport keras\nfrom keras.datasets import cifar100\nfrom keras.preprocessing.image import ImageDataGenerator\nfrom keras.models import Sequential\nfrom keras.layers import Dense, Dropout, Activation, Flatten\nfrom keras.layers import Conv2D, MaxPooling2D, BatchNormalization\... | [
[
"matplotlib.image.imread",
"numpy.mean",
"numpy.std",
"numpy.argmax",
"matplotlib.pyplot.axis",
"matplotlib.pyplot.show",
"numpy.expand_dims",
"matplotlib.pyplot.imshow"
]
] |
tsuwandy/botbuilder-community-python | [
"e035a993cd3b0fd8c7b2ff1126c4e993d0c8efc3",
"e035a993cd3b0fd8c7b2ff1126c4e993d0c8efc3"
] | [
"samples/summarize-bot/siatl/logger/plotting.py",
"samples/summarize-bot/BertSum/src/prepro/data_builder.py"
] | [
"import numpy\nfrom visdom import Visdom\n# import matplotlib.pyplot as plt\n# import seaborn as sns\n\n\nclass Visualizer:\n\n def __init__(self, env=\"main\",\n server=\"http://localhost\",\n port=8097,\n base_url=\"/\",\n http_proxy_host=None,\n ... | [
[
"numpy.concatenate",
"numpy.column_stack"
],
[
"torch.save"
]
] |
zsl-nlp/DeepOffense-Unsupervised | [
"3c6f18eefd1d7302ba2c77eeb1a3ab47d7991fc4"
] | [
"UnsupervisedMT/NMT/src/utils.py"
] | [
"# Copyright (c) 2018-present, Facebook, Inc.\n# All rights reserved.\n#\n# This source code is licensed under the license found in the\n# LICENSE file in the root directory of this source tree.\n#\n\nimport os\nimport re\nimport sys\nimport pickle\nimport random\nimport inspect\nimport argparse\nimport subprocess\... | [
[
"torch.cuda.manual_seed",
"numpy.random.seed",
"torch.ByteTensor",
"torch.manual_seed",
"numpy.sqrt"
]
] |
cbrochtrup/transformers | [
"c89bdfbe720bc8f41c7dc6db5473a2cb0955f224"
] | [
"src/transformers/modeling_utils.py"
] | [
"# coding=utf-8\n# Copyright 2018 The Google AI Language Team Authors, Facebook AI Research authors and The HuggingFace Inc. team.\n# Copyright (c) 2018, NVIDIA CORPORATION. All rights reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in complianc... | [
[
"torch.nn.Linear",
"torch.cat",
"torch.einsum",
"torch.nn.Parameter",
"torch.ones",
"torch.load",
"torch.nn.BCEWithLogitsLoss",
"torch.nn.functional.pad",
"torch.nn.CrossEntropyLoss",
"torch.topk",
"torch.nn.LayerNorm",
"torch.gather",
"torch.is_tensor",
"to... |
aaberbach/bmtk | [
"6efdf6387d2a6badf276b917ee15d238daeae883",
"6efdf6387d2a6badf276b917ee15d238daeae883"
] | [
"bmtk/simulator/filternet/lgnmodel/fitfuns.py",
"bmtk/simulator/filternet/lgnmodel/spatialfilter.py"
] | [
"import os\r\nfrom math import *\r\nimport numpy as np\r\nimport numpy.fft as npft\r\n\r\n\r\ndef makeFitStruct_GLM(dtsim, kbasprs, nkt, flag_exp):\r\n gg = {}\r\n gg['k'] = []\r\n gg['dc'] = 0\r\n gg['kt'] = np.zeros((nkt,1))\r\n gg['ktbas'] = []\r\n gg['kbasprs'] = kbasprs\r\n gg['dt'] = dtsi... | [
[
"numpy.concatenate",
"numpy.array",
"numpy.zeros",
"numpy.log",
"numpy.tile",
"numpy.exp",
"numpy.shape",
"numpy.eye",
"numpy.flipud",
"numpy.min",
"numpy.fft.fft",
"numpy.arange",
"numpy.transpose",
"numpy.size",
"numpy.fft.ifft"
],
[
"numpy.whe... |
databill86/HyperFoods | [
"9267937c8c70fd84017c0f153c241d2686a356dd",
"9267937c8c70fd84017c0f153c241d2686a356dd"
] | [
"venv/lib/python3.6/site-packages/tensorflow_core/lite/experimental/microfrontend/ops/gen_audio_microfrontend_op.py",
"venv/lib/python3.6/site-packages/tensorflow_core/python/keras/api/_v1/keras/applications/nasnet/__init__.py"
] | [
"\"\"\"Python wrappers around TensorFlow ops.\n\nThis file is MACHINE GENERATED! Do not edit.\nOriginal C++ source file: audio_microfrontend_op.cc\n\"\"\"\n\nimport collections\n\nfrom tensorflow.python import pywrap_tensorflow as _pywrap_tensorflow\nfrom tensorflow.python.eager import context as _context\nfrom ten... | [
[
"tensorflow.python.eager.execute.make_float",
"tensorflow.python.util.dispatch.dispatch",
"tensorflow.python.eager.execute.make_type",
"tensorflow.python.framework.ops.to_raw_op",
"tensorflow.python.eager.context.context",
"tensorflow.python.framework.ops.convert_to_tensor",
"tensorflo... |
natkaratkova/covid19_scenarios | [
"40e646ef23453a2b7555529523deb9f18cc5a88d"
] | [
"data/scripts/scenarios.py"
] | [
"import sys\nimport csv\nimport os\nimport json\nimport numpy as np\nimport multiprocessing as multi\nimport yaml\n\nfrom uuid import uuid4\nsys.path.append('..')\n\nimport generated.types as schema\n\nfrom datetime import datetime\nfrom scipy.stats import linregress\nfrom paths import TMP_CASES, BASE_PATH, JSON_DI... | [
[
"numpy.array",
"numpy.log",
"numpy.minimum",
"scipy.stats.linregress",
"numpy.exp"
]
] |
robertwb/model-analysis | [
"e081016a1c81f17057ad3714f867832632899504"
] | [
"tensorflow_model_analysis/eval_saved_model/example_trainers/fixed_prediction_estimator.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 ... | [
[
"tensorflow.estimator.export.build_parsing_serving_input_receiver_fn",
"tensorflow.estimator.EstimatorSpec",
"tensorflow.estimator.export.RegressionOutput",
"tensorflow.FixedLenFeature",
"tensorflow.constant",
"tensorflow.losses.mean_squared_error",
"tensorflow.estimator.Estimator",
... |
jsasaki-utokyo/model2roms | [
"f2dbe56cd4c3ecfbb88177ed0ff34db48c148b8d"
] | [
"interp2D.py"
] | [
"from __future__ import print_function\n\nimport datetime\nimport logging\n\nimport extrapolate as ex\nimport numpy as np\n\ntry:\n import ESMF\nexcept ImportError:\n logging.error(\"[M2R_interp2D] Could not find module ESMF\")\n pass\n\n__author__ = 'Trond Kristiansen'\n__email__ = 'me@trondkristiansen.co... | [
[
"numpy.rot90",
"numpy.asarray",
"numpy.zeros",
"matplotlib.pyplot.savefig",
"numpy.squeeze"
]
] |
even311379/EbirdTaiwan2020 | [
"2c1aa4d7346b5ade909d45f7c245fa4988394124"
] | [
"ebirdtaiwan/dash_apps/TaipeiCompetition.py"
] | [
"import dash\nimport dash_core_components as dcc\nimport dash_html_components as html\nfrom dash.dependencies import Input, Output, State\nfrom django_plotly_dash import DjangoDash\n\nimport dash_bootstrap_components as dbc\nimport plotly.graph_objs as go\nimport random\nimport json\nimport pandas as pd\nimport num... | [
[
"pandas.DataFrame"
]
] |
Doctorado-ML/mufs | [
"a0f172ac13870043494050ad988a279369043e1b"
] | [
"sample.py"
] | [
"import warnings\nimport time\nfrom mufs import MUFS\nfrom mufs.Metrics import Metrics\nfrom stree import Stree\nimport numpy as np\nfrom scipy.io import arff\n\nmufsc = MUFS(discrete=False)\n\nfilename = \"conn-bench-sonar-mines-rocks.arff\"\ndata, meta = arff.loadarff(filename)\ntrain = np.array([data[i] for i in... | [
[
"scipy.io.arff.loadarff",
"numpy.array"
]
] |
Ginfung/FSSE | [
"c54510b78dfceec76c74893e8514ed5177b504e5"
] | [
"Metrics/tse_plots.py"
] | [
"from __future__ import division\nimport matplotlib.pyplot as plt\nfrom matplotlib.ticker import ScalarFormatter\nimport pickle\nfrom scipy.stats import ttest_ind\nfrom numpy import median\nimport scipy\nimport numpy\nimport debug\n\n\nclass FixedOrderFormatter(ScalarFormatter):\n \"\"\"Formats axis ticks using ... | [
[
"numpy.median",
"numpy.percentile",
"matplotlib.pyplot.subplots",
"matplotlib.pyplot.tight_layout",
"matplotlib.pyplot.show",
"scipy.stats.wilcoxon",
"matplotlib.pyplot.subplots_adjust",
"matplotlib.ticker.ScalarFormatter.__init__"
]
] |
XuesongDing/fatiando | [
"57a0e0802fde2e53628511d3a7a2964e69bb309a",
"57a0e0802fde2e53628511d3a7a2964e69bb309a"
] | [
"fatiando/mesher/mesh.py",
"fatiando/seismic/epic2d.py"
] | [
"\"\"\"\nMeshes (collections) of geometric objects.\n\nMeshes behave like lists/arrays of geometric objects (they are iterables).\n\"\"\"\nfrom __future__ import division, absolute_import\nfrom future.builtins import range, object, super\nimport numpy as np\nimport scipy.special\nimport scipy.interpolate\nimport co... | [
[
"numpy.array",
"numpy.ma.isMA",
"numpy.savetxt",
"numpy.reshape",
"numpy.zeros",
"numpy.fromiter",
"numpy.arange",
"numpy.linspace",
"numpy.meshgrid"
],
[
"numpy.array",
"numpy.empty",
"numpy.sqrt"
]
] |
NYCPlanning/db-equitable-development-tool | [
"b24d83dc4092489995cabcdcb611642c1c8ee3b2"
] | [
"utils/PUMA_helpers.py"
] | [
"import geopandas as gp\nfrom shapely.geometry import Point\nimport pandas as pd\nfrom numpy import nan\nimport requests\nfrom utils.geocode import from_eviction_address\n\n\ngeocode_functions = {\"from_eviction_address\": from_eviction_address}\n\nborough_code_mapper = {\n \"037\": \"BX\",\n \"038\": \"MN\",... | [
[
"pandas.notnull"
]
] |
CrazySummerday/ctpn.pytorch | [
"99f6baf2780e550d7b4656ac7a7b90af9ade468f"
] | [
"ctpn/dataset.py"
] | [
"#-*- coding:utf-8 -*-\nimport os\nimport numpy as np\nimport cv2\nimport torch\nfrom torch.utils.data import Dataset\nimport xml.etree.ElementTree as ET\nfrom ctpn.utils import cal_rpn\n\nIMAGE_MEAN = [123.68, 116.779, 103.939]\n\n'''\n从xml文件中读取图像中的真值框\n'''\ndef readxml(path):\n gtboxes = []\n xml = ET.parse... | [
[
"numpy.array",
"numpy.random.randint",
"numpy.expand_dims",
"torch.from_numpy"
]
] |
trendmicro/PyShortTextCategorization | [
"86d8ad22035243dbeb1c53fe286d6ef8be9a9fd7"
] | [
"shorttext/stack/stacking.py"
] | [
"import pickle\n\nimport numpy as np\nfrom keras.layers import Dense, Reshape\nfrom keras.models import Sequential\nfrom keras.regularizers import l2\n\nimport shorttext.utils.classification_exceptions as e\nimport shorttext.utils.kerasmodel_io as kerasio\nfrom shorttext.utils.compactmodel_io import CompactIOMachin... | [
[
"numpy.array"
]
] |
mrocklin/napari | [
"b61d9ae570e30091a97b6c76e37cd95fe5b296b6",
"b61d9ae570e30091a97b6c76e37cd95fe5b296b6"
] | [
"examples/nD_multiscale_image.py",
"napari/_qt/qt_viewer.py"
] | [
"\"\"\"\nDisplays an nD multiscale image\n\"\"\"\n\nfrom skimage.transform import pyramid_gaussian\nimport napari\nimport numpy as np\n\n\n# create multiscale from random data\nbase = np.random.random((1536, 1536))\nbase = np.array([base * (8 - i) / 8 for i in range(8)])\nprint('base shape', base.shape)\nmultiscale... | [
[
"numpy.random.random"
],
[
"numpy.array"
]
] |
vishalbelsare/TileDB-Py | [
"bb4d5ea4d07e02721e431956363d3b9d59c3b9e6"
] | [
"tiledb/tests/test_dask.py"
] | [
"import pytest\n\nda = pytest.importorskip(\"dask.array\")\n\nimport sys\nimport tiledb\nfrom tiledb.tests.common import DiskTestCase\n\nimport numpy as np\nfrom numpy.testing import assert_array_equal, assert_approx_equal\n\n# override the no_output fixture because it conflicts with these tests\n# eg: \"Resource... | [
[
"numpy.array",
"numpy.testing.assert_array_equal",
"numpy.ones",
"numpy.random.randn",
"numpy.mean"
]
] |
FMI-RobertoDeresu/fmi-text-to-image | [
"23b494d4f79f7bef7b0b664ebf5a94917018b50a"
] | [
"main.py"
] | [
"import utils\nimport nltk\nimport argparse\nimport tensorflow as tf\nimport time\nimport re\nimport numpy as np\nimport skimage\nimport matplotlib.pyplot as plt\nfrom pathlib import Path\nfrom tensorflow.python.client import device_lib\nfrom models.word2vec import Word2Vec\nfrom matplotlib import image as mpimg\nf... | [
[
"numpy.random.rand",
"tensorflow.conj",
"numpy.array_equal",
"tensorflow.tensordot",
"tensorflow.matmul",
"tensorflow.contrib.tpu.shutdown_system",
"tensorflow.contrib.tpu.batch_parallel",
"tensorflow.global_variables_initializer",
"tensorflow.InteractiveSession",
"numpy.ra... |
ziqi-zhang/ReMoS_artifact | [
"9cbac09333aeb0891cc54d287d6829fdf4bd5d23"
] | [
"NLP_backdoor/RIPPLe/poison.py"
] | [
"from typing import Dict, Union, Callable, List, Optional\nfrom pathlib import Path\nimport subprocess\nimport numpy as np\nimport pandas as pd\nimport random\nimport torch\nimport yaml\nimport json\nimport shutil\nfrom sklearn.feature_extraction.text import CountVectorizer, TfidfVectorizer\nfrom sklearn.linear_mod... | [
[
"numpy.random.choice",
"torch.no_grad",
"numpy.argsort",
"pandas.concat",
"torch.zeros_like",
"torch.load",
"pandas.read_csv"
]
] |
EnriqueNueve/ResNetFCN | [
"c01b3675ec77089ba9e3a2a8a0fa4b7d1baf95fc"
] | [
"ResNetFCN_App/resnetfcn_app.py"
] | [
"# python3 resnetfcn_app.py test_pic.jpg\n\n##########################\n\nimport os\nimport numpy as np\nimport tensorflow as tf\nfrom PIL import Image , ImageOps\nimport matplotlib.pyplot as plt\nimport matplotlib.image as mpimg\n\n##########################\n\n# Passed img path\n#img_path = \"test_pic.jpg\"\nimg_... | [
[
"numpy.concatenate",
"numpy.array",
"tensorflow.convert_to_tensor",
"numpy.reshape",
"tensorflow.lite.Interpreter",
"matplotlib.pyplot.title",
"matplotlib.pyplot.figure",
"numpy.where",
"numpy.transpose",
"numpy.argmax",
"matplotlib.pyplot.axis",
"matplotlib.pyplot.... |
prasad4fun/neural_sequence_labeling | [
"a580ba1b559e915cb5a69ac15b29d383dc1cf2fe"
] | [
"models/base_model.py"
] | [
"import tensorflow as tf\nimport numpy as np\nfrom tensorflow.contrib.crf import viterbi_decode, crf_log_likelihood\nfrom tensorflow.python.ops.rnn_cell import LSTMCell, GRUCell, MultiRNNCell\nfrom utils import CoNLLeval, load_dataset, get_logger, process_batch_data, align_data\nfrom data.common import word_convert... | [
[
"tensorflow.reduce_min",
"tensorflow.train.AdagradOptimizer",
"tensorflow.train.get_checkpoint_state",
"tensorflow.python.ops.rnn_cell.LSTMCell",
"tensorflow.global_variables_initializer",
"tensorflow.train.GradientDescentOptimizer",
"tensorflow.trainable_variables",
"tensorflow.co... |
shyan0903/522_Ramen | [
"3f09087fda543568d3d7c3e9759e92a815479cfc"
] | [
"src/download_data.py"
] | [
"# author: Irene and Anthea Chen\r\n# date: 2021-11-24\r\n\r\n\"\"\"Download needed dataframe\r\n\r\nUsage: download_data.py --url=<url> --out_file=<out_file> \r\n \r\nOptions:\r\n--url=<url> the url for the data set\r\n--out_file=<out_file> Path (including filename) of where to locally write the file... | [
[
"pandas.read_excel"
]
] |
maximzubkov/Transformer-XH | [
"1712c195b75473ba50779baf92e291b1d29ad248"
] | [
"transformer-xh/main.py"
] | [
"# Copyright (c) Microsoft Corporation.\n# Licensed under the MIT license.\n\nimport torch\nimport argparse\nimport os\nimport json\nimport numpy as np\n\nfrom model import Model_Hotpot, Model_FEVER\nimport data\nimport logging\nimport random\nimport torch.nn as nn\nimport torch.distributed as dist\nfrom tqdm impor... | [
[
"torch.device",
"torch.cuda.manual_seed_all",
"numpy.random.seed",
"torch.distributed.init_process_group",
"torch.manual_seed",
"torch.cuda.is_available"
]
] |
waikuen2010/onnxruntime | [
"dbe1b57a71248946ade29c762817699fd1adc3ff"
] | [
"tools/ci_build/build.py"
] | [
"#!/usr/bin/env python3\n# Copyright (c) Microsoft Corporation. All rights reserved.\n# Licensed under the MIT License.\n\nimport argparse\nimport contextlib\nimport glob\nimport os\nimport re\nimport shlex\nimport shutil\nimport subprocess\nimport sys\nimport platform\nfrom amd_hipify import amd_hipify\nfrom distu... | [
[
"torch.cuda.device_count"
]
] |
apoorvjain25/opendr-1 | [
"5467263c9ef46118399686b56150556bb2a9fcb9"
] | [
"demo_fit_teapot.py"
] | [
"__author__ = 'pol'\n\nimport matplotlib.pyplot as plt\nimport glfw\nimport generative_models\nfrom utils import *\nimport OpenGL.GL as GL\nfrom utils import *\nplt.ion()\nfrom OpenGL import contextdata\nimport sys\n\n#__GL_THREADED_OPTIMIZATIONS\n\n#Main script options:r\n\nglModes = ['glfw','mesa']\nglMode = glMo... | [
[
"matplotlib.pyplot.ion",
"matplotlib.pyplot.title",
"matplotlib.pyplot.figure",
"matplotlib.pyplot.show",
"matplotlib.pyplot.imshow"
]
] |
fanglab/6mASCOPE | [
"3f1fdcb7693ff152f17623ce549526ec272698b1",
"3f1fdcb7693ff152f17623ce549526ec272698b1"
] | [
"SLpackage/private/pacbio/pythonpkgs/kineticstools/lib/python2.7/site-packages/kineticsTools/BasicLdaEnricher.py",
"SLpackage/private/pacbio/pythonpkgs/pbcore/lib/python2.7/site-packages/pbcore/io/align/CmpH5IO.py"
] | [
"from __future__ import absolute_import\n# Basic LDA Enricher class\n\nfrom math import sqrt\nimport math\nimport scipy.stats as s\nimport array as a\n\nfrom scipy.optimize import fminbound\nfrom scipy.special import gammaln as gamln\nfrom numpy import log, pi, log10, e, log1p, exp\nimport numpy as np\n\nfrom .Mult... | [
[
"numpy.log",
"numpy.zeros",
"numpy.genfromtxt",
"numpy.exp",
"numpy.multiply"
],
[
"numpy.uint8",
"numpy.array",
"numpy.isnan",
"numpy.uint32",
"numpy.uint16",
"numpy.frombuffer",
"numpy.cumsum",
"numpy.int32",
"numpy.flatnonzero"
]
] |
nmandery/h3ronpy | [
"58602a294bbb916f16c2080fb13aef0e5bd569a2"
] | [
"tests/test_op.py"
] | [
"import h3.api.numpy_int as h3\nimport numpy as np\n\nfrom h3ronpy.op import kring_distances_agg, kring_distances\n\n\ndef test_kring_distances_agg():\n h3indexes = np.array([h3.geo_to_h3(10.2, 45.5, 8), h3.geo_to_h3(10.3, 45.1, 8)], dtype=np.uint64)\n k_max = 4\n df = kring_distances_agg(h3indexes, k_max,... | [
[
"numpy.unique"
]
] |
armandwayoff/Graph-Optimization | [
"9a7472d023935a49e270f1d1d7191af26ca6ffe9"
] | [
"Simulated Annealing/simulated_annealing_subplots.py"
] | [
"# inspired by https://www.youtube.com/watch?v=NPE3zncXA5s\n\nimport matplotlib.pyplot as plt\nimport networkx as nx\nfrom math import *\nfrom random import *\nimport time\n\n\nclass Vertex:\n def __init__(self, x, y):\n self.x = x\n self.y = y\n\n\ndef dist(x1, y1, x2, y2):\n return sqrt((x1 - ... | [
[
"matplotlib.pyplot.show",
"matplotlib.pyplot.title",
"matplotlib.pyplot.subplot"
]
] |
rpatil524/datasets | [
"6382607ee210d7cc3075e3006cbba1ad437858f0"
] | [
"src/datasets/download/streaming_download_manager.py"
] | [
"import glob\nimport io\nimport os\nimport posixpath\nimport re\nimport tarfile\nimport time\nfrom asyncio import TimeoutError\nfrom io import BytesIO\nfrom itertools import chain\nfrom pathlib import Path, PurePath, PurePosixPath\nfrom typing import Callable, Generator, Iterable, List, Optional, Tuple, Union\nfrom... | [
[
"pandas.read_csv",
"scipy.io.loadmat"
]
] |
tokupooh/DeZero | [
"8405b72c0ffcf49a946ef6b3ac6fecae97da7c2c"
] | [
"steps/step48.py"
] | [
"if '__file__' in globals():\n import os\n import sys\n sys.path.append(os.path.join(os.path.dirname(__file__), '..'))\nimport math\n\nimport matplotlib.pyplot as plt\nimport numpy as np\n\nimport dezero\nimport dezero.functions as F\nfrom dezero import optimizers\nfrom dezero.models import MLP\n\nif __nam... | [
[
"matplotlib.pyplot.contourf",
"matplotlib.pyplot.savefig",
"numpy.random.permutation",
"numpy.argmax",
"numpy.arange",
"matplotlib.pyplot.scatter"
]
] |
hpi-bp1819-naumann/shift-detector | [
"5d081d05ec084021f11827aa3fd3e167854b2a2a",
"5d081d05ec084021f11827aa3fd3e167854b2a2a"
] | [
"shift_detector/precalculations/text_metadata.py",
"tests/precalculations/test_embedding_distance_precalculation.py"
] | [
"import logging as logger\nimport re\nimport regex\nimport unicodedata\nfrom abc import abstractmethod\nfrom collections import defaultdict\n\nimport pandas as pd\nimport nltk\n# noinspection PyPackageRequirements\nfrom iso639 import languages\nfrom langdetect import detect, DetectorFactory\nfrom nltk.corpus import... | [
[
"pandas.DataFrame",
"pandas.MultiIndex.from_product"
],
[
"pandas.DataFrame",
"numpy.array",
"pandas.Series"
]
] |
artyompal/imet | [
"75d708392237a1392ac5fa2f598a747408a88f19"
] | [
"old_models/train_4p_resnetd152b.py"
] | [
"#!/usr/bin/python3.6\n''' Trains a model. '''\n\nimport argparse, hashlib, logging, math, os, pprint, random, sys, time\nimport multiprocessing\nfrom typing import *\nfrom collections import defaultdict, Counter\n\nimport numpy as np\nimport pandas as pd\n\nimport torch\nimport torch.nn as nn\nimport torch.optim a... | [
[
"torch.nn.Linear",
"numpy.load",
"torch.load",
"torch.nn.BCEWithLogitsLoss",
"pandas.read_csv",
"torch.multiprocessing.set_sharing_strategy",
"torch.nn.DataParallel",
"numpy.concatenate",
"numpy.save",
"torch.tensor",
"torch.utils.data.DataLoader",
"numpy.array",
... |
tub-rip/event_utils | [
"1ae06397b17bca32036155b80da64d295d4fe09f"
] | [
"lib/data_formats/read_events.py"
] | [
"import h5py\nimport numpy as np\nimport os\n\ndef compute_indices(event_stamps, frame_stamps):\n \"\"\"\n Given event timestamps and frame timestamps as arrays,\n find the event indices that correspond to the beginning and\n end period of each frames\n @param event_stamps The event timestamps\n @... | [
[
"numpy.array",
"numpy.load",
"numpy.where",
"numpy.stack",
"numpy.searchsorted"
]
] |
sys-bio/SBstoat | [
"31b184176a7f19074c905db76e6e6ac8e4fc36a8"
] | [
"tests/testModelStudy.py"
] | [
"# -*- coding: utf-8 -*-\n\"\"\"\nCreated on Tue Aug 19, 2020\n\n@author: joseph-hellerstein\n\"\"\"\n\nfrom SBstoat.modelStudy import ModelStudy, mkDataSourceDct\nimport tests._testHelpers as th\nfrom tests import _testConstants as tcn\n\nimport matplotlib\nimport numpy as np\nimport os\nimport shutil\nimport unit... | [
[
"matplotlib.use",
"numpy.isclose"
]
] |
hzhwcmhf/contk_docs | [
"d4874cce5347bcf9f33d9fe99756c7145f181b88"
] | [
"hred-tensorflow-master/main.py"
] | [
"import os\n\nimport json\nimport numpy as np\nimport tensorflow as tf\nfrom cotk.dataloader import MultiTurnDialog\nfrom cotk.wordvector import WordVector, Glove\nfrom utils import debug, try_cache\n\nfrom model import HredModel\n\ndef create_model(sess, data, args, embed):\n\twith tf.variable_scope(args.name):\n\... | [
[
"numpy.array",
"tensorflow.train.latest_checkpoint",
"tensorflow.Session",
"tensorflow.train.get_checkpoint_state",
"tensorflow.global_variables",
"tensorflow.ConfigProto",
"tensorflow.variable_scope",
"tensorflow.variables_initializer"
]
] |
nboukraa/openqa | [
"876d56c074f425ec6eff53fe7dda9a1a807bd0c2"
] | [
"src/reader/data.py"
] | [
"#!/usr/bin/env python3\n# Copyright 2017-present, Facebook, Inc.\n# All rights reserved.\n#\n# This source code is licensed under the license found in the\n# LICENSE file in the root directory of this source tree.\n\"\"\"Edit from DrQA\"\"\"\n\nimport numpy as np\nimport logging\nimport unicodedata\n\nfrom torch.u... | [
[
"numpy.random.random",
"numpy.random.shuffle",
"numpy.argsort"
]
] |
teixeirafilipe/cpd | [
"9bd801fa0e9f81807af48cb089f5481c26332994",
"9bd801fa0e9f81807af48cb089f5481c26332994"
] | [
"examples/example_mdrpd.py",
"examples/example_mdrpd2.py"
] | [
"#! /usr/bin/env python3\n\n# MIT License\n#\n#Copyright 2020 Filipe Teixeira\n#\n# Permission is hereby granted, free of charge, to any person obtaining a copy\n# of this software and associated documentation files (the \"Software\"), to deal\n# in the Software without restriction, including without limitation the... | [
[
"sklearn.model_selection.train_test_split",
"pandas.read_csv",
"sklearn.ensemble.RandomForestRegressor"
],
[
"sklearn.model_selection.train_test_split",
"pandas.read_csv",
"sklearn.ensemble.RandomForestRegressor"
]
] |
ctschnur/Qcodes | [
"f75e4786e268f415935aa4658d92526279c7a102"
] | [
"qcodes/instrument_drivers/american_magnetics/AMI430.py"
] | [
"import collections\nimport logging\nimport time\nfrom functools import partial\nfrom typing import Union, Iterable, Callable\nimport numbers\n\nimport numpy as np\n\nfrom qcodes import Instrument, IPInstrument, InstrumentChannel\nfrom qcodes.utils.deprecate import deprecate\nfrom qcodes.math_utils.field_vector imp... | [
[
"numpy.atleast_1d",
"numpy.linalg.norm",
"numpy.isclose",
"numpy.abs"
]
] |
jelletreep/parcels | [
"7ba3e08de7de046474373f6a5fe02835fc99a8dc"
] | [
"parcels/particlefile.py"
] | [
"\"\"\"Module controlling the writing of ParticleSets to NetCDF file\"\"\"\nimport os\nimport random\nimport shutil\nimport string\nfrom datetime import timedelta as delta\nfrom glob import glob\n\nimport netCDF4\nimport numpy as np\n\nfrom parcels.tools.error import ErrorCode\nfrom parcels.tools.loggers import log... | [
[
"numpy.max",
"numpy.array",
"numpy.isclose",
"numpy.zeros",
"numpy.load",
"numpy.save",
"numpy.isfinite",
"numpy.unique"
]
] |
alexyuwen/rasa | [
"cf04a71c980675db9968a79bb8900c96c70cc78c"
] | [
"rasa/shared/core/domain.py"
] | [
"import copy\nimport collections\nimport json\nimport logging\nimport os\nfrom enum import Enum\nfrom pathlib import Path\nfrom typing import (\n Any,\n Dict,\n List,\n NamedTuple,\n NoReturn,\n Optional,\n Set,\n Text,\n Tuple,\n Union,\n TYPE_CHECKING,\n Iterable,\n)\n\nfrom ra... | [
[
"numpy.random.choice"
]
] |
ChenThread/fromage | [
"0feec3fd17a67da4de9fbcb34c77da4ef6d24211"
] | [
"tools/mkatlas.py"
] | [
"import sys, struct\nimport numpy as np\nimport scipy.cluster.vq as vq\nfrom PIL import Image, ImageOps, ImageColor\n\nim = Image.open(sys.argv[1])\nfp = open(sys.argv[2], \"wb\")\nclut = [None] * 256\nsingle_pixel_colors = [None] * 256\nimgdata = [None] * (256*256)\nimgwidth = 256\nmipmap_levels = 4\n\ndef draw_4b... | [
[
"scipy.cluster.vq.vq",
"scipy.cluster.vq.kmeans",
"numpy.zeros"
]
] |
AdamSchunk/pysc2 | [
"c793aeb3a9bf70ffa9880205018a21d5c29b9582"
] | [
"pysc2/lib/features.py"
] | [
"# Copyright 2017 Google Inc. 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 app... | [
[
"numpy.concatenate",
"numpy.array",
"numpy.zeros",
"numpy.unpackbits",
"numpy.frombuffer",
"numpy.all",
"numpy.clip",
"numpy.cumsum"
]
] |
Zac-HD/napari | [
"102a7e8f845893c874d2b86f9371d41130100b89",
"102a7e8f845893c874d2b86f9371d41130100b89"
] | [
"napari/layers/points/_tests/test_points.py",
"napari/benchmarks/benchmark_qt_viewer_image.py"
] | [
"from copy import copy\nfrom itertools import cycle, islice\n\nimport numpy as np\nimport pandas as pd\nimport pytest\nfrom vispy.color import get_colormap\n\nfrom napari._tests.utils import check_layer_world_data_extent\nfrom napari.layers import Points\nfrom napari.layers.points._points_utils import points_to_squ... | [
[
"numpy.concatenate",
"numpy.testing.assert_allclose",
"numpy.array",
"numpy.add",
"numpy.empty",
"numpy.asarray",
"numpy.repeat",
"numpy.testing.assert_equal",
"numpy.random.seed",
"pandas.DataFrame",
"numpy.ix_",
"numpy.random.randint",
"numpy.unique",
"num... |
matiasrvazquez/scikit-learn | [
"e821a9e8a0d4ef63b1219faf9ab902ad0fd4b181"
] | [
"examples/inspection/plot_partial_dependence.py"
] | [
"\"\"\"\n===============================================================\nPartial Dependence and Individual Conditional Expectation Plots\n===============================================================\n\nPartial dependence plots show the dependence between the target function [2]_\nand a set of features of intere... | [
[
"sklearn.inspection.partial_dependence",
"matplotlib.pyplot.colorbar",
"sklearn.inspection.PartialDependenceDisplay.from_estimator",
"pandas.DataFrame",
"sklearn.datasets.fetch_california_housing",
"matplotlib.pyplot.suptitle",
"sklearn.preprocessing.QuantileTransformer",
"matplotl... |
wuchihsu/FLAML | [
"54d303a95ab8615ec298a5a7a530f8d1d477bf68"
] | [
"flaml/model.py"
] | [
"# !\r\n# * Copyright (c) Microsoft Corporation. All rights reserved.\r\n# * Licensed under the MIT License. See LICENSE file in the\r\n# * project root for license information.\r\nfrom contextlib import contextmanager\r\nfrom functools import partial\r\nimport signal\r\nimport os\r\nfrom typing import Callable,... | [
[
"pandas.to_datetime",
"scipy.sparse.issparse",
"pandas.DataFrame",
"numpy.ones",
"sklearn.dummy.DummyRegressor",
"sklearn.dummy.DummyClassifier",
"numpy.argmax",
"numpy.sqrt",
"numpy.issubdtype",
"numpy.squeeze",
"numpy.log2"
]
] |
matrixxd/woofpatrol | [
"af7f7b6f44719450f6e0bf707c82f2be727f2553"
] | [
"env/Scripts/f2py.py"
] | [
"#!C:\\Users\\Darren\\Desktop\\OnlineDogFilter\\env\\Scripts\\python.exe\n# See http://cens.ioc.ee/projects/f2py2e/\nfrom __future__ import division, print_function\n\nimport os\nimport sys\nfor mode in [\"g3-numpy\", \"2e-numeric\", \"2e-numarray\", \"2e-numpy\"]:\n try:\n i = sys.argv.index(\"--\" + mod... | [
[
"numpy.f2py.main"
]
] |
milljm/raven | [
"5f29fe81b75e2ffbeb54a55aa63647e7b2f6457b",
"5f29fe81b75e2ffbeb54a55aa63647e7b2f6457b",
"5f29fe81b75e2ffbeb54a55aa63647e7b2f6457b"
] | [
"framework/PostProcessors/LimitSurfaceIntegral.py",
"framework/Metrics/SklMetric.py",
"framework/PostProcessorFunctions/HistorySetSync.py"
] | [
"# Copyright 2017 Battelle Energy Alliance, 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# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable ... | [
[
"numpy.random.seed",
"numpy.vectorize",
"numpy.unique"
],
[
"sklearn.__version__.split"
],
[
"numpy.array",
"numpy.ndenumerate",
"numpy.zeros",
"numpy.searchsorted",
"numpy.linspace"
]
] |
omardrwch/mfanalysis | [
"36c00e0d4ee346bb6dddc5776a86c8c2ebd4501a"
] | [
"mfanalysis/utils.py"
] | [
"from __future__ import print_function\nfrom __future__ import unicode_literals\n\nimport numpy as np\n\nclass Utils:\n def __init__(self):\n pass\n\n def linear_regression(self, x, y, nj, return_variance = False):\n \"\"\"\n Performs a (weighted or not) linear regression.\n Finds ... | [
[
"numpy.sum",
"numpy.array"
]
] |
sjgg555/aoc2021 | [
"bf3a84a85949b65558a749aa0b39fb5b79b850ac"
] | [
"Day 14/day14pt1.py"
] | [
"from day14data import simple_test_data, data\nimport numpy as np\nfrom collections import Counter\n\n#data = simple_test_data\n\nsteps = 10\ntemplate = data[0]\nstart, end = np.array(data[1]).T\n\nresult = template\nfor step in range(steps):\n step_result = \"\"\n for i in range(len(result)):\n search... | [
[
"numpy.where",
"numpy.array"
]
] |
gabeorlanski/external-knowledge-codegen | [
"3e1e3581f5774ca51d79c97e768eb5227e7e3dba"
] | [
"apidocs/retrieve.py"
] | [
"from typing import List\nimport json\nimport pprint\nimport sys\nimport argparse\nimport re\nfrom tqdm import tqdm\nimport string\nfrom collections import defaultdict\nfrom elasticsearch import Elasticsearch\nimport operator\nimport numpy as np\nimport pickle\n\n#PUNCT_TO_SPACE = dict(zip(list(string.punctuation),... | [
[
"numpy.max",
"numpy.sum",
"numpy.array",
"numpy.log"
]
] |
alisure-fork/gcn | [
"4b7b64f941b89647f1ae9aa1f6a0e4276dbdf0d7"
] | [
"gcn/utils.py"
] | [
"import numpy as np\nimport pickle as pkl\nimport networkx as nx\nimport scipy.sparse as sp\nfrom scipy.sparse.linalg.eigen.arpack import eigsh\nimport sys\n\n\ndef parse_index_file(filename):\n \"\"\"Parse index file.\"\"\"\n index = []\n for line in open(filename):\n index.append(int(line.strip())... | [
[
"numpy.isinf",
"scipy.sparse.coo_matrix",
"numpy.array",
"scipy.sparse.diags",
"numpy.zeros",
"scipy.sparse.vstack",
"scipy.sparse.eye",
"numpy.sort",
"scipy.sparse.linalg.eigen.arpack.eigsh",
"numpy.power",
"scipy.sparse.isspmatrix_coo",
"scipy.sparse.csr_matrix",
... |
crowsonkb/v-diffusion-pytorch | [
"93b6a54986d8259837a100046777fba52d812554"
] | [
"diffusion/sampling.py"
] | [
"import torch\nfrom tqdm.auto import trange\n\nfrom . import utils\n\n\n# DDPM/DDIM sampling\n\n@torch.no_grad()\ndef sample(model, x, steps, eta, extra_args, callback=None):\n \"\"\"Draws samples from a model given starting noise.\"\"\"\n ts = x.new_ones([x.shape[0]])\n\n # Create the noise schedule\n ... | [
[
"torch.randn_like",
"torch.no_grad",
"torch.cuda.amp.autocast",
"torch.enable_grad"
]
] |
chameleon-hpc/chameleon-scripts | [
"67c22be72b436395384dd9d83ef05a3397a851ee"
] | [
"tests_samoa/table_tools/plot_data.py"
] | [
"import sys\nimport getopt\nimport matplotlib.pyplot as plt\nimport matplotlib\nimport os\n\nfrom filter_csv import *\n\nmarkers_times = 'x'\nmarkers_efficiency = 'o'\nmarkers_imbalance = 'o'\n\ncolors = ['#1f77b4','#ff7f0e','#2ca02c']\n\ndef plot_speedup_curve(ax,x,base_time, times, label, marker):\n speedups = [ ... | [
[
"matplotlib.ticker.ScalarFormatter",
"matplotlib.pyplot.figure"
]
] |
keonlee9420/tacotron2_toolkit | [
"fe0e19fdb00f2554d99b0f33e56d65a1d1956b86"
] | [
"logger.py"
] | [
"import random\nimport torch\nfrom tensorboardX import SummaryWriter\nfrom plotting_utils import plot_alignment_to_numpy, plot_spectrogram_to_numpy\nfrom plotting_utils import plot_gate_outputs_to_numpy\n\n\nclass Tacotron2Logger(SummaryWriter):\n def __init__(self, logdir, use_mmi, use_guided_attn_loss):\n ... | [
[
"torch.sigmoid"
]
] |
fmu2/Wasserstein-BiGAN | [
"db4f7f26da54f255cd38451721108f3a762ba3d4"
] | [
"interpolate.py"
] | [
"import argparse, torch\nfrom torchvision import utils\nfrom wali_celeba import create_WALI\n\n\nNLAT = 100\nIMAGE_SIZE = 64\nNUM_CHANNELS = 3\n\n\ndef interpolate(generator, z0, z1, nintp=10, path='linear', filepath=None):\n \"\"\" Interpolate in the latent space.\n\n Args:\n generator: Generator network that... | [
[
"torch.cat",
"torch.sin",
"torch.linspace",
"torch.cuda.is_available",
"torch.load",
"torch.randn"
]
] |
Devanshu24/ignite | [
"2f0ba3e65cfa36b43bc87b315733fd3f3585e430"
] | [
"tests/ignite/engine/test_create_supervised.py"
] | [
"import os\nfrom distutils.version import LooseVersion\nfrom importlib.util import find_spec\nfrom typing import Optional, Union\nfrom unittest.mock import patch\n\nimport pytest\nimport torch\nfrom pytest import approx\nfrom torch.nn import Linear\nfrom torch.nn.functional import mse_loss\nfrom torch.optim import ... | [
[
"torch.nn.Linear",
"torch.cuda.is_available",
"torch.tensor",
"torch.jit.trace",
"torch.randn"
]
] |
dydcfg/prediction-flow | [
"332068f521bba51acc8600fe72e36e92c331bef1"
] | [
"prediction_flow/transformers/column/tests/test_log_transformer.py"
] | [
"import numpy as np\n\nfrom prediction_flow.transformers.column import LogTransformer\n\n\ndef test_normal():\n log_transformer = LogTransformer()\n\n x = np.array([100, 10, 32])\n log_transformer.fit(x)\n\n np.testing.assert_array_almost_equal(\n log_transformer.transform(x), np.array([4.615121,... | [
[
"numpy.array"
]
] |
rahhul/GANs | [
"cec9e2f81528099407b8a9d3dce2f1cf85e449be",
"cec9e2f81528099407b8a9d3dce2f1cf85e449be"
] | [
"cifar10/trainer/discriminator.py",
"LSGAN/utils.py"
] | [
"# python3\n\nimport util\n\nimport tensorflow as tf\nfrom tensorflow import keras\nfrom tensorflow.keras.models import Sequential\nfrom tensorflow.keras.layers import Dense, Conv2D, Dropout, Flatten, LeakyReLU\nfrom tensorflow.keras.layers import BatchNormalization\nfrom tensorflow.keras.optimizers import Adam\nfr... | [
[
"tensorflow.keras.layers.Flatten",
"tensorflow.keras.initializers.glorot_normal",
"tensorflow.keras.layers.Dense",
"tensorflow.keras.layers.Conv2D",
"tensorflow.keras.layers.LeakyReLU",
"tensorflow.keras.layers.Dropout",
"tensorflow.keras.models.Sequential",
"tensorflow.keras.optim... |
MassDynamics/protein-inference | [
"05cc9738a3fcd074d8e6789bb24979a9837082cf"
] | [
"protein_inference/benchmarking/benchmark_percolator_inference.py"
] | [
"import pandas as pd\nimport plotly.express as px\nimport plotly.graph_objects as go\n\n\nclass ProcessPercolatorInference():\n\n def load_protein_table(self, path):\n protein_table = pd.read_csv(path, sep=\"\\t\")\n protein_table[\"peptides\"] = protein_table.peptideIds.str.split(r\"\\s\")\n ... | [
[
"pandas.read_csv",
"pandas.DataFrame.merge"
]
] |
daanknoope/pgmpy | [
"b1ad5ec01837dc1fc369dd542971492fae642ab4",
"b1ad5ec01837dc1fc369dd542971492fae642ab4"
] | [
"pgmpy/tests/test_factors/test_discrete/test_Factor.py",
"pgmpy/tests/test_readwrite/test_XMLBeliefNetwork.py"
] | [
"import unittest\nimport warnings\nfrom collections import OrderedDict\n\nimport numpy as np\nimport numpy.testing as np_test\nfrom pgmpy.extern.six.moves import range\n\nfrom pgmpy.factors.discrete import DiscreteFactor\nfrom pgmpy.factors.discrete import JointProbabilityDistribution as JPD\nfrom pgmpy.factors imp... | [
[
"numpy.array",
"numpy.asarray",
"numpy.testing.assert_almost_equal",
"numpy.sum",
"numpy.testing.assert_array_equal",
"numpy.ones",
"numpy.testing.assert_array_almost_equal",
"numpy.random.uniform",
"numpy.arange",
"numpy.prod"
],
[
"numpy.array"
]
] |
Tarekbouamer/Image-Retrieval-for-Image-Based-Localization | [
"fcad9af4f558bebb3cbec1d08e49603a452f439d",
"fcad9af4f558bebb3cbec1d08e49603a452f439d"
] | [
"cirtorch/enhance/color/hsv.py",
"scripts/test_globalF.py"
] | [
"import math\n\nimport torch\nimport torch.nn as nn\n\n\ndef rgb_to_hsv(image, eps=1e-6):\n \"\"\"\n Convert an image from RGB to HSV.\n The image data is assumed to be in the range of (0, 1).\n \"\"\"\n\n if not isinstance(image, torch.Tensor):\n raise TypeError(\"Input type is not a ... | [
[
"torch.stack",
"torch.gather",
"torch.tensor",
"torch.ones_like",
"torch.floor"
],
[
"torch.save",
"numpy.dot",
"numpy.argsort",
"torch.load"
]
] |
BIT-DA/RIPU | [
"125edf112c9ded1e7497aedb2a092331824df100"
] | [
"core/active/build.py"
] | [
"import math\nimport torch\n\nimport numpy as np\nimport torch.nn.functional as F\n\nfrom PIL import Image\nfrom tqdm import tqdm\nfrom .floating_region import FloatingRegionScore\nfrom .spatial_purity import SpatialPurity\n\n\ndef PixelSelection(cfg, feature_extractor, classifier, tgt_epoch_loader):\n feature_e... | [
[
"torch.nn.functional.one_hot",
"torch.max",
"torch.no_grad",
"torch.save",
"torch.nn.functional.interpolate",
"torch.softmax",
"torch.log",
"torch.argmax"
]
] |
balarsen/pymc_learning | [
"e4a077d492af6604a433433e64b835ce4ed0333a",
"e4a077d492af6604a433433e64b835ce4ed0333a"
] | [
"Learning/Example1.py",
"Deconvolution/convolution1.py"
] | [
"# http://www.ncbi.nlm.nih.gov/pmc/articles/PMC3097064/\nfrom pylab import *\nimport spacepy.plot as spp # for the styles\nimport numpy as np\nimport pymc as pm\n\nimport pymc\nimport numpy as np\n\nn = 5 * np.ones(4, dtype=int)\nx = np.array([-.86, -.3, -.05, .73])\n\nalpha = pymc.Normal('alpha', mu=0, tau=.01)\n... | [
[
"numpy.array",
"numpy.ones"
],
[
"numpy.array",
"numpy.zeros_like",
"numpy.zeros",
"numpy.random.seed",
"numpy.percentile",
"numpy.random.poisson",
"matplotlib.pyplot.plot",
"matplotlib.pyplot.legend",
"matplotlib.pyplot.subplots",
"matplotlib.pyplot.figure",
... |
Robyo12121/rightcall | [
"c2dd5d6b01f44a0299e19d67b148f802a86c30fa"
] | [
"lambda_functions/odigo/odigo.py"
] | [
"#!/usr/bin/env python3.7\n# -*- coding: utf-8 -*-\n\nimport os\nimport sys\nimport time\nimport datetime\nimport pandas as pd\nfrom bs4 import BeautifulSoup\nfrom requestium import Session\nfrom selenium.webdriver.common.action_chains import ActionChains\nfrom dotenv import load_dotenv\n\nfrom lxml import html\n\n... | [
[
"pandas.read_csv"
]
] |
cheind/bone-solve-ik | [
"e95ad73e438923c7e63e668b109e8a4734b62a96"
] | [
"boneik/io.py"
] | [
"import json\nimport numpy as np\nfrom pathlib import Path\n\nfrom . import kinematics\nfrom . import utils\n\n\ndef load_json(jsonpath: Path) -> kinematics.Body:\n jsonpath = Path(jsonpath)\n assert jsonpath.is_file()\n data = json.load(open(jsonpath, \"r\"))\n b = kinematics.BodyBuilder()\n\n def _... | [
[
"numpy.deg2rad",
"matplotlib.pyplot.show"
]
] |
nmningmei/melody_embedding | [
"e82b4c897b421e61a1909e5b4f44523e3cb7aa61"
] | [
"scripts/generate_README.py"
] | [
"#!/usr/bin/env python3\n# -*- coding: utf-8 -*-\n\"\"\"\nCreated on Sat Oct 12 10:40:48 2019\n\n@author: nmei\n\"\"\"\n\nimport os\nimport pandas as pd\n\nimport torch\nfrom torchvision import models\nfrom torchvision.transforms import functional as TF\nfrom torch import optim\nfrom tor... | [
[
"torch.cuda.is_available"
]
] |
sadjadasghari/3d-vehicle-tracking | [
"f8433f72a51dd1a7190570e63e9fda4a924a81f0",
"f8433f72a51dd1a7190570e63e9fda4a924a81f0",
"f8433f72a51dd1a7190570e63e9fda4a924a81f0"
] | [
"3d-tracking/lib/utils/net_utils.py",
"faster-rcnn.pytorch/lib/roi_data_layer/roidb.py",
"faster-rcnn.pytorch/lib/model/rpn/bbox_transform.py"
] | [
"import random\n\nimport cv2\nimport numpy as np\nimport torch\nimport torch.nn as nn\nimport torch.nn.functional as F\nfrom model.roi_crop.functions.roi_crop import RoICropFunction\nfrom model.utils.config import cfg\nfrom torch.autograd import Variable\n\n\ndef save_net(fname, net):\n import h5py\n h5f = h5... | [
[
"torch.cat",
"numpy.asarray",
"numpy.minimum",
"numpy.round",
"torch.save",
"torch.abs",
"torch.nn.functional.grid_sample",
"numpy.sqrt",
"torch.nn.functional.max_pool2d",
"torch.pow"
],
[
"numpy.where",
"numpy.array",
"numpy.argsort"
],
[
"torch.sta... |
rahular/joint-coref-srl | [
"cd85fb4e11af1a1ea400ed657d0a4511c1d6c6be"
] | [
"allennlp/allennlp/modules/stacked_alternating_lstm.py"
] | [
"\"\"\"\nA stacked LSTM with LSTM layers which alternate between going forwards over\nthe sequence and going backwards.\n\"\"\"\n\nfrom typing import Optional, Tuple, Union, List\nimport torch\nfrom torch.nn.utils.rnn import PackedSequence\nfrom allennlp.modules.augmented_lstm import AugmentedLstm\nfrom allennlp.co... | [
[
"torch.cat"
]
] |
tillaczel/Deep-Learning-in-Computer-Vision | [
"792e90a3ad5bafdb30e0267226c2c75b8afd01e3",
"792e90a3ad5bafdb30e0267226c2c75b8afd01e3"
] | [
"project_1_2/src/bbox.py",
"project_2/src/metrics/sensitivity.py"
] | [
"import numpy as np\nimport matplotlib.pyplot as plt\nimport matplotlib.patches as patches\nimport os\n\nimport torch\nimport wandb\nfrom torch import nn\nfrom tqdm import tqdm\n\nfrom project_1_2.src.data import get_data_raw\n\n\ndef plt_bboxes(img, bboxes, labels, filename=None):\n fig, axs = plt.subplots(1, 1... | [
[
"numpy.max",
"numpy.delete",
"numpy.array",
"torch.nn.AvgPool2d",
"matplotlib.pyplot.savefig",
"matplotlib.pyplot.subplots",
"torch.softmax",
"numpy.argmax",
"numpy.argwhere",
"matplotlib.patches.Rectangle"
],
[
"torch.zeros",
"torch.mean",
"torch.sum"
]
] |
subhankar01/Covid-Chestxray-lambda-fuzzy | [
"188d766569d768332ff0f0ee392bdf4d438e3da2"
] | [
"deep CNN features/xception_extract.py"
] | [
"import os\r\nfrom os.path import basename, join, exists\r\nimport numpy as np\r\nimport math\r\nnp.random.seed(777)\r\nimport tensorflow_addons as tfa\r\nfrom tensorflow.keras import models\r\nfrom tensorflow.keras import layers \r\nfrom tensorflow.keras import models\r\nfrom tensorflow.keras import optimizers\r\n... | [
[
"tensorflow.keras.preprocessing.image.ImageDataGenerator",
"tensorflow.keras.applications.xception.Xception",
"numpy.random.seed",
"tensorflow.keras.models.Model",
"tensorflow.keras.callbacks.ModelCheckpoint",
"numpy.save",
"tensorflow.keras.layers.Dense",
"tensorflow.keras.layers.... |
Mykko/Human-Path-Prediction | [
"956fcf16b98c81cf8e23133f9a766192e17e63e0"
] | [
"PECNet/social_eth_ucy_utils.py"
] | [
"import pickle\nimport numpy as np\nfrom IPython import embed\nimport csv\nimport torch\nfrom torch import nn\nfrom torch.utils import data\nimport os\nimport sys\nsys.path.append('../')\nfrom eth_ucy_utils import *\n\ndef get_pickle_path(set_name, set_type):\n\t_dir = os.path.dirname(__file__)\n\tif _dir:\n\t\tret... | [
[
"numpy.array",
"numpy.flip"
]
] |
juanitopereza/Granulacion | [
"07e455fee338f86bf4dc5eae068b677e87a534d0"
] | [
"aversiestofunciona.py"
] | [
"import numpy as np\nimport matplotlib.pyplot as plt\nfrom os import listdir\n#%%\ndef find_nearest(array,value):\n idx = np.argsort(np.abs(array-value))[0:2]\n return idx\n#%%\nmibisec = {}\narchivos = listdir(\"./lineas\")\n\nNAVE = np.loadtxt(\"lineas_NAVE.txt\")\n\nc = 299792458.0 # CODATA\ngrav_red = 625... | [
[
"matplotlib.pyplot.xlim",
"matplotlib.pyplot.xlabel",
"matplotlib.pyplot.plot",
"matplotlib.pyplot.figure",
"numpy.loadtxt",
"matplotlib.pyplot.scatter",
"matplotlib.pyplot.ylabel",
"numpy.abs",
"matplotlib.pyplot.show",
"matplotlib.pyplot.ticklabel_format"
]
] |
reportportal/service-auto-analyzer | [
"38508e012d0ceeb621c508ad09f16ad6b5a88602"
] | [
"service/cluster_service.py"
] | [
"\"\"\"\n* Copyright 2019 EPAM Systems\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or ag... | [
[
"sklearn.feature_extraction.text.CountVectorizer"
]
] |
dreaming-qin/python_algorithm | [
"f5277cec71aad6f62e665e171e0a96f33abd1671"
] | [
"mathematical_model_exercises/main_problem4.py"
] | [
"import pandas as pd\nimport numpy as np\nimport math\nimport sys\nimport random\n\nfrom term_influnce import format_data, get_follower, get_music_feature, get_term_MS\n\nfilename='../2021_ICM_Problem_D_Data/full_music_data.csv'\ndf = pd.read_csv(filename)\ndata = np.array(df.iloc[:,:].values)\n\n# 名称\ninflunce_nam... | [
[
"numpy.max",
"numpy.array",
"pandas.read_csv",
"numpy.sum"
]
] |
MaximProshin/nncf | [
"2290d2f4cebcf6749e419dc76850e7bd8b7d8da1",
"2290d2f4cebcf6749e419dc76850e7bd8b7d8da1",
"2290d2f4cebcf6749e419dc76850e7bd8b7d8da1",
"2290d2f4cebcf6749e419dc76850e7bd8b7d8da1"
] | [
"tests/torch/sparsity/rb/test_algo.py",
"tests/torch/test_models/inceptionv3.py",
"nncf/torch/pruning/filter_pruning/global_ranking/evolutionary_optimization.py",
"tests/torch/pruning/filter_pruning/test_set_pruning_rate.py"
] | [
"\"\"\"\n Copyright (c) 2019-2022 Intel Corporation\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 http://www.apache.org/licenses/LICENSE-2.0\n Unless required by applicable law o... | [
[
"torch.nn.Conv2d",
"torch.nn.BatchNorm2d",
"torch.ones_like"
],
[
"torch.nn.Linear",
"torch.cat",
"torch.nn.functional.avg_pool2d",
"torch.nn.init.constant_",
"torch.nn.functional.dropout",
"torch.nn.BatchNorm2d",
"torch.utils.model_zoo.load_url",
"torch.nn.function... |
raminzahedi/fsdl-text-recognizer-project | [
"b683173e5e19fbbdb3c6ab42990406e2a0c73e81"
] | [
"lab2/text_recognizer/networks/line_cnn_sliding_window.py"
] | [
"import pathlib\nfrom typing import Tuple\n\nfrom boltons.cacheutils import cachedproperty\nimport numpy as np\nimport tensorflow as tf\nfrom tensorflow.keras.layers import Activation, Conv2D, Dense, Dropout, Flatten, Input, MaxPooling2D, Permute, Reshape, TimeDistributed, Lambda, ZeroPadding2D\nfrom tensorflow.ker... | [
[
"tensorflow.keras.layers.Lambda",
"tensorflow.keras.layers.Input",
"tensorflow.keras.layers.TimeDistributed",
"tensorflow.expand_dims",
"tensorflow.keras.layers.Reshape",
"tensorflow.keras.models.Model",
"tensorflow.keras.layers.Conv2D",
"tensorflow.squeeze"
]
] |
abr-98/COVID-19_regression_analysis | [
"f902f4771f665ee27c33a9cb7e3e4c83be54493d"
] | [
"merge_states.py"
] | [
"import pandas as pd\nimport numpy as np\n\nimport os\nimport json\n\ndef merge():\n\n\tdf=pd.read_csv('covid_19_india.csv', index_col=0)\n\n\ts_names=df['State/UnionTerritory'].unique()\n\n\tdf_2=pd.read_csv('total_country_mod.csv')\n\n\tdf3=df_2\n\n\tdf3.to_csv('total_state_data.csv',index=False)\n\n\twith open('... | [
[
"pandas.read_csv"
]
] |
Louiealbp/ContrastiveLearningGoalReaching | [
"4ef3e22cb8276a8c2f4f313e2b27138b9cd361b3"
] | [
"utils.py"
] | [
"import numpy as np\nimport torch\nfrom collections import deque\nimport os\n\ndef make_dir(dir_path):\n try:\n os.mkdir(dir_path)\n except OSError:\n pass\n return dir_path\n\ndef preprocess_obs(obs, bits=5):\n \"\"\"Preprocessing image, see https://arxiv.org/abs/1807.03039.\"\"\"\n bi... | [
[
"torch.rand_like",
"numpy.zeros",
"torch.norm",
"numpy.random.randint",
"torch.as_tensor",
"torch.floor",
"torch.exp"
]
] |
xuwanwei/FedML | [
"c049a30d9839c4554e7e14b0c18275e96fea8130"
] | [
"fedml_api/distributed/fedopt/FedOptAggregator.py"
] | [
"import copy\nimport logging\nimport random\nimport time\n\nimport numpy as np\nimport torch\nimport wandb\n\nfrom .optrepo import OptRepo\nfrom .utils import transform_list_to_tensor\n\n\nclass FedOptAggregator(object):\n\n def __init__(self, train_global, test_global, all_train_data_num,\n trai... | [
[
"numpy.random.seed",
"torch.no_grad",
"torch.utils.data.Subset",
"torch.utils.data.DataLoader"
]
] |
arthursgonzaga/GoogleNewsScraping | [
"f07ba1185f24e5ccc1c090604b15a63c2ed0ce49"
] | [
"main.py"
] | [
"import pandas as pd\nfrom GoogleNews import GoogleNews\n\nSEARCHING = 'Dados'\n\ngooglenews = GoogleNews()\ngooglenews.set_lang('pt')\ngooglenews.search(SEARCHING)\nprint(\"Searching for... \" + SEARCHING)\nresults = googlenews.result()\ndf = pd.DataFrame(results)\ndf.to_csv('exported_results.csv', index=False)\np... | [
[
"pandas.DataFrame"
]
] |
genekogan/deeplab-pytorch | [
"c58f66878a1c5012c68a24eabdd15090b9becf4c"
] | [
"runway_model.py"
] | [
"from __future__ import absolute_import, division, print_function\nimport pickle\nimport numpy as np\nimport cv2\nimport torch\nimport torch.nn as nn\nimport torch.nn.functional as F\nimport yaml\nfrom addict import Dict\nfrom libs.models import *\nfrom libs.utils import DenseCRF\n\nfrom demo import *\nimport runwa... | [
[
"numpy.array",
"torch.nn.functional.interpolate",
"torch.cuda.is_available",
"numpy.argmax",
"torch.load",
"torch.nn.functional.softmax",
"numpy.dstack",
"torch.set_grad_enabled",
"numpy.unique"
]
] |
Mozen/Transorformer-tensor2tensor | [
"e29b7dded31c6e909a4bd91fd2523517a15d93b3"
] | [
"tensor2tensor/data_generators/text_encoder.py"
] | [
"# coding=utf-8\n# Copyright 2018 The Tensor2Tensor Authors.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless requir... | [
[
"numpy.full",
"tensorflow.gfile.Open",
"matplotlib.image.imread",
"tensorflow.gfile.Exists",
"tensorflow.logging.info",
"tensorflow.reshape",
"tensorflow.Session",
"tensorflow.Graph",
"tensorflow.constant",
"tensorflow.write_file",
"tensorflow.image.encode_png",
"te... |
MattFerraro/radon | [
"795b74fd7d12e7c4a191646e6bdf9e0386c8e95e"
] | [
"test.py"
] | [
"# import numpy as np\n# import matplotlib.pyplot as plt\n\n# # Number of samplepoints\n# N = 600\n# # sample spacing\n# T = 1.0 / 800.0\n# x = np.linspace(0.0, N*T, N)\n# y = np.sin(50.0 * 2.0 * np.pi * x) + 0.5 * np.sin(80.0 * 2.0 * np.pi * x)\n# # yf = numpy\n# # xf = np.linspace(0.0, 1.0/(2.0*T), N/2)\n\n# ft =... | [
[
"numpy.fft.rfft",
"numpy.sin",
"numpy.cos",
"numpy.abs",
"numpy.fft.irfft",
"numpy.linspace"
]
] |
myutman/deep-voice-conversion | [
"d707d0ea54d73d2a2df53f2f73b6d23f4afc5231"
] | [
"eval2.py"
] | [
"# -*- coding: utf-8 -*-\n# /usr/bin/python2\n\nfrom __future__ import print_function\n\nimport tensorflow as tf\nfrom models import Net2\nimport argparse\nfrom hparam import hparam as hp\nfrom tensorpack.predict.base import OfflinePredictor\nfrom tensorpack.predict.config import PredictConfig\nfrom tensorpack.tfut... | [
[
"tensorflow.summary.FileWriter",
"tensorflow.train.latest_checkpoint"
]
] |
pksvision/Video-Dehazing-Pytorch | [
"f318114d27c9b4e36c605027f351b6035fad9140"
] | [
"utils/models/vgg16.py"
] | [
"import torch\nimport torch.nn as nn\nimport torch.nn.functional as F\n\n\nclass Vgg16(torch.nn.Module):\n def __init__(self):\n super(Vgg16, self).__init__()\n self.conv1_1 = nn.Conv2d(3, 64, kernel_size=3, stride=1, padding=1)\n self.conv1_2 = nn.Conv2d(64, 64, kernel_size=3, stride=1, pad... | [
[
"torch.nn.Conv2d",
"torch.nn.functional.max_pool2d"
]
] |
supreethms1809/magma-2.2.0 | [
"b713d0b0a7a4724847e3a4050987c5ea9e7a7279"
] | [
"results/v200_cuda70_k40c.py"
] | [
"import numpy\nfrom numpy import array, nan, inf\n\nversion = '2.0.0'\ncuda = '7.0'\ndevice = 'Kepler K40c'\ncpu = '2x8 core Sandy Bridge E5-2670'\n\n# ------------------------------------------------------------\n# file: v2.0.0/cuda7.0-k40c/cgeqrf.txt\n# numactl --interleave=all ../testing/testing_cgeqrf -... | [
[
"numpy.array"
]
] |
Sushil-Thapa/rectif.ai | [
"b308f613402097dca9734806a8c27ba3eef6a358"
] | [
"rectifai/settings.py"
] | [
"import os\nimport logging\nfrom dotenv import load_dotenv\nload_dotenv(verbose=True)\n\nlogger = logging.getLogger(__name__)\n\n# The Root Directory of the project\nROOT_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))\n\nPOSENET_PATH = os.path.join(ROOT_DIR, 'data','raw','posenet.pth')\nPOSTURENE... | [
[
"torch.cuda.is_available"
]
] |
asappresearch/neural-ilm | [
"fd7e09960525391f4084a5753429deabd7ff00aa"
] | [
"ulfs/gumbel.py"
] | [
"import torch\nfrom torch.autograd import Variable\nimport torch.nn.functional as F\n\n\ndef sample_gumbel(shape, eps=1e-10):\n \"\"\"\n Sample from Gumbel(0, 1)\n based on\n https://github.com/ericjang/gumbel-softmax/blob/3c8584924603869e90ca74ac20a6a03d99a91ef9/Categorical%20VAE.ipynb ,\n (MIT lice... | [
[
"torch.rand",
"torch.autograd.Variable",
"torch.FloatTensor",
"torch.nn.functional.softmax",
"torch.log"
]
] |
nielswart/inetbfa-data-conversion | [
"bf2a28c19608babe32846036122584a1dccd34a1"
] | [
"datamanager/transforms.py"
] | [
"import pandas as pd\nimport numpy as np\nfrom functools import partial\nfrom os import path\nfrom datamanager.envs import MASTER_DATA_PATH\n\n'''\nThis module contains equity indicator and transformation functions for time series data based on pandas DataFrame's\n'''\n\ndef calc_booktomarket(close, bookvalue):\n ... | [
[
"pandas.DataFrame",
"pandas.rolling_mean",
"numpy.log",
"numpy.isnan"
]
] |
tiskw/gaussian-process-bootstrapping-layer | [
"a1c20232ba286aa3245e6aab575a9aaaf274931f"
] | [
"print_variance.py"
] | [
"#!/usr/bin/env python3\n\n\"\"\"\nTraining script for CIFAR10 classifier.\n\"\"\"\n\nimport argparse\nimport os\nimport time\n\nimport numpy\nimport sklearn.metrics\nimport torch\nimport torchvision\n\nfrom model import LeNet5, GaussianProcessBootstrapping\n\n\nclass GaussianProcessBootstrappingPrintVar(GaussianPr... | [
[
"torch.zeros",
"torch.no_grad",
"torch.linalg.lstsq",
"torch.eye",
"torch.utils.data.DataLoader",
"torch.load",
"torch.transpose",
"torch.matmul"
]
] |
exandwhy/COVID19_Streamlit | [
"db84b55943e72446dcc9e51dd5ca09f7ce771dee"
] | [
"app.py"
] | [
"import streamlit as st\nimport numpy as np\nimport pandas as pd\nimport plotly.express as px\nimport plotly.graph_objects as go\nimport matplotlib\nfrom plotly.subplots import make_subplots\nimport warnings\nwarnings.filterwarnings(action='ignore')\n\n@st.cache(allow_output_mutation=True)\ndef get_data():\n url... | [
[
"pandas.to_datetime",
"pandas.DatetimeIndex",
"pandas.DataFrame",
"numpy.log1p",
"pandas.read_json",
"pandas.read_csv"
]
] |
renatomello/qibo | [
"20c6f3f22effbeccd5d31ed456717f9bee449e0c",
"20c6f3f22effbeccd5d31ed456717f9bee449e0c"
] | [
"src/qibo/backends/matrices.py",
"src/qibo/tests/test_core_hamiltonians_from_symbols.py"
] | [
"import numpy as np\n\n\nclass Matrices:\n\n _NAMES = [\"I\", \"H\", \"X\", \"Y\", \"Z\", \"S\", \"T\", \"CNOT\", \"CZ\", \"SWAP\", \"FSWAP\", \"TOFFOLI\"]\n\n def __init__(self, backend):\n self.backend = backend\n self._I = None\n self._H = None\n self._X = None\n self._Y ... | [
[
"numpy.zeros",
"numpy.ones",
"numpy.exp",
"numpy.eye",
"numpy.sqrt"
],
[
"numpy.kron",
"numpy.eye"
]
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.