{"metadata":{"kernelspec":{"display_name":"Python 3","language":"python","name":"python3"},"language_info":{"codemirror_mode":{"name":"ipython","version":3},"file_extension":".py","mimetype":"text/x-python","name":"python","nbconvert_exporter":"python","pygments_lexer":"ipython3","version":"3.10.14"},"kaggle":{"accelerator":"nvidiaTeslaT4","dataSources":[{"sourceId":84493,"databundleVersionId":9871156,"sourceType":"competition"},{"sourceId":9801075,"sourceType":"datasetVersion","datasetId":6006872},{"sourceId":9806342,"sourceType":"datasetVersion","datasetId":6010899},{"sourceId":10277864,"sourceType":"datasetVersion","datasetId":6359705},{"sourceId":10304887,"sourceType":"datasetVersion","datasetId":6378806},{"sourceId":203900450,"sourceType":"kernelVersion"}],"dockerImageVersionId":30787,"isInternetEnabled":false,"language":"python","sourceType":"notebook","isGpuEnabled":true},"papermill":{"default_parameters":{},"duration":7.594014,"end_time":"2024-10-10T11:58:36.355301","environment_variables":{},"exception":null,"input_path":"__notebook__.ipynb","output_path":"__notebook__.ipynb","parameters":{},"start_time":"2024-10-10T11:58:28.761287","version":"2.6.0"}},"nbformat_minor":4,"nbformat":4,"cells":[{"cell_type":"markdown","source":"### ℹ️ Info\n* **forked original great work kernels**\n    * https://www.kaggle.com/code/voix97/jane-street-rmf-inference-nn-xgb\n* **2024/12/26 My Additional**\n    * XGB local train modelx5 add. dataset is here.\n    * https://www.kaggle.com/datasets/hideyukizushi/als-e-105-pp0-30-xgb-5fold\n    ```\n    # My add XGB CV\n    Fold:0\t0.02815069772843637\n    Fold:1\t0.03025051553457081\n    Fold:2\t0.030019236957170792\n    Fold:3\t0.01810551744095168\n    Fold:4\t0.029192405102951957\n    ```\n* **2024/12/30 My Additional**\n    * XGB local train modelx5 add. dataset is here.\n    * https://www.kaggle.com/datasets/hideyukizushi/als-e-106-pp0-40-xgb-5fold\n    ```\n    # My add XGB CV\n    Fold:0    0.03925861557112098\n    Fold:1    0.03926324675193538\n    Fold:2    0.036001183736670606\n    Fold:3    0.03101361931294766\n    Fold:4    0.039566354720759755\n    ```","metadata":{}},{"cell_type":"markdown","source":"---\n---","metadata":{}},{"cell_type":"code","source":"import pandas as pd\nimport polars as pl\nimport numpy as np\nimport os, gc\nfrom tqdm.auto import tqdm\nfrom matplotlib import pyplot as plt\nimport pickle\n\nimport torch\nimport torch.nn as nn\nimport torch.nn.functional as F\nfrom pytorch_lightning import (LightningDataModule, LightningModule, Trainer)\nfrom pytorch_lightning.callbacks import EarlyStopping, ModelCheckpoint, Timer\n\nimport pandas as pd\nimport numpy as np\nfrom sklearn.metrics import r2_score\nfrom sklearn.model_selection import train_test_split\nfrom torch.utils.data import Dataset, DataLoader\n\n\nfrom sklearn.metrics import r2_score\nfrom lightgbm import LGBMRegressor\nimport lightgbm as lgb\nfrom xgboost import XGBRegressor\nfrom catboost import CatBoostRegressor\nfrom sklearn.ensemble import VotingRegressor\n\nimport warnings\nwarnings.filterwarnings('ignore')\npd.options.display.max_columns = None\n\nimport kaggle_evaluation.jane_street_inference_server","metadata":{"execution":{"iopub.status.busy":"2024-12-31T03:20:27.985769Z","iopub.execute_input":"2024-12-31T03:20:27.986196Z","iopub.status.idle":"2024-12-31T03:20:39.305561Z","shell.execute_reply.started":"2024-12-31T03:20:27.98614Z","shell.execute_reply":"2024-12-31T03:20:39.30482Z"},"trusted":true},"outputs":[],"execution_count":null},{"cell_type":"markdown","source":"### Configurations","metadata":{}},{"cell_type":"code","source":"class CONFIG:\n    seed = 286\n    target_col = \"responder_6\"\n    # feature_cols = [\"symbol_id\", \"time_id\"] + [f\"feature_{idx:02d}\" for idx in range(79)]+ [f\"responder_{idx}_lag_1\" for idx in range(9)]\n    feature_cols = [f\"feature_{idx:02d}\" for idx in range(79)]+ [f\"responder_{idx}_lag_1\" for idx in range(9)]\n    \n    model_paths = [\n        #\"/kaggle/input/js24-train-gbdt-model-with-lags-singlemodel/result.pkl\",\n        #\"/kaggle/input/js24-trained-gbdt-model/result.pkl\",\n        \"/kaggle/input/js-xs-nn-trained-model\",\n    ]","metadata":{"execution":{"iopub.status.busy":"2024-12-31T03:20:39.307283Z","iopub.execute_input":"2024-12-31T03:20:39.307842Z","iopub.status.idle":"2024-12-31T03:20:39.312721Z","shell.execute_reply.started":"2024-12-31T03:20:39.307812Z","shell.execute_reply":"2024-12-31T03:20:39.311611Z"},"trusted":true},"outputs":[],"execution_count":null},{"cell_type":"markdown","source":"### Load preprocessed data (to calculate CV)","metadata":{}},{"cell_type":"code","source":"valid = pl.scan_parquet(\n    f\"/kaggle/input/js24-preprocessing-create-lags/validation.parquet/\"\n).collect().to_pandas()","metadata":{"execution":{"iopub.status.busy":"2024-12-31T03:20:39.314079Z","iopub.execute_input":"2024-12-31T03:20:39.314465Z","iopub.status.idle":"2024-12-31T03:20:41.795517Z","shell.execute_reply.started":"2024-12-31T03:20:39.314433Z","shell.execute_reply":"2024-12-31T03:20:41.794164Z"},"trusted":true},"outputs":[],"execution_count":null},{"cell_type":"markdown","source":"---\n# **《《《XGB Models》》》**\n---","metadata":{}},{"cell_type":"code","source":"xgb_model = None\nmodel_path = \"/kaggle/input/als-e-106-pp0-40-xgb-5fold/result0.pkl\"\nwith open( model_path, \"rb\") as fp:\n    result = pickle.load(fp)\n    xgb_model = result[\"model\"]\n\nxgb_feature_cols = [\"symbol_id\", \"time_id\"] + CONFIG.feature_cols\n\n# Show model\ndisplay(xgb_model)","metadata":{"execution":{"iopub.status.busy":"2024-12-31T03:20:41.796889Z","iopub.execute_input":"2024-12-31T03:20:41.79734Z","iopub.status.idle":"2024-12-31T03:20:41.91347Z","shell.execute_reply.started":"2024-12-31T03:20:41.797297Z","shell.execute_reply":"2024-12-31T03:20:41.910226Z"},"trusted":true},"outputs":[],"execution_count":null},{"cell_type":"code","source":"xgb_model1 = None\nmodel_path = \"/kaggle/input/als-e-106-pp0-40-xgb-5fold/result1.pkl\"\nwith open( model_path, \"rb\") as fp:\n    result = pickle.load(fp)\n    xgb_model1 = result[\"model\"]\n\nxgb_feature_cols = [\"symbol_id\", \"time_id\"] + CONFIG.feature_cols\n\n# Show model\ndisplay(xgb_model1)","metadata":{"trusted":true,"execution":{"iopub.status.busy":"2024-12-31T03:20:41.915734Z","iopub.execute_input":"2024-12-31T03:20:41.916749Z","iopub.status.idle":"2024-12-31T03:20:41.947453Z","shell.execute_reply.started":"2024-12-31T03:20:41.916696Z","shell.execute_reply":"2024-12-31T03:20:41.946659Z"}},"outputs":[],"execution_count":null},{"cell_type":"code","source":"xgb_model2 = None\nmodel_path = \"/kaggle/input/als-e-106-pp0-40-xgb-5fold/result2.pkl\"\nwith open( model_path, \"rb\") as fp:\n    result = pickle.load(fp)\n    xgb_model2 = result[\"model\"]\n\nxgb_feature_cols = [\"symbol_id\", \"time_id\"] + CONFIG.feature_cols\n\n# Show model\ndisplay(xgb_model2)","metadata":{"trusted":true,"execution":{"iopub.status.busy":"2024-12-31T03:20:41.949437Z","iopub.execute_input":"2024-12-31T03:20:41.950378Z","iopub.status.idle":"2024-12-31T03:20:41.982647Z","shell.execute_reply.started":"2024-12-31T03:20:41.950332Z","shell.execute_reply":"2024-12-31T03:20:41.981637Z"}},"outputs":[],"execution_count":null},{"cell_type":"code","source":"xgb_model3 = None\nmodel_path = \"/kaggle/input/als-e-106-pp0-40-xgb-5fold/result3.pkl\"\nwith open( model_path, \"rb\") as fp:\n    result = pickle.load(fp)\n    xgb_model3 = result[\"model\"]\n\nxgb_feature_cols = [\"symbol_id\", \"time_id\"] + CONFIG.feature_cols\n\n# Show model\ndisplay(xgb_model3)","metadata":{"trusted":true,"execution":{"iopub.status.busy":"2024-12-31T03:20:41.983784Z","iopub.execute_input":"2024-12-31T03:20:41.984207Z","iopub.status.idle":"2024-12-31T03:20:42.01591Z","shell.execute_reply.started":"2024-12-31T03:20:41.984139Z","shell.execute_reply":"2024-12-31T03:20:42.014929Z"}},"outputs":[],"execution_count":null},{"cell_type":"code","source":"xgb_model4 = None\nmodel_path = \"/kaggle/input/als-e-106-pp0-40-xgb-5fold/result4.pkl\"\nwith open( model_path, \"rb\") as fp:\n    result = pickle.load(fp)\n    xgb_model4 = result[\"model\"]\n\nxgb_feature_cols = [\"symbol_id\", \"time_id\"] + CONFIG.feature_cols\n\n# Show model\ndisplay(xgb_model4)","metadata":{"trusted":true,"execution":{"iopub.status.busy":"2024-12-31T03:20:42.017121Z","iopub.execute_input":"2024-12-31T03:20:42.017461Z","iopub.status.idle":"2024-12-31T03:20:42.044423Z","shell.execute_reply.started":"2024-12-31T03:20:42.017433Z","shell.execute_reply":"2024-12-31T03:20:42.043383Z"}},"outputs":[],"execution_count":null},{"cell_type":"code","source":"# ------------------------------------------- #\n# Public XGB Model\n# ------------------------------------------- #\nxgb_model5 = None\nmodel_path = \"/kaggle/input/js-with-lags-trained-xgb/result.pkl\"\nwith open( model_path, \"rb\") as fp:\n    result = pickle.load(fp)\n    xgb_model5 = result[\"model\"]\n\nxgb_feature_cols = [\"symbol_id\", \"time_id\"] + CONFIG.feature_cols\n\n# Show model\ndisplay(xgb_model5)","metadata":{"trusted":true,"execution":{"iopub.status.busy":"2024-12-31T03:20:42.045735Z","iopub.execute_input":"2024-12-31T03:20:42.046222Z","iopub.status.idle":"2024-12-31T03:20:42.072854Z","shell.execute_reply.started":"2024-12-31T03:20:42.046158Z","shell.execute_reply":"2024-12-31T03:20:42.071853Z"}},"outputs":[],"execution_count":null},{"cell_type":"markdown","source":"---\n# **《《《NN Models》》》**\n---","metadata":{}},{"cell_type":"code","source":"# Custom R2 metric for validation\ndef r2_val(y_true, y_pred, sample_weight):\n    r2 = 1 - np.average((y_pred - y_true) ** 2, weights=sample_weight) / (np.average((y_true) ** 2, weights=sample_weight) + 1e-38)\n    return r2\n\n\nclass NN(LightningModule):\n    def __init__(self, input_dim, hidden_dims, dropouts, lr, weight_decay):\n        super().__init__()\n        self.save_hyperparameters()\n        layers = []\n        in_dim = input_dim\n        for i, hidden_dim in enumerate(hidden_dims):\n            layers.append(nn.BatchNorm1d(in_dim))\n            if i > 0:\n                layers.append(nn.SiLU())\n            if i < len(dropouts):\n                layers.append(nn.Dropout(dropouts[i]))\n            layers.append(nn.Linear(in_dim, hidden_dim))\n            # layers.append(nn.ReLU())\n            in_dim = hidden_dim\n        layers.append(nn.Linear(in_dim, 1))  # 输出层\n        layers.append(nn.Tanh())\n        self.model = nn.Sequential(*layers)\n        self.lr = lr\n        self.weight_decay = weight_decay\n        self.validation_step_outputs = []\n\n    def forward(self, x):\n        return 5 * self.model(x).squeeze(-1)  # 输出为一维张量\n\n    def training_step(self, batch):\n        x, y, w = batch\n        y_hat = self(x)\n        loss = F.mse_loss(y_hat, y, reduction='none') * w  # 考虑样本权重\n        loss = loss.mean()\n        self.log('train_loss', loss, on_step=False, on_epoch=True, batch_size=x.size(0))\n        return loss\n\n    def validation_step(self, batch):\n        x, y, w = batch\n        y_hat = self(x)\n        loss = F.mse_loss(y_hat, y, reduction='none') * w\n        loss = loss.mean()\n        self.log('val_loss', loss, on_step=False, on_epoch=True, batch_size=x.size(0))\n        self.validation_step_outputs.append((y_hat, y, w))\n        return loss\n\n    def on_validation_epoch_end(self):\n        \"\"\"Calculate validation WRMSE at the end of the epoch.\"\"\"\n        y = torch.cat([x[1] for x in self.validation_step_outputs]).cpu().numpy()\n        if self.trainer.sanity_checking:\n            prob = torch.cat([x[0] for x in self.validation_step_outputs]).cpu().numpy()\n        else:\n            prob = torch.cat([x[0] for x in self.validation_step_outputs]).cpu().numpy()\n            weights = torch.cat([x[2] for x in self.validation_step_outputs]).cpu().numpy()\n            # r2_val\n            val_r_square = r2_val(y, prob, weights)\n            self.log(\"val_r_square\", val_r_square, prog_bar=True, on_step=False, on_epoch=True)\n        self.validation_step_outputs.clear()\n\n    def configure_optimizers(self):\n        optimizer = torch.optim.Adam(self.parameters(), lr=self.lr, weight_decay=self.weight_decay)\n        scheduler = torch.optim.lr_scheduler.ReduceLROnPlateau(optimizer, mode='min', factor=0.5, patience=5,\n                                                               verbose=True)\n        return {\n            'optimizer': optimizer,\n            'lr_scheduler': {\n                'scheduler': scheduler,\n                'monitor': 'val_loss',\n            }\n        }\n\n    def on_train_epoch_end(self):\n        if self.trainer.sanity_checking:\n            return\n        epoch = self.trainer.current_epoch\n        metrics = {k: v.item() if isinstance(v, torch.Tensor) else v for k, v in self.trainer.logged_metrics.items()}\n        formatted_metrics = {k: f\"{v:.5f}\" for k, v in metrics.items()}\n        print(f\"Epoch {epoch}: {formatted_metrics}\")","metadata":{"trusted":true,"execution":{"iopub.status.busy":"2024-12-31T03:20:42.07407Z","iopub.execute_input":"2024-12-31T03:20:42.074376Z","iopub.status.idle":"2024-12-31T03:20:42.089625Z","shell.execute_reply.started":"2024-12-31T03:20:42.074347Z","shell.execute_reply":"2024-12-31T03:20:42.088736Z"}},"outputs":[],"execution_count":null},{"cell_type":"code","source":"N_folds = 5\n# 加载最佳模型\nmodels = []\nfor fold in range(N_folds):\n    checkpoint_path = f\"{CONFIG.model_paths[0]}/nn_{fold}.model\"\n    model = NN.load_from_checkpoint(checkpoint_path)\n    models.append(model.to(\"cuda:0\"))","metadata":{"trusted":true,"execution":{"iopub.status.busy":"2024-12-31T03:20:42.090734Z","iopub.execute_input":"2024-12-31T03:20:42.091027Z","iopub.status.idle":"2024-12-31T03:20:43.066397Z","shell.execute_reply.started":"2024-12-31T03:20:42.090998Z","shell.execute_reply":"2024-12-31T03:20:43.065345Z"}},"outputs":[],"execution_count":null},{"cell_type":"markdown","source":"### CV Score","metadata":{}},{"cell_type":"code","source":"X_valid = valid[ xgb_feature_cols ]\ny_valid = valid[ CONFIG.target_col ]\nw_valid = valid[ \"weight\" ]\ny_pred_valid_xgb = xgb_model.predict(X_valid)\nvalid_score = r2_score( y_valid, y_pred_valid_xgb, sample_weight=w_valid )\nvalid_score","metadata":{"trusted":true,"execution":{"iopub.status.busy":"2024-12-31T03:20:43.067668Z","iopub.execute_input":"2024-12-31T03:20:43.067958Z","iopub.status.idle":"2024-12-31T03:20:45.684067Z","shell.execute_reply.started":"2024-12-31T03:20:43.067929Z","shell.execute_reply":"2024-12-31T03:20:45.683103Z"}},"outputs":[],"execution_count":null},{"cell_type":"code","source":"X_valid = valid[ CONFIG.feature_cols ]\ny_valid = valid[ CONFIG.target_col ]\nw_valid = valid[ \"weight\" ]\nX_valid = X_valid.fillna(method = 'ffill').fillna(0)\nX_valid.shape, y_valid.shape, w_valid.shape","metadata":{"execution":{"iopub.status.busy":"2024-12-31T03:20:45.685447Z","iopub.execute_input":"2024-12-31T03:20:45.685745Z","iopub.status.idle":"2024-12-31T03:20:47.917407Z","shell.execute_reply.started":"2024-12-31T03:20:45.685716Z","shell.execute_reply":"2024-12-31T03:20:47.916467Z"},"trusted":true},"outputs":[],"execution_count":null},{"cell_type":"code","source":"y_pred_valid_nn = np.zeros(y_valid.shape)\nwith torch.no_grad():\n    for model in models:\n        model.eval()\n        y_pred_valid_nn += model(torch.FloatTensor(X_valid.values).to(\"cuda:0\")).cpu().numpy() / len(models)\nvalid_score = r2_score( y_valid, y_pred_valid_nn, sample_weight=w_valid )\nvalid_score","metadata":{"execution":{"iopub.status.busy":"2024-12-31T03:20:47.920188Z","iopub.execute_input":"2024-12-31T03:20:47.920538Z","iopub.status.idle":"2024-12-31T03:20:55.734585Z","shell.execute_reply.started":"2024-12-31T03:20:47.920507Z","shell.execute_reply":"2024-12-31T03:20:55.733382Z"},"trusted":true},"outputs":[],"execution_count":null},{"cell_type":"code","source":"y_pred_valid_ensemble = 0.5 * (y_pred_valid_xgb + y_pred_valid_nn)\nvalid_score = r2_score( y_valid, y_pred_valid_ensemble, sample_weight=w_valid )\nvalid_score","metadata":{"trusted":true,"execution":{"iopub.status.busy":"2024-12-31T03:20:55.736007Z","iopub.execute_input":"2024-12-31T03:20:55.736574Z","iopub.status.idle":"2024-12-31T03:20:55.762106Z","shell.execute_reply.started":"2024-12-31T03:20:55.73651Z","shell.execute_reply":"2024-12-31T03:20:55.760737Z"}},"outputs":[],"execution_count":null},{"cell_type":"code","source":"del valid, X_valid, y_valid, w_valid\ngc.collect()","metadata":{"execution":{"iopub.status.busy":"2024-12-31T03:20:55.763799Z","iopub.execute_input":"2024-12-31T03:20:55.76427Z","iopub.status.idle":"2024-12-31T03:20:56.006036Z","shell.execute_reply.started":"2024-12-31T03:20:55.764223Z","shell.execute_reply":"2024-12-31T03:20:56.004966Z"},"trusted":true},"outputs":[],"execution_count":null},{"cell_type":"markdown","source":"---\n# **《《《Finaly Inf&Blend》》》**\n---","metadata":{}},{"cell_type":"code","source":"lags_ : pl.DataFrame | None = None\n    \ndef predict(test: pl.DataFrame, lags: pl.DataFrame | None) -> pl.DataFrame | pd.DataFrame:\n    global lags_\n    if lags is not None:\n        lags_ = lags\n\n    predictions = test.select(\n        'row_id',\n        pl.lit(0.0).alias('responder_6'),\n    )\n    symbol_ids = test.select('symbol_id').to_numpy()[:, 0]\n\n    lags = lags_.clone().group_by([\"date_id\", \"symbol_id\"], maintain_order=True).last() # pick up last record of previous date\n    test = test.join(lags, on=[\"date_id\", \"symbol_id\"],  how=\"left\")\n\n    # ------------------------------------------------- #\n    # Inf\n    # ------------------------------------------------- #\n    preds1 = np.zeros((test.shape[0],))\n    preds2 = np.zeros((test.shape[0],))\n    \n    \"\"\" Pred XGB \"\"\"\n    preds1 += xgb_model.predict(test[xgb_feature_cols].to_pandas())/4\n    # preds1 += xgb_model1.predict(test[xgb_feature_cols].to_pandas())/5\n    preds1 += xgb_model2.predict(test[xgb_feature_cols].to_pandas())/4\n    # preds1 += xgb_model3.predict(test[xgb_feature_cols].to_pandas())/5\n    preds1 += xgb_model4.predict(test[xgb_feature_cols].to_pandas())/4\n    preds1 += xgb_model5.predict(test[xgb_feature_cols].to_pandas())/4\n    \n    \"\"\" Pred NN \"\"\"\n    test_input = test[CONFIG.feature_cols].to_pandas()\n    test_input = test_input.fillna(method = 'ffill').fillna(0)\n    test_input = torch.FloatTensor(test_input.values).to(\"cuda:0\")\n    with torch.no_grad():\n        for i, nn_model in enumerate(tqdm(models)):\n            nn_model.eval()\n            preds2 += nn_model(test_input).cpu().numpy()/len(models)\n\n    \"\"\" Model Weight \"\"\"\n    _ModelW=[0.56,0.50]\n    preds = (preds1*_ModelW[0] + preds2*_ModelW[1])\n\n    \"\"\" Finaly \"\"\"\n    predictions = \\\n    test.select('row_id').\\\n    with_columns(\n        pl.Series(\n            name   = 'responder_6', \n            values = np.clip(preds, a_min = -5, a_max = 5),\n            dtype  = pl.Float64,\n        )\n    )\n\n    assert isinstance(predictions, pl.DataFrame | pd.DataFrame)\n    assert list(predictions.columns) == ['row_id', 'responder_6']\n    assert len(predictions) == len(test)\n\n    return predictions","metadata":{"_cell_guid":"b1076dfc-b9ad-4769-8c92-a6c4dae69d19","_uuid":"8f2839f25d086af736a60e9eeb907d3b93b6e0e5","papermill":{"duration":0.018344,"end_time":"2024-10-10T11:58:33.59684","exception":false,"start_time":"2024-10-10T11:58:33.578496","status":"completed"},"tags":[],"execution":{"iopub.status.busy":"2024-12-31T03:20:56.007581Z","iopub.execute_input":"2024-12-31T03:20:56.007899Z","iopub.status.idle":"2024-12-31T03:20:56.019357Z","shell.execute_reply.started":"2024-12-31T03:20:56.007869Z","shell.execute_reply":"2024-12-31T03:20:56.018369Z"},"trusted":true},"outputs":[],"execution_count":null},{"cell_type":"code","source":"inference_server = kaggle_evaluation.jane_street_inference_server.JSInferenceServer(predict)\n\nif os.getenv('KAGGLE_IS_COMPETITION_RERUN'):\n    inference_server.serve()\nelse:\n    inference_server.run_local_gateway(\n        (\n            '/kaggle/input/jane-street-realtime-marketdata-forecasting/test.parquet',\n            '/kaggle/input/jane-street-realtime-marketdata-forecasting/lags.parquet',\n        )\n    )","metadata":{"_cell_guid":"b1076dfc-b9ad-4769-8c92-a6c4dae69d19","_uuid":"8f2839f25d086af736a60e9eeb907d3b93b6e0e5","papermill":{"duration":2.225871,"end_time":"2024-10-10T11:58:35.830964","exception":false,"start_time":"2024-10-10T11:58:33.605093","status":"completed"},"tags":[],"execution":{"iopub.status.busy":"2024-12-31T03:21:10.189501Z","iopub.execute_input":"2024-12-31T03:21:10.18988Z","iopub.status.idle":"2024-12-31T03:21:10.375464Z","shell.execute_reply.started":"2024-12-31T03:21:10.189845Z","shell.execute_reply":"2024-12-31T03:21:10.374287Z"},"trusted":true},"outputs":[],"execution_count":null},{"cell_type":"code","source":"","metadata":{"trusted":true},"outputs":[],"execution_count":null}]}