【问题标题】:Error with visualization of apache beam interactive_beam on jupyter notebookjupyter notebook 上的 apache beam interactive_beam 可视化错误
【发布时间】:2022-06-21 23:25:52
【问题描述】:

目前,我正在使用 jupyter notebook 上的 apache beam 进行学习。我尝试了下面的代码并尝试使用 interactive_beam 显示输出,但是当我尝试运行 .show() 时,笔记本本身的标题看起来很笨重并且过度放大并且没有显示输出。

import apache_beam as beam
from apache_beam.runners.interactive.interactive_runner import InteractiveRunner
import apache_beam.runners.interactive.interactive_beam as ib

with beam.Pipeline(InteractiveRunner()) as p:
input_data = p | beam.Create([1,2,3,4,5])
ib.show(input_data)

Image of header

【问题讨论】:

  • 您能找到任何解决方法吗?

标签: jupyter-notebook apache-beam


【解决方案1】:

尝试使用ib.collect(input_data),它为我解决了这个问题

来源:https://codelabs.developers.google.com/codelabs/dataflow-notebooks-streamingwordcount#4

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2023-03-18
    • 2020-12-12
    • 1970-01-01
    • 1970-01-01
    • 2018-08-01
    • 2020-12-22
    • 1970-01-01
    相关资源
    最近更新 更多