Datasets:

Modalities:
Text
Formats:
parquet
Size:
< 1K
ArXiv:
Libraries:
Datasets
pandas
Dataset Viewer
Auto-converted to Parquet Duplicate
repository
stringclasses
11 values
repo_id
stringlengths
1
3
target_module_path
stringlengths
16
72
prompt
stringlengths
407
21.7k
relavent_test_path
stringlengths
51
97
full_function
stringlengths
2.6k
33.8k
function_name
stringlengths
3
49
context-complexity
stringclasses
3 values
seaborn
6
seaborn/_base.py
def iter_data( self, grouping_vars=None, *, reverse=False, from_comp_data=False, by_facet=True, allow_empty=False, dropna=True, ): """Generator for getting subsets of data defined by semantic variables. Also injects "col" and "row" into grouping semantics. Param...
/usr/src/app/target_test_cases/failed_tests_VectorPlotter.iter_data.txt
def iter_data( self, grouping_vars=None, *, reverse=False, from_comp_data=False, by_facet=True, allow_empty=False, dropna=True, ): """Generator for getting subsets of data defined by semantic variables. Also injects "col" and "row" into grouping semantics. Param...
VectorPlotter.iter_data
Self-Contained
seaborn
21
seaborn/axisgrid.py
def add_legend(self, legend_data=None, title=None, label_order=None, adjust_subtitles=False, **kwargs): """Draw a legend, maybe placing it outside axes and resizing the figure. Parameters ---------- legend_data : dict Dictionary mapping label names (or...
/usr/src/app/target_test_cases/failed_tests_axisgrid.Grid.add_legend.txt
def add_legend(self, legend_data=None, title=None, label_order=None, adjust_subtitles=False, **kwargs): """Draw a legend, maybe placing it outside axes and resizing the figure. Parameters ---------- legend_data : dict Dictionary mapping label names (or...
axisgrid.Grid.add_legend
Repo-Level
seaborn
28
seaborn/axisgrid.py
def __init__( self, data, *, hue=None, vars=None, x_vars=None, y_vars=None, hue_order=None, palette=None, hue_kws=None, corner=False, diag_sharey=True, height=2.5, aspect=1, layout_pad=.5, despine=True, dropna=False, ): """Initialize the plot figure and PairGrid object. ...
/usr/src/app/target_test_cases/failed_tests_axisgrid.PairGrid.__init__.txt
def __init__( self, data, *, hue=None, vars=None, x_vars=None, y_vars=None, hue_order=None, palette=None, hue_kws=None, corner=False, diag_sharey=True, height=2.5, aspect=1, layout_pad=.5, despine=True, dropna=False, ): """Initialize the plot figure and PairGrid object. ...
axisgrid.PairGrid.__init__
Repo-Level
seaborn
29
seaborn/axisgrid.py
def pairplot( data, *, hue=None, hue_order=None, palette=None, vars=None, x_vars=None, y_vars=None, kind="scatter", diag_kind="auto", markers=None, height=2.5, aspect=1, corner=False, dropna=False, plot_kws=None, diag_kws=None, grid_kws=None, size=None, ): """Plot pairwise relationships in a...
/usr/src/app/target_test_cases/failed_tests_axisgrid.pairplot.txt
def pairplot( data, *, hue=None, hue_order=None, palette=None, vars=None, x_vars=None, y_vars=None, kind="scatter", diag_kind="auto", markers=None, height=2.5, aspect=1, corner=False, dropna=False, plot_kws=None, diag_kws=None, grid_kws=None, size=None, ): """Plot pairwise relationships in a...
axisgrid.pairplot
Self-Contained
seaborn
33
seaborn/palettes.py
def color_palette(palette=None, n_colors=None, desat=None, as_cmap=False): """Return a list of colors or continuous colormap defining a palette. Possible ``palette`` values include: - Name of a seaborn palette (deep, muted, bright, pastel, dark, colorblind) - Name of matplotlib colormap ...
/usr/src/app/target_test_cases/failed_tests_color_palette.txt
def color_palette(palette=None, n_colors=None, desat=None, as_cmap=False): """Return a list of colors or continuous colormap defining a palette. Possible ``palette`` values include: - Name of a seaborn palette (deep, muted, bright, pastel, dark, colorblind) - Name of matplotlib colormap ...
color_palette
Repo-Level
seaborn
71
seaborn/utils.py
def despine(fig=None, ax=None, top=True, right=True, left=False, bottom=False, offset=None, trim=False): """Remove the top and right spines from plot(s). fig : matplotlib figure, optional Figure to despine all axes of, defaults to the current figure. ax : matplotlib axes, optional ...
/usr/src/app/target_test_cases/failed_tests_utils.despine.txt
def despine(fig=None, ax=None, top=True, right=True, left=False, bottom=False, offset=None, trim=False): """Remove the top and right spines from plot(s). fig : matplotlib figure, optional Figure to despine all axes of, defaults to the current figure. ax : matplotlib axes, optional ...
utils.despine
Self-Contained
seaborn
73
seaborn/utils.py
def move_legend(obj, loc, **kwargs): """ Recreate a plot's legend at a new location. The name is a slight misnomer. Matplotlib legends do not expose public control over their position parameters. So this function creates a new legend, copying over the data from the original object, which is then re...
/usr/src/app/target_test_cases/failed_tests_utils.move_legend.txt
def move_legend(obj, loc, **kwargs): """ Recreate a plot's legend at a new location. The name is a slight misnomer. Matplotlib legends do not expose public control over their position parameters. So this function creates a new legend, copying over the data from the original object, which is then re...
utils.move_legend
Self-Contained
scikit-learn
0
sklearn/linear_model/_bayes.py
def fit(self, X, y): """Fit the model according to the given training data and parameters. Iterative procedure to maximize the evidence Parameters ---------- X : array-like of shape (n_samples, n_features) Training vector, where `n_samples` is the number of samp...
/usr/src/app/target_test_cases/failed_tests_ARDRegression.fit.txt
def fit(self, X, y): """Fit the model according to the given training data and parameters. Iterative procedure to maximize the evidence Parameters ---------- X : array-like of shape (n_samples, n_features) Training vector, where `n_samples` is the number of samp...
ARDRegression.fit
Repo-Level
scikit-learn
9
sklearn/linear_model/_bayes.py
def fit(self, X, y, sample_weight=None): """Fit the model. Parameters ---------- X : ndarray of shape (n_samples, n_features) Training data. y : ndarray of shape (n_samples,) Target values. Will be cast to X's dtype if necessary. sample_weigh...
/usr/src/app/target_test_cases/failed_tests_BayesianRidge.fit.txt
def fit(self, X, y, sample_weight=None): """Fit the model. Parameters ---------- X : ndarray of shape (n_samples, n_features) Training data. y : ndarray of shape (n_samples,) Target values. Will be cast to X's dtype if necessary. sample_weigh...
BayesianRidge.fit
Repo-Level
scikit-learn
14
sklearn/cluster/_bisect_k_means.py
def fit(self, X, y=None, sample_weight=None): """Compute bisecting k-means clustering. Parameters ---------- X : {array-like, sparse matrix} of shape (n_samples, n_features) Training instances to cluster. .. note:: The data will be converted to C ordering, ...
/usr/src/app/target_test_cases/failed_tests_BisectingKMeans.fit.txt
def fit(self, X, y=None, sample_weight=None): """Compute bisecting k-means clustering. Parameters ---------- X : {array-like, sparse matrix} of shape (n_samples, n_features) Training instances to cluster. .. note:: The data will be converted to C ordering, ...
BisectingKMeans.fit
Repo-Level
scikit-learn
15
sklearn/calibration.py
def fit(self, X, y, sample_weight=None, **fit_params): """Fit the calibrated model. Parameters ---------- X : array-like of shape (n_samples, n_features) Training data. y : array-like of shape (n_samples,) Target values. sample_weight : arra...
/usr/src/app/target_test_cases/failed_tests_CalibratedClassifierCV.fit.txt
def fit(self, X, y, sample_weight=None, **fit_params): """Fit the calibrated model. Parameters ---------- X : array-like of shape (n_samples, n_features) Training data. y : array-like of shape (n_samples,) Target values. sample_weight : arra...
CalibratedClassifierCV.fit
Repo-Level
scikit-learn
38
sklearn/linear_model/_coordinate_descent.py
def fit(self, X, y, sample_weight=None, check_input=True): """Fit model with coordinate descent. Parameters ---------- X : {ndarray, sparse matrix, sparse array} of (n_samples, n_features) Data. Note that large sparse matrices and arrays requiring `int64` ...
/usr/src/app/target_test_cases/failed_tests_ElasticNet.fit.txt
def fit(self, X, y, sample_weight=None, check_input=True): """Fit model with coordinate descent. Parameters ---------- X : {ndarray, sparse matrix, sparse array} of (n_samples, n_features) Data. Note that large sparse matrices and arrays requiring `int64` ...
ElasticNet.fit
Repo-Level
scikit-learn
55
sklearn/gaussian_process/_gpc.py
def log_marginal_likelihood( self, theta=None, eval_gradient=False, clone_kernel=True ): """Return log-marginal likelihood of theta for training data. In the case of multi-class classification, the mean log-marginal likelihood of the one-versus-rest classifiers are returned. ...
/usr/src/app/target_test_cases/failed_tests_GaussianProcessClassifier.log_marginal_likelihood.txt
def log_marginal_likelihood( self, theta=None, eval_gradient=False, clone_kernel=True ): """Return log-marginal likelihood of theta for training data. In the case of multi-class classification, the mean log-marginal likelihood of the one-versus-rest classifiers are returned. ...
GaussianProcessClassifier.log_marginal_likelihood
Repo-Level
scikit-learn
57
sklearn/gaussian_process/_gpr.py
def fit(self, X, y): """Fit Gaussian process regression model. Parameters ---------- X : array-like of shape (n_samples, n_features) or list of object Feature vectors or other representations of training data. y : array-like of shape (n_samples,) or (n_samples, ...
/usr/src/app/target_test_cases/failed_tests_GaussianProcessRegressor.fit.txt
def fit(self, X, y): """Fit Gaussian process regression model. Parameters ---------- X : array-like of shape (n_samples, n_features) or list of object Feature vectors or other representations of training data. y : array-like of shape (n_samples,) or (n_samples, ...
GaussianProcessRegressor.fit
Repo-Level
scikit-learn
58
sklearn/gaussian_process/_gpr.py
def log_marginal_likelihood( self, theta=None, eval_gradient=False, clone_kernel=True ): """Return log-marginal likelihood of theta for training data. Parameters ---------- theta : array-like of shape (n_kernel_params,) default=None Kernel hyperparameters for...
/usr/src/app/target_test_cases/failed_tests_GaussianProcessRegressor.log_marginal_likelihood.txt
def log_marginal_likelihood( self, theta=None, eval_gradient=False, clone_kernel=True ): """Return log-marginal likelihood of theta for training data. Parameters ---------- theta : array-like of shape (n_kernel_params,) default=None Kernel hyperparameters for...
GaussianProcessRegressor.log_marginal_likelihood
Self-Contained
scikit-learn
59
sklearn/gaussian_process/_gpr.py
def predict(self, X, return_std=False, return_cov=False): """Predict using the Gaussian process regression model. We can also predict based on an unfitted model by using the GP prior. In addition to the mean of the predictive distribution, optionally also returns its standard deviat...
/usr/src/app/target_test_cases/failed_tests_GaussianProcessRegressor.predict.txt
def predict(self, X, return_std=False, return_cov=False): """Predict using the Gaussian process regression model. We can also predict based on an unfitted model by using the GP prior. In addition to the mean of the predictive distribution, optionally also returns its standard deviat...
GaussianProcessRegressor.predict
Repo-Level
scikit-learn
66
sklearn/decomposition/_incremental_pca.py
def partial_fit(self, X, y=None, check_input=True): """Incremental fit with X. All of X is processed as a single batch. Parameters ---------- X : array-like of shape (n_samples, n_features) Training data, where `n_samples` is the number of samples and `n_feat...
/usr/src/app/target_test_cases/failed_tests_IncrementalPCA.partial_fit.txt
def partial_fit(self, X, y=None, check_input=True): """Incremental fit with X. All of X is processed as a single batch. Parameters ---------- X : array-like of shape (n_samples, n_features) Training data, where `n_samples` is the number of samples and `n_feat...
IncrementalPCA.partial_fit
Repo-Level
scikit-learn
70
sklearn/impute/_iterative.py
def fit_transform(self, X, y=None, **params): """Fit the imputer on `X` and return the transformed `X`. Parameters ---------- X : array-like, shape (n_samples, n_features) Input data, where `n_samples` is the number of samples and `n_features` is the number o...
/usr/src/app/target_test_cases/failed_tests_IterativeImputer.fit_transform.txt
def fit_transform(self, X, y=None, **params): """Fit the imputer on `X` and return the transformed `X`. Parameters ---------- X : array-like, shape (n_samples, n_features) Input data, where `n_samples` is the number of samples and `n_features` is the number o...
IterativeImputer.fit_transform
Repo-Level
scikit-learn
72
sklearn/preprocessing/_discretization.py
def fit(self, X, y=None, sample_weight=None): """ Fit the estimator. Parameters ---------- X : array-like of shape (n_samples, n_features) Data to be discretized. y : None Ignored. This parameter exists only for compatibility with ...
/usr/src/app/target_test_cases/failed_tests_KBinsDiscretizer.fit.txt
def fit(self, X, y=None, sample_weight=None): """ Fit the estimator. Parameters ---------- X : array-like of shape (n_samples, n_features) Data to be discretized. y : None Ignored. This parameter exists only for compatibility with ...
KBinsDiscretizer.fit
Repo-Level
scikit-learn
75
sklearn/cluster/_kmeans.py
def fit(self, X, y=None, sample_weight=None): """Compute k-means clustering. Parameters ---------- X : {array-like, sparse matrix} of shape (n_samples, n_features) Training instances to cluster. It must be noted that the data will be converted to C ordering, ...
/usr/src/app/target_test_cases/failed_tests_KMeans.fit.txt
def fit(self, X, y=None, sample_weight=None): """Compute k-means clustering. Parameters ---------- X : {array-like, sparse matrix} of shape (n_samples, n_features) Training instances to cluster. It must be noted that the data will be converted to C ordering, ...
KMeans.fit
Repo-Level
scikit-learn
77
sklearn/impute/_knn.py
def transform(self, X): """Impute all missing values in X. Parameters ---------- X : array-like of shape (n_samples, n_features) The input data to complete. Returns ------- X : array-like of shape (n_samples, n_output_features) The im...
/usr/src/app/target_test_cases/failed_tests_KNNImputer.transform.txt
def transform(self, X): """Impute all missing values in X. Parameters ---------- X : array-like of shape (n_samples, n_features) The input data to complete. Returns ------- X : array-like of shape (n_samples, n_output_features) The im...
KNNImputer.transform
Repo-Level
scikit-learn
99
sklearn/linear_model/_linear_loss.py
def gradient_hessian( self, coef, X, y, sample_weight=None, l2_reg_strength=0.0, n_threads=1, gradient_out=None, hessian_out=None, raw_prediction=None, ): """Computes gradient and hessian w.r.t. coef. Parameters ...
/usr/src/app/target_test_cases/failed_tests_LinearModelLoss.gradient_hessian.txt
def gradient_hessian( self, coef, X, y, sample_weight=None, l2_reg_strength=0.0, n_threads=1, gradient_out=None, hessian_out=None, raw_prediction=None, ): """Computes gradient and hessian w.r.t. coef. Parameters ...
LinearModelLoss.gradient_hessian
File-Level
scikit-learn
100
sklearn/linear_model/_linear_loss.py
def gradient_hessian_product( self, coef, X, y, sample_weight=None, l2_reg_strength=0.0, n_threads=1 ): """Computes gradient and hessp (hessian product function) w.r.t. coef. Parameters ---------- coef : ndarray of shape (n_dof,), (n_classes, n_dof) or (n_classes * n_dof...
/usr/src/app/target_test_cases/failed_tests_LinearModelLoss.gradient_hessian_product.txt
def gradient_hessian_product( self, coef, X, y, sample_weight=None, l2_reg_strength=0.0, n_threads=1 ): """Computes gradient and hessp (hessian product function) w.r.t. coef. Parameters ---------- coef : ndarray of shape (n_dof,), (n_classes, n_dof) or (n_classes * n_dof...
LinearModelLoss.gradient_hessian_product
File-Level
scikit-learn
103
sklearn/linear_model/_base.py
def fit(self, X, y, sample_weight=None): """ Fit linear model. Parameters ---------- X : {array-like, sparse matrix} of shape (n_samples, n_features) Training data. y : array-like of shape (n_samples,) or (n_samples, n_targets) Target values....
/usr/src/app/target_test_cases/failed_tests_LinearRegression.fit.txt
def fit(self, X, y, sample_weight=None): """ Fit linear model. Parameters ---------- X : {array-like, sparse matrix} of shape (n_samples, n_features) Training data. y : array-like of shape (n_samples,) or (n_samples, n_targets) Target values....
LinearRegression.fit
Repo-Level
scikit-learn
114
sklearn/cluster/_kmeans.py
def fit(self, X, y=None, sample_weight=None): """Compute the centroids on X by chunking it into mini-batches. Parameters ---------- X : {array-like, sparse matrix} of shape (n_samples, n_features) Training instances to cluster. It must be noted that the data ...
/usr/src/app/target_test_cases/failed_tests_MiniBatchKMeans.fit.txt
def fit(self, X, y=None, sample_weight=None): """Compute the centroids on X by chunking it into mini-batches. Parameters ---------- X : {array-like, sparse matrix} of shape (n_samples, n_features) Training instances to cluster. It must be noted that the data ...
MiniBatchKMeans.fit
Repo-Level
scikit-learn
115
sklearn/cluster/_kmeans.py
def partial_fit(self, X, y=None, sample_weight=None): """Update k means estimate on a single mini-batch X. Parameters ---------- X : {array-like, sparse matrix} of shape (n_samples, n_features) Training instances to cluster. It must be noted that the data wil...
/usr/src/app/target_test_cases/failed_tests_MiniBatchKMeans.partial_fit.txt
def partial_fit(self, X, y=None, sample_weight=None): """Update k means estimate on a single mini-batch X. Parameters ---------- X : {array-like, sparse matrix} of shape (n_samples, n_features) Training instances to cluster. It must be noted that the data wil...
MiniBatchKMeans.partial_fit
Repo-Level
scikit-learn
120
sklearn/linear_model/_coordinate_descent.py
def fit(self, X, y): """Fit MultiTaskElasticNet model with coordinate descent. Parameters ---------- X : ndarray of shape (n_samples, n_features) Data. y : ndarray of shape (n_samples, n_targets) Target. Will be cast to X's dtype if necessary. ...
/usr/src/app/target_test_cases/failed_tests_MultiTaskElasticNet.fit.txt
def fit(self, X, y): """Fit MultiTaskElasticNet model with coordinate descent. Parameters ---------- X : ndarray of shape (n_samples, n_features) Data. y : ndarray of shape (n_samples, n_targets) Target. Will be cast to X's dtype if necessary. ...
MultiTaskElasticNet.fit
Repo-Level
scikit-learn
123
sklearn/neighbors/_nca.py
def fit(self, X, y): """Fit the model according to the given training data. Parameters ---------- X : array-like of shape (n_samples, n_features) The training samples. y : array-like of shape (n_samples,) The corresponding training labels. R...
/usr/src/app/target_test_cases/failed_tests_NeighborhoodComponentsAnalysis.fit.txt
def fit(self, X, y): """Fit the model according to the given training data. Parameters ---------- X : array-like of shape (n_samples, n_features) The training samples. y : array-like of shape (n_samples,) The corresponding training labels. R...
NeighborhoodComponentsAnalysis.fit
Repo-Level
scikit-learn
131
sklearn/multiclass.py
def partial_fit(self, X, y, classes=None, **partial_fit_params): """Partially fit underlying estimators. Should be used when memory is inefficient to train all data. Chunks of data can be passed in several iteration, where the first call should have an array of all target variables....
/usr/src/app/target_test_cases/failed_tests_OneVsOneClassifier.partial_fit.txt
def partial_fit(self, X, y, classes=None, **partial_fit_params): """Partially fit underlying estimators. Should be used when memory is inefficient to train all data. Chunks of data can be passed in several iteration, where the first call should have an array of all target variables....
OneVsOneClassifier.partial_fit
Repo-Level
scikit-learn
133
sklearn/multiclass.py
def partial_fit(self, X, y, classes=None, **partial_fit_params): """Partially fit underlying estimators. Should be used when memory is inefficient to train all data. Chunks of data can be passed in several iterations. Parameters ---------- X : {array-like, sparse ma...
/usr/src/app/target_test_cases/failed_tests_OneVsRestClassifier.partial_fit.txt
def partial_fit(self, X, y, classes=None, **partial_fit_params): """Partially fit underlying estimators. Should be used when memory is inefficient to train all data. Chunks of data can be passed in several iterations. Parameters ---------- X : {array-like, sparse ma...
OneVsRestClassifier.partial_fit
Repo-Level
End of preview. Expand in Data Studio

Can Language Models Replace Programmers? REPOCOD Says 'Not Yet'

Large language models (LLMs) have achieved high accuracy, i.e., more than 90 pass@1, in solving Python coding problems in HumanEval and MBPP. Thus, a natural question is, whether LLMs achieve comparable code completion performance compared to human developers? Unfortunately, one cannot answer this question using existing manual crafted or simple (e.g., single-line) code generation benchmarks, since such tasks fail to represent real-world software development tasks. In addition, existing benchmarks often use poor code correctness metrics, providing misleading conclusions.

To address these challenges, we create REPOCOD, a code generation benchmark with 980 problems collected from 11 popular real-world projects, with more than 58% of them requiring file-level or repository-level context information. In addition, REPOCOD has the longest average canonical solution length (331.6 tokens) and the highest average cyclomatic complexity (9.00) compared to existing benchmarks. Each task in REPOCOD includes 313.5 developer-written test cases on average for better correctness evaluation. In our evaluations on ten LLMs, none of the models achieves more than 30 pass@1 on REPOCOD, disclosing the necessity of building stronger LLMs that can help developers in real-world software development.

For easier evaluation, we sample 200 of the hardest problems in REPOCOD to create REPOCOD-Lite, using the product of the prompt length and canonical solution length (in terms of line count) as an indicator of difficulty. From the three categories of questions—self-contained, file-level, and repo-level—we select 66, 67, and 67 samples respectively in descending order of the scores.

  • For more details on data collection and evaluation results, please refer to our arxiv preprint.

  • Examples code for downloading repositories, preparing repository snapshot, and running test cases for evaluation are propived at code

  • Check our Leaderboard for preliminary results using SOTA LLMs with RAG.

Usage

from datasets import load_dataset
data = load_dataset('lt-asset/REPOCOD_Lite')
print(data)
DatasetDict({
    train: Dataset({
        features: ['repository', 'repo_id', 'target_module_path', 'prompt', 'relavent_test_path', 'full_function', 'function_name'],
        num_rows: 200
    })
})

Data Fields

  • repository: the source repository of the current sample
  • repo_id: the unique index of the sample in the corresponding source repository
  • target_module_path: the file path containing the current sample relative to the root of the source repository
  • prompt: the developer provided function signature and docstring
  • relavent_test_path: the path to the relevant test cases
  • full_function: the canonical solution of the current sample
  • function_name: the name of the target function (current sample)

Example

"repository": "seaborn",                          # collected from seaborn
"repo_id": "6",                                   # first sample from seaborn 
"target_module_path": "seaborn/_base.py",  # the target function is in this path
"prompt": "     def iter_data(
        self, grouping_vars=None, *,
        reverse=False, from_comp_data=False,
        by_facet=True, allow_empty=False, dropna=True,
    ):
        '''Generator for getting subsets of data defined by semantic variables.

        Also injects "col" and "row" into grouping semantics.

        Parameters
        ----------
        grouping_vars : string or list of strings
            Semantic variables that define the subsets of data.
        reverse : bool
            If True, reverse the order of iteration.
        from_comp_data : bool
            If True, use self.comp_data rather than self.plot_data
        by_facet : bool
            If True, add faceting variables to the set of grouping variables.
        allow_empty : bool
            If True, yield an empty dataframe when no observations exist for
            combinations of grouping variables.
        dropna : bool
            If True, remove rows with missing data.

        Yields
        ------
        sub_vars : dict
            Keys are semantic names, values are the level of that semantic.
        sub_data : :class:`pandas.DataFrame`
            Subset of ``plot_data`` for this combination of semantic values.

        '''",                            # the function signature and docstring for the target function
"relevant_test_path": "/usr/src/app/target_test_cases/failed_tests_Continuous.label.txt", # Path to relevant tests for the function
"full_function": "     def iter_data(
        self, grouping_vars=None, *,
        reverse=False, from_comp_data=False,
        by_facet=True, allow_empty=False, dropna=True,
    ):
        '''Generator for getting subsets of data defined by semantic variables.

        Also injects "col" and "row" into grouping semantics.

        Parameters
        ----------
        grouping_vars : string or list of strings
            Semantic variables that define the subsets of data.
        reverse : bool
            If True, reverse the order of iteration.
        from_comp_data : bool
            If True, use self.comp_data rather than self.plot_data
        by_facet : bool
            If True, add faceting variables to the set of grouping variables.
        allow_empty : bool
            If True, yield an empty dataframe when no observations exist for
            combinations of grouping variables.
        dropna : bool
            If True, remove rows with missing data.

        Yields
        ------
        sub_vars : dict
            Keys are semantic names, values are the level of that semantic.
        sub_data : :class:`pandas.DataFrame`
            Subset of ``plot_data`` for this combination of semantic values.

        '''
        if grouping_vars is None:
            grouping_vars = []
        ...",                            # the full snippet of the target function, including the function signature and docstring for the target function
"function_name": "VectorPlotter.iter_data"               # The name of the target function

Citation

@misc{liang2024repocod,
      title={Can Language Models Replace Programmers? REPOCOD Says 'Not Yet'}, 
      author={Shanchao Liang and Yiran Hu and Nan Jiang and Lin Tan},
      year={2024},
      eprint={2410.21647},
      archivePrefix={arXiv},
      primaryClass={cs.SE},
      url={https://arxiv.org/abs/2410.21647}, 
}
Downloads last month
17

Paper for lt-asset/REPOCOD_Lite