summaryrefslogtreecommitdiffstats
path: root/dpd/src/Symbol_align.py
diff options
context:
space:
mode:
authorMatthias P. Braendli <matthias.braendli@mpb.li>2017-12-29 06:43:49 +0100
committerMatthias P. Braendli <matthias.braendli@mpb.li>2017-12-29 06:43:58 +0100
commita62e05c9564045044df734fd3723b3f665ad91ae (patch)
tree5a9e1570362fe9a47fe581c292f3bd84f6fd3e82 /dpd/src/Symbol_align.py
parentbf53849fba5796d1b98254a7eeab575a50ae7996 (diff)
downloaddabmod-a62e05c9564045044df734fd3723b3f665ad91ae.tar.gz
dabmod-a62e05c9564045044df734fd3723b3f665ad91ae.tar.bz2
dabmod-a62e05c9564045044df734fd3723b3f665ad91ae.zip
DPD: Make logging to file optional in all modules, simplify apply_adapt_dumps
Diffstat (limited to 'dpd/src/Symbol_align.py')
-rw-r--r--dpd/src/Symbol_align.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/dpd/src/Symbol_align.py b/dpd/src/Symbol_align.py
index d921f25..f2802ee 100644
--- a/dpd/src/Symbol_align.py
+++ b/dpd/src/Symbol_align.py
@@ -12,7 +12,7 @@ import logging
try:
logging_path = os.path.dirname(logging.getLoggerClass().root.handlers[0].baseFilename)
except:
- logging_path = "/tmp/"
+ logging_path = None
import numpy as np
import scipy
@@ -75,7 +75,7 @@ class Symbol_align:
offset = peaks[np.argmin([tx_product_avg[peak] for peak in peaks])]
- if logging.getLogger().getEffectiveLevel() == logging.DEBUG and self.plot:
+ if logging.getLogger().getEffectiveLevel() == logging.DEBUG and self.plot and logging_path is not None:
dt = datetime.datetime.now().isoformat()
fig_path = logging_path + "/" + dt + "_Symbol_align.svg"