{"kind":"task","effective_mode":"full","benchmark":{"kind":"benchmark","effective_mode":"full","slug":"bigcodebench","formal_name":"BigCodeBench","introduction":"BigCodeBench poses 1,140 function-level tasks drawn across 139 libraries. It tests whether a model can compose several real APIs correctly rather than write one self-contained function.","introduction_ja":"","introduction_en":"","category":"Category not supplied","task_count":null,"acquisition_status":"Acquisition status not supplied","official_url":"https://bigcode-bench.github.io/","indexing_mode":"index","profile":{"resources":[],"task_format":"","scoring":"","metric":"","size":"","answer_access":"","license":"","citation":"","maintainer":"","released":"","why_hard":"","related":[],"history":"","construction":"","limitations":"","saturation":"","scores":[]}},"task_id":"375e304a-b3c9-5614-973b-d2b4d3610c9f","task_key":"default--v0~2e1~2e0~5fhf--375e304a-b3c9-5614-973b-d2b4d3610c9f","task_revision_id":"1","upstream_id":"","short_description":"BigCodeBench v0.1.0_hf 375e304a-b3c9-5614-973b-d2b4d3610c9f","config":"default","split":"v0.1.0_hf","body":"{\"code_prompt\":\"import pandas as pd\\nfrom sklearn.preprocessing import MinMaxScaler\\nimport matplotlib.pyplot as plt\\ndef task_func(data):\\n\",\"complete_prompt\":\"import pandas as pd\\nfrom sklearn.preprocessing import MinMaxScaler\\nimport matplotlib.pyplot as plt\\n\\n\\ndef task_func(data):\\n    \\\"\\\"\\\"\\n    Processes a dataset containing salary information and experience, then plots normalized salary against experience.\\n    The function executes the following steps:\\n    1. Input Validation: Checks if the input data dictionary contains the required keys ('Salary_String' and 'Experience').\\n       Raises a ValueError if the necessary keys are missing.\\n    2. DataFrame Conversion: Converts the input data into a pandas DataFrame for easier manipulation.\\n    3. Empty Data Handling: Checks if the DataFrame is empty. If so, it returns a default Axes instance with\\n       labeled axes but no data plotted. This handles cases where there is no data to plot.\\n    4. Salary Conversion: Converts 'Salary_String' values from comma-separated strings to floats.\\n       It handles potential conversion errors by catching ValueErrors and re-raising them with a custom message.\\n    5. Salary Normalization: Applies Min-Max scaling to normalize the salary values. This step transforms\\n       the salary data into a range between 0 and 1, allowing for easier comparison and visualization.\\n    6. Data Plotting: Creates a scatter plot of the normalized salary against experience using matplotlib.\\n       The plot's axes are labeled accordingly.\\n\\n    Parameters:\\n    - data (dict): A dictionary with two keys: 'Salary_String' and 'Experience'.\\n                   'Salary_String' should contain salary values as comma-separated strings.\\n                   'Experience' should contain corresponding experience values as integers.\\n\\n    Returns:\\n    - matplotlib.axes.Axes: An Axes instance with the plotted scatter plot.\\n\\n    Raises:\\n    - ValueError: If the input dictionary does not contain the required keys or if data conversion from string to float fails.\\n\\n    Requirements:\\n    - pandas\\n    - sklearn\\n    - matplotlib\\n\\n    Example:\\n    >>> ax = task_func({'Salary_String': ['1,000', '2,000', '3,000'], 'Experience': [1, 2, 3]})\\n    >>> print(ax.get_title())\\n    Normalized Salary vs Experience\\n    \\\"\\\"\\\"\\n\",\"entry_point\":\"task_func\",\"instruct_prompt\":\"Processes a dataset containing salary information and experience, then plots normalized salary against experience. The function executes the following steps: 1. Input Validation: Checks if the input data dictionary contains the required keys ('Salary_String' and 'Experience'). Raises a ValueError if the necessary keys are missing. 2. DataFrame Conversion: Converts the input data into a pandas DataFrame for easier manipulation. 3. Empty Data Handling: Checks if the DataFrame is empty. If so, it returns a default Axes instance with labeled axes but no data plotted. This handles cases where there is no data to plot. 4. Salary Conversion: Converts 'Salary_String' values from comma-separated strings to floats. It handles potential conversion errors by catching ValueErrors and re-raising them with a custom message. 5. Salary Normalization: Applies Min-Max scaling to normalize the salary values. This step transforms the salary data into a range between 0 and 1, allowing for easier comparison and visualization. 6. Data Plotting: Creates a scatter plot of the normalized salary against experience using matplotlib. The plot's axes are labeled accordingly.\\nThe function should raise the exception for: ValueError: If the input dictionary does not contain the required keys or if data conversion from string to float fails.\\nThe function should output with:\\n    matplotlib.axes.Axes: An Axes instance with the plotted scatter plot.\\nYou should write self-contained code starting with:\\n```\\nimport pandas as pd\\nfrom sklearn.preprocessing import MinMaxScaler\\nimport matplotlib.pyplot as plt\\ndef task_func(data):\\n```\",\"libs\":\"['pandas', 'matplotlib', 'sklearn']\"}","display_format":"code","language":"","answer_status":"published","assets":[],"source_url":"https://bigcode-bench.github.io/","history":"initial import","indexing_mode":"index","subproblems":[],"grids":[]}