TFX-什么是示例_gen_pb2,它在哪里记录?

发布于 2025-01-24 12:31:17 字数 631 浏览 5 评论 0 原文

示例GEN TFX Pipeline Component 具有示例代码,该示例代码使用 example_gen_pb2 但是它是什么,它在哪里记录?

# Input has a single split 'input_dir/*'.
# Output 2 splits: train:eval=3:1.
output = proto.Output(
             split_config=example_gen_pb2.SplitConfig(splits=[
                 proto.SplitConfig.Split(name='train', hash_buckets=3),
                 proto.SplitConfig.Split(name='eval', hash_buckets=1)
             ]))
example_gen = CsvExampleGen(input_base=input_dir, output_config=output)

The ExampleGen TFX Pipeline Component has the example code which uses example_gen_pb2 but what is it and where is it documented?

# Input has a single split 'input_dir/*'.
# Output 2 splits: train:eval=3:1.
output = proto.Output(
             split_config=example_gen_pb2.SplitConfig(splits=[
                 proto.SplitConfig.Split(name='train', hash_buckets=3),
                 proto.SplitConfig.Split(name='eval', hash_buckets=1)
             ]))
example_gen = CsvExampleGen(input_base=input_dir, output_config=output)

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

夜血缘 2025-01-31 12:31:17

API DOC是在这里
由于它是原始文件,最简单的方法是检查本身,它具有对数据结构的评论。
谢谢你!

The API doc is here.
Since it's proto file, the easiest way is checking the definition itself, which has comments for the data structure.
Thank you!

看海 2025-01-31 12:31:17

如果要导入它,则可以从tfx.proto:

from tfx.proto import example_gen_pb2

来源:

If you want to import it, you can do it from tfx.proto:

from tfx.proto import example_gen_pb2

Source:
https://github.com/tensorflow/tfx/blob/master/tfx/components/example_gen/utils_test.py

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文