aboutsummaryrefslogtreecommitdiffstats
path: root/dpd/src/Model.py
diff options
context:
space:
mode:
Diffstat (limited to 'dpd/src/Model.py')
-rw-r--r--dpd/src/Model.py11
1 files changed, 2 insertions, 9 deletions
diff --git a/dpd/src/Model.py b/dpd/src/Model.py
index 07ac5a4..f923799 100644
--- a/dpd/src/Model.py
+++ b/dpd/src/Model.py
@@ -28,9 +28,8 @@ class Model:
np.median(np.abs(rxframe_aligned))
))
- tx_rx_frame_path = ('/tmp/tx_rx_sync_' +
- datetime.datetime.now().isoformat() +
- '.pdf')
+ dt = datetime.datetime.now().isoformat()
+ tx_rx_frame_path = ("/tmp/" + dt + "_tx_rx_sync.pdf")
plt.plot(np.abs(rxframe_aligned[:128]), label="rxframe")
plt.plot(np.abs(txframe_aligned[:128]), label="txframe")
plt.xlabel("Samples")
@@ -40,12 +39,6 @@ class Model:
plt.clf()
logging.debug("Tx, Rx synchronized %s" % tx_rx_frame_path)
- dt = datetime.datetime.now().isoformat()
- txframe_path = ('/tmp/tx_3_' + dt + '.iq')
- txframe_aligned.tofile(txframe_path)
- rxframe_path = ('/tmp/rx_3_' + dt + '.iq')
- rxframe_aligned.tofile(rxframe_path)
-
mse = np.mean(np.abs(np.square(txframe_aligned - rxframe_aligned)))
logging.debug("MSE: {}".format(mse))