You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@beam.apache.org by "ASF GitHub Bot (Jira)" <ji...@apache.org> on 2021/12/01 15:48:00 UTC

[jira] [Work logged] (BEAM-12565) Implement compare for DataFrame and Series

     [ https://issues.apache.org/jira/browse/BEAM-12565?focusedWorklogId=688754&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-688754 ]

ASF GitHub Bot logged work on BEAM-12565:
-----------------------------------------

                Author: ASF GitHub Bot
            Created on: 01/Dec/21 15:47
            Start Date: 01/Dec/21 15:47
    Worklog Time Spent: 10m 
      Work Description: roger-mike commented on a change in pull request #16027:
URL: https://github.com/apache/beam/pull/16027#discussion_r760314080



##########
File path: sdks/python/apache_beam/dataframe/frames_test.py
##########
@@ -1082,6 +1082,50 @@ def test_dt_tz_localize_nonexistent(self):
             'Europe/Warsaw', ambiguous='NaT', nonexistent=pd.Timedelta('1H')),
         s)
 
+  def test_compare_series(self):
+    s1 = pd.Series(["a", "b", "c", "d", "e"])
+    s2 = pd.Series(["a", "a", "c", "b", "e"])
+
+    self._run_test(lambda s1, s2: s1.compare(s2), s1, s2)
+    self._run_test(lambda s1, s2: s1.compare(s2, align_axis=0), s1, s2)
+    self._run_test(lambda s1, s2: s1.compare(s2, keep_shape=True), s1, s2)
+    self._run_test(
+        lambda s1, s2: s1.compare(s2, keep_shape=True, keep_equal=True), s1, s2)
+
+  def test_compare_dataframe(self):

Review comment:
       The test for `Dataframe.compare` in `pandas_doctests.test.py` was skipped because it tries to apply a `loc` to `df2` and it's not implemented, making the tests fail.




-- 
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: github-unsubscribe@beam.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Issue Time Tracking
-------------------

    Worklog Id:     (was: 688754)
    Time Spent: 40m  (was: 0.5h)

> Implement compare for DataFrame and Series
> ------------------------------------------
>
>                 Key: BEAM-12565
>                 URL: https://issues.apache.org/jira/browse/BEAM-12565
>             Project: Beam
>          Issue Type: Improvement
>          Components: dsl-dataframe
>            Reporter: Brian Hulette
>            Assignee: Mike Hernandez
>            Priority: P3
>          Time Spent: 40m
>  Remaining Estimate: 0h
>
> Add an implementation of [compare|https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.DataFrame.compare.html] for DeferredDataFrame and DeferredSeries. It should be fully unit tested with some combination of pandas_doctests_test.py and frames_test.py.
> https://github.com/apache/beam/pull/14274 is an example of a typical PR that adds new operations. See https://lists.apache.org/thread.html/r8ffe96d756054610dfdb4e849ffc6a741e826d15ba7e5bdeee1b4266%40%3Cdev.beam.apache.org%3E for background on the DataFrame API.



--
This message was sent by Atlassian Jira
(v8.20.1#820001)