You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@spark.apache.org by gu...@apache.org on 2022/03/29 02:14:31 UTC
[spark] branch branch-3.3 updated: [MINOR][PYTHON] Fix `MultilayerPerceptronClassifierTest.test_raw_and_probability_prediction`
This is an automated email from the ASF dual-hosted git repository.
gurwls223 pushed a commit to branch branch-3.3
in repository https://gitbox.apache.org/repos/asf/spark.git
The following commit(s) were added to refs/heads/branch-3.3 by this push:
new fbb9c20 [MINOR][PYTHON] Fix `MultilayerPerceptronClassifierTest.test_raw_and_probability_prediction`
fbb9c20 is described below
commit fbb9c2024054695adc6c15f52b06b157ea5bd211
Author: Harutaka Kawamura <hk...@gmail.com>
AuthorDate: Tue Mar 29 11:08:48 2022 +0900
[MINOR][PYTHON] Fix `MultilayerPerceptronClassifierTest.test_raw_and_probability_prediction`
### What changes were proposed in this pull request?
- A follow-up for https://github.com/apache/spark/pull/35778
- Increase `rtol` to de-flake the test.
https://github.com/apache/spark/runs/5725350556
```
Not equal to tolerance rtol=0.15, atol=1e-08
Mismatched elements: 3 / 3 (100%)
Max absolute difference: 4.39314499
Max relative difference: 0.23356037
x: array([-14.190332, -10.063731, 26.570715])
y: array([-11.608192, -8.15828 , 22.17757 ])
```
### Why are the changes needed?
### Does this PR introduce _any_ user-facing change?
### How was this patch tested?
Closes #35997 from harupy/fix-test_raw_and_probability_prediction-2.
Authored-by: Harutaka Kawamura <hk...@gmail.com>
Signed-off-by: Hyukjin Kwon <gu...@apache.org>
(cherry picked from commit 264dbd7641ee30b01212d10de98f29c8be5c8943)
Signed-off-by: Hyukjin Kwon <gu...@apache.org>
---
python/pyspark/ml/tests/test_algorithms.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/python/pyspark/ml/tests/test_algorithms.py b/python/pyspark/ml/tests/test_algorithms.py
index 08da859..e677e79 100644
--- a/python/pyspark/ml/tests/test_algorithms.py
+++ b/python/pyspark/ml/tests/test_algorithms.py
@@ -106,7 +106,7 @@ class MultilayerPerceptronClassifierTest(SparkSessionTestCase):
np.testing.assert_allclose(
result.rawPrediction,
expected_rawPrediction,
- rtol=0.15,
+ rtol=0.3,
# Use the same default value as `np.allclose`
atol=1e-08,
)
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@spark.apache.org
For additional commands, e-mail: commits-help@spark.apache.org