Commit 5814b0df authored by Michal Maciejewski's avatar Michal Maciejewski
Browse files

Integrated busbar/magnet resistance query and computation

parent b6e106a4
This diff is collapsed.
This diff is collapsed.
......@@ -133,20 +133,15 @@
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"deletable": false,
"editable": false
},
"outputs": [],
"outputs": [],
"source": [
"circuit_type = 'IT'\n",
"hwc_test = 'PNO.D16'\n",
"hwc_test_history_df = pd.read_csv('/eos/project/l/lhcsm/hwc/IT/hwc_test_history.csv')\n",
"hwcb = HwcBrowser(hwc_test_history_df, circuit_type, hwc_test)\n",
"display(hwcb.widget)"
"source": [
"circuit_type = 'IT'\n",
"hwc_test = 'PNO.D16'\n",
"hwc_test_history_df = pd.read_csv('/eos/project/l/lhcsm/hwc/IT/hwc_test_history.csv')\n",
"hwcb = HwcBrowser(hwc_test_history_df, circuit_type, hwc_test)\n",
"display(hwcb.widget)"
......@@ -164,127 +159,26 @@
"execution_count": null,
"metadata": {
"deletable": false,
"tags": [
"skip_output"
"circuit_name = hwcb.get_circuit_name()\n",
"t_start = hwcb.get_start_time()\n",
"t_end = hwcb.get_end_time()\n",
"author = hwcb.get_author()\n",
"is_automatic = hwcb.is_automatic_mode()\n",
"\n",
"it_query = ItCircuitQuery(circuit_type, circuit_name)\n",
"\n",
"with Timer():\n",
" # PC - NXCALS\n",
" i_meas_rqx_nxcals_df, i_meas_rtqx1_nxcals_df, i_meas_rtqx2_nxcals_df = QueryBuilder().with_nxcals(spark) \\\n",
" .with_duration(t_start=t_start, t_end=t_end) \\\n",
" .with_circuit_type(circuit_type) \\\n",
" .with_metadata(circuit_name=circuit_name, system='PC', signal='I_MEAS') \\\n",
" .signal_query() \\\n",
" .synchronize_time() \\\n",
" .convert_index_to_sec().dfs\n",
" i_meas_rqx_nxcals_df.rename(columns={\"I_MEAS\": \"I_MEAS_RQX\"}, inplace=True)\n",
" i_meas_rtqx1_nxcals_df.rename(columns={\"I_MEAS\": \"I_MEAS_RTQX1\"}, inplace=True)\n",
" i_meas_rtqx2_nxcals_df.rename(columns={\"I_MEAS\": \"I_MEAS_RTQX2\"}, inplace=True)\n",
" \n",
" # I_Q1 = I_RQX + I_RTQX1\n",
" i_meas_q1_nxcals_df = SignalTransformationBuilder.add_two_dataframes(i_meas_rqx_nxcals_df, i_meas_rtqx1_nxcals_df, col_name='I_MEAS_Q1')\n",
" # I_Q2 = I_RQX + I_RTQX2\n",
" i_meas_q2_nxcals_df = SignalTransformationBuilder.add_two_dataframes(i_meas_rqx_nxcals_df, i_meas_rtqx2_nxcals_df, col_name='I_MEAS_Q2')\n",
" # I_Q3 = I_RQX\n",
" i_meas_q3_nxcals_df = pd.DataFrame(index=i_meas_rqx_nxcals_df.index, data=i_meas_rqx_nxcals_df.values, columns=['I_MEAS_Q3'])\n",
"\n",
" # PC - PM\n",
" source_timestamp_fgc_df = QueryBuilder().with_pm() \\\n",
" .with_duration(t_start=t_start, t_end=t_end) \\\n",
" .with_circuit_type(circuit_type) \\\n",
" .with_metadata(circuit_name=circuit_name, system='PC', source='*') \\\n",
" .event_query().df\n",
"\n",
" timestamp_fgc = min(source_timestamp_fgc_df['timestamp'].values)\n",
]
},
" # QDS - U_RES\n",
" i_meas_raw_dfs = QueryBuilder().with_nxcals(spark) \\\n",
" .with_duration(t_start=t_start, t_end=t_end) \\\n",
" .with_circuit_type(circuit_type) \\\n",
" .with_metadata(circuit_name=circuit_name, system='PC', signal='I_MEAS') \\\n",
" .signal_query() \\\n",
" .dfs\n",
" \n",
" plateau_starts = []\n",
" plateau_ends = []\n",
" for i_meas_raw_df in i_meas_raw_dfs:\n",
" if i_meas_raw_df.max().values[0] > 100:\n",
" plateau_start, plateau_end = find_plateau_start_and_end(i_meas_raw_df, i_meas_threshold=0,\n",
" min_duration_in_sec=10)\n",
" plateau_starts.append(plateau_start)\n",
" plateau_ends.append(plateau_end)\n",
"\n",
" plateau_start, plateau_end = extract_intersecting_plateaus(plateau_ends, plateau_starts)\n",
"\n",
" plateau_start = np.array(plateau_start)\n",
" plateau_end = np.array(plateau_end)\n",
"\n",
" ramp_up_start, ramp_up_end = find_start_end_of_the_longest_ramp_up(plateau_start, plateau_end)\n",
"\n",
" def translate(timestamp):\n",
" mask_plateau = (timestamp >= plateau_start) & (timestamp <= plateau_end)\n",
" index_plateau = np.where(mask_plateau == True)[0]\n",
"\n",
"outputs": [],
"source": [
"circuit_name = hwcb.get_circuit_name()\n",
"t_start = hwcb.get_start_time()\n",
"t_end = hwcb.get_end_time()\n",
"author = hwcb.get_author()\n",
"is_automatic = hwcb.is_automatic_mode()\n",
" if (timestamp > ramp_up_start) and (timestamp < ramp_up_end):\n",
" return 0\n",
"\n",
" return -1\n",
"\n",
" translate_udf = udf(translate, IntegerType())\n",
" \n",
" u_res_dfs = QueryBuilder().with_nxcals(spark) \\\n",
" .with_duration(t_start=t_start, t_end=t_end) \\\n",
" .with_circuit_type(circuit_type) \\\n",
" .with_metadata(circuit_name=circuit_name, system='QDS', signal=['U_RES_Q1', 'U_RES_Q2', 'U_RES_Q3']) \\\n",
" .signal_query() \\\n",
" .synchronize_time() \\\n",
" .convert_index_to_sec().dfs\n",
" \n",
" i_meas_feature_df = QueryBuilder() \\\n",
" .with_nxcals(spark) \\\n",
" .with_duration(t_start=t_start, t_end=t_end) \\\n",
" .with_circuit_type(circuit_type) \\\n",
"\n",
"it_query = ItCircuitQuery(circuit_type, circuit_name)\n",
"it_analysis = ItCircuitAnalysis(circuit_type, results_table=None, is_automatic=is_automatic)\n",
"\n",
" .feature_query(['mean', 'std'], function=translate_udf) \\\n",
" .sort_values(by='class') \\\n",
" .df\n",
" \n",
" u_mag_feature_df = QueryBuilder() \\\n",
" .with_nxcals(spark) \\\n",
" .with_duration(t_start=t_start, t_end=t_end) \\\n",
" .with_circuit_type(circuit_type) \\\n",
" .with_metadata(circuit_name=circuit_name, system='QDS', signal=['U_RES_Q1', 'U_RES_Q2', 'U_RES_Q3']) \\\n",
" .feature_query(['mean', 'std'], function=translate_udf) \\\n",
" .correct_voltage_sign() \\\n",
" .sort_values(by='class') \\\n",
" .df\n",
" \n",
" it_analysis = ItCircuitAnalysis(circuit_type, results_table=None, is_automatic=is_automatic)\n",
" r_res_df = it_analysis.calculate_resistance(i_meas_feature_df, u_mag_feature_df)\n",
" \n",
" # DFB\n",
" tt893_nxcals_dfs = QueryBuilder().with_nxcals(spark) \\\n",
" .with_duration(t_start=t_start, t_end=t_end) \\\n",
" .with_circuit_type(circuit_type) \\\n",
" .with_metadata(circuit_name=circuit_name, system='LEADS_NXCALS_WINCCOA', signal='TT893') \\\n",
" .signal_query()\\\n",
" .synchronize_time() \\\n",
" .convert_index_to_sec() \\\n",
" .filter_median() \\\n",
" .dfs\n",
" \n",
" tt891a_nxcals_dfs = QueryBuilder().with_nxcals(spark) \\\n",
"with Timer():\n",
" # PC - NXCALS\n",
" i_meas_rqx_nxcals_df, i_meas_rtqx1_nxcals_df, i_meas_rtqx2_nxcals_df = it_query.query_signal_nxcals(t_start, t_end, system='PC', signal_names='I_MEAS', spark=spark)\n",
" i_meas_rqx_nxcals_df.rename(columns={\"I_MEAS\": \"I_MEAS_RQX\"}, inplace=True)\n",
" i_meas_rtqx1_nxcals_df.rename(columns={\"I_MEAS\": \"I_MEAS_RTQX1\"}, inplace=True)\n",
" i_meas_rtqx2_nxcals_df.rename(columns={\"I_MEAS\": \"I_MEAS_RTQX2\"}, inplace=True)\n",
" \n",
" # I_Q1 = I_RQX + I_RTQX1\n",
......@@ -466,11 +360,11 @@
"*CRITERIA*\n",
"- Check if R_max < 5 nOhm\n",
"\n",
"*GRAPHS*: \n",
"- t = 0 s corresponds to the start of the test"
"*GRAPHS*: \n",
 
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
......@@ -484,11 +378,11 @@
" .with_ylabel(ylabel='I_Q, [A]') \\\n",
" .with_signal(u_res_df) \\\n",
" .with_ylabel(ylabel='U_RES_Q, [V]') \\\n",
" .plot(show_plot=False).get_axes()[0]\n",
" for ps, pe in zip(plateau_start, plateau_end):\n",
" .plot(show_plot=False).get_axes()[0]\n",
" ax.axvspan(xmin=(ps-Time.to_unix_timestamp(t_start))/1e9, xmax=(pe-Time.to_unix_timestamp(t_start))/1e9, facecolor='xkcd:orange')"
]
},
{
"cell_type": "code",
"execution_count": null,
......
......@@ -46,18 +46,15 @@
"metadata": {},
"source": [
"# 0. Initialise Working Environment"
]
},
{
"cell_type": "code",
"execution_count": 1,
{
"cell_type": "code",
"execution_count": null,
"metadata": {
 
 
"scrolled": false
},
"outputs": [],
"source": [
"# External libraries\n",
......@@ -93,31 +90,18 @@
"- Choose a circuit name in order to display HWC test with, campaign name as well as start and end time"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"editable": false
},
"circuit_type = 'RB'\n",
"hwc_test = 'PLI1.a2'\n",
"hwc_test_history_df = pd.read_csv('/eos/project/l/lhcsm/hwc/RB/hwc_test_history.csv')\n",
"hwcb = HwcBrowser(hwc_test_history_df, circuit_type, hwc_test)\n",
"display(hwcb.widget)"
]
},
"outputs": [],
"source": [
"circuit_type = 'RB'\n",
"metadata": {},
"source": [
"# 2. Query All Signals Prior to Analysis"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"hwc_test = 'PLI1.a2'\n",
"hwc_test_history_df = pd.read_csv('/eos/project/l/lhcsm/hwc/RB/hwc_test_history.csv')\n",
"hwcb = HwcBrowser(hwc_test_history_df, circuit_type, hwc_test)\n",
"display(hwcb.widget)"
]
},
......
......@@ -49,13 +49,10 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"# 0. Initialise Working Environment"
]
},
{
"cell_type": "code",
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
......@@ -103,21 +100,15 @@
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"scrolled": false
 
},
"outputs": [],
"source": [
"circuit_type = 'RB'\n",
"hwc_test = 'PLI1.b2'\n",
"hwc_test_history_df = pd.read_csv('/eos/project/l/lhcsm/hwc/RB/hwc_test_history.csv')\n",
"hwcb = HwcBrowser(hwc_test_history_df, circuit_type, hwc_test)\n",
"display(hwcb.widget)"
]
},
"circuit_type = 'RB'\n",
"hwc_test = 'PLI1.b2'\n",
"hwc_test_history_df = pd.read_csv('/eos/project/l/lhcsm/hwc/RB/hwc_test_history.csv')\n",
"hwcb = HwcBrowser(hwc_test_history_df, circuit_type, hwc_test)\n",
"display(hwcb.widget)"
]
......@@ -229,10 +220,15 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"# 5. Energy Extraction System\n",
"## 5.1. Analysis of the Energy Extraction Voltage\n",
"\n",
"*QUERY*:\n",
"\n",
"|Variable Name\t|Variable Type\t|Variable Unit\t|Database|Comment\n",
"|---------------|---------------|---------------|--------|------|\n",
"|i_a_df\t|DataFrame\t|A\t|PM|I_A is the raw power converter current logged around the FPA with high sampling frequench|\n",
"|i_meas_df\t|DataFrame\t|A|PM\t|I_MEAS is filtered I_A with lower sampling frequency and longer duration|\n",
"|i_ref_df | DataFrame | A |PM| Reference power converter current, STATUS.I_REF|\n",
"|u_dump_res_odd_df | DataFrame | V |PM| Energy extraction odd voltage U_DUMP_RES|\n",
"|u_dump_res_even_df | DataFrame | V |PM| Energy extraction even voltage U_DUMP_RES|\n",
......@@ -260,11 +256,21 @@
"\n",
"Second plot (triggering view):\n",
"- the power converter current on the left axis, I_MEAS\n",
"- the power converter reference current on the left axis, STATUS.I_REF (should stop at the moment of the FGC PM timestamp)\n",
"- the two energy extraction voltages on the right axis, U_DUMP_RES, U_DUMP_RES\n",
"- the green dashed line denotes the PIC timestamp\n"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"rb_analysis.analyze_char_time_u_dump_res_ee(circuit_name, timestamp_fgc, [u_dump_res_odd_df, u_dump_res_even_df], i_meas_df)"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
......
......@@ -48,13 +48,10 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"# 0. Initialise Working Environment"
]
},
{
"cell_type": "code",
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
......@@ -122,18 +119,11 @@
"# 2. Query All Signals Prior to Analysis"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"circuit_name = hwcb.get_circuit_name()\n",
"t_start = hwcb.get_start_time()\n",
"t_end = hwcb.get_end_time()\n",
"author = hwcb.get_author()\n",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"circuit_name = hwcb.get_circuit_name()\n",
"t_start = hwcb.get_start_time()\n",
......
......@@ -56,15 +56,14 @@
"metadata": {
"editable": false
},
"outputs": [],
"source": [
"source": [
"import io\n",
"import re\n",
"import sys\n",
"import time\n",
"import time\n",
"import pandas as pd\n",
"from IPython.display import display, Javascript\n",
"\n",
"# lhc-sm-api\n",
"from lhcsmapi.Time import Time\n",
......@@ -96,19 +95,24 @@
"# 1. Select PLI2.s1 HWC Test\n",
"- Choose a circuit name in order to display HWC test with, campaign name as well as start and end time"
]
},
{
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"editable": false
},
"outputs": [],
"source": [
"circuit_type = 'RB'\n",
},
"outputs": [],
"source": [
"hwc_test = 'PLI2.s1'\n",
"hwc_test_history_df = pd.read_csv('/eos/project/l/lhcsm/hwc/RB/hwc_test_history.csv')\n",
"hwcb = HwcBrowser(hwc_test_history_df, circuit_type, hwc_test)\n",
"display(hwcb.widget)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# 2. Query All Signals Prior to Analysis"
......@@ -149,12 +153,11 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"# 3. Power Converter\n",
"## 3.1. Plot of the Power Converter Main Current\n",
"source": [
"# 3. Power Converter\n",
"\n",
"*QUERY*:\n",
"\n",
"|Variable Name\t|Variable Type\t|Variable Unit\t|Database|Comment\n",
"|---------------|---------------|---------------|--------|------|\n",
"|i_meas_nxcals_df | DataFrame | A |NXCALS| Main power converter current, I_MEAS|\n",
......@@ -169,52 +172,17 @@
"- Orange box(es) represent period(s) of time with constant current used for calculation of busbar resistance and DFB thresholds"
]
},
{
"cell_type": "code",
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"deletable": false,
"editable": false,
"scrolled": false
},
"outputs": [],
"source": [
"ax = i_meas_nxcals_df.plot(figsize=(30, 10), grid=True)\n",
"for ps, pe in zip(plateau_start, plateau_end):\n",
" ax.axvspan(xmin=(ps-Time.to_unix_timestamp(i_meas_raw_nxcals_df.index[0]))/1e9, \n",
" xmax=(pe-Time.to_unix_timestamp(i_meas_raw_nxcals_df.index[0]))/1e9, facecolor='xkcd:goldenrod')\n",
"execution_count": null,
"metadata": {
"editable": false,
"ax.tick_params(labelsize=15)"
]
},
{
"scrolled": false
},
"outputs": [],
"# 4. Busbar\n",
"## 4.1. Busbar Resistance\n",
"\n",
"*QUERY*:\n",
"\n",
"|Variable Name\t|Variable Type\t|Variable Unit\t|Database|Comment\n",
"|---------------|---------------|---------------|--------|------|\n",
"|i_meas_feature_df | DataFrame | A |NXCALS| Mean, std, and count values of the main power converter current labeled (1,2,...) at the current plateaus, I_MEAS|\n",
"|u_res_feature_df | DataFrame | V |NXCALS| Mean, std, and count values of the busbar voltage labeled (1,2,...) at the current plateaus, U_RES|\n",
"\n",
"*ANALYSIS*:\n",
"\n",
"- Calculation of the busbar resistance as the slope of a linear fit of U,I curve obtained from the corresponding mean alues of the voltage and current\n",
"\n",
"*CRITERIA*:\n",
"\n",
"- Check if the busbar resistance is below 3 nOhm\n",
"\n",
"*GRAPHS*:\n",
"source": [
"ax = i_meas_nxcals_df.plot(figsize=(30, 10), grid=True)\n",
"for ps, pe in zip(plateau_start, plateau_end):\n",
" ax.axvspan(xmin=(ps-Time.to_unix_timestamp(i_meas_raw_nxcals_df.index[0]))/1e9, \n",
" xmax=(pe-Time.to_unix_timestamp(i_meas_raw_nxcals_df.index[0]))/1e9, facecolor='xkcd:goldenrod')\n",
"ax.set_xlabel(\"time, [s]\", fontsize=15)\n",
......
This diff is collapsed.
......@@ -50,13 +50,10 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"# 0. Initialise Working Environment"
]
},
{
"cell_type": "code",
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
......
......@@ -47,27 +47,23 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"# 0. Initialise Working Environment"
]
},
{
"cell_type": "code",
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"editable": false
},
"outputs": [],
"import io\n",
"source": [
"import io\n",
"import re\n",
"import sys\n",
"import time\n",
"from IPython.display import display, Javascript\n",
"import pandas as pd\n",
"from IPython.display import display, Javascript\n",
"\n",
"# lhc-sm-api\n",
"from lhcsmapi.Time import Time\n",
......@@ -76,11 +72,11 @@
"# GUI\n",
"from lhcsmapi.gui.hwc.HwcBrowser import HwcBrowser\n",
"\n",
"# Query\n",
"from lhcsmapi.analysis.RbCircuitQuery import RbCircuitQuery\n",
"from lhcsmapi.pyedsl.QueryBuilder import QueryBuilder\n",
"from lhcsmapi.analysis.RbCircuitAnalysis import RbCircuitAnalysis\n",
"\n",
"# Analysis\n",
"from lhcsmapi.analysis.report_template import apply_report_template\n",
"from lhcsmapi.analysis.busbar.BusbarResistanceAnalysis import convert_to_col, find_plateau_start_and_end\n",
"\n",
......@@ -99,38 +95,44 @@
"# 1. Select PLI2.s1 HWC Test\n",
"- Choose a circuit name in order to display HWC test with, campaign name as well as start and end time"
]
},
{
},
"cell_type": "code",
"execution_count": null,
"metadata": {
"editable": false
},
"outputs": [],
"source": [
"circuit_type = 'RB'\n",
"editable": false
},
"outputs": [],
"hwc_test = 'PLIS.s2'\n",
"hwc_test_history_df = pd.read_csv('/eos/project/l/lhcsm/hwc/RB/hwc_test_history.csv')\n",
"hwcb = HwcBrowser(hwc_test_history_df, circuit_type, hwc_test)\n",
"display(hwcb.widget)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# 2. Query All Signals Prior to Analysis"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"metadata": {
"editable": false,
]
"tags": [
"skip_output"
]
},
"outputs": [],
"source": [
"metadata": {
"circuit_name = hwcb.get_circuit_name()\n",
"t_start = hwcb.get_start_time()\n",
"t_end = hwcb.get_end_time()\n",
"is_automatic = hwcb.is_automatic_mode()\n",
"rb_query = RbCircuitQuery(circuit_type, circuit_name, max_executions=4)\n",
"rb_analysis = RbCircuitAnalysis(circuit_type, pd.DataFrame(), is_automatic=is_automatic)\n",
"\n",
......@@ -151,12 +153,11 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"# 3. Power Converter\n",
"## 3.1. Plot of the Power Converter Main Current\n",
"cell_type": "markdown",
"metadata": {},
"\n",
"*QUERY*:\n",
"\n",
"|Variable Name\t|Variable Type\t|Variable Unit\t|Database|Comment\n",
"|---------------|---------------|---------------|--------|------|\n",
"|i_meas_nxcals_df | DataFrame | A |NXCALS| Main power converter current, I_MEAS|\n",
......@@ -167,55 +168,21 @@
"\n",
"*GRAPHS*:\n",
"\n",
"- t = 0 s corresponds to the start of the test\n",
"- Orange box(es) represent period(s) of time with constant current used for calculation of busbar resistance and DFB thresholds"
"*PLOT*:\n",
"- t = 0 s corresponds to the start of the test\n",
"- Orange box(es) represent period(s) of time with constant current used for calculation of busbar resistance and DFB thresholds"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"deletable": false,
"editable": false,
"scrolled": false
]
},
{
"cell_type": "code",
"for ps, pe in zip(plateau_start, plateau_end):\n",
"execution_count": null,
"metadata": {
"editable": false,
"ax.set_xlabel(\"time, [s]\", fontsize=15)\n",
"ax.set_ylabel(\"I_MEAS, [A]\", fontsize=15)\n",
"ax.tick_params(labelsize=15)"
]
"scrolled": false
},
"outputs": [],
"metadata": {},
"source": [
"# 4. Busbar\n",
"## 4.1. Busbar Resistance\n",
"\n",
"*QUERY*:\n",
"\n",
"|Variable Name\t|Variable Type\t|Variable Unit\t|Database|Comment\n",
"|---------------|---------------|---------------|--------|------|\n",
"|i_meas_feature_df | DataFrame | A |NXCALS| Mean, std, and count values of the main power converter current labeled (1,2,...) at the current plateaus, I_MEAS|\n",
"|u_res_feature_df | DataFrame | V |NXCALS| Mean, std, and count values of the busbar voltage labeled (1,2,...) at the current plateaus, U_RES|\n",
"\n",
"*ANALYSIS*:\n",
"\n",
"- Calculation of the busbar resistance as the slope of a linear fit of U,I curve obtained from the corresponding mean alues of the voltage and current\n",
"\n",
"*CRITERIA*:\n",
"\n",
"- Check if the busbar resistance is below 3 nOhm\n",
"source": [
"ax = i_meas_nxcals_df.plot(figsize=(30, 10), grid=True)\n",
"for ps, pe in zip(plateau_start, plateau_end):\n",
" ax.axvspan(xmin=(ps-Time.to_unix_timestamp(i_meas_raw_nxcals_df.index[0]))/1e9, \n",
" xmax=(pe-Time.to_unix_timestamp(i_meas_raw_nxcals_df.index[0]))/1e9, facecolor='xkcd:goldenrod')\n",
"ax.set_xlabel(\"time, [s]\", fontsize=15)\n",
......@@ -228,11 +195,11 @@
"metadata": {},
"source": [