Dataset Viewer
Auto-converted to Parquet Duplicate
code
stringlengths
31
1.05M
apis
sequence
extract_api
stringlengths
97
1.91M
# # Copyright (c) 2021 The GPflux Contributors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agr...
[ "numpy.testing.assert_equal", "tensorflow_probability.distributions.MultivariateNormalDiag", "tensorflow_probability.distributions.MultivariateNormalTriL", "numpy.testing.assert_allclose", "numpy.concatenate", "numpy.testing.assert_array_equal", "numpy.eye", "numpy.allclose", "gpflux.encoders.Direct...
[((897, 935), 'tensorflow.keras.backend.set_floatx', 'tf.keras.backend.set_floatx', (['"""float64"""'], {}), "('float64')\n", (924, 935), True, 'import tensorflow as tf\n'), ((2330, 2370), 'pytest.mark.parametrize', 'pytest.mark.parametrize', (['"""w_dim"""', '[1, 5]'], {}), "('w_dim', [1, 5])\n", (2353, 2370), False, ...
""" This script will modulate the blinky lights using the following algorithm: 1) uses user-provided location to obtain row of pixel data from bathy image 2) samples a 'number of LEDs' number of pixels from that row 3) shifts the sampled row data to center it at the location specified by user 4) displays resulting pix...
[ "PIL.Image.open", "numpy.roll", "numpy.asarray", "optparse.OptionParser", "time.sleep", "numpy.take", "blinkytape.BlinkyTape", "sys.exit", "json.load" ]
[((1945, 1968), 'optparse.OptionParser', 'optparse.OptionParser', ([], {}), '()\n', (1966, 1968), False, 'import optparse\n'), ((3304, 3328), 'blinkytape.BlinkyTape', 'BlinkyTape', (['port', 'n_leds'], {}), '(port, n_leds)\n', (3314, 3328), False, 'from blinkytape import BlinkyTape\n'), ((3366, 3374), 'time.sleep', 'sl...
""" Basic usage =========== This example presents the basic usage of brokenaxes """ import matplotlib.pyplot as plt from brokenaxes import brokenaxes import numpy as np fig = plt.figure(figsize=(5,2)) bax = brokenaxes(xlims=((0, .1), (.4, .7)), ylims=((-1, .7), (.79, 1)), hspace=.05) x = np.linspace(0, 1, 100) bax...
[ "matplotlib.pyplot.figure", "brokenaxes.brokenaxes", "numpy.linspace", "numpy.cos", "numpy.sin" ]
[((180, 206), 'matplotlib.pyplot.figure', 'plt.figure', ([], {'figsize': '(5, 2)'}), '(figsize=(5, 2))\n', (190, 206), True, 'import matplotlib.pyplot as plt\n'), ((212, 299), 'brokenaxes.brokenaxes', 'brokenaxes', ([], {'xlims': '((0, 0.1), (0.4, 0.7))', 'ylims': '((-1, 0.7), (0.79, 1))', 'hspace': '(0.05)'}), '(xlims...
# -*- coding: utf-8 -*- # This code is part of Qiskit. # # (C) Copyright IBM 2017, 2021. # # This code is licensed under the Apache License, Version 2.0. You may # obtain a copy of this license in the LICENSE.txt file in the root directory # of this source tree or at http://www.apache.org/licenses/LICENSE-2.0. # # Any...
[ "qiskit_metal.draw.union", "math.cos", "qiskit_metal.Dict", "numpy.array", "qiskit_metal.draw.rectangle", "qiskit_metal.draw.translate", "qiskit_metal.draw.rotate", "math.sin" ]
[((4010, 4566), 'qiskit_metal.Dict', 'Dict', ([], {'pad_width': '"""1000um"""', 'pad_height': '"""300um"""', 'finger_width': '"""50um"""', 'finger_height': '"""100um"""', 'finger_space': '"""50um"""', 'pad_pos_x': '"""0um"""', 'pad_pos_y': '"""0um"""', 'comb_width': '"""50um"""', 'comb_space_vert': '"""50um"""', 'comb_...
import inspect import numpy as np from pandas._libs import reduction as libreduction from pandas.util._decorators import cache_readonly from pandas.core.dtypes.common import ( is_dict_like, is_extension_array_dtype, is_list_like, is_sequence, ) from pandas.core.dtypes.generic import ABCSeries def f...
[ "pandas.core.dtypes.common.is_list_like", "pandas._libs.reduction.compute_reduction", "pandas.Series", "pandas.core.dtypes.common.is_sequence", "numpy.asarray", "inspect.getfullargspec", "numpy.errstate", "numpy.apply_along_axis", "numpy.empty_like", "pandas.core.dtypes.common.is_dict_like" ]
[((5381, 5409), 'numpy.empty_like', 'np.empty_like', (['target.values'], {}), '(target.values)\n', (5394, 5409), True, 'import numpy as np\n'), ((2193, 2213), 'pandas.core.dtypes.common.is_list_like', 'is_list_like', (['self.f'], {}), '(self.f)\n', (2205, 2213), False, 'from pandas.core.dtypes.common import is_dict_lik...
# Copyright (c) Pymatgen Development Team. # Distributed under the terms of the MIT License. """ Test for the piezo tensor class """ __author__ = "<NAME>" __version__ = "0.1" __maintainer__ = "<NAME>" __email__ = "<EMAIL>" __status__ = "Development" __date__ = "4/1/16" import os import unittest import numpy as np ...
[ "pymatgen.analysis.piezo.PiezoTensor.from_vasp_voigt", "pymatgen.analysis.piezo.PiezoTensor", "numpy.array", "numpy.zeros", "pymatgen.analysis.piezo.PiezoTensor.from_voigt", "unittest.main" ]
[((2195, 2210), 'unittest.main', 'unittest.main', ([], {}), '()\n', (2208, 2210), False, 'import unittest\n'), ((554, 684), 'numpy.array', 'np.array', (['[[0.0, 0.0, 0.0, 0.0, 0.03839, 0.0], [0.0, 0.0, 0.0, 0.03839, 0.0, 0.0], [\n 6.89822, 6.89822, 27.4628, 0.0, 0.0, 0.0]]'], {}), '([[0.0, 0.0, 0.0, 0.0, 0.03839, 0....
import argparse import json import numpy as np import pandas as pd import os from sklearn.linear_model import LogisticRegression from sklearn.model_selection import train_test_split from sklearn.metrics import classification_report,f1_score from keras.models import Sequential from keras.layers import Dense, Dropout fro...
[ "pandas.read_csv", "sklearn.metrics.classification_report", "keras.utils.vis_utils.plot_model", "numpy.column_stack", "keras.layers.Dense", "numpy.mean", "argparse.ArgumentParser", "keras.backend.clip", "numpy.asarray", "numpy.concatenate", "keras.backend.epsilon", "json.loads", "sklearn.mod...
[((2973, 2997), 'pandas.read_csv', 'pd.read_csv', (['dataset_csv'], {}), '(dataset_csv)\n', (2984, 2997), True, 'import pandas as pd\n'), ((4112, 4136), 'numpy.asarray', 'np.asarray', (['sentence_emb'], {}), '(sentence_emb)\n', (4122, 4136), True, 'import numpy as np\n'), ((4182, 4203), 'numpy.asarray', 'np.asarray', (...
''' ------------------------------------------------------------------------------------------------- This code accompanies the paper titled "Human injury-based safety decision of automated vehicles" Author: <NAME>, <NAME>, <NAME>, <NAME> Corresponding author: <NAME> (<EMAIL>) ------------------------------------------...
[ "numpy.abs", "numpy.sqrt", "numpy.cos", "numpy.sin", "numpy.arctan" ]
[((723, 742), 'numpy.cos', 'np.cos', (['delta_angle'], {}), '(delta_angle)\n', (729, 742), True, 'import numpy as np\n'), ((1050, 1084), 'numpy.arctan', 'np.arctan', (['(veh_cgf[0] / veh_cgs[0])'], {}), '(veh_cgf[0] / veh_cgs[0])\n', (1059, 1084), True, 'import numpy as np\n'), ((1106, 1142), 'numpy.abs', 'np.abs', (['...
"\"\"\"Test the search module\"\"\"\n\nfrom collections.abc import Iterable, Sized\nfrom io import S(...TRUNCATED)
["sklearn.utils._testing.assert_warns_message","sklearn.model_selection.GridSearchCV","sklearn.model(...TRUNCATED)
"[((4079, 4125), 'numpy.array', 'np.array', (['[[-1, -1], [-2, -1], [1, 1], [2, 1]]'], {}), '([[-1, (...TRUNCATED)
"# -*- encoding:utf-8 -*-\n# @Time : 2021/1/3 15:15\n# @Author : gfjiang\nimport os.path as osp\(...TRUNCATED)
["math.sqrt","cvtools.imwrite","mmdet.ops.nms","matplotlib.pyplot.imshow","os.path.exists","cvtools.(...TRUNCATED)
"[((643, 671), 'matplotlib.pyplot.figure', 'plt.figure', ([], {'figsize': '(32, 32)'}), '(figsize=(3(...TRUNCATED)
End of preview. Expand in Data Studio
README.md exists but content is empty.
Downloads last month
37