##// END OF EJS Templates
Added missing files (sdc/pdc/makefile) for LFR-EQM boards...
Added missing files (sdc/pdc/makefile) for LFR-EQM boards Improved Validation IIR LFR design Update LFR Filter, first implementation of filter RAM Init.

File last commit:

r639:5ffe6bd0368c default
r639:5ffe6bd0368c default
Show More
PlotResults.ipynb
83 lines | 2.3 KiB | text/plain | TextLexer
pellion
Added missing files (sdc/pdc/makefile) for LFR-EQM boards...
r639 {
"cells": [
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"collapsed": false
},
"outputs": [],
"source": [
"#%matplotlib qt\n",
"%matplotlib inline\n",
"import matplotlib.pyplot as plt\n",
"plt.rcParams[\"figure.figsize\"] = [12,12]\n",
"import numpy as np\n",
"import pandas as pds"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"collapsed": false
},
"outputs": [],
"source": [
"def try_plot(df,ax,left,right):\n",
" try:\n",
" df[(df.index >= left) & (df.index <= right)].plot(ax=ax,subplots=True,legend=False)\n",
" except:\n",
" pass\n",
" \n",
"def make_plots(path=\"./simulation\",left=50e-3,right=100e-3):\n",
" inputSig = pds.read_csv(path+\"/log_input.txt\",index_col=0,delim_whitespace=True,header=None,names=[\"TSTAMP\",\"BIAS1\",\"BIAS2\",\"BIAS3\",\"BIAS4\",\"BIAS5\",\"B1\",\"B2\",\"B3\"])\n",
" fXSig=[]\n",
" G=[0.89,0.87,0.89]\n",
" [fXSig.append(pds.read_csv(\n",
" path+\"./log_output_f{0}.txt\".format(F),index_col=0,delim_whitespace=True,header=None,\n",
" names=[\"TSTAMP\",\"BIAS1\",\"BIAS4\",\"BIAS5\",\"B1\",\"B2\",\"B3\"])) for F in range(3) ]\n",
" inputSig.index*=5e-9\n",
" for F in range(3):\n",
" if len(fXSig[F].index):\n",
" fXSig[F].index*=5e-9\n",
" fXSig[F]/=G[F]\n",
" axes=inputSig[(inputSig.index >= left) & (inputSig.index <= right)].filter([\"BIAS1\",\"BIAS4\",\"BIAS5\",\"B1\",\"B2\",\"B3\"]).plot(subplots=True,layout=(3,2)) \n",
" [ try_plot(df,axes,left,right) for df in fXSig ]\n",
" "
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"collapsed": false
},
"outputs": [],
"source": [
"make_plots()"
]
}
],
"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.5.2"
}
},
"nbformat": 4,
"nbformat_minor": 1
}