This is an automated email from the ASF dual-hosted git repository.

altay pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/beam.git


The following commit(s) were added to refs/heads/master by this push:
     new f79b55c  [BEAM-7389] Add outputs for Filter page examples
     new f3f3171  Merge pull request #9259 from davidcavazos/filter-page
f79b55c is described below

commit f79b55ce39ed72a91e842a7f60acb6cfea7a2abf
Author: David Cavazos <[email protected]>
AuthorDate: Fri Aug 2 11:18:25 2019 -0700

    [BEAM-7389] Add outputs for Filter page examples
---
 .../transforms/python/element-wise/filter.md       | 35 ++++++++++++++++++++--
 1 file changed, 33 insertions(+), 2 deletions(-)

diff --git a/website/src/documentation/transforms/python/element-wise/filter.md 
b/website/src/documentation/transforms/python/element-wise/filter.md
index 420718c..5318f20 100644
--- a/website/src/documentation/transforms/python/element-wise/filter.md
+++ b/website/src/documentation/transforms/python/element-wise/filter.md
@@ -42,17 +42,23 @@ on the comparison ordering of the element.
 
 ## Examples
 
-In the following examples, we create a pipeline with a `PCollection` of 
produce their icon, name, and duration.
+In the following examples, we create a pipeline with a `PCollection` of 
produce with their icon, name, and duration.
 Then, we apply `Filter` in multiple ways to filter out produce by their 
duration value.
 
+`Filter` accepts a function that keeps elements that return `True`, and 
filters out the remaining elements.
+
 ### Example 1: Filtering with a function
 
 We define a function `is_perennial` which returns `True` if the element's 
duration equals `'perennial'`, and `False` otherwise.
-`Filter` accepts this function, keeps elements that return `True`, and filters 
out the remaining elements.
 
 ```py
 {% github_sample 
/apache/beam/blob/master/sdks/python/apache_beam/examples/snippets/transforms/element_wise/filter.py
 tag:filter_function %}```
 
+Output `PCollection` after `Filter`:
+
+```
+{% github_sample 
/apache/beam/blob/master/sdks/python/apache_beam/examples/snippets/transforms/element_wise/filter_test.py
 tag:perennials %}```
+
 <table>
   <td>
     <a class="button" target="_blank"
@@ -72,6 +78,11 @@ We can also use lambda functions to simplify **Example 1**.
 ```py
 {% github_sample 
/apache/beam/blob/master/sdks/python/apache_beam/examples/snippets/transforms/element_wise/filter.py
 tag:filter_lambda %}```
 
+Output `PCollection` after `Filter`:
+
+```
+{% github_sample 
/apache/beam/blob/master/sdks/python/apache_beam/examples/snippets/transforms/element_wise/filter_test.py
 tag:perennials %}```
+
 <table>
   <td>
     <a class="button" target="_blank"
@@ -94,6 +105,11 @@ In this example, `has_duration` takes `plant` and 
`duration` as arguments.
 ```py
 {% github_sample 
/apache/beam/blob/master/sdks/python/apache_beam/examples/snippets/transforms/element_wise/filter.py
 tag:filter_multiple_arguments %}```
 
+Output `PCollection` after `Filter`:
+
+```
+{% github_sample 
/apache/beam/blob/master/sdks/python/apache_beam/examples/snippets/transforms/element_wise/filter_test.py
 tag:perennials %}```
+
 <table>
   <td>
     <a class="button" target="_blank"
@@ -117,6 +133,11 @@ We then use that value to filter out perennials.
 ```py
 {% github_sample 
/apache/beam/blob/master/sdks/python/apache_beam/examples/snippets/transforms/element_wise/filter.py
 tag:filter_side_inputs_singleton %}```
 
+Output `PCollection` after `Filter`:
+
+```
+{% github_sample 
/apache/beam/blob/master/sdks/python/apache_beam/examples/snippets/transforms/element_wise/filter_test.py
 tag:perennials %}```
+
 <table>
   <td>
     <a class="button" target="_blank"
@@ -138,6 +159,11 @@ so it is possible to iterate over large `PCollection`s 
that won't fit into memor
 ```py
 {% github_sample 
/apache/beam/blob/master/sdks/python/apache_beam/examples/snippets/transforms/element_wise/filter.py
 tag:filter_side_inputs_iter %}```
 
+Output `PCollection` after `Filter`:
+
+```
+{% github_sample 
/apache/beam/blob/master/sdks/python/apache_beam/examples/snippets/transforms/element_wise/filter_test.py
 tag:valid_plants %}```
+
 <table>
   <td>
     <a class="button" target="_blank"
@@ -163,6 +189,11 @@ If the `PCollection` won't fit into memory, use 
`beam.pvalue.AsIter(pcollection)
 ```py
 {% github_sample 
/apache/beam/blob/master/sdks/python/apache_beam/examples/snippets/transforms/element_wise/filter.py
 tag:filter_side_inputs_dict %}```
 
+Output `PCollection` after `Filter`:
+
+```
+{% github_sample 
/apache/beam/blob/master/sdks/python/apache_beam/examples/snippets/transforms/element_wise/filter_test.py
 tag:perennials %}```
+
 <table>
   <td>
     <a class="button" target="_blank"

Reply via email to