zhengruifeng commented on code in PR #41947:
URL: https://github.com/apache/spark/pull/41947#discussion_r1260511824
##########
python/pyspark/testing/utils.py:
##########
@@ -243,6 +245,10 @@ def assertDataFrameEqual(df: DataFrame, expected:
DataFrame, check_row_order: bo
If set to `False` (default), the row order is not taken into account.
If set to `True`, the order of rows is important and will be checked
during comparison.
+ precision : float, optional
+ The level of precision when asserting approximate equality for float
values in df
+ and expected. Set to 1e-5 by default.
Review Comment:
good point, we actually use `rtol` and `atol` in both scala and python:
in python:
https://github.com/apache/spark/blob/5a702f22f49ca6a1b6220ac645e3fce70ec5189d/python/pyspark/ml/tests/test_algorithms.py#L390-L396
https://github.com/apache/spark/blob/f3edc0c3570ea4b28f68607d6404c6b8d0801161/python/pyspark/pandas/tests/plot/test_series_plot_matplotlib.py#L364-L367
in scala:
https://github.com/apache/spark/blob/d679dabdd1b5ad04b8c7deb1c06ce886a154a928/mllib/src/test/scala/org/apache/spark/ml/classification/LogisticRegressionSuite.scala#L379-L400
https://github.com/apache/spark/blob/d679dabdd1b5ad04b8c7deb1c06ce886a154a928/mllib/src/test/scala/org/apache/spark/ml/regression/GeneralizedLinearRegressionSuite.scala#L1021-L1040
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]