Projektpraktikum/electron_lost_found.ipynb

929 lines
1.3 MiB
Plaintext
Raw Normal View History

{
"cells": [
{
"cell_type": "code",
"execution_count": 99,
"metadata": {},
"outputs": [],
"source": [
"import uproot\n",
"import numpy as np\n",
"import sys\n",
"import os\n",
"import matplotlib\n",
"import matplotlib.pyplot as plt\n",
"from mpl_toolkits import mplot3d\n",
"import itertools\n",
"import awkward as ak\n",
2023-09-14 16:33:27 +02:00
"import seaborn as sns\n",
"from scipy.optimize import curve_fit\n",
"%matplotlib inline"
]
},
{
"cell_type": "code",
"execution_count": 100,
"metadata": {},
"outputs": [],
"source": [
2023-09-14 16:33:27 +02:00
"file = uproot.open(\"tracking_losses_ntuple_Bd2KstEE.root:PrDebugTrackingLosses.PrDebugTrackingTool/Tuple;1\")\n",
"#file = uproot.open(\"tracking_losses_ntuple_Dst0ToD0EE.root:PrDebugTrackingLosses.PrDebugTrackingTool/Tuple;1\")\n",
"\n",
2023-09-14 16:33:27 +02:00
"#look at particles only from Signal\n",
"allcolumns = file.arrays()\n",
2023-09-14 16:33:27 +02:00
"tracked = allcolumns[(allcolumns.isElectron) & (~allcolumns.lost) & (allcolumns.fromSignal)]\n",
"lost = allcolumns[(allcolumns.isElectron) & (allcolumns.lost) & (allcolumns.fromSignal)] \n",
"\n",
"#ak.num(tracked, axis=0)\n",
"\n"
]
},
{
"cell_type": "code",
"execution_count": 101,
"metadata": {},
2023-09-15 12:33:25 +02:00
"outputs": [],
2023-09-14 16:33:27 +02:00
"source": [
"#lost\n",
"l_eph = lost[\"brem_photons_pe\"]\n",
"ak.nan_to_num(l_eph)\n",
"l_pT = lost[\"pt\"]\n",
"l_sci_x = lost[\"scifi_hit_pos_x\"]\n",
"ak.nan_to_num(l_sci_x)\n",
"\n",
"#found\n",
"f_eph = tracked[\"brem_photons_pe\"]\n",
"ak.nan_to_num(f_eph)\n",
"f_pT = tracked[\"pt\"]\n",
"f_sci_x = tracked[\"scifi_hit_pos_x\"]\n",
2023-09-15 12:33:25 +02:00
"ak.nan_to_num(f_sci_x)\n",
"\n",
"l_sci_x, l_pT = ak.broadcast_arrays(l_sci_x, l_pT)\n",
"f_sci_x, f_pT = ak.broadcast_arrays(f_sci_x, f_pT)\n",
"\n",
"l_sci_x = ak.to_numpy(ak.flatten(l_sci_x))\n",
"l_pT = ak.to_numpy(ak.flatten(l_pT))\n",
"f_sci_x = ak.to_numpy(ak.flatten(f_sci_x))\n",
"f_pT = ak.to_numpy(ak.flatten(f_pT))"
2023-09-14 16:33:27 +02:00
]
},
{
"cell_type": "code",
"execution_count": 102,
2023-09-14 16:33:27 +02:00
"metadata": {},
"outputs": [
{
"data": {
"image/png": "iVBORw0KGgoAAAANSUhEUgAABj4AAAIhCAYAAAD+a8NgAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjcuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8pXeV/AAAACXBIWXMAAA9hAAAPYQGoP6dpAADy6klEQVR4nOzde3wU1f3/8feSOyFEAiQhEAMqIBBQBA0XbUAgiASkqFTRCNYiFYUiULxVDbaCgiIWKl5KuYpofwoCagyIopSrKCqXon6LCEqAYkgAIQnh/P6gWZlkJtklu2QTXs/HYx8Pcvbs2TNnZodz5syZj8sYYwQAAAAAAAAAAFAD1KrqCgAAAAAAAAAAAPgKEx8AAAAAAAAAAKDGYOIDAAAAAAAAAADUGEx8AAAAAAAAAACAGoOJDwAAAAAAAAAAUGMw8QEAAAAAAAAAAGoMJj4AAAAAAAAAAECNwcQHAAAAAAAAAACoMZj4AAAAAAAAAAAANcZ5M/ExZ84cuVwufffdd34p/4UXXtCcOXN8Xu7QoUPVtGlTn5db4t1331VmZqbfyq+OXC6XpU22b9+uzMxM22PH3/unMj766CO5XC599NFHPivT6Tgv+a7/9//+n8++y5+c2mb69Om65JJLFBoaKpfLpcOHD3u8jwP5WKhK3333nVwuV4Xnx/J+Z5VRXrndunVTcnKyT7+vadOmGjp06Fl//ueff1ZmZqZPf7dARdau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ckJSWZp59+usz3eNue5Z2DSupT+lVyfjzz/8TS7XXmsV5ybH3wwQfmd7/7nYmJiTFRUVEmIyPDHD161Ozbt8/cfPPNJjo62sTHx5uxY8eWOb8A8C+7vn9qaqr7fU/OYU79Iru+hTf9oOXLl5vLLrvMhIaGmqZNm5opU6bYlunEk36R03jQ0z5Vef1LT/scdv2n3bt3m9tuu800bNjQhIaGmksvvdQ888wzlr5ISR9hypQp5tlnnzVNmzY1kZGRplOnTmbdunUVtk9J/bKzs83QoUNNvXr1TO3atU16errtGNIXY+SS7S45xirq51RmvO7NGMeT/oSd0v8fVmas6+k43JPfztdff21uvfVWy/EzY8aMCrfHGGPeeOMNc9VVV7mvFTRr1szceeedljy5ublmzJgxplmzZiY0NNQ0bNjQ9OnTx9KXPbNt7PoVJecMp31cml0+b/rtdsrrY3rahlu3bjW9evUyERERpkGDBmbEiBFm+fLlZcbc2dnZpn///qZx48YmLCzMXHzxxebuu+82Bw8etJRXXt++sLDQ/PGPfzRxcXEmIiLCdO3a1WzYsKFM/6u0in5nxnh2Lcfbcku2ZevWreaWW24xdevWNbGxsebOO+80hw8ftpRVmWth5e3H0jy5fmE3Rjtw4IC55557TKtWrUxkZKRp2LCh6d69u/n4449t28ST83JF58sbbrjBXHjhhbbH8lVXXWXat2/vdfuV9/+OJ9fFCgoKzJ///GfTsmVLExoaaho0aGCGDh1qDhw4YNveZyo5J+/YscOkpaWZ2rVrm/j4eDNp0iRjjDHr1q0zXbt2NbVr1zbNmzc3c+bMKVPGV199Zfr3728uuOACExYWZi677LIy+Ur246uvvmrGjx9v4uPjTWRkpElPTzc5OTkmPz/fDBs2zNSvX9/Ur1/fDB061Bw5csRShrftWd45qKQ+pV8l58cz/08s3V5nHuslx9bkyZPNU0895R7jp6ammp07d5rCwkLzwAMPmEaNGpm6deuaAQMGmP3791e4X85X5/XEx8SJE40kc+utt5p33nnHzJs3z1x00UUmOjrafP311+58LVu2NJdccomZP3+
2023-09-14 16:33:27 +02:00
"text/plain": [
2023-09-15 12:33:25 +02:00
"<Figure size 2000x600 with 4 Axes>"
2023-09-14 16:33:27 +02:00
]
},
"metadata": {},
"output_type": "display_data"
}
],
"source": [
"fig, ((ax0, ax1)) = plt.subplots(nrows=1, ncols=2, figsize=(20,6))\n",
"\n",
"a0=ax0.hist2d(l_sci_x, l_pT, bins=100, cmap=plt.cm.jet)\n",
2023-09-14 16:33:27 +02:00
"ax0.set_xlabel(\"scifi x\")\n",
"ax0.set_ylabel(r\"$p_T$\")\n",
"ax0.set_title(\"lost electron positions in the scifi in regard to their transverse momentum\")\n",
"plt.colorbar(a0[3],ax=ax0)\n",
2023-09-14 16:33:27 +02:00
"\n",
"a1=ax1.hist2d(f_sci_x, f_pT, bins=100, cmap=plt.cm.jet)\n",
2023-09-14 16:33:27 +02:00
"ax1.set_xlabel(\"scifi x\")\n",
"ax1.set_ylabel(r\"$p_T$\")\n",
"ax1.set_title(\"found electron positions in the scifi in regard to their transverse momentum\")\n",
"plt.colorbar(a1[3],ax=ax1)\n",
2023-09-14 16:33:27 +02:00
"\n",
2023-09-15 12:33:25 +02:00
"\"\"\"\n",
2023-09-18 12:12:50 +02:00
"B:\n",
2023-09-15 12:33:25 +02:00
"we can see that the lost electrons cover a wider spread in the x direction of the scifi tracker,\n",
"while most of those have low pT \n",
2023-09-18 12:12:50 +02:00
"\n",
2023-09-15 12:33:25 +02:00
"\"\"\"\n",
2023-09-14 16:33:27 +02:00
"plt.show()"
]
},
{
"cell_type": "code",
2023-09-18 12:12:50 +02:00
"execution_count": null,
"metadata": {},
"outputs": [],
"source": []
},
{
"cell_type": "code",
"execution_count": 103,
2023-09-15 12:33:25 +02:00
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"[[4.09e+04], [8.66e+03], [8.07e+04], ..., [5.63e+03], [6.29e+03], [2.26e+03]]\n",
"[4.62e+04, 9.36e+03, 1.34e+05, 5.63e+04, ..., 2.01e+04, 6.94e+03, 7.83e+03]\n",
"8657.132\n",
"9355.866625028413\n"
]
}
],
"source": [
"energy_found = tracked[\"energy\"]\n",
"energy_found = energy_found[tracked[\"brem_photons_pe_length\"]!=0]\n",
"#ak.nan_to_num(energy_found)\n",
"\n",
"e_ph_found = tracked[\"brem_photons_pe\"]\n",
"e_ph_found = e_ph_found[tracked[\"brem_photons_pe_length\"]!=0]\n",
"#ak.nan_to_num(e_ph_found, nan=[0])\n",
"e_ph_found = ak.sum(e_ph_found, axis=-1, keepdims=True)\n",
"print(e_ph_found)\n",
"print(energy_found)\n",
"\n",
"energy_lost = lost[\"energy\"]\n",
"energy_lost = energy_lost[lost[\"brem_photons_pe_length\"]!=0]\n",
"#ak.nan_to_num(energy_lost)\n",
"\n",
"e_ph_lost = lost[\"brem_photons_pe\"]\n",
"e_ph_lost = e_ph_lost[lost[\"brem_photons_pe_length\"]!=0]\n",
"#ak.nan_to_num(e_ph_lost)\n",
"e_ph_lost = ak.sum(e_ph_lost, axis=-1,keepdims=True)\n",
"\n",
"#e_ph_found, energy_found = ak.broadcast_arrays(e_ph_found, energy_found)\n",
"#e_ph_lost, energy_lost = ak.broadcast_arrays(e_ph_lost, energy_lost)\n",
"\n",
"e_ph_found = ak.to_numpy(ak.flatten(e_ph_found))\n",
"energy_found = ak.to_numpy(energy_found)\n",
"\n",
"e_ph_lost = ak.to_numpy(ak.flatten(e_ph_lost))\n",
"energy_lost = ak.to_numpy(energy_lost)\n",
"\n",
"print(e_ph_found[1])\n",
"print(energy_found[1])"
]
},
{
"cell_type": "code",
"execution_count": 104,
"metadata": {},
"outputs": [],
2023-09-15 12:33:25 +02:00
"source": [
"q_e_found = e_ph_found/energy_found\n",
"q_e_lost = e_ph_lost/energy_lost"
]
},
2023-09-14 16:33:27 +02:00
{
"cell_type": "code",
"execution_count": 105,
2023-09-14 16:33:27 +02:00
"metadata": {},
"outputs": [
{
"data": {
2023-09-18 12:12:50 +02:00
"image/png": "iVBORw0KGgoAAAANSUhEUgAAAioAAAHMCAYAAAD7xYOxAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjcuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8pXeV/AAAACXBIWXMAAA9hAAAPYQGoP6dpAAA13ElEQVR4nO3de3gU5d3/8c/mnBCygUhCgJRjAiRBVKI0QS1aEUFFW+sRMSqiVioglpNHsPoEaz2gj6BSBPpDhBYBqSIHlSAHEUiCiqAgoAQNBhCSQGqAZH5/WPZxSYDsZHdnNvt+Xdde7czO3POdudLuh/u+Z8ZhGIYhAAAAGwqxugAAAIBTIagAAADbIqgAAADbIqgAAADbIqgAAADbIqgAAADbIqgAAADbIqgAAADbIqgAAADbIqgAAADbIqgAAADbIqgAaLDFixfL4XCc8jNt2jSvHKe6ulqJiYl6/vnn/X5sANYIs7oAAIGvsLBQkvT2228rMTGx1vfp6eleOc5HH32kffv26fe//73fjw3AGgQVAA1WWFiouLg4XX311XI4HD47zrx585SVlaW2bdv6/dgArMHQD4AGKygoUPfu3X0aFAzD0IIFC3Tdddf5/dgArENQAdAgBw4c0O7du9WtWzcdP3681scwDK8cZ+3atSopKXELKv46NgDrEFQANMiJOSKTJ09WeHh4rc+WLVvO2IZhGIqLi9P+/ftPuc28efPUrVs3paamenzsffv26corr1STJk2Ulpam5cuXN+SUAfgRc1QANEhBQYEkaf78+UpJSan1fX0ms27fvl0tWrTQWWeddcpt5s+frzvvvNPUsYcOHaqWLVtq3759ev/993XDDTfo66+/VkJCwhlrA2AtggqABiksLFRUVJQGDBig0NDQU2736quv6l//+pfCw8P1ySefqFWrVvrnP/+p9PR0FRYW6pxzztE999yjuXPnqlWrVlq0aJE6deokSVq/fr12795da35KfY59+PBhLVy4UDt27FBMTIwGDBig7t276+23364VfADYD0M/ABqksLBQmZmZpw0pkrR582Zt2LBBI0aM0A8//KCePXvqkUcekSQVFRVp48aNuuOOO/Tjjz/qvPPO09SpU137vvXWW0pLS1NmZqbHx96+fbtiY2Pdely6deumL774wszpAvAzggoA08rKyrRz50517979jNt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y9DkqKSkpGjt2rIYOHepa9+STT2rWrFn68ssvz7h/eXm5nE6nysrK6FEBACBAePL7bWmPSmVlZa3ZvqGhodyeDAAAJFk8R+Xqq6/WU089pV/96lfKyMhQUVGRnnvuOd15551ePU51dbWOHTvm1TYhhYeHKzQ01OoyAACNmKVDPxUVFXr00Ue1YMEClZaWqlWrVrr55pv12GOPKSIi4oz7n6nryDAM7d27V4cOHfJB9ZCk+Ph4tWzZkufYAADqzZOhn4B+18+ZTrSkpESHDh1SYmKiYmJi+DH1IsMwVFlZqdLSUsXHxys5OdnqkgAAAcKToGLp0I8vVVdXu0JKQkKC1eU0StHR0ZKk0tJSJSYmMgwEAPC6RvtSwhNzUmJiYiyupHE7cX2ZAwQA8IVGG1ROYLjHt7i+AABfavRBBQAABC6Cig317t1bI0aMsLoMAAAs12gn057W2vH+O1aOH491kvz8fF1yySU6ePCg4uPjLasDAACz6FEBAAC2RVCxuYMHD+q2225Ts2bNFBMTo379+mn79u2u77/99ltdffXVatasmZo0aaKMjAwtXrxY33zzjS655BJJUrNmzeRwOHT77bdbdBYAAJgTnEM/AeT222/X9u3btWjRIsXFxWnMmDHq37+/tmzZovDwcA0dOlRHjx7VRx99pCZNmmjLli2KjY1VSkqK3nrrLV133XX66quvFBcX53ruCQAAkmpPhbBwusKpEFRs7ERAWbNmjXJyciRJb7zxhlJSUrRw4UJdf/312r17t6677jp169ZNktShQwfX/s2bN5ckJSYmMkcFABCQGPqxsa1btyosLEw9e/Z0rUtISFDnzp21detWSdKwYcP05JNPqlevXnr88cf12WefWVUuAABeR1CxsVO9hskwDNeD1u666y7t3LlTgwYN0ueff66srCy99NJL/iwTAACfIajYWHp6uo4fP65PPvnEte7AgQPatm2bunbt6lqXkpKie++9V/Pnz9eDDz6oqVOnSpLrDdTV1dX+LRwAAC8hqNhYamqqrrnmGg0ZMkSrV6/Wp59+qltvvVWtW7fWNddcI0kaMWKEli5dql27dqmwsFAffvihK8S0bdtWDodD77zzjvbt26fDhw9beToAAHgsOCfT2nBW86lMnz5dw4cP11VXXaWjR4/q4osv1uLFixUeHi7p596SoUOHas+ePYqLi9MVV1yh559/XpLUunVrTZgwQWPHjtUdd9yh2267TTNmzLDwbAAA8IzDONVEiABQXl4up9OpsrIyxcXFuX33008/adeuXWrfvr2ioqIsqrDx4zoDQACz6Pbk0/1+n4yhHwAAYFsEFQAAYFsEFQAAYFsEFQAAYFsEFQAAYFsEFQAAYFsEFQAAYFsEFQAAYFsEFQAAYFsEFRsyDEN33323mjdvLofDoU2bNllWS+/evTVixAjLjg8ACG5B+a6f8ePtfawlS5ZoxowZys/PV4cOHXTWWWd5vS4AAAJBUAYVu9uxY4eSk5OVk5NjdSkAgMbi5Pf6BAiGfmzm9ttv1/3336/du3fL4XCoXbt2qqqq0rBhw5SYmKioqChdeOGF2rBhg2ufGTNmKD4+3q2dhQsXyuFwuJbHjx+vc845R//v//0/tWvXTk6nUzfddJMqKipc2xw5ckS33XabYmNjlZycrGeffdbn5wsAwOkQVGxm0qRJeuKJJ9SmTRuVlJRow4YNGj16tN566y3NnDlThYWF6tSpk/r27asff/zRo7Z37NihhQsX6p133tE777y
2023-09-14 16:33:27 +02:00
"text/plain": [
"<Figure size 640x480 with 1 Axes>"
]
},
"metadata": {},
"output_type": "display_data"
2023-09-15 12:33:25 +02:00
}
],
"source": [
2023-09-18 12:12:50 +02:00
"plt.hist(q_e_lost, bins=100, density=True, alpha=0.5, histtype='bar', color=\"darkorange\", label=\"lost\")\n",
"plt.hist(q_e_found, bins=100, density=True, alpha=0.5, histtype='bar', color=\"blue\", label=\"found\")\n",
2023-09-15 12:33:25 +02:00
"plt.xlabel(r\"$E_\\gamma/E_0$\")\n",
2023-09-18 12:12:50 +02:00
"plt.ylabel(\"counts (normed)\")\n",
"plt.title(r'$E_{ph}/E_0$')\n",
2023-09-15 12:33:25 +02:00
"plt.legend()\n",
"\n",
"\"\"\"\n",
2023-09-18 12:12:50 +02:00
"B:\n",
"we can clearly see that lost electrons are responsible for higher energy photons\n",
2023-09-15 12:33:25 +02:00
"\"\"\"\n",
"\n",
"plt.show()"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": []
},
{
"cell_type": "code",
"execution_count": 106,
2023-09-15 12:33:25 +02:00
"metadata": {},
"outputs": [
2023-09-14 16:33:27 +02:00
{
"data": {
"image/png": "iVBORw0KGgoAAAANSUhEUgAABkQAAAIlCAYAAACEkZQnAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjcuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8pXeV/AAAACXBIWXMAAA9hAAAPYQGoP6dpAADPd0lEQVR4nOzde3gU1f3H8U9IIIRAYoIQiHLTIiLgDRUBKyAKqGBrvaMItsULCopaFWsFrIIXFFpQ0VZFQEH9IbaKIl4AawXkIlapYrWooFysRECEQML5/YG7ziYzmZnN7P39ep592MyeOefM7GzYkznf880yxhgBAAAAAAAAAACksTqJ7gAAAAAAAAAAAECscUMEAAAAAAAAAACkPW6IAAAAAAAAAACAtMcNEQAAAAAAAAAAkPa4IQIAAAAAAAAAANIeN0QAAAAAAAAAAEDa44YIAAAAAAAAAABIe9wQAQAAAAAAAAAAaY8bIgAAAAAAAAAAIO1xQwQZ6ZlnnlGHDh2Ul5enrKwsrV69OtFdsjVmzBhlZWUFVt+0adOUlZWlzz//PLA6rf79739rzJgxMasfqSkrK0tjxoyJSd0//PCDxowZo0WLFgVe95AhQ9SwYcNA6xw3bpxeeOGFQOsEAABIhFiPLR566CFNmzYt8HqHDBmi1q1bB15vyMsvvxyz775ITYsWLVJWVlZMxixSbMfhrVu3Vv/+/QOr7+uvv9aYMWOS9m8wADIDN0SQcb755hsNGjRIhx56qObPn68lS5bosMMOS3S30sK///1vjR07lhsiiLBkyRL99re/jUndP/zwg8aOHRuzwUXQuCECAADgTaxuiMTayy+/rLFjxya6G0gixx57rJYsWaJjjz02JvWn0jj866+/1tixY7khAiChchLdASDePvnkE+3du1eXXHKJevTokejuZLQffvhBDRo0SHQ3EmLXrl2qX79+oBFAyerEE09MdBeQpDL5dwAAAIAxRrt371ZeXl6iu5IQmfJdsKCggDERHGXK5wBIJkSIIKMMGTJEJ510kiTpggsuUFZWlnr27Bl+/e9//7u6du2qBg0aqFGjRjrttNO0ZMmSanXYhVjbLW+VlZWla665RjNmzFD79u3VoEEDHXXUUXrppZeq7T9v3jwdffTRys3NVZs2bTRhwgRfx/b666+rd+/eKigoUIMGDdS9e3e98cYbge778ccf66KLLlJJSYlyc3PVsmVLXXrppSovL9e0adN03nnnSZJ69eqlrKwsZWVlhWd19ezZUx07dtRbb72lbt26qUGDBvr1r38tSfryyy91ySWXqGnTpsrNzVX79u11//33a9++feG2P//8c2VlZWnChAl64IEH1KZNGzVs2FBdu3bV0qVLPR3npk2bdMUVV+jggw9WvXr11KZNG40dO1YVFRVRt7NixQqdddZZKi4uVv369XXMMcfo2WefjSgTWk5gwYIF+vWvf60mTZqoQYMGKi8vlzFG48aNU6tWrVS/fn0dd9xxeu2119SzZ8/wtfn999/rgAMO0BVXXFGt/c8//1zZ2dm67777ajz2sWPHqkuXLiouLlZBQYGOPfZYPfbYYzLGRJQrLy/XDTfcoGbNmqlBgwY6+eSTtXLlSrVu3VpDhgwJl/vmm280bNgwHXHEEWrYsKGaNm2qU045Rf/4xz+qtV11yazQ+Vi4cKGuuuoqHXjggWrcuLF+9atf6euvv47Y980331TPnj3VuHFj5eXlqWXLljrnnHP0ww8/6PPPP1eTJk3Cxxe65qz9rCoUrj5z5kxdf/31atasmfLy8tSjRw+99957tvt8+umnOuOMM9SwYUO1aNFCN9xwg8rLyyPKbN26VcOGDdNBBx2kevXq6ZBDDtHvf//7iHJZWVnauXOnnnzyyXBfrb9/PvzwQ/3iF79QUVGR6tevr6OPPlpPPvmkbf9nzZql3//+9yotLVVBQYFOPfVUrV271vG4rf7zn/9o4MCBEZ+3Bx98sFbtePkdEvoduWrVKp177rkqKirSoYceKsnbdff5558rJydH48ePr9b+W2+9paysLD333HOezgEAAIidxx9/XEcddZTq16+v4uJinX322froo48iyvz3v//VhRdeqNLSUuXm5qqkpES9e/cOzxpv3bq11qxZo8WLF4e/N7ktc2WM0UMPPaSjjz5aeXl5Kioq0rnnnqv//ve/rn32s+/8+fPVu3dvFRYWqkGDBmrfvn34+8mQIUPC36tC/bYuKxYaH06dOlXt27dXbm5u+Pve22+/rd69e6tRo0Zq0KCBunXrpnnz5kW07ed7tBM/4xev7TzzzDPq2rWr8vPz1bBhQ/Xt27fad+vQcrQffPCB+vTpo0aNGql3796SpO+++06/+c1vVFxcrIYNG+rMM8/Uf//734hxxD/+8Y/w99Oqpk+frqysLC1fvtzxuP2MXzZs2KBzzz1XjRo10gEHHKCLL75Yy5cvjxjfhs7lhRdeqNatWysvL0+tW7fWRRddpC+++CKiPrsls0Lnw8tY4+GHH9ZRRx2lhg0bqlGjRjr88MN16623ht+rmsbhdkLfy9977z396le/UkFBgQoLC3XJJZfom2++sd1n/vz5OvbYY5WXl6fDDz9cjz/+eLUybuOZRYsW6fjjj5ckXXbZZeG+WseKXv4mE+r/mjVrdNFFF6mwsFAlJSX69a9/rW3btjket5Wf8YuXdrz+Dqnp7yJerrsZM2YoKyur2jmRpDvuuEN169b1/LsAyGgGyCCffvqpefDBB40kM27cOLNkyRKzZs0aY4wxTz31lJFk+vTpY1544QXzzDPPmM6dO5t69eqZf/zjH+E6Bg8ebFq1alWt7tGjR5uqHylJpnXr1uaEE04wzz77rHn55ZdNz549TU5Ojvnss8/C5V5//XWTnZ1tTjrpJPP888+b5557zhx//PGmZcuW1eq0M2PGDJOVlWV++ctfmueff968+OKLpn///iY7O9u8/vrr4XJPPPGEkWTWrVvne9/Vq1ebhg0bmtatW5upU6eaN954w8ycOdOcf/75Zvv27WbLli1m3LhxRpJ58MEHzZIlS8ySJUvMli1bjDHG9OjRwxQXF5sWLVqYyZMnm4ULF5rFixebLVu2mIMOOsg0adLETJ061cyfP99cc801RpK56qqrwu2vW7cufD779etnXnjhBfPCCy+YTp06maKiIvPdd9/VeI42btxoWrRoYVq1amUeeeQR8/rrr5s//vGPJjc31wwZMiSqdt58801Tr1498/Of/9w888wzZv78+WbIkCFGknniiSeqnfeDDjrIXH755eaVV14x//d//2cqKirMqFGjjCRz+eWXm/nz55u//OUvpmXLlqZ58+amR48e4TpGjhxp8vPzqx3n7373O1O/fn3zv//9r8bjHzJkiHnsscfMa6+9Zl577TXzxz/+0eTl5ZmxY8dGlLvoootMnTp1zC233GIWLFhgJk2aZFq0aGEKCwvN4MGDw+U+/vhjc9VVV5nZs2ebRYsWmZdeesn85je/MXXq1DELFy6MqFOSGT16dLXzccghh5jhw4ebV1991fz1r381RUVFplevXhHvRf369c1pp51mXnjhBbNo0SLz1FNPmUGDBpmysjKze/duM3/+fCPJ/OY3vwlfc59++qnjeVi4cKGRZFq0aGF+8YtfmBdffNHMnDnT/OxnPzMFBQURn8vBgwebevXqmfbt25sJEyaY119/3dx+++0mKysr4rzt2rXLHHnkkSY/P99MmDDBLFiwwPzhD38wOTk55owzzgiXW7JkicnLyzNnnHFGuK+h3z8ff/yxadSokTn00EPN9OnTzbx588xFF11kJJl77rmnWv9bt25tLr74YjNv3jwza9Ys07JlS9O2bVtTUVFR43WwZs0aU1hYaDp16mSmT59uFixYYG644QZTp04dM2bMmKja8fo7JPQ7slWrVubmm282r732mnnhhReMMd6vu7PPPtu0bNmy2nGed955prS01Ozdu7fG4wcAAMGxG1uExgMXXXSRmTdvnpk+fbo55JBDTGFhofnkk0/C5dq1a2d+9rOfmRkzZpjFixebOXPmmBt
2023-09-14 16:33:27 +02:00
"text/plain": [
2023-09-15 12:33:25 +02:00
"<Figure size 2000x600 with 4 Axes>"
2023-09-14 16:33:27 +02:00
]
},
"metadata": {},
"output_type": "display_data"
}
],
"source": [
2023-09-15 12:33:25 +02:00
"fig, ((ax0, ax1)) = plt.subplots(nrows=1, ncols=2, figsize=(20,6))\n",
"\n",
"a0 = ax0.hist2d(e_ph_found, energy_found, density=True, bins=200, cmap=plt.cm.jet, range=[[0,100000],[0,100000]])\n",
2023-09-15 12:33:25 +02:00
"ax0.set_xlabel(r\"$E_\\gamma$\")\n",
"ax0.set_ylabel(r\"$E_e$\")\n",
"ax0.set_title(\"found electron energy against photon energy\")\n",
"plt.colorbar(a0[3],ax=ax0)\n",
2023-09-15 12:33:25 +02:00
"\n",
"a1 = ax1.hist2d(e_ph_lost, energy_lost, density=True, bins=200, cmap=plt.cm.jet, range=[[0,100000],[0,100000]])\n",
2023-09-15 12:33:25 +02:00
"ax1.set_xlabel(r\"$E_\\gamma$\")\n",
"ax1.set_ylabel(r\"$E_e$\")\n",
"ax1.set_title(\"lost electron energy against photon energy\")\n",
"plt.colorbar(a1[3],ax=ax1)\n",
2023-09-15 12:33:25 +02:00
"\n",
"\"\"\"\n",
2023-09-18 12:12:50 +02:00
"B:\n",
"concentrated at the E_ph/E_0~1 line especially at lower energies.\n",
"lost E_ph to E_0: fewer entries at lower q_e\n",
2023-09-15 12:33:25 +02:00
"\"\"\"\n",
2023-09-14 16:33:27 +02:00
"plt.show()"
]
},
{
"cell_type": "code",
"execution_count": 107,
"metadata": {},
"outputs": [],
2023-09-18 12:12:50 +02:00
"source": [
"brem_vtx_x_found = tracked[\"brem_vtx_x\"]\n",
"brem_vtx_x_found = brem_vtx_x_found[tracked[\"brem_vtx_x_length\"]!=0]\n",
"brem_vtx_x_found = ak.to_numpy(ak.flatten(brem_vtx_x_found))\n",
"\n",
"brem_vtx_z_found = tracked[\"brem_vtx_z\"]\n",
"brem_vtx_z_found = brem_vtx_z_found[tracked[\"brem_vtx_z_length\"]!=0]\n",
"#print(ak.to_numpy(brem_vtx_z_found))\n",
2023-09-18 12:12:50 +02:00
"brem_vtx_z_found = ak.to_numpy(ak.flatten(brem_vtx_z_found))\n",
"\n",
"brem_vtx_x_lost = lost[\"brem_vtx_x\"]\n",
"brem_vtx_x_lost = brem_vtx_x_lost[lost[\"brem_vtx_x_length\"]!=0]\n",
"brem_vtx_x_lost = ak.to_numpy(ak.flatten(brem_vtx_x_lost))\n",
"\n",
"brem_vtx_z_lost = lost[\"brem_vtx_z\"]\n",
"brem_vtx_z_lost = brem_vtx_z_lost[lost[\"brem_vtx_z_length\"]!=0]\n",
"brem_vtx_z_lost = ak.to_numpy(ak.flatten(brem_vtx_z_lost))\n",
"\n",
"#vtx_x_fit= ak.to_numpy(vtx_x_found)\n",
"#vtx_z_fit = ak.to_numpy(vtx_z_found)"
2023-09-18 12:12:50 +02:00
]
},
{
"cell_type": "code",
2023-09-19 09:58:54 +02:00
"execution_count": null,
2023-09-18 12:12:50 +02:00
"metadata": {},
"outputs": [],
"source": [
"\n"
]
2023-09-18 12:12:50 +02:00
},
{
"cell_type": "code",
"execution_count": 108,
2023-09-18 12:12:50 +02:00
"metadata": {},
"outputs": [
{
"data": {
"image/png": "iVBORw0KGgoAAAANSUhEUgAABkAAAAIlCAYAAACNejRdAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjcuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8pXeV/AAAACXBIWXMAAA9hAAAPYQGoP6dpAAEAAElEQVR4nOzde3xU5Z0/8M+QhBBoMpIgiZGotKJVAhaxRtBdsNykIrV0Gy2WglKli6JZoChlldDlInFFulBctZawIuKvr9VWeqGAVayLF4zSClqqlSIoIVbiBCTkxvn9MfPMzLlf5pyZcyaf9+uV12TOnDnnOWduz3Oe5/t9QpIkSSAiIiIiIiIiIiIiIsoiPTJdACIiIiIiIiIiIiIiIrexA4SIiIiIiIiIiIiIiLIOO0CIiIiIiIiIiIiIiCjrsAOEiIiIiIiIiIiIiIiyDjtAiIiIiIiIiIiIiIgo67ADhIiIiIiIiIiIiIiIsg47QIiIiIiIiIiIiIiIKOuwA4SIiIiIiIiIiIiIiLIOO0CIiIiIiIiIiIiIiCjrsAOEiIiIiIiIiIiIiIiyDjtAiCjtZsyYgfr6+kwXg4iIiIiIKLDYriIiIjLHDhAiIiIiIiIiIiIiIso67AA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xjW9gxIgR2Lx5M7q6ulBXV4ejR4/a2tc3v/lNVFdX4wc/+AH27duHe++9F++88w5ee+015OXlxdebMmUKbrzxRvzgBz/A559/DgB45513MHLkSJxzzjl48MEHUVZWht///ve488478Y9//AOLFy+W7au6uhrf/e53MWvWLGzfvh11dXXo6OjAjh07MHv2bMyfPx+bNm3C3XffjfPPPx9TpkzRLfekSZPQv39/rF+/HmPGjJE9Vl9fj0svvRRDhw51VE7lsQ4fPhzHjh3DmjVr8Mwzz8RDuy+++GLNPLd/+tOfcNVVV6Ffv3748Y9/jEGDBuHIkSN47rnn0N7ejvz8fMtlmjZtGt58800sW7YMF1xwAT777DO8+eab+PTTTy2+wkREREREcploV2mx2qYyqxN///vf162vm0lnewhwr03kl/aQFjfbQwDbREQUUBIRkU1btmyRAEh1dXWy5X/9618lANLGjRtVz7nmmmukPn36aP4tW7bM8r5feOEFCYD0i1/8Ir7siiuukPr37y8dP348vqyzs1OqrKyUBgwYIJ0+fTq+fPr06dK5556r2u7ixYul5K9EcV95jLNnz5Z69eol22ZVVZVUXl4utba2xpe1tLRIxcXFkpWvWbGvf/u3f5Mtf/LJJ2XnU6x33333qbYxYcIEacCAAVIkEpEtv+OOO6RevXpJx44dk23jwQcflK33la98RQIgPfPMM/FlHR0d0plnnilNmTLF9Bjmzp0rFRQUSJ999ll82TvvvCMBkNasWeO4nFrH+sADD0gApAMHDsiWr1+/XrX8a1/7mnTGGWdITU1NumW3WqYvfOELUk1NjfGJICIiIiKyKJPtKmXd2WqbykqdWK++ried7aHk7bjZJvJDe0iS1K+rm+0hSWKbiIiCiSmwiMi2++67D1/60pdw1113obOzM/43cOBAFBQU4IMPPlA953e/+x1OnDih+fejH/3IcVk+//xzvPbaa/iXf/kX2eionJwcTJs2DYcPH8b+/fsdb3/y5Mmy+0OHDsWpU6fQ1NQU3//u3bsxZcoU9OrVK75eYWEhrrvuOlv7uummm2T3q6urkZubixdeeEG2/Fvf+pbs/qlTp/D888/jm9/8Jnr37i17Tb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7P/kEQERERUbfmp3aV3TaVoFcntlpfV2J7yBo/tIcAtomIKDjYAUJEtnzpS1/C1VdfjX//93/HiRMnUFVVBUmScOTIEbzwwgu
2023-09-18 12:12:50 +02:00
"text/plain": [
"<Figure size 2000x600 with 4 Axes>"
]
},
"metadata": {},
"output_type": "display_data"
}
],
"source": [
"fig, ((ax0, ax1)) = plt.subplots(nrows=1, ncols=2, figsize=(20,6))\n",
"\n",
"a0 = ax0.hist2d(brem_vtx_z_found, brem_vtx_x_found, density=False, bins=300, cmap=plt.cm.jet, cmin=1)\n",
2023-09-19 09:58:54 +02:00
"ax0.set_xlabel(\"z [mm]\")\n",
"ax0.set_ylabel(\"x [mm]\")\n",
2023-09-18 12:12:50 +02:00
"ax0.set_title(r\"$e^\\pm$ found brem vertices\")\n",
"\n",
"plt.colorbar(a0[3],ax=ax0)\n",
"\n",
"a1 = ax1.hist2d(brem_vtx_z_lost, brem_vtx_x_lost, density=False, bins=300, cmap=plt.cm.jet, cmin=1)\n",
2023-09-19 09:58:54 +02:00
"ax1.set_xlabel(\"z [mm]\")\n",
"ax1.set_ylabel(\"x [mm]\")\n",
2023-09-18 12:12:50 +02:00
"ax1.set_title(r\"$e^\\pm$ lost brem vertices\")\n",
"#ax1.set(xlim=(0,4000), ylim=(-1000,1000))\n",
2023-09-18 12:12:50 +02:00
"\n",
"plt.colorbar(a1[3], ax=ax1)\n",
"\n",
"\"\"\"\n",
"z: VeLo - RICH1 - TT - Magnet - T1,T2,T3 - RICH2 - M1\n",
2023-09-18 12:12:50 +02:00
"B:\n",
"vertices of lost e photons are more densely concentrated around the beampipe, especially in the z range of the magnet\n",
"found: vertices are densely located @ or around the detectors, while there are no clusters in the z range of the magnet\n",
2023-09-18 12:12:50 +02:00
"\"\"\"\n",
"plt.show()"
]
},
{
"cell_type": "code",
"execution_count": 109,
"metadata": {},
"outputs": [],
"source": [
"#plot singular tracks by fitting brem vertices\n",
"vtx_z_found = tracked[\"brem_vtx_z\"]\n",
"vtx_z_found = vtx_z_found[tracked[\"brem_vtx_z_length\"]>3]\n",
"\n",
"vtx_x_found = tracked[\"brem_vtx_x\"]\n",
"vtx_x_found = vtx_x_found[tracked[\"brem_vtx_x_length\"]>3]\n",
"\n",
"vtx_z_lost = lost[\"brem_vtx_z\"]\n",
"vtx_z_lost = vtx_z_lost[lost[\"brem_vtx_z_length\"]>3]\n",
"\n",
"vtx_x_lost = lost[\"brem_vtx_x\"]\n",
"vtx_x_lost = vtx_x_lost[lost[\"brem_vtx_x_length\"]>3]\n",
"\n",
"def cubic_fit(x, a, b, c, d):\n",
" return (a + b*x + c*x**2 + d*x**3)\n",
"\n",
"def quint_fit(x, a, b, c, d, e, f):\n",
" return (a + b*x + c*x**2 + d*x**3 + e*x**4 + f*x**5)\n"
]
},
{
"cell_type": "code",
"execution_count": 110,
"metadata": {},
"outputs": [
{
"data": {
"image/png": "iVBORw0KGgoAAAANSUhEUgAABoQAAAIhCAYAAABnv9iQAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjcuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8pXeV/AAAACXBIWXMAAA9hAAAPYQGoP6dpAAC0nUlEQVR4nOzdd5wV1f3/8ffcvo1ll7JLE4QgqDRLpKhRpCvWGGsQ1Aj5WVETY4kCaiBqvopiNJqo2DUm2AkCgqgBFAsYezSAhb5sL3dvOb8/btl77967hba7l9eTx33MzJkzM2fm7C5z7mfOGcsYYwQAAAAAAAAAAIC0ZWvpAgAAAAAAAAAAAGDvIiAEAAAAAAAAAACQ5ggIAQAAAAAAAAAApDkCQgAAAAAAAAAAAGmOgBAAAAAAAAAAAECaIyAEAAAAAAAAAACQ5ggIAQAAAAAAAAAApDkCQgAAAAAAAAAAAGmOgBAAAAAAAAAAAECaIyAEpKHnn39ehx56qDIyMmRZltauXdvSRUpq5syZsiyr0XzPPPOM5s6du/cL1IBevXpp4sSJLVoGSdq5c6fOOeccde7cWZZl6bTTTkuZt7WUua2Y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j1kSHRnnzySV177bXq1q2b3G63vvnmG0nS0qVLNWrUKLVr106ZmZk6+uij9eabb8btI/Lz8cknn+gXv/hF9Jpfc8018vv9+uqrrzR+/Hjl5OSoV69euvPOOxst92GHHaZjjz22XnogEFC3bt10xhlnRNNqa2t1++23q3///nK73erUqZMuvPBCbd++PW7byDB6CxYs0GGHHSaPx6NZs2bJsixVVlbq8ccfj17byO9OqiHj3nvvPZ188snq0KGDPB6P+vTpU68X23//+1+dd9556ty5s9xutw4++GD9+c9/jssTDAZ1++23q1+/ftGfv0GDBunee+9NeW0iw5f4/X49+OCDcb8XkXWLFy/WRRddpE6dOikzM1Ner1fBYFB33nln9Dp17txZF1xwgX744Ye4/R9//PEaMGCAVq1apREjRigjI0O9evXSY489Jin0+3z44YcrMzNTAwcO1KJFi1KWtbHyStKWLVs0bdo0de/eXS6XSwceeKBmzZoV1yj96U9/qpNOOiluvwMHDpRlWVqzZk00bcGCBbIsS//5z39Slqcp1zzZEDHGGM2ePVs9e/aUx+PRkUceqSVLluj444+P+1sb+Zl59tlnddNNN6lr165q166dRo8era+++iquLEuWLNGpp56q7t27y+Px6Cc/+YmmTZumHTt2NHhNpdBQKRMnToz+fHXt2lUnnXRSvfoEAAB71qOPPqrBgwfL4/EoPz9fp59+ur744ou4PP/73/90zjnnqGvXrnK73SooKNCoUaOiQ0P16tVLn332mVasWBG9N2qol0tD96sN3f998803uvDCC9W3b19lZmaqW7duOvnkk5PeK5WUlOjaa69V7969o/eKJ554or788suU5fL5fJo8ebKys7Oj7cCqqir95je/0YEHHhi9RkceeaSeffbZRq/tp59+qlNPPVV5eXnyeDwaMmSIHn/88ej6xu4rUwkGg/rDH/6gAw44IHofl6pN89FHH+nMM89UXl5e9MtwY4weeOCBaJsxLy9PZ555pv73v//F7WNP30dv375dLpdLN998c711X375pSzLimvfNeW+uqF29E9/+lNJ0oUXXhi9tjNnzoy7PomeeeYZDR8+XNnZ2crOztaQIUP0yCOPxOVpSpty+/btmjp1qnr06BFt0x199NFaunRpyuvT0HcgU6ZMUXZ2tv7zn/9o7NixysnJ0ahRoyQ13v6OiHzn8dhjj0XbDkceeaRWr14tY4zuuusuHXjggcrOztYJJ5wQbUPvSnkl6YMPPtApp5yi/Px8eTweHXbYYfr73/8eXV9WViaHw6G77rormrZjxw7ZbDbl5ubG1fOVV16pTp06yRiTsjxNuebJviMqKSnRxRdfrPz8fGVnZ+ukk07S//73v7ifF6nuZ+azzz7Tueeeq9zcXBUUFOiiiy5SaWlp3D7//Oc/62c/+5k6d+6srKwsDRw4UHfeead8Pl+D11SSXnjhBQ0dOlS5ubnKzMxU7969ddFFFzW6HbDfMgDSxjfffGP+/Oc/G0lm9uzZZtWqVeazzz4zxhjz9NNPG0lm7Nix5qWXXjLPP/+8OeKII4zL5TLvvPNOdB+TJ082PXv2rLfvGTNmmMQ/GZJMr169zFFHHWX+/ve/m4ULF5rjjz/eOBwO8+2330bzLV261NjtdnPMMceYBQsWmBdeeMH89Kc/NQcccEC9fSb67LPPzNFHH20KCwvNqlWroh9jjFm/fr2RZLp162ZGjhxp/vGPf5jFixeb9evXm5KSEjNlyhTz5JNPmmXLlplFixaZ3/zmN8Zms5nHH3887hiTJk0ylmWZX/3qV+bll182//rXv8wf/vAHc++990bz9OzZ05x00knGGGOCwaC59tprjdPpNI899lg0z7PPPmskmSuuuMIsXrzYLF261PzlL38xV155ZYPnWF1dbQYNGmSysrLMn/70J7N48WJz8803G4fDYU488URjjDE1NTVm1apV5rDDDjO9e/eOXofS0tKU++3Zs6fp1q2bOeCAA8yjjz5qFi5caM4//3wjydx1113RfMuXL49exzPPPNO88sor5rXXXjNFRUXmySefNJZlmdNOO80sWLDAvPrqq2bixInGbrebpUuXRvcR+fno16+fue2228ySJUvMddddZySZyy+/3PTv39/cd999ZsmSJebCCy80ksw///nPBq/LvffeaySZr7/+Oi594cKFRpJ55ZVXjDHGBAIBM378eJOVlWVmzZpllixZYv72t7+Zbt26mUMOOcRUVVXFXZMuXbqY3r17m0cffdQsX77cvP/++2bVqlUmIyPDnHjiidFrG/ndiVyf5cuXR/ezaNEi43Q6zaBBg8z8+fPNsmX
"text/plain": [
"<Figure size 2000x600 with 2 Axes>"
]
},
"metadata": {},
"output_type": "display_data"
}
],
"source": [
"fig, ((ax0, ax1)) = plt.subplots(nrows=1, ncols=2, figsize=(20,6))\n",
"\n",
"for i in range(3,6):\n",
" popt, pcov = curve_fit(cubic_fit,ak.to_numpy(vtx_z_found[i,:]),ak.to_numpy(vtx_x_found[i,:]))\n",
" z_coord = np.linspace(vtx_z_found[i,0],12000,1000)\n",
" fit = cubic_fit(z_coord, popt[0], popt[1], popt[2], popt[3])\n",
" ax0.plot(z_coord, fit, \"-\", label=\"fit\"+str(i))\n",
"\n",
"ax0.legend()\n",
"ax0.set_xlabel(\"z [mm]\")\n",
"ax0.set_ylabel(\"x [mm]\")\n",
"ax0.set_title(\"found tracks of brem vertices from few signals\")\n",
"ax0.set(xlim=(0,12000), ylim=(-4000,4000))\n",
"ax0.grid()\n",
"\n",
"for i in range(3,6):\n",
" popt, pcov = curve_fit(cubic_fit,ak.to_numpy(vtx_z_lost[i,:]),ak.to_numpy(vtx_x_lost[i,:]))\n",
" z_coord = np.linspace(vtx_z_lost[i,0],12000,1000)\n",
" fit = cubic_fit(z_coord, popt[0], popt[1], popt[2], popt[3])\n",
" ax1.plot(z_coord, fit, \"-\", label=\"fit\"+str(i))\n",
"\n",
"ax1.legend()\n",
"ax1.set_xlabel(\"z [mm]\")\n",
"ax1.set_ylabel(\"x [mm]\")\n",
"ax1.set_title(\"lost tracks of brem vertices from few signals\")\n",
"ax1.set(xlim=(0,12000), ylim=(-4000,4000))\n",
"ax1.grid()\n",
"\n",
"plt.show()"
]
},
{
"cell_type": "code",
"execution_count": 111,
"metadata": {},
"outputs": [],
2023-09-19 09:58:54 +02:00
"source": [
"endvtx_x_found = tracked[\"all_endvtx_x\"]\n",
"endvtx_x_found = endvtx_x_found[tracked[\"all_endvtx_x_length\"]!=0]\n",
"endvtx_x_found = ak.to_numpy(ak.flatten(endvtx_x_found))\n",
"\n",
"endvtx_z_found = tracked[\"all_endvtx_z\"]\n",
"endvtx_z_found = endvtx_z_found[tracked[\"all_endvtx_z_length\"]!=0]\n",
"#print(ak.to_numpy(brem_vtx_z_found))\n",
"endvtx_z_found = ak.to_numpy(ak.flatten(endvtx_z_found))\n",
"\n",
"endvtx_x_lost = lost[\"all_endvtx_x\"]\n",
"endvtx_x_lost = endvtx_x_lost[lost[\"all_endvtx_x_length\"]!=0]\n",
"endvtx_x_lost = ak.to_numpy(ak.flatten(endvtx_x_lost))\n",
"\n",
"endvtx_z_lost = lost[\"all_endvtx_z\"]\n",
"endvtx_z_lost = endvtx_z_lost[lost[\"all_endvtx_z_length\"]!=0]\n",
"endvtx_z_lost = ak.to_numpy(ak.flatten(endvtx_z_lost))"
]
},
{
"cell_type": "code",
"execution_count": 112,
2023-09-19 09:58:54 +02:00
"metadata": {},
"outputs": [
{
"data": {
"image/png": "iVBORw0KGgoAAAANSUhEUgAABkAAAAIlCAYAAACNejRdAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjcuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8pXeV/AAAACXBIWXMAAA9hAAAPYQGoP6dpAADUd0lEQVR4nOz9f3wU5b3//z+XBEKksBIwCSlRaYtURa0HWwR9Fyi/pCK12mJLD5XW+uOgUgpoi5xWbAUULdJCtWo9xiMqfvs9pUeqRbFVPBb8FaWV1mJtUbESYzUmoDGQsJ8/yO7OZGfnx+7M7kzyuN9uuSWZveaaa2Y3u9eVuV6vK5ZIJBICAAAAAAAAAADoRnoVuwEAAAAAAAAAAAB+4wYIAAAAAAAAAADodrgBAgAAAAAAAAAAuh1ugAAAAAAAAAAAgG6HGyAAAAAAAAAAAKDb4QYIAAAAAAAAAADodrgBAgAAAAAAAAAAuh1ugAAAAAAAAAAAgG6HGyAAAAAAAAAAAKDb4QYIAAAAAAAAAADodrgBAiA05syZo7q6umI3AwAAAAAii3EVAABp3AABAAAAAAAAAADdDjdAAHQb999/v44//niVl5crFotp+/btxW6SpaVLlyoWixW7GSlha48kbd26VUuXLtV7772X8VhdXZ1isZheffXVgrcLAAAA6M6C7Gvb9fGLLUpjIsZDAOANN0AAFNX06dN1+OGH6/DDD9e9996ruXPnpn6/7rrrXNfz9ttva/bs2fr4xz+uTZs2adu2bTrmmGMCbDmCtHXrVl1zzTWWg6MzzzxT27Zt05AhQwrfMAAAACCE/BpXBcmuj49M2a4X4yEA8Ka02A0A0LP95je/Sf08Z84cjR8/XnPmzPFcz8svv6wDBw7o3//93zVu3DgfW4hC+uCDD3TYYYfZljniiCN0xBFHFKhFAAAAQPj5Na5C8TmNiRgPAYA3RIAA8N2TTz6pKVOmKB6Pa+DAgTrzzDP1t7/9LbDjzZkzR6effrok6bzzzlMsFtP48eNTbZk4caL69++vww47TGPHjtWDDz5oWcfRRx+dsb1rKHTy9z//+c/66le/qng8rqqqKn3zm99Uc3Nzxv4PPvigPvWpT6msrEzDhg3TjTfe6Onc/va3v2nWrFmqrKxUWVmZjj32WP3sZz+zbKObNuXanl//+teKxWL63e9+l/HYLbfcolgspj/96U85tfv555/Xl770JQ0cOFAf//jHtXTpUl1xxRWSpGHDhikWiykWi+nxxx+XZB3y/de//lVf/epXVVVVpbKyMh155JH6+te/rra2Ns/X8+2339ZFF12k2tpalZWV6YgjjtBpp52mRx991NW1AgAAAPxQ6HGVXTucxlROfWinPn42fo+HpMKMidy029h2L2OibCmw3IyJGA8B6ImIAAHgq6VLl+pHP/qR5syZo/nz56u1tVXXXHONJk6cqL/85S/6yEc+knXfurq6nI75/e9/X5/5zGd06aWXavny5ZowYYIGDBigLVu2aPLkyTrxxBN1xx13qKysTDfffLPOOuss3XfffTrvvPNyPEvp3HPP1XnnnacLLrhAL774ohYvXixJ+q//+q9Umd/97nf6whe+oDFjxmj9+vXq6OjQypUr9dZbb7k6xl/+8heNHTtWRx55pH784x+rurpaDz/8sObNm6d//etfu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1tramjn/w4EFVV1dn7Gu1rat33nlH7e3tWrNmTca1/PznPy9J+te//uW6Tfm2R5KOP/54ffrTn9add94pSero6NC6dev0hS98QRUVFTm32+o5cqupqUkdHR0aOnSobTkv7br//vt1/vnn6xe/+IXGjBmjiooKff3rX1dDQ0PO7QQAAADcCNO4ysuYyu8+tN/joeT5BD0myqXdUvBjIsZDAHoy1gAB4Ivdu3dLkm666abUguRdffzjHy9YewYOHKhevXppz549GY+9+eabkqTBgwentvXt2zdjwWzJunPq9vixWMyyk+im4zhw4MDUzKpLL73UssywYcMK1p6kb3zjG5o7d65eeukl/eMf/9CePXv0jW98I692GxeZ96qiokIlJSV64403bMt5adfgwYO1evVqrV69Wq+//roeeOABfe9731NjY6M2bdqUc1sBAAAAJ2EaV3kZU/ndh/Z7PJSsM+gxUa7tDnpMxHgIQE/GDRAAvkhGAMRiMZ1yyilFbo3Ur18/jR49Wr/61a904403qry8XJJ08OBBrVu3TkOHDtUxxxyTKn/00UersbFRb731lqqqqiRJ+/fv18MPP5zz8T/zmc/oV7/6lW644YZUiPXevXu1ceNGx/0PO+wwTZgwQS+88IJOPPFE9enTJ6d2+NWepK9+9atasGCB6urq9I9//EMf/ehHNWXKFN/b3XW2Vjbl5eUaN26cfvnLX2rZsmWmm1pGubbryCOP1GWXXabf/e53+sMf/uDtJAAAAACPwjSu8jqmSsrWh3bbx5f8Hw8lzyfoMZGf7fZzTMR4CEBPxg0QAL74+Mc/rgkTJug///M/tW/fPo0ePVqJREJ79uzRY489pvPPP1/jx48vaJtWrFihyZMna8KECVq0aJH69Omjm2++WTt27NB9991nmmVz3nnn6Qc/+IG+8pWv6IorrtCHH36on/70p+ro6Mj5+D/60Y90xhlnaPLkyVq4cKE6Ojp0/fXXq1+/fnr33Xcd9//JT36i008/Xf/v//0//cd//IeOPvpo7d27V6+88oo2btyo3//+9wVtjyQdfvjh+uIXv6i6ujq99957WrRokXr1MmdT9KPdJ5xwQqqu888/X71799aIESPUv3//jLKrVq3S6aefrtGjR+t73/uePvGJT+itt97SAw88oFtvvTW1j5t2NTc3a8KECZo1a5Y++clPqn///nr22We1adMmnXPOOa6uEQAAAJCrsI2r3Iyp3PahvfTxk+X8HA9JhRkT+dXubNfLips
2023-09-19 09:58:54 +02:00
"text/plain": [
"<Figure size 2000x600 with 4 Axes>"
]
},
"metadata": {},
"output_type": "display_data"
}
],
"source": [
"fig, ((ax0, ax1)) = plt.subplots(nrows=1, ncols=2, figsize=(20,6))\n",
"\n",
"a0 = ax0.hist2d(endvtx_z_found, endvtx_x_found, density=False, bins=500, cmap=plt.cm.jet, cmin=1)\n",
2023-09-19 09:58:54 +02:00
"ax0.set_xlabel(\"z [mm]\")\n",
"ax0.set_ylabel(\"x [mm]\")\n",
"ax0.set_title(r\"$e^\\pm$ found end vertices\")\n",
"ax0.set(xlim=(0,12000), ylim=(-4000,4000))\n",
2023-09-19 09:58:54 +02:00
"\n",
"plt.colorbar(a0[3],ax=ax0)\n",
"\n",
"a1 = ax1.hist2d(endvtx_z_lost, endvtx_x_lost, density=False, bins=500, cmap=plt.cm.jet, cmin=1)\n",
2023-09-19 09:58:54 +02:00
"ax1.set_xlabel(\"z [mm]\")\n",
"ax1.set_ylabel(\"x [mm]\")\n",
"ax1.set_title(r\"$e^\\pm$ lost end vertices\")\n",
"ax1.set(xlim=(0,12000), ylim=(-4000,4000))\n",
2023-09-19 09:58:54 +02:00
"\n",
"plt.colorbar(a1[3], ax=ax1)\n",
"\n",
"\"\"\"\n",
"z: VeLo - RICH1 - TT - Magnet - T1,T2,T3 - RICH2 - M1\n",
"B:\n",
"vertices of lost e photons are more densely concentrated around the beampipe, especially in the z range of the magnet\n",
"found: vertices are densely located @ or around the detectors, while there are no clusters in the z range of the magnet\n",
"\"\"\"\n",
"plt.show()"
]
},
{
"cell_type": "code",
"execution_count": 113,
2023-09-19 09:58:54 +02:00
"metadata": {},
"outputs": [],
"source": [
"# try to plot trajectories using all tracker hits (Velo, UT, SciFi)\n",
"\n",
"velo_x_found = tracked[\"velo_hit_pos_x\"]\n",
"velo_z_found = tracked[\"velo_hit_pos_z\"]\n",
"ut_x_found = tracked[\"ut_hit_pos_x\"]\n",
"ut_z_found = tracked[\"ut_hit_pos_z\"]\n",
"scifi_x_found = tracked[\"scifi_hit_pos_x\"]\n",
"scifi_z_found = tracked[\"scifi_hit_pos_z\"]\n",
"\n",
"tracker_x_found = ak.concatenate([velo_x_found,ut_x_found,scifi_x_found], axis=1)\n",
"tracker_z_found = ak.concatenate([velo_z_found,ut_z_found,scifi_z_found], axis=1)\n",
"\n",
"velo_x_lost = lost[\"velo_hit_pos_x\"]\n",
"velo_z_lost = lost[\"velo_hit_pos_z\"]\n",
"ut_x_lost = lost[\"ut_hit_pos_x\"]\n",
"ut_z_lost = lost[\"ut_hit_pos_z\"]\n",
"scifi_x_lost = lost[\"scifi_hit_pos_x\"]\n",
"scifi_z_lost = lost[\"scifi_hit_pos_z\"]\n",
"\n",
"tracker_x_lost = ak.concatenate([velo_x_lost,ut_x_lost,scifi_x_lost], axis=1)\n",
"tracker_z_lost = ak.concatenate([velo_z_lost,ut_z_lost,scifi_z_lost], axis=1)"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": []
},
{
"cell_type": "code",
"execution_count": 114,
2023-09-19 09:58:54 +02:00
"metadata": {},
"outputs": [
{
"data": {
"image/png": "iVBORw0KGgoAAAANSUhEUgAABoQAAAIhCAYAAABnv9iQAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjcuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8pXeV/AAAACXBIWXMAAA9hAAAPYQGoP6dpAAEAAElEQVR4nOzddXRUx9vA8e/GXYkiMeKCu0NxSmlLaUux+q8uVGhxKVKKtEipGxQoLQVKcXf3hLgT4m6bze68f+RlyxJPgQCdzzk9nNzce2fu3TvbefLcmVEIIQSSJEmSJEmSJEmSJEmSJEmSJEnSA0uvsSsgSZIkSZIkSZIkSZI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6dOni1u/GgDh7u4uOnbsKH777Texbds20bt3b2FgYCBiYmK0++3Zs0fo6+uL7t27i40bN4oNGzaIDh06iBYtWlQ6561CQ0NFt27dhLOzszh+/Lj2PyGEiIuLE4Bo2rSp6NOnj/j999/Frl27RFxcnMjNzRUTJkwQv/zyi9i3b5/YsWOHeO+994Senp746aefdMoYO3asUCgU4oUXXhCbN28W27dvF5988on4/PPPtfu4ubmJoUOHCiGE0Gg0YuLEicLQ0FD88MMP2n3Wrl0rAPHGG2+IXbt2iT179ohVq1aJN998s9rry8vLE8ePHxfOzs6iW7du2usrLS0V+/fv117fyJEjxZYtW8TWrVtFVlaWmDt3rgDE008/Lf7++2/x888/C09PT2FtbS0iIyN1Pk8jIyPh7+8vPv/8c7F7927x7LP
2023-09-19 09:58:54 +02:00
"text/plain": [
"<Figure size 2000x600 with 2 Axes>"
]
},
"metadata": {},
"output_type": "display_data"
}
],
"source": [
"fig, ((ax0, ax1)) = plt.subplots(nrows=1, ncols=2, figsize=(20,6))\n",
"\n",
"nstart=0\n",
"nend=200\n",
"\n",
"for i in range(nstart,nend):\n",
2023-09-19 09:58:54 +02:00
" popt, pcov = curve_fit(cubic_fit,ak.to_numpy(tracker_z_found[i,:]),ak.to_numpy(tracker_x_found[i,:]))\n",
" z_coord = np.linspace(tracker_z_found[i,0],14000,1000)\n",
2023-09-19 09:58:54 +02:00
" fit = cubic_fit(z_coord, popt[0], popt[1], popt[2], popt[3])\n",
" ax0.plot(z_coord, fit, \"-\", label=\"fit \"+str(i), lw=0.5)\n",
" ax0.errorbar(ak.to_numpy(tracker_z_found[i,:]),ak.to_numpy(tracker_x_found[i,:]),fmt=\".\",ms=3)\n",
2023-09-19 09:58:54 +02:00
"\n",
"ax0.vlines(3000, -4000,4000, lw=1, ls=\":\", color=\"red\")\n",
"ax0.vlines(7500, -4000,4000, lw=1, ls=\":\", color=\"red\")\n",
"ax0.set_xticks(np.arange(0,14000,1000) , minor=True)\n",
"ax0.set_yticks(np.arange(-4000,4000,500), minor=True)\n",
2023-09-19 09:58:54 +02:00
"ax0.set_xlabel(\"z [mm]\")\n",
"ax0.set_ylabel(\"x [mm]\")\n",
"ax0.set_title(\"found tracks from detector hits from few signals\")\n",
"ax0.set(xlim=(0,14000), ylim=(-4000,4000))\n",
2023-09-19 09:58:54 +02:00
"ax0.grid()\n",
"\n",
"for i in range(nstart,nend):\n",
2023-09-19 09:58:54 +02:00
" popt, pcov = curve_fit(cubic_fit,ak.to_numpy(tracker_z_lost[i,:]),ak.to_numpy(tracker_x_lost[i,:]))\n",
" z_coord = np.linspace(tracker_z_lost[i,0],14000,1000)\n",
2023-09-19 09:58:54 +02:00
" fit = cubic_fit(z_coord, popt[0], popt[1], popt[2], popt[3])\n",
" ax1.plot(z_coord, fit, \"-\", label=\"fit \"+str(i), lw=0.5)\n",
" ax1.errorbar(ak.to_numpy(tracker_z_lost[i,:]),ak.to_numpy(tracker_x_lost[i,:]),fmt=\".\",ms=3)\n",
2023-09-19 09:58:54 +02:00
"\n",
"ax1.vlines(3000, -4000,4000, lw=1, ls=\":\", color=\"red\")\n",
"ax1.vlines(7500, -4000,4000, lw=1, ls=\":\", color=\"red\")\n",
"ax1.set_xticks(np.arange(0,14000,1000) , minor=True)\n",
"ax1.set_yticks(np.arange(-4000,4000,500), minor=True)\n",
2023-09-19 09:58:54 +02:00
"ax1.set_xlabel(\"z [mm]\")\n",
"ax1.set_ylabel(\"x [mm]\")\n",
"ax1.set_title(\"lost tracks from detector hits from few signals\")\n",
"ax1.set(xlim=(0,14000), ylim=(-4000,4000))\n",
2023-09-19 09:58:54 +02:00
"ax1.grid()\n",
"\n",
"\n",
"\"\"\"\n",
"the trajectories between the velo and tt should be linear, which cannot be plotted accurately using a single fit.\n",
"lost tracks diverge more severely.\n",
"\n",
"electrons and photons will be stopped by the ECAL which serves to measure the particles energy\n",
"\n",
"\"\"\"\n",
"\n",
"\n",
"\n",
2023-09-19 09:58:54 +02:00
"plt.show()"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": []
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": []
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": []
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": []
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": []
},
2023-09-19 09:58:54 +02:00
{
"cell_type": "code",
"execution_count": 16,
"metadata": {},
"outputs": [
{
"data": {
"text/plain": [
"{'all_endvtx_types_length': 11,\n",
" 'all_endvtx_types': [101.0,\n",
" 101.0,\n",
" 101.0,\n",
" 101.0,\n",
" 101.0,\n",
" 101.0,\n",
" 101.0,\n",
" 101.0,\n",
" 101.0,\n",
" 101.0,\n",
" 0.0],\n",
" 'all_endvtx_x_length': 11,\n",
" 'all_endvtx_x': [19.496400833129883,\n",
" 24.957000732421875,\n",
" 32.490699768066406,\n",
" 34.14419937133789,\n",
" 34.6599006652832,\n",
" 36.427101135253906,\n",
" -1914.992431640625,\n",
" -2413.033203125,\n",
" -3782.947998046875,\n",
" -3786.80810546875,\n",
" -3819.826904296875],\n",
" 'all_endvtx_y_length': 11,\n",
" 'all_endvtx_y': [-20.370500564575195,\n",
" -26.043100357055664,\n",
" -33.85060119628906,\n",
" -35.53160095214844,\n",
" -36.069400787353516,\n",
" -37.92850112915039,\n",
" -504.0671081542969,\n",
" -533.6621704101562,\n",
" -598.8317260742188,\n",
" -599.1124877929688,\n",
" -593.3890991210938],\n",
" 'all_endvtx_z_length': 11,\n",
" 'all_endvtx_z': [399.7018127441406,\n",
" 500.7049865722656,\n",
" 637.5723266601562,\n",
" 667.4852905273438,\n",
" 677.0195922851562,\n",
" 709.4874877929688,\n",
" 8576.556640625,\n",
" 9281.2119140625,\n",
" 11183.1640625,\n",
" 11188.4541015625,\n",
" 11237.0966796875],\n",
" 'brem_photons_pe_length': 10,\n",
" 'brem_photons_pe': [2469.182861328125,\n",
" 169.8916473388672,\n",
" 223.71347045898438,\n",
" 388.2983703613281,\n",
" 3228.4228515625,\n",
" 809.4715576171875,\n",
" 171.57342529296875,\n",
" 223.80494689941406,\n",
" 178.85166931152344,\n",
" 793.921142578125],\n",
" 'brem_photons_px_length': 10,\n",
" 'brem_photons_px': [133.6999969482422,\n",
" 9.329999923706055,\n",
" 12.489999771118164,\n",
" 20.93000030517578,\n",
" 175.22000122070312,\n",
" 43.81999969482422,\n",
" -98.19999694824219,\n",
" -129.77000427246094,\n",
" -106.12000274658203,\n",
" -465.2200012207031],\n",
" 'brem_photons_py_length': 10,\n",
" 'brem_photons_py': [-137.9199981689453,\n",
" -9.65999984741211,\n",
" -12.579999923706055,\n",
" -21.809999465942383,\n",
" -183.27999877929688,\n",
" -47.79999923706055,\n",
" -6.090000152587891,\n",
" -7.429999828338623,\n",
" -5.800000190734863,\n",
" -36.66999816894531],\n",
" 'brem_photons_pz_length': 10,\n",
" 'brem_photons_pz': [2461.699951171875,\n",
" 169.36000061035156,\n",
" 223.00999450683594,\n",
" 387.1199951171875,\n",
" 3218.449951171875,\n",
" 806.8699951171875,\n",
" 140.55999755859375,\n",
" 182.19000244140625,\n",
" 143.85000610351562,\n",
" 642.2899780273438],\n",
" 'brem_vtx_x_length': 10,\n",
" 'brem_vtx_x': [19.496400833129883,\n",
" 24.957000732421875,\n",
" 32.490699768066406,\n",
" 34.14419937133789,\n",
" 34.6599006652832,\n",
" 36.427101135253906,\n",
" -1914.992431640625,\n",
" -2413.033203125,\n",
" -3782.947998046875,\n",
" -3786.80810546875],\n",
" 'brem_vtx_y_length': 10,\n",
" 'brem_vtx_y': [-20.370500564575195,\n",
" -26.043100357055664,\n",
" -33.85060119628906,\n",
" -35.53160095214844,\n",
" -36.069400787353516,\n",
" -37.92850112915039,\n",
" -504.0671081542969,\n",
" -533.6621704101562,\n",
" -598.8317260742188,\n",
" -599.1124877929688],\n",
" 'brem_vtx_z_length': 10,\n",
" 'brem_vtx_z': [399.7018127441406,\n",
" 500.7049865722656,\n",
" 637.5723266601562,\n",
" 667.4852905273438,\n",
" 677.0195922851562,\n",
" 709.4874877929688,\n",
" 8576.556640625,\n",
" 9281.2119140625,\n",
" 11183.1640625,\n",
" 11188.4541015625],\n",
" 'endvtx_type': 0,\n",
" 'endvtx_x': nan,\n",
" 'endvtx_y': nan,\n",
" 'endvtx_z': nan,\n",
" 'energy': 9355.866625028413,\n",
" 'eta': 3.237728027535365,\n",
" 'event_count': 2,\n",
" 'fromB': True,\n",
" 'fromD': False,\n",
" 'fromDecay': True,\n",
" 'fromHadInt': False,\n",
" 'fromPV': False,\n",
" 'fromPairProd': False,\n",
" 'fromSignal': True,\n",
" 'fromStrange': False,\n",
" 'isElectron': True,\n",
" 'isKaon': False,\n",
" 'isMuon': False,\n",
" 'isPion': False,\n",
" 'isProton': False,\n",
" 'lost': False,\n",
" 'lost_in_track_fit': False,\n",
" 'match_fraction': 1.0,\n",
" 'mcp_idx': 5488,\n",
" 'mother_id': 511,\n",
" 'mother_key': 5479,\n",
" 'originvtx_type': 2,\n",
" 'originvtx_x': -0.0663,\n",
" 'originvtx_y': -0.0023,\n",
" 'originvtx_z': 40.3966,\n",
" 'p': 9355.866611073503,\n",
" 'phi': -0.8090232566094933,\n",
" 'pid': -11,\n",
" 'pt': 733.3612464536151,\n",
" 'px': 506.17,\n",
" 'py': -530.67,\n",
" 'pz': 9327.08,\n",
" 'scifi_hit_pos_x_length': 13,\n",
" 'scifi_hit_pos_x': [-1402.2215576171875,\n",
" -1448.5460205078125,\n",
" -1495.479736328125,\n",
" -1542.3804931640625,\n",
" -1865.9482421875,\n",
" -1914.599853515625,\n",
" -1915.0545654296875,\n",
" -1963.8216552734375,\n",
" -2012.78173828125,\n",
" -2349.04052734375,\n",
" -2398.658935546875,\n",
" -2448.573486328125,\n",
" -2498.376220703125],\n",
" 'scifi_hit_pos_y_length': 13,\n",
" 'scifi_hit_pos_y': [-470.2232666015625,\n",
" -473.55914306640625,\n",
" -476.8390197753906,\n",
" -480.12762451171875,\n",
" -501.0274963378906,\n",
" -504.04315185546875,\n",
" -504.0709228515625,\n",
" -507.0843200683594,\n",
" -510.0830383300781,\n",
" -530.0570068359375,\n",
" -532.8589477539062,\n",
" -535.61572265625,\n",
" -538.2548217773438],\n",
" 'scifi_hit_pos_z_length': 13,\n",
" 'scifi_hit_pos_z': [7824.40576171875,\n",
" 7894.1943359375,\n",
" 7964.38330078125,\n",
" 8034.171875,\n",
" 8506.294921875,\n",
" 8575.99609375,\n",
" 8576.6455078125,\n",
" 8646.2744140625,\n",
" 8716.0634765625,\n",
" 9191.1904296875,\n",
" 9260.98046875,\n",
" 9331.171875,\n",
" 9400.962890625],\n",
" 'track_p': 1931.9397828451663,\n",
" 'track_pt': 151.36962154532284,\n",
" 'tx': 0.05426886013629132,\n",
" 'ty': -0.056895620065443846,\n",
" 'ut_hit_pos_x_length': 4,\n",
" 'ut_hit_pos_x': [112.31356048583984,\n",
" 114.4996337890625,\n",
" 122.83889770507812,\n",
" 124.72588348388672],\n",
" 'ut_hit_pos_y_length': 4,\n",
" 'ut_hit_pos_y': [-135.26077270507812,\n",
" -138.64544677734375,\n",
" -152.51470947265625,\n",
" -155.91305541992188],\n",
" 'ut_hit_pos_z_length': 4,\n",
" 'ut_hit_pos_z': [2313.153564453125,\n",
" 2368.153564453125,\n",
" 2593.153564453125,\n",
" 2648.153564453125],\n",
" 'velo_hit_pos_x_length': 10,\n",
" 'velo_hit_pos_x': [3.2025206089019775,\n",
" 4.559732437133789,\n",
" 5.917426109313965,\n",
" 7.274953365325928,\n",
" 8.638668060302734,\n",
" 10.008487701416016,\n",
" 11.378168106079102,\n",
" 12.745656967163086,\n",
" 15.399646759033203,\n",
" 19.47773551940918],\n",
" 'velo_hit_pos_y_length': 10,\n",
" 'velo_hit_pos_y': [-3.429784059524536,\n",
" -4.8510894775390625,\n",
" -6.275496482849121,\n",
" -7.6981940269470215,\n",
" -9.124002456665039,\n",
" -10.54817008972168,\n",
" -11.963949203491211,\n",
" -13.374946594238281,\n",
" -16.1297550201416,\n",
" -20.351228713989258],\n",
" 'velo_hit_pos_z_length': 10,\n",
" 'velo_hit_pos_z': [100.64099884033203,\n",
" 125.64099884033203,\n",
" 150.64100646972656,\n",
" 175.64100646972656,\n",
" 200.64100646972656,\n",
" 225.64100646972656,\n",
" 250.64100646972656,\n",
" 275.6409912109375,\n",
" 324.3590087890625,\n",
" 399.3590087890625],\n",
" 'velo_track_idx': 143,\n",
" 'velo_track_tx': 0.054571494460105896,\n",
" 'velo_track_ty': -0.056447889655828476,\n",
" 'velo_track_x': 39.710758209228516,\n",
" 'velo_track_y': -41.2618293762207,\n",
" 'velo_track_z': 770.0}"
]
},
"execution_count": 16,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"tracked[1].tolist()"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": []
}
],
"metadata": {
"kernelspec": {
"display_name": "env1",
"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.11.5"
},
"orig_nbformat": 4
},
"nbformat": 4,
"nbformat_minor": 2
}