{
"cells": [
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# Tokamak GOLEM Tektronix MSO56 DAS Oscilloscope"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## The device\n",
"\n",
"\n",
"
\n",
"Datasheet\n",
"\n",
"## Screenshot\n",
"\n",
"Relevant data screenshot
\n",
"\n",
"\n",
"## Data\n",
"\n",
"Data directory\n",
"\n",
"\n",
"### Raw data\n",
"1. [LoopVoltageCoil_raw.csv](LoopVoltageCoil_raw.csv)\n",
"1. [BtCoil_raw.csv](BtCoil_raw.csv)\n",
"1. [RogowskiCoil_raw.csv](RogowskiCoil_raw.csv)\n",
"1. [LeyboldPhotodiodeNoFilter_raw.csv](LeyboldPhotodiodeNoFilter_raw.csv)\n",
"1. [Trigger_raw.csv](Trigger_raw.csv)\n",
"\n",
"## Math operated\n",
"1. [BtCoil_integrated.csv](BtCoil_integrated.csv)\n",
"1. [RogowskiCoil_integrated.csv](RogowskiCoil_integrated.csv)\n"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"# Data manipulation (This notebook to download)\n",
"\n",
"## Prerequisites"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"#Libraries\n",
"import pandas as pd\n",
"import matplotlib.pyplot as plt\n",
"\n",
"URL = 'http://golem.fjfi.cvut.cz/shots/{}/DASs/StandardDAS/{}.csv'\n",
"shot_no = 34423\n",
"\n",
"# function for reading 1D y(t) signals\n",
"def read_signal1d(shot_number, signal_id):\n",
" url = URL.format(shot_number, signal_id)\n",
" return pd.read_csv(url,names=['time',signal_id],\n",
" index_col='time')"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Raw data from oscilloscope"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"# read the specified signals\n",
"U_l = read_signal1d(shot_no, 'LoopVoltageCoil_raw')\n",
"dI_chp = read_signal1d(shot_no, 'RogowskiCoil_raw')\n",
"dB_t = read_signal1d(shot_no, 'BtCoil_raw')\n",
"I_all = read_signal1d(shot_no, 'LeyboldPhotodiodeNoFilter_raw')\n",
"Trigger = read_signal1d(shot_no, 'Trigger_raw')\n",
"\n",
"\n",
"# combine into a data frame table\n",
"df = pd.concat([U_l, dI_chp, dB_t, I_all,Trigger], axis='columns')\n",
"\n",
"# plot the data table in subplots from 1 to 25 ms\n",
"df.loc[0e-3:25e-3].plot(subplots=True, ylim=(None,None))\n",
"plt.show() # display the figure in a window"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Oscilloscope data through math operation"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"B_t = read_signal1d(shot_no, 'BtCoil_integrated')\n",
"I_chp = read_signal1d(shot_no, 'RogowskiCoil_integrated')\n",
"\n",
"# combine into a data frame table\n",
"df = pd.concat([B_t,I_chp], axis='columns')\n",
"\n",
"df.loc[1e-3:25e-3].plot(subplots=True, ylim=(0,None))\n",
"plt.show() # display the figure in a window"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Classical presentation"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"df = pd.concat([U_l, B_t, I_chp, I_all], axis='columns')\n",
"\n",
"# plot the data table in subplots from 1 to 25 ms\n",
"df.loc[1e-3:25e-3].plot(subplots=True, ylim=(None,None))\n",
"plt.show() # display the figure in a window"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"\n",
"All data screenshot
\n",
"\n",
"
Standard DAS Oscilloscope"
]
}
],
"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.7.4"
}
},
"nbformat": 4,
"nbformat_minor": 4
}