repo_name
stringlengths
6
130
hexsha
list
file_path
list
code
list
apis
list
possible_versions
list
TH4NOS/show_attend_and_tell.tensorflow
[ "4a795a0fd7755b0b3af9e3a778612bb9387c6b94" ]
[ "make_flickr_dataset.py" ]
[ "import pandas as pd\nimport numpy as np\nimport os\nimport cPickle\nfrom cnn_util import *\n\nvgg_model = '/home/taeksoo/Package/caffe/models/vgg/VGG_ILSVRC_19_layers.caffemodel'\nvgg_deploy = '/home/taeksoo/Package/caffe/models/vgg/VGG_ILSVRC_19_layers_deploy.prototxt'\n\nannotation_path = './data/results_2013012...
[ [ "pandas.read_table", "pandas.merge", "numpy.save" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.3", "1.1", "1.5", "1.2" ], "scipy": [], "tensorflow": [] } ]
NamTran838P/pspnet-keras
[ "4005fd7867036e5476bcc694fd2f548a22860d4b", "4005fd7867036e5476bcc694fd2f548a22860d4b" ]
[ "pspnet/weight_converter.py", "build/lib/pspnet/pspnet.py" ]
[ "#!/usr/bin/env python\r\n\"\"\"Convert the weights from pycaffe to an intermediary numpy weight file.\"\"\"\r\nfrom __future__ import print_function\r\n\r\nimport sys\r\nfrom os.path import splitext\r\nimport numpy as np\r\nimport caffe\r\n\r\ndef rot90(W):\r\n \"\"\"Rotate the weights for conversion to Theano....
[ [ "numpy.asarray", "numpy.rot90", "numpy.transpose" ], [ "matplotlib.pyplot.imshow", "numpy.expand_dims", "matplotlib.pyplot.axes", "numpy.max", "numpy.pad", "numpy.fliplr", "scipy.ndimage.zoom", "numpy.argmax", "tensorflow.Session", "matplotlib.pyplot.axis", ...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [ "0.13", "0.14", "0.15", "0.10", "0.16", "0.19", "0.18", "0.12", "1.0", "0.17",...
AJBrodie/inflowProject
[ "5cb5f7a7a991ffa09ed4c28ff6e44be0bd09640e" ]
[ "plot_contour.py" ]
[ "from __future__ import print_function, absolute_import, division \nimport numpy as np\nfrom scipy.interpolate import griddata\nimport matplotlib.pyplot as plt\nimport numpy.ma as ma\nfrom pyKratos import *\n\n\ndef PlotContour(Nodes, variable,name):\n nnodes = len(Nodes)\n x = []\n y = []\n z = []\n ...
[ [ "numpy.amax", "matplotlib.pyplot.contourf", "numpy.linspace", "matplotlib.pyplot.scatter", "numpy.amin", "matplotlib.pyplot.ylim", "matplotlib.pyplot.title", "matplotlib.pyplot.savefig", "matplotlib.pyplot.axes", "matplotlib.pyplot.colorbar", "matplotlib.pyplot.xlim", ...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [ "1.7", "1.0", "0.10", "1.2", "0.14", "0.19", "1.5", "0.12", "0.17", "0.13", "1.6", "1.4", "1.9", "1.3", "1.10", "0.15", "0.18", "0.16"...
kawano8811/sagemaker-deployment
[ "d9647cf4cf3015ee337b4d9275cb2de2bf3e9cd6" ]
[ "Project/serve/predict.py" ]
[ "import argparse\nimport json\nimport os\nimport pickle\nimport sys\nimport sagemaker_containers\nimport pandas as pd\nimport numpy as np\nimport torch\nimport torch.nn as nn\nimport torch.optim as optim\nimport torch.utils.data\n\nfrom model import LSTMClassifier\n\nfrom utils import review_to_words, convert_and_p...
[ [ "numpy.hstack", "torch.load", "torch.from_numpy", "numpy.round", "torch.no_grad", "torch.cuda.is_available" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
kuanih/NIPS2017-Paper-Challenge
[ "51aac9a440b0db2109e62d4428b3ee8f92907eb1" ]
[ "sgan_cifar10_pytorch.py" ]
[ "'''\nSGAN PyTroch implementation of << ... >>\n'''\n\n### IMPORTS ###\n\nimport torch\nimport torch.nn as nn\nimport torch.optim as optim\nimport numpy as np\nimport time\nimport os.path\nimport utils\n\n# initialize logger\nimport logging.config\nimport yaml\nwith open('./log_config.yaml') as file:\n Dict = ya...
[ [ "torch.nn.CrossEntropyLoss", "torch.load", "numpy.int32", "torch.nn.BCELoss", "numpy.concatenate", "torch.cuda.is_available", "numpy.random.RandomState", "torch.nn.MSELoss" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
yger/probeinterface
[ "9f01a1dea38c750793a4884182f2850670471eab", "9f01a1dea38c750793a4884182f2850670471eab" ]
[ "examples/ex_08_more_plotting_examples.py", "examples/ex_01_generate_probe_from_sratch.py" ]
[ "\"\"\"\nMore plotting examples\n----------------------\n\nHere some examples to showcase several plotting scenarios.\n\n\"\"\"\n\n##############################################################################\n# Import\n\nimport numpy as np\nimport matplotlib.pyplot as plt\n\nfrom probeinterface import Probe, Prob...
[ [ "numpy.random.rand", "matplotlib.pyplot.show", "matplotlib.pyplot.subplots", "matplotlib.pyplot.figure" ], [ "matplotlib.pyplot.show", "numpy.zeros" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
sahirsharma/Martian
[ "062e9b47849512863c16713811f347ad7e121b56", "062e9b47849512863c16713811f347ad7e121b56", "062e9b47849512863c16713811f347ad7e121b56", "062e9b47849512863c16713811f347ad7e121b56" ]
[ "NASA SPACEAPPS CHALLENGE/Solution/Software part/Astronomical Data and Python Libraries/Astropy/astropy-1.1.2/astropy/modeling/optimizers.py", "NASA SPACEAPPS CHALLENGE/Solution/Software part/Astronomical Data and Python Libraries/Astropy/astropy-1.1.2/astropy/coordinates/builtin_frames/icrs_cirs_transforms.py", ...
[ "# Licensed under a 3-clause BSD style license - see LICENSE.rst\n\n\"\"\"\nOptimization algorithms used in `~astropy.modeling.fitting`.\n\"\"\"\n\nfrom __future__ import (absolute_import, unicode_literals, division,\n print_function)\nimport warnings\nimport abc\nimport numpy as np\nfrom ..e...
[ [ "numpy.asarray", "numpy.array", "numpy.finfo" ], [ "numpy.all", "numpy.array" ], [ "numpy.random.randn", "numpy.arcsin" ], [ "numpy.all" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { ...
rajatvd/dice_rl
[ "0e9e1a0963cb99ae3d995aa302fa19094c580d35" ]
[ "dice_rl/tests/run_env_test.py" ]
[ "# Copyright 2020 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# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable law or agreed ...
[ [ "tensorflow.compat.v2.test.main" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
EricCacciavillani/LyreBird
[ "858657faef39d1adcba19ff0213210ba490b4afa" ]
[ "Failed_Code/LSTM_Muisc_generator.py" ]
[ "from music21 import converter, instrument, note, chord, midi, stream\nimport numpy as np\nimport shelve\nfrom keras.models import load_model\nimport sys\nimport string\nimport random\nimport zlib\nimport _pickle as cPickle\nimport zlib\n\nshelf = shelve.open('/home/eric/Desktop/LyreBird/Main_Production/Saved_Weigh...
[ [ "numpy.argmax", "numpy.zeros" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
bsipocz/matplotlib
[ "80cd156fa6e17c8420e0c8348e876bb19c0e9462" ]
[ "lib/matplotlib/sphinxext/plot_directive.py" ]
[ "\"\"\"\nA directive for including a matplotlib plot in a Sphinx document.\n\nBy default, in HTML output, `plot` will include a .png file with a\nlink to a high-res .png and .pdf. In LaTeX output, it will include a\n.pdf.\n\nThe source code for the plot may be included in one of three ways:\n\n 1. **A path to a s...
[ [ "matplotlib.cbook.mkdirs", "matplotlib._pylab_helpers.Gcf.get_all_fig_managers", "matplotlib.use", "matplotlib.rc_file_defaults", "matplotlib.rcParams.update", "matplotlib.pyplot.close" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
filip-halt/milvus
[ "9a25a9bde9329d3528a7951a20363af81c32ec4c" ]
[ "tests/python_client/testcases/test_collection.py" ]
[ "import numpy\nimport pandas as pd\nimport pytest\nfrom pymilvus import DataType\n\nfrom base.client_base import TestcaseBase\nfrom utils.util_log import test_log as log\nfrom common import common_func as cf\nfrom common import common_type as ct\nfrom common.common_type import CaseLabel, CheckTasks\nfrom utils.util...
[ [ "pandas.DataFrame", "pandas.date_range" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "0.23", "0.21", "2.0", "1.4", "1.3", "0.19", "1.1", "1.5", "0.24", "0.20", "1.0", "0.25", "1.2" ], "scipy": [], "tensorflow": [] } ]
jjmachan/DeepHash
[ "3689802e4005fbb23e4759bfe8ff50de688e7485" ]
[ "datasets.py" ]
[ "import numpy as np\nfrom PIL import Image\n\nfrom torch.utils.data import Dataset\nfrom torch.utils.data.sampler import BatchSampler\n\n\nclass SiameseMNIST(Dataset):\n \"\"\"\n Train: For each sample creates randomly a positive or a negative pair\n Test: Creates fixed pairs for testing\n \"\"\"\n\n ...
[ [ "numpy.random.choice", "numpy.random.shuffle", "numpy.array", "numpy.where", "numpy.random.RandomState", "numpy.random.randint" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
mzaksana/exkaldi-rt
[ "828137d9c85bb99758ddd8235913dc75ef58ce6d" ]
[ "exkaldirt/decode.py" ]
[ "# coding=utf-8\n#\n# Yu Wang (University of Yamanashi)\n# Feb, 2021\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# Unles...
[ [ "numpy.log", "numpy.exp", "numpy.zeros", "numpy.sum" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
JusteRaimbault/coco
[ "a059756daf9fdccd786c8c12992f2318f9fe3111" ]
[ "code-experiments/build/python/example_experiment.py" ]
[ "#!/usr/bin/env python\n\"\"\"Python script for the COCO experimentation module `cocoex`.\n\nUsage from a system shell::\n\n python example_experiment.py bbob\n\nruns a full but short experiment on the bbob suite. The optimization\nalgorithm used is determined by the `SOLVER` attribute in this file::\n\n pyth...
[ [ "numpy.random.rand" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
snirandjan/CISI
[ "037afc47897c8316827eb240680e95a5bc030c88" ]
[ "scripts/gridmaker.py" ]
[ "\"\"\"\nMake gridcells based on outercorners of the shape of the inputfile and specified resolution (e.g. 0.1 degrees). \nInputs: \n- df = inputfile containing shape \n- height = resolution in degrees\n \n@Author: Elco Koks & Sadhana Nirandjan - Institute for Environmental studies, VU University Amsterdam\n\"\"\"...
[ [ "numpy.ceil", "pandas.DataFrame" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "0.23", "0.21", "2.0", "1.4", "0.19", "1.1", "1.5", "1.2", "0.24", "0.20", "1.0", "0.25", "1.3" ], "scipy": [], "tensorflow": [] } ]
nielstiben/DTU-MLOP
[ "3a76d7d3f45541dd5c1d52387f9b3888470484a7" ]
[ "s3_reproduceability/final_exercise/src/models/train_model.py" ]
[ "# -*- coding: utf-8 -*-\nimport logging\nimport os\nfrom pathlib import Path\n\nimport click\nimport torch\nfrom dotenv import find_dotenv, load_dotenv\nfrom matplotlib import pyplot as plt\nfrom torch import nn, optim\nimport hydra\nfrom omegaconf import OmegaConf\n\nfrom model import MyAwesomeModel\n\n\n\n@hydra...
[ [ "torch.nn.NLLLoss", "matplotlib.pyplot.title", "numpy.random.seed", "torch.cuda.manual_seed", "torch.manual_seed", "torch.utils.data.DataLoader", "torch.stack", "matplotlib.pyplot.xlabel", "matplotlib.pyplot.show", "matplotlib.pyplot.ylabel" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
humanconnectome/PreRelease
[ "a6ce45ffb79190026255eb98f47cf06e89105b57" ]
[ "allcurated2boxRestricted.py" ]
[ "import datetime\nimport pycurl\nimport sys\nimport shutil\nfrom openpyxl import load_workbook\nimport pandas as pd\n#import download.box\nfrom io import BytesIO\n\nimport ccf\nfrom ccf.box import LifespanBox\n\n\n# This code walks through each of the external datatypes (except pedigrees), subsets to subjects/event...
[ [ "pandas.merge", "pandas.read_excel", "pandas.read_csv", "pandas.concat", "pandas.DataFrame", "pandas.read_json" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.1", "1.5", "1.2", "1.3" ], "scipy": [], "tensorflow": [] } ]
diwasblack/machine_learning
[ "83bf5af98a3db5e13f628f39d7519575c580497d" ]
[ "assignment_4/pytorch_nn.py" ]
[ "import torch\nfrom torch.autograd import Variable\n\ninput_size = 2\noutput_size = 1\n\nhidden_layer_nodes = 10\nbatch_size = 4\n\n# Create Tensors to hold the inputs and outputs and wrap them in variables.\nx = Variable(torch.FloatTensor([[0, 0], [1, 0], [0, 1], [1, 1]]))\ny = Variable(torch.FloatTensor([[0], [1]...
[ [ "torch.nn.Linear", "torch.FloatTensor", "torch.nn.MSELoss", "torch.nn.Sigmoid" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
vyasr/cudf
[ "9617fcd452a66bdeb9c2275216e866b78f997508" ]
[ "python/cudf/cudf/core/dataframe.py" ]
[ "# Copyright (c) 2018-2021, NVIDIA CORPORATION.\n\nfrom __future__ import annotations, division\n\nimport inspect\nimport itertools\nimport numbers\nimport pickle\nimport sys\nimport warnings\nfrom collections import defaultdict\nfrom collections.abc import Iterable, Sequence\nfrom typing import Any, Optional, Set,...
[ [ "pandas.Series", "pandas.io.formats.console.get_console_size", "numpy.issubdtype", "pandas.Index", "pandas.DataFrame", "pandas.api.types.is_dict_like", "pandas._config.get_option", "numpy.dtype", "numpy.result_type", "pandas.api.types.is_list_like", "pandas.io.formats.p...
[ { "matplotlib": [], "numpy": [], "pandas": [ "0.23", "0.24" ], "scipy": [], "tensorflow": [] } ]
Michelle0903/Performance-Comparison-of-Structural-Similarity-Metrics
[ "c2c409eefe335e4946ca895ad1d22b4930263819" ]
[ "Structral Similarity/stsim_1.py" ]
[ "from perceptual.metric import Metric\nimport cv2\nimport os\nimport glob\nimport heapq\nimport time\nfrom torch.utils.data import Dataset, DataLoader\n\ndata_dir = \"/Users/yuxiao/Desktop/data/Corbis128BigExperiment_gray/\"\ndata = glob.glob(data_dir + \"*.tiff\")\n\n\nclass ImgData(Dataset):\n\n def __init__(s...
[ [ "torch.utils.data.DataLoader" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
hieuhd1/django_bgRemoverML
[ "1b307d581e9638f58cd08c3a5c00c6f278d249f5" ]
[ "libs/preprocessing.py" ]
[ "import logging\nimport time\n\nimport numpy as np\nfrom PIL import Image\n\nfrom libs.strings import PREPROCESS_METHODS\n\nlogger = logging.getLogger(__name__)\n\n\ndef method_detect(method: str):\n \"\"\"Detects which method to use and returns its object\"\"\"\n if method in PREPROCESS_METHODS:\n if ...
[ [ "numpy.array", "numpy.where" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
Pandinosaurus/open_model_zoo
[ "2543996541346418919c5cddfb71e33e2cdef080" ]
[ "tools/accuracy_checker/openvino/tools/accuracy_checker/launcher/openvino_launcher.py" ]
[ "\"\"\"\nCopyright (c) 2018-2022 Intel Corporation\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law ...
[ [ "numpy.resize", "numpy.expand_dims", "numpy.concatenate", "numpy.ndim", "numpy.shape", "numpy.transpose", "numpy.array", "numpy.zeros" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
annekegh/mcdiff
[ "c85bda048be323c21d407abcc8d4ab6b1564b589" ]
[ "lib/permeability/msd.py" ]
[ "\"\"\"Script to compare different methods to extract profiles:\ncalc flux\nAG, April 9, 2013\nAG, April 25, 2013\nAG, Jan 11, 2016\nAG, Sept 14, 2016\"\"\"\n\nimport numpy as np\nimport mcdiff\nfrom mcdiff.outreading import read_F_D_edges, read_Drad\nimport matplotlib.pyplot as plt\n\n##### UNITS #####\n# F -- in ...
[ [ "numpy.dot", "scipy.special.jn_zeros", "scipy.special.jv", "numpy.arange", "matplotlib.pyplot.ylim", "numpy.linalg.inv", "matplotlib.pyplot.savefig", "scipy.linalg.expm", "matplotlib.pyplot.plot", "scipy.special.j0", "matplotlib.pyplot.ylabel", "numpy.float64", ...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
salamoslam/recommendations
[ "252a2ee85e792ed49f6c4b7a7b63e8471333a498" ]
[ "src/collaborative_filtration/nearest_neighbours.py" ]
[ "import sys\n# insert at 1, 0 is the script path (or '' in REPL)\nsys.path.insert(1, '../src/data')\n\n# from get_users_info import *\n# from get_brand_category_info import *\n# from get_preference_matrix import *\nimport implicit\nimport faiss\nfrom tqdm import tqdm\nfrom scipy.sparse import csr_matrix\nfrom scipy...
[ [ "numpy.array", "scipy.spatial.distance.cosine", "scipy.spatial.distance.euclidean" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [ "0.13", "1.6", "0.14", "1.10", "0.15", "1.4", "1.3", "1.9", "0.19", "1.5", "0.18", "1.2", "1.7", "0.12", "1.0", "0.17", "0.16", "1.8" ...
Duplums/pynet
[ "5f91dc2e80c2eb4e44d57403dd65aa80e8a5875b", "5f91dc2e80c2eb4e44d57403dd65aa80e8a5875b" ]
[ "pynet/models/multimodal_mnist_svhn.py", "pynet/models/pinayanet.py" ]
[ "import torch.nn as nn\nfrom torchvision.models import resnet18\n\nclass ColorfulMNISTEncoder(nn.Module):\n \"\"\" Encoder for representation learning on Colorful MNIST (MNIST + STL-10 background)\"\"\"\n def __init__(self, latent_dim, mode=\"base\"):\n assert mode in [\"SimCLR\", \"base\", \"classifie...
[ [ "torch.nn.Linear", "torch.nn.ReLU", "torch.nn.Conv2d", "torch.nn.Flatten" ], [ "torch.randn_like", "torch.nn.Dropout", "torch.reshape", "torch.nn.Linear", "torch.nn.SELU", "numpy.prod", "torch.flatten" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
Tasemo/ros_ai_report
[ "7fa9e4b7d6fee50451664d40e0d1efba79f7ebe4" ]
[ "scripts/ai.py" ]
[ "#!/usr/bin/env python3\n\nimport os\nimport torch\nimport torchaudio\nimport pickle\nimport rospy\nfrom ros_ai_report.model import Model\nfrom ros_ai_report.srv import CommandPrediction, CommandPredictionResponse\n\ndef predictCommand(req):\n waveform, sample_rate = torchaudio.load(req.filename)\n if (sample...
[ [ "torch.load" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
moanan/visual_kinematics
[ "1d61cba58e03432df675cd3e96f4d92dba10d2de" ]
[ "examples/forward.py" ]
[ "#!/usr/bin/env python3\n\nfrom visual_kinematics import Robot\nimport numpy as np\nfrom math import pi\n\n\ndef main():\n np.set_printoptions(precision=3, suppress=True)\n\n dh_params = np.array([[0.163, 0., 0., 0.5 * pi],\n [0., 0.5 * pi, 0.632, pi],\n [0., ...
[ [ "numpy.set_printoptions", "numpy.array" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
qbazd/leo_pass_selector
[ "9da7dfe7bb0dbdbb3e4a9447ce204d583ceda6e7" ]
[ "granule_utils.py" ]
[ "#!/usr/bin/env python \n# -*- coding: utf-8 -*-\n\nimport datetime \nimport numpy as np\nfrom pyorbital import tlefile, orbital\nfrom pyorbital.tlefile import Tle\n\n#def read_all_tles_from_file(platform, tles_file):\n#\tplatform = platform.strip().upper()\n#\ttles = []\n#\tfp = open(tles_file)\n#\tfor l0 in fp:\n...
[ [ "numpy.concatenate", "numpy.arange", "numpy.array" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
dgumenyuk/Environment_generation
[ "092fbecdc208f84aa58f2ccd3522262984e79cda" ]
[ "RQ3/Vehicle_case_study/full_model/MyTcCrossOver.py" ]
[ "import numpy as np\nfrom pymoo.model.crossover import Crossover\nfrom Solution import Solution\nimport random as rm\nfrom scipy.spatial.distance import directed_hausdorff\nimport copy\nclass MyTcCrossover(Crossover):\n def __init__(self, cross_rate):\n\n # define the crossover: number of parents and numb...
[ [ "numpy.full_like", "numpy.random.random" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
munish8448/MajorProjectEEE
[ "3999f4eb19f46c79ae4279a22303acee09da54e1" ]
[ "Test/Arduino and pythonScript/serial_plot.py" ]
[ "import serial as ser\nimport matplotlib.pyplot as myplot\nimport numpy as np\n\nport = '/dev/ttyACM0'\nbaud = 9600\n\ns = ser.Serial(port,baud)\ns.close()\ns.open()\nmyplot.close('all')\nmyplot.figure()\nmyplot.ion()\nmyplot.show()\n\ndataset = np.array([])\n\nwhile True:\n\n datainbinary = s.readline().decode(...
[ [ "matplotlib.pyplot.cla", "matplotlib.pyplot.show", "matplotlib.pyplot.plot", "numpy.append", "matplotlib.pyplot.close", "numpy.array", "matplotlib.pyplot.pause", "matplotlib.pyplot.ion", "matplotlib.pyplot.figure" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
seungjun45/updown-baseline
[ "a94248bab3e8be4555c114f7d41e15bd3df3f71a" ]
[ "updown/modules/updown_cell.py" ]
[ "from functools import lru_cache\nfrom typing import Dict, Optional, Tuple\n\nimport torch\nfrom torch import nn\nfrom allennlp.nn.util import masked_mean\n\nfrom updown.modules.attention import BottomUpTopDownAttention\n\n\nclass UpDownCell(nn.Module):\n r\"\"\"\n The basic computation unit of :class:`~updow...
[ [ "torch.nn.LSTMCell", "torch.abs", "torch.cat" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
nick-terry/Splitting-GP
[ "efd886f6442f096833460cf8cd28ff3e18da732a", "efd886f6442f096833460cf8cd28ff3e18da732a" ]
[ "dgp/dgp/hgp/DataSet.py", "dgp/dgp/hgp/PoE.py" ]
[ "import pdb\n\nimport copy\nfrom random import shuffle\n\nimport numpy as np\n\n\nclass DataSet(object):\n\n def __init__(self,X=None,y=None,superset=None,indices=None):\n\n # a DataSet object contains pairs of inputs (in X)\n # and outputs (in y). It can be a subset of another\n # DataSet o...
[ [ "numpy.hstack", "numpy.log2", "numpy.asarray", "numpy.median", "numpy.append", "numpy.argmax", "numpy.where", "numpy.vstack" ], [ "numpy.log", "numpy.asarray", "numpy.exp", "numpy.sum", "numpy.vstack" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
WeAllOneCode/PGS2
[ "9df272984eacf4e0ea87f1f80e4fdcc9ea1a7a37" ]
[ "alab/plots.py" ]
[ "#!/usr/bin/env python\n\n# Copyright (C) 2015 University of Southern California and\n# Nan Hua\n# \n# Authors: Nan Hua\n# \n# This program is free software: you can redistribute it and/or modify\n# it under the terms of the GNU General Public License as published by\n# the Free Software Fo...
[ [ "matplotlib.backends.backend_pdf.PdfPages", "matplotlib.pyplot.gca", "matplotlib.pyplot.title", "numpy.clip", "matplotlib.use", "matplotlib.colors.LinearSegmentedColormap", "matplotlib.pyplot.colorbar", "matplotlib.pyplot.setp", "matplotlib.pyplot.close", "numpy.array", ...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
anonymousneuripssubmission/ACE
[ "82b61c41de9a53a068644727b83bb4a4136da993" ]
[ "ace.py" ]
[ "\"\"\"ACE library.\n\nLibrary for discovering and testing concept activation vectors. It contains\nConceptDiscovery class that is able to discover the concepts belonging to one\nof the possible classification labels of the classification task of a network\nand calculate each concept's TCAV score..\n\"\"\"\nfrom mu...
[ [ "numpy.expand_dims", "sklearn.cluster.KMeans", "tensorflow.gfile.Exists", "sklearn.cluster.DBSCAN", "numpy.concatenate", "numpy.mean", "numpy.argmin", "numpy.where", "scipy.stats.ttest_rel", "numpy.reshape", "numpy.arange", "numpy.stack", "numpy.save", "nump...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [ "0.13", "1.6", "0.14", "1.10", "0.15", "1.4", "0.16", "1.9", "0.19", "1.5", "0.18", "1.2", "1.7", "0.12", "1.0", "0.17", "1.3", "1.8" ...
lkk688/WaymoObjectDetection
[ "c470f2648de69ec8a547269f16bb2f2868d9e05e", "c470f2648de69ec8a547269f16bb2f2868d9e05e" ]
[ "2DObject/WaymoCOCODetectron2eval.py", "WaymoDetectron2Train.py" ]
[ "from __future__ import print_function\nimport torch\nprint(torch.__version__)\nimport torchvision\nprint(torchvision.__version__)\nimport matplotlib\nmatplotlib.use('Agg')\nimport matplotlib.pyplot as plt\nimport matplotlib.patches as patches\n\nimport numpy as np\n# check if CUDA is available\ntrain_on_gpu = torc...
[ [ "matplotlib.use", "torch.cuda.is_available" ], [ "numpy.random.choice", "numpy.asarray", "matplotlib.use", "torch.cuda.is_available", "numpy.random.randint" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
ohadravid/numpy
[ "28ff24e264ec0e264c69e944a2c0aa48af9d27fa" ]
[ "numpy/core/tests/test_overrides.py" ]
[ "import inspect\nimport sys\nimport tempfile\nfrom io import StringIO\nfrom unittest import mock\n\nimport numpy as np\nfrom numpy.testing import (\n assert_, assert_equal, assert_raises, assert_raises_regex)\nfrom numpy.core.overrides import (\n _get_implementing_args, array_function_dispatch,\n verify_ma...
[ [ "numpy.testing.assert_raises_regex", "numpy.testing.assert_equal", "numpy.core.overrides.verify_matching_signatures", "numpy.fromfile", "numpy.random.random", "numpy.asarray", "numpy.compat.pickle.dumps", "numpy.arange", "numpy.core.overrides._get_implementing_args", "numpy...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
lff5985/dtaidistance
[ "df553bbd3a204ad9719e9eb6682a82d63ec80ff6" ]
[ "tests/test_clustering.py" ]
[ "import os\nimport sys\nimport math\nimport tempfile\nimport pytest\nimport logging\nfrom pathlib import Path\nimport numpy as np\nfrom dtaidistance import dtw, clustering\n\n\nlogger = logging.getLogger(\"be.kuleuven.dtai.distance\")\ndirectory = None\n\n\ndef test_clustering():\n s = np.array([\n [0., ...
[ [ "numpy.array", "numpy.zeros", "matplotlib.pyplot.subplots" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
dylanjm/raven
[ "ef1372364a2776385931763f2b28fdf2930c77b9", "7262bc3564da08dbb7bd76892b6435d9ce48256b" ]
[ "framework/SupervisedLearning/ScikitLearn/MultiClass/OutputCodeClassifier.py", "framework/Simulation.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 ...
[ [ "sklearn.svm.SVC" ], [ "numpy.set_printoptions" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
dataloop-ai/ZazuAutoML
[ "2de5b01b0b8e21aba3927b59d36c7f957fb628b9" ]
[ "dataloader/dataloader.py" ]
[ "\nfrom .compute_overlap import compute_overlap\nimport copy\nimport csv\nimport glob\nimport os\nimport random\nimport sys\n\nimport cv2\nimport numpy as np\nimport torch\nfrom PIL.Image import Image\n\n\nimport skimage\nimport skimage.color\nimport skimage.io\nimport skimage.transform\nfrom pycocotools import coc...
[ [ "pandas.read_csv", "torch.zeros", "numpy.arange", "numpy.set_printoptions", "numpy.tile", "numpy.stack", "torch.tensor", "torch.from_numpy", "numpy.logical_or", "numpy.append", "numpy.argmax", "pandas.DataFrame", "numpy.random.rand", "numpy.array", "nump...
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.3", "1.1", "1.5", "1.2" ], "scipy": [], "tensorflow": [] } ]
AntoineStevan/EA-elective-NEAT
[ "e45ae8fc84af9d99afb58434ec0747ebedef91b1", "e45ae8fc84af9d99afb58434ec0747ebedef91b1" ]
[ "hyper_viz.py", "domain/config.py" ]
[ "import os\n\nimport matplotlib.pyplot as plt\nimport numpy as np\n\ndirectory = \"runs\"\nshow = False\nBestfit = -1\nBestParams = []\niteration = 0\n\nfiles = os.listdir(directory)\nfiles.sort()\n\nfor run in files:\n iteration += 1\n file = os.path.join(directory, run)\n arr = np.load(file)\n params ...
[ [ "numpy.amax", "numpy.set_printoptions", "matplotlib.pyplot.draw", "matplotlib.pyplot.plot", "matplotlib.pyplot.clf", "numpy.load", "matplotlib.pyplot.pause" ], [ "numpy.full" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
ladt/SeeingThroughFog
[ "c714a4c3e8f8e604494b1db6e9eef529b0326405" ]
[ "tools/ProjectionTools/Radar2RGB/run_3d_illustration.py" ]
[ "from tools.DatasetViewer.lib.read import load_radar_points\nfrom tools.DatasetViewer.lib.read import load_calib_data\nfrom tools.ProjectionTools.Lidar2RGB.lib.utils import transform_coordinates, filter_below_groundplane\n# import cv2\nimport numpy as np\nimport os\nimport open3d as o3d\n\nimport matplotlib as mpl\...
[ [ "matplotlib.cm.ScalarMappable", "matplotlib.colors.Normalize" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
umd-fire-coml/MultiSeg
[ "2c12a01827480ac86d337169be58c1cf3ec03a03" ]
[ "train/davis2016.py" ]
[ "import glob\nimport numpy as np\nimport re\nimport skimage.io\n\nfrom image_seg import config, utils\nfrom os.path import join, exists\n\n###############################################################################\n# CLASS DICTIONARIES #\n###############...
[ [ "numpy.expand_dims", "numpy.random.seed", "numpy.random.shuffle", "numpy.array", "numpy.sum" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
zhoujt1994/HiCluster
[ "ee7431c33d8b565cd8b92b633e6f79b2267c1535" ]
[ "schicluster/dev/merge_cell.py" ]
[ "import time\nimport cv2\nimport argparse\nimport numpy as np\nimport pandas as pd\nfrom scipy import stats\nfrom scipy.sparse import save_npz, load_npz, csr_matrix, coo_matrix\n\nparser = argparse.ArgumentParser()\n\n\ndef merge_cell(indir,\n cell_list,\n group,\n chrom,\n...
[ [ "scipy.stats.ttest_1samp", "numpy.logical_and", "scipy.sparse.load_npz", "numpy.save", "numpy.ones", "scipy.sparse.csr_matrix", "scipy.stats.norm", "scipy.stats.wilcoxon", "numpy.zeros", "numpy.array", "scipy.sparse.save_npz", "numpy.where", "numpy.sum", "nu...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [ "1.6", "1.10", "1.4", "1.3", "1.9", "0.19", "1.5", "1.7", "1.0", "1.2", "1.8" ], "tensorflow": [] } ]
Ravineel/ML_DL_RL_Projects
[ "35d41c370b079e138fb76626bdf9af38e91175a0" ]
[ "Practice/uncertain_method.py" ]
[ "#%%\nfrom sklearn.metrics import f1_score\nfrom sklearn.metrics import confusion_matrix\nimport pandas as pd\nimport numpy as np\nfrom sklearn.model_selection import train_test_split\nfrom sklearn.naive_bayes import GaussianNB\n#%%\ndata = pd.read_csv(\"./DataSets/iris.csv\", delimiter=',')\nprint(data.head(10))\n...
[ [ "pandas.read_csv", "sklearn.naive_bayes.GaussianNB", "numpy.asarray", "sklearn.metrics.confusion_matrix", "sklearn.model_selection.train_test_split", "sklearn.metrics.f1_score" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.1", "1.5", "1.2", "1.3" ], "scipy": [], "tensorflow": [] } ]
gergelycsegzi/fcsparser
[ "1fc436461c0c5f2efdb6b78465451aa5f1b82309" ]
[ "fcsparser/api.py" ]
[ "#!/usr/bin/env python\n\"\"\"\nParser for FCS 2.0, 3.0, 3.1 files. Python 2/3 compatible.\n`\nDistributed under the MIT License.\n\nUseful documentation for dtypes in numpy\nhttp://docs.scipy.org/doc/numpy/reference/generated/numpy.ndarray.byteswap.html?highlight=byteswap#numpy.ndarray.byteswap # noqa\nhttp://doc...
[ [ "numpy.arange", "numpy.array", "numpy.zeros", "pandas.DataFrame" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "0.23", "0.21", "2.0", "1.4", "0.19", "1.1", "1.5", "1.2", "0.24", "0.20", "1.0", "0.25", "1.3" ], "scipy": [], "tensorflow": [] } ]
cmorace/pycat
[ "7abc53f90a03b4961c10003eaca2c01efec9e4d2" ]
[ "pycat/shape.py" ]
[ "from typing import List\nfrom pycat.base.graphics_batch import GraphicsBatch\n\nfrom pyglet import shapes\n\n\nfrom pycat.base.color import Color\nfrom pycat.geometry import Point\n\n\nclass Line(shapes.Line):\n\n def __init__(\n self,\n a: Point,\n b: Point,\n width: float = 1,\n ...
[ [ "numpy.array" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
cswaney/fawkes
[ "90c623476bf62b808947277840a2d5de3c95a7ce", "90c623476bf62b808947277840a2d5de3c95a7ce" ]
[ "examples/continuous/mcmc.py", "tests/continuous_simulation_test.py" ]
[ "from fawkes.models import NetworkPoisson\nimport pandas as pd\nimport h5py as h5\nimport numpy as np\nnp.seterr(divide='ignore', invalid='ignore') # TODO: how to deal with these?\nimport matplotlib.pyplot as plt\nimport time\nimport sys\n\n\"\"\"Estimates the continuous-time Network Poisson model for specified gr...
[ [ "numpy.seterr" ], [ "matplotlib.pyplot.tight_layout", "numpy.median", "numpy.max", "matplotlib.pyplot.subplot", "matplotlib.pyplot.show", "matplotlib.pyplot.hist" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
RichardOkubo/PythonScripts
[ "86090465f739a2fc3f1f8ef22977efd241f97361" ]
[ "src/pl_min.py" ]
[ "\"\"\"Programação linear com Python (Minimização).\n\nmin z = 10*x1 + 15*x2 + 25*x3\n\nsujeito a:\n\n x1 + x2 + x3 >= 1000\n x1 - 2*x2 >= 0\n x3 >= 340\n x1, x2, x3 >= 0\n\"\"\"\nimport numpy as np\nfrom scipy.optimize import linprog\n\n# Defina a matriz de restrições de desigual...
[ [ "numpy.array", "scipy.optimize.linprog" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [ "1.6", "1.10", "0.15", "1.4", "0.16", "1.9", "0.19", "1.5", "0.18", "1.2", "1.7", "1.0", "0.17", "1.3", "1.8" ], "tensorflow": [] } ]
VirkSaab/YAMLF
[ "33cf0b18cf2f9f53b491e1d28a11b1685ed4b6a9" ]
[ "yamlf/default_settings.py" ]
[ "\"\"\"\nDefault Settings file for machine learning training and testing hyperparameters\nAuthor: Jitender Singh Virk [virksaab.github.io]\nLast updated: 29 Jun 2020\n\"\"\"\n\nfrom typing import Tuple\nfrom easydict import EasyDict as edict\nfrom torch.utils.tensorboard import SummaryWriter\nimport torch, datetime...
[ [ "torch.device", "torch.utils.tensorboard.SummaryWriter", "torch.cuda.is_available" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
olinguyen/kaggle-lung-cancer-detection
[ "a1c15743a567d4a55ecc318957d166948602f699" ]
[ "unet.py" ]
[ "from __future__ import division\nfrom __future__ import print_function\n\nimport numpy as np\nfrom keras.models import Model, load_model\nfrom keras.layers import Input, merge, Convolution2D, MaxPooling2D, UpSampling2D\nfrom keras.optimizers import Adam\nfrom keras import backend as K\n\n\nluna = 'databowl/luna/'\...
[ [ "numpy.round", "numpy.std", "numpy.mean", "numpy.load", "numpy.zeros", "numpy.sum" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
leejjoon/Matplotlib--JJ-s-dev
[ "0b47697b19b77226c633ec6a3d74a2199a153315" ]
[ "examples/pylab_examples/line_styles.py" ]
[ "#!/usr/bin/env python\n# This should probably be replaced with a demo that shows all\n# line and marker types in a single panel, with labels.\n\nimport matplotlib.pyplot as plt\nfrom matplotlib.lines import Line2D\nimport numpy as np\n\nt = np.arange(0.0, 1.0, 0.1)\ns = np.sin(2*np.pi*t)\nlinestyles = ['_', '-', '...
[ [ "numpy.arange", "numpy.sin", "matplotlib.pyplot.plot", "matplotlib.pyplot.subplot", "matplotlib.pyplot.show" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
washizzle/facenet_pytorch
[ "50106fe55c08b523d23ef0d5908308bb399523d9" ]
[ "models.py" ]
[ "import numpy as np\nimport torch\nimport torch.nn as nn\nfrom torchvision.models import resnet34\n\n\nclass FaceNetModel(nn.Module):\n def __init__(self, embedding_size, num_classes, pretrained=False):\n super (FaceNetModel, self).__init__()\n \n self.model = resnet34(pretrained)...
[ [ "torch.sqrt", "torch.sum", "torch.nn.Linear", "torch.nn.Upsample", "torch.pow" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
xingjianleng/cogent3
[ "a85d08a948f6903e4e04eea8292f588cc0b4907e" ]
[ "tests/test_core/test_seq_aln_integration.py" ]
[ "#!/usr/bin/env python\n\n\nfrom unittest import TestCase, main\n\nfrom numpy import alltrue, array, transpose\n\nfrom cogent3.core.alignment import Alignment, ArrayAlignment\nfrom cogent3.core.moltype import RNA\nfrom cogent3.core.sequence import ArraySequence, RnaSequence\n\n\n__author__ = \"Sandra Smit\"\n__copy...
[ [ "numpy.testing.assert_equal", "numpy.array", "numpy.transpose" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
rosrad/lhotse
[ "177ce3a6b963d4ac56a87843a0130ccfc74b3a57", "177ce3a6b963d4ac56a87843a0130ccfc74b3a57" ]
[ "lhotse/audio.py", "test/features/test_opensmile.py" ]
[ "import logging\nimport random\nimport re\nimport warnings\nfrom concurrent.futures import ProcessPoolExecutor\nfrom contextlib import contextmanager\nfrom dataclasses import dataclass\nfrom decimal import ROUND_HALF_UP\nfrom functools import lru_cache, partial\nfrom io import BytesIO\nfrom itertools import islice\...
[ [ "numpy.empty", "numpy.concatenate", "numpy.frombuffer", "numpy.append", "numpy.delete", "numpy.round", "numpy.average", "numpy.zeros", "numpy.sum", "numpy.vstack" ], [ "numpy.shape", "numpy.random.rand" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
mireianievas/cta-lstchain
[ "71d26b186e2ac4c5837f1c3d66dcc849b4bf2e3f" ]
[ "lstchain/reco/r0_to_dl1.py" ]
[ "\"\"\"This is a module for extracting data from simtelarray and observed\nfiles and calculate image parameters of the events: Hillas parameters,\ntiming parameters. They can be stored in HDF5 file. The option of saving the\nfull camera image is also available.\n\n\"\"\"\nimport logging\nimport os\nfrom copy import...
[ [ "pandas.read_hdf", "numpy.arctan", "numpy.asarray", "numpy.cumsum", "numpy.log10", "numpy.argmax", "numpy.bincount", "numpy.count_nonzero", "scipy.interpolate.interp1d", "numpy.array", "numpy.sum", "numpy.loadtxt" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "0.23", "0.21", "2.0", "1.4", "0.19", "1.1", "1.5", "1.2", "0.24", "0.20", "1.0", "0.25", "1.3" ], "scipy": [ "0.13", "1.6", "0.14", "1.10", "0...
zhao-clive/ijcai-18
[ "1b7359ca7ef5b74b814f92cc1dda24d50648a1de" ]
[ "step2_features.py" ]
[ "\"\"\"\n instance_id,\n\n item_id,item_category_list,item_property_list,item_brand_id,item_city_id,\n item_price_level,item_sales_level,item_collected_level,item_pv_level,\n\n user_id,user_gender_id,user_age_level,user_occupation_id,user_star_level,\n\n context_id,context_timestamp,context_page_id,p...
[ [ "pandas.merge", "pandas.read_csv" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.3", "1.1", "1.5", "1.2" ], "scipy": [], "tensorflow": [] } ]
esilgard/BreastMR
[ "1feb39064fd8d485e856927abe6da8716c30547e" ]
[ "fhcrc_pathology/Nottingham.py" ]
[ "'''author@esilgard'''\n#\n# Copyright (c) 2013-2016 Fred Hutchinson Cancer Research Center\n#\n# Licensed under the Apache License, Version 2.0: http://www.apache.org/licenses/LICENSE-2.0\n#\n\nfrom .OneFieldPerReportML import OneFieldPerReportML\nfrom . import global_strings as gb\nfrom sklearn.externals import j...
[ [ "sklearn.externals.joblib.load" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
derikk/ExoRad2-public
[ "034406bfd8237670f0796f9c95ab2fa5d609bc95" ]
[ "tests/test_plotter.py" ]
[ "import logging\nimport os\nimport pathlib\nimport unittest\n\nimport matplotlib.pyplot as plt\n\nfrom exorad import tasks\nfrom exorad.log import setLogLevel, disableLogging, enableLogging\nfrom exorad.utils.plotter import Plotter\n\npath = pathlib.Path(__file__).parent.absolute()\ndata_dir = os.path.join(path.par...
[ [ "matplotlib.pyplot.show" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
tanselsimsek/Support-Vector-Machines
[ "eb2f951c9a574fedf7e508ab257c78a521e9a3f8" ]
[ "Q_3/run_3_ATS.py" ]
[ "import sys\nimport numpy as np\nsys.path.append('./')\nfrom sklearn.metrics import confusion_matrix\nfrom SVM_MVP_Q3 import SVM_MVP,Preprocessing_Pipeline\n\ndef run_SVM_Q3():\n pipeline = Preprocessing_Pipeline()\n data,labels = pipeline.load_dataset(\"Letters_Q_O.csv\")\n data_scl = pipeline.normal_scal...
[ [ "sklearn.metrics.confusion_matrix" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
disiji/pycalib
[ "e22ed16bf6cc09161904ee014f92cc52f17d7dbc", "e22ed16bf6cc09161904ee014f92cc52f17d7dbc" ]
[ "benchmark/MNIST.py", "figures/active_learning/active_learning_calibration.py" ]
[ "import os.path\nimport numpy as np\nimport gpflow\nimport xgboost as xgb\n\n# Install latest version of scikit-garden from github to enable partial_fit(X, y):\n# (https://github.com/scikit-garden/scikit-garden)\nfrom skgarden import MondrianForestClassifier\nfrom sklearn.ensemble import RandomForestClassifier\nfro...
[ [ "sklearn.neural_network.MLPClassifier", "sklearn.ensemble.AdaBoostClassifier", "sklearn.ensemble.RandomForestClassifier" ], [ "numpy.hstack" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
ForeverZyh/MalwareBackdoors
[ "42642b2ea534843d76fad7d64f13079df3e21203" ]
[ "backdoor_attack.py" ]
[ "\"\"\"\nCopyright (c) 2021, FireEye, Inc.\nCopyright (c) 2021 Giorgio Severi\n\nThis script runs a batch of attack experiments with the provided configuration\noptions.\n\nAttack scripts generally require a configuration file with the following fields:\n\n{\n \"model\": \"string -- name of the model to target\",\...
[ [ "sklearn.model_selection.train_test_split", "numpy.random.seed", "tensorflow.random.set_seed" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
axa-rev-research/quackie
[ "8f63fedb382b3ac9d705be691cc7510a512a8659" ]
[ "accuracy.py" ]
[ "import pandas as pd\nfrom sklearn.metrics import accuracy_score, recall_score\n\nimport models\nimport qa_experimenters\nfrom interpreters import baseline_interpreter\n\n# disable info logging for datasets\nqa_experimenters.datasets.logging.set_verbosity_error()\n\n# load models\nmodel_classif = models.Model_Class...
[ [ "sklearn.metrics.recall_score", "pandas.DataFrame", "sklearn.metrics.accuracy_score" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "0.23", "0.21", "2.0", "1.4", "0.19", "1.1", "1.5", "1.2", "0.24", "0.20", "1.0", "0.25", "1.3" ], "scipy": [], "tensorflow": [] } ]
deb-intel/lp-opt-tool
[ "881bde402db387b04c2f33cc96fb817f47c4d623", "881bde402db387b04c2f33cc96fb817f47c4d623", "881bde402db387b04c2f33cc96fb817f47c4d623" ]
[ "test/test_exhaustive.py", "lpot/data/datasets/dummy_dataset.py", "lpot/adaptor/tf_utils/transform_graph/fold_old_batchnorm.py" ]
[ "\"\"\"Tests for quantization\"\"\"\r\nimport numpy as np\r\nimport unittest\r\nimport os\r\nimport yaml\r\nimport tensorflow as tf\r\nimport importlib\r\n\r\ndef build_fake_yaml():\r\n fake_yaml = '''\r\n model:\r\n name: fake_yaml\r\n framework: tensorflow\r\n inputs: x\r\n ...
[ [ "tensorflow.Graph", "tensorflow.graph_util.convert_variables_to_constants", "tensorflow.import_graph_def", "numpy.random.random", "tensorflow.compat.v1.graph_util.convert_variables_to_constants", "tensorflow.placeholder", "tensorflow.compat.v1.global_variables_initializer", "tensor...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "1.10" ] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflo...
tue-mps/damiirl
[ "01126a2dbc5132cecc11a049804b253061d0c05b" ]
[ "main.py" ]
[ "import numpy as np\nimport numpy.random as random\nimport torch\nimport os\n\nfrom objectworld import ObjectWorld\nfrom binaryworld import BinaryWorld\nfrom sem import SEM\nfrom mcem import MCEM\nfrom mdp import MDP\nfrom drawing import Drawing\ntorch.manual_seed(0)\n\nmiirl_type = 'SEM' # either 'SEM' or 'MCEM', ...
[ [ "torch.manual_seed", "torch.save" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
smmmmi/E2SRI
[ "dfd7ca23c9cf5fac83f7a86e6b1609e926a8e6ff" ]
[ "src/models/PerceptualSimilarity/util.py" ]
[ "import torch\nimport numpy as np\nfrom skimage.metrics import structural_similarity\n\n\ndef normalize_tensor(in_feat, eps=1e-10):\n norm_factor = torch.sqrt(torch.sum(in_feat ** 2, dim=1, keepdim=True))\n return in_feat / (norm_factor + eps)\n\n\ndef l2(p0, p1, range=255.):\n return .5 * np.mean((p0 / ra...
[ [ "numpy.maximum", "numpy.arange", "torch.sum", "numpy.concatenate", "numpy.max", "numpy.mean", "numpy.prod", "numpy.transpose", "numpy.where", "numpy.sum", "numpy.isclose" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
mostafamahdieh/DefectPredictionTCP
[ "372db59e77c2d0ea3918dedd186c6ff213c06911" ]
[ "bugprediction/evaluate_bugprediction.py" ]
[ "import numpy as np\r\nimport pandas as pd\r\nimport h5py\r\n\r\ndef findRowIndex(data, value):\r\n\tfor i in range(0, data.shape[0]):\r\n\t\tprint(str(data[i]),\"<>\",value)\r\n\t\tif (str(data[i]) == value):\r\n\t\t\treturn i\r\n\treturn -1\r\n\r\ndef runBugpredictionEvaluation(project, versionNumber):\r\n\tdataP...
[ [ "pandas.read_csv" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.1", "1.5", "1.2", "1.3" ], "scipy": [], "tensorflow": [] } ]
ZettaAI/cloud-volume
[ "ed42399e7b7152072b1448b5b4dc1e910305643c" ]
[ "cloudvolume/skeleton.py" ]
[ "from collections import defaultdict\nimport copy\nimport datetime\nfrom io import BytesIO\nimport re\nimport os\nimport networkx as nx\n\nimport fastremap\nimport numpy as np\nimport struct\n\nfrom . import lib\nfrom .exceptions import (\n SkeletonDecodeError, SkeletonEncodeError, \n SkeletonUnassignedEdgeError,...
[ [ "numpy.diag", "numpy.sqrt", "numpy.dtype", "numpy.all", "numpy.concatenate", "numpy.max", "matplotlib.cm.rainbow", "numpy.where", "numpy.unique", "numpy.arange", "numpy.lexsort", "numpy.frombuffer", "numpy.copy", "numpy.zeros", "numpy.isin", "matplot...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
shomikverma/pvtrace
[ "3ae04b31bc044cbc15b910ba678ab6d80b226cb4" ]
[ "pvtrace/scene/renderer.py" ]
[ "import numpy as np\nimport os\nimport time\nimport io\nfrom typing import Tuple\nfrom contextlib import contextmanager\nfrom collections import deque\nfrom anytree import LevelOrderIter, PostOrderIter\nfrom pvtrace.geometry.sphere import Sphere\nfrom pvtrace.geometry.cylinder import Cylinder\nfrom pvtrace.geometry...
[ [ "numpy.copy", "numpy.array", "numpy.column_stack" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
XinyuJing/DI-star
[ "b573a5462e3d0ab72298c767eb945742e36fa6d8", "b573a5462e3d0ab72298c767eb945742e36fa6d8", "b573a5462e3d0ab72298c767eb945742e36fa6d8" ]
[ "ctools/worker/actor/zergling_actor.py", "ctools/torch_utils/optimizer_util.py", "distar/data/collate_fn.py" ]
[ "import copy\nimport queue\nimport time\nimport uuid\nfrom collections import namedtuple\nfrom threading import Thread\nfrom typing import List, Dict, Callable, Any, Tuple\nfrom easydict import EasyDict\nfrom collections import deque\n\nimport torch\n\nfrom ctools.data import default_collate, default_decollate\nfro...
[ [ "torch.zeros" ], [ "torch.nn.utils.clip_grad_norm_", "torch.zeros_like", "torch.nn.utils.clip_grad_value_" ], [ "torch.BoolTensor", "torch.LongTensor", "torch.cat", "torch.nn.utils.rnn.pad_sequence", "torch.utils.data.get_worker_info", "torch.utils.data._utils.colla...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
HRS-Navigation/MITK-Diffusion
[ "b1bf62d1c76f0d0cc26dd252561cb5d8769b4f87" ]
[ "Plugins/org.mitk.gui.qt.diffusionimaging.python/resources/dipy_reconstructions.py" ]
[ "import sys\n\ndef get_mitk_sphere():\n \"\"\" Return MITK compliant dipy Sphere object.\n MITK stores ODFs as 252 values spherically sampled from the continuous ODF.\n The sampling directions are generate by a 5-fold subdivisions of an icosahedron.\n \"\"\"\n xyz = np.array([\n 0.975676754955...
[ [ "numpy.max", "numpy.array", "numpy.linalg.norm", "numpy.nan_to_num" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
OnurUner/DeepSide
[ "dffb7ddc1d1bde36bbf5abb6eac107d39985c57a", "dffb7ddc1d1bde36bbf5abb6eac107d39985c57a" ]
[ "src/models/subnet.py", "src/loss/diceloss.py" ]
[ "import torch\nimport torch.nn as nn\n\n\ndef _make_block(D_in, D_out, p_dropout=0.5):\n\tlinear = nn.Linear(D_in, D_out)\n\ttorch.nn.init.xavier_normal_(linear.weight)\n\tnorm = nn.BatchNorm1d(D_out)\n\tactivation = nn.ReLU(inplace=True)\n\tdropout = nn.Dropout(p=p_dropout) # 0.4 for mm models # 0.3 perfect for ml...
[ [ "torch.nn.BatchNorm1d", "torch.nn.Dropout", "torch.nn.Sequential", "torch.nn.init.xavier_normal_", "torch.nn.Linear", "torch.nn.ReLU" ], [ "torch.sigmoid" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
LoLab-VU/Gleipnir
[ "6085435f4840d403c0878b0d50192565ccc82965", "6085435f4840d403c0878b0d50192565ccc82965" ]
[ "examples/gaussians/NS_gaussians_dnest4.py", "examples/eggcarton/NS_eggcarton_multinest.py" ]
[ "\"\"\"\nImplementation of a 5-dimensional Gaussian problem and its Nested Sampling\nusing DNest4 via Gleipnir.\n\nAdapted from the DNest4 python gaussian example:\nhttps://github.com/eggplantbren/DNest4/blob/master/python/examples/gaussian/gaussian.py\n\"\"\"\n\nimport numpy as np\nfrom scipy.stats import uniform\...
[ [ "numpy.log", "numpy.sqrt", "scipy.stats.uniform", "matplotlib.pyplot.show", "numpy.sum" ], [ "matplotlib.pyplot.show", "scipy.stats.uniform", "numpy.cos" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
daverblair/QRankGWAS
[ "4c326eca9151af7fba981f201cc6a554e72e93db" ]
[ "QRankGWAS/QRankGWAS.py" ]
[ "import os\nimport io\nimport argparse\nimport time\nimport copy\nimport numpy as np\nimport pandas as pd\nimport statsmodels.api as sm\nfrom scipy.stats import chi2\nfrom sklearn.utils import shuffle\nfrom bgen.reader import BgenFile\n\n\n__version__ = \"0.0.9\"\n\n\nclass QRank:\n\n def _computeNullRanks(self,...
[ [ "numpy.diag", "numpy.dot", "pandas.concat", "pandas.read_csv", "pandas.Series", "scipy.stats.chi2", "numpy.arange", "numpy.sort", "pandas.DataFrame", "numpy.linalg.lstsq", "numpy.identity", "numpy.linalg.cholesky", "numpy.argsort", "numpy.array", "numpy....
[ { "matplotlib": [], "numpy": [], "pandas": [ "2.0", "1.4", "1.3", "1.1", "1.5", "1.2" ], "scipy": [], "tensorflow": [] } ]
grundrauschen/center-points
[ "0fa523314a3168d4d229b6f61d0d05d314a8b35a", "0fa523314a3168d4d229b6f61d0d05d314a8b35a", "5a12f68ac012a0a2bf52d8a8381d0272e309ac18" ]
[ "centerpoints/iterated_radon.py", "tests/lib_test.py", "centerpoints/iterated_tverberg.py" ]
[ "from math import log, ceil\n\nimport numpy as np\nfrom .interfaces import CenterpointAlgo\nfrom .helpers import chunks\nfrom .lib import radon_point, sample_with_replacement, radon_partition\n\n\nclass IteratedRadon(CenterpointAlgo):\n def __init__(self, use_tree=False):\n self._use_tree = use_tree\n\n ...
[ [ "numpy.asarray" ], [ "numpy.dot", "numpy.eye", "numpy.concatenate", "numpy.asmatrix", "numpy.zeros_like", "numpy.testing.assert_allclose", "numpy.array", "numpy.zeros", "numpy.sum" ], [ "numpy.hstack", "numpy.asarray", "numpy.arange", "numpy.ceil", ...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
vghost2008/semantic-segmentation
[ "f1f6a94e77e92bcfdd57c38aa9802797f0a7534e" ]
[ "network/batch_norm.py" ]
[ "# Copyright (c) Facebook, Inc. and its affiliates.\nimport logging\nimport torch\nimport torch.distributed as dist\nfrom torch import nn\nfrom torch.nn import functional as F\n\nclass FrozenBatchNorm2d(nn.Module):\n \"\"\"\n BatchNorm2d where the batch statistics and the affine parameters are fixed.\n\n I...
[ [ "torch.nn.functional.batch_norm", "torch.ones", "torch.zeros", "torch.zeros_like", "torch.ones_like" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
Karthikeya108/sdc-pipeline-project
[ "7d41ad27a661cf44179b01b54095e15a657a3273" ]
[ "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" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [ "1.7", "1.0", "0.10", "1.2", "0.14", "0.19", "1.5", "0.12", "0.17", "0.13", "1.6", "1.4", "1.9", "1.3", "1.10", "0.15", "0.18", "0.16"...
ejeschke/glue
[ "21689e3474aeaeb70e258d76c60755596856976c" ]
[ "glue/plugins/tools/spectrum_tool/qt/spectrum_tool.py" ]
[ "from __future__ import absolute_import, division, print_function\n\nimport os\nimport logging\nimport platform\nimport traceback\n\nimport numpy as np\n\nfrom qtpy import QtCore, QtGui, QtWidgets, compat\nfrom qtpy.QtCore import Qt\n\nfrom glue.external.six.moves import range as xrange\nfrom glue.core.exceptions i...
[ [ "numpy.nanmax", "numpy.isfinite", "numpy.clip", "numpy.nanmin", "numpy.nansum", "numpy.nanmean", "numpy.searchsorted", "numpy.where", "numpy.empty" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
twiecki/aesara
[ "104dc0379c3585a0bc8ebb87f61f2ae38d101b83", "104dc0379c3585a0bc8ebb87f61f2ae38d101b83", "104dc0379c3585a0bc8ebb87f61f2ae38d101b83" ]
[ "aesara/gradient.py", "tests/link/c/test_type.py", "tests/sparse/test_opt.py" ]
[ "\"\"\"Driver for gradient calculations.\"\"\"\n\nimport logging\nimport time\nimport warnings\nfrom collections import OrderedDict\nfrom functools import partial, reduce\nfrom typing import TYPE_CHECKING, Callable, List, Optional, Union\n\nimport numpy as np\n\nimport aesara\nfrom aesara.compile.ops import ViewOp\...
[ [ "numpy.minimum", "numpy.isfinite", "numpy.asarray", "numpy.ndarray", "numpy.dtype", "numpy.all", "numpy.argmax", "numpy.array" ], [ "numpy.random.standard_normal", "numpy.float64" ], [ "numpy.int32", "numpy.random.random" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
xden2331/a-PyTorch-Tutorial-to-Image-Captioning
[ "4daddf2f4e19ebf61086bf12f733d8bf6045edb6" ]
[ "resnet.py" ]
[ "# Original code: https://github.com/pytorch/vision/blob/master/torchvision/models/resnet.py\n\nimport torch.nn as nn\nimport math\n\ndef conv3x3(in_planes, out_planes, stride=1):\n \"3x3 convolution with padding\"\n return nn.Conv2d(in_planes, out_planes, kernel_size=3, stride=stride,\n p...
[ [ "torch.nn.Sequential", "torch.nn.Conv2d", "torch.nn.Linear", "torch.nn.AvgPool2d", "torch.nn.MaxPool2d", "torch.nn.AdaptiveAvgPool2d", "torch.nn.BatchNorm2d", "torch.nn.ReLU" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
robbi621/coba
[ "634f4bbd22f9702c38f9322d0425704b469f2227" ]
[ "convolutional_neural_network.py" ]
[ "# -*- coding: utf-8 -*-\n\"\"\"convolutional_neural_network.ipynb\n\nAutomatically generated by Colaboratory.\n\nOriginal file is located at\n https://colab.research.google.com/github/robbi621/pembelajaran-mesin/blob/main/neural_network/convolutional_neural_network.ipynb\n\"\"\"\n\nfrom google.colab import driv...
[ [ "matplotlib.pyplot.legend", "matplotlib.pyplot.title", "tensorflow.keras.layers.Dense", "numpy.arange", "tensorflow.keras.layers.Conv2D", "tensorflow.keras.layers.InputLayer", "tensorflow.keras.layers.MaxPool2D", "sklearn.metrics.classification_report", "matplotlib.pyplot.ylabe...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [ "2.7", "2.6", "2.4", "2.3", "2.5", "2.2" ] } ]
gf0507033/kornia
[ "2624f40a62d3639e6d946f3ca41fd1ce4b9de82d" ]
[ "test/geometry/test_conversions.py" ]
[ "from typing import Optional\n\nimport pytest\nimport numpy as np\n\nimport kornia\nfrom kornia.testing import tensor_to_gradcheck_var, create_eye_batch\n\nimport torch\nfrom torch.autograd import gradcheck\nfrom torch.testing import assert_allclose\n\n\n# based on:\n# https://github.com/ceres-solver/ceres-solver/b...
[ [ "torch.jit.script", "torch.testing.assert_allclose", "numpy.sqrt", "torch.zeros", "torch.sin", "torch.set_printoptions", "torch.eye", "numpy.cos", "torch.tensor", "numpy.sin", "torch.rand", "torch.autograd.gradcheck", "torch.cos" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
refraction-ray/tensorcircuit
[ "666154f4dbdb25164c0e778a96ee56ac22323a6c" ]
[ "tests/test_gates.py" ]
[ "import sys\nimport os\nimport numpy as np\n\nthisfile = os.path.abspath(__file__)\nmodulepath = os.path.dirname(os.path.dirname(thisfile))\n\nsys.path.insert(0, modulepath)\nimport tensorcircuit as tc\n\n\ndef test_rgate(highp):\n # tc.set_dtype(\"complex128\")\n np.testing.assert_almost_equal(\n tc.g...
[ [ "numpy.eye", "numpy.array" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
katherinelatimer2013/pymatgen
[ "b57a502576d3f471e75fcec259dfb2a7daa285ed" ]
[ "pymatgen/core/structure.py" ]
[ "# coding: utf-8\n# Copyright (c) Pymatgen Development Team.\n# Distributed under the terms of the MIT License.\n\nfrom __future__ import division, unicode_literals\n\nimport math\nimport os\nimport json\nimport collections\nimport itertools\nfrom abc import ABCMeta, abstractmethod\nimport random\nimport warnings\n...
[ [ "numpy.matrix", "numpy.dot", "numpy.round", "numpy.all", "numpy.max", "numpy.zeros_like", "numpy.fill_diagonal", "numpy.any", "numpy.cross", "numpy.random.randn", "scipy.spatial.distance.squareform", "numpy.where", "numpy.divide", "numpy.unique", "numpy....
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [ "0.13", "1.6", "0.14", "1.10", "0.15", "1.4", "0.16", "1.9", "0.19", "1.5", "0.18", "1.2", "1.7", "0.12", "1.0", "0.17", "1.3", "1.8" ...
Atashnezhad/ROP-Modeling
[ "3edbad0f570f1df67b819b946a50a6e05baaf25f" ]
[ "Atashnezhad et al PDC ROP model/Interaction_Viz.py" ]
[ "#!/usr/bin/env python\n# coding: utf-8\n\n# In[ ]:\n\n\nimport numpy as np\nimport pandas as pd\nimport math\nimport matplotlib.pylab as plt\nfrom scipy.optimize import curve_fit\nimport seaborn as sns\nimport itertools\nfrom math import pi\nfrom matplotlib.legend_handler import HandlerPatch\nfrom scipy.optimize i...
[ [ "matplotlib.pylab.show", "numpy.abs", "numpy.linspace", "numpy.asarray", "matplotlib.pylab.Line2D", "numpy.cos", "pandas.DataFrame", "numpy.sin", "matplotlib.pylab.figure", "matplotlib.pylab.Circle" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "0.23", "0.21", "2.0", "1.4", "0.19", "1.1", "1.5", "1.2", "0.24", "0.20", "1.0", "0.25", "1.3" ], "scipy": [], "tensorflow": [] } ]
Wassouli/DVGI
[ "6310007009d2bfe150f1e4b29c7588f720c4bba2" ]
[ "tools/propagation_inpaint.py" ]
[ "import sys, argparse, os, time\nsys.path.append(os.path.abspath(os.path.join(__file__, '..', '..')))\n\nimport torch\nimport cv2\nimport numpy as np\nfrom mmcv import ProgressBar\nfrom utils import flow as flo\n\nfrom tools.frame_inpaint import DeepFillv1\n\n\ndef parse_args():\n parser = argparse.ArgumentParse...
[ [ "numpy.ones", "torch.no_grad", "numpy.zeros_like", "numpy.zeros", "numpy.sum" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
salahali2019/lung-segmentation-2d
[ "4a65b2450bbf2cf4cbe8a415de6d339224d6dc95" ]
[ "predict_image_extract.py" ]
[ "from load_data import loadDataJSRT, loadDataMontgomery,loadTestingData\n\nimport numpy as np\nimport pandas as pd\nfrom keras.models import load_model\nfrom keras.preprocessing.image import ImageDataGenerator\nfrom skimage import morphology, color, io, exposure\nimport matplotlib.pyplot as plt\nfrom skimage.transf...
[ [ "numpy.expand_dims", "tensorflow.concat", "scipy.ndimage.morphology.binary_fill_holes", "tensorflow.image.resize_images", "numpy.dstack", "numpy.logical_or", "numpy.prod", "numpy.array", "numpy.logical_and", "numpy.zeros", "numpy.sum" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [ "0.13", "1.6", "0.14", "0.15", "1.4", "0.16", "1.0", "0.19", "1.5", "0.18", "1.2", "1.7", "0.12", "0.10", "0.17", "1.3" ], "tensorflow": [...
ifsheldon/billiard_game
[ "1ce13d39158734efd76e617bba2bb319d5498c3f" ]
[ "pyverilog/test_sqr_sum.py" ]
[ "import os\n\nimport numpy as np\nimport pyverilator\n\nfrom . import to_fix_point_int, to_float\n\n\ndef test_sqr_sum():\n os.chdir(\"./pyverilog\")\n sim = pyverilator.PyVerilator.build(\"sqr_sum.v\")\n # speed limit in WC is 1.0\n v = np.random.randn(3)\n v /= np.sqrt((v ** 2).sum()) + np.random.r...
[ [ "numpy.random.randn", "numpy.random.rand" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
dvirassulin/IML.HUJI
[ "52ac69455ba185c15ac491edd1d148edf3383506" ]
[ "IMLearn/metalearners/adaboost.py" ]
[ "import numpy as np\nfrom ..base import BaseEstimator\nfrom typing import Callable, NoReturn\nfrom ..metrics.loss_functions import misclassification_error\n\n\nclass AdaBoost(BaseEstimator):\n \"\"\"\n AdaBoost class for boosting a specified weak learner\n\n Attributes\n ----------\n self.wl_: Callab...
[ [ "numpy.log", "numpy.abs", "numpy.sign", "numpy.exp", "numpy.zeros", "numpy.sum" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
mshukor/DSACfD
[ "65e4e73257d2295e7df2044332d8c75aa7b51e5d", "65e4e73257d2295e7df2044332d8c75aa7b51e5d" ]
[ "rl_algorithms/ddpg/learner.py", "rl_algorithms/common/abstract/her.py" ]
[ "import argparse\nfrom collections import OrderedDict\nfrom typing import Tuple\n\nimport torch\nimport torch.nn as nn\nimport torch.nn.functional as F\nfrom torch.nn.utils import clip_grad_norm_\nimport torch.optim as optim\n\nfrom rl_algorithms.common.abstract.learner import Learner\nimport rl_algorithms.common.h...
[ [ "torch.nn.functional.mse_loss", "torch.cat", "torch.load" ], [ "numpy.concatenate", "numpy.array", "numpy.array_equal" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
dnaneet/numcode
[ "7ec9345f65367a2690f4b9815d476e241edc2d52" ]
[ "FEM/fenics/rd01.py" ]
[ "#Reaction diffusion\nfrom dolfin import *\nprint('dolfin import complete...\\n')\nimport matplotlib.pyplot as plt\n\n\n# Create mesh and define function space\nmesh = UnitSquareMesh(32, 32)\nV = FunctionSpace(mesh, \"Lagrange\", 1)\nprint('Unit square mesh created...\\n')\n\n\nplot(mesh);\nprint('close plot window...
[ [ "matplotlib.pyplot.show" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
gandhiy/lipMIP
[ "11843e6bf2223acca44f57d29791521aac15caf3" ]
[ "scripts/job_builder_architecture_series.py" ]
[ "\"\"\" Script to build a bunch of networks, train each of them, and then\n\tbuild jobs to evaluate each of these\n\"\"\"\nimport matlab.engine\nimport numpy as np\nimport torch \nimport sys \nsys.path.append('..')\nfrom experiment import Experiment, MethodNest, Job\nfrom hyperbox import Hyperbox \nfrom relu_nets i...
[ [ "numpy.array", "numpy.zeros", "numpy.ones" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
ForexAndBeyond/FinRL-Meta
[ "95a3f60cc9a392e0bb92a2e6860ab0afb1782d75" ]
[ "finrl_meta/env_fx_trading/env_fx.py" ]
[ "import datetime\nimport math\nimport random\n\nimport gym\nimport numpy as np\nfrom gym import spaces\nfrom gym.utils import seeding\nfrom stable_baselines3.common.vec_env import DummyVecEnv\n\nfrom finrl_meta.env_fx_trading.util.log_render import render_to_file\nfrom finrl_meta.env_fx_trading.util.plot_chart impo...
[ [ "numpy.array" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
wright-group/WrightTune
[ "e9a4937b6fda24dfd10baf2fc674c15542861aba" ]
[ "attune/_tune.py" ]
[ "__all__ = [\"Tune\"]\n\n\nimport WrightTools as wt\nimport numpy as np\nimport scipy.interpolate\n\n\nclass Tune:\n def __init__(self, independent, dependent, *, dep_units=None, **kwargs):\n \"\"\"A Tune which maps one set of inputs to associated output points.\n\n Currently all tunes are assumed ...
[ [ "numpy.asarray", "numpy.allclose" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
Ichinga-Samuel/IPOM
[ "3d90c27812eaea7bc003ea5b0a2e39db301b0b84" ]
[ "model/model.py" ]
[ "import pprint as prp\nimport numpy as np\nfrom math import *\n\nfrom report.report_builder import BuildDoc\n\n\ndef model(TPd, op):\n try:\n # Operational Parameters\n Nm, Nd, Nc, Na, Nsp = op\n # Constant Parameters\n td = 180 # total time required to load, digest and discharge a b...
[ [ "numpy.array", "numpy.abs", "numpy.nonzero" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
carmenalab/emgdecomp
[ "ec13b4c78e2d4af34a343f0b6ca8d57219eeffec", "ec13b4c78e2d4af34a343f0b6ca8d57219eeffec" ]
[ "emgdecomp/decomposition.py", "emgdecomp/plots.py" ]
[ "import collections\nimport dataclasses\nimport logging\nimport pickle\nimport time\nfrom dataclasses import dataclass\nfrom typing import Optional, Union, Dict, Tuple, List, Callable\n\nimport numpy as np\nimport pandas as pd\nfrom scipy.cluster.vq import kmeans2\nfrom scipy.signal import find_peaks\nfrom scipy.st...
[ [ "numpy.dot", "scipy.signal.find_peaks", "numpy.sqrt", "sklearn.metrics.silhouette_score", "numpy.squeeze", "numpy.dtype", "numpy.max", "numpy.zeros_like", "numpy.mean", "sklearn.cluster.AgglomerativeClustering", "numpy.divide", "numpy.linalg.svd", "scipy.cluster...
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [ "1.6", "1.4", "1.5", "1.2", "1.7", "1.3" ], "tensorflow": [] }, { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
Calvibert/machine-learning-exercises
[ "8184a8338505ea8075992f419385620be6522d14" ]
[ "src/pandas/pandas_operations.py" ]
[ "import pandas as pd\ndf = pd.DataFrame({'col1':[1,2,3,4],'col2':[444,555,666,444],'col3':['abc','def','ghi','xyz']})\ndf.head()\n\nprint(df)\n\nprint(df['col2'].unique())\nprint(len(df['col2'].unique()))\nprint(df['col2'].nunique())\n\nprint(df.nunique())\nprint(df['col2'].value_counts())\n\nprint(df['col1'] > 2)\...
[ [ "pandas.DataFrame" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [ "0.23", "0.21", "2.0", "1.4", "0.19", "1.1", "1.5", "1.2", "0.24", "0.20", "1.0", "0.25", "1.3" ], "scipy": [], "tensorflow": [] } ]
sidorof/Thymus-timeseries
[ "8f43b35ed098ddc6e4eb912c01b824bcf2047d7f" ]
[ "tests/test_point.py" ]
[ "# tests/test_point.py\n\"\"\"\nThis module tests the Point class\n\"\"\"\nimport unittest\n\nfrom datetime import date, datetime\nimport json\nimport numpy as np\n\nfrom thymus.timeseries import Timeseries\nfrom thymus.point import Point\n\n\nclass TestPoint(unittest.TestCase):\n \"\"\" This class tests the cla...
[ [ "numpy.arange" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
alexlyttle/helium-glitch-fitter
[ "22575f0126e3c7c4e124a0acc740b8e71ce5294e" ]
[ "examples/glitch_fit_many2.py" ]
[ "\"\"\"\nGlitch fit for many stars\n\nTODO: \n - Power law for b and phi\n - Base of convection zone - small amplitude.\n\"\"\"\nimport jax\nimport jax.numpy as jnp\nimport numpy as np\n\nfrom regression import init_optimizer, loss_fn, make_targets, get_update_fn, \\\n make_plot\nfrom parser import parse_args\nf...
[ [ "matplotlib.collections.LineCollection", "matplotlib.pyplot.subplots", "numpy.stack", "matplotlib.pyplot.colorbar", "matplotlib.pyplot.show", "numpy.loadtxt", "matplotlib.pyplot.figure" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]
uakarsh/h2o-3
[ "30dc00950692cc71d8803a5ffc565aeb4bd3ac6f" ]
[ "h2o-py/h2o/explanation/_explain.py" ]
[ "# -*- encoding: utf-8 -*-\n\nimport random\nimport warnings\nfrom contextlib import contextmanager\nfrom collections import OrderedDict, Counter, defaultdict\ntry:\n from StringIO import StringIO # py2 (first as py2 also has io.StringIO, but only with unicode support)\nexcept:\n from io import StringIO # p...
[ [ "numpy.nanmax", "numpy.linspace", "numpy.nanmin", "pandas.DataFrame", "numpy.max", "numpy.argmin", "numpy.mean", "numpy.histogram", "numpy.ones_like", "numpy.full", "numpy.std", "numpy.interp", "numpy.zeros", "numpy.min", "numpy.isnan", "numpy.power"...
[ { "matplotlib": [], "numpy": [], "pandas": [ "0.23", "0.21", "2.0", "1.4", "0.19", "1.1", "1.5", "1.2", "0.24", "0.20", "1.0", "0.25", "1.3" ], "scipy": [], "tensorflow": [] } ]
yayiblue/op_v0814_crwusiz
[ "8c047a54cd950af875239eefc80f3558693cb4f8" ]
[ "selfdrive/controls/lib/latcontrol_lqr.py" ]
[ "import math\nimport numpy as np\n\nfrom common.numpy_fast import clip, interp\nfrom common.realtime import DT_CTRL\nfrom cereal import log\nfrom selfdrive.controls.lib.drive_helpers import get_steer_max\nfrom selfdrive.controls.lib.latcontrol import LatControl, MIN_STEER_SPEED\n\nTORQUE_SCALE_BP = [0., 30., 80., 1...
[ [ "numpy.sign", "numpy.array" ] ]
[ { "matplotlib": [], "numpy": [], "pandas": [], "scipy": [], "tensorflow": [] } ]