You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@madlib.apache.org by ok...@apache.org on 2021/02/22 19:24:05 UTC
[madlib] branch master updated: DL: Fix predict bug for the multi
dependent single independent case
This is an automated email from the ASF dual-hosted git repository.
okislal pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/madlib.git
The following commit(s) were added to refs/heads/master by this push:
new 49c3805 DL: Fix predict bug for the multi dependent single independent case
49c3805 is described below
commit 49c38054c89e2763a92ab0e53072c28c887293fc
Author: Orhan Kislal <ok...@apache.org>
AuthorDate: Mon Feb 22 22:22:45 2021 +0300
DL: Fix predict bug for the multi dependent single independent case
---
src/ports/postgres/modules/deep_learning/madlib_keras_predict.py_in | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/src/ports/postgres/modules/deep_learning/madlib_keras_predict.py_in b/src/ports/postgres/modules/deep_learning/madlib_keras_predict.py_in
index d23d765..3c7b28e 100644
--- a/src/ports/postgres/modules/deep_learning/madlib_keras_predict.py_in
+++ b/src/ports/postgres/modules/deep_learning/madlib_keras_predict.py_in
@@ -377,7 +377,6 @@ def internal_keras_predict(independent_var, model_architecture, model_weights,
# Since the test data isn't mini-batched,
# we have to make sure that the test data np array has the same
# number of dimensions as input_shape. So we add a dimension to x.
-
independent_var_filtered = []
for i in independent_var:
if i is not None:
@@ -389,7 +388,7 @@ def internal_keras_predict(independent_var, model_architecture, model_weights,
# and not mini-batched, this list contains exactly one list in it,
# so return back the first list in probs.
result = []
- if len(independent_var_filtered) > 1:
+ if len(probs) > 1:
for i in probs:
for j in i[0]:
result.append(j)