HyukjinKwon commented on a change in pull request #34235:
URL: https://github.com/apache/spark/pull/34235#discussion_r726734654



##########
File path: python/pyspark/pandas/series.py
##########
@@ -5014,11 +4998,11 @@ def dot(self, other: Union["Series", DataFrame]) -> 
Union[Scalar, "Series"]:
         y   -14
         dtype: int64
         """
-        if isinstance(other, DataFrame):
-            if not same_anchor(self, other):
-                if not 
self.index.sort_values().equals(other.index.sort_values()):
-                    raise ValueError("matrices are not aligned")
+        if not same_anchor(self, other):
+            if not self.index.sort_values().equals(other.index.sort_values()):

Review comment:
       Can we add another parameter to enable/disable this check? This is too 
expensive operation .. sort both sides, and aggregate which introduces 3 
suffles ... 
   
   Or maybe we should introduce a configuration to enable and disable all of 
such instances ....




-- 
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]

Reply via email to