{"metadata":{"kernelspec":{"language":"python","display_name":"Python 3","name":"python3"},"language_info":{"name":"python","version":"3.10.13","mimetype":"text/x-python","codemirror_mode":{"name":"ipython","version":3},"pygments_lexer":"ipython3","nbconvert_exporter":"python","file_extension":".py"},"kaggle":{"accelerator":"none","dataSources":[{"sourceId":58266,"databundleVersionId":6641124,"sourceType":"competition"}],"dockerImageVersionId":30646,"isInternetEnabled":true,"language":"python","sourceType":"notebook","isGpuEnabled":false}},"nbformat_minor":4,"nbformat":4,"cells":[{"cell_type":"code","source":"import numpy as np\nimport pandas as pd","metadata":{"_uuid":"8f2839f25d086af736a60e9eeb907d3b93b6e0e5","_cell_guid":"b1076dfc-b9ad-4769-8c92-a6c4dae69d19","execution":{"iopub.status.busy":"2024-02-27T11:35:22.958936Z","iopub.execute_input":"2024-02-27T11:35:22.959661Z","iopub.status.idle":"2024-02-27T11:35:24.560560Z","shell.execute_reply.started":"2024-02-27T11:35:22.959624Z","shell.execute_reply":"2024-02-27T11:35:24.559250Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"# Load the sample_submission.csv file\nsample_submission_path = '/kaggle/input/predict-ai-model-runtime/sample_submission.csv'\nsample_submission_df = pd.read_csv(sample_submission_path)","metadata":{"execution":{"iopub.status.busy":"2024-02-27T11:35:24.563122Z","iopub.execute_input":"2024-02-27T11:35:24.564222Z","iopub.status.idle":"2024-02-27T11:35:24.611991Z","shell.execute_reply.started":"2024-02-27T11:35:24.564172Z","shell.execute_reply":"2024-02-27T11:35:24.609825Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"# Display dataframe\nsample_submission_df","metadata":{"execution":{"iopub.status.busy":"2024-02-27T11:35:24.614200Z","iopub.execute_input":"2024-02-27T11:35:24.615169Z","iopub.status.idle":"2024-02-27T11:35:24.646703Z","shell.execute_reply.started":"2024-02-27T11:35:24.615114Z","shell.execute_reply":"2024-02-27T11:35:24.644660Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"# Display basic statistics\nsample_submission_df.describe()","metadata":{"execution":{"iopub.status.busy":"2024-02-27T11:35:24.649535Z","iopub.execute_input":"2024-02-27T11:35:24.650607Z","iopub.status.idle":"2024-02-27T11:35:24.694256Z","shell.execute_reply.started":"2024-02-27T11:35:24.650569Z","shell.execute_reply":"2024-02-27T11:35:24.691097Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"# The last 50 cases are not \"0;1;2;3;4\"\nsample_submission_df[sample_submission_df[\"TopConfigs\"] != \"0;1;2;3;4\"]","metadata":{"execution":{"iopub.status.busy":"2024-02-27T11:35:24.697618Z","iopub.execute_input":"2024-02-27T11:35:24.700229Z","iopub.status.idle":"2024-02-27T11:35:24.772583Z","shell.execute_reply.started":"2024-02-27T11:35:24.700169Z","shell.execute_reply":"2024-02-27T11:35:24.770178Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"def generate_random_config():\n    \"\"\"\n    Generate a random configuration string consisting of 5 unique digits between 0 and 9.\n    \n    Returns:\n        str: A string containing 5 unique digits between 0 and 9, separated by semicolons.\n    \"\"\"\n    return \";\".join(map(str, np.random.choice(range(10), 5, replace=False)))\n\n# Create the baseline submission DataFrame\nbaseline_submission = pd.DataFrame({\n    'ID': sample_submission_df['ID'],\n    'TopConfigs': [generate_random_config() for _ in range(len(sample_submission_df))]\n})\n\n# Save the DataFrame to a CSV file\nbaseline_submission.to_csv('submission.csv', index=False)","metadata":{"execution":{"iopub.status.busy":"2024-02-27T11:35:24.782961Z","iopub.execute_input":"2024-02-27T11:35:24.784574Z","iopub.status.idle":"2024-02-27T11:35:24.845734Z","shell.execute_reply.started":"2024-02-27T11:35:24.784522Z","shell.execute_reply":"2024-02-27T11:35:24.844226Z"},"trusted":true},"execution_count":null,"outputs":[]},{"cell_type":"code","source":"baseline_submission","metadata":{"execution":{"iopub.status.busy":"2024-02-27T11:35:24.849892Z","iopub.execute_input":"2024-02-27T11:35:24.850756Z","iopub.status.idle":"2024-02-27T11:35:24.869291Z","shell.execute_reply.started":"2024-02-27T11:35:24.850709Z","shell.execute_reply":"2024-02-27T11:35:24.867371Z"},"trusted":true},"execution_count":null,"outputs":[]}]}