1

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)
mon
  • 18,789
  • 22
  • 112
  • 205

2 Answers2

0

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!

-1

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

Lahkim Omar
  • 49
  • 1
  • 4