aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNiklas Halle <niklas@niklashalle.net>2021-06-10 16:13:02 +0200
committerNiklas Halle <niklas@niklashalle.net>2021-06-10 16:13:02 +0200
commit4f48784d6deec36f8e180d2d7e35799891f4d2db (patch)
tree175d1ce4d8847fbfcda85e6ec1bd13703676162e
parentbb2f3170e03834eb2855e14b9713ad49a9c1d8ed (diff)
downloadbachelor_thesis-4f48784d6deec36f8e180d2d7e35799891f4d2db.tar.gz
bachelor_thesis-4f48784d6deec36f8e180d2d7e35799891f4d2db.zip
exec
-rwxr-xr-x[-rw-r--r--]code/python/convolution.py3
-rw-r--r--code/python/utils.py2
2 files changed, 4 insertions, 1 deletions
diff --git a/code/python/convolution.py b/code/python/convolution.py
index 9baf366..9a36f46 100644..100755
--- a/code/python/convolution.py
+++ b/code/python/convolution.py
@@ -1,5 +1,8 @@
#!/usr/bin/env python3.6
+import os
+
+os.environ['TF_CPP_MIN_LOG_LEVEL'] = '1'
import tensorflow as tf
from sklearn.model_selection import train_test_split
diff --git a/code/python/utils.py b/code/python/utils.py
index 408ecbd..bca87a8 100644
--- a/code/python/utils.py
+++ b/code/python/utils.py
@@ -40,7 +40,7 @@ def loss(y_true, y_pred, margin=1):
product = tf.where(cond, neg, pos)
# add marging
result = tf.math.add(1.0, product)
- error = tf.math.maximum(0.0, result)
+ error = result #tf.math.maximum(0.0, result)
return error
def load_tester(path):