Skip to content

Commit 9f431f7

Browse files
authored
Move PeriodicStream into periodicsequence. (#35412)
* Move PeriodicStream into periodicsequence. * Consolidate PeriodicStream into PeriodicImpulse. * Fix fn_runner_test that used PeriodicStream. * Reformat * Fix some edge cases and resolve floating point precision problem. Add tests. * Fix lint and move tests for periodic impulse to its own test case. * Add more docstrings. Revise stop_timestamp part as it is an exclusive upper bound. * Fix pydoc error.
1 parent cd01e34 commit 9f431f7

File tree

5 files changed

+342
-348
lines changed

5 files changed

+342
-348
lines changed

sdks/python/apache_beam/ml/ts/util.py

Lines changed: 0 additions & 193 deletions
This file was deleted.

sdks/python/apache_beam/ml/ts/util_test.py

Lines changed: 0 additions & 93 deletions
This file was deleted.

sdks/python/apache_beam/runners/portability/fn_api_runner/fn_runner_test.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,6 @@
5353
from apache_beam.metrics import monitoring_infos
5454
from apache_beam.metrics.execution import MetricKey
5555
from apache_beam.metrics.metricbase import MetricName
56-
from apache_beam.ml.ts.util import PeriodicStream
5756
from apache_beam.options.pipeline_options import DebugOptions
5857
from apache_beam.options.pipeline_options import DirectOptions
5958
from apache_beam.options.pipeline_options import PipelineOptions
@@ -1264,7 +1263,7 @@ def test_sliding_windows(self):
12641263
with self.create_pipeline() as p:
12651264
ret = (
12661265
p
1267-
| PeriodicStream(data, interval=1)
1266+
| PeriodicImpulse(data=data, fire_interval=1)
12681267
| beam.WithKeys(0)
12691268
| beam.WindowInto(beam.transforms.window.SlidingWindows(6, 3))
12701269
| beam.GroupByKey())

0 commit comments

Comments
 (0)